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
Plasma Workspace
Commits
07cf18a6
Commit
07cf18a6
authored
Nov 19, 2020
by
Alexander Lohnau
💬
Browse files
Reload KCM when entry was adopted
This solves the UI sync issues when using the adoption command.
CCBUG: 417983
parent
527dd737
Changes
3
Hide whitespace changes
Inline
Side-by-side
kcms/icons/main.cpp
View file @
07cf18a6
...
...
@@ -186,15 +186,12 @@ void IconModule::processPendingDeletions()
m_model
->
removeItemsPendingDeletion
();
}
void
IconModule
::
ghnsEntriesChanged
(
const
QQmlListReference
&
changedEntries
)
void
IconModule
::
ghnsEntriesChanged
()
{
if
(
changedEntries
.
count
()
==
0
)
{
return
;
}
// reload the display icontheme items
KIconTheme
::
reconfigure
();
KIconLoader
::
global
()
->
newIconLoader
();
m_model
->
load
();
load
();
QPixmapCache
::
clear
();
}
...
...
kcms/icons/main.h
View file @
07cf18a6
...
...
@@ -74,7 +74,7 @@ public:
void
load
()
override
;
void
save
()
override
;
Q_INVOKABLE
void
ghnsEntriesChanged
(
const
QQmlListReference
&
changedEntries
);
Q_INVOKABLE
void
ghnsEntriesChanged
();
Q_INVOKABLE
void
installThemeFromFile
(
const
QUrl
&
url
);
Q_INVOKABLE
QList
<
int
>
availableIconSizes
(
int
group
)
const
;
...
...
kcms/icons/package/contents/ui/main.qml
View file @
07cf18a6
...
...
@@ -262,7 +262,12 @@ KCM.GridViewKCM {
text
:
i18n
(
"
Get New Icons...
"
)
configFile
:
"
icons.knsrc
"
viewMode
:
NewStuff
.
Page
.
ViewMode
.
Preview
onChangedEntriesChanged
:
kcm
.
ghnsEntriesChanged
(
newStuffButton
.
changedEntries
);
Connections
{
target
:
newStuffButton
.
engine
.
engine
function
onSignalEntryEvent
(
entry
,
event
)
{
kcm
.
ghnsEntriesChanged
();
}
}
}
}
}
...
...
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