diff options
| author | jacob1 <jfu614@gmail.com> | 2012-12-18 17:20:52 (GMT) |
|---|---|---|
| committer | jacob1 <jfu614@gmail.com> | 2012-12-18 17:20:52 (GMT) |
| commit | c06afff0a572c34ea4da8b87670e21c67b9c06b7 (patch) | |
| tree | 95a251e1c2127a33f528a2194f451bfa5bfd30f1 /src/client/Client.cpp | |
| parent | 672c5ee9135fab6329f789c902f278329869b561 (diff) | |
| download | powder-c06afff0a572c34ea4da8b87670e21c67b9c06b7.zip powder-c06afff0a572c34ea4da8b87670e21c67b9c06b7.tar.gz | |
selecting a stamp moves it to the front of the list again (unless you hold ctrl)
attempted to do MVC right?
Diffstat (limited to 'src/client/Client.cpp')
| -rw-r--r-- | src/client/Client.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/client/Client.cpp b/src/client/Client.cpp index 0f9de28..4c7ac43 100644 --- a/src/client/Client.cpp +++ b/src/client/Client.cpp @@ -909,6 +909,20 @@ RequestStatus Client::UploadSave(SaveInfo & save) return RequestFailure; } +void Client::MoveStampToFront(std::string stampID) +{ + for (std::list<std::string>::iterator iterator = stampIDs.begin(), end = stampIDs.end(); iterator != end; ++iterator) + { + if((*iterator) == stampID) + { + stampIDs.erase(iterator); + break; + } + } + stampIDs.push_front(stampID); + updateStamps(); +} + SaveFile * Client::GetStamp(std::string stampID) { std::string stampFile = std::string(STAMPS_DIR PATH_SEP + stampID + ".stm"); |
