diff options
author | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2018-06-04 16:21:32 +0200 |
---|---|---|
committer | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2018-06-25 13:01:14 +0000 |
commit | 92b3ef24ed35b405f50ac67b2e51e74eb384451b (patch) | |
tree | 8479aa5ac4b82cd92faf342736048af939b77e21 /tests/manual/windowgeometry | |
parent | f8944a7f07112c85dc4f66848cabb490514cd28e (diff) |
Fix window(child)geometry manual tests
Task-number: QTBUG-67632
Change-Id: I16482d3501cc7c7893d6eac4617c77dc70e1e215
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
Diffstat (limited to 'tests/manual/windowgeometry')
-rw-r--r-- | tests/manual/windowgeometry/controllerwidget.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/tests/manual/windowgeometry/controllerwidget.cpp b/tests/manual/windowgeometry/controllerwidget.cpp index 7620d2df56..b05ea2907e 100644 --- a/tests/manual/windowgeometry/controllerwidget.cpp +++ b/tests/manual/windowgeometry/controllerwidget.cpp @@ -256,7 +256,7 @@ private: WidgetWindowControl::WidgetWindowControl(QWidget *w ) : BaseWindowControl(w) - , m_statesControl(new WindowStatesControl(WindowStatesControl::WantVisibleCheckBox | WindowStatesControl::WantActiveCheckBox)) + , m_statesControl(new WindowStatesControl) { setTitle(w->windowTitle()); m_layout->addWidget(m_statesControl, 2, 0); @@ -354,34 +354,34 @@ private: virtual void setObjectWindowFlags(QObject *o, Qt::WindowFlags f) { static_cast<QWindow *>(o)->setFlags(f); } - WindowStateControl *m_stateControl; + WindowStatesControl *m_statesControl; }; WindowControl::WindowControl(QWindow *w ) : BaseWindowControl(w) - , m_stateControl(new WindowStateControl(WindowStateControl::WantVisibleCheckBox | WindowStateControl::WantMinimizeRadioButton)) + , m_statesControl(new WindowStatesControl) { setTitle(w->title()); QGroupBox *stateGroupBox = new QGroupBox(tr("State")); QVBoxLayout *l = new QVBoxLayout(stateGroupBox); - l->addWidget(m_stateControl); + l->addWidget(m_statesControl); m_layout->addWidget(stateGroupBox, 2, 0); - connect(m_stateControl, SIGNAL(changed()), this, SLOT(stateChanged())); + connect(m_statesControl, SIGNAL(changed()), this, SLOT(stateChanged())); } void WindowControl::refresh() { const QWindow *w = static_cast<const QWindow *>(m_object); BaseWindowControl::refresh(); - m_stateControl->setVisibleValue(w->isVisible()); - m_stateControl->setState(w->windowState()); + m_statesControl->setVisibleValue(w->isVisible()); + m_statesControl->setStates(w->windowStates()); } void WindowControl::stateChanged() { QWindow *w = static_cast<QWindow *>(m_object); - w->setVisible(m_stateControl->visibleValue()); - w->setWindowState(m_stateControl->state()); + w->setVisible(m_statesControl->visibleValue()); + w->setWindowStates(m_statesControl->states()); } #endif |