OLD | NEW |
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 #ifndef CHROME_BROWSER_UI_COCOA_UI_LOCALIZER_H_ | 5 #ifndef CHROME_BROWSER_UI_COCOA_UI_LOCALIZER_H_ |
6 #define CHROME_BROWSER_UI_COCOA_UI_LOCALIZER_H_ | 6 #define CHROME_BROWSER_UI_COCOA_UI_LOCALIZER_H_ |
7 | 7 |
8 #import "third_party/GTM/AppKit/GTMUILocalizer.h" | 8 #import "third_party/google_toolbox_for_mac/src/AppKit/GTMUILocalizer.h" |
9 | 9 |
10 @class NSString; | 10 @class NSString; |
11 | 11 |
12 // A base class for generated localizers. | 12 // A base class for generated localizers. |
13 // | 13 // |
14 // To use this, include your xib file in the list generate_localizer scans (see | 14 // To use this, include your xib file in the list generate_localizer scans (see |
15 // chrome_browser.gypi). Then add an instance of ChromeUILocalizer to the xib. | 15 // chrome_browser.gypi). Then add an instance of ChromeUILocalizer to the xib. |
16 // Connect the owner_ outlet of the instance to the "File's Owner" of the xib. | 16 // Connect the owner_ outlet of the instance to the "File's Owner" of the xib. |
17 // It expects the owner_ outlet to be an instance or subclass of | 17 // It expects the owner_ outlet to be an instance or subclass of |
18 // NSWindowController or NSViewController. It will then localize any items in | 18 // NSWindowController or NSViewController. It will then localize any items in |
19 // the NSWindowController's window and subviews, or the NSViewController's view | 19 // the NSWindowController's window and subviews, or the NSViewController's view |
20 // and subviews, when awakeFromNib is called on the instance. You can | 20 // and subviews, when awakeFromNib is called on the instance. You can |
21 // optionally hook up otherObjectToLocalize_ and yetAnotherObjectToLocalize_ and | 21 // optionally hook up otherObjectToLocalize_ and yetAnotherObjectToLocalize_ and |
22 // those will also be localized. Strings in the xib that you want localized must | 22 // those will also be localized. Strings in the xib that you want localized must |
23 // start with ^IDS. The value must be a valid resource constant. | 23 // start with ^IDS. The value must be a valid resource constant. |
24 // Things that will be localized are: | 24 // Things that will be localized are: |
25 // - Titles and altTitles (for menus, buttons, windows, menuitems, -tabViewItem) | 25 // - Titles and altTitles (for menus, buttons, windows, menuitems, -tabViewItem) |
26 // - -stringValue (for labels) | 26 // - -stringValue (for labels) |
27 // - tooltips | 27 // - tooltips |
28 // - accessibility help | 28 // - accessibility help |
29 // - accessibility descriptions | 29 // - accessibility descriptions |
30 // - menus | 30 // - menus |
31 @interface ChromeUILocalizer : GTMUILocalizer | 31 @interface ChromeUILocalizer : GTMUILocalizer |
32 @end | 32 @end |
33 | 33 |
34 #endif // CHROME_BROWSER_UI_COCOA_UI_LOCALIZER_H_ | 34 #endif // CHROME_BROWSER_UI_COCOA_UI_LOCALIZER_H_ |
OLD | NEW |