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

Unified Diff: chrome/test/testing_profile.cc

Issue 223027: Convert the BrowerThemeProvider pointer from being ref counted to (Closed)
Patch Set: Created 11 years, 3 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/test/testing_profile.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/testing_profile.cc
diff --git a/chrome/test/testing_profile.cc b/chrome/test/testing_profile.cc
index bddfc7f526a7e775fcd8c74046190ce790c6dd83..2f417cfe9550a4f7f7f98b7503d3b9c1cd6b7936 100644
--- a/chrome/test/testing_profile.cc
+++ b/chrome/test/testing_profile.cc
@@ -175,19 +175,18 @@ void TestingProfile::CreateTemplateURLModel() {
void TestingProfile::UseThemeProvider(BrowserThemeProvider* theme_provider) {
theme_provider->Init(this);
created_theme_provider_ = true;
- theme_provider_ = theme_provider;
+ theme_provider_.reset(theme_provider);
}
void TestingProfile::InitThemes() {
if (!created_theme_provider_) {
#if defined(OS_LINUX) && !defined(TOOLKIT_VIEWS)
- scoped_refptr<BrowserThemeProvider> themes(new GtkThemeProvider);
+ theme_provider_.reset(new GtkThemeProvider);
#else
- scoped_refptr<BrowserThemeProvider> themes(new BrowserThemeProvider);
+ theme_provider_.reset(new BrowserThemeProvider);
#endif
- themes->Init(this);
+ theme_provider_->Init(this);
created_theme_provider_ = true;
- theme_provider_.swap(themes);
}
}
« no previous file with comments | « chrome/test/testing_profile.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698