From b3741cd67cdd0c5cf5934be40716a63de71b0abc Mon Sep 17 00:00:00 2001 From: jacob1 Date: Sat, 29 Sep 2012 16:24:20 -0400 Subject: lock icon on unpublished saves diff --git a/src/client/Client.cpp b/src/client/Client.cpp index 051dfcd..1490f5f 100644 --- a/src/client/Client.cpp +++ b/src/client/Client.cpp @@ -1646,6 +1646,7 @@ std::vector * Client::SearchSaves(int start, int count, std::string q json::String tempUsername = savesArray[j]["Username"]; json::String tempName = savesArray[j]["Name"]; json::Number tempVersion = savesArray[j]["Version"]; + json::Boolean tempPublished = savesArray[j]["Published"]; SaveInfo * tempSaveInfo = new SaveInfo( tempID.Value(), tempDate.Value(), @@ -1655,6 +1656,7 @@ std::vector * Client::SearchSaves(int start, int count, std::string q tempName.Value() ); tempSaveInfo->Version = tempVersion.Value(); + tempSaveInfo->SetPublished(tempPublished); saveArray->push_back(tempSaveInfo); } } diff --git a/src/interface/SaveButton.cpp b/src/interface/SaveButton.cpp index bf91839..ef40c08 100644 --- a/src/interface/SaveButton.cpp +++ b/src/interface/SaveButton.cpp @@ -247,6 +247,11 @@ void SaveButton::Draw(const Point& screenPos) g->drawtext(x, y, "\xA6", 160, 70, 50, 255); } } + if (!save->GetPublished()) + { + g->drawtext(screenPos.X, screenPos.Y-2, "\xCD", 255, 255, 255, 255); + g->drawtext(screenPos.X, screenPos.Y-2, "\xCE", 212, 151, 81, 255); + } } if(file) { diff --git a/src/search/SearchModel.h b/src/search/SearchModel.h index c894090..9e93f05 100644 --- a/src/search/SearchModel.h +++ b/src/search/SearchModel.h @@ -37,7 +37,7 @@ private: void notifyShowOwnChanged(); void notifyShowFavouriteChanged(); - //Variables and methods for backgroun save request + //Variables and methods for background save request bool saveListLoaded; bool updateSaveListWorking; volatile bool updateSaveListFinished; -- cgit v0.9.2-21-gd62e