* Update all applications in tree to use the new localizing system
* Remove the old one from the locale librairy, with some cleanup Known regressions : * readonlybootprompt will no longer update the locale settings : the method used messed with internal undocumented things * external localized apps (webpositive for example) will not run anymore. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37336 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -45,8 +45,6 @@ class BCatalog {
|
||||
const BCatalog& operator= (const BCatalog&);
|
||||
// hide assignment and copy-constructor
|
||||
|
||||
static status_t GetAppCatalog(BCatalog*);
|
||||
|
||||
BCatalogAddOn *fCatalog;
|
||||
|
||||
private:
|
||||
@@ -55,10 +53,6 @@ class BCatalog {
|
||||
};
|
||||
|
||||
|
||||
extern BCatalog* be_catalog;
|
||||
extern BCatalog* be_app_catalog;
|
||||
|
||||
|
||||
// Proxy class for handling a "shared object local" catalog.
|
||||
// This must be included (statically linked) into each shared object needing
|
||||
// a catalog on its own (application, add-on, library, ...). The shared object
|
||||
@@ -70,6 +64,9 @@ class BCatalogStub {
|
||||
|
||||
public:
|
||||
static BCatalog* GetCatalog();
|
||||
static void ForceReload();
|
||||
// Use this to force re-initialisation of the catalog (when there
|
||||
// is a locale change for example)
|
||||
};
|
||||
|
||||
|
||||
@@ -96,7 +93,6 @@ class BCatalogStub {
|
||||
// source-file.
|
||||
|
||||
|
||||
#ifdef B_TRANSLATE_USE_NEW_MACROS
|
||||
// Translation macros which may be used to shorten translation requests:
|
||||
#undef B_TRANSLATE
|
||||
#define B_TRANSLATE(str) \
|
||||
@@ -113,22 +109,6 @@ class BCatalogStub {
|
||||
#undef B_TRANSLATE_ID
|
||||
#define B_TRANSLATE_ID(id) \
|
||||
BCatalogStub::GetCatalog()->GetString((id))
|
||||
#else
|
||||
#define B_TRANSLATE(str) \
|
||||
be_catalog->GetString((str), B_TRANSLATE_CONTEXT)
|
||||
|
||||
#undef B_TRANSLATE_COMMENT
|
||||
#define B_TRANSLATE_COMMENT(str, cmt) \
|
||||
be_catalog->GetString((str), B_TRANSLATE_CONTEXT, (cmt))
|
||||
|
||||
#undef B_TRANSLATE_ALL
|
||||
#define B_TRANSLATE_ALL(str, ctx, cmt) \
|
||||
be_catalog->GetString((str), (ctx), (cmt))
|
||||
|
||||
#undef B_TRANSLATE_ID
|
||||
#define B_TRANSLATE_ID(id) \
|
||||
be_catalog->GetString((id))
|
||||
#endif
|
||||
|
||||
// Translation markers which can be used to mark static strings/IDs which
|
||||
// are used as key for translation requests (at other places in the code):
|
||||
|
||||
@@ -1,120 +0,0 @@
|
||||
#ifndef _CATALOG_IN_ADD_ON_H_
|
||||
#define _CATALOG_IN_ADD_ON_H_
|
||||
|
||||
#include <Catalog.h>
|
||||
#include <Entry.h>
|
||||
#include <Locale.h>
|
||||
#include <LocaleRoster.h>
|
||||
#include <Node.h>
|
||||
#include <TypeConstants.h>
|
||||
|
||||
/*
|
||||
* This header file is somewhat special...
|
||||
*
|
||||
* Since the TR-macros are referencing be_catalog, we want each add-on
|
||||
* to have its own be_catalog (instead of sharing the one from the lib).
|
||||
* In order to do so, we define another be_catalog in this file, which
|
||||
* will override the one from liblocale.so.
|
||||
* This way we implement something like add-on-local storage. It would
|
||||
* be desirable to find a better way, so please tell us if you know one!
|
||||
*
|
||||
* Every add-on that wants to use the Locale Kit needs to include this
|
||||
* file once (no more, exactly once!).
|
||||
* You have to include it in the source-file that loads the add-on's
|
||||
* catalog (by use of get_add_on_catalog().
|
||||
*
|
||||
*/
|
||||
|
||||
BCatalog *be_catalog = NULL;
|
||||
// global that points to this add-on's catalog
|
||||
|
||||
|
||||
/*
|
||||
* utility function which determines the entry-ref for "this" add-on:
|
||||
*/
|
||||
static status_t
|
||||
get_add_on_ref(entry_ref *ref)
|
||||
{
|
||||
if (!ref)
|
||||
return B_BAD_VALUE;
|
||||
|
||||
image_info imageInfo;
|
||||
int32 cookie = 0;
|
||||
status_t res = B_ERROR;
|
||||
void *dataPtr = static_cast<void*>(&be_catalog);
|
||||
while ((res = get_next_image_info(0, &cookie, &imageInfo)) == B_OK) {
|
||||
char *dataStart = static_cast<char*>(imageInfo.data);
|
||||
if (imageInfo.type == B_ADD_ON_IMAGE && dataStart <= dataPtr
|
||||
&& dataStart+imageInfo.data_size > dataPtr) {
|
||||
get_ref_for_path(imageInfo.name, ref);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Every add-on should load its catalog through this function, since
|
||||
* it does not only load the add-on's catalog, but it does several
|
||||
* other useful things:
|
||||
* - be_catalog (the one belonging to this add-on) is initialized
|
||||
* such that the TR-macros use the add-on's catalog.
|
||||
* - if givenSig is empty (NULL or "") the add-on's signature is
|
||||
* used to determine the catalog-sig.
|
||||
* - if the add-on's executable contains an embedded catalog, that
|
||||
* one is loaded, too.
|
||||
*/
|
||||
status_t
|
||||
get_add_on_catalog(BCatalog* cat, const char *givenSig)
|
||||
{
|
||||
if (!cat)
|
||||
return B_BAD_VALUE;
|
||||
|
||||
// determine entry-ref of the add-on this code lives in:
|
||||
entry_ref ref;
|
||||
status_t res = get_add_on_ref(&ref);
|
||||
if (res == B_OK) {
|
||||
// ok, we have found the entry-ref for our add-on,
|
||||
// so we try to fetch the fingerprint from our add-on-file:
|
||||
int32 fp = 0;
|
||||
BNode addOnNode(&ref);
|
||||
addOnNode.ReadAttr(BLocaleRoster::kCatFingerprintAttr,
|
||||
B_INT32_TYPE, 0, &fp, sizeof(int32));
|
||||
BString sig(givenSig);
|
||||
if (sig.Length() == 0) {
|
||||
res = addOnNode.ReadAttrString("BEOS:MIME", &sig);
|
||||
if (res == B_OK) {
|
||||
// drop supertype from mimetype (should be "application/"):
|
||||
int32 pos = sig.FindFirst('/');
|
||||
if (pos >= 0)
|
||||
sig.Remove(0, pos+1);
|
||||
}
|
||||
}
|
||||
if (res == B_OK) {
|
||||
// try to load it's catalog...
|
||||
cat->fCatalog
|
||||
= be_locale_roster->LoadCatalog(sig.String(), NULL, fp);
|
||||
// ...and try to load an embedded catalog, too (if that exists):
|
||||
BCatalogAddOn *embeddedCatalog
|
||||
= be_locale_roster->LoadEmbeddedCatalog(&ref);
|
||||
if (embeddedCatalog) {
|
||||
if (!cat->fCatalog)
|
||||
// embedded catalog is the only catalog that was found:
|
||||
cat->fCatalog = embeddedCatalog;
|
||||
else {
|
||||
// append embedded catalog to list of loaded catalogs:
|
||||
BCatalogAddOn *currCat = cat->fCatalog;
|
||||
while (currCat->fNext)
|
||||
currCat = currCat->fNext;
|
||||
currCat->fNext = embeddedCatalog;
|
||||
}
|
||||
}
|
||||
be_catalog = cat;
|
||||
}
|
||||
}
|
||||
return cat->InitCheck();
|
||||
}
|
||||
|
||||
|
||||
#endif /* _CATALOG_IN_ADD_ON_H_ */
|
||||
@@ -45,8 +45,6 @@ class BLocale {
|
||||
|
||||
void GetSortKey(const char *string, BString *key);
|
||||
|
||||
status_t GetAppCatalog(BCatalog *);
|
||||
|
||||
protected:
|
||||
BCollator *fCollator;
|
||||
BLanguage *fLanguage;
|
||||
|
||||
@@ -33,11 +33,6 @@ class BLocaleRoster {
|
||||
BLocaleRoster();
|
||||
~BLocaleRoster();
|
||||
|
||||
// status_t GetCatalog(BLocale *,const char *mimeType, BCatalog *catalog);
|
||||
// status_t GetCatalog(const char *mimeType, BCatalog *catalog);
|
||||
// status_t SetCatalog(BLocale *,const char *mimeType, BCatalog *catalog);
|
||||
BCatalog* GetCatalog(BCatalog* catalog, vint32* catalogInitStatus);
|
||||
|
||||
// status_t GetLocaleFor(const char *langCode, const char *countryCode);
|
||||
|
||||
status_t GetSystemCatalog(BCatalogAddOn **) const;
|
||||
@@ -73,6 +68,7 @@ class BLocaleRoster {
|
||||
static int32 kEmbeddedCatResId;
|
||||
|
||||
private:
|
||||
BCatalog* GetCatalog(BCatalog* catalog, vint32* catalogInitStatus);
|
||||
|
||||
BCatalogAddOn* LoadCatalog(const char *signature,
|
||||
const char *language = NULL, int32 fingerprint = 0);
|
||||
@@ -83,6 +79,7 @@ class BLocaleRoster {
|
||||
const char *signature, const char *language);
|
||||
|
||||
friend class BCatalog;
|
||||
friend class BCatalogStub;
|
||||
friend class BPrivate::EditableCatalog;
|
||||
friend status_t get_add_on_catalog(BCatalog*, const char *);
|
||||
};
|
||||
|
||||
@@ -9,7 +9,7 @@ Application ZipOMatic-Z :
|
||||
ZipOMaticWindow.cpp
|
||||
ZipperThread.cpp
|
||||
|
||||
: be tracker $(TARGET_LIBSUPC++) liblocale.so
|
||||
: be tracker $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
: ZipOMatic.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -37,7 +37,6 @@ ZipOMatic::ZipOMatic()
|
||||
fGotRefs(false),
|
||||
fInvoker(new BInvoker(new BMessage(ZIPPO_QUIT_OR_CONTINUE), NULL, this))
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -28,8 +28,6 @@ private:
|
||||
|
||||
bool fGotRefs;
|
||||
BInvoker* fInvoker;
|
||||
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
#endif // _ZIPOMATIC_H_
|
||||
|
||||
@@ -191,9 +191,7 @@ TranslationComparator(const void* left, const void* right)
|
||||
|
||||
class AboutApp : public BApplication {
|
||||
public:
|
||||
AboutApp();
|
||||
private:
|
||||
BCatalog fCatalog;
|
||||
AboutApp();
|
||||
};
|
||||
|
||||
|
||||
@@ -292,7 +290,6 @@ private:
|
||||
AboutApp::AboutApp()
|
||||
: BApplication("application/x-vnd.Haiku-About")
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
AboutWindow *window = new(std::nothrow) AboutWindow();
|
||||
if (window)
|
||||
window->Show();
|
||||
|
||||
@@ -19,7 +19,7 @@ Application AboutSystem :
|
||||
HyperTextActions.cpp
|
||||
HyperTextView.cpp
|
||||
Utilities.cpp
|
||||
: $(TARGET_LIBSTDC++) be translation liblocale.so
|
||||
: $(TARGET_LIBSTDC++) be translation $(HAIKU_LOCALE_LIBS)
|
||||
: AboutSystem.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -30,16 +30,12 @@ public:
|
||||
virtual void ReadyToRun();
|
||||
|
||||
virtual void AboutRequested();
|
||||
|
||||
private:
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
|
||||
BootManager::BootManager()
|
||||
: BApplication(kSignature)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ Application bootman :
|
||||
be
|
||||
textencoding
|
||||
tracker
|
||||
liblocale.so
|
||||
$(HAIKU_LOCALE_LIBS)
|
||||
$(TARGET_LIBSUPC++)
|
||||
:
|
||||
bootman.rdef
|
||||
|
||||
@@ -130,11 +130,8 @@ CodyCam::CodyCam()
|
||||
fVideoConsumer(NULL),
|
||||
fWindow(NULL),
|
||||
fPort(0),
|
||||
fVideoControlWindow(NULL),
|
||||
fAppCatalog(NULL)
|
||||
fVideoControlWindow(NULL)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fAppCatalog);
|
||||
|
||||
int32 index = 0;
|
||||
kCaptureRate[index++] = B_TRANSLATE("Every 15 seconds");
|
||||
kCaptureRate[index++] = B_TRANSLATE("Every 30 seconds");
|
||||
|
||||
@@ -110,7 +110,6 @@ private:
|
||||
BWindow* fWindow;
|
||||
port_id fPort;
|
||||
BWindow* fVideoControlWindow;
|
||||
BCatalog fAppCatalog;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -11,7 +11,8 @@ Application CodyCam :
|
||||
Settings.cpp
|
||||
SettingsHandler.cpp
|
||||
VideoConsumer.cpp
|
||||
: be locale media translation $(TARGET_NETAPI_LIB) $(TARGET_LIBSTDC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) media translation $(TARGET_NETAPI_LIB)
|
||||
$(TARGET_LIBSTDC++)
|
||||
: CodyCam.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -95,7 +95,6 @@ TBarApp::TBarApp()
|
||||
InitSettings();
|
||||
InitIconPreloader();
|
||||
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
be_roster->StartWatching(this);
|
||||
|
||||
sBarTeamInfoList.MakeEmpty();
|
||||
|
||||
@@ -178,8 +178,6 @@ class TBarApp : public BApplication {
|
||||
static BLocker sSubscriberLock;
|
||||
static BList sBarTeamInfoList;
|
||||
static BList sSubscribers;
|
||||
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
#endif // BAR_APP_H
|
||||
|
||||
@@ -39,7 +39,7 @@ Application Deskbar :
|
||||
ResourceSet.cpp
|
||||
Switcher.cpp
|
||||
$(targetSource)
|
||||
: be tracker liblocale.so $(targetLib) $(TARGET_LIBSUPC++)
|
||||
: be tracker $(HAIKU_LOCALE_LIBS) $(targetLib) $(TARGET_LIBSUPC++)
|
||||
;
|
||||
|
||||
DoCatalogs Deskbar :
|
||||
|
||||
@@ -89,7 +89,6 @@ class DiskProbe : public BApplication {
|
||||
uint32 fWindowCount;
|
||||
BRect fWindowFrame;
|
||||
BMessenger fFindTarget;
|
||||
BCatalog fAppCatalog;
|
||||
};
|
||||
|
||||
|
||||
@@ -236,10 +235,8 @@ DiskProbe::DiskProbe()
|
||||
: BApplication(kSignature),
|
||||
fOpenWindow(NULL),
|
||||
fFindWindow(NULL),
|
||||
fWindowCount(0),
|
||||
fAppCatalog(NULL)
|
||||
fWindowCount(0)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fAppCatalog);
|
||||
fFilePanel = new BFilePanel();
|
||||
fWindowFrame = fSettings.Message().FindRect("window_frame");
|
||||
}
|
||||
|
||||
@@ -16,8 +16,8 @@ Application DiskProbe :
|
||||
ProbeView.cpp
|
||||
OpenWindow.cpp
|
||||
FindWindow.cpp
|
||||
: be locale tracker translation libexpression_parser.a libmapm.a
|
||||
$(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) tracker translation libexpression_parser.a
|
||||
libmapm.a $(TARGET_LIBSUPC++)
|
||||
: DiskProbe.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -36,8 +36,6 @@ DriveSetup::~DriveSetup()
|
||||
void
|
||||
DriveSetup::ReadyToRun()
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
fWindow = new MainWindow(BRect(50, 50, 600, 450));
|
||||
if (_RestoreSettings() != B_OK)
|
||||
fWindow->ApplyDefaultSettings();
|
||||
|
||||
@@ -32,7 +32,6 @@ private:
|
||||
MainWindow* fWindow;
|
||||
|
||||
BMessage fSettings;
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -13,7 +13,8 @@ Preference DriveSetup :
|
||||
PartitionList.cpp
|
||||
Support.cpp
|
||||
|
||||
: be liblocale.so libcolumnlistview.a libshared.a $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) libcolumnlistview.a libshared.a
|
||||
$(TARGET_LIBSUPC++)
|
||||
: DriveSetup.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
ExpanderApp::ExpanderApp()
|
||||
: BApplication("application/x-vnd.Haiku-Expander")
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
BPoint windowPosition = fSettings.Message().FindPoint("window_position");
|
||||
BRect windowFrame(0, 0, 450, 120);
|
||||
windowFrame.OffsetBy(windowPosition);
|
||||
|
||||
@@ -48,7 +48,6 @@ class ExpanderApp : public BApplication {
|
||||
void UpdateSettingsFrom(BMessage *message);
|
||||
private:
|
||||
ExpanderWindow *fWindow;
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
#endif /* _ExpanderApp_h */
|
||||
|
||||
@@ -9,7 +9,7 @@ Application Expander :
|
||||
ExpanderPreferences.cpp
|
||||
DirectoryFilePanel.cpp
|
||||
ExpanderRules.cpp
|
||||
: be tracker liblocale.so $(TARGET_LIBSUPC++)
|
||||
: be tracker $(HAIKU_LOCALE_LIBS) $(TARGET_LIBSUPC++)
|
||||
: Expander.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -99,9 +99,6 @@ InstallerApp::AboutRequested()
|
||||
void
|
||||
InstallerApp::ReadyToRun()
|
||||
{
|
||||
// Initilialize the Locale Kit
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
const char* infoText = B_TRANSLATE(
|
||||
"Welcome to the Haiku Installer!\n\n"
|
||||
|
||||
|
||||
@@ -21,7 +21,6 @@ public:
|
||||
|
||||
private:
|
||||
BWindow* fEULAWindow;
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
#endif // INSTALLER_APP_H
|
||||
|
||||
@@ -12,7 +12,8 @@ Application Installer :
|
||||
ProgressReporter.cpp
|
||||
UnzipEngine.cpp
|
||||
WorkerThread.cpp
|
||||
: be tracker translation libshared.a $(TARGET_LIBSTDC++) liblocale.so
|
||||
: be tracker translation libshared.a $(TARGET_LIBSTDC++)
|
||||
$(HAIKU_LOCALE_LIBS)
|
||||
: Installer.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -33,8 +33,8 @@ Application Mail :
|
||||
WIndex.cpp
|
||||
Words.cpp
|
||||
KUndoBuffer.cpp
|
||||
: be tracker $(TARGET_LIBSTDC++) $(TARGET_LIBSUPC++) liblocale.so libmail.so
|
||||
libtextencoding.so
|
||||
: be tracker $(TARGET_LIBSTDC++) $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
libmail.so libtextencoding.so
|
||||
: Mail.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -117,8 +117,6 @@ TMailApp::TMailApp()
|
||||
fMailCharacterSet(B_MS_WINDOWS_CONVERSION),
|
||||
fContentFont(be_fixed_font)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
// set default values
|
||||
fContentFont.SetSize(12.0);
|
||||
fAutoMarkRead = true;
|
||||
|
||||
@@ -129,8 +129,6 @@ class TMailApp : public BApplication {
|
||||
int32 fUseAccountFrom;
|
||||
uint32 fMailCharacterSet;
|
||||
BFont fContentFont;
|
||||
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ Application MidiPlayer :
|
||||
MidiPlayerWindow.cpp
|
||||
ScopeView.cpp
|
||||
SynthBridge.cpp
|
||||
: be midi midi2 $(TARGET_LIBSUPC++) liblocale.so
|
||||
: be midi midi2 $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
: MidiPlayer.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -34,7 +34,6 @@
|
||||
MidiPlayerApp::MidiPlayerApp()
|
||||
: BApplication(MIDI_PLAYER_SIGNATURE)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
window = new MidiPlayerWindow;
|
||||
}
|
||||
|
||||
|
||||
@@ -39,7 +39,6 @@ class MidiPlayerApp : public BApplication {
|
||||
|
||||
private:
|
||||
typedef BApplication super;
|
||||
BCatalog fCatalog;
|
||||
MidiPlayerWindow* window;
|
||||
};
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ Application PackageInstaller :
|
||||
PackageTextViewer.cpp
|
||||
PackageImageViewer.cpp
|
||||
InstalledPackageInfo.cpp
|
||||
: be locale tracker translation z $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) tracker translation z $(TARGET_LIBSUPC++)
|
||||
: PackageInstaller.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -40,18 +40,15 @@ class PackageInstaller : public BApplication {
|
||||
private:
|
||||
BFilePanel *fOpen;
|
||||
uint32 fWindowCount;
|
||||
BCatalog fAppCatalog;
|
||||
};
|
||||
|
||||
|
||||
PackageInstaller::PackageInstaller()
|
||||
: BApplication("application/x-vnd.Haiku-PackageInstaller"),
|
||||
fOpen(NULL),
|
||||
fWindowCount(0),
|
||||
fAppCatalog(NULL)
|
||||
fWindowCount(0)
|
||||
{
|
||||
fOpen = new BFilePanel(B_OPEN_PANEL);
|
||||
be_locale->GetAppCatalog(&fAppCatalog);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ Application Pairs :
|
||||
PairsView.cpp
|
||||
PairsTopButton.cpp
|
||||
|
||||
: be liblocale.so $(TARGET_LIBSTDC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) $(TARGET_LIBSTDC++)
|
||||
: Pairs.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -20,7 +20,6 @@ Pairs::Pairs()
|
||||
BApplication(kSignature),
|
||||
fWindow(NULL)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -24,8 +24,6 @@ public:
|
||||
|
||||
private:
|
||||
PairsWindow* fWindow;
|
||||
BCatalog fCatalog;
|
||||
|
||||
};
|
||||
|
||||
#endif // PAIRS_H
|
||||
|
||||
@@ -23,7 +23,7 @@ Application Pulse :
|
||||
PulseView.cpp
|
||||
PulseWindow.cpp
|
||||
|
||||
: be locale $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) $(TARGET_LIBSUPC++)
|
||||
: Pulse.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -37,8 +37,6 @@
|
||||
PulseApp::PulseApp(int argc, char **argv)
|
||||
: BApplication(APP_SIGNATURE)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
prefs = new Prefs();
|
||||
|
||||
int mini = false, deskbar = false, normal = false;
|
||||
|
||||
@@ -27,8 +27,6 @@ public:
|
||||
|
||||
private:
|
||||
void BuildPulse();
|
||||
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
extern bool LastEnabledCPU(int cpu);
|
||||
|
||||
@@ -178,12 +178,7 @@ void
|
||||
BootPromptWindow::_InitCatalog(bool saveSettings)
|
||||
{
|
||||
// Initilialize the Locale Kit
|
||||
// TODO: The below code is a work-around for not being able to
|
||||
// call GetAppCatalog() more than once.
|
||||
be_catalog = be_app_catalog = NULL;
|
||||
// NOTE: be_catalog and be_app_catalog will point fo &fCatalog!
|
||||
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
BCatalogStub::ForceReload();
|
||||
|
||||
// Generate a settings file
|
||||
// TODO: This should not be necessary.
|
||||
@@ -191,6 +186,7 @@ BootPromptWindow::_InitCatalog(bool saveSettings)
|
||||
if (!saveSettings)
|
||||
return;
|
||||
|
||||
/*
|
||||
BPath path;
|
||||
if (find_directory(B_USER_SETTINGS_DIRECTORY, &path) != B_OK
|
||||
|| path.Append("Locale settings") != B_OK) {
|
||||
@@ -204,7 +200,7 @@ BootPromptWindow::_InitCatalog(bool saveSettings)
|
||||
settings.Unflatten(&file);
|
||||
|
||||
BString language;
|
||||
if (fCatalog.GetLanguage(&language) == B_OK) {
|
||||
if (fCatalog->GetLanguage(&language) == B_OK) {
|
||||
settings.RemoveName("language");
|
||||
settings.AddString("language", language.String());
|
||||
}
|
||||
@@ -218,6 +214,7 @@ BootPromptWindow::_InitCatalog(bool saveSettings)
|
||||
|| settings.Flatten(&file) != B_OK) {
|
||||
fprintf(stderr, "Failed to write Local Kit settings!\n");
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -30,7 +30,6 @@ private:
|
||||
status_t _GetCurrentKeymapRef(entry_ref& ref) const;
|
||||
|
||||
private:
|
||||
BCatalog fCatalog;
|
||||
BTextView* fInfoTextView;
|
||||
BStringView* fLanguagesLabelView;
|
||||
BListView* fLanguagesListView;
|
||||
|
||||
@@ -9,7 +9,7 @@ Application ReadOnlyBootPrompt :
|
||||
BootPromptWindow.cpp
|
||||
Keymap.cpp
|
||||
KeymapListItem.cpp
|
||||
: be libshared.a $(TARGET_LIBSTDC++) liblocale.so
|
||||
: be libshared.a $(TARGET_LIBSTDC++) $(HAIKU_LOCALE_LIBS)
|
||||
: BootPrompt.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ Application Screenshot :
|
||||
ScreenshotWindow.cpp
|
||||
PreviewView.cpp
|
||||
Utility.cpp
|
||||
: be locale tracker translation $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) tracker translation $(TARGET_LIBSUPC++)
|
||||
: ScreenshotApp.rdef
|
||||
;
|
||||
|
||||
@@ -21,7 +21,7 @@ DoCatalogs Screenshot :
|
||||
Application screenshot :
|
||||
Screenshot.cpp
|
||||
Utility.cpp
|
||||
: be locale translation $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) translation $(TARGET_LIBSUPC++)
|
||||
: Screenshot.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -40,7 +40,6 @@ Screenshot::Screenshot()
|
||||
fUtility(new Utility()),
|
||||
fLaunchGui(true)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -29,7 +29,6 @@ private:
|
||||
int32 _GetImageType(const char* name) const;
|
||||
|
||||
Utility* fUtility;
|
||||
BCatalog fCatalog;
|
||||
|
||||
bool fLaunchGui;
|
||||
};
|
||||
|
||||
@@ -27,7 +27,6 @@ ScreenshotApp::ScreenshotApp()
|
||||
fSilent(false),
|
||||
fClipboard(false)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -26,7 +26,6 @@ public:
|
||||
void ReadyToRun();
|
||||
|
||||
private:
|
||||
BCatalog fCatalog;
|
||||
Utility* fUtility;
|
||||
bool fSilent;
|
||||
bool fClipboard;
|
||||
|
||||
@@ -18,7 +18,7 @@ Application ShowImage :
|
||||
ShowImageView.cpp
|
||||
ShowImageWindow.cpp
|
||||
: libshared.a
|
||||
be tracker translation liblocale.so $(TARGET_LIBSUPC++)
|
||||
be tracker translation $(HAIKU_LOCALE_LIBS) $(TARGET_LIBSUPC++)
|
||||
: ShowImage.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -38,8 +38,6 @@ ShowImageApp::ShowImageApp()
|
||||
:
|
||||
BApplication(kApplicationSignature)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
fPulseStarted = false;
|
||||
fOpenPanel = new BFilePanel(B_OPEN_PANEL);
|
||||
}
|
||||
|
||||
@@ -43,7 +43,6 @@ private:
|
||||
BFilePanel *fOpenPanel;
|
||||
bool fPulseStarted;
|
||||
ShowImageSettings fSettings;
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ Application SoundRecorder :
|
||||
UpDownButton.cpp
|
||||
VUView.cpp
|
||||
VolumeSlider.cpp
|
||||
: be locale media tracker $(TARGET_LIBSTDC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) media tracker $(TARGET_LIBSTDC++)
|
||||
: SoundRecorder.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -128,8 +128,6 @@ RecorderWindow::RecorderWindow() :
|
||||
|
||||
CalcSizes(MIN_WIDTH, MIN_HEIGHT);
|
||||
|
||||
be_locale->GetAppCatalog(&fAppCatalog);
|
||||
|
||||
SetTitle(B_TRANSLATE("SoundRecorder"));
|
||||
|
||||
fInitCheck = InitWindow();
|
||||
|
||||
@@ -169,7 +169,6 @@ static void NotifyPlayFile(void * cookie, BSoundPlayer::sound_player_notificatio
|
||||
|
||||
void RefsReceived(BMessage *msg);
|
||||
void CopyTarget(BMessage *msg);
|
||||
BCatalog fAppCatalog;
|
||||
};
|
||||
|
||||
#endif /* RECORDERWINDOW_H */
|
||||
|
||||
@@ -16,7 +16,8 @@ Application StyledEdit :
|
||||
StyledEditApp.cpp
|
||||
StyledEditView.cpp
|
||||
StyledEditWindow.cpp
|
||||
: be translation tracker libtextencoding.so liblocale.so $(TARGET_LIBSUPC++)
|
||||
: be translation tracker libtextencoding.so $(HAIKU_LOCALE_LIBS)
|
||||
$(TARGET_LIBSUPC++)
|
||||
: $(styled_edit_rsrc)
|
||||
;
|
||||
|
||||
|
||||
@@ -87,8 +87,6 @@ StyledEditApp::StyledEditApp()
|
||||
: BApplication(APP_SIGNATURE),
|
||||
fOpenPanel(NULL)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
fOpenPanel = new BFilePanel();
|
||||
BMenuBar* menuBar =
|
||||
dynamic_cast<BMenuBar*>(fOpenPanel->Window()->FindView("MenuBar"));
|
||||
|
||||
@@ -49,7 +49,6 @@ class StyledEditApp : public BApplication {
|
||||
int32 fWindowCount;
|
||||
int32 fNextUntitledWindow;
|
||||
bool fBadArguments;
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
extern StyledEditApp* styled_edit_app;
|
||||
|
||||
@@ -26,7 +26,7 @@ Application Terminal :
|
||||
TermWindow.cpp
|
||||
VTKeyTbl.c
|
||||
VTPrsTbl.c
|
||||
: be locale tracker textencoding $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) tracker textencoding $(TARGET_LIBSUPC++)
|
||||
: Terminal.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -61,8 +61,7 @@ TermApp::TermApp()
|
||||
fStartFullscreen(false),
|
||||
fWindowNumber(-1),
|
||||
fTermWindow(NULL),
|
||||
fArgs(NULL),
|
||||
fAppCatalog(NULL)
|
||||
fArgs(NULL)
|
||||
{
|
||||
const char *defaultArgs[2];
|
||||
defaultArgs[0] = kDefaultShell;
|
||||
@@ -76,8 +75,6 @@ TermApp::TermApp()
|
||||
defaultArgs[0] = passwdStruct.pw_shell;
|
||||
}
|
||||
|
||||
be_locale->GetAppCatalog(&fAppCatalog);
|
||||
|
||||
fArgs = new Arguments(2, defaultArgs);
|
||||
|
||||
fWindowTitle = B_TRANSLATE("Terminal");
|
||||
|
||||
@@ -77,7 +77,6 @@ class TermApp : public BApplication {
|
||||
BWindow* fTermWindow;
|
||||
BRect fTermFrame;
|
||||
Arguments *fArgs;
|
||||
BCatalog fAppCatalog;
|
||||
};
|
||||
|
||||
#endif // TERM_APP_H
|
||||
|
||||
@@ -127,14 +127,11 @@ GrepWindow::GrepWindow(BMessage* message)
|
||||
fChangesIterator(NULL),
|
||||
fChangesPulse(NULL),
|
||||
|
||||
fFilePanel(NULL),
|
||||
fAppCatalog(NULL)
|
||||
fFilePanel(NULL)
|
||||
{
|
||||
if (fModel == NULL)
|
||||
return;
|
||||
|
||||
be_locale->GetAppCatalog(&fAppCatalog);
|
||||
|
||||
entry_ref directory;
|
||||
_InitRefsReceived(&directory, message);
|
||||
|
||||
|
||||
@@ -145,7 +145,6 @@ private:
|
||||
BMessageRunner* fChangesPulse;
|
||||
|
||||
BFilePanel* fFilePanel;
|
||||
BCatalog fAppCatalog;
|
||||
};
|
||||
|
||||
#endif // GREP_WINDOW_H
|
||||
|
||||
@@ -24,7 +24,8 @@ Application TextSearch :
|
||||
|
||||
$(additionalBeOSSources)
|
||||
|
||||
: be locale tracker textencoding libshared.a $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) tracker textencoding libshared.a
|
||||
$(TARGET_LIBSUPC++)
|
||||
: TextSearch.rdef
|
||||
;
|
||||
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ Application TV :
|
||||
MainWin.cpp
|
||||
VideoNode.cpp
|
||||
VideoView.cpp
|
||||
: be locale media $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) media $(TARGET_LIBSUPC++)
|
||||
: tv.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -47,8 +47,6 @@ MainApp::MainApp()
|
||||
{
|
||||
InitPrefs();
|
||||
|
||||
be_locale->GetAppCatalog(&fAppCatalog);
|
||||
|
||||
gDeviceRoster = new DeviceRoster;
|
||||
|
||||
fMainWindow = NewWindow();
|
||||
|
||||
@@ -38,7 +38,6 @@ public:
|
||||
|
||||
private:
|
||||
BWindow * fMainWindow;
|
||||
BCatalog fAppCatalog;
|
||||
};
|
||||
|
||||
extern MainApp *gMainApp;
|
||||
|
||||
@@ -7,7 +7,7 @@ UsePrivateHeaders app interface ;
|
||||
|
||||
Application Workspaces :
|
||||
Workspaces.cpp
|
||||
: be locale $(TARGET_LIBSUPC++)
|
||||
: be $(HAIKU_LOCALE_LIBS) $(TARGET_LIBSUPC++)
|
||||
: Workspaces.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -149,7 +149,6 @@ class WorkspacesApp : public BApplication {
|
||||
|
||||
private:
|
||||
WorkspacesWindow* fWindow;
|
||||
BCatalog fAppCatalog;
|
||||
};
|
||||
|
||||
|
||||
@@ -809,7 +808,6 @@ WorkspacesWindow::SetAutoRaise(bool enable)
|
||||
WorkspacesApp::WorkspacesApp()
|
||||
: BApplication(kSignature)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fAppCatalog);
|
||||
fWindow = new WorkspacesWindow(new WorkspacesSettings());
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -129,7 +129,7 @@ StdBinCommands
|
||||
# commands that need libbe.so, libsupc++.so and liblocale.so
|
||||
StdBinCommands
|
||||
dstcheck.cpp
|
||||
: be $(TARGET_LIBSUPC++) liblocale.so : $(haiku-utils_rsrc) ;
|
||||
: be $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS) : $(haiku-utils_rsrc) ;
|
||||
|
||||
# Haiku-specific apps which need libbe.so
|
||||
if $(TARGET_PLATFORM) = haiku {
|
||||
|
||||
@@ -101,7 +101,6 @@ TimedAlert::GetLabel(BString &string)
|
||||
int
|
||||
main(int argc, char **argv)
|
||||
{
|
||||
BCatalog fCatalog;
|
||||
time_t t;
|
||||
struct tm tm;
|
||||
tzset();
|
||||
@@ -136,7 +135,6 @@ main(int argc, char **argv)
|
||||
|
||||
if (dst != tm.tm_isdst || argc > 1) {
|
||||
BApplication app("application/x-vnd.Haiku-cmd-dstconfig");
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
BString string;
|
||||
TimedAlert::GetLabel(string);
|
||||
|
||||
@@ -15,13 +15,6 @@
|
||||
#include <Roster.h>
|
||||
|
||||
|
||||
BCatalog* be_catalog = NULL;
|
||||
// catalog used by translation macros
|
||||
BCatalog* be_app_catalog = NULL;
|
||||
// app-catalog (useful for accessing app's catalog from inside an add-on,
|
||||
// since in an add-on, be_catalog will hold the add-on's catalog.
|
||||
|
||||
|
||||
//#pragma mark - BCatalog
|
||||
BCatalog::BCatalog()
|
||||
:
|
||||
@@ -39,8 +32,6 @@ BCatalog::BCatalog(const char *signature, const char *language,
|
||||
|
||||
BCatalog::~BCatalog()
|
||||
{
|
||||
if (be_catalog == this)
|
||||
be_app_catalog = be_catalog = NULL;
|
||||
be_locale_roster->UnloadCatalog(fCatalog);
|
||||
}
|
||||
|
||||
@@ -117,51 +108,6 @@ BCatalog::SetCatalog(const char* signature, uint32 fingerprint)
|
||||
}
|
||||
|
||||
|
||||
status_t
|
||||
BCatalog::GetAppCatalog(BCatalog* catalog)
|
||||
{
|
||||
app_info appInfo;
|
||||
if (!be_app || be_app->GetAppInfo(&appInfo) != B_OK)
|
||||
return B_ENTRY_NOT_FOUND;
|
||||
BString sig(appInfo.signature);
|
||||
|
||||
// drop supertype from mimetype (should be "application/"):
|
||||
int32 pos = sig.FindFirst('/');
|
||||
if (pos >= 0)
|
||||
sig.Remove(0, pos+1);
|
||||
|
||||
// try to fetch fingerprint from app-file (attribute):
|
||||
uint32 fingerprint = 0;
|
||||
BNode appNode(&appInfo.ref);
|
||||
appNode.ReadAttr(BLocaleRoster::kCatFingerprintAttr, B_UINT32_TYPE, 0,
|
||||
&fingerprint, sizeof(uint32));
|
||||
catalog->SetCatalog(sig.String(), fingerprint);
|
||||
// try to load catalog (with given fingerprint):
|
||||
|
||||
// load native embedded id-based catalog. If such a catalog exists,
|
||||
// we can fall back to native strings for id-based access, too.
|
||||
BCatalogAddOn *embeddedCatalog
|
||||
= be_locale_roster->LoadEmbeddedCatalog(&appInfo.ref);
|
||||
if (embeddedCatalog) {
|
||||
if (!catalog->fCatalog)
|
||||
// embedded catalog is the only catalog that was found:
|
||||
catalog->fCatalog = embeddedCatalog;
|
||||
else {
|
||||
// append embedded catalog to list of loaded catalogs:
|
||||
BCatalogAddOn *currCat = catalog->fCatalog;
|
||||
while (currCat->fNext)
|
||||
currCat = currCat->fNext;
|
||||
currCat->fNext = embeddedCatalog;
|
||||
}
|
||||
}
|
||||
|
||||
// make app-catalog the current catalog for translation-macros:
|
||||
be_app_catalog = be_catalog = catalog;
|
||||
|
||||
return catalog->InitCheck();
|
||||
}
|
||||
|
||||
|
||||
//#pragma mark - BCatalogAddOn
|
||||
BCatalogAddOn::BCatalogAddOn(const char *signature, const char *language,
|
||||
uint32 fingerprint)
|
||||
|
||||
@@ -8,9 +8,6 @@
|
||||
#define __CATALOG_STUB_H__
|
||||
|
||||
|
||||
#define B_TRANSLATE_USE_NEW_MACROS
|
||||
|
||||
|
||||
#include <Catalog.h>
|
||||
#include <Locale.h>
|
||||
#include <LocaleRoster.h>
|
||||
@@ -26,4 +23,11 @@ BCatalogStub::GetCatalog()
|
||||
}
|
||||
|
||||
|
||||
/* static */ void
|
||||
BCatalogStub::ForceReload()
|
||||
{
|
||||
sCatalogInitOnce = false;
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -43,15 +43,3 @@ BLocale::GetString(uint32 id)
|
||||
|
||||
return fCountry->GetString(id);
|
||||
}
|
||||
|
||||
status_t
|
||||
BLocale::GetAppCatalog(BCatalog *catalog)
|
||||
{
|
||||
if (!catalog)
|
||||
return B_BAD_VALUE;
|
||||
// TODO: This is not so nice, and I don't know why it is here, but how
|
||||
// is it envisioned to switch languages on the fly?
|
||||
if (be_catalog)
|
||||
debugger( "GetAppCatalog() has been called while be_catalog != NULL");
|
||||
return BCatalog::GetAppCatalog(catalog);
|
||||
}
|
||||
|
||||
@@ -425,11 +425,6 @@ BLocaleRoster::GetCatalog(BCatalog* catalog, vint32* catalogInitStatus)
|
||||
// This function is used in the translation macros, so it can't return a
|
||||
// status_t. Maybe it could throw exceptions ?
|
||||
|
||||
if (catalog == NULL) {
|
||||
log_team(LOG_ERR, "GetCatalog called with a NULL catalog!");
|
||||
return catalog;
|
||||
}
|
||||
|
||||
if (*catalogInitStatus == true) {
|
||||
// Catalog already loaded - nothing else to do
|
||||
return catalog;
|
||||
@@ -456,11 +451,16 @@ BLocaleRoster::GetCatalog(BCatalog* catalog, vint32* catalogInitStatus)
|
||||
BFile objectFile(info.name, B_READ_ONLY);
|
||||
BAppFileInfo objectInfo(&objectFile);
|
||||
char objectSignature[B_MIME_TYPE_LENGTH];
|
||||
objectInfo.GetSignature(objectSignature);
|
||||
if (objectInfo.GetSignature(objectSignature) != B_OK) {
|
||||
log_team(LOG_ERR, "File %s has no mimesignature, so it can't use"
|
||||
"localization.", info.name);
|
||||
return catalog;
|
||||
}
|
||||
|
||||
// drop supertype from mimetype (should be "application/"):
|
||||
char* stripSignature = objectSignature;
|
||||
while(*(stripSignature++)!='/');
|
||||
while(*stripSignature != '/')
|
||||
stripSignature ++;
|
||||
|
||||
log_team(LOG_DEBUG,
|
||||
"Image %s (address %x) requested catalog with mimetype %s",
|
||||
|
||||
@@ -16,10 +16,6 @@
|
||||
APRApplication::APRApplication(void)
|
||||
: BApplication(APPEARANCE_APP_SIGNATURE)
|
||||
{
|
||||
// Do this now because we need to call BWindow constructor with a translated
|
||||
// string.
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
|
||||
fWindow = new APRWindow(BRect(100, 100, 550, 420));
|
||||
fWindow->Show();
|
||||
}
|
||||
|
||||
@@ -21,7 +21,6 @@ public:
|
||||
private:
|
||||
|
||||
APRWindow *fWindow;
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -22,7 +22,7 @@ Preference Appearance :
|
||||
#FontMenu.cpp
|
||||
#MenuView.cpp
|
||||
|
||||
: be $(TARGET_LIBSTDC++) liblocale.so
|
||||
: be $(TARGET_LIBSTDC++) $(HAIKU_LOCALE_LIBS)
|
||||
: Appearance.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -48,7 +48,6 @@ public:
|
||||
|
||||
private:
|
||||
BackgroundsWindow* fWindow;
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
|
||||
@@ -60,7 +59,6 @@ BackgroundsApplication::BackgroundsApplication()
|
||||
BApplication(kSignature),
|
||||
fWindow(NULL)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
fWindow = new BackgroundsWindow();
|
||||
fWindow->Show();
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ Preference Backgrounds :
|
||||
Backgrounds.cpp
|
||||
BackgroundsView.cpp
|
||||
ImageFilePanel.cpp
|
||||
: be tracker translation $(TARGET_LIBSUPC++) liblocale.so
|
||||
: be tracker translation $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
: Backgrounds.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ Preference CPUFrequency :
|
||||
DriverInterface.cpp
|
||||
main.cpp
|
||||
StatusView.cpp
|
||||
: be $(TARGET_LIBSUPC++) liblocale.so
|
||||
: be $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
: cpufrequency.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -24,9 +24,6 @@ main(int argc, char* argv[])
|
||||
{
|
||||
BApplication *app = new BApplication(kPrefSignature);
|
||||
|
||||
BCatalog cat;
|
||||
be_locale->GetAppCatalog(&cat);
|
||||
|
||||
PreferencesWindow<freq_preferences> *window;
|
||||
window = new PreferencesWindow<freq_preferences>(
|
||||
B_TRANSLATE("CPU Frequency"),
|
||||
|
||||
@@ -77,8 +77,6 @@ class FileTypes : public BApplication {
|
||||
BWindow *fApplicationTypesWindow;
|
||||
uint32 fWindowCount;
|
||||
uint32 fTypeWindowCount;
|
||||
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
|
||||
@@ -172,7 +170,6 @@ FileTypes::FileTypes()
|
||||
fWindowCount(0),
|
||||
fTypeWindowCount(0)
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
fFilePanel = new BFilePanel(B_OPEN_PANEL, NULL, NULL,
|
||||
B_FILE_NODE | B_DIRECTORY_NODE, false);
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ Preference FileTypes :
|
||||
|
||||
PreferredAppMenu.cpp
|
||||
StringView.cpp
|
||||
: be tracker $(TARGET_LIBSUPC++) liblocale.so
|
||||
: be tracker $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
: FileTypes.rdef FileTypes.icons.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ Preference Fonts :
|
||||
FontView.cpp
|
||||
main.cpp
|
||||
MainWindow.cpp
|
||||
: be $(TARGET_LIBSUPC++) liblocale.so
|
||||
: be $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
: Fonts.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -25,16 +25,12 @@ class FontsApp : public BApplication {
|
||||
FontsApp();
|
||||
|
||||
virtual void AboutRequested();
|
||||
|
||||
private:
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
|
||||
FontsApp::FontsApp()
|
||||
: BApplication("application/x-vnd.Haiku-Fonts")
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
MainWindow *window = new MainWindow();
|
||||
window->Show();
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ Preference Keyboard :
|
||||
KeyboardSettings.cpp
|
||||
KeyboardView.cpp
|
||||
KeyboardWindow.cpp
|
||||
: translation be $(TARGET_LIBSUPC++) liblocale.so
|
||||
: translation be $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
: Keyboard.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -21,7 +21,6 @@
|
||||
KeyboardApplication::KeyboardApplication()
|
||||
: BApplication("application/x-vnd.Haiku-Keyboard")
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
new KeyboardWindow();
|
||||
}
|
||||
|
||||
|
||||
@@ -21,9 +21,6 @@ public:
|
||||
|
||||
void MessageReceived(BMessage* message);
|
||||
void AboutRequested(void);
|
||||
|
||||
private:
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -12,7 +12,7 @@ Preference Keymap :
|
||||
KeymapListItem.cpp
|
||||
KeymapWindow.cpp
|
||||
|
||||
: be tracker liblocale.so libshared.a $(TARGET_LIBSTDC++)
|
||||
: be tracker $(HAIKU_LOCALE_LIBS) libshared.a $(TARGET_LIBSTDC++)
|
||||
: Keymap.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -13,7 +13,6 @@
|
||||
KeymapApplication::KeymapApplication()
|
||||
: BApplication("application/x-vnd.Haiku-Keymap")
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
// create the window
|
||||
fWindow = new KeymapWindow();
|
||||
fWindow->Show();
|
||||
|
||||
@@ -28,7 +28,6 @@ class KeymapApplication : public BApplication {
|
||||
|
||||
private:
|
||||
KeymapWindow* fWindow;
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
#endif // KEYMAP_APPLICATION_H
|
||||
|
||||
@@ -16,7 +16,6 @@
|
||||
|
||||
#include <new>
|
||||
|
||||
#define B_TRANSLATE_USE_NEW_MACROS
|
||||
#include <Bitmap.h>
|
||||
#include <Country.h>
|
||||
#include <Catalog.h>
|
||||
|
||||
@@ -4,9 +4,6 @@
|
||||
*/
|
||||
|
||||
|
||||
#define B_TRANSLATE_USE_NEW_MACROS
|
||||
|
||||
|
||||
#include "Locale.h"
|
||||
#include "LocaleWindow.h"
|
||||
|
||||
|
||||
@@ -5,9 +5,6 @@
|
||||
*/
|
||||
|
||||
|
||||
#define B_TRANSLATE_USE_NEW_MACROS
|
||||
|
||||
|
||||
#include "Locale.h"
|
||||
#include "LocaleWindow.h"
|
||||
#include "LanguageListView.h"
|
||||
|
||||
@@ -4,9 +4,6 @@
|
||||
*/
|
||||
|
||||
|
||||
#define B_TRANSLATE_USE_NEW_MACROS
|
||||
|
||||
|
||||
#include "TimeFormatSettingsView.h"
|
||||
|
||||
#include <Alert.h>
|
||||
|
||||
@@ -46,7 +46,7 @@ if $(HAIKU_OPENSSL_ENABLED) {
|
||||
Preference E-mail
|
||||
: $(sources)
|
||||
: be libmail.so $(HAIKU_NETWORK_LIBS) $(TARGET_NETAPI_LIB)
|
||||
$(HAIKU_OPENSSL_LIBS) $(TARGET_LIBSUPC++) liblocale.so
|
||||
$(HAIKU_OPENSSL_LIBS) $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS)
|
||||
: e-mail.rdef
|
||||
;
|
||||
|
||||
|
||||
@@ -17,15 +17,12 @@ class MailConfigApp : public BApplication {
|
||||
public:
|
||||
MailConfigApp();
|
||||
~MailConfigApp();
|
||||
private:
|
||||
BCatalog fCatalog;
|
||||
};
|
||||
|
||||
|
||||
MailConfigApp::MailConfigApp()
|
||||
: BApplication("application/x-vnd.Haiku-Mail")
|
||||
{
|
||||
be_locale->GetAppCatalog(&fCatalog);
|
||||
(new ConfigWindow())->Show();
|
||||
}
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ Preference Media :
|
||||
MediaViews.cpp
|
||||
MediaListItem.cpp
|
||||
MediaAlert.cpp
|
||||
: media be liblocale.so $(TARGET_LIBSUPC++)
|
||||
: media be $(HAIKU_LOCALE_LIBS) $(TARGET_LIBSUPC++)
|
||||
: media.rdef
|
||||
;
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user