Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Plasma
KWin
Commits
16db84d4
Commit
16db84d4
authored
May 17, 2019
by
Laurent Montel
Browse files
Use QVariant::fromValue directly
parent
49e0cf53
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/wayland/autotests/client/test_plasma_window_model.cpp
View file @
16db84d4
...
...
@@ -861,29 +861,29 @@ void PlasmaWindowModelTest::testChangeWindowAfterModelDestroy_data()
QTest
::
addColumn
<
QVariant
>
(
"setter"
);
QTest
::
addColumn
<
QVariant
>
(
"value"
);
QTest
::
newRow
(
"active"
)
<<
&
PlasmaWindow
::
activeChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setActive
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"minimized"
)
<<
&
PlasmaWindow
::
minimizedChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setMinimized
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"fullscreen"
)
<<
&
PlasmaWindow
::
fullscreenChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setFullscreen
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"keepAbove"
)
<<
&
PlasmaWindow
::
keepAboveChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setKeepAbove
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"keepBelow"
)
<<
&
PlasmaWindow
::
keepBelowChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setKeepBelow
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"maximized"
)
<<
&
PlasmaWindow
::
maximizedChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setMaximized
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"demandsAttention"
)
<<
&
PlasmaWindow
::
demandsAttentionChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setDemandsAttention
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"closeable"
)
<<
&
PlasmaWindow
::
closeableChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setCloseable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"minimizeable"
)
<<
&
PlasmaWindow
::
minimizeableChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setMinimizeable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"maximizeable"
)
<<
&
PlasmaWindow
::
maximizeableChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setMaximizeable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"fullscreenable"
)
<<
&
PlasmaWindow
::
fullscreenableChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setFullscreenable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"skipTaskbar"
)
<<
&
PlasmaWindow
::
skipTaskbarChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setSkipTaskbar
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"shadeable"
)
<<
&
PlasmaWindow
::
shadeableChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setShadeable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"shaded"
)
<<
&
PlasmaWindow
::
shadedChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setShaded
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"movable"
)
<<
&
PlasmaWindow
::
movableChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setMovable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"resizable"
)
<<
&
PlasmaWindow
::
resizableChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setResizable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"vdChangeable"
)
<<
&
PlasmaWindow
::
virtualDesktopChangeableChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setVirtualDesktopChangeable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"onallDesktop"
)
<<
&
PlasmaWindow
::
onAllDesktopsChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setOnAllDesktops
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"title"
)
<<
&
PlasmaWindow
::
titleChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setTitle
)
<<
QVariant
(
QStringLiteral
(
"foo"
));
QTest
::
newRow
(
"appId"
)
<<
&
PlasmaWindow
::
appIdChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setAppId
)
<<
QVariant
(
QStringLiteral
(
"foo"
));
QTest
::
newRow
(
"icon"
)
<<
&
PlasmaWindow
::
iconChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setThemedIconName
)
<<
QVariant
(
QStringLiteral
(
"foo"
));
QTest
::
newRow
(
"vd"
)
<<
&
PlasmaWindow
::
virtualDesktopChanged
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
setVirtualDesktop
)
<<
QVariant
(
2u
);
QTest
::
newRow
(
"unmapped"
)
<<
&
PlasmaWindow
::
unmapped
<<
q
Variant
F
romValue
(
&
PlasmaWindowInterface
::
unmap
)
<<
QVariant
();
QTest
::
newRow
(
"active"
)
<<
&
PlasmaWindow
::
activeChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setActive
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"minimized"
)
<<
&
PlasmaWindow
::
minimizedChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setMinimized
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"fullscreen"
)
<<
&
PlasmaWindow
::
fullscreenChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setFullscreen
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"keepAbove"
)
<<
&
PlasmaWindow
::
keepAboveChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setKeepAbove
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"keepBelow"
)
<<
&
PlasmaWindow
::
keepBelowChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setKeepBelow
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"maximized"
)
<<
&
PlasmaWindow
::
maximizedChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setMaximized
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"demandsAttention"
)
<<
&
PlasmaWindow
::
demandsAttentionChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setDemandsAttention
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"closeable"
)
<<
&
PlasmaWindow
::
closeableChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setCloseable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"minimizeable"
)
<<
&
PlasmaWindow
::
minimizeableChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setMinimizeable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"maximizeable"
)
<<
&
PlasmaWindow
::
maximizeableChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setMaximizeable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"fullscreenable"
)
<<
&
PlasmaWindow
::
fullscreenableChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setFullscreenable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"skipTaskbar"
)
<<
&
PlasmaWindow
::
skipTaskbarChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setSkipTaskbar
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"shadeable"
)
<<
&
PlasmaWindow
::
shadeableChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setShadeable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"shaded"
)
<<
&
PlasmaWindow
::
shadedChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setShaded
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"movable"
)
<<
&
PlasmaWindow
::
movableChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setMovable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"resizable"
)
<<
&
PlasmaWindow
::
resizableChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setResizable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"vdChangeable"
)
<<
&
PlasmaWindow
::
virtualDesktopChangeableChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setVirtualDesktopChangeable
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"onallDesktop"
)
<<
&
PlasmaWindow
::
onAllDesktopsChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setOnAllDesktops
)
<<
QVariant
(
true
);
QTest
::
newRow
(
"title"
)
<<
&
PlasmaWindow
::
titleChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setTitle
)
<<
QVariant
(
QStringLiteral
(
"foo"
));
QTest
::
newRow
(
"appId"
)
<<
&
PlasmaWindow
::
appIdChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setAppId
)
<<
QVariant
(
QStringLiteral
(
"foo"
));
QTest
::
newRow
(
"icon"
)
<<
&
PlasmaWindow
::
iconChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setThemedIconName
)
<<
QVariant
(
QStringLiteral
(
"foo"
));
QTest
::
newRow
(
"vd"
)
<<
&
PlasmaWindow
::
virtualDesktopChanged
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
setVirtualDesktop
)
<<
QVariant
(
2u
);
QTest
::
newRow
(
"unmapped"
)
<<
&
PlasmaWindow
::
unmapped
<<
Q
Variant
::
f
romValue
(
&
PlasmaWindowInterface
::
unmap
)
<<
QVariant
();
}
void
PlasmaWindowModelTest
::
testChangeWindowAfterModelDestroy
()
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment