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

Side by Side Diff: chrome/browser/themes/theme_service.cc

Issue 1497193002: Remove all the ephemeral apps code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Self review, Devlin review. Created 5 years 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/themes/theme_service.h" 5 #include "chrome/browser/themes/theme_service.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 118
119 ~ThemeObserver() override { 119 ~ThemeObserver() override {
120 extensions::ExtensionRegistry::Get(theme_service_->profile_) 120 extensions::ExtensionRegistry::Get(theme_service_->profile_)
121 ->RemoveObserver(this); 121 ->RemoveObserver(this);
122 } 122 }
123 123
124 private: 124 private:
125 void OnExtensionWillBeInstalled(content::BrowserContext* browser_context, 125 void OnExtensionWillBeInstalled(content::BrowserContext* browser_context,
126 const extensions::Extension* extension, 126 const extensions::Extension* extension,
127 bool is_update, 127 bool is_update,
128 bool from_ephemeral,
129 const std::string& old_name) override { 128 const std::string& old_name) override {
130 if (extension->is_theme()) { 129 if (extension->is_theme()) {
131 // The theme may be initially disabled. Wait till it is loaded (if ever). 130 // The theme may be initially disabled. Wait till it is loaded (if ever).
132 theme_service_->installed_pending_load_id_ = extension->id(); 131 theme_service_->installed_pending_load_id_ = extension->id();
133 } 132 }
134 } 133 }
135 134
136 void OnExtensionLoaded(content::BrowserContext* browser_context, 135 void OnExtensionLoaded(content::BrowserContext* browser_context,
137 const extensions::Extension* extension) override { 136 const extensions::Extension* extension) override {
138 if (extension->is_theme() && 137 if (extension->is_theme() &&
(...skipping 558 matching lines...) Expand 10 before | Expand all | Expand 10 after
697 void ThemeService::OnInfobarDestroyed() { 696 void ThemeService::OnInfobarDestroyed() {
698 number_of_infobars_--; 697 number_of_infobars_--;
699 698
700 if (number_of_infobars_ == 0) 699 if (number_of_infobars_ == 0)
701 RemoveUnusedThemes(false); 700 RemoveUnusedThemes(false);
702 } 701 }
703 702
704 ThemeSyncableService* ThemeService::GetThemeSyncableService() const { 703 ThemeSyncableService* ThemeService::GetThemeSyncableService() const {
705 return theme_syncable_service_.get(); 704 return theme_syncable_service_.get();
706 } 705 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/chrome_browser_main_extra_parts_profiles.cc ('k') | chrome/browser/ui/app_list/app_list_test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698