Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
PIM GrantleeTheme
Commits
4ea8c2c6
Commit
4ea8c2c6
authored
Nov 03, 2020
by
Laurent Montel
😁
Browse files
Modernize code (using auto)
parent
6689bf5a
Pipeline
#39389
passed with stage
in 8 minutes and 15 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
autotest/grantleethememanagertest.cpp
View file @
4ea8c2c6
...
...
@@ -71,14 +71,14 @@ void GrantleeThemeManagerTest::destructionOrderTest()
QCOMPARE
(
manager
->
themes
().
count
(),
2
);
QVERIFY
(
!
manager
->
actionForTheme
());
// Bug? No "default" theme.
QActionGroup
*
actionGroup
=
new
QActionGroup
(
this
);
auto
*
actionGroup
=
new
QActionGroup
(
this
);
manager
->
setActionGroup
(
actionGroup
);
KActionMenu
*
menu
=
new
KActionMenu
(
this
);
auto
*
menu
=
new
KActionMenu
(
this
);
manager
->
setThemeMenu
(
menu
);
QCOMPARE
(
menu
->
menu
()
->
actions
().
count
(),
4
);
// 2 themes + separator + download
KActionMenu
*
menu2
=
new
KActionMenu
(
this
);
auto
*
menu2
=
new
KActionMenu
(
this
);
manager
->
setThemeMenu
(
menu2
);
QCOMPARE
(
menu2
->
menu
()
->
actions
().
count
(),
4
);
...
...
src/grantleethememanager.cpp
View file @
4ea8c2c6
...
...
@@ -222,7 +222,7 @@ public:
void
slotThemeSelected
()
{
if
(
q
->
sender
())
{
KToggleAction
*
act
=
qobject_cast
<
KToggleAction
*>
(
q
->
sender
());
auto
*
act
=
qobject_cast
<
KToggleAction
*>
(
q
->
sender
());
selectTheme
(
act
);
Q_EMIT
q
->
grantleeThemeSelected
();
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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