mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-29 19:00:33 +02:00
allow new searches even if tags haven't loaded
fixes search buttons being enabled but not working until the tags list is loaded
This commit is contained in:
@@ -64,7 +64,7 @@ void * SearchModel::updateTagListT()
|
|||||||
void SearchModel::UpdateSaveList(int pageNumber, std::string query)
|
void SearchModel::UpdateSaveList(int pageNumber, std::string query)
|
||||||
{
|
{
|
||||||
//Threading
|
//Threading
|
||||||
if(!updateSaveListWorking && !updateTagListWorking)
|
if(!updateSaveListWorking)
|
||||||
{
|
{
|
||||||
lastQuery = query;
|
lastQuery = query;
|
||||||
lastError = "";
|
lastError = "";
|
||||||
@@ -84,7 +84,7 @@ void SearchModel::UpdateSaveList(int pageNumber, std::string query)
|
|||||||
selected.clear();
|
selected.clear();
|
||||||
notifySelectedChanged();
|
notifySelectedChanged();
|
||||||
|
|
||||||
if(GetShowTags() && !tagList.size())
|
if(GetShowTags() && !tagList.size() && !updateTagListWorking)
|
||||||
{
|
{
|
||||||
updateTagListFinished = false;
|
updateTagListFinished = false;
|
||||||
updateTagListWorking = true;
|
updateTagListWorking = true;
|
||||||
|
@@ -48,7 +48,7 @@ private:
|
|||||||
bool updateTagListWorking;
|
bool updateTagListWorking;
|
||||||
volatile bool updateTagListFinished;
|
volatile bool updateTagListFinished;
|
||||||
pthread_t updateTagListThread;
|
pthread_t updateTagListThread;
|
||||||
static void * updateTagListTHelper(void * obj);
|
static void * updateTagListTHelper(void * obj);
|
||||||
void * updateTagListT();
|
void * updateTagListT();
|
||||||
public:
|
public:
|
||||||
SearchModel();
|
SearchModel();
|
||||||
|
Reference in New Issue
Block a user