@@ -156,8 +156,9 @@ MenuXbe::MenuXbe(MenuNode* parent, std::string const& label, std::string const&
156156 updateScanningLabel ();
157157 XBEScanner::scanPath (
158158 remainingScanPaths.front (),
159- [this ](bool succeeded, std::list<XBEScanner::XBEInfo> const & items,
160- long long duration) { this ->onScanCompleted (succeeded, items, duration); });
159+ [this ](bool succeeded, std::list<XBEInfo> const & items, long long duration) {
160+ this ->onScanCompleted (succeeded, items, duration);
161+ });
161162 }
162163}
163164
@@ -220,7 +221,7 @@ void MenuXbe::updateScanningLabel() {
220221}
221222
222223void MenuXbe::onScanCompleted (bool succeeded,
223- std::list<XBEScanner:: XBEInfo> const & items,
224+ std::list<XBEInfo> const & items,
224225 long long duration) {
225226 (void )duration;
226227 std::string path = remainingScanPaths.front ();
@@ -237,8 +238,9 @@ void MenuXbe::onScanCompleted(bool succeeded,
237238 updateScanningLabel ();
238239 XBEScanner::scanPath (
239240 remainingScanPaths.front (),
240- [this ](bool succeeded, std::list<XBEScanner::XBEInfo> const & items,
241- long long duration) { this ->onScanCompleted (succeeded, items, duration); });
241+ [this ](bool succeeded, std::list<XBEInfo> const & items, long long duration) {
242+ this ->onScanCompleted (succeeded, items, duration);
243+ });
242244 return ;
243245 }
244246
@@ -249,7 +251,9 @@ void MenuXbe::createChildren() {
249251 std::vector<std::shared_ptr<MenuItem>> newChildren;
250252
251253 for (auto & info: discoveredItems) {
252- newChildren.push_back (std::make_shared<MenuLaunch>(info.name , info.path ));
254+ XPR0Image saveIcon;
255+ info.loadCompressedSaveGameIcon (saveIcon);
256+ newChildren.push_back (std::make_shared<MenuLaunch>(info.title , info.path , saveIcon));
253257 }
254258
255259 std::sort (begin (newChildren), end (newChildren),
@@ -285,8 +289,12 @@ void MenuXbe::createChildren() {
285289/* *****************************************************************************************
286290 MenuLaunch
287291******************************************************************************************/
288- MenuLaunch::MenuLaunch (std::string const & label, std::string const & path) :
289- MenuItem(label), path(path) {
292+ MenuLaunch::MenuLaunch (std::string const & label, std::string path) :
293+ MenuItem(label), path(std::move(path)), image() {
294+ }
295+
296+ MenuLaunch::MenuLaunch (std::string const & label, std::string path, XPR0Image image) :
297+ MenuItem(label), path(std::move(path)), image(std::move(image)) {
290298}
291299
292300MenuLaunch::~MenuLaunch () {
0 commit comments