summaryrefslogtreecommitdiff
path: root/src/frontend/cmoduleindexdialog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/frontend/cmoduleindexdialog.cpp')
-rw-r--r--src/frontend/cmoduleindexdialog.cpp29
1 files changed, 13 insertions, 16 deletions
diff --git a/src/frontend/cmoduleindexdialog.cpp b/src/frontend/cmoduleindexdialog.cpp
index d85e6b7..a32d1ea 100644
--- a/src/frontend/cmoduleindexdialog.cpp
+++ b/src/frontend/cmoduleindexdialog.cpp
@@ -7,27 +7,24 @@
*
**********/
-#include "cmoduleindexdialog.h"
+#include "frontend/cmoduleindexdialog.h"
-#include "util/cpointers.h"
+#include <QApplication>
+#include <QDebug>
+#include <QProgressDialog>
+#include <QString>
#include "backend/managers/cswordbackend.h"
+#include "util/cpointers.h"
+#include "util/dialogutil.h"
-#include <boost/scoped_ptr.hpp>
-
-//Qt includes
-#include <QString>
-#include <QProgressDialog>
-#include <QDebug>
-#include <QApplication>
-#include <QMessageBox>
CModuleIndexDialog* CModuleIndexDialog::getInstance() {
- qDebug("CModuleIndexDialog::getInstance");
+ qDebug() << "CModuleIndexDialog::getInstance";
static CModuleIndexDialog* instance = 0;
if (instance == 0) {
instance = new CModuleIndexDialog();
}
- qDebug("CModuleIndexDialog::getInstance end");
+ qDebug() << "CModuleIndexDialog::getInstance end";
return instance;
}
@@ -45,7 +42,7 @@ void CModuleIndexDialog::indexAllModules( const QList<CSwordModuleInfo*>& module
m_progress->raise();
foreach (CSwordModuleInfo* info, modules) {
- //TODO: how to cancel
+ /// \todo how to cancel
//QObject::connect(CPointers::backend(), SIGNAL(sigSwordSetupChanged()), this, SLOT(swordSetupChanged()));
connect(this, SIGNAL(sigCancel()), info, SLOT(cancelIndexing()) );
connect(m_progress, SIGNAL(canceled()), info, SLOT(cancelIndexing()));
@@ -54,7 +51,7 @@ void CModuleIndexDialog::indexAllModules( const QList<CSwordModuleInfo*>& module
QString modname(info->name());
const QString labelText = tr("Creating index for work: %1").arg(modname);
m_progress->setLabelText(labelText);
- //todo: if we want to cancel indexing from
+ /// \todo if we want to cancel indexing from
info->buildIndex(); //waits until this module is finished
m_currentModuleIndex++;
@@ -96,7 +93,7 @@ void CModuleIndexDialog::slotFinished( ) {
// Modules may be removed
void CModuleIndexDialog::slotSwordSetupChanged() {
- qDebug("CModuleIndexDialog::slotSwordSetupChanged, TODO: cancel if modules are removed");
- QMessageBox::information(0, tr("Indexing Is Cancelled"), tr("Indexing is cancelled because modules are removed."));
+ qDebug() << "CModuleIndexDialog::slotSwordSetupChanged"; /// \todo cancel if modules are removed
+ util::showInformation(0, tr("Indexing Is Cancelled"), tr("Indexing is cancelled because modules are removed."));
emit sigCancel();
}