mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-22 22:25:38 +00:00
Merge pull request #400 from Koerty/grid-fix-populateList
[GRID FIX] Update the populateList function of the GridGameListView
This commit is contained in:
commit
2ff3252b21
|
@ -51,9 +51,17 @@ bool GridGameListView::input(InputConfig* config, Input input)
|
|||
void GridGameListView::populateList(const std::vector<FileData*>& files)
|
||||
{
|
||||
mGrid.clear();
|
||||
for(auto it = files.cbegin(); it != files.cend(); it++)
|
||||
mHeaderText.setText(mRoot->getSystem()->getFullName());
|
||||
if (files.size() > 0)
|
||||
{
|
||||
mGrid.add((*it)->getName(), (*it)->getThumbnailPath(), *it);
|
||||
for (auto it = files.cbegin(); it != files.cend(); it++)
|
||||
{
|
||||
mGrid.add((*it)->getName(), (*it)->getThumbnailPath(), *it);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
addPlaceholder();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue