Commit 063b95d9 authored by Eike Ziller's avatar Eike Ziller Committed by hjk

Use more descriptive progress bar titles

Change-Id: I70450a2aa675d69f820de48dd75909f36051efe0
Reviewed-by: Orgad Shaneh's avatarOrgad Shaneh <orgads@gmail.com>
Reviewed-by: default avatarDaniel Teske <daniel.teske@digia.com>
Reviewed-by: default avatarhjk <hjk121@nokiamail.com>
parent 8b93a0f7
......@@ -290,7 +290,7 @@ QFuture<void> ModelManagerInterface::refreshSourceFiles(const QStringList &sourc
m_synchronizer.addFuture(result);
if (sourceFiles.count() > 1)
addTaskInternal(result, tr("Indexing"), Constants::TASK_INDEX);
addTaskInternal(result, tr("Parsing QML Files"), Constants::TASK_INDEX);
if (sourceFiles.count() > 1 && !m_shouldScanImports) {
bool scan = false;
......@@ -1054,7 +1054,7 @@ void ModelManagerInterface::updateImportPaths()
m_synchronizer.addFuture(result);
addTaskInternal(result, tr("QML import scan"), Constants::TASK_IMPORT_SCAN);
addTaskInternal(result, tr("Scanning QML Imports"), Constants::TASK_IMPORT_SCAN);
}
}
......
......@@ -2062,7 +2062,7 @@ void ClearCasePlugin::updateIndex()
QFuture<void> result = QtConcurrent::run(&sync,
project->files(Project::ExcludeGeneratedFiles));
if (!m_settings.disableIndexer)
ProgressManager::addTask(result, tr("CC Indexing"), ClearCase::Constants::TASK_INDEX);
ProgressManager::addTask(result, tr("Updating ClearCase Index"), ClearCase::Constants::TASK_INDEX);
}
/*! retrieve a \a file (usually of the form path\to\filename.cpp@@\main\ver)
......
......@@ -257,7 +257,7 @@ void Locator::refresh(QList<ILocatorFilter *> filters)
filters = m_filters;
QFuture<void> task = QtConcurrent::run(&ILocatorFilter::refresh, filters);
FutureProgress *progress =
ProgressManager::addTask(task, tr("Indexing"), Core::Constants::TASK_INDEX);
ProgressManager::addTask(task, tr("Updating Locator Caches"), Core::Constants::TASK_INDEX);
connect(progress, SIGNAL(finished()), this, SLOT(saveSettings()));
}
......
......@@ -207,7 +207,7 @@ QFuture<void> BuiltinIndexingSupport::refreshSourceFiles(const QStringList &sour
m_synchronizer.addFuture(result);
if (mode == CppModelManagerInterface::ForcedProgressNotification || sourceFiles.count() > 1) {
Core::ProgressManager::addTask(result, QCoreApplication::translate("CppTools::Internal::BuiltinIndexingSupport", "Parsing"),
Core::ProgressManager::addTask(result, QCoreApplication::translate("CppTools::Internal::BuiltinIndexingSupport", "Parsing C/C++ Files"),
CppTools::Constants::TASK_INDEX);
}
......
......@@ -372,7 +372,7 @@ void CppFindReferences::findAll_helper(Core::SearchResult *search, CPlusPlus::Sy
result = QtConcurrent::run(&find_helper, workingCopy, context, this, symbol);
createWatcher(result, search);
FutureProgress *progress = ProgressManager::addTask(result, tr("Searching"),
FutureProgress *progress = ProgressManager::addTask(result, tr("Searching for Usages"),
CppTools::Constants::TASK_SEARCH);
connect(progress, SIGNAL(clicked()), search, SLOT(popup()));
......@@ -672,7 +672,7 @@ void CppFindReferences::findMacroUses(const Macro &macro, const QString &replace
result = QtConcurrent::run(&findMacroUses_helper, workingCopy, snapshot, this, macro);
createWatcher(result, search);
FutureProgress *progress = ProgressManager::addTask(result, tr("Searching"),
FutureProgress *progress = ProgressManager::addTask(result, tr("Searching for Usages"),
CppTools::Constants::TASK_SEARCH);
connect(progress, SIGNAL(clicked()), search, SLOT(popup()));
}
......
......@@ -147,7 +147,7 @@ void SymbolsFindFilter::startSearch(Core::SearchResult *search)
connect(watcher, SIGNAL(finished()),
symbolSearcher, SLOT(deleteLater()));
watcher->setFuture(QtConcurrent::run(&SymbolSearcher::runSearch, symbolSearcher));
FutureProgress *progress = ProgressManager::addTask(watcher->future(), tr("Searching"),
FutureProgress *progress = ProgressManager::addTask(watcher->future(), tr("Searching for Symbol"),
Core::Constants::TASK_SEARCH);
connect(progress, SIGNAL(clicked()), search, SLOT(popup()));
}
......
......@@ -489,7 +489,7 @@ void DebuggerEngine::startDebugger(DebuggerRunControl *runControl)
d->m_progress.setProgressRange(0, 1000);
FutureProgress *fp = ProgressManager::addTask(d->m_progress.future(),
tr("Launching"), "Debugger.Launcher");
tr("Launching Debugger"), "Debugger.Launcher");
fp->setKeepOnFinish(FutureProgress::HideOnFinish);
d->m_progress.reportStarted();
......
......@@ -322,7 +322,7 @@ QueryContext::~QueryContext()
void QueryContext::start()
{
Core::FutureProgress *fp = Core::ProgressManager::addTask(m_progress.future(), tr("Gerrit"),
Core::FutureProgress *fp = Core::ProgressManager::addTask(m_progress.future(), tr("Querying Gerrit"),
"gerrit-query");
fp->setKeepOnFinish(Core::FutureProgress::HideOnFinish);
m_progress.reportStarted();
......
......@@ -172,7 +172,7 @@ FetchContext::~FetchContext()
void FetchContext::start()
{
m_progress.setProgressRange(0, 2);
FutureProgress *fp = ProgressManager::addTask(m_progress.future(), tr("Gerrit Fetch"),
FutureProgress *fp = ProgressManager::addTask(m_progress.future(), tr("Fetching from Gerrit"),
"gerrit-fetch");
fp->setKeepOnFinish(FutureProgress::HideOnFinish);
m_progress.reportStarted();
......
......@@ -194,7 +194,7 @@ void SearchWidget::indexingStarted()
{
Q_ASSERT(!m_progress);
m_progress = new QFutureInterface<void>();
Core::ProgressManager::addTask(m_progress->future(), tr("Indexing"), "Help.Indexer");
Core::ProgressManager::addTask(m_progress->future(), tr("Indexing Documentation"), "Help.Indexer");
m_progress->setProgressRange(0, 2);
m_progress->setProgressValueAndText(1, tr("Indexing Documentation..."));
m_progress->reportStarted();
......
......@@ -901,7 +901,7 @@ bool SessionManager::loadSession(const QString &session)
if (fileName.toFileInfo().exists()) {
d->m_virginSession = false;
ProgressManager::addTask(d->m_future.future(), tr("Session"),
ProgressManager::addTask(d->m_future.future(), tr("Loading Session"),
"ProjectExplorer.SessionFile.Load");
d->m_future.setProgressRange(0, 1);
......
......@@ -514,7 +514,7 @@ void QbsProject::prepareForParsing()
m_qbsUpdateFutureInterface = new QFutureInterface<void>();
m_qbsUpdateFutureInterface->setProgressRange(0, 0);
ProgressManager::addTask(m_qbsUpdateFutureInterface->future(),
tr("Evaluating"), "Qbs.QbsEvaluate");
tr("Reading Project \"%1\"").arg(displayName()), "Qbs.QbsEvaluate");
m_qbsUpdateFutureInterface->reportStarted();
}
......
......@@ -840,8 +840,9 @@ void QmakeProject::asyncUpdate()
m_asyncUpdateFutureInterface = new QFutureInterface<void>();
m_asyncUpdateFutureInterface->setProgressRange(0, 0);
Core::ProgressManager::addTask(m_asyncUpdateFutureInterface->future(), tr("Evaluating"),
Constants::PROFILE_EVALUATE);
Core::ProgressManager::addTask(m_asyncUpdateFutureInterface->future(),
tr("Reading Project \"%1\"").arg(displayName()),
Constants::PROFILE_EVALUATE);
if (debug)
qDebug()<<" adding task";
......
......@@ -942,7 +942,7 @@ void FindReferences::displayResults(int first, int last)
Core::SearchResultWindow::instance()->popup(IOutputPane::Flags(IOutputPane::ModeSwitch | IOutputPane::WithFocus));
FutureProgress *progress = ProgressManager::addTask(
m_watcher.future(), tr("Searching"),
m_watcher.future(), tr("Searching for Usages"),
QmlJSEditor::Constants::TASK_SEARCH);
connect(progress, SIGNAL(clicked()), m_currentSearch, SLOT(popup()));
......
......@@ -1452,7 +1452,7 @@ void BaseQtVersion::buildDebuggingHelper(ToolChain *tc, int tools)
buildTask->showOutputOnError(true);
QFuture<void> task = QtConcurrent::run(&QtSupport::DebuggingHelperBuildTask::run, buildTask);
const QString taskName = QCoreApplication::translate("BaseQtVersion", "Building helpers");
const QString taskName = QCoreApplication::translate("BaseQtVersion", "Building Debugging Helpers");
ProgressManager::addTask(task, taskName, "Qt::BuildHelpers");
}
......
......@@ -326,7 +326,7 @@ void QmlDumpTool::pathAndEnvironment(Project *project, BaseQtVersion *version,
QmlDumpBuildTask *buildTask = new QmlDumpBuildTask(version, toolChain);
buildTask->updateProjectWhenDone(project, preferDebug);
QFuture<void> task = QtConcurrent::run(&QmlDumpBuildTask::run, buildTask);
const QString taskName = QmlDumpBuildTask::tr("Building helper");
const QString taskName = QmlDumpBuildTask::tr("Building QML Helpers");
Core::ProgressManager::addTask(task, taskName, "QmakeProjectManager::BuildHelpers");
}
return;
......
......@@ -448,7 +448,7 @@ void QtOptionsPageWidget::buildDebuggingHelper(DebuggingHelperBuildTask::Tools t
this, SLOT(debuggingHelperBuildFinished(int,QString,DebuggingHelperBuildTask::Tools)),
Qt::QueuedConnection);
QFuture<void> task = QtConcurrent::run(&DebuggingHelperBuildTask::run, buildTask);
const QString taskName = tr("Building helpers");
const QString taskName = tr("Building Helpers");
Core::ProgressManager::addTask(task, taskName, "QmakeProjectManager::BuildHelpers");
}
......
......@@ -182,7 +182,7 @@ void BaseFileFind::runSearch(Core::SearchResult *search)
ITextEditorDocument::openedTextDocumentContents()));
}
FutureProgress *progress =
ProgressManager::addTask(watcher->future(), tr("Search"), Constants::TASK_SEARCH);
ProgressManager::addTask(watcher->future(), tr("Searching"), Constants::TASK_SEARCH);
progress->setWidget(label);
progress->setStatusBarWidget(statusLabel);
connect(progress, SIGNAL(clicked()), search, SLOT(popup()));
......
......@@ -551,7 +551,7 @@ bool BaseTextDocument::open(QString *errorString, const QString &fileName, const
} else {
QFutureInterface<void> interface;
interface.setProgressRange(0, chunks);
ProgressManager::addTask(interface.future(), tr("Opening file"), Constants::TASK_OPEN_FILE);
ProgressManager::addTask(interface.future(), tr("Opening File"), Constants::TASK_OPEN_FILE);
interface.reportStarted();
d->m_document->setUndoRedoEnabled(false);
QTextCursor c(d->m_document);
......
......@@ -310,7 +310,8 @@ void Manager::registerMimeTypes()
connect(&m_registeringWatcher, SIGNAL(finished()), processor, SLOT(deleteLater()));
m_registeringWatcher.setFuture(future);
ProgressManager::addTask(future, tr("Registering definitions"), "TextEditor.Task.Register");
ProgressManager::addTask(future, tr("Registering Highlighting Definitions"),
"TextEditor.Task.Register");
} else {
m_hasQueuedRegistration = true;
m_registeringWatcher.cancel();
......@@ -443,7 +444,8 @@ void Manager::downloadDefinitions(const QList<QUrl> &urls, const QString &savePa
m_isDownloadingDefinitionsSpec = true;
QFuture<void> future = QtConcurrent::map(m_downloaders, DownloaderStarter());
m_downloadWatcher.setFuture(future);
ProgressManager::addTask(future, tr("Downloading definitions"), "TextEditor.Task.Download");
ProgressManager::addTask(future, tr("Downloading Highlighting Definitions"),
"TextEditor.Task.Download");
}
void Manager::downloadDefinitionsFinished()
......
......@@ -266,7 +266,7 @@ bool CleanDialog::promptToDelete()
Qt::QueuedConnection);
QFuture<void> task = QtConcurrent::run(cleanTask, &Internal::CleanFilesTask::run);
const QString taskName = tr("Cleaning %1").
const QString taskName = tr("Cleaning \"%1\"").
arg(QDir::toNativeSeparators(d->m_workingDirectory));
Core::ProgressManager::addTask(task, taskName, "VcsBase.cleanRepository");
return true;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment