summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoryetist <[email protected]>2015-06-18 23:34:16 +0800
committerinfirit <[email protected]>2015-08-26 14:44:56 +0200
commit1112319594f210b0c6727d4657bc5b70de4168ab (patch)
tree4f642b4185ab6f691a25605cba64c86eb3745713
parentf3423b7e59b3dea7579cddb208ada0e2d671c6c3 (diff)
downloadmate-panel-1112319594f210b0c6727d4657bc5b70de4168ab.tar.bz2
mate-panel-1112319594f210b0c6727d4657bc5b70de4168ab.tar.xz
Gtk3: Don't use deprecated gtk_widget_reparent
-rw-r--r--mate-panel/panel-widget.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/mate-panel/panel-widget.c b/mate-panel/panel-widget.c
index 30e55f9c..9dd01d24 100644
--- a/mate-panel/panel-widget.c
+++ b/mate-panel/panel-widget.c
@@ -2816,7 +2816,12 @@ panel_widget_reparent (PanelWidget *old_panel,
panel_widget_reset_saved_focus (old_panel);
if (gtk_container_get_focus_child (GTK_CONTAINER (old_panel)) == applet)
focus_widget = gtk_window_get_focus (GTK_WINDOW (old_panel->toplevel));
+#if GTK_CHECK_VERSION(3, 14, 0)
+ gtk_container_remove (GTK_CONTAINER(old_panel), applet);
+ gtk_container_add (GTK_CONTAINER(new_panel), applet);
+#else
gtk_widget_reparent (applet, GTK_WIDGET (new_panel));
+#endif
if (info && info->type == PANEL_OBJECT_APPLET)
mate_panel_applet_frame_set_panel (MATE_PANEL_APPLET_FRAME (ad->applet), new_panel);