mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-11 05:26:24 +02:00
ThreadManager: Make TaskType a property of a Task.
This commit is contained in:
1 parent
f9bab64bdf
commit
8b5173350f
6 files changed
+30
-12
No files matched your search
@@ -340,6 +340,10 @@ public:
|
||||
info_->readyEvent.Notify();
|
||||
}
|
||||
|
||||
TaskType Type() const override {
|
||||
return TaskType::IO_BLOCKING;
|
||||
}
|
||||
|
||||
void Run() override {
|
||||
// An early-return will result in the destructor running, where we can set
|
||||
// flags like working and pending.
|
||||
@@ -738,7 +742,7 @@ std::shared_ptr<GameInfo> GameInfoCache::GetInfo(Draw::DrawContext *draw, const
|
||||
}
|
||||
|
||||
GameInfoWorkItem *item = new GameInfoWorkItem(gamePath, info);
|
||||
g_threadManager.EnqueueTask(item, TaskType::IO_BLOCKING);
|
||||
g_threadManager.EnqueueTask(item);
|
||||
|
||||
// Don't re-insert if we already have it.
|
||||
if (info_.find(pathStr) == info_.end())
|
||||
|
||||
Reference in new issue
Block a user