diff options
author | Cameron Cawley | 2019-10-15 20:37:28 +0100 |
---|---|---|
committer | Thierry Crozat | 2019-10-15 20:37:28 +0100 |
commit | 06b038a1c15d1486fc3466050391e12d22b5356a (patch) | |
tree | eb1b384b2d87e31ac0cd57a588f8aa21d33b75d8 /gui | |
parent | b8e7f45760d935af90588754cce6ab378adffb0c (diff) | |
download | scummvm-rg350-06b038a1c15d1486fc3466050391e12d22b5356a.tar.gz scummvm-rg350-06b038a1c15d1486fc3466050391e12d22b5356a.tar.bz2 scummvm-rg350-06b038a1c15d1486fc3466050391e12d22b5356a.zip |
GUI: Fix crash when clicking and dragging a tab widget
Diffstat (limited to 'gui')
-rw-r--r-- | gui/widgets/tab.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gui/widgets/tab.cpp b/gui/widgets/tab.cpp index 0305b57061..d373bc9222 100644 --- a/gui/widgets/tab.cpp +++ b/gui/widgets/tab.cpp @@ -221,7 +221,8 @@ void TabWidget::handleMouseDown(int x, int y, int button, int clickCount) { } void TabWidget::handleMouseMoved(int x, int y, int button) { - assert(y < _tabHeight); + if (y < 0 || y >= _tabHeight) + return; if (x < 0) return; |