Commit 36f4ff94 authored by Kai Uwe Broulik's avatar Kai Uwe Broulik 🍇
Browse files

[XWindowTasksModel] When name or visible name changed only update display role

The window name and user visible name are not used in the app identification heuristic, so a change here cannot result in the icon,
app id, app name, generic name, PID or launcher changing.

Differential Revision: https://phabricator.kde.org/D11096
parent 852f7481
......@@ -324,11 +324,16 @@ void XWindowTasksModel::Private::windowChanged(WId window, NET::Properties prope
bool wipeAppDataCache = false;
QVector<int> changedRoles;
if (properties & (NET::WMName | NET::WMVisibleName | NET::WMPid)
if (properties & (NET::WMPid)
|| properties2 & (NET::WM2DesktopFileName | NET::WM2WindowClass)) {
wipeInfoCache = true;
wipeAppDataCache = true;
changedRoles << Qt::DisplayRole << Qt::DecorationRole << AppId << AppName << GenericName << LauncherUrl << AppPid;
changedRoles << Qt::DecorationRole << AppId << AppName << GenericName << LauncherUrl << AppPid;
}
if (properties & (NET::WMName | NET::WMVisibleName)) {
changedRoles << Qt::DisplayRole;
wipeInfoCache = true;
}
if ((properties & NET::WMIcon) && usingFallbackIcon.contains(window)) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment