Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:13.2:Update
xfce4-panel-plugin-weather
xfce4-panel-plugin-weather-upower-0.99.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File xfce4-panel-plugin-weather-upower-0.99.patch of Package xfce4-panel-plugin-weather
From d51c1ea939ffeecac6f9f5cd136d35628b585e73 Mon Sep 17 00:00:00 2001 From: Eric Koegel <eric@xfce.org> Date: Tue, 3 Jun 2014 20:44:16 +0200 Subject: Support upower-0.99 (bug #10922). upower-0.99 changed from the "changed" signal to "notify" as well as the function signature. This patch adds that while still supporting the previous versions of upower. Index: xfce4-weather-plugin-0.8.3/panel-plugin/weather.c =================================================================== --- xfce4-weather-plugin-0.8.3.orig/panel-plugin/weather.c +++ xfce4-weather-plugin-0.8.3/panel-plugin/weather.c @@ -1484,8 +1484,14 @@ mi_click(GtkWidget *widget, #ifdef HAVE_UPOWER_GLIB static void +#if UP_CHECK_VERSION(0, 99, 0) upower_changed_cb(UpClient *client, + GParamSpec *pspec, plugin_data *data) +#else /* UP_CHECK_VERSION < 0.99 */ +upower_changed_cb(UpClient *client, + plugin_data *data) +#endif /* UP_CHECK_VERSION */ { gboolean on_battery, lid_closed; @@ -1512,7 +1518,7 @@ upower_changed_cb(UpClient *client, schedule_next_wakeup(data); } } -#endif +#endif /* HAVE_UPOWER_GLIB */ static void @@ -2090,10 +2096,16 @@ weather_construct(XfcePanelPlugin *plugi G_CALLBACK(xfceweather_show_about), data); #ifdef HAVE_UPOWER_GLIB - if (data->upower) - g_signal_connect(data->upower, "changed", - G_CALLBACK(upower_changed_cb), data); -#endif + if (data->upower) { +#if UP_CHECK_VERSION(0, 99, 0) + g_signal_connect (data->upower, "notify", + G_CALLBACK(upower_changed_cb), data); +#else /* UP_CHECK_VERSION < 0.99 */ + g_signal_connect (data->upower, "changed", + G_CALLBACK(upower_changed_cb), data); +#endif /* UP_CHECK_VERSION */ + } +#endif /* HAVE_UPOWER_GLIB */ /* call update handler updates */ update_handler(data);
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor