diff --git a/src/qtgui/rclmain_w.cpp b/src/qtgui/rclmain_w.cpp index a1d8f200..d90b5544 100644 --- a/src/qtgui/rclmain_w.cpp +++ b/src/qtgui/rclmain_w.cpp @@ -621,6 +621,10 @@ void RclMain::periodic100() if (status) { QMessageBox::warning(0, "Recoll", tr("Indexing failed")); + } else { + // On the first run, show missing helpers. We only do this once + if (m_firstIndexing) + showMissingHelpers(); } string reason; maybeOpenDb(reason, 1); @@ -713,6 +717,11 @@ void RclMain::toggleIndexing() break; case IXST_NOTRUNNING: { + // Could also mean that no helpers are missing, but then we + // won't try to show a message anyway (which is what + // firstIndexing is used for) + m_firstIndexing = theconfig->getMissingHelperDesc().empty(); + vector args; args.push_back("-c"); args.push_back(theconfig->getConfDir()); @@ -739,6 +748,10 @@ void RclMain::rebuildIndex() QMessageBox::Cancel, QMessageBox::NoButton); if (rep == QMessageBox::Ok) { + // Could also mean that no helpers are missing, but then we + // won't try to show a message anyway (which is what + // firstIndexing is used for) + m_firstIndexing = theconfig->getMissingHelperDesc().empty(); vector args; args.push_back("-c"); args.push_back(theconfig->getConfDir()); @@ -1058,13 +1071,18 @@ void RclMain::showAboutDialog() void RclMain::showMissingHelpers() { string miss = theconfig->getMissingHelperDesc(); - QString msg = tr("External applications/commands needed and not found " + QString msg = QString::fromAscii("

") + + tr("External applications/commands needed and not found " "for indexing your file types:\n\n"); + msg += "("; + msg += QString::fromLocal8Bit(theconfig->getConfDir().c_str()); + msg += "/missing):

\n";
     if (!miss.empty()) {
 	msg += QString::fromUtf8(miss.c_str());
     } else {
 	msg += tr("No helpers found missing");
     }
+    msg += "
"; QMessageBox::information(this, tr("Missing helper programs"), msg); } diff --git a/src/qtgui/rclmain_w.h b/src/qtgui/rclmain_w.h index 134accf2..b189ca9c 100644 --- a/src/qtgui/rclmain_w.h +++ b/src/qtgui/rclmain_w.h @@ -71,7 +71,8 @@ public: m_idxproc(0), m_sortspecnochange(false), m_indexerState(IXST_RUNNINGNOTMINE), - m_queryActive(false) + m_queryActive(false), + m_firstIndexing(false) { setupUi(this); init(); @@ -177,6 +178,7 @@ private: RefCntr m_source; IndexerState m_indexerState; bool m_queryActive; + bool m_firstIndexing; // If set on init, will be displayed either through ext app, or // preview (if no ext app set)