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

Unified Diff: chrome/browser/ui/gtk/gtk_theme_service.cc

Issue 6766004: Create a ProfileDependencyManager to order ProfileKeyedService destruction. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix improper usage of static_cast<> in existing mac code. Created 9 years, 9 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
« no previous file with comments | « chrome/browser/ui/gtk/gtk_theme_service.h ('k') | chrome/browser/ui/gtk/reload_button_gtk.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/gtk/gtk_theme_service.cc
diff --git a/chrome/browser/ui/gtk/gtk_theme_service.cc b/chrome/browser/ui/gtk/gtk_theme_service.cc
index 81bf8a96815c0258c695fce8f0a937a036a5ea9f..bab5948559777a9824dcec755e802a37394914fe 100644
--- a/chrome/browser/ui/gtk/gtk_theme_service.cc
+++ b/chrome/browser/ui/gtk/gtk_theme_service.cc
@@ -327,7 +327,7 @@ bool GtkThemeService::HasCustomImage(int id) const {
void GtkThemeService::InitThemesFor(NotificationObserver* observer) {
observer->Observe(NotificationType::BROWSER_THEME_CHANGED,
- Source<ui::ThemeProvider>(this),
+ Source<ThemeService>(this),
NotificationService::NoDetails());
}
@@ -358,8 +358,11 @@ void GtkThemeService::Observe(NotificationType type,
const NotificationSource& source,
const NotificationDetails& details) {
if ((type == NotificationType::PREF_CHANGED) &&
- (*Details<std::string>(details).ptr() == prefs::kUsesSystemTheme))
+ (*Details<std::string>(details).ptr() == prefs::kUsesSystemTheme)) {
use_gtk_ = profile()->GetPrefs()->GetBoolean(prefs::kUsesSystemTheme);
+ } else {
+ ThemeService::Observe(type, source, details);
+ }
}
GtkWidget* GtkThemeService::BuildChromeButton() {
« no previous file with comments | « chrome/browser/ui/gtk/gtk_theme_service.h ('k') | chrome/browser/ui/gtk/reload_button_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698