diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2017-05-19 19:09:17 +0200 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2017-05-19 19:09:17 +0200 |
commit | ff83cfac10939ceba524c93d4e36f634f4bec805 (patch) | |
tree | d481913f2136bf04d2d1deb650e6bd084a531676 /plugingui/mainwindow.cc | |
parent | a3dc9bd19f976cbc84ba3d1a16c72257b42b28ba (diff) |
Make sure we don't resize to negative values.
Diffstat (limited to 'plugingui/mainwindow.cc')
-rw-r--r-- | plugingui/mainwindow.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugingui/mainwindow.cc b/plugingui/mainwindow.cc index 578af28..d98d335 100644 --- a/plugingui/mainwindow.cc +++ b/plugingui/mainwindow.cc @@ -99,7 +99,7 @@ void MainWindow::repaintEvent(RepaintEvent* repaintEvent) void MainWindow::sizeChanged(std::size_t width, std::size_t height) { - tabs.resize(width - 2 * 16, height); + tabs.resize(std::max((int)width - 2 * 16, 0), height); } void MainWindow::closeEventHandler() |