diff options
Diffstat (limited to 'src/undomanager.cpp')
-rw-r--r-- | src/undomanager.cpp | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/src/undomanager.cpp b/src/undomanager.cpp index 5869e4b..21b3364 100644 --- a/src/undomanager.cpp +++ b/src/undomanager.cpp @@ -21,7 +21,7 @@ #include "undomanager.h" #include <klocale.h> #include <kio/netaccess.h> -#include <qtimer.h> +#include <tqtimer.h> #include <assert.h> #include "dolphin.h" @@ -32,8 +32,8 @@ DolphinCommand::DolphinCommand() : m_type(Copy), m_macroIndex(-1) { - // Implementation note: DolphinCommands are stored in a QValueList, whereas - // QValueList requires a default constructor of the added class. + // Implementation note: DolphinCommands are stored in a TQValueList, whereas + // TQValueList requires a default constructor of the added class. // Instead of expressing this implementation detail to the interface by adding a // Type::Undefined just Type::Copy is used to assure that all members have // a defined state. @@ -84,7 +84,7 @@ void UndoManager::addCommand(const DolphinCommand& command) } emit undoAvailable(true); - emit undoTextChanged(i18n("Undo: %1").arg(commandText(command))); + emit undoTextChanged(i18n("Undo: %1").tqarg(commandText(command))); // prevent an endless growing of the Undo history if (m_historyIndex > 10000) { @@ -132,12 +132,12 @@ void UndoManager::undo() emit undoTextChanged(i18n("Undo")); } else { - emit undoTextChanged(i18n("Undo: %1").arg(commandText(m_history[m_historyIndex]))); + emit undoTextChanged(i18n("Undo: %1").tqarg(commandText(m_history[m_historyIndex]))); } if (m_historyIndex < static_cast<int>(m_history.count()) - 1) { emit redoAvailable(true); - emit redoTextChanged(i18n("Redo: %1").arg(commandText(command))); + emit redoTextChanged(i18n("Redo: %1").tqarg(commandText(command))); } else { emit redoAvailable(false); @@ -147,7 +147,7 @@ void UndoManager::undo() KURL::List sourceURLs = command.source(); KURL::List::Iterator it = sourceURLs.begin(); const KURL::List::Iterator end = sourceURLs.end(); - const QString destURL(command.destination().prettyURL(+1)); + const TQString destURL(command.destination().prettyURL(+1)); KIO::Job* job = 0; switch (command.type()) { @@ -185,7 +185,7 @@ void UndoManager::undo() while (it != end) { // TODO: use KIO::special for accessing the trash protocol. See // also Dolphin::slotJobResult() for further details. - const QString originalFileName((*it).filename().section('-', 1)); + const TQString originalFileName((*it).filename().section('-', 1)); KURL newDestURL(destURL + originalFileName); KIO::NetAccess::move(*it, newDestURL); ++it; @@ -205,8 +205,8 @@ void UndoManager::undo() if (job != 0) { // Execute the jobs in a synchronous manner and forward the progress // information to the Dolphin statusbar. - connect(job, SIGNAL(percent(KIO::Job*, unsigned long)), - this, SLOT(slotPercent(KIO::Job*, unsigned long))); + connect(job, TQT_SIGNAL(percent(KIO::Job*, unsigned long)), + this, TQT_SLOT(slotPercent(KIO::Job*, unsigned long))); KIO::NetAccess::synchronousRun(job, &Dolphin::mainWin()); } @@ -244,11 +244,11 @@ void UndoManager::redo() emit redoTextChanged(i18n("Redo")); } else { - emit redoTextChanged(i18n("Redo: %1").arg(commandText(m_history[m_historyIndex + 1]))); + emit redoTextChanged(i18n("Redo: %1").tqarg(commandText(m_history[m_historyIndex + 1]))); } emit undoAvailable(true); - emit undoTextChanged(i18n("Undo: %1").arg(commandText(command))); + emit undoTextChanged(i18n("Undo: %1").tqarg(commandText(command))); Dolphin& dolphin = Dolphin::mainWin(); @@ -275,11 +275,11 @@ void UndoManager::redo() } case DolphinCommand::Trash: { - const QString destURL(command.destination().prettyURL()); + const TQString destURL(command.destination().prettyURL()); while (it != end) { // TODO: use KIO::special for accessing the trash protocol. See // also Dolphin::slotJobResult() for further details. - const QString originalFileName((*it).filename().section('-', 1)); + const TQString originalFileName((*it).filename().section('-', 1)); KURL originalSourceURL(destURL + "/" + originalFileName); KIO::Job* moveToTrashJob = KIO::trash(originalSourceURL); KIO::NetAccess::synchronousRun(moveToTrashJob, &dolphin); @@ -309,8 +309,8 @@ void UndoManager::redo() if (job != 0) { // Execute the jobs in a synchronous manner and forward the progress // information to the Dolphin statusbar. - connect(job, SIGNAL(percent(KIO::Job*, unsigned long)), - this, SLOT(slotPercent(KIO::Job*, unsigned long))); + connect(job, TQT_SIGNAL(percent(KIO::Job*, unsigned long)), + this, TQT_SLOT(slotPercent(KIO::Job*, unsigned long))); KIO::NetAccess::synchronousRun(job, &dolphin); } @@ -338,9 +338,9 @@ UndoManager::~UndoManager() m_progressIndicator = 0; } -QString UndoManager::commandText(const DolphinCommand& command) const +TQString UndoManager::commandText(const DolphinCommand& command) const { - QString text; + TQString text; switch (command.type()) { case DolphinCommand::Copy: text = i18n("Copy"); break; case DolphinCommand::Move: text = i18n("Move"); break; @@ -358,7 +358,7 @@ void UndoManager::slotPercent(KIO::Job* /* job */, unsigned long /* percent */) { // It is not allowed to update the progress indicator in the context // of this slot, hence do an asynchronous triggering. - QTimer::singleShot(0, this, SLOT(updateProgress())); + TQTimer::singleShot(0, this, TQT_SLOT(updateProgress())); } void UndoManager::updateProgress() |