Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(263)

Unified Diff: chrome/browser/ui/webui/options/font_settings_handler.h

Issue 7044012: Support getting the font list in Pepper. This currently only works out of (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/options/font_settings_handler.h
===================================================================
--- chrome/browser/ui/webui/options/font_settings_handler.h (revision 85766)
+++ chrome/browser/ui/webui/options/font_settings_handler.h (working copy)
@@ -6,13 +6,14 @@
#define CHROME_BROWSER_UI_WEBUI_OPTIONS_FONT_SETTINGS_HANDLER_H_
#pragma once
+#include "base/memory/weak_ptr.h"
#include "chrome/browser/prefs/pref_member.h"
-#include "chrome/browser/ui/webui/options/font_settings_fonts_list_loader.h"
#include "chrome/browser/ui/webui/options/options_ui.h"
+#include "content/browser/font_list_async.h"
// Font settings overlay page UI handler.
-class FontSettingsHandler : public OptionsPageUIHandler,
- public FontSettingsFontsListLoader::Observer {
+class FontSettingsHandler : public base::SupportsWeakPtr<FontSettingsHandler>,
+ public OptionsPageUIHandler {
public:
FontSettingsHandler();
virtual ~FontSettingsHandler();
@@ -30,12 +31,11 @@
const NotificationSource& source,
const NotificationDetails& details);
- // FontSettingsFontsListLoader::Observer implementation.
- virtual void FontsListHasLoaded();
-
private:
void HandleFetchFontsData(const ListValue* args);
+ void FontsListHasLoaded(scoped_refptr<content::FontListResult> list);
+
void SetUpStandardFontSample();
void SetUpSerifFontSample();
void SetUpSansSerifFontSample();
@@ -51,8 +51,6 @@
IntegerPrefMember default_fixed_font_size_;
IntegerPrefMember minimum_font_size_;
- scoped_refptr<FontSettingsFontsListLoader> fonts_list_loader_;
-
DISALLOW_COPY_AND_ASSIGN(FontSettingsHandler);
};

Powered by Google App Engine
This is Rietveld 408576698