Reload menu items when a game is removed from the favourites list. Resort the list(s) when a game is added or removed from the favourites list.

This commit is contained in:
Pieter Hulshoff 2016-06-25 11:42:36 +02:00
parent da0fe6c299
commit ed07075360
2 changed files with 2 additions and 0 deletions

View File

@ -690,6 +690,7 @@ void Page::addPlaylist()
if(playlist_->first != "favorites" && std::find(items->begin(), items->end(), selectedItem_) == items->end())
{
items->push_back(selectedItem_);
collection->sortItems();
collection->saveRequest = true;
}
}

View File

@ -626,6 +626,7 @@ RetroFE::RETROFE_STATE RetroFE::processUserInput(Page *page)
if(input_.newKeyPressed(UserInput::KeyCodeRemovePlaylist))
{
page->removePlaylist();
page->onNewItemSelected();
page->reallocateMenuSpritePoints();
}
if(input_.newKeyPressed(UserInput::KeyCodeAddPlaylist))