color-device: Rename signal "updated" to "calibration-changed"

The generic term updated can mean anything. This is specifically about
calibration related updates like changing the sink colorimetry
(Colorspace, HDR metadata) and changes to the white point for night
light etc.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3904>
This commit is contained in:
Sebastian Wick
2024-07-25 16:10:25 +02:00
parent f5ce2ddf3c
commit c123178f1c
4 changed files with 37 additions and 23 deletions

View File

@ -59,7 +59,7 @@
enum
{
DEVICE_UPDATED,
DEVICE_CALIBRATION_CHANGED,
READY,
N_SIGNALS
@ -120,10 +120,11 @@ on_device_ready (MetaColorDevice *color_device,
}
static void
on_device_updated (MetaColorDevice *color_device,
MetaColorManager *color_manager)
on_device_calibration_changed (MetaColorDevice *color_device,
MetaColorManager *color_manager)
{
g_signal_emit (color_manager, signals[DEVICE_UPDATED], 0, color_device);
g_signal_emit (color_manager, signals[DEVICE_CALIBRATION_CHANGED], 0,
color_device);
}
static char *
@ -204,8 +205,8 @@ update_devices (MetaColorManager *color_manager)
g_signal_connect_object (color_device, "ready",
G_CALLBACK (on_device_ready),
color_manager, 0);
g_signal_connect_object (color_device, "updated",
G_CALLBACK (on_device_updated),
g_signal_connect_object (color_device, "calibration-changed",
G_CALLBACK (on_device_calibration_changed),
color_manager, 0);
}
}
@ -499,8 +500,8 @@ meta_color_manager_class_init (MetaColorManagerClass *klass)
G_PARAM_STATIC_STRINGS);
g_object_class_install_properties (object_class, N_PROPS, obj_props);
signals[DEVICE_UPDATED] =
g_signal_new ("device-updated",
signals[DEVICE_CALIBRATION_CHANGED] =
g_signal_new ("device-calibration-changed",
G_TYPE_FROM_CLASS (klass),
G_SIGNAL_RUN_LAST, 0,
NULL, NULL, NULL,