Skip to content

Commit

Permalink
UI|Client|ChoiceWidget: Choice popups are opaque
Browse files Browse the repository at this point in the history
ChoiceWidget's popup may already be over a couple of layers of widgets,
so making it fully opaque improves readability.

Todo for later: Blurring would also be ok.
  • Loading branch information
skyjake committed Aug 20, 2013
1 parent 3d49311 commit f16e47c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
4 changes: 4 additions & 0 deletions doomsday/client/data/defaultstyle.pack/colors.dei
Expand Up @@ -20,6 +20,10 @@ group label {
color dimaccent { rgb <0.85, 0.68, 0.34> }
}

group choice {
color popup { rgb $= gui.colorAlpha(background.rgb, 1.0) }
}

group progress {
group light {
color wheel { rgb <1.0, 1.0, 1.0, 0.5> }
Expand Down
6 changes: 4 additions & 2 deletions doomsday/client/src/ui/widgets/choicewidget.cpp
Expand Up @@ -72,13 +72,15 @@ DENG2_OBSERVES(ContextWidgetOrganizer, WidgetCreation)
self.setAction(new SignalAction(thisPublic, SLOT(openPopup())));

updateButtonWithSelection();

updateStyle();
}

void updateStyle()
{
// todo
// Popup background color.
Background bg = choices->background();
bg.solidFill = self.style().colors().colorf("choice.popup");
choices->set(bg);
}

void widgetCreatedForItem(GuiWidget &widget, ui::Item const &item)
Expand Down

0 comments on commit f16e47c

Please sign in to comment.