diff options
Diffstat (limited to 'lib/kross/main')
-rw-r--r-- | lib/kross/main/mainmodule.cpp | 8 | ||||
-rw-r--r-- | lib/kross/main/manager.cpp | 14 | ||||
-rw-r--r-- | lib/kross/main/scriptaction.cpp | 8 | ||||
-rw-r--r-- | lib/kross/main/scriptcontainer.cpp | 18 | ||||
-rw-r--r-- | lib/kross/main/scriptguiclient.cpp | 22 | ||||
-rw-r--r-- | lib/kross/main/wdgscriptsmanager.cpp | 8 |
6 files changed, 39 insertions, 39 deletions
diff --git a/lib/kross/main/mainmodule.cpp b/lib/kross/main/mainmodule.cpp index dde74502..8c29180f 100644 --- a/lib/kross/main/mainmodule.cpp +++ b/lib/kross/main/mainmodule.cpp @@ -79,7 +79,7 @@ EventSignal::Ptr MainModule::addSignal(const TQString& name, TQObject* sender, T { EventSignal* event = new EventSignal(name, sender, signal); if(! addChild(name, event)) { - krosswarning( TQString("Failed to add signal name='%1' signature='%2'").tqarg(name).tqarg(signal.data()) ); + krosswarning( TQString("Failed to add signal name='%1' signature='%2'").arg(name).arg(signal.data()) ); return 0; } return event; @@ -89,7 +89,7 @@ EventSlot::Ptr MainModule::addSlot(const TQString& name, TQObject* receiver, TQC { EventSlot* event = new EventSlot(name, receiver, slot); if(! addChild(name, event)) { - krosswarning( TQString("Failed to add slot name='%1' signature='%2'").tqarg(name).tqarg(slot.data()) ); + krosswarning( TQString("Failed to add slot name='%1' signature='%2'").arg(name).arg(slot.data()) ); return 0; } return event; @@ -99,7 +99,7 @@ QtObject::Ptr MainModule::addTQObject(TQObject* object, const TQString& name) { QtObject* qtobject = new QtObject(object, name); if(! addChild(name, qtobject)) { - krosswarning( TQString("Failed to add TQObject name='%1'").tqarg(object->name()) ); + krosswarning( TQString("Failed to add TQObject name='%1'").arg(object->name()) ); return 0; } return qtobject; @@ -109,7 +109,7 @@ EventAction::Ptr MainModule::addKAction(KAction* action, const TQString& name) { EventAction* event = new EventAction(name, action); if(! addChild(name, event)) { - krosswarning( TQString("Failed to add KAction name='%1'").tqarg(action->name()) ); + krosswarning( TQString("Failed to add KAction name='%1'").arg(action->name()) ); return 0; } return event; diff --git a/lib/kross/main/manager.cpp b/lib/kross/main/manager.cpp index 646a8746..156eb2ac 100644 --- a/lib/kross/main/manager.cpp +++ b/lib/kross/main/manager.cpp @@ -169,7 +169,7 @@ Interpreter* Manager::getInterpreter(const TQString& interpretername) setException(0); // clear previous exceptions if(! d->interpreterinfos.contains(interpretername)) { - setException( new Exception(i18n("No such interpreter '%1'").tqarg(interpretername)) ); + setException( new Exception(i18n("No such interpreter '%1'").arg(interpretername)) ); return 0; } @@ -206,22 +206,22 @@ Module::Ptr Manager::loadModule(const TQString& modulename) if(module) return module; else - krossdebug( TQString("Manager::loadModule(%1) =======> Modulename registered, but module is invalid!").tqarg(modulename) ); + krossdebug( TQString("Manager::loadModule(%1) =======> Modulename registered, but module is invalid!").arg(modulename) ); } KLibLoader* loader = KLibLoader::self(); KLibrary* lib = loader->globalLibrary( modulename.latin1() ); if(! lib) { - krosswarning( TQString("Failed to load module '%1': %2").tqarg(modulename).tqarg(loader->lastErrorMessage()) ); + krosswarning( TQString("Failed to load module '%1': %2").arg(modulename).arg(loader->lastErrorMessage()) ); return 0; } - krossdebug( TQString("Successfully loaded module '%1'").tqarg(modulename) ); + krossdebug( TQString("Successfully loaded module '%1'").arg(modulename) ); def_module_func func; func = (def_module_func) lib->symbol("init_module"); if(! func) { - krosswarning( TQString("Failed to determinate init function in module '%1'").tqarg(modulename) ); + krosswarning( TQString("Failed to determinate init function in module '%1'").arg(modulename) ); return 0; } @@ -235,14 +235,14 @@ Module::Ptr Manager::loadModule(const TQString& modulename) lib->unload(); if(! module) { - krosswarning( TQString("Failed to load module '%1'").tqarg(modulename) ); + krosswarning( TQString("Failed to load module '%1'").arg(modulename) ); return 0; } // Don't remember module cause we like to have freeing it handled by the caller. //d->modules.replace(modulename, module); - //krossdebug( TQString("Kross::Api::Manager::loadModule modulename='%1' module='%2'").tqarg(modulename).tqarg(module->toString()) ); + //krossdebug( TQString("Kross::Api::Manager::loadModule modulename='%1' module='%2'").arg(modulename).arg(module->toString()) ); return module; } diff --git a/lib/kross/main/scriptaction.cpp b/lib/kross/main/scriptaction.cpp index b658a0b1..f7e11618 100644 --- a/lib/kross/main/scriptaction.cpp +++ b/lib/kross/main/scriptaction.cpp @@ -152,9 +152,9 @@ ScriptAction::ScriptAction(const TQString& scriptconfigfile, const TQDomElement& if(icon.isNull()) icon = KMimeType::iconForURL( KURL(file) ); if(description.isEmpty()) - description = TQString("%1<br>%2").tqarg(text.isEmpty() ? name : text).tqarg(file); + description = TQString("%1<br>%2").arg(text.isEmpty() ? name : text).arg(file); else - description += TQString("<br>%1").tqarg(file); + description += TQString("<br>%1").arg(file); ScriptContainer::setName(file); } @@ -230,8 +230,8 @@ void ScriptAction::activate() TQString errormessage = Kross::Api::ScriptContainer::getException()->getError(); TQString tracedetails = Kross::Api::ScriptContainer::getException()->getTrace(); d->logs << TQString("<b>%1</b><br>%2") - .tqarg( TQStyleSheet::escape(errormessage) ) - .tqarg( TQStyleSheet::escape(tracedetails) ); + .arg( TQStyleSheet::escape(errormessage) ) + .arg( TQStyleSheet::escape(tracedetails) ); emit failed(errormessage, tracedetails); } else { diff --git a/lib/kross/main/scriptcontainer.cpp b/lib/kross/main/scriptcontainer.cpp index a345dd02..7f7f980e 100644 --- a/lib/kross/main/scriptcontainer.cpp +++ b/lib/kross/main/scriptcontainer.cpp @@ -87,7 +87,7 @@ ScriptContainer::ScriptContainer(const TQString& name) : MainModule(name) , d( new ScriptContainerPrivate() ) // initialize d-pointer class { - //krossdebug( TQString("ScriptContainer::ScriptContainer() Ctor name='%1'").tqarg(name) ); + //krossdebug( TQString("ScriptContainer::ScriptContainer() Ctor name='%1'").arg(name) ); d->script = 0; d->name = name; @@ -95,7 +95,7 @@ ScriptContainer::ScriptContainer(const TQString& name) ScriptContainer::~ScriptContainer() { - //krossdebug( TQString("ScriptContainer::~ScriptContainer() Dtor name='%1'").tqarg(d->name) ); + //krossdebug( TQString("ScriptContainer::~ScriptContainer() Dtor name='%1'").arg(d->name) ); finalize(); delete d; @@ -164,8 +164,8 @@ bool ScriptContainer::setOption(const TQString name, const TQVariant& value) if(info->hasOption(name)) { d->options.replace(name, value); return true; - } else krosswarning( TQString("Kross::Api::ScriptContainer::setOption(%1, %2): No such option").tqarg(name).tqarg(value.toString()) ); - } else krosswarning( TQString("Kross::Api::ScriptContainer::setOption(%1, %2): No such interpreterinfo").tqarg(name).tqarg(value.toString()) ); + } else krosswarning( TQString("Kross::Api::ScriptContainer::setOption(%1, %2): No such option").arg(name).arg(value.toString()) ); + } else krosswarning( TQString("Kross::Api::ScriptContainer::setOption(%1, %2): No such interpreterinfo").arg(name).arg(value.toString()) ); return false; } @@ -244,19 +244,19 @@ bool ScriptContainer::initialize() finalize(); if(! d->scriptfile.isNull()) { - krossdebug( TQString("Kross::Api::ScriptContainer::initialize() file=%1").tqarg(d->scriptfile) ); + krossdebug( TQString("Kross::Api::ScriptContainer::initialize() file=%1").arg(d->scriptfile) ); if(d->interpretername.isNull()) { d->interpretername = Manager::scriptManager()->getInterpreternameForFile( d->scriptfile ); if(d->interpretername.isNull()) { - setException( new Exception(i18n("Failed to determinate interpreter for scriptfile '%1'").tqarg(d->scriptfile)) ); + setException( new Exception(i18n("Failed to determinate interpreter for scriptfile '%1'").arg(d->scriptfile)) ); return false; } } TQFile f( d->scriptfile ); if(! f.open(IO_ReadOnly)) { - setException( new Exception(i18n("Failed to open scriptfile '%1'").tqarg(d->scriptfile)) ); + setException( new Exception(i18n("Failed to open scriptfile '%1'").arg(d->scriptfile)) ); return false; } d->code = TQString( f.readAll() ); @@ -265,13 +265,13 @@ bool ScriptContainer::initialize() Interpreter* interpreter = Manager::scriptManager()->getInterpreter(d->interpretername); if(! interpreter) { - setException( new Exception(i18n("Unknown interpreter '%1'").tqarg(d->interpretername)) ); + setException( new Exception(i18n("Unknown interpreter '%1'").arg(d->interpretername)) ); return false; } d->script = interpreter->createScript(this); if(! d->script) { - setException( new Exception(i18n("Failed to create script for interpreter '%1'").tqarg(d->interpretername)) ); + setException( new Exception(i18n("Failed to create script for interpreter '%1'").arg(d->interpretername)) ); return false; } if(d->script->hadException()) { diff --git a/lib/kross/main/scriptguiclient.cpp b/lib/kross/main/scriptguiclient.cpp index bce26d5c..88877f5a 100644 --- a/lib/kross/main/scriptguiclient.cpp +++ b/lib/kross/main/scriptguiclient.cpp @@ -147,10 +147,10 @@ void ScriptGUIClient::reloadInstalledScripts() bool ScriptGUIClient::installScriptPackage(const TQString& scriptpackagefile) { - krossdebug( TQString("Install script package: %1").tqarg(scriptpackagefile) ); + krossdebug( TQString("Install script package: %1").arg(scriptpackagefile) ); KTar archive( scriptpackagefile ); if(! archive.open(IO_ReadOnly)) { - KMessageBox::sorry(0, i18n("Could not read the package \"%1\".").tqarg(scriptpackagefile)); + KMessageBox::sorry(0, i18n("Could not read the package \"%1\".").arg(scriptpackagefile)); return false; } @@ -167,17 +167,17 @@ bool ScriptGUIClient::installScriptPackage(const TQString& scriptpackagefile) if( TQDir(destination).exists() ) { if( KMessageBox::warningContinueCancel(0, - i18n("A script package with the name \"%1\" already exists. Replace this package?" ).tqarg(packagename), + i18n("A script package with the name \"%1\" already exists. Replace this package?" ).arg(packagename), i18n("Replace")) != KMessageBox::Continue ) return false; if(! KIO::NetAccess::del(destination, 0) ) { - KMessageBox::sorry(0, i18n("Could not uninstall this script package. You may not have sufficient permissions to delete the folder \"%1\".").tqarg(destination)); + KMessageBox::sorry(0, i18n("Could not uninstall this script package. You may not have sufficient permissions to delete the folder \"%1\".").arg(destination)); return false; } } - krossdebug( TQString("Copy script-package to destination directory: %1").tqarg(destination) ); + krossdebug( TQString("Copy script-package to destination directory: %1").arg(destination) ); const KArchiveDirectory* archivedir = archive.directory(); archivedir->copyTo(destination, true); @@ -188,7 +188,7 @@ bool ScriptGUIClient::installScriptPackage(const TQString& scriptpackagefile) bool ScriptGUIClient::uninstallScriptPackage(const TQString& scriptpackagepath) { if(! KIO::NetAccess::del(scriptpackagepath, 0) ) { - KMessageBox::sorry(0, i18n("Could not uninstall this script package. You may not have sufficient permissions to delete the folder \"%1\".").tqarg(scriptpackagepath)); + KMessageBox::sorry(0, i18n("Could not uninstall this script package. You may not have sufficient permissions to delete the folder \"%1\".").arg(scriptpackagepath)); return false; } reloadInstalledScripts(); @@ -197,18 +197,18 @@ bool ScriptGUIClient::uninstallScriptPackage(const TQString& scriptpackagepath) bool ScriptGUIClient::loadScriptConfigFile(const TQString& scriptconfigfile) { - krossdebug( TQString("ScriptGUIClient::loadScriptConfig file=%1").tqarg(scriptconfigfile) ); + krossdebug( TQString("ScriptGUIClient::loadScriptConfig file=%1").arg(scriptconfigfile) ); TQDomDocument domdoc; TQFile file(scriptconfigfile); if(! file.open(IO_ReadOnly)) { - krosswarning( TQString("ScriptGUIClient::loadScriptConfig(): Failed to read scriptconfigfile: %1").tqarg(scriptconfigfile) ); + krosswarning( TQString("ScriptGUIClient::loadScriptConfig(): Failed to read scriptconfigfile: %1").arg(scriptconfigfile) ); return false; } bool ok = domdoc.setContent(&file); file.close(); if(! ok) { - krosswarning( TQString("ScriptGUIClient::loadScriptConfig(): Failed to parse scriptconfigfile: %1").tqarg(scriptconfigfile) ); + krosswarning( TQString("ScriptGUIClient::loadScriptConfig(): Failed to parse scriptconfigfile: %1").arg(scriptconfigfile) ); return false; } @@ -244,7 +244,7 @@ bool ScriptGUIClient::loadScriptConfigDocument(const TQString& scriptconfigfile, else { // else just print a warning and fall through (so, install the action // and don't care any longer of the duplicated name)... - krosswarning( TQString("Kross::Api::ScriptGUIClient::loadScriptConfigDocument: There exists already a scriptaction with name \"%1\". Added anyway...").tqarg(action->name()) ); + krosswarning( TQString("Kross::Api::ScriptGUIClient::loadScriptConfigDocument: There exists already a scriptaction with name \"%1\". Added anyway...").arg(action->name()) ); } } installedcollection->attach( action ); @@ -353,7 +353,7 @@ bool ScriptGUIClient::executeScriptFile() bool ScriptGUIClient::executeScriptFile(const TQString& file) { - krossdebug( TQString("Kross::Api::ScriptGUIClient::executeScriptFile() file='%1'").tqarg(file) ); + krossdebug( TQString("Kross::Api::ScriptGUIClient::executeScriptFile() file='%1'").arg(file) ); ScriptAction::Ptr action = new ScriptAction(file); return executeScriptAction(action); diff --git a/lib/kross/main/wdgscriptsmanager.cpp b/lib/kross/main/wdgscriptsmanager.cpp index cb696c5a..e521023e 100644 --- a/lib/kross/main/wdgscriptsmanager.cpp +++ b/lib/kross/main/wdgscriptsmanager.cpp @@ -95,7 +95,7 @@ class ToolTip : public TQToolTip if(item) { TQRect r( m_parent->itemRect(item) ); if(r.isValid() && item->action()) { - tip(r, TQString("<qt>%1</qt>").tqarg(item->action()->toolTip())); + tip(r, TQString("<qt>%1</qt>").arg(item->action()->toolTip())); } } } @@ -287,7 +287,7 @@ void WdgScriptsManager::slotUninstallScript() if( KMessageBox::warningContinueCancel(0, i18n("Uninstall the script package \"%1\" and delete the package's folder \"%2\"?") - .tqarg(item->action()->text()).tqarg(packagepath), + .arg(item->action()->text()).arg(packagepath), i18n("Uninstall")) != KMessageBox::Continue ) { return; @@ -321,7 +321,7 @@ void WdgScriptsManager::slotGetNewScript() { #ifdef KROSS_SUPPORT_NEWSTUFF const TQString appname = KApplication::kApplication()->name(); - const TQString type = TQString("%1/script").tqarg(appname); + const TQString type = TQString("%1/script").arg(appname); if(! d->newstuff) { d->newstuff = new ScriptNewStuff(d->m_scripguiclient, type); @@ -336,7 +336,7 @@ void WdgScriptsManager::slotGetNewScript() TQObject::connect(p, TQT_SIGNAL(providersLoaded(Provider::List*)), d, TQT_SLOT(slotProviders(Provider::List*))); - p->load(type, TQString("http://download.kde.org/khotnewstuff/%1scripts-providers.xml").tqarg(appname)); + p->load(type, TQString("http://download.kde.org/khotnewstuff/%1scripts-providers.xml").arg(appname)); d->exec(); #endif } |