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
dtk
dtk-widgets
Commits
bf347488
Commit
bf347488
authored
Apr 08, 2020
by
LE BRETON Come
Browse files
Static cast is useless...
parent
ca8fc6ab
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/dtkWidgets/dtkWidgetsMainWindow.cpp
View file @
bf347488
...
...
@@ -94,7 +94,8 @@ dtkWidgetsMenu *dtkWidgetsMainWindow::populateThemesMenu(void)
d
->
menu_themes
=
d
->
menubar
->
addMenu
(
fa
::
paintbrush
,
"Themes"
);
auto
*
inner_menu_theme
=
d
->
menu_themes
->
addMenu
(
fa
::
paintbrush
,
"Choose Theme"
);
for
(
const
QString
theme
:
dtkThemesEngine
::
instance
()
->
themes
())
{
connect
(
static_cast
<
dtkWidgetsMenuItem
*>
(
inner_menu_theme
->
addItem
(
new
dtkWidgetsMenuItemTheme
(
theme
))),
&
dtkWidgetsMenuItem
::
clicked
,
[
=
]
(
void
)
->
void
{
dtkWidgetsMenuItem
*
item
=
inner_menu_theme
->
addItem
(
new
dtkWidgetsMenuItemTheme
(
theme
));
connect
(
item
,
&
dtkWidgetsMenuItem
::
clicked
,
[
=
]
()
{
dtkThemesEngine
::
instance
()
->
apply
(
theme
);
});
}
...
...
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