diff --git a/app/src/toolbox.cpp b/app/src/toolbox.cpp index 731ade450..c74da9b48 100644 --- a/app/src/toolbox.cpp +++ b/app/src/toolbox.cpp @@ -169,8 +169,6 @@ void ToolBoxWidget::initUI() QSettings settings(PENCIL2D, PENCIL2D); restoreGeometry(settings.value("ToolBoxGeom").toByteArray()); - - ui->scrollArea->setMinimumHeight(getMinHeightForWidth(width())); } void ToolBoxWidget::updateUI() @@ -191,7 +189,7 @@ int ToolBoxWidget::getMinHeightForWidth(int width) if (mDockArea != Qt::LeftDockWidgetArea && mDockArea != Qt::RightDockWidgetArea) { return ui->scrollAreaWidgetContents_2->layout()->heightForWidth(width); } - return BaseDockWidget::getMinHeightForWidth(width); + return 1; } void ToolBoxWidget::onToolSetActive(ToolType toolType) diff --git a/app/src/toolbox.h b/app/src/toolbox.h index df31f2488..f2e6c6ece 100644 --- a/app/src/toolbox.h +++ b/app/src/toolbox.h @@ -68,7 +68,7 @@ public slots: Ui::ToolBoxWidget* ui = nullptr; - Qt::DockWidgetArea mDockArea; + Qt::DockWidgetArea mDockArea = Qt::DockWidgetArea::LeftDockWidgetArea; }; #endif