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

Side by Side Diff: chrome/browser/cocoa/preferences_window_controller.mm

Issue 3305003: New authorization framework for sync. ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/cocoa/preferences_window_controller.h" 5 #import "chrome/browser/cocoa/preferences_window_controller.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "app/l10n_util.h" 9 #include "app/l10n_util.h"
10 #include "app/l10n_util_mac.h" 10 #include "app/l10n_util_mac.h"
(...skipping 1332 matching lines...) Expand 10 before | Expand all | Expand 10 after
1343 [alert setAlertStyle:NSWarningAlertStyle]; 1343 [alert setAlertStyle:NSWarningAlertStyle];
1344 const SEL kEndSelector = 1344 const SEL kEndSelector =
1345 @selector(stopSyncAlertDidEnd:returnCode:contextInfo:); 1345 @selector(stopSyncAlertDidEnd:returnCode:contextInfo:);
1346 [alert beginSheetModalForWindow:[self window] 1346 [alert beginSheetModalForWindow:[self window]
1347 modalDelegate:self 1347 modalDelegate:self
1348 didEndSelector:kEndSelector 1348 didEndSelector:kEndSelector
1349 contextInfo:NULL]; 1349 contextInfo:NULL];
1350 } else { 1350 } else {
1351 // Otherwise, the sync button was a "sync my bookmarks" button. 1351 // Otherwise, the sync button was a "sync my bookmarks" button.
1352 // Kick off the sync setup process. 1352 // Kick off the sync setup process.
1353 syncService_->EnableForUser(NULL); 1353 syncService_->ShowLoginDialog(NULL);
1354 ProfileSyncService::SyncEvent(ProfileSyncService::START_FROM_OPTIONS); 1354 ProfileSyncService::SyncEvent(ProfileSyncService::START_FROM_OPTIONS);
1355 } 1355 }
1356 } 1356 }
1357 1357
1358 // Called when the user clicks on the link to the privacy dashboard. 1358 // Called when the user clicks on the link to the privacy dashboard.
1359 - (IBAction)showPrivacyDashboard:(id)sender { 1359 - (IBAction)showPrivacyDashboard:(id)sender {
1360 Browser* browser = BrowserList::GetLastActive(); 1360 Browser* browser = BrowserList::GetLastActive();
1361 1361
1362 if (!browser || !browser->GetSelectedTabContents()) 1362 if (!browser || !browser->GetSelectedTabContents())
1363 browser = Browser::Create(profile_); 1363 browser = Browser::Create(profile_);
(...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after
2135 case OPTIONS_PAGE_ADVANCED: 2135 case OPTIONS_PAGE_ADVANCED:
2136 return underTheHoodView_; 2136 return underTheHoodView_;
2137 case OPTIONS_PAGE_DEFAULT: 2137 case OPTIONS_PAGE_DEFAULT:
2138 case OPTIONS_PAGE_COUNT: 2138 case OPTIONS_PAGE_COUNT:
2139 LOG(DFATAL) << "Invalid page value " << page; 2139 LOG(DFATAL) << "Invalid page value " << page;
2140 } 2140 }
2141 return basicsView_; 2141 return basicsView_;
2142 } 2142 }
2143 2143
2144 @end 2144 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698