Showing the changes to interface/src/scripting/SelectionScriptingInterface.cpp (1 of 4 files). Show all
Unified · Split
| @@ -71,6 +71,12 @@ bool SelectionScriptingInterface::removeFromSelectedItemsList(const QString& lis · 70 unmodified lines | ||
| 71 | 71 | return false; |
| 72 | 72 | } |
| 73 | 73 | |
| 74 | +bool SelectionScriptingInterface::clearSelectedItemsList(const QString& listName) { | |
| 75 | + _selectedItemsListMap.insert(listName, GameplayObjects()); | |
| 76 | + emit selectedItemsListChanged(listName); | |
| 77 | + return true; | |
| 78 | +} | |
| 79 | + | |
| 74 | 80 | template <class T> bool SelectionScriptingInterface::addToGameplayObjects(const QString& listName, T idToAdd) { |
| 75 | 81 | GameplayObjects currentList = _selectedItemsListMap.value(listName); |
| 76 | 82 | currentList.addToGameplayObjects(idToAdd); |