aboutsummaryrefslogtreecommitdiff
path: root/gui/widget.cpp
diff options
context:
space:
mode:
authorAlexander Tkachev2016-07-12 22:37:57 +0600
committerAlexander Tkachev2016-07-12 22:37:57 +0600
commit64a79fd1ab4270ed50ef62cf0a795c842eb4d72a (patch)
tree4d7b9ff7ff40d55870a55890927874f7f999d395 /gui/widget.cpp
parent53ab0b28051eb346aa6a05c8c60e77d0f4cfa3cc (diff)
downloadscummvm-rg350-64a79fd1ab4270ed50ef62cf0a795c842eb4d72a.tar.gz
scummvm-rg350-64a79fd1ab4270ed50ef62cf0a795c842eb4d72a.tar.bz2
scummvm-rg350-64a79fd1ab4270ed50ef62cf0a795c842eb4d72a.zip
GUI: Fix TabWidget height issues
Changes theme stx files to specify TabWidget's type. That fixes wrong TabWidget height. Changes TabWidget's getHeight() to return not only "children" height, but also tabs height. That fixes wrong clipping area. Changes Widget's findWidget to use getHeight(). That fixes bug when widgets in the bottom of TabWidget were not reacting to the mouse events.
Diffstat (limited to 'gui/widget.cpp')
-rw-r--r--gui/widget.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/gui/widget.cpp b/gui/widget.cpp
index 32ca0223c5..f2a29c3100 100644
--- a/gui/widget.cpp
+++ b/gui/widget.cpp
@@ -156,7 +156,7 @@ void Widget::draw() {
Widget *Widget::findWidgetInChain(Widget *w, int x, int y) {
while (w) {
// Stop as soon as we find a widget that contains the point (x,y)
- if (x >= w->_x && x < w->_x + w->_w && y >= w->_y && y < w->_y + w->_h)
+ if (x >= w->_x && x < w->_x + w->_w && y >= w->_y && y < w->_y + w->getHeight())
break;
w = w->_next;
}