diff options
Diffstat (limited to 'tdefilereplace/tdefilereplacepart.cpp')
-rw-r--r-- | tdefilereplace/tdefilereplacepart.cpp | 86 |
1 files changed, 43 insertions, 43 deletions
diff --git a/tdefilereplace/tdefilereplacepart.cpp b/tdefilereplace/tdefilereplacepart.cpp index 14d9ff3..c3c4b82 100644 --- a/tdefilereplace/tdefilereplacepart.cpp +++ b/tdefilereplace/tdefilereplacepart.cpp @@ -28,12 +28,12 @@ #include <kbugreport.h> #include <tdeconfig.h> #include <tdefiledialog.h> -#include <kinstance.h> +#include <tdeinstance.h> #include <tdeio/netaccess.h> #include <tdelocale.h> #include <tdemessagebox.h> #include <tdeparts/genericfactory.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <kiconloader.h> #include <tdeglobal.h> #include <kiconeffect.h> @@ -143,7 +143,7 @@ void TDEFileReplacePart::slotSearchingOperation() m_view->showSemaphore("yellow"); - kapp->processEvents(); + tdeApp->processEvents(); //disabling and enabling sorting... don't ask me why, but it works! rv->setSorting(0); @@ -377,7 +377,7 @@ void TDEFileReplacePart::showAboutApplication() void TDEFileReplacePart::appHelpActivated() { - kapp->invokeHelp(TQString(), "tdefilereplace"); + tdeApp->invokeHelp(TQString(), "tdefilereplace"); } void TDEFileReplacePart::reportBug() @@ -493,7 +493,7 @@ void TDEFileReplacePart::initGUI() actionCollection()->setHighlightingEnabled(true); - DCOPClient *client = kapp->dcopClient(); + DCOPClient *client = tdeApp->dcopClient(); QCStringList appList = client->registeredApplications(); bool quantaFound = false; for(QCStringList::Iterator it = appList.begin(); it != appList.end(); ++it) @@ -506,53 +506,53 @@ void TDEFileReplacePart::initGUI() } // GUI - connect(m_view, TQT_SIGNAL(updateGUI()), this, TQT_SLOT(updateGUI())); + connect(m_view, TQ_SIGNAL(updateGUI()), this, TQ_SLOT(updateGUI())); // File - (void)new TDEAction(i18n("Customize Search/Replace Session..."), "projectopen", TDEShortcut(CTRL + Key_F), TQT_TQOBJECT(this), TQT_SLOT(slotSetNewParameters()), actionCollection(), "new_project"); - (void)new TDEAction(i18n("&Search"), "filesearch", 0, TQT_TQOBJECT(this), TQT_SLOT(slotSearchingOperation()), actionCollection(), "search"); - (void)new TDEAction(i18n("S&imulate"), "filesimulate", 0, TQT_TQOBJECT(this), TQT_SLOT(slotSimulatingOperation()), actionCollection(), "file_simulate"); - (void)new TDEAction(i18n("&Replace"), "filereplace", 0, TQT_TQOBJECT(this), TQT_SLOT(slotReplacingOperation()), actionCollection(), "replace"); - (void)new TDEAction(i18n("Sto&p"), "process-stop", 0, TQT_TQOBJECT(this), TQT_SLOT(slotStop()), actionCollection(), "stop"); - (void)new TDEAction(i18n("Cre&ate Report File..."), "document-save-as", 0, TQT_TQOBJECT(this), TQT_SLOT(slotCreateReport()), actionCollection(), "results_create_report"); - (void)new TDEAction(i18n("&Save Results List to File..."), "document-save-as", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultSave()), actionCollection(), "results_save"); - (void)new TDEAction(i18n("&Load Results List From File..."), "unsortedList", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultLoad()), actionCollection(), "results_load"); + (void)new TDEAction(i18n("Customize Search/Replace Session..."), "projectopen", TDEShortcut(CTRL + Key_F), this, TQ_SLOT(slotSetNewParameters()), actionCollection(), "new_project"); + (void)new TDEAction(i18n("&Search"), "filesearch", 0, this, TQ_SLOT(slotSearchingOperation()), actionCollection(), "search"); + (void)new TDEAction(i18n("S&imulate"), "filesimulate", 0, this, TQ_SLOT(slotSimulatingOperation()), actionCollection(), "file_simulate"); + (void)new TDEAction(i18n("&Replace"), "filereplace", 0, this, TQ_SLOT(slotReplacingOperation()), actionCollection(), "replace"); + (void)new TDEAction(i18n("Sto&p"), "process-stop", 0, this, TQ_SLOT(slotStop()), actionCollection(), "stop"); + (void)new TDEAction(i18n("Cre&ate Report File..."), "document-save-as", 0, this, TQ_SLOT(slotCreateReport()), actionCollection(), "results_create_report"); + (void)new TDEAction(i18n("&Save Results List to File..."), "document-save-as", 0, m_view, TQ_SLOT(slotResultSave()), actionCollection(), "results_save"); + (void)new TDEAction(i18n("&Load Results List From File..."), "unsortedList", 0, m_view, TQ_SLOT(slotResultLoad()), actionCollection(), "results_load"); // Strings - (void)new TDEAction(i18n("&Add String..."), "editadd", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotStringsAdd()), actionCollection(), "strings_add"); - (void)new TDEAction(i18n("&Delete String"), "editremove", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotStringsDeleteItem()), actionCollection(), "strings_del"); - (void)new TDEAction(i18n("&Empty Strings List"), "edit-delete", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotStringsEmpty()), actionCollection(), "strings_empty"); - (void)new TDEAction(i18n("&Save Strings List to File..."), "document-save-as", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotStringsSave()), actionCollection(), "strings_save"); - (void)new TDEAction(i18n("&Load Strings List From File..."), "unsortedList", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotStringsLoad()), actionCollection(), "strings_load"); - (void)new TDEAction(i18n("&Invert Current String (search <--> replace)"), "invert", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotStringsInvertCur()), actionCollection(), "strings_invert"); - (void)new TDEAction(i18n("&Invert All Strings (search <--> replace)"), "invert", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotStringsInvertAll()), actionCollection(), "strings_invert_all"); + (void)new TDEAction(i18n("&Add String..."), "editadd", 0, m_view, TQ_SLOT(slotStringsAdd()), actionCollection(), "strings_add"); + (void)new TDEAction(i18n("&Delete String"), "editremove", 0, m_view, TQ_SLOT(slotStringsDeleteItem()), actionCollection(), "strings_del"); + (void)new TDEAction(i18n("&Empty Strings List"), "edit-delete", 0, m_view, TQ_SLOT(slotStringsEmpty()), actionCollection(), "strings_empty"); + (void)new TDEAction(i18n("&Save Strings List to File..."), "document-save-as", 0, m_view, TQ_SLOT(slotStringsSave()), actionCollection(), "strings_save"); + (void)new TDEAction(i18n("&Load Strings List From File..."), "unsortedList", 0, m_view, TQ_SLOT(slotStringsLoad()), actionCollection(), "strings_load"); + (void)new TDEAction(i18n("&Invert Current String (search <--> replace)"), "invert", 0, m_view, TQ_SLOT(slotStringsInvertCur()), actionCollection(), "strings_invert"); + (void)new TDEAction(i18n("&Invert All Strings (search <--> replace)"), "invert", 0, m_view, TQ_SLOT(slotStringsInvertAll()), actionCollection(), "strings_invert_all"); // Options - (void)new TDEToggleAction(i18n("&Include Sub-Folders"), "recursive_option", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOptionRecursive()), actionCollection(), "options_recursive"); - (void)new TDEToggleAction(i18n("Create &Backup Files"), "backup_option", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOptionBackup()), actionCollection(), "options_backup"); - (void)new TDEToggleAction(i18n("Case &Sensitive"), "casesensitive_option", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOptionCaseSensitive()), actionCollection(), "options_case"); - (void)new TDEToggleAction(i18n("Enable Commands &in Replace String: [$command:option$]"), "command_option", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOptionVariables()), actionCollection(), "options_var"); - (void)new TDEToggleAction(i18n("Enable &Regular Expressions"), "regularexpression_option", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOptionRegularExpressions()), actionCollection(), "options_regularexpressions"); - (void)new TDEAction(i18n("Configure &TDEFileReplace..."), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOptionPreferences()), actionCollection(), "configure_tdefilereplace"); + (void)new TDEToggleAction(i18n("&Include Sub-Folders"), "recursive_option", 0, this, TQ_SLOT(slotOptionRecursive()), actionCollection(), "options_recursive"); + (void)new TDEToggleAction(i18n("Create &Backup Files"), "backup_option", 0, this, TQ_SLOT(slotOptionBackup()), actionCollection(), "options_backup"); + (void)new TDEToggleAction(i18n("Case &Sensitive"), "casesensitive_option", 0, this, TQ_SLOT(slotOptionCaseSensitive()), actionCollection(), "options_case"); + (void)new TDEToggleAction(i18n("Enable Commands &in Replace String: [$command:option$]"), "command_option", 0, this, TQ_SLOT(slotOptionVariables()), actionCollection(), "options_var"); + (void)new TDEToggleAction(i18n("Enable &Regular Expressions"), "regularexpression_option", 0, this, TQ_SLOT(slotOptionRegularExpressions()), actionCollection(), "options_regularexpressions"); + (void)new TDEAction(i18n("Configure &TDEFileReplace..."), "configure", 0, this, TQ_SLOT(slotOptionPreferences()), actionCollection(), "configure_tdefilereplace"); // Results - (void)new TDEAction(i18n("&Properties"), "informations", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultProperties()), actionCollection(), "results_infos"); - (void)new TDEAction(i18n("&Open"), "document-open", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultOpen()), actionCollection(), "results_openfile"); - (void)new TDEAction(i18n("Open &With..."), "document-open", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultOpenWith()), actionCollection(), "results_openfilewith"); + (void)new TDEAction(i18n("&Properties"), "informations", 0, m_view, TQ_SLOT(slotResultProperties()), actionCollection(), "results_infos"); + (void)new TDEAction(i18n("&Open"), "document-open", 0, m_view, TQ_SLOT(slotResultOpen()), actionCollection(), "results_openfile"); + (void)new TDEAction(i18n("Open &With..."), "document-open", 0, m_view, TQ_SLOT(slotResultOpenWith()), actionCollection(), "results_openfilewith"); if(quantaFound) { - (void)new TDEAction(i18n("&Edit in Quanta"), "quanta", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultEdit()), actionCollection(), "results_editfile"); + (void)new TDEAction(i18n("&Edit in Quanta"), "quanta", 0, m_view, TQ_SLOT(slotResultEdit()), actionCollection(), "results_editfile"); } - (void)new TDEAction(i18n("Open Parent &Folder"), "go-up", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultDirOpen()), actionCollection(), "results_opendir"); - (void)new TDEAction(i18n("Remove &Entry"), "edit-clear", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultRemoveEntry()), actionCollection(), "results_removeentry"); - (void)new TDEAction(i18n("&Delete"), "edit-delete", 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultDelete()), actionCollection(), "results_delete"); - (void)new TDEAction(i18n("E&xpand Tree"), 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultTreeExpand()), actionCollection(), "results_treeexpand"); - (void)new TDEAction(i18n("&Reduce Tree"), 0, TQT_TQOBJECT(m_view), TQT_SLOT(slotResultTreeReduce()), actionCollection(), "results_treereduce"); + (void)new TDEAction(i18n("Open Parent &Folder"), "go-up", 0, m_view, TQ_SLOT(slotResultDirOpen()), actionCollection(), "results_opendir"); + (void)new TDEAction(i18n("Remove &Entry"), "edit-clear", 0, m_view, TQ_SLOT(slotResultRemoveEntry()), actionCollection(), "results_removeentry"); + (void)new TDEAction(i18n("&Delete"), "edit-delete", 0, m_view, TQ_SLOT(slotResultDelete()), actionCollection(), "results_delete"); + (void)new TDEAction(i18n("E&xpand Tree"), 0, m_view, TQ_SLOT(slotResultTreeExpand()), actionCollection(), "results_treeexpand"); + (void)new TDEAction(i18n("&Reduce Tree"), 0, m_view, TQ_SLOT(slotResultTreeReduce()), actionCollection(), "results_treereduce"); // Help - (void)new TDEAction(i18n("&About TDEFileReplace"), "tdefilereplace", 0, TQT_TQOBJECT(this), TQT_SLOT(showAboutApplication()), actionCollection(), "help_about_tdefilereplace"); - (void)new TDEAction(i18n("TDEFileReplace &Handbook"), "help", 0, TQT_TQOBJECT(this), TQT_SLOT(appHelpActivated()), actionCollection(), "help_tdefilereplace"); - (void)new TDEAction(i18n("&Report Bug"), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(reportBug()), actionCollection(), "report_bug"); + (void)new TDEAction(i18n("&About TDEFileReplace"), "tdefilereplace", 0, this, TQ_SLOT(showAboutApplication()), actionCollection(), "help_about_tdefilereplace"); + (void)new TDEAction(i18n("TDEFileReplace &Handbook"), "help", 0, this, TQ_SLOT(appHelpActivated()), actionCollection(), "help_tdefilereplace"); + (void)new TDEAction(i18n("&Report Bug"), 0, 0, this, TQ_SLOT(reportBug()), actionCollection(), "report_bug"); } void TDEFileReplacePart::initView() @@ -904,7 +904,7 @@ void TDEFileReplacePart::fileReplace() // Avoids files that not match requirements if(!TDEFileReplaceLib::isAnAccessibleFile(d.canonicalPath(), fileName, m_option)) continue; - kapp->processEvents(); + tdeApp->processEvents(); if(m_option->m_backup) replaceAndBackup(d.canonicalPath(), fileName); else @@ -960,7 +960,7 @@ void TDEFileReplacePart::recursiveFileReplace(const TQString &directoryName, int TQFileInfo qi(filePath); m_view->displayScannedFiles(foldersNumber, filesNumber); - kapp->processEvents(); + tdeApp->processEvents(); // Replace recursively if "filePath" is a directory and we have not reached the max depth level if (qi.isDir()) @@ -1245,7 +1245,7 @@ void TDEFileReplacePart::fileSearch(const TQString& directoryName, const TQStrin TQFileInfo fileInfo(filePath+"/"+fileName); if(fileInfo.isDir()) continue; - kapp->processEvents(); + tdeApp->processEvents(); search(filePath, fileName); filesNumber++; m_view->displayScannedFiles(0, filesNumber); @@ -1297,7 +1297,7 @@ void TDEFileReplacePart::recursiveFileSearch(const TQString &directoryName, cons m_view->displayScannedFiles(foldersNumber, filesNumber); - kapp->processEvents(); + tdeApp->processEvents(); // Searchs recursively if "filePath" is a directory and we have not reached the max depth level if (fileInfo.isDir()) { |