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
System Settings
Commits
f2605e1e
Commit
f2605e1e
authored
Jan 21, 2021
by
Fabian Vogt
Browse files
Fix headers missing for non-KCM modules
(cherry picked from commit
fbf85dcc
)
parent
cad2c981
Changes
1
Hide whitespace changes
Inline
Side-by-side
core/ModuleView.cpp
View file @
f2605e1e
...
...
@@ -443,17 +443,18 @@ void ModuleView::activeModuleChanged(KPageWidgetItem *current, KPageWidgetItem *
// We need to get the state of the now active module
stateChanged
();
KCModuleInfo
*
activeModuleInfo
=
activeModule
();
KCModuleProxy
*
activeModule
=
d
->
mPages
.
value
(
d
->
mPageWidget
->
currentPage
());
if
(
activeModule
)
{
if
(
activeModule
||
activeModuleInfo
)
{
// TODO: if we'll ever need statistics for kinfocenter modules, save them with an URL like "kinfo:"
if
(
d
->
mSaveStatistics
)
{
if
(
activeModule
&&
d
->
mSaveStatistics
)
{
KActivities
::
ResourceInstance
::
notifyAccessed
(
QUrl
(
QStringLiteral
(
"kcm:"
)
+
activeModule
->
moduleInfo
().
service
()
->
storageId
()),
QStringLiteral
(
"org.kde.systemsettings"
));
}
d
->
mCustomHeader
->
setText
(
activeModule
->
module
Info
().
moduleName
());
d
->
mCustomHeader
->
setText
(
activeModuleInfo
->
moduleName
());
const
bool
isQml
=
(
activeModule
->
realModule
()
&&
activeModule
->
realModule
()
->
inherits
(
"KCModuleQml"
));
const
bool
isQml
=
(
activeModule
&&
activeModule
->
realModule
()
&&
activeModule
->
realModule
()
->
inherits
(
"KCModuleQml"
));
d
->
mCustomHeader
->
setVisible
(
!
isQml
);
current
->
setHeaderVisible
(
!
isQml
);
...
...
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