diff options
author | Timothy Pearson <[email protected]> | 2013-02-01 08:14:08 -0600 |
---|---|---|
committer | Timothy Pearson <[email protected]> | 2013-02-01 08:14:08 -0600 |
commit | 98f4a055baf6eb7ea5c3d69d6a3f2162b491e253 (patch) | |
tree | f56598fd630d341dd40899da38b7fd4b3931770a /kcontrol/locale | |
parent | 93943a849d1abc2003ceefe294dc419b9927f7d0 (diff) | |
download | tdebase-98f4a055baf6eb7ea5c3d69d6a3f2162b491e253.tar.gz tdebase-98f4a055baf6eb7ea5c3d69d6a3f2162b491e253.zip |
Rename KLocale to enhance compatibility with KDE4
Diffstat (limited to 'kcontrol/locale')
-rw-r--r-- | kcontrol/locale/kcmlocale.cpp | 42 | ||||
-rw-r--r-- | kcontrol/locale/kcmlocale.h | 10 | ||||
-rw-r--r-- | kcontrol/locale/klocalesample.cpp | 8 | ||||
-rw-r--r-- | kcontrol/locale/klocalesample.h | 10 | ||||
-rw-r--r-- | kcontrol/locale/localemon.cpp | 34 | ||||
-rw-r--r-- | kcontrol/locale/localemon.h | 10 | ||||
-rw-r--r-- | kcontrol/locale/localenum.cpp | 20 | ||||
-rw-r--r-- | kcontrol/locale/localenum.h | 10 | ||||
-rw-r--r-- | kcontrol/locale/localeother.cpp | 18 | ||||
-rw-r--r-- | kcontrol/locale/localeother.h | 10 | ||||
-rw-r--r-- | kcontrol/locale/localetime.cpp | 38 | ||||
-rw-r--r-- | kcontrol/locale/localetime.h | 10 | ||||
-rw-r--r-- | kcontrol/locale/main.cpp | 8 | ||||
-rw-r--r-- | kcontrol/locale/toplevel.cpp | 38 | ||||
-rw-r--r-- | kcontrol/locale/toplevel.h | 38 |
15 files changed, 152 insertions, 152 deletions
diff --git a/kcontrol/locale/kcmlocale.cpp b/kcontrol/locale/kcmlocale.cpp index c2f50eab7..288946faf 100644 --- a/kcontrol/locale/kcmlocale.cpp +++ b/kcontrol/locale/kcmlocale.cpp @@ -43,7 +43,7 @@ #include "kcmlocale.moc" #include "toplevel.h" -KLocaleConfig::KLocaleConfig(KLocale *locale, +TDELocaleConfig::TDELocaleConfig(TDELocale *locale, TQWidget *parent, const char *name) : TQWidget (parent, name), m_locale(locale) @@ -120,7 +120,7 @@ KLocaleConfig::KLocaleConfig(KLocale *locale, } -void KLocaleConfig::slotInstallLanguage() +void TDELocaleConfig::slotInstallLanguage() { TDEProcess *proc = new TDEProcess; @@ -132,7 +132,7 @@ void KLocaleConfig::slotInstallLanguage() proc->start(); } -void KLocaleConfig::slotUninstallLanguage() +void TDELocaleConfig::slotUninstallLanguage() { TDEProcess *proc = new TDEProcess; @@ -144,7 +144,7 @@ void KLocaleConfig::slotUninstallLanguage() proc->start(); } -void KLocaleConfig::slotSelectLanguage() +void TDELocaleConfig::slotSelectLanguage() { TDEProcess *proc = new TDEProcess; @@ -156,14 +156,14 @@ void KLocaleConfig::slotSelectLanguage() proc->start(); } -void KLocaleConfig::slotLanguageSelectorExited(TDEProcess *) +void TDELocaleConfig::slotLanguageSelectorExited(TDEProcess *) { //reload here loadLanguageList(); setEnabled(true); } -void KLocaleConfig::slotAddLanguage(const TQString & code) +void TDELocaleConfig::slotAddLanguage(const TQString & code) { TQStringList languageList = m_locale->languageList(); @@ -190,7 +190,7 @@ void KLocaleConfig::slotAddLanguage(const TQString & code) emit languageChanged(); } -void KLocaleConfig::slotRemoveLanguage() +void TDELocaleConfig::slotRemoveLanguage() { TQStringList languageList = m_locale->languageList(); int pos = m_languages->currentItem(); @@ -209,7 +209,7 @@ void KLocaleConfig::slotRemoveLanguage() } } -void KLocaleConfig::slotLanguageUp() +void TDELocaleConfig::slotLanguageUp() { TQStringList languageList = m_locale->languageList(); int pos = m_languages->currentItem(); @@ -231,7 +231,7 @@ void KLocaleConfig::slotLanguageUp() } } -void KLocaleConfig::slotLanguageDown() +void TDELocaleConfig::slotLanguageDown() { TQStringList languageList = m_locale->languageList(); int pos = m_languages->currentItem(); @@ -253,10 +253,10 @@ void KLocaleConfig::slotLanguageDown() } } -void KLocaleConfig::loadLanguageList() +void TDELocaleConfig::loadLanguageList() { // temperary use of our locale as the global locale - KLocale *lsave = TDEGlobal::_locale; + TDELocale *lsave = TDEGlobal::_locale; TDEGlobal::_locale = m_locale; // clear the list @@ -316,10 +316,10 @@ void KLocaleConfig::loadLanguageList() TDEGlobal::_locale = lsave; } -void KLocaleConfig::loadCountryList() +void TDELocaleConfig::loadCountryList() { // temperary use of our locale as the global locale - KLocale *lsave = TDEGlobal::_locale; + TDELocale *lsave = TDEGlobal::_locale; TDEGlobal::_locale = m_locale; TQString sub = TQString::fromLatin1("l10n/"); @@ -391,11 +391,11 @@ void KLocaleConfig::loadCountryList() TDEGlobal::_locale = lsave; } -void KLocaleConfig::readLocale(const TQString &path, TQString &name, +void TDELocaleConfig::readLocale(const TQString &path, TQString &name, const TQString &sub) const { // temperary use of our locale as the global locale - KLocale *lsave = TDEGlobal::_locale; + TDELocale *lsave = TDEGlobal::_locale; TDEGlobal::_locale = m_locale; // read the name @@ -411,7 +411,7 @@ void KLocaleConfig::readLocale(const TQString &path, TQString &name, TDEGlobal::_locale = lsave; } -void KLocaleConfig::save() +void TDELocaleConfig::save() { TDEConfigBase *config = TDEGlobal::config(); @@ -427,7 +427,7 @@ void KLocaleConfig::save() config->sync(); } -void KLocaleConfig::slotCheckButtons() +void TDELocaleConfig::slotCheckButtons() { m_removeLanguage->setEnabled( m_languages->currentItem() != -1 ); m_upButton->setEnabled( m_languages->currentItem() > 0 ); @@ -435,7 +435,7 @@ void KLocaleConfig::slotCheckButtons() m_languages->currentItem() < (signed)(m_languages->count() - 1) ); } -void KLocaleConfig::slotLocaleChanged() +void TDELocaleConfig::slotLocaleChanged() { loadLanguageList(); loadCountryList(); @@ -457,7 +457,7 @@ void KLocaleConfig::slotLocaleChanged() m_comboCountry->setCurrentItem( m_locale->country() ); } -void KLocaleConfig::slotTranslate() +void TDELocaleConfig::slotTranslate() { kdDebug() << "slotTranslate()" << endl; @@ -499,7 +499,7 @@ void KLocaleConfig::slotTranslate() TQWhatsThis::add( m_removeLanguage, str ); } -TQStringList KLocaleConfig::languageList() const +TQStringList TDELocaleConfig::languageList() const { TQString fileName = locate("locale", TQString::fromLatin1("l10n/%1/entry.desktop") @@ -511,7 +511,7 @@ TQStringList KLocaleConfig::languageList() const return entry.readListEntry("Languages"); } -void KLocaleConfig::changedCountry(const TQString & code) +void TDELocaleConfig::changedCountry(const TQString & code) { m_locale->setCountry(code); diff --git a/kcontrol/locale/kcmlocale.h b/kcontrol/locale/kcmlocale.h index 3a2992826..c8b126919 100644 --- a/kcontrol/locale/kcmlocale.h +++ b/kcontrol/locale/kcmlocale.h @@ -31,19 +31,19 @@ class KAddButton; class KLanguageButton; -class KLocale; -class KLocaleSample; +class TDELocale; +class TDELocaleSample; class TQLabel; class TQListBox; class TQPushButton; -class KLocaleConfig : public TQWidget +class TDELocaleConfig : public TQWidget { Q_OBJECT public: - KLocaleConfig( KLocale *_locale, + TDELocaleConfig( TDELocale *_locale, TQWidget *parent = 0, const char *name = 0); void save(); @@ -84,7 +84,7 @@ private slots: private: TQStringList languageList() const; - KLocale *m_locale; + TDELocale *m_locale; KLanguageButton *m_comboCountry; diff --git a/kcontrol/locale/klocalesample.cpp b/kcontrol/locale/klocalesample.cpp index 7af914ae9..91c978a6d 100644 --- a/kcontrol/locale/klocalesample.cpp +++ b/kcontrol/locale/klocalesample.cpp @@ -36,7 +36,7 @@ #include "klocalesample.h" #include "klocalesample.moc" -KLocaleSample::KLocaleSample(KLocale *locale, +TDELocaleSample::TDELocaleSample(TDELocale *locale, TQWidget *parent, const char*name) : TQWidget(parent, name), m_locale(locale) @@ -82,11 +82,11 @@ KLocaleSample::KLocaleSample(KLocale *locale, timer->start(1000); } -KLocaleSample::~KLocaleSample() +TDELocaleSample::~TDELocaleSample() { } -void KLocaleSample::slotUpdateTime() +void TDELocaleSample::slotUpdateTime() { TQDateTime dt = TQDateTime::currentDateTime(); @@ -95,7 +95,7 @@ void KLocaleSample::slotUpdateTime() m_timeSample->setText(m_locale->formatTime(TQT_TQTIME_OBJECT(dt.time()), true)); } -void KLocaleSample::slotLocaleChanged() +void TDELocaleSample::slotLocaleChanged() { m_numberSample->setText(m_locale->formatNumber(1234567.89) + TQString::fromLatin1(" / ") + diff --git a/kcontrol/locale/klocalesample.h b/kcontrol/locale/klocalesample.h index 1b8fb94e0..f4233c3cf 100644 --- a/kcontrol/locale/klocalesample.h +++ b/kcontrol/locale/klocalesample.h @@ -30,15 +30,15 @@ class TQLabel; class TQResizeEvent; -class KLocale; +class TDELocale; -class KLocaleSample : public TQWidget +class TDELocaleSample : public TQWidget { Q_OBJECT public: - KLocaleSample(KLocale *_locale, + TDELocaleSample(TDELocale *_locale, TQWidget *parent = 0, const char*name = 0); - virtual ~KLocaleSample(); + virtual ~TDELocaleSample(); public slots: void slotLocaleChanged(); @@ -47,7 +47,7 @@ protected slots: void slotUpdateTime(); private: - KLocale *m_locale; + TDELocale *m_locale; TQLabel *m_numberSample, *m_labNumber; TQLabel *m_moneySample, *m_labMoney; TQLabel *m_timeSample, *m_labTime; diff --git a/kcontrol/locale/localemon.cpp b/kcontrol/locale/localemon.cpp index 795524813..609e0c9ad 100644 --- a/kcontrol/locale/localemon.cpp +++ b/kcontrol/locale/localemon.cpp @@ -41,7 +41,7 @@ #include "localemon.h" #include "localemon.moc" -KLocaleConfigMoney::KLocaleConfigMoney(KLocale *locale, +TDELocaleConfigMoney::TDELocaleConfigMoney(TDELocale *locale, TQWidget *parent, const char*name) : TQWidget(parent, name), m_locale(locale) @@ -121,11 +121,11 @@ KLocaleConfigMoney::KLocaleConfigMoney(KLocale *locale, adjustSize(); } -KLocaleConfigMoney::~KLocaleConfigMoney() +TDELocaleConfigMoney::~TDELocaleConfigMoney() { } -void KLocaleConfigMoney::save() +void TDELocaleConfigMoney::save() { TDEConfig *config = TDEGlobal::config(); TDEConfigGroupSaver saver(config, "Locale"); @@ -178,7 +178,7 @@ void KLocaleConfigMoney::save() m_locale->negativePrefixCurrencySymbol(), true, true); i = ent.readNumEntry("PositiveMonetarySignPosition", - (int)KLocale::BeforeQuantityMoney); + (int)TDELocale::BeforeQuantityMoney); config->deleteEntry("PositiveMonetarySignPosition", false, true); if (i != m_locale->positiveMonetarySignPosition()) config->writeEntry("PositiveMonetarySignPosition", @@ -186,7 +186,7 @@ void KLocaleConfigMoney::save() true, true); i = ent.readNumEntry("NegativeMonetarySignPosition", - (int)KLocale::ParensAround); + (int)TDELocale::ParensAround); config->deleteEntry("NegativeMonetarySignPosition", false, true); if (i != m_locale->negativeMonetarySignPosition()) config->writeEntry("NegativeMonetarySignPosition", @@ -196,7 +196,7 @@ void KLocaleConfigMoney::save() config->sync(); } -void KLocaleConfigMoney::slotLocaleChanged() +void TDELocaleConfigMoney::slotLocaleChanged() { m_edMonCurSym->setText( m_locale->currencySymbol() ); m_edMonDecSym->setText( m_locale->monetaryDecimalSymbol() ); @@ -209,55 +209,55 @@ void KLocaleConfigMoney::slotLocaleChanged() m_cmbMonNegMonSignPos->setCurrentItem( m_locale->negativeMonetarySignPosition() ); } -void KLocaleConfigMoney::slotMonCurSymChanged(const TQString &t) +void TDELocaleConfigMoney::slotMonCurSymChanged(const TQString &t) { m_locale->setCurrencySymbol(t); emit localeChanged(); } -void KLocaleConfigMoney::slotMonDecSymChanged(const TQString &t) +void TDELocaleConfigMoney::slotMonDecSymChanged(const TQString &t) { m_locale->setMonetaryDecimalSymbol(t); emit localeChanged(); } -void KLocaleConfigMoney::slotMonThoSepChanged(const TQString &t) +void TDELocaleConfigMoney::slotMonThoSepChanged(const TQString &t) { m_locale->setMonetaryThousandsSeparator(t); emit localeChanged(); } -void KLocaleConfigMoney::slotMonFraDigChanged(int value) +void TDELocaleConfigMoney::slotMonFraDigChanged(int value) { m_locale->setFracDigits(value); emit localeChanged(); } -void KLocaleConfigMoney::slotMonPosPreCurSymChanged() +void TDELocaleConfigMoney::slotMonPosPreCurSymChanged() { m_locale->setPositivePrefixCurrencySymbol(m_chMonPosPreCurSym->isChecked()); emit localeChanged(); } -void KLocaleConfigMoney::slotMonNegPreCurSymChanged() +void TDELocaleConfigMoney::slotMonNegPreCurSymChanged() { m_locale->setNegativePrefixCurrencySymbol(m_chMonNegPreCurSym->isChecked()); emit localeChanged(); } -void KLocaleConfigMoney::slotMonPosMonSignPosChanged(int i) +void TDELocaleConfigMoney::slotMonPosMonSignPosChanged(int i) { - m_locale->setPositiveMonetarySignPosition((KLocale::SignPosition)i); + m_locale->setPositiveMonetarySignPosition((TDELocale::SignPosition)i); emit localeChanged(); } -void KLocaleConfigMoney::slotMonNegMonSignPosChanged(int i) +void TDELocaleConfigMoney::slotMonNegMonSignPosChanged(int i) { - m_locale->setNegativeMonetarySignPosition((KLocale::SignPosition)i); + m_locale->setNegativeMonetarySignPosition((TDELocale::SignPosition)i); emit localeChanged(); } -void KLocaleConfigMoney::slotTranslate() +void TDELocaleConfigMoney::slotTranslate() { TQObjectList list; list.append(TQT_TQOBJECT(m_cmbMonPosMonSignPos)); diff --git a/kcontrol/locale/localemon.h b/kcontrol/locale/localemon.h index 412236efe..d84db0e37 100644 --- a/kcontrol/locale/localemon.h +++ b/kcontrol/locale/localemon.h @@ -32,16 +32,16 @@ class TQComboBox; class TQLineEdit; class KIntNumInput; -class KLocale; +class TDELocale; class KLanguageCombo; -class KLocaleConfigMoney : public TQWidget +class TDELocaleConfigMoney : public TQWidget { Q_OBJECT public: - KLocaleConfigMoney(KLocale *locale, TQWidget *parent = 0, const char *name = 0); - virtual ~KLocaleConfigMoney(); + TDELocaleConfigMoney(TDELocale *locale, TQWidget *parent = 0, const char *name = 0); + virtual ~TDELocaleConfigMoney(); void save(); @@ -70,7 +70,7 @@ private slots: void slotMonNegMonSignPosChanged(int i); private: - KLocale *m_locale; + TDELocale *m_locale; // Money TQLabel *m_labMonCurSym; diff --git a/kcontrol/locale/localenum.cpp b/kcontrol/locale/localenum.cpp index 4d291f969..ca523d2e9 100644 --- a/kcontrol/locale/localenum.cpp +++ b/kcontrol/locale/localenum.cpp @@ -35,7 +35,7 @@ #include "localenum.h" #include "localenum.moc" -KLocaleConfigNumber::KLocaleConfigNumber(KLocale *locale, +TDELocaleConfigNumber::TDELocaleConfigNumber(TDELocale *locale, TQWidget *parent, const char*name) : TQWidget(parent, name), m_locale(locale) @@ -75,14 +75,14 @@ KLocaleConfigNumber::KLocaleConfigNumber(KLocale *locale, TQT_SLOT(slotLocaleChanged())); } -KLocaleConfigNumber::~KLocaleConfigNumber() +TDELocaleConfigNumber::~TDELocaleConfigNumber() { } -void KLocaleConfigNumber::save() +void TDELocaleConfigNumber::save() { // temperary use of our locale as the global locale - KLocale *lsave = TDEGlobal::_locale; + TDELocale *lsave = TDEGlobal::_locale; TDEGlobal::_locale = m_locale; TDEConfig *config = TDEGlobal::config(); @@ -125,7 +125,7 @@ void KLocaleConfigNumber::save() TDEGlobal::_locale = lsave; } -void KLocaleConfigNumber::slotLocaleChanged() +void TDELocaleConfigNumber::slotLocaleChanged() { // #### load all settings here m_edDecSym->setText( m_locale->decimalSymbol() ); @@ -134,31 +134,31 @@ void KLocaleConfigNumber::slotLocaleChanged() m_edMonNegSign->setText( m_locale->negativeSign() ); } -void KLocaleConfigNumber::slotDecSymChanged(const TQString &t) +void TDELocaleConfigNumber::slotDecSymChanged(const TQString &t) { m_locale->setDecimalSymbol(t); emit localeChanged(); } -void KLocaleConfigNumber::slotThoSepChanged(const TQString &t) +void TDELocaleConfigNumber::slotThoSepChanged(const TQString &t) { m_locale->setThousandsSeparator(t); emit localeChanged(); } -void KLocaleConfigNumber::slotMonPosSignChanged(const TQString &t) +void TDELocaleConfigNumber::slotMonPosSignChanged(const TQString &t) { m_locale->setPositiveSign(t); emit localeChanged(); } -void KLocaleConfigNumber::slotMonNegSignChanged(const TQString &t) +void TDELocaleConfigNumber::slotMonNegSignChanged(const TQString &t) { m_locale->setNegativeSign(t); emit localeChanged(); } -void KLocaleConfigNumber::slotTranslate() +void TDELocaleConfigNumber::slotTranslate() { TQString str; diff --git a/kcontrol/locale/localenum.h b/kcontrol/locale/localenum.h index 5c2702e7d..1e19b687f 100644 --- a/kcontrol/locale/localenum.h +++ b/kcontrol/locale/localenum.h @@ -31,17 +31,17 @@ class TQCheckBox; class TQComboBox; class TQLineEdit; -class KLocale; +class TDELocale; class KLanguageCombo; -class KLocaleConfigNumber : public TQWidget +class TDELocaleConfigNumber : public TQWidget { Q_OBJECT public: - KLocaleConfigNumber( KLocale *_locale, + TDELocaleConfigNumber( TDELocale *_locale, TQWidget *parent=0, const char *name=0); - virtual ~KLocaleConfigNumber( ); + virtual ~TDELocaleConfigNumber( ); void save(); @@ -66,7 +66,7 @@ private slots: void slotThoSepChanged(const TQString &t); private: - KLocale *m_locale; + TDELocale *m_locale; // Numbers TQLabel *m_labDecSym; diff --git a/kcontrol/locale/localeother.cpp b/kcontrol/locale/localeother.cpp index 2231864ef..66b95e50c 100644 --- a/kcontrol/locale/localeother.cpp +++ b/kcontrol/locale/localeother.cpp @@ -35,7 +35,7 @@ #include "localeother.moc" -KLocaleConfigOther::KLocaleConfigOther(KLocale *locale, +TDELocaleConfigOther::TDELocaleConfigOther(TDELocale *locale, TQWidget *parent, const char*name) : TQWidget(parent, name), m_locale(locale) @@ -70,11 +70,11 @@ KLocaleConfigOther::KLocaleConfigOther(KLocale *locale, adjustSize(); } -KLocaleConfigOther::~KLocaleConfigOther() +TDELocaleConfigOther::~TDELocaleConfigOther() { } -void KLocaleConfigOther::save() +void TDELocaleConfigOther::save() { TDEConfig *config = TDEGlobal::config(); TDEConfigGroupSaver saver(config, "Locale"); @@ -92,7 +92,7 @@ void KLocaleConfigOther::save() config->writeEntry("PageSize", m_locale->pageSize(), true, true); - i = ent.readNumEntry("MeasureSystem", (int)KLocale::Metric); + i = ent.readNumEntry("MeasureSystem", (int)TDELocale::Metric); config->deleteEntry("MeasureSystem", false, true); if (i != m_locale->measureSystem()) config->writeEntry("MeasureSystem", @@ -101,7 +101,7 @@ void KLocaleConfigOther::save() config->sync(); } -void KLocaleConfigOther::slotLocaleChanged() +void TDELocaleConfigOther::slotLocaleChanged() { m_combMeasureSystem->setCurrentItem(m_locale->measureSystem()); @@ -113,7 +113,7 @@ void KLocaleConfigOther::slotLocaleChanged() m_combPageSize->setCurrentItem(i); } -void KLocaleConfigOther::slotTranslate() +void TDELocaleConfigOther::slotTranslate() { m_combMeasureSystem->changeItem( m_locale->translate("The Metric System", "Metric"), 0 ); @@ -124,7 +124,7 @@ void KLocaleConfigOther::slotTranslate() m_combPageSize->changeItem( m_locale->translate("US Letter"), 1 ); } -void KLocaleConfigOther::slotPageSizeChanged(int i) +void TDELocaleConfigOther::slotPageSizeChanged(int i) { TQPrinter::PageSize pageSize = TQPrinter::A4; @@ -135,8 +135,8 @@ void KLocaleConfigOther::slotPageSizeChanged(int i) emit localeChanged(); } -void KLocaleConfigOther::slotMeasureSystemChanged(int i) +void TDELocaleConfigOther::slotMeasureSystemChanged(int i) { - m_locale->setMeasureSystem((KLocale::MeasureSystem)i); + m_locale->setMeasureSystem((TDELocale::MeasureSystem)i); emit localeChanged(); } diff --git a/kcontrol/locale/localeother.h b/kcontrol/locale/localeother.h index 4e000bec6..1ccad292d 100644 --- a/kcontrol/locale/localeother.h +++ b/kcontrol/locale/localeother.h @@ -29,15 +29,15 @@ class TQLabel; class TQComboBox; -class KLocale; +class TDELocale; -class KLocaleConfigOther : public TQWidget +class TDELocaleConfigOther : public TQWidget { Q_OBJECT public: - KLocaleConfigOther(KLocale *locale, TQWidget *parent = 0, const char *name = 0); - virtual ~KLocaleConfigOther(); + TDELocaleConfigOther(TDELocale *locale, TQWidget *parent = 0, const char *name = 0); + virtual ~TDELocaleConfigOther(); void save(); @@ -59,7 +59,7 @@ private slots: void slotMeasureSystemChanged(int i); private: - KLocale *m_locale; + TDELocale *m_locale; TQLabel *m_labMeasureSystem; TQComboBox *m_combMeasureSystem; diff --git a/kcontrol/locale/localetime.cpp b/kcontrol/locale/localetime.cpp index c41bcba4d..1e31f14f7 100644 --- a/kcontrol/locale/localetime.cpp +++ b/kcontrol/locale/localetime.cpp @@ -80,7 +80,7 @@ bool operator>= (const StringPair &p1, const StringPair &p2) return ! (p1.userName>=p2.userName); } -StringPair KLocaleConfigTime::buildStringPair(const TQChar &c, const TQString &s) const +StringPair TDELocaleConfigTime::buildStringPair(const TQChar &c, const TQString &s) const { StringPair pair; pair.storeName=c; @@ -88,7 +88,7 @@ StringPair KLocaleConfigTime::buildStringPair(const TQChar &c, const TQString &s return pair; } -TQValueList<StringPair> KLocaleConfigTime::timeMap() const +TQValueList<StringPair> TDELocaleConfigTime::timeMap() const { TQValueList < StringPair > list; list+=buildStringPair('H',m_locale->translate("HH")); @@ -104,7 +104,7 @@ TQValueList<StringPair> KLocaleConfigTime::timeMap() const return list; } -TQValueList <StringPair> KLocaleConfigTime::dateMap() const +TQValueList <StringPair> TDELocaleConfigTime::dateMap() const { TQValueList < StringPair > list; list+=buildStringPair('Y',m_locale->translate("YYYY")); @@ -123,7 +123,7 @@ TQValueList <StringPair> KLocaleConfigTime::dateMap() const return list; } -TQString KLocaleConfigTime::userToStore(const TQValueList<StringPair> & list, +TQString TDELocaleConfigTime::userToStore(const TQValueList<StringPair> & list, const TQString & userFormat) const { TQString result; @@ -161,7 +161,7 @@ TQString KLocaleConfigTime::userToStore(const TQValueList<StringPair> & list, return result; } -TQString KLocaleConfigTime::storeToUser(const TQValueList<StringPair> & list, +TQString TDELocaleConfigTime::storeToUser(const TQValueList<StringPair> & list, const TQString & storeFormat) const { TQString result; @@ -189,7 +189,7 @@ TQString KLocaleConfigTime::storeToUser(const TQValueList<StringPair> & list, return result; } -KLocaleConfigTime::KLocaleConfigTime(KLocale *_locale, +TDELocaleConfigTime::TDELocaleConfigTime(TDELocale *_locale, TQWidget *parent, const char*name) : TQWidget(parent, name), m_locale(_locale) @@ -239,14 +239,14 @@ KLocaleConfigTime::KLocaleConfigTime(KLocale *_locale, lay->setColStretch(1, 1); } -KLocaleConfigTime::~KLocaleConfigTime() +TDELocaleConfigTime::~TDELocaleConfigTime() { } -void KLocaleConfigTime::save() +void TDELocaleConfigTime::save() { // temperary use of our locale as the global locale - KLocale *lsave = TDEGlobal::_locale; + TDELocale *lsave = TDEGlobal::_locale; TDEGlobal::_locale = m_locale; TDEConfig *config = TDEGlobal::config(); @@ -302,7 +302,7 @@ void KLocaleConfigTime::save() TDEGlobal::_locale = lsave; } -void KLocaleConfigTime::showEvent( TQShowEvent *e ) +void TDELocaleConfigTime::showEvent( TQShowEvent *e ) { // This option makes sense only for languages where nouns are declined if ( !m_locale->nounDeclension() ) @@ -310,7 +310,7 @@ void KLocaleConfigTime::showEvent( TQShowEvent *e ) TQWidget::showEvent( e ); } -void KLocaleConfigTime::slotCalendarSystemChanged(int calendarSystem) +void TDELocaleConfigTime::slotCalendarSystemChanged(int calendarSystem) { kdDebug() << "CalendarSystem: " << calendarSystem << endl; @@ -333,7 +333,7 @@ void KLocaleConfigTime::slotCalendarSystemChanged(int calendarSystem) emit localeChanged(); } -void KLocaleConfigTime::slotLocaleChanged() +void TDELocaleConfigTime::slotLocaleChanged() { typedef TQValueVector<TQString> CalendarVector; CalendarVector calendars(4); @@ -375,7 +375,7 @@ calendarType); } -void KLocaleConfigTime::slotTimeFmtChanged(const TQString &t) +void TDELocaleConfigTime::slotTimeFmtChanged(const TQString &t) { // m_locale->setTimeFormat(t); m_locale->setTimeFormat( userToStore( timeMap(), t ) ); @@ -383,27 +383,27 @@ void KLocaleConfigTime::slotTimeFmtChanged(const TQString &t) emit localeChanged(); } -void KLocaleConfigTime::slotDateFmtChanged(const TQString &t) +void TDELocaleConfigTime::slotDateFmtChanged(const TQString &t) { // m_locale->setDateFormat(t); m_locale->setDateFormat( userToStore( dateMap(), t ) ); emit localeChanged(); } -void KLocaleConfigTime::slotDateFmtShortChanged(const TQString &t) +void TDELocaleConfigTime::slotDateFmtShortChanged(const TQString &t) { //m_locale->setDateFormatShort(t); m_locale->setDateFormatShort( userToStore( dateMap(), t ) ); emit localeChanged(); } -void KLocaleConfigTime::slotWeekStartDayChanged(int firstDay) { +void TDELocaleConfigTime::slotWeekStartDayChanged(int firstDay) { kdDebug(173) << k_funcinfo << "first day is now: " << firstDay << endl; m_locale->setWeekStartDay(m_comboWeekStartDay->currentItem() + 1); emit localeChanged(); } -void KLocaleConfigTime::slotDateMonthNamePossChanged() +void TDELocaleConfigTime::slotDateMonthNamePossChanged() { if (m_locale->nounDeclension()) { @@ -412,7 +412,7 @@ void KLocaleConfigTime::slotDateMonthNamePossChanged() } } -void KLocaleConfigTime::slotTranslate() +void TDELocaleConfigTime::slotTranslate() { TQString str; @@ -531,7 +531,7 @@ void KLocaleConfigTime::slotTranslate() } } -void KLocaleConfigTime::updateWeekDayNames() +void TDELocaleConfigTime::updateWeekDayNames() { const KCalendarSystem * calendar = m_locale->calendar(); diff --git a/kcontrol/locale/localetime.h b/kcontrol/locale/localetime.h index b77de2af9..0c34380f7 100644 --- a/kcontrol/locale/localetime.h +++ b/kcontrol/locale/localetime.h @@ -31,18 +31,18 @@ class TQCheckBox; class TQComboBox; -class KLocale; +class TDELocale; class KLanguageCombo; class StringPair; -class KLocaleConfigTime : public TQWidget +class TDELocaleConfigTime : public TQWidget { Q_OBJECT public: - KLocaleConfigTime( KLocale *_locale, TQWidget *parent=0, const char *name=0); - virtual ~KLocaleConfigTime( ); + TDELocaleConfigTime( TDELocale *_locale, TQWidget *parent=0, const char *name=0); + virtual ~TDELocaleConfigTime( ); void save(); @@ -83,7 +83,7 @@ private: const TQString & userFormat) const; StringPair buildStringPair(const TQChar &storeName, const TQString &userName) const; - KLocale *m_locale; + TDELocale *m_locale; // Time & dates TQLabel *m_labTimeFmt; diff --git a/kcontrol/locale/main.cpp b/kcontrol/locale/main.cpp index 63ca9da4b..634c3bd45 100644 --- a/kcontrol/locale/main.cpp +++ b/kcontrol/locale/main.cpp @@ -23,16 +23,16 @@ extern "C" { KDE_EXPORT void *init_kcm_locale() { - KLocale::setMainCatalogue("kcmlocale"); - return new KLocaleFactory("kcmlocale"); + TDELocale::setMainCatalogue("kcmlocale"); + return new TDELocaleFactory("kcmlocale"); } } /* extern "C" { TDECModule *create_locale(TQWidget *parent, const char* name) { - KLocale::setMainCatalogue("kcmlocale"); - return new KLocaleApplication(parent, "kcmlocale"); + TDELocale::setMainCatalogue("kcmlocale"); + return new TDELocaleApplication(parent, "kcmlocale"); } } */ diff --git a/kcontrol/locale/toplevel.cpp b/kcontrol/locale/toplevel.cpp index e3a50847c..8df790ec7 100644 --- a/kcontrol/locale/toplevel.cpp +++ b/kcontrol/locale/toplevel.cpp @@ -45,9 +45,9 @@ #include "kcmlocale.h" #include "toplevel.moc" -KLocaleApplication::KLocaleApplication(TQWidget *parent, const char* /*name*/, +TDELocaleApplication::TDELocaleApplication(TQWidget *parent, const char* /*name*/, const TQStringList &args) - : TDECModule( KLocaleFactory::instance(), parent, args) + : TDECModule( TDELocaleFactory::instance(), parent, args) { TDEAboutData* aboutData = new TDEAboutData("kcmlocale", I18N_NOOP("KCMLocale"), @@ -62,26 +62,26 @@ KLocaleApplication::KLocaleApplication(TQWidget *parent, const char* /*name*/, m_nullConfig = new TDEConfig(TQString::null, false, false); m_globalConfig = new TDEConfig(TQString::null, false, true); - m_locale = new KLocale(TQString::fromLatin1("kcmlocale"), m_nullConfig); + m_locale = new TDELocale(TQString::fromLatin1("kcmlocale"), m_nullConfig); TQVBoxLayout *l = new TQVBoxLayout(this, 0, KDialog::spacingHint()); l->setAutoAdd(TRUE); m_tab = new TQTabWidget(this); - m_localemain = new KLocaleConfig(m_locale, this); + m_localemain = new TDELocaleConfig(m_locale, this); m_tab->addTab( m_localemain, TQString::null); - m_localenum = new KLocaleConfigNumber(m_locale, this); + m_localenum = new TDELocaleConfigNumber(m_locale, this); m_tab->addTab( m_localenum, TQString::null ); - m_localemon = new KLocaleConfigMoney(m_locale, this); + m_localemon = new TDELocaleConfigMoney(m_locale, this); m_tab->addTab( m_localemon, TQString::null ); - m_localetime = new KLocaleConfigTime(m_locale, this); + m_localetime = new TDELocaleConfigTime(m_locale, this); m_tab->addTab( m_localetime, TQString::null ); - m_localeother = new KLocaleConfigOther(m_locale, this); + m_localeother = new TDELocaleConfigOther(m_locale, this); m_tab->addTab( m_localeother, TQString::null ); // Examples m_gbox = new TQVGroupBox(this); - m_sample = new KLocaleSample(m_locale, m_gbox); + m_sample = new TDELocaleSample(m_locale, m_gbox); // getting signals from childs connect(m_localemain, TQT_SIGNAL(localeChanged()), @@ -146,33 +146,33 @@ KLocaleApplication::KLocaleApplication(TQWidget *parent, const char* /*name*/, load(); } -KLocaleApplication::~KLocaleApplication() +TDELocaleApplication::~TDELocaleApplication() { delete m_locale; delete m_globalConfig; delete m_nullConfig; } -void KLocaleApplication::load() +void TDELocaleApplication::load() { load( false ); } -void KLocaleApplication::load( bool useDefaults ) +void TDELocaleApplication::load( bool useDefaults ) { m_globalConfig->setReadDefaults( useDefaults ); m_globalConfig->reparseConfiguration(); - *m_locale = KLocale(TQString::fromLatin1("kcmlocale"), m_globalConfig); + *m_locale = TDELocale(TQString::fromLatin1("kcmlocale"), m_globalConfig); emit localeChanged(); emit languageChanged(); emit changed(useDefaults); } -void KLocaleApplication::save() +void TDELocaleApplication::save() { // temperary use of our locale as the global locale - KLocale *lsave = TDEGlobal::_locale; + TDELocale *lsave = TDEGlobal::_locale; TDEGlobal::_locale = m_locale; KMessageBox::information(this, m_locale->translate ("Changed language settings apply only to " @@ -206,12 +206,12 @@ void KLocaleApplication::save() emit changed(false); } -void KLocaleApplication::defaults() +void TDELocaleApplication::defaults() { load( true ); } -TQString KLocaleApplication::quickHelp() const +TQString TDELocaleApplication::quickHelp() const { return m_locale->translate("<h1>Country/Region & Language</h1>\n" "<p>From here you can configure language, numeric, and time \n" @@ -222,7 +222,7 @@ TQString KLocaleApplication::quickHelp() const "to use 24 hours and and use comma as decimal separator.</p>\n"); } -void KLocaleApplication::slotTranslate() +void TDELocaleApplication::slotTranslate() { // The untranslated string for TQLabel are stored in // the name() so we use that when retranslating @@ -269,7 +269,7 @@ void KLocaleApplication::slotTranslate() // not retranslated. } -void KLocaleApplication::slotChanged() +void TDELocaleApplication::slotChanged() { emit changed(true); } diff --git a/kcontrol/locale/toplevel.h b/kcontrol/locale/toplevel.h index 4514ecfc5..e381d6749 100644 --- a/kcontrol/locale/toplevel.h +++ b/kcontrol/locale/toplevel.h @@ -32,21 +32,21 @@ class TQTabWidget; class TQGroupBox; class TDEConfig; -class KLocale; -class KLocaleConfig; -class KLocaleConfigMoney; -class KLocaleConfigNumber; -class KLocaleConfigTime; -class KLocaleConfigOther; -class KLocaleSample; - -class KLocaleApplication : public TDECModule +class TDELocale; +class TDELocaleConfig; +class TDELocaleConfigMoney; +class TDELocaleConfigNumber; +class TDELocaleConfigTime; +class TDELocaleConfigOther; +class TDELocaleSample; + +class TDELocaleApplication : public TDECModule { Q_OBJECT public: - KLocaleApplication(TQWidget *parent, const char *name, const TQStringList &); - virtual ~KLocaleApplication(); + TDELocaleApplication(TQWidget *parent, const char *name, const TQStringList &); + virtual ~TDELocaleApplication(); virtual void load(); virtual void load(bool useDefault); @@ -66,22 +66,22 @@ public slots: void slotChanged(); private: - KLocale *m_locale; + TDELocale *m_locale; TQTabWidget *m_tab; - KLocaleConfig *m_localemain; - KLocaleConfigNumber *m_localenum; - KLocaleConfigMoney *m_localemon; - KLocaleConfigTime *m_localetime; - KLocaleConfigOther *m_localeother; + TDELocaleConfig *m_localemain; + TDELocaleConfigNumber *m_localenum; + TDELocaleConfigMoney *m_localemon; + TDELocaleConfigTime *m_localetime; + TDELocaleConfigOther *m_localeother; TQGroupBox *m_gbox; - KLocaleSample *m_sample; + TDELocaleSample *m_sample; TDEConfig * m_globalConfig; TDEConfig * m_nullConfig; }; -typedef KGenericFactory<KLocaleApplication, TQWidget > KLocaleFactory; +typedef KGenericFactory<TDELocaleApplication, TQWidget > TDELocaleFactory; #endif |