diff options
author | monsta <[email protected]> | 2017-01-27 15:05:00 +0300 |
---|---|---|
committer | monsta <[email protected]> | 2017-01-27 15:05:00 +0300 |
commit | a97dea0d4b8e1f2a7682bc7787e5b66143695070 (patch) | |
tree | 85bb817709f4ef6de76456990893fa094b5ba440 | |
parent | 58cff7d1f9416f01e8bff7d93dd5a321fccf81b0 (diff) | |
download | mate-panel-a97dea0d4b8e1f2a7682bc7787e5b66143695070.tar.bz2 mate-panel-a97dea0d4b8e1f2a7682bc7787e5b66143695070.tar.xz |
[GTK+3] clock: fix runtime warning about invalid signal
port of 02b7511302cef8b527cbc45c1ac674ab28f2dc01 to mixed GTK+2/3 code
-rw-r--r-- | applets/clock/clock.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/applets/clock/clock.c b/applets/clock/clock.c index 17aeb172..35720bdf 100644 --- a/applets/clock/clock.c +++ b/applets/clock/clock.c @@ -1330,6 +1330,7 @@ do_not_eat_button_press (GtkWidget *widget, return FALSE; } +#if !GTK_CHECK_VERSION (3, 0, 0) /* Don't request smaller size then the last one we did, this avoids jumping when proportional fonts are used. We must take care to call "unfix_size" whenever options are changed or such where @@ -1346,6 +1347,7 @@ clock_size_request (GtkWidget *clock, GtkRequisition *req, gpointer data) req->width = cd->fixed_width; req->height = cd->fixed_height; } +#endif static void clock_update_text_gravity (GtkWidget *label) @@ -1428,9 +1430,12 @@ create_main_clock_label (ClockData *cd) GtkWidget *label; label = gtk_label_new (NULL); + +#if !GTK_CHECK_VERSION (3, 0, 0) g_signal_connect (label, "size_request", G_CALLBACK (clock_size_request), cd); +#endif g_signal_connect_swapped (label, "style_set", G_CALLBACK (unfix_size), cd); |