Ticket #7874: DecorInfo.diff

File DecorInfo.diff, 2.6 KB (added by humdinger, 13 years ago)

Localization

  • src/kits/interface/DecorInfo.cpp

     
    1919
    2020#include <DecoratorPrivate.h>
    2121
     22#include <Catalog.h>
     23#include <LocaleBackend.h>
     24using BPrivate::gLocaleBackend;
     25using BPrivate::LocaleBackend;
    2226
     27#undef B_TRANSLATE_CONTEXT
     28#define B_TRANSLATE_CONTEXT "DecorInfo"
     29
     30#undef B_TRANSLATE
     31#define B_TRANSLATE(str) \
     32    gLocaleBackend->GetString(B_TRANSLATE_MARK(str), "DecorInfo")
     33
    2334namespace BPrivate {
    2435
    2536
     
    258269                "decorator!?!?!\n");
    259270            return;
    260271        }
     272        // we need to translate some strings, and in order to do so, we need
     273        // to use the LocaleBackend to reach liblocale.so
     274        if (gLocaleBackend == NULL)
     275        LocaleBackend::LoadBackend();
    261276
    262         fName = "Default";
     277        fName = B_TRANSLATE_MARK("Default");
    263278        fAuthors = "DarkWyrm, Stephan Aßmus, Clemens Zeidler, Ingo Weinhold";
    264         fShortDescription = "Default Haiku window decorator.";
     279        fShortDescription = B_TRANSLATE_MARK("Default Haiku window decorator.");
    265280        fLongDescription = fShortDescription;
    266281        fLicenseURL = "http://";
    267282        fLicenseName = "MIT";
  • src/kits/locale/Jamfile

     
    6666SEARCH on [ FGristFiles AboutMenuItem.cpp ] += [ FDirName $(HAIKU_TOP) src kits shared ] ;
    6767SEARCH on [ FGristFiles AboutWindow.cpp ] += [ FDirName $(HAIKU_TOP) src kits shared ] ;
    6868SEARCH on [ FGristFiles ColorControl.cpp ] += [ FDirName $(HAIKU_TOP) src kits interface ] ;
    69 SEARCH on [ FGristFiles StringForSize.cpp ] += [ FDirName $(HAIKU_TOP) src kits shared ] ;
    70 SEARCH on [ FGristFiles TextView.cpp ] += [ FDirName $(HAIKU_TOP) src kits interface ] ;
     69SEARCH on [ FGristFiles DecorInfo.cpp ] += [ FDirName $(HAIKU_TOP) src kits interface ] ;
    7170SEARCH on [ FGristFiles Dragger.cpp ] += [ FDirName $(HAIKU_TOP) src kits interface ] ;
    7271SEARCH on [ FGristFiles Menu.cpp ] += [ FDirName $(HAIKU_TOP) src kits interface ] ;
    7372SEARCH on [ FGristFiles PrintJob.cpp ] += [ FDirName $(HAIKU_TOP) src kits interface ] ;
     73SEARCH on [ FGristFiles StringForSize.cpp ] += [ FDirName $(HAIKU_TOP) src kits shared ] ;
     74SEARCH on [ FGristFiles TextView.cpp ] += [ FDirName $(HAIKU_TOP) src kits interface ] ;
    7475SEARCH on [ FGristFiles ZombieReplicantView.cpp ] += [ FDirName $(HAIKU_TOP) src kits interface ] ;
    7576
    7677DoCatalogs liblocale.so
     
    7980    AboutMenuItem.cpp
    8081    AboutWindow.cpp
    8182    ColorControl.cpp
     83    DecorInfo.cpp
    8284    Dragger.cpp
    8385    Menu.cpp
    8486    PrintJob.cpp