Skip to content

Commit

Permalink
UI|Client: Use the "Close" icon in various places
Browse files Browse the repository at this point in the history
The "Close" icon (x) is meant to invoke the roundness of the progress
indicator. The purpose is to add a visual distinction to potentially
destructive actions such as deleting, clearing, and unloading.
  • Loading branch information
skyjake committed Nov 26, 2014
1 parent d27032d commit c6481f4
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 5 deletions.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Expand Up @@ -64,7 +64,7 @@ group console {
}

group gameselection {
rule max.width { constant $= UNIT * 280 }
rule max.width { constant $= UNIT * 270 }
rule max.height { constant $= UNIT * 215 }
}

Expand Down
Expand Up @@ -286,8 +286,8 @@ DENG2_OBSERVES(App, GameChange)
container->add(close = new ButtonWidget);
container->add(profile = new ProfilePickerWidget(settings, tr("appearance")));

// close->setText(tr("Close"));
close->setImage(style().images().image("close"));
close->setImageColor(style().colors().colorf("altaccent"));
close->setOverrideImageSize(style().fonts().font("title").height().valuei());
close->setAction(new SignalAction(thisPublic, SLOT(close())));

Expand Down
3 changes: 2 additions & 1 deletion doomsday/client/src/ui/widgets/consolewidget.cpp
Expand Up @@ -345,7 +345,8 @@ ConsoleWidget::ConsoleWidget() : GuiWidget("console"), d(new Instance(this))
d->logMenu = new PopupMenuWidget;
d->logMenu->setAnchor(d->button->rule().midX(), d->button->rule().top());
d->logMenu->items()
<< new ui::ActionItem(tr("Clear Log"), new CommandAction("clear"))
<< new ui::ActionItem(style().images().image("close"), tr("Clear Log"),
new CommandAction("clear"))
<< new ui::ActionItem(tr("Show Full Log"), new SignalAction(this, SLOT(showFullLog())))
<< new ui::ActionItem(tr("Go to Latest"), new SignalAction(d->log, SLOT(scrollToBottom())))
<< new ui::ActionItem(tr("Copy Path to Clipboard"),
Expand Down
3 changes: 2 additions & 1 deletion doomsday/client/src/ui/widgets/profilepickerwidget.cpp
Expand Up @@ -133,7 +133,8 @@ void ProfilePickerWidget::openMenu()
<< new ActionItem(tr("Duplicate..."), new SignalAction(this, SLOT(duplicate())))
<< new ui::Item(Item::Separator)
<< new ActionItem(tr("Reset to Defaults..."), new SignalAction(this, SLOT(reset())))
<< new ActionItem(tr("Delete..."), new SignalAction(this, SLOT(remove())));
<< new ActionItem(style().images().image("close"), tr("Delete..."),
new SignalAction(this, SLOT(remove())));
add(d->menu);

ChildWidgetOrganizer const &org = d->menu->menu().organizer();
Expand Down
3 changes: 2 additions & 1 deletion doomsday/client/src/ui/widgets/taskbarwidget.cpp
Expand Up @@ -399,7 +399,8 @@ TaskBarWidget::TaskBarWidget() : GuiWidget("taskbar"), d(new Instance(this))
d->mainMenu->setAnchorAndOpeningDirection(d->logo->rule(), ui::Up);

// Game unloading confirmation submenu.
ui::SubmenuItem *unloadMenu = new ui::SubmenuItem(tr("Unload Game"), ui::Left);
ui::SubmenuItem *unloadMenu = new ui::SubmenuItem(style().images().image("close"),
tr("Unload Game"), ui::Left);
unloadMenu->items()
<< new ui::Item(ui::Item::Separator, tr("Really unload the game?"))
<< new ui::ActionItem(tr("Unload") + " " _E(b) + tr("(discard progress)"), new SignalAction(this, SLOT(unloadGame())))
Expand Down

0 comments on commit c6481f4

Please sign in to comment.