fix(tray): Fix glib assertion when old property value is missing
xembedsniproxy sets WindowId as 'i' instead of 'u' and DBus::Proxy ignores incorrectly typed value.
This commit is contained in:
parent
316a9be656
commit
afd291a566
|
@ -126,7 +126,7 @@ void Item::processUpdatedProperties(Glib::RefPtr<Gio::AsyncResult>& _result) {
|
||||||
for (const auto& [name, value] : properties) {
|
for (const auto& [name, value] : properties) {
|
||||||
Glib::VariantBase old_value;
|
Glib::VariantBase old_value;
|
||||||
proxy_->get_cached_property(old_value, name);
|
proxy_->get_cached_property(old_value, name);
|
||||||
if (!value.equal(old_value)) {
|
if (!old_value || !value.equal(old_value)) {
|
||||||
proxy_->set_cached_property(name, value);
|
proxy_->set_cached_property(name, value);
|
||||||
setProperty(name, const_cast<Glib::VariantBase&>(value));
|
setProperty(name, const_cast<Glib::VariantBase&>(value));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue