cache: better implemented changing disk cache folders

Not complete yet, but getting there.
This commit is contained in:
itsmattkc
2020-08-07 02:31:46 +10:00
parent 00d84cfda0
commit df14c2aaa7
33 changed files with 701 additions and 431 deletions
+5 -1
View File
@@ -25,6 +25,7 @@
#include <memory>
#include "render/colormanager.h"
#include "render/diskmanager.h"
#include "project/item/folder/folder.h"
#include "window/mainwindow/mainwindowlayoutinfo.h"
@@ -71,7 +72,10 @@ public:
bool is_new() const;
const QString& cache_path() const {
const QString& cache_path(bool default_if_empty = true) const {
if (cache_path_.isEmpty() && default_if_empty) {
return DiskManager::instance()->GetDefaultCachePath();
}
return cache_path_;
}