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

Side by Side Diff: chrome/browser/ui/cocoa/extensions/browser_actions_controller.mm

Issue 11570009: Split PrefService into PrefService, PrefServiceSimple and PrefServiceSyncable. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to head again, previous had unrelated broken win_rel test. Created 7 years, 12 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) 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 "browser_actions_controller.h" 5 #import "browser_actions_controller.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 #include <string> 8 #include <string>
9 9
10 #include "base/sys_string_conversions.h" 10 #include "base/sys_string_conversions.h"
(...skipping 422 matching lines...) Expand 10 before | Expand all | Expand 10 after
433 if (effect == NSViewAnimationFadeInEffect) { 433 if (effect == NSViewAnimationFadeInEffect) {
434 return NO; 434 return NO;
435 } else if (effect == NSViewAnimationFadeOutEffect) { 435 } else if (effect == NSViewAnimationFadeOutEffect) {
436 return YES; 436 return YES;
437 } 437 }
438 438
439 NOTREACHED(); 439 NOTREACHED();
440 return YES; 440 return YES;
441 } 441 }
442 442
443 + (void)registerUserPrefs:(PrefService*)prefs { 443 + (void)registerUserPrefs:(PrefServiceSyncable*)prefs {
444 prefs->RegisterDoublePref(prefs::kBrowserActionContainerWidth, 444 prefs->RegisterDoublePref(prefs::kBrowserActionContainerWidth,
445 0, 445 0,
446 PrefService::UNSYNCABLE_PREF); 446 PrefServiceSyncable::UNSYNCABLE_PREF);
447 } 447 }
448 448
449 #pragma mark - 449 #pragma mark -
450 #pragma mark NSMenuDelegate 450 #pragma mark NSMenuDelegate
451 451
452 - (void)menuNeedsUpdate:(NSMenu*)menu { 452 - (void)menuNeedsUpdate:(NSMenu*)menu {
453 [menu removeAllItems]; 453 [menu removeAllItems];
454 454
455 // See menu_button.h for documentation on why this is needed. 455 // See menu_button.h for documentation on why this is needed.
456 [menu addItemWithTitle:@"" action:nil keyEquivalent:@""]; 456 [menu addItemWithTitle:@"" action:nil keyEquivalent:@""];
(...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after
869 const extensions::ExtensionList& toolbar_items = 869 const extensions::ExtensionList& toolbar_items =
870 toolbarModel_->toolbar_items(); 870 toolbarModel_->toolbar_items();
871 if (index < toolbar_items.size()) { 871 if (index < toolbar_items.size()) {
872 const Extension* extension = toolbar_items[index]; 872 const Extension* extension = toolbar_items[index];
873 return [buttons_ objectForKey:base::SysUTF8ToNSString(extension->id())]; 873 return [buttons_ objectForKey:base::SysUTF8ToNSString(extension->id())];
874 } 874 }
875 return nil; 875 return nil;
876 } 876 }
877 877
878 @end 878 @end
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/extensions/browser_actions_controller.h ('k') | chrome/browser/ui/cocoa/task_manager_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698