OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #import "chrome/browser/cocoa/preferences_localizer.h" |
| 6 |
| 7 #include "app/l10n_util.h" |
| 8 #include "base/sys_string_conversions.h" |
| 9 #include "grit/chromium_strings.h" |
| 10 #include "grit/generated_resources.h" |
| 11 |
| 12 @implementation PreferencesLocalizer |
| 13 |
| 14 // Override to map into our string bundles instead of strings plists. |
| 15 // TODO(pinkerton): This should use a string lookup table to map the string to |
| 16 // a constant. |
| 17 - (NSString *)localizedStringForString:(NSString *)string { |
| 18 if ([string isEqualToString: |
| 19 @"^Make Chromium My Default Browser"]) { |
| 20 std::wstring tempString = |
| 21 l10n_util::GetStringF(IDS_OPTIONS_DEFAULTBROWSER_USEASDEFAULT, |
| 22 l10n_util::GetString(IDS_PRODUCT_NAME)); |
| 23 return base::SysWideToNSString(tempString); |
| 24 } |
| 25 return [super localizedStringForString:string]; |
| 26 } |
| 27 |
| 28 @end |
OLD | NEW |