From 7a3c0a1eed449a0418221a349bbf2b5a2fc63693 Mon Sep 17 00:00:00 2001 From: David Capello Date: Tue, 7 Apr 2015 11:29:36 -0300 Subject: [PATCH] Minor fixes in style for ButtonSet and StatusBar controls (mini Entry/Slider) --- data/skins/default/sheet.png | Bin 12693 -> 12607 bytes src/app/ui/button_set.cpp | 24 +++++++++++++++++++----- src/ui/graphics.cpp | 9 +++++++++ src/ui/graphics.h | 1 + src/ui/widget.cpp | 2 +- 5 files changed, 30 insertions(+), 6 deletions(-) diff --git a/data/skins/default/sheet.png b/data/skins/default/sheet.png index 983a538e35e7735654dc1e88cf51b4ef401eba6c..ec2cad03030c68fbf4c226814cc63a27a75695b7 100644 GIT binary patch literal 12607 zcmW+-bzGBQ7ayI{9nw9zTX1yO7^6pr64DZibR#fY1SEvf9fEXBIt{u*Qo7##-aoc| zw$HtL?(TE$Io~*o)z?*fhEInN005q8sDlgv05l-#0l>vZeS$}>B?SO512jNN#sPVM z^H(Yv7czDhh_0AucHhhW=xfau##q9m`K7w^PB~9*%Wqo!wCT=e)k?#!7W9Q$`tOU3 zl1ighDN+nWw)n+cFWXOK8mU?A3&eekI+$er-!9VZuQT;{f2LAMk~a&jr>lv8k}w9GtR^go6DyieTqn4>x0f`4pUa< z$m@1DO>F?EzaCiCCrCvQuycHD9^HMpA%A^_6s+n~e7ZkB={f!cjSkzm@yziHpZs~rYz9xP;>E4g)f&kwMV;@|!6E#=}C zcCp0uXfa$*sIwrA6yc6jzAM{Fp^Uv(59S9e&wU^SsKGemsBuUSaLlRrbVJXdBLqI7 z0i0tqiGJgB0kyV1?4O;CpDHEC{J{i=_>*EEoS4B+J%7~3t{G>o&$~e2Sd@Wnd9sDf zIW}kv@o-IqltrWV7`Fga0+zuW1Mvv_lx&&DLdxX6bR}SaN_xe^6W41me=79D{(WR` zBtD@3Ht}N?85)QZC;@;l_Uff>eP4 zfLdr3bP0`->iLwCSPvOLU%qoJJVUn;gmjH7a@a5a4R8mw@g?lFUP9mwO*Fe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GENHufX%NhR_5m# zUqa{7%FeyO4n~UsXU-BFDPl)9(~_{DSu0!ISu6gx6gP>Zzm7+f9oS+frCH;iha+7` zOdxu>KSHdGv3Lmh=~F|ewiqC_{xc`arC^g~`TgV|s-0h9W=+M1Sx>~?6cd|&^bBgX zuy>|=KG5oqjW)*4^>aeIh@ADUW{b%Lf~b<>4-6`+*dTxf5B0Lw{PWkETwTuq|9Km# zNTra!SS9EL62A>{)_RvI^M#2h8}S)*+2~07`v|Q)$pR#@+r7JQgqBCBR2tu(AEy)` zD$5z~u0)zl#OvJfnebFoG>7g3W@u8H<|#VDwu-;-a~;bJ{pub<)GSn|jA=98eIfU! z->NDnhEq%t{V`z&)vK8L0pofx$9`0sr;Zykgg+`B75b11JXO<(2f;dYayFicJgAik z+eGk;=|tA~ytWjVN|Z(fu9@fillRect(getBgColor(), g->getClipBounds()); if (isSelected() || hasMouseOver()) { - nw = PART_TOOLBUTTON_HOT_NW; - face = theme->colors.buttonHotFace(); + if (hasCapture()) { + nw = PART_TOOLBUTTON_PUSHED_NW; + face = theme->colors.buttonSelectedFace(); + } + else { + nw = PART_TOOLBUTTON_HOT_NW; + face = theme->colors.buttonHotFace(); + } } else { nw = PART_TOOLBUTTON_LAST_NW; @@ -85,9 +91,13 @@ void ButtonSet::Item::onPaint(ui::PaintEvent& ev) theme->draw_bounds_nw(g, rc, nw, face); if (m_icon) { - g->drawRgbaSurface(m_icon, - rc.x + rc.w/2 - m_icon->width()/2, - rc.y + rc.h/2 - m_icon->height()/2 - 1*guiscale()); + int u = rc.x + rc.w/2 - m_icon->width()/2; + int v = rc.y + rc.h/2 - m_icon->height()/2 - 1*guiscale(); + + if (isSelected() && hasCapture()) + g->drawColoredRgbaSurface(m_icon, theme->colors.buttonSelectedText(), u, v); + else + g->drawRgbaSurface(m_icon, u, v); } } @@ -98,6 +108,8 @@ bool ButtonSet::Item::onProcessMessage(ui::Message* msg) case ui::kMouseDownMessage: captureMouse(); buttonSet()->setSelectedItem(this); + invalidate(); + if (!buttonSet()->m_triggerOnMouseUp) buttonSet()->onItemChange(); break; @@ -105,6 +117,8 @@ bool ButtonSet::Item::onProcessMessage(ui::Message* msg) case ui::kMouseUpMessage: if (hasCapture()) { releaseMouse(); + invalidate(); + if (buttonSet()->m_triggerOnMouseUp) buttonSet()->onItemChange(); } diff --git a/src/ui/graphics.cpp b/src/ui/graphics.cpp index a0be1c08a..475679fb4 100644 --- a/src/ui/graphics.cpp +++ b/src/ui/graphics.cpp @@ -11,6 +11,7 @@ #include "ui/graphics.h" #include "base/string.h" +#include "gfx/clip.h" #include "gfx/point.h" #include "gfx/rect.h" #include "gfx/region.h" @@ -148,6 +149,14 @@ void Graphics::drawRgbaSurface(she::Surface* surface, int x, int y) dst->drawRgbaSurface(src, m_dx+x, m_dy+y); } +void Graphics::drawColoredRgbaSurface(she::Surface* surface, gfx::Color color, int x, int y) +{ + she::ScopedSurfaceLock src(surface); + she::ScopedSurfaceLock dst(m_surface); + dst->drawColoredRgbaSurface(src, color, gfx::ColorNone, + gfx::Clip(m_dx+x, m_dy+y, 0, 0, surface->width(), surface->height())); +} + void Graphics::blit(she::Surface* srcSurface, int srcx, int srcy, int dstx, int dsty, int w, int h) { she::ScopedSurfaceLock src(srcSurface); diff --git a/src/ui/graphics.h b/src/ui/graphics.h index 57b18c3a4..47013fba0 100644 --- a/src/ui/graphics.h +++ b/src/ui/graphics.h @@ -67,6 +67,7 @@ namespace ui { void drawSurface(she::Surface* surface, int x, int y); void drawRgbaSurface(she::Surface* surface, int x, int y); + void drawColoredRgbaSurface(she::Surface* surface, gfx::Color color, int x, int y); void blit(she::Surface* src, int srcx, int srcy, int dstx, int dsty, int w, int h); diff --git a/src/ui/widget.cpp b/src/ui/widget.cpp index c4b47e994..91fac1ff8 100644 --- a/src/ui/widget.cpp +++ b/src/ui/widget.cpp @@ -1263,7 +1263,7 @@ void Widget::offerCapture(ui::MouseMessage* mouseMsg, int widget_type) { if (hasCapture()) { Widget* pick = getManager()->pick(mouseMsg->position()); - if (pick && pick->getType() == widget_type) { + if (pick && pick != this && pick->getType() == widget_type) { releaseMouse(); MouseMessage* mouseMsg2 = new MouseMessage(