[gnome-build-meta/matthiasc/40] Revert "Drop a gedit patch"
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-build-meta/matthiasc/40] Revert "Drop a gedit patch"
- Date: Tue, 23 Mar 2021 16:53:06 +0000 (UTC)
commit 75fc27fb31e16648e54fbfeb939d0970432a1b4b
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Mar 23 12:50:25 2021 -0400
Revert "Drop a gedit patch"
This reverts commit b7a160d89edcfe25fa5f52c13de07db280efa09d.
elements/core/gedit.bst | 2 +
files/gedit/102.patch | 100 ++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 102 insertions(+)
---
diff --git a/elements/core/gedit.bst b/elements/core/gedit.bst
index bce66b4f..bc6ee1ed 100644
--- a/elements/core/gedit.bst
+++ b/elements/core/gedit.bst
@@ -4,6 +4,8 @@ sources:
- kind: tar
url: gnome_downloads:gedit/40/gedit-40.0.tar.xz
ref: 0e8aac632b8879a57346aaf35c66f7df40c3fd5ea37a78e04ea218e41e3984e9
+- kind: patch
+ path: files/gedit/102.patch
build-depends:
- sdk/gobject-introspection.bst
diff --git a/files/gedit/102.patch b/files/gedit/102.patch
new file mode 100644
index 00000000..8d960bfb
--- /dev/null
+++ b/files/gedit/102.patch
@@ -0,0 +1,100 @@
+From 8f6490c602991a456413e0053429bb7b4c70d4b6 Mon Sep 17 00:00:00 2001
+From: Zander Brown <zbrown gnome org>
+Date: Thu, 11 Feb 2021 10:26:55 +0000
+Subject: [PATCH] file-browser: drop use of confirm-trash
+
+Nautilus has removed their key as it was being (ab)used by other apps:
+https://gitlab.gnome.org/GNOME/nautilus/-/commit/e96aac1f6526f5373405e071703b5f18b0c728d3
+
+This then caused gedit to crash on launch as the plug-in is enabled by
+default:
+https://gitlab.gnome.org/GNOME/gedit/-/issues/408
+
+Fix #408 by simply assuming the default value of the key
+---
+ .../filebrowser/gedit-file-browser-plugin.c | 32 -------------------
+ 1 file changed, 32 deletions(-)
+
+diff --git a/plugins/filebrowser/gedit-file-browser-plugin.c
b/plugins/filebrowser/gedit-file-browser-plugin.c
+index 2e8e13e7f..983e5de74 100644
+--- a/plugins/filebrowser/gedit-file-browser-plugin.c
++++ b/plugins/filebrowser/gedit-file-browser-plugin.c
+@@ -50,7 +50,6 @@
+ #define NAUTILUS_BASE_SETTINGS "org.gnome.nautilus.preferences"
+ #define NAUTILUS_FALLBACK_SETTINGS "org.gnome.gedit.plugins.filebrowser.nautilus"
+ #define NAUTILUS_CLICK_POLICY_KEY "click-policy"
+-#define NAUTILUS_CONFIRM_TRASH_KEY "confirm-trash"
+
+ #define TERMINAL_BASE_SETTINGS "org.gnome.desktop.default-applications.terminal"
+ #define TERMINAL_EXEC_KEY "exec"
+@@ -66,10 +65,8 @@ struct _GeditFileBrowserPluginPrivate
+ GeditFileBrowserWidget *tree_widget;
+ gboolean auto_root;
+ gulong end_loading_handle;
+- gboolean confirm_trash;
+
+ guint click_policy_handle;
+- guint confirm_trash_handle;
+ };
+
+ enum
+@@ -321,14 +318,6 @@ on_click_policy_changed (GSettings *settings,
+ gedit_file_browser_view_set_click_policy (view, policy);
+ }
+
+-static void
+-on_confirm_trash_changed (GSettings *settings,
+- const gchar *key,
+- GeditFileBrowserPlugin *plugin)
+-{
+- plugin->priv->confirm_trash = g_settings_get_boolean (settings, key);
+-}
+-
+ static void
+ install_nautilus_prefs (GeditFileBrowserPlugin *plugin)
+ {
+@@ -349,18 +338,6 @@ install_nautilus_prefs (GeditFileBrowserPlugin *plugin)
+ "changed::" NAUTILUS_CLICK_POLICY_KEY,
+ G_CALLBACK (on_click_policy_changed),
+ plugin);
+-
+- /* Get confirm_trash */
+- prefb = g_settings_get_boolean (priv->nautilus_settings,
+- NAUTILUS_CONFIRM_TRASH_KEY);
+-
+- priv->confirm_trash = prefb;
+-
+- priv->confirm_trash_handle =
+- g_signal_connect (priv->nautilus_settings,
+- "changed::" NAUTILUS_CONFIRM_TRASH_KEY,
+- G_CALLBACK (on_confirm_trash_changed),
+- plugin);
+ }
+
+ static void
+@@ -588,12 +565,6 @@ gedit_file_browser_plugin_deactivate (GeditWindowActivatable *activatable)
+ priv->click_policy_handle);
+ }
+
+- if (priv->confirm_trash_handle)
+- {
+- g_signal_handler_disconnect (priv->nautilus_settings,
+- priv->confirm_trash_handle);
+- }
+-
+ panel = gedit_window_get_side_panel (priv->window);
+ gtk_container_remove (GTK_CONTAINER (panel), GTK_WIDGET (priv->tree_widget));
+ }
+@@ -932,9 +903,6 @@ on_confirm_delete_cb (GeditFileBrowserWidget *widget,
+ gchar *secondary;
+ gboolean result;
+
+- if (!priv->confirm_trash)
+- return TRUE;
+-
+ if (paths->next == NULL)
+ {
+ normal = get_filename_from_path (GTK_TREE_MODEL (store), (GtkTreePath *)(paths->data));
+--
+GitLab
+
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]