[Xfce4-commits] [apps/mousepad] 21/45: Update the window title when path-in-title setting changes

noreply at xfce.org noreply at xfce.org
Fri Jul 11 13:03:26 CEST 2014


This is an automated email from the git hooks/post-receive script.

mbrush pushed a commit to branch master
in repository apps/mousepad.

commit 442432667d7b83ea8ec584f45024f2a274f9fb88
Author: Matthew Brush <mbrush at codebrainz.ca>
Date:   Sun Jul 6 22:58:30 2014 -0700

    Update the window title when path-in-title setting changes
---
 mousepad/mousepad-window.c |   17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/mousepad/mousepad-window.c b/mousepad/mousepad-window.c
index 1564903..9a0e839 100644
--- a/mousepad/mousepad-window.c
+++ b/mousepad/mousepad-window.c
@@ -552,6 +552,17 @@ mousepad_window_update_statusbar_settings (MousepadWindow   *window,
 
 
 
+/* Called in response to any setting changed which affects the window title. */
+static void
+mousepad_window_update_window_title (MousepadWindow   *window,
+                                     gchar            *key,
+                                     MousepadSettings *settings)
+{
+  mousepad_window_set_title (window);
+}
+
+
+
 static void
 mousepad_window_init (MousepadWindow *window)
 {
@@ -716,6 +727,12 @@ mousepad_window_init (MousepadWindow *window)
                             "changed::view-insert-spaces",
                             G_CALLBACK (mousepad_window_update_statusbar_settings),
                             window);
+
+  /* update the window title when 'path-in-title' setting changes */
+  g_signal_connect_swapped (MOUSEPAD_GSETTINGS,
+                            "changed::window-path-in-title",
+                            G_CALLBACK (mousepad_window_update_window_title),
+                            window);
 }
 
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list