ui: fixes in project setup and indexing
* allow to ignore missing paths in project setup * button to remove missing paths in project setup * fixed progress dialog stays on empty project indexing * don't unblock ui between indexin steps
This commit is contained in:
@@ -148,7 +148,7 @@ void Project::load()
|
||||
}
|
||||
}
|
||||
|
||||
void Project::refresh(DialogView* dialogView, RefreshMode refreshMode)
|
||||
void Project::refresh(RefreshMode refreshMode, DialogView* dialogView)
|
||||
{
|
||||
if (m_state == PROJECT_STATE_NOT_LOADED)
|
||||
{
|
||||
@@ -274,7 +274,7 @@ void Project::refresh(DialogView* dialogView, RefreshMode refreshMode)
|
||||
}
|
||||
else
|
||||
{
|
||||
buildIndex(info);
|
||||
buildIndex(info, dialogView);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -296,11 +296,15 @@ RefreshInfo Project::getRefreshInfo(RefreshMode mode) const
|
||||
}
|
||||
}
|
||||
|
||||
void Project::buildIndex(const RefreshInfo& info)
|
||||
void Project::buildIndex(const RefreshInfo& info, DialogView* dialogView)
|
||||
{
|
||||
if (info.mode == REFRESH_NONE || (!info.filesToClear.size() && !info.filesToIndex.size()))
|
||||
{
|
||||
if (!m_hasGUI)
|
||||
if (m_hasGUI)
|
||||
{
|
||||
dialogView->hideDialogs();
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageFinishedParsing().dispatch();
|
||||
}
|
||||
@@ -312,6 +316,8 @@ void Project::buildIndex(const RefreshInfo& info)
|
||||
MessageStatus("Preparing Indexing", false, true).dispatch();
|
||||
MessageClearErrorCount().dispatch();
|
||||
|
||||
dialogView->showUnknownProgressDialog("Preparing Indexing", "Setting up Indexers");
|
||||
|
||||
if (info.mode == REFRESH_ALL_FILES)
|
||||
{
|
||||
m_storage->clear();
|
||||
@@ -426,6 +432,10 @@ void Project::buildIndex(const RefreshInfo& info)
|
||||
)
|
||||
);
|
||||
}
|
||||
else
|
||||
{
|
||||
dialogView->hideUnknownProgressDialog();
|
||||
}
|
||||
|
||||
taskSequential->addTask(std::make_shared<TaskFinishParsing>(m_storage.get(), m_storageCache));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user