Popular sites on the NTP: Try to keep the ordering constant
[chromium-blink-merge.git] / content / public / browser / font_list_async.h
blob07510db5e3aebffe198e4a071276ce344f3e4283
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CONTENT_PUBLIC_BROWSER_FONT_LIST_ASYNC_H_
6 #define CONTENT_PUBLIC_BROWSER_FONT_LIST_ASYNC_H_
8 #include "base/callback_forward.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "content/common/content_export.h"
12 namespace base {
13 class ListValue;
16 namespace content {
18 // Retrieves the list of fonts on the system as a list of strings. It provides
19 // a non-blocking interface to GetFontList_SlowBlocking in common/.
21 // This function will run asynchronously on a background thread since getting
22 // the font list from the system can be slow. This function may be called from
23 // any thread that has a BrowserThread::ID. The callback will be executed on
24 // the calling thread.
25 CONTENT_EXPORT void GetFontListAsync(
26 const base::Callback<void(scoped_ptr<base::ListValue>)>& callback);
28 } // namespace content
30 #endif // CONTENT_PUBLIC_BROWSER_FONT_LIST_ASYNC_H_