diff options
Diffstat (limited to 'src/gpm-kbd-backlight.c')
-rw-r--r-- | src/gpm-kbd-backlight.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gpm-kbd-backlight.c b/src/gpm-kbd-backlight.c index a439e94..3a0f6e6 100644 --- a/src/gpm-kbd-backlight.c +++ b/src/gpm-kbd-backlight.c @@ -486,6 +486,9 @@ gpm_kbd_backlight_control_resume_cb (GpmControl *control, **/ static void gpm_kbd_backlight_client_changed_cb (UpClient *client, +#if UP_CHECK_VERSION(0, 99, 0) + GParamSpec *pspec, +#endif GpmKbdBacklight *backlight) { gpm_kbd_backlight_evaluate_power_source_and_set (backlight); @@ -755,8 +758,13 @@ noerr: /* Use upower for ac changed signal */ backlight->priv->client = up_client_new (); +#if UP_CHECK_VERSION(0, 99, 0) + g_signal_connect (backlight->priv->client, "notify", + G_CALLBACK (gpm_kbd_backlight_client_changed_cb), backlight); +#else g_signal_connect (backlight->priv->client, "changed", G_CALLBACK (gpm_kbd_backlight_client_changed_cb), backlight); +#endif backlight->priv->settings = g_settings_new (GPM_SETTINGS_SCHEMA); //g_signal_connect (backlight->priv->settings, "changed", G_CALLBACK (gpm_settings_key_changed_cb), backlight); |