From 0819a3d1982403935eb70b958ad515494d1b9a0a Mon Sep 17 00:00:00 2001 From: Jasmine Hassan Date: Thu, 18 Oct 2012 22:52:00 +0200 Subject: [lc-p/fm] Replace deprecated GDK_DISPLAY with GDK_DISPLAY_XDISPLAY Don't use GDK_DISPLAY () http://git.gnome.org/browse/nautilus/commit/?id=b66ce0fd23500f9727c1aac93366430285575697 --- libcaja-private/caja-autorun.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libcaja-private/caja-autorun.c') diff --git a/libcaja-private/caja-autorun.c b/libcaja-private/caja-autorun.c index cf801b08..d78f402d 100644 --- a/libcaja-private/caja-autorun.c +++ b/libcaja-private/caja-autorun.c @@ -747,7 +747,8 @@ is_shift_pressed (void) ret = FALSE; gdk_error_trap_push (); - status = XkbGetState (GDK_DISPLAY (), XkbUseCoreKbd, &state); + status = XkbGetState (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()), + XkbUseCoreKbd, &state); gdk_error_trap_pop (); if (status == Success) -- cgit v1.2.1 From 40cd5a93ced42275631a3d86ad68219aa73cb7a3 Mon Sep 17 00:00:00 2001 From: Jasmine Hassan Date: Thu, 18 Oct 2012 22:56:14 +0200 Subject: [all] Don't use gtk_dialog_set_has_separator() http://git.gnome.org/browse/nautilus/commit/?id=73e2941f9b837d5d0326e6e88caa7a1e3fdcabeb --- libcaja-private/caja-autorun.c | 1 - 1 file changed, 1 deletion(-) (limited to 'libcaja-private/caja-autorun.c') diff --git a/libcaja-private/caja-autorun.c b/libcaja-private/caja-autorun.c index d78f402d..bfb26968 100644 --- a/libcaja-private/caja-autorun.c +++ b/libcaja-private/caja-autorun.c @@ -993,7 +993,6 @@ show_dialog: dialog = gtk_dialog_new (); - gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE); hbox = gtk_hbox_new (FALSE, 12); gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), hbox, TRUE, TRUE, 0); gtk_container_set_border_width (GTK_CONTAINER (hbox), 12); -- cgit v1.2.1 From 0d0641f10e84e0de0b39e63789508c260913cc98 Mon Sep 17 00:00:00 2001 From: Jasmine Hassan Date: Mon, 5 Nov 2012 14:20:13 +0200 Subject: [lc-p] convert to new GDK_KEY prefix http://git.gnome.org/browse/nautilus/commit/?id=64dcbea2a005e4ed8bb4945d06a943058b8c7ba8 --- libcaja-private/caja-autorun.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libcaja-private/caja-autorun.c') diff --git a/libcaja-private/caja-autorun.c b/libcaja-private/caja-autorun.c index bfb26968..61adb3e0 100644 --- a/libcaja-private/caja-autorun.c +++ b/libcaja-private/caja-autorun.c @@ -908,7 +908,7 @@ autorun_always_toggled (GtkToggleButton *togglebutton, AutorunDialogData *data) static gboolean combo_box_enter_ok (GtkWidget *togglebutton, GdkEventKey *event, GtkDialog *dialog) { - if (event->keyval == GDK_KP_Enter || event->keyval == GDK_Return) + if (event->keyval == GDK_KEY_KP_Enter || event->keyval == GDK_KEY_Return) { gtk_dialog_response (dialog, GTK_RESPONSE_OK); return TRUE; -- cgit v1.2.1 From c97aca046a4f75e73e5d82a814337eef950efce3 Mon Sep 17 00:00:00 2001 From: Jasmine Hassan Date: Mon, 5 Nov 2012 14:29:50 +0200 Subject: [autorun] use gdk_error_trap_pop_ignored() for GTK3 http://git.gnome.org/browse/nautilus/commit/?id=8dd87483bd187bfac80a606233b769c230343980 --- libcaja-private/caja-autorun.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libcaja-private/caja-autorun.c') diff --git a/libcaja-private/caja-autorun.c b/libcaja-private/caja-autorun.c index 61adb3e0..21f71eb8 100644 --- a/libcaja-private/caja-autorun.c +++ b/libcaja-private/caja-autorun.c @@ -749,7 +749,11 @@ is_shift_pressed (void) gdk_error_trap_push (); status = XkbGetState (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()), XkbUseCoreKbd, &state); +#if GTK_CHECK_VERSION(3,0,0) + gdk_error_trap_pop_ignored (); +#else gdk_error_trap_pop (); +#endif if (status == Success) { -- cgit v1.2.1 From 4895118afc287dc511792a5f91f109a2e1f868d0 Mon Sep 17 00:00:00 2001 From: Jasmine Hassan Date: Wed, 31 Oct 2012 04:23:12 +0200 Subject: [lc-p] don't use GtkObject (GTK3) the ::destroy signal of GtkObject has only been moved to GtkWidget in GTK3 (after GtkObject removal): http://developer.gnome.org/gtk3/3.0/ch25s02.html So, we use conditionals in this case, to keep working with GTK2 Original commit: http://git.gnome.org/browse/nautilus/commit/?id=aef4cfcf93ef34a0b2d4c87b40fcec2b7a66dd06 --- libcaja-private/caja-autorun.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libcaja-private/caja-autorun.c') diff --git a/libcaja-private/caja-autorun.c b/libcaja-private/caja-autorun.c index 21f71eb8..89b8e63d 100644 --- a/libcaja-private/caja-autorun.c +++ b/libcaja-private/caja-autorun.c @@ -274,7 +274,7 @@ dialog_response_cb (GtkDialog *dialog, } static void -dialog_destroy_cb (GtkObject *object, +dialog_destroy_cb (GtkWidget *object, CajaAutorunComboBoxData *data) { handle_dialog_closure (data); -- cgit v1.2.1 From 7a42b9b076d6b831c89bd0b9e996368c1c95aef3 Mon Sep 17 00:00:00 2001 From: Jasmine Hassan Date: Thu, 18 Oct 2012 10:30:31 +0200 Subject: [all] use g_list_free() and g_strcmp0 instead of eel functions Was: general: use g_list_free_full() instead of eel functions http://git.gnome.org/browse/nautilus/commit/?id=5e669515fd7f760382e6b7aa1449734a35a2d7f4 . Instead of g_list_free_full(), we use g_list_foreach and g_list_free() to avoid unnecessary glib dependency bump to 2.28 --- libcaja-private/caja-autorun.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libcaja-private/caja-autorun.c') diff --git a/libcaja-private/caja-autorun.c b/libcaja-private/caja-autorun.c index 89b8e63d..66534642 100644 --- a/libcaja-private/caja-autorun.c +++ b/libcaja-private/caja-autorun.c @@ -33,7 +33,6 @@ #include #include -#include #include "caja-icon-info.h" #include "caja-global-preferences.h" @@ -652,7 +651,8 @@ caja_autorun_prepare_combo_box (GtkWidget *combo_box, { g_object_unref (default_app_info); } - eel_g_object_list_free (app_info_list); + g_list_foreach (app_info_list, (GFunc) g_object_unref, NULL); + g_list_free(app_info_list); gtk_combo_box_set_model (GTK_COMBO_BOX (combo_box), GTK_TREE_MODEL (list_store)); g_object_unref (G_OBJECT (list_store)); -- cgit v1.2.1