logic: reduced waiting time when interrupting indexer processes

* made multiprocess AST traversal interruptible again
* removed const variables that define sleep times for threads
This commit is contained in:
mlangkabel
2018-09-21 17:19:03 +02:00
parent 593e075399
commit 951256c07b
44 changed files with 244 additions and 187 deletions
+3 -6
View File
@@ -298,8 +298,7 @@ DatabasePolicy QtDialogView::finishedIndexingDialog(
while (!m_resultReady)
{
const int SLEEP_TIME_MS = 25;
std::this_thread::sleep_for(std::chrono::milliseconds(SLEEP_TIME_MS));
std::this_thread::sleep_for(std::chrono::milliseconds(25));
}
return policy;
@@ -338,8 +337,7 @@ int QtDialogView::confirm(const std::string& message, const std::vector<std::str
while (!m_resultReady)
{
const int SLEEP_TIME_MS = 25;
std::this_thread::sleep_for(std::chrono::milliseconds(SLEEP_TIME_MS));
std::this_thread::sleep_for(std::chrono::milliseconds(25));
}
return result;
@@ -378,8 +376,7 @@ int QtDialogView::confirm(const std::wstring& message, const std::vector<std::ws
while (!m_resultReady)
{
const int SLEEP_TIME_MS = 25;
std::this_thread::sleep_for(std::chrono::milliseconds(SLEEP_TIME_MS));
std::this_thread::sleep_for(std::chrono::milliseconds(25));
}
return result;