@@ -157,8 +157,9 @@ MenuXbe::MenuXbe(MenuNode* parent, std::string const& label, std::string const&
157157 updateScanningLabel ();
158158 XBEScanner::scanPath (
159159 remainingScanPaths.front (),
160- [this ](bool succeeded, std::list<XBEScanner::XBEInfo> const & items,
161- long long duration) { this ->onScanCompleted (succeeded, items, duration); });
160+ [this ](bool succeeded, std::list<XBEInfo> const & items, long long duration) {
161+ this ->onScanCompleted (succeeded, items, duration);
162+ });
162163 }
163164}
164165
@@ -221,7 +222,7 @@ void MenuXbe::updateScanningLabel() {
221222}
222223
223224void MenuXbe::onScanCompleted (bool succeeded,
224- std::list<XBEScanner:: XBEInfo> const & items,
225+ std::list<XBEInfo> const & items,
225226 long long duration) {
226227 (void )duration;
227228 std::string path = remainingScanPaths.front ();
@@ -239,8 +240,9 @@ void MenuXbe::onScanCompleted(bool succeeded,
239240 updateScanningLabel ();
240241 XBEScanner::scanPath (
241242 remainingScanPaths.front (),
242- [this ](bool succeeded, std::list<XBEScanner::XBEInfo> const & items,
243- long long duration) { this ->onScanCompleted (succeeded, items, duration); });
243+ [this ](bool succeeded, std::list<XBEInfo> const & items, long long duration) {
244+ this ->onScanCompleted (succeeded, items, duration);
245+ });
244246 return ;
245247 }
246248
@@ -251,7 +253,9 @@ void MenuXbe::createChildren() {
251253 std::vector<std::shared_ptr<MenuItem>> newChildren;
252254
253255 for (auto & info: discoveredItems) {
254- newChildren.push_back (std::make_shared<MenuLaunch>(info.name , info.path ));
256+ XPR0Image saveIcon;
257+ info.loadCompressedSaveGameIcon (saveIcon);
258+ newChildren.push_back (std::make_shared<MenuLaunch>(info.title , info.path , saveIcon));
255259 }
256260
257261 std::sort (begin (newChildren), end (newChildren),
@@ -288,8 +292,12 @@ void MenuXbe::createChildren() {
288292/* *****************************************************************************************
289293 MenuLaunch
290294******************************************************************************************/
291- MenuLaunch::MenuLaunch (std::string const & label, std::string const & path) :
292- MenuItem(label), path(path) {
295+ MenuLaunch::MenuLaunch (std::string const & label, std::string path) :
296+ MenuItem(label), path(std::move(path)), image() {
297+ }
298+
299+ MenuLaunch::MenuLaunch (std::string const & label, std::string path, XPR0Image image) :
300+ MenuItem(label), path(std::move(path)), image(std::move(image)) {
293301}
294302
295303MenuLaunch::~MenuLaunch () {
0 commit comments