diff options
author | Edward Welbourne <edward.welbourne@qt.io> | 2020-07-23 13:54:47 +0200 |
---|---|---|
committer | Edward Welbourne <edward.welbourne@qt.io> | 2020-07-27 11:20:35 +0200 |
commit | 02c2c930f0874a8886cb0983606c38cb8b356cd7 (patch) | |
tree | 501d5fc16f2ba14f02bb27a75964ffe8993510d0 /tests/manual/windowflags | |
parent | 2059170b33ffb05b99d9a3e1e374eb5a4bce9163 (diff) |
Fix some compiler errors caused by bit-rot in manual tests
Two methods that have gone away or been renamed,
an enum that now doesn't support being assigned from int.
QTime should no longer be used as a timer.
Removed a test of deprecated code that's gone away.
Task-number: QTBUG-85700
Change-Id: Idc6d59542625d22b9937084411b54b0d8aa87f00
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'tests/manual/windowflags')
-rw-r--r-- | tests/manual/windowflags/controls.cpp | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/tests/manual/windowflags/controls.cpp b/tests/manual/windowflags/controls.cpp index b999a59abe..410b928299 100644 --- a/tests/manual/windowflags/controls.cpp +++ b/tests/manual/windowflags/controls.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2016 The Qt Company Ltd. +** Copyright (C) 2020 The Qt Company Ltd. ** Contact: https://www.qt.io/licensing/ ** ** This file is part of the test suite of the Qt Toolkit. @@ -72,7 +72,8 @@ HintControl::HintControl(QWidget *parent) connect(transparentForInputCheckBox, SIGNAL(clicked()), this, SLOT(slotCheckBoxChanged())); QGridLayout *layout = new QGridLayout(this); layout->setSpacing(0); - layout->setMargin(ControlLayoutMargin); + layout->setContentsMargins(ControlLayoutMargin, ControlLayoutMargin, + ControlLayoutMargin, ControlLayoutMargin); layout->addWidget(msWindowsFixedSizeDialogCheckBox, 0, 0); layout->addWidget(x11BypassWindowManagerCheckBox, 1, 0); layout->addWidget(framelessWindowCheckBox, 2, 0); @@ -171,7 +172,8 @@ WindowStateControl::WindowStateControl(QWidget *parent) { QHBoxLayout *layout = new QHBoxLayout(this); group->setExclusive(false); - layout->setMargin(ControlLayoutMargin); + layout->setContentsMargins(ControlLayoutMargin, ControlLayoutMargin, + ControlLayoutMargin, ControlLayoutMargin); group->addButton(restoreButton, Qt::WindowNoState); restoreButton->setEnabled(false); layout->addWidget(restoreButton); @@ -214,7 +216,8 @@ WindowStatesControl::WindowStatesControl(QWidget *parent) { QHBoxLayout *layout = new QHBoxLayout(this); layout->setSpacing(0); - layout->setMargin(ControlLayoutMargin); + layout->setContentsMargins(ControlLayoutMargin, ControlLayoutMargin, + ControlLayoutMargin, ControlLayoutMargin); connect(visibleCheckBox, SIGNAL(toggled(bool)), this, SIGNAL(changed())); layout->addWidget(visibleCheckBox); connect(activeCheckBox, SIGNAL(toggled(bool)), this, SIGNAL(changed())); @@ -280,7 +283,8 @@ TypeControl::TypeControl(QWidget *parent) group->setExclusive(true); QGridLayout *layout = new QGridLayout(this); layout->setSpacing(0); - layout->setMargin(ControlLayoutMargin); + layout->setContentsMargins(ControlLayoutMargin, ControlLayoutMargin, + ControlLayoutMargin, ControlLayoutMargin); group->addButton(windowRadioButton, Qt::Window); layout->addWidget(windowRadioButton, 0, 0); group->addButton(dialogRadioButton, Qt::Dialog); |