RatbagdResolution: emit properties changed from resolution_set_active
This allows clients to respond to changes in the active resolution. It's
not the cleanest approach, but it works. To clean it up, we could cache
the changed resolutions and make sure to only emit the signal on those,
just as the FIXME already notes.
References
@@ -94,6 +94,12 @@ static int ratbagd_resolution_active_signal_cb(sd_bus *bus,
"b",
ratbag_resolution_is_active(lib_resolution));
+ (void) sd_bus_emit_properties_changed(bus,
+ resolution->path,
+ RATBAGD_NAME_ROOT ".Resolution",
+ "IsActive",
+ NULL);
+
return 0;
}
