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