mirror of
https://github.com/swaywm/sway.git
synced 2026-04-14 08:22:08 -04:00
Fix get_icon
Property reply functions are now notified if there was an error with the property instead of silent failure. Also issues in `get_item` were resolved.
This commit is contained in:
parent
87035380e3
commit
13b81f9fb9
4 changed files with 47 additions and 17 deletions
|
|
@ -38,7 +38,10 @@ static void register_host(char *name) {
|
|||
dbus_message_unref(message);
|
||||
}
|
||||
|
||||
static void get_items_reply(DBusMessageIter *iter, void *_data) {
|
||||
static void get_items_reply(DBusMessageIter *iter, void *_data, enum property_status status) {
|
||||
if (status != PROP_EXISTS) {
|
||||
return;
|
||||
}
|
||||
DBusMessageIter array;
|
||||
|
||||
// O(n) function, could be faster dynamically reading values
|
||||
|
|
@ -60,7 +63,10 @@ static void get_items_reply(DBusMessageIter *iter, void *_data) {
|
|||
}
|
||||
}
|
||||
}
|
||||
static void get_obj_items_reply(DBusMessageIter *iter, void *_data) {
|
||||
static void get_obj_items_reply(DBusMessageIter *iter, void *_data, enum property_status status) {
|
||||
if (status != PROP_EXISTS) {
|
||||
return;
|
||||
}
|
||||
DBusMessageIter array;
|
||||
DBusMessageIter dstruct;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue