ui: Indexing UI

* Added DialogView with QtDialogView implementation to handle information dialogs
* Implemented QtIndexingDialog class that covers all different dialogs for indexing
* Directly communicate with DialogView from Prpject and all Tasks involved in indexing
* Block QtMainWindow UI while indexing
This commit is contained in:
Eberhard Graether
2016-08-23 23:45:45 +02:00
parent 377f0ef34f
commit 2c90b75a9f
70 changed files with 1565 additions and 375 deletions
+10 -8
View File
@@ -1,11 +1,11 @@
#include "data/parser/java/TaskParseJava.h"
#include "component/view/DialogView.h"
#include "data/parser/java/JavaParser.h"
#include "data/parser/ParserClientImpl.h"
#include "data/PersistentStorage.h"
#include "utility/file/FileRegister.h"
#include "utility/messaging/type/MessageFinishedParsing.h"
#include "utility/messaging/type/MessageStatus.h"
#include "utility/text/TextAccess.h"
#include "utility/utility.h"
@@ -13,12 +13,14 @@ TaskParseJava::TaskParseJava(
PersistentStorage* storage,
std::shared_ptr<std::mutex> storageMutex,
std::shared_ptr<FileRegister> fileRegister,
const Parser::Arguments& arguments
const Parser::Arguments& arguments,
DialogView* dialogView
)
: m_storage(storage)
, m_storageMutex(storageMutex)
, m_fileRegister(fileRegister)
, m_arguments(arguments)
, m_dialogView(dialogView)
{
}
@@ -38,12 +40,8 @@ Task::TaskState TaskParseJava::update()
return Task::STATE_FINISHED;
}
std::stringstream ss;
ss << "indexing files (ESC to quit): [";
ss << m_fileRegister->getParsedSourceFilesCount() << "/";
ss << m_fileRegister->getSourceFilesCount() << "] ";
ss << sourcePath.str();
MessageStatus(ss.str(), false, true).dispatch();
m_dialogView->updateIndexingDialog(
m_fileRegister->getParsedSourceFilesCount(), m_fileRegister->getSourceFilesCount(), sourcePath.str());
std::shared_ptr<IntermediateStorage> intermediateStorage = std::make_shared<IntermediateStorage>();
@@ -76,3 +74,7 @@ void TaskParseJava::interrupt()
void TaskParseJava::revert()
{
}
void TaskParseJava::abort()
{
}