GUI: Account for the scroll bar size in ScrollContainerWidget objects
This commit is contained in:
parent
30bdbb6f76
commit
7ef8da53d7
9 changed files with 148 additions and 38 deletions
|
@ -166,7 +166,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->getHeight())
|
||||
if (x >= w->_x && x < w->_x + w->getWidth() && y >= w->_y && y < w->_y + w->getHeight())
|
||||
break;
|
||||
w = w->_next;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue