diff options
author | Johannes Schickel | 2006-04-18 18:50:07 +0000 |
---|---|---|
committer | Johannes Schickel | 2006-04-18 18:50:07 +0000 |
commit | a9431edca2f5ed3a8e6753662822393755bc69e6 (patch) | |
tree | d3425dc1cef9efd1ad27a56c94852ec5b6e26a9a /gui/ThemeNew.cpp | |
parent | 1ae205a2412eb0503e2ed26245f653e7047af982 (diff) | |
download | scummvm-rg350-a9431edca2f5ed3a8e6753662822393755bc69e6.tar.gz scummvm-rg350-a9431edca2f5ed3a8e6753662822393755bc69e6.tar.bz2 scummvm-rg350-a9431edca2f5ed3a8e6753662822393755bc69e6.zip |
- Fixed popup widget for --force-1x-overlay with new theme
- adds support for highlightened popupwidgets
svn-id: r22012
Diffstat (limited to 'gui/ThemeNew.cpp')
-rw-r--r-- | gui/ThemeNew.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/gui/ThemeNew.cpp b/gui/ThemeNew.cpp index 51080d160f..60b160b03a 100644 --- a/gui/ThemeNew.cpp +++ b/gui/ThemeNew.cpp @@ -637,13 +637,18 @@ void ThemeNew::drawPopUpWidget(const Common::Rect &r, const Common::String &sel, (state == kStateDisabled) ? -30 : 256, start, end, _gradientFactors[kPopUpWidgetFactor]); const Graphics::Surface *arrow = surface(kWidgetArrow); - Common::Rect arrowRect(r.right - 4 - arrow->w, r.top + 4, r.right - 4, r.top + 4 + arrow->h); + + int yOff = r.height() / 2 - arrow->h; + if (yOff < 0) + yOff = 0; + + Common::Rect arrowRect(r.right - 4 - arrow->w, r.top + yOff, r.right - 4, r.top + yOff + arrow->h); arrowRect.clip(r); drawSurface(arrowRect, arrow, false, false, (state == kStateDisabled) ? -30 : 256); - arrowRect.top += arrow->h + 1; - arrowRect.bottom += arrow->h + 1; + arrowRect.top += arrow->h; + arrowRect.bottom += arrow->h; arrowRect.clip(r); drawSurface(arrowRect, arrow, true, false, (state == kStateDisabled) ? -30 : 256); |