task: massively simplified task system

Made various changes and fixes to the task system:

- Tasks are built around QtConcurrent rather than QThread. Reduces
  code complexity significantly.
- Task error reporting is now streamlined in both TaskManager and
  TaskDialog.
- Moved ProjectImport/Save/LoadManager to the app/task folder
This commit is contained in:
itsmattkc
2020-05-19 02:44:32 +10:00
parent c4b0a53174
commit b9cd83eff1
49 changed files with 864 additions and 1332 deletions
+2 -12
View File
@@ -29,7 +29,6 @@
#include "dialog/actionsearch/actionsearch.h"
#include "dialog/task/task.h"
#include "panel/panelmanager.h"
#include "task/cache/cache.h"
#include "tool/tool.h"
#include "ui/style/style.h"
#include "undo/undostack.h"
@@ -613,21 +612,12 @@ void MainMenu::OpenRecentItemTriggered()
void MainMenu::SequenceCacheTriggered()
{
TimeBasedPanel* p = PanelManager::instance()->MostRecentlyFocused<TimeBasedPanel>();
if (p && p->GetConnectedViewer()) {
// FIXME: Hardcoded divider...
// FIXME: Consider preventing caching the footage viewer
CacheTask* task = new CacheTask(p->GetConnectedViewer(), 2, false);
TaskDialog* dialog = new TaskDialog(task, tr("Caching Sequence"), parentWidget());
dialog->open();
}
Core::instance()->CacheActiveSequence(false);
}
void MainMenu::SequenceCacheInOutTriggered()
{
qDebug() << "STUB";
Core::instance()->CacheActiveSequence(true);
}
void MainMenu::Retranslate()