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

Side by Side Diff: chrome/browser/ui/cocoa/first_run_dialog.mm

Issue 9153008: Progressively refacto FirstRun class to first_run namespace(part 4). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/first_run/first_run_win.cc ('k') | chrome/browser/ui/gtk/first_run_dialog.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #import "chrome/browser/ui/cocoa/first_run_dialog.h" 5 #import "chrome/browser/ui/cocoa/first_run_dialog.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/mac/mac_util.h" 8 #include "base/mac/mac_util.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #import "base/memory/scoped_nsobject.h" 10 #import "base/memory/scoped_nsobject.h"
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 145
146 } // namespace 146 } // namespace
147 147
148 namespace first_run { 148 namespace first_run {
149 149
150 void ShowFirstRunDialog(Profile* profile, 150 void ShowFirstRunDialog(Profile* profile,
151 bool randomize_search_engine_experiment) { 151 bool randomize_search_engine_experiment) {
152 // If the default search is not managed via policy, ask the user to 152 // If the default search is not managed via policy, ask the user to
153 // choose a default. 153 // choose a default.
154 TemplateURLService* model = TemplateURLServiceFactory::GetForProfile(profile); 154 TemplateURLService* model = TemplateURLServiceFactory::GetForProfile(profile);
155 if (FirstRun::ShouldShowSearchEngineSelector(model)) { 155 if (first_run::ShouldShowSearchEngineSelector(model)) {
156 ShowSearchEngineSelectionDialog(profile, 156 ShowSearchEngineSelectionDialog(profile,
157 randomize_search_engine_experiment); 157 randomize_search_engine_experiment);
158 } 158 }
159 ShowFirstRun(profile); 159 ShowFirstRun(profile);
160 } 160 }
161 161
162 } // namespace first_run 162 } // namespace first_run
163 163
164 @implementation FirstRunDialogController 164 @implementation FirstRunDialogController
165 165
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 300
301 - (IBAction)learnMore:(id)sender { 301 - (IBAction)learnMore:(id)sender {
302 GURL url = google_util::AppendGoogleLocaleParam( 302 GURL url = google_util::AppendGoogleLocaleParam(
303 GURL(chrome::kLearnMoreReportingURL)); 303 GURL(chrome::kLearnMoreReportingURL));
304 NSString* urlStr = base::SysUTF8ToNSString(url.spec());; 304 NSString* urlStr = base::SysUTF8ToNSString(url.spec());;
305 NSURL* learnMoreUrl = [NSURL URLWithString:urlStr]; 305 NSURL* learnMoreUrl = [NSURL URLWithString:urlStr];
306 [[NSWorkspace sharedWorkspace] openURL:learnMoreUrl]; 306 [[NSWorkspace sharedWorkspace] openURL:learnMoreUrl];
307 } 307 }
308 308
309 @end 309 @end
OLDNEW
« no previous file with comments | « chrome/browser/first_run/first_run_win.cc ('k') | chrome/browser/ui/gtk/first_run_dialog.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698