| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "app/mac/nsimage_cache.h" | 10 #include "app/mac/nsimage_cache.h" |
| (...skipping 399 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 410 return NO; | 410 return NO; |
| 411 } else if (effect == NSViewAnimationFadeOutEffect) { | 411 } else if (effect == NSViewAnimationFadeOutEffect) { |
| 412 return YES; | 412 return YES; |
| 413 } | 413 } |
| 414 | 414 |
| 415 NOTREACHED(); | 415 NOTREACHED(); |
| 416 return YES; | 416 return YES; |
| 417 } | 417 } |
| 418 | 418 |
| 419 + (void)registerUserPrefs:(PrefService*)prefs { | 419 + (void)registerUserPrefs:(PrefService*)prefs { |
| 420 prefs->RegisterDoublePref(prefs::kBrowserActionContainerWidth, 0); | 420 prefs->RegisterDoublePref(prefs::kBrowserActionContainerWidth, |
| 421 0, |
| 422 PrefService::UNSYNCABLE_PREF); |
| 421 } | 423 } |
| 422 | 424 |
| 423 #pragma mark - | 425 #pragma mark - |
| 424 #pragma mark Private Methods | 426 #pragma mark Private Methods |
| 425 | 427 |
| 426 - (void)createButtons { | 428 - (void)createButtons { |
| 427 if (!toolbarModel_) | 429 if (!toolbarModel_) |
| 428 return; | 430 return; |
| 429 | 431 |
| 430 NSUInteger i = 0; | 432 NSUInteger i = 0; |
| (...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 855 if (profile_->IsOffTheRecord()) | 857 if (profile_->IsOffTheRecord()) |
| 856 index = toolbarModel_->IncognitoIndexToOriginal(index); | 858 index = toolbarModel_->IncognitoIndexToOriginal(index); |
| 857 if (index < toolbarModel_->size()) { | 859 if (index < toolbarModel_->size()) { |
| 858 const Extension* extension = toolbarModel_->GetExtensionByIndex(index); | 860 const Extension* extension = toolbarModel_->GetExtensionByIndex(index); |
| 859 return [buttons_ objectForKey:base::SysUTF8ToNSString(extension->id())]; | 861 return [buttons_ objectForKey:base::SysUTF8ToNSString(extension->id())]; |
| 860 } | 862 } |
| 861 return nil; | 863 return nil; |
| 862 } | 864 } |
| 863 | 865 |
| 864 @end | 866 @end |
| OLD | NEW |