|
a/src/qtgui/rclmain_w.cpp |
|
b/src/qtgui/rclmain_w.cpp |
|
... |
|
... |
1230 |
return;
|
1230 |
return;
|
1231 |
}
|
1231 |
}
|
1232 |
if (rcldb->needUpdate(udi, sig)) {
|
1232 |
if (rcldb->needUpdate(udi, sig)) {
|
1233 |
QString msg =
|
1233 |
QString msg =
|
1234 |
tr("Index not up to date for this file. "
|
1234 |
tr("Index not up to date for this file. "
|
1235 |
"Refusing to risk showing the wrong entry.");
|
1235 |
"Refusing to risk showing the wrong entry. ");
|
1236 |
if (m_indexerState == IXST_NOTRUNNING) {
|
1236 |
bool ixnotact = (m_indexerState == IXST_NOTRUNNING);
|
|
|
1237 |
if (ixnotact) {
|
1237 |
msg += tr("Click Ok to update the "
|
1238 |
msg += tr("Click Ok to update the "
|
1238 |
"index for this file, then re-run the "
|
1239 |
"index for this file, then you will need to "
|
1239 |
"query when indexing is done. "
|
1240 |
"re-run the query when indexing is done. ");
|
1240 |
"Else, Cancel.");
|
|
|
1241 |
} else {
|
1241 |
} else {
|
1242 |
msg += tr("Indexer running so things should improve when "
|
1242 |
msg += tr("The indexer is running so things should "
|
1243 |
"it's done");
|
1243 |
"improve when it's done. ");
|
1244 |
}
|
1244 |
}
|
|
|
1245 |
msg += tr("Click Cancel to return to the list. "
|
|
|
1246 |
"Click Ignore to show the preview anyway. ");
|
|
|
1247 |
QMessageBox::StandardButtons bts =
|
|
|
1248 |
QMessageBox::Ignore | QMessageBox::Cancel;
|
|
|
1249 |
if (ixnotact)
|
|
|
1250 |
bts |= QMessageBox::Ok;
|
1245 |
int rep =
|
1251 |
int rep =
|
1246 |
QMessageBox::warning(0, tr("Warning"),
|
1252 |
QMessageBox::warning(0, tr("Warning"),
|
1247 |
msg,
|
1253 |
msg, bts,
|
1248 |
QMessageBox::Ok,
|
|
|
1249 |
(m_indexerState == IXST_NOTRUNNING) ?
|
|
|
1250 |
QMessageBox::Cancel :
|
1254 |
ixnotact? QMessageBox::Cancel :
|
1251 |
QMessageBox::NoButton,
|
|
|
1252 |
QMessageBox::NoButton);
|
1255 |
QMessageBox::NoButton);
|
1253 |
if (m_indexerState == IXST_NOTRUNNING &&
|
1256 |
if (m_indexerState == IXST_NOTRUNNING &&
|
1254 |
rep == QMessageBox::Ok) {
|
1257 |
rep == QMessageBox::Ok) {
|
1255 |
LOGDEB(("Requesting index update for %s\n",
|
1258 |
LOGDEB(("Requesting index update for %s\n",
|
1256 |
doc.url.c_str()));
|
1259 |
doc.url.c_str()));
|
1257 |
vector<Rcl::Doc> docs(1, doc);
|
1260 |
vector<Rcl::Doc> docs(1, doc);
|
1258 |
updateIdxForDocs(docs);
|
1261 |
updateIdxForDocs(docs);
|
1259 |
}
|
1262 |
}
|
|
|
1263 |
if (rep != QMessageBox::Ignore)
|
1260 |
return;
|
1264 |
return;
|
1261 |
}
|
1265 |
}
|
1262 |
}
|
1266 |
}
|
1263 |
}
|
1267 |
}
|
1264 |
// Do the zeitgeist thing
|
1268 |
// Do the zeitgeist thing
|
1265 |
zg_send_event(ZGSEND_PREVIEW, doc);
|
1269 |
zg_send_event(ZGSEND_PREVIEW, doc);
|