ui: resize mod download dialog using its parents geometry

This commit is contained in:
flow 2022-04-15 08:27:40 -03:00
parent 5f15f51610
commit 8e9eca6a97

View File

@ -22,7 +22,9 @@ ModDownloadDialog::ModDownloadDialog(const std::shared_ptr<ModFolderModel> &mods
: QDialog(parent), mods(mods), m_instance(instance)
{
setObjectName(QStringLiteral("ModDownloadDialog"));
resize(400, 347);
resize(std::max(0.5*parent->width(), 400.0), std::max(0.75*parent->height(), 400.0));
m_verticalLayout = new QVBoxLayout(this);
m_verticalLayout->setObjectName(QStringLiteral("verticalLayout"));