Skip to content

Commit

Permalink
UI|Home: Added “Refresh” to the Packages column menu
Browse files Browse the repository at this point in the history
  • Loading branch information
skyjake committed Jan 14, 2017
1 parent b2dadec commit 5a87029
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions doomsday/apps/client/src/ui/home/packagescolumnwidget.cpp
Expand Up @@ -25,6 +25,7 @@
#include <de/CallbackAction>
#include <de/Config>
#include <de/DirectoryListDialog>
#include <de/FileSystem>
#include <de/Loop>
#include <de/Package>
#include <de/PopupMenuWidget>
Expand Down Expand Up @@ -95,9 +96,12 @@ DENG_GUI_PIMPL(PackagesColumnWidget)
});

// Column menu.
self().header().menuButton().setPopup([] (PopupButtonWidget const &) -> PopupWidget * {
self().header().menuButton().setPopup([this] (PopupButtonWidget const &) -> PopupWidget * {
auto *menu = new PopupMenuWidget;
menu->items() << new ui::SubwidgetItem(tr("Folders"), ui::Left, makePackageFoldersDialog);
menu->items()
<< new ui::ActionItem(/*style().images().image("refresh"), */tr("Refresh"),
new CallbackAction([this] () { packages->refreshPackages(); }))
<< new ui::SubwidgetItem(tr("Folders"), ui::Left, makePackageFoldersDialog);
return menu;
}, ui::Down);
}
Expand Down

0 comments on commit 5a87029

Please sign in to comment.