Rename KGlobal, KProcess, and KClipboard to avoid conflicts with KDE4

pull/1/head
Timothy Pearson 12 years ago
parent f2f2c5781e
commit d9b70de56a

@ -56,7 +56,7 @@ ErrorLog::ErrorLog(const TQString &name)
{
TQWidget::setCaption(i18n("KRadio Logger"));
TQFrame *info = addPage(i18n("Information"), i18n("Information"),
KGlobal::instance()->iconLoader()->loadIcon(
TDEGlobal::instance()->iconLoader()->loadIcon(
"messagebox_info", KIcon::NoGroup, KIcon::SizeMedium
)
);
@ -71,7 +71,7 @@ ErrorLog::ErrorLog(const TQString &name)
TQFrame *warn = addPage(i18n("Warnings"), i18n("Warnings"),
KGlobal::instance()->iconLoader()->loadIcon(
TDEGlobal::instance()->iconLoader()->loadIcon(
"messagebox_warning", KIcon::NoGroup, KIcon::SizeMedium
)
);
@ -86,7 +86,7 @@ ErrorLog::ErrorLog(const TQString &name)
TQFrame *err = addPage(i18n("Errors"), i18n("Errors"),
KGlobal::instance()->iconLoader()->loadIcon(
TDEGlobal::instance()->iconLoader()->loadIcon(
"messagebox_critical", KIcon::NoGroup, KIcon::SizeMedium
)
);
@ -99,7 +99,7 @@ ErrorLog::ErrorLog(const TQString &name)
logError(i18n("logging started"));
TQFrame *debug = addPage(i18n("Debugging"), i18n("Debugging"),
KGlobal::instance()->iconLoader()->loadIcon(
TDEGlobal::instance()->iconLoader()->loadIcon(
"find", KIcon::NoGroup, KIcon::SizeMedium
)
);

@ -403,9 +403,9 @@ void RadioViewFrequencyRadio::drawContents(TQPainter *paint)
TQString s;
if (m_frequency < 10) {
s = i18n("%1 kHz").arg(KGlobal::locale()->formatNumber((int)(m_frequency * 1000), 0));
s = i18n("%1 kHz").arg(TDEGlobal::locale()->formatNumber((int)(m_frequency * 1000), 0));
} else {
s = i18n("%1 MHz").arg(KGlobal::locale()->formatNumber(m_frequency, 2));
s = i18n("%1 MHz").arg(TDEGlobal::locale()->formatNumber(m_frequency, 2));
}
float pxs = xh_f;

@ -336,10 +336,10 @@ bool RecordingMonitor::noticeSoundStreamData(SoundStreamID id,
double MB = kB / 1024;
double GB = MB / 1024;
TQString str_size;
str_size = i18n("%1 Byte").arg(KGlobal::locale()->formatNumber((int)B, 0));
if (kB > 1) str_size = i18n("%1 kB").arg(KGlobal::locale()->formatNumber(kB, 3));
if (MB > 1) str_size = i18n("%1 MB").arg(KGlobal::locale()->formatNumber(MB, 3));
if (GB > 1) str_size = i18n("%1 GB").arg(KGlobal::locale()->formatNumber(GB, 3));
str_size = i18n("%1 Byte").arg(TDEGlobal::locale()->formatNumber((int)B, 0));
if (kB > 1) str_size = i18n("%1 kB").arg(TDEGlobal::locale()->formatNumber(kB, 3));
if (MB > 1) str_size = i18n("%1 MB").arg(TDEGlobal::locale()->formatNumber(MB, 3));
if (GB > 1) str_size = i18n("%1 GB").arg(TDEGlobal::locale()->formatNumber(GB, 3));
m_labelSize->setText(str_size);
m_labelRate->setText(i18n("%1 Hz").arg(sf.m_SampleRate));

@ -199,7 +199,7 @@ void KRadioAboutWidget::fontChange( const TQFont &/*oldFont*/ )
{
if( mTitleLabel != 0 )
{
TQFont f( KGlobalSettings::generalFont() );
TQFont f( TDEGlobalSettings::generalFont() );
f.setBold( true );
f.setPointSize( 14 ); // Perhaps changeable ?
mTitleLabel->setFont(f);
@ -207,7 +207,7 @@ void KRadioAboutWidget::fontChange( const TQFont &/*oldFont*/ )
if( mVersionLabel != 0 )
{
TQFont f( KGlobalSettings::generalFont() );
TQFont f( TDEGlobalSettings::generalFont() );
f.setBold( true );
mVersionLabel->setFont(f);
mAuthorLabel->setFont(f);
@ -262,7 +262,7 @@ TQFrame *KRadioAboutWidget::addLicensePage( const TQString &title,
TQVBoxLayout *vbox = new TQVBoxLayout( page, KDialog::spacingHint() );
TQTextEdit *textEdit = new TQTextEdit( page, "license" );
textEdit->setFont( KGlobalSettings::fixedFont() );
textEdit->setFont( TDEGlobalSettings::fixedFont() );
textEdit->setReadOnly( true );
textEdit->setWordWrap( TQTextEdit::NoWrap );
textEdit->setText( text );

@ -131,9 +131,9 @@ TQString FrequencyRadioStation::description() const
float cf = frequency();
TQString f;
if (cf >= 10)
f = i18n("%1 MHz").arg(KGlobal::locale()->formatNumber(cf, 2));
f = i18n("%1 MHz").arg(TDEGlobal::locale()->formatNumber(cf, 2));
else
f = i18n("%1 kHz").arg(KGlobal::locale()->formatNumber(cf * 1000, 0));
f = i18n("%1 kHz").arg(TDEGlobal::locale()->formatNumber(cf * 1000, 0));
return f;
}

@ -137,12 +137,12 @@ protected :
#define PLUGIN_LIBRARY_FUNCTIONS(class_name, i18nName, description) \
extern "C" void KRadioPlugin_LoadLibrary() \
{ \
KGlobal::locale()->insertCatalogue(i18nName); \
TDEGlobal::locale()->insertCatalogue(i18nName); \
} \
\
extern "C" void KRadioPlugin_UnloadLibrary() \
{ \
KGlobal::locale()->removeCatalogue(i18nName); \
TDEGlobal::locale()->removeCatalogue(i18nName); \
} \
\
extern "C" void KRadioPlugin_GetAvailablePlugins(TQMap<TQString, TQString> &info) \
@ -163,12 +163,12 @@ extern "C" PluginBase *KRadioPlugin_CreatePlugin(const TQString &type, const TQS
#define PLUGIN_LIBRARY_FUNCTIONS2(class_name1, i18nName, description1, class_name2, description2) \
extern "C" void KRadioPlugin_LoadLibrary() \
{ \
KGlobal::locale()->insertCatalogue(i18nName); \
TDEGlobal::locale()->insertCatalogue(i18nName); \
} \
\
extern "C" void KRadioPlugin_UnloadLibrary() \
{ \
KGlobal::locale()->removeCatalogue(i18nName); \
TDEGlobal::locale()->removeCatalogue(i18nName); \
} \
\
extern "C" void KRadioPlugin_GetAvailablePlugins(TQMap<TQString, TQString> &info) \

@ -141,7 +141,7 @@ KRadioApp::~KRadioApp()
void KRadioApp::saveState()
{
IErrorLogClient::staticLogDebug(i18n("saveState"));
saveState(KGlobal::config());
saveState(TDEGlobal::config());
}
void KRadioApp::saveState (KConfig *c)
@ -193,7 +193,7 @@ void KRadioApp::restoreState (KConfig *c)
if (n_libs < 6) { // this seems to be a meaningful minimum value for a working kradio setup
TQStringList libs
= KGlobal::dirs()->findAllResources("lib", "kradio/plugins/*.so");
= TDEGlobal::dirs()->findAllResources("lib", "kradio/plugins/*.so");
TQValueListIterator<TQString> end = libs.end();
int idx = 0;
// progress->progressBar()->setTotalSteps(libs.count());
@ -338,7 +338,7 @@ PluginBase *KRadioApp::CreatePlugin (PluginManager *manager, const TQString &cla
insert_profiler.stop();
//BlockProfiler restore_profiler("KRadioApp::CreatePlugin - restore");
//retval->restoreState(KGlobal::config());
//retval->restoreState(TDEGlobal::config());
}
return retval;

@ -56,7 +56,7 @@ int main(int argc, char *argv[])
profiler_kradioapp.stop();
BlockProfiler profiler_restore("main::restore");
a.restoreState(KGlobal::config());
a.restoreState(TDEGlobal::config());
a.startPlugins();
profiler_restore.stop();

@ -292,7 +292,7 @@ TQFrame *PluginManager::addConfigurationPage (const ConfigPageInfo &info)
TQFrame *f = m_configDialog->addPage(
info.itemName,
info.pageHeader,
KGlobal::instance()->iconLoader()->loadIcon( info.iconName, KIcon::NoGroup, KIcon::SizeMedium )
TDEGlobal::instance()->iconLoader()->loadIcon( info.iconName, KIcon::NoGroup, KIcon::SizeMedium )
);
// fill config frame with layout ...
@ -371,7 +371,7 @@ void PluginManager::addAboutPage (PluginBase *forWhom,
TQFrame *f = m_aboutDialog->addPage(
info.itemName,
info.pageHeader,
KGlobal::instance()->iconLoader()->loadIcon( info.iconName, KIcon::NoGroup, KIcon::SizeMedium )
TDEGlobal::instance()->iconLoader()->loadIcon( info.iconName, KIcon::NoGroup, KIcon::SizeMedium )
);
// register this frame and config page
@ -516,7 +516,7 @@ void PluginManager::slotConfigOK()
{
emit sigConfigOK();
if (m_Application)
m_Application->saveState(KGlobal::config());
m_Application->saveState(TDEGlobal::config());
}

Loading…
Cancel
Save