aboutsummaryrefslogtreecommitdiff
path: root/editors/mousepad
diff options
context:
space:
mode:
authorOlivier Duchateau <olivierd@FreeBSD.org>2015-07-11 06:02:20 +0000
committerOlivier Duchateau <olivierd@FreeBSD.org>2015-07-11 06:02:20 +0000
commit4737f9481892443caefdb3eca7392a12fccdee66 (patch)
treeaeba9b64cd25b473e74b6409a665417427894dad /editors/mousepad
parent0313916357cf4312313ccf524eb4536797d3e7e8 (diff)
downloadports-4737f9481892443caefdb3eca7392a12fccdee66.tar.gz
ports-4737f9481892443caefdb3eca7392a12fccdee66.zip
Notes
Diffstat (limited to 'editors/mousepad')
-rw-r--r--editors/mousepad/Makefile4
-rw-r--r--editors/mousepad/files/patch-mousepad_mousepad-action-group.c25
-rw-r--r--editors/mousepad/files/patch-mousepad_mousepad-settings.c11
-rw-r--r--editors/mousepad/files/patch-mousepad_mousepad-view.c12
-rw-r--r--editors/mousepad/files/patch-mousepad_mousepad-window.c18
5 files changed, 68 insertions, 2 deletions
diff --git a/editors/mousepad/Makefile b/editors/mousepad/Makefile
index 25f0e70e0e0a..57fefab4b804 100644
--- a/editors/mousepad/Makefile
+++ b/editors/mousepad/Makefile
@@ -3,7 +3,7 @@
PORTNAME= mousepad
PORTVERSION= 0.4.0
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= editors xfce
MASTER_SITES= XFCE/src/apps/${PORTNAME}/${PORTVERSION:R}
DIST_SUBDIR= xfce4
@@ -17,7 +17,7 @@ LICENSE_FILE= ${WRKSRC}/COPYING
LIB_DEPENDS= libdbus-glib-1.so:${PORTSDIR}/devel/dbus-glib
GNU_CONFIGURE= yes
-USES= desktop-file-utils gettext gmake libtool pkgconfig perl5 tar:bzip2
+USES= desktop-file-utils gettext gmake libtool perl5 pkgconfig tar:bzip2
USE_GNOME= glib20 intltool intlhack
OPTIONS_DEFINE= GTK3
diff --git a/editors/mousepad/files/patch-mousepad_mousepad-action-group.c b/editors/mousepad/files/patch-mousepad_mousepad-action-group.c
new file mode 100644
index 000000000000..3d50b3a5bd0a
--- /dev/null
+++ b/editors/mousepad/files/patch-mousepad_mousepad-action-group.c
@@ -0,0 +1,25 @@
+--- mousepad/mousepad-action-group.c.orig 2014-09-01 20:50:07 UTC
++++ mousepad/mousepad-action-group.c
+@@ -283,7 +283,8 @@ void
+ mousepad_action_group_set_active_style_scheme (MousepadActionGroup *self,
+ GtkSourceStyleScheme *scheme)
+ {
+- GtkAction *action;
++ GtkAction *action;
++ const gchar *scheme_name = NULL;
+
+ g_return_if_fail (MOUSEPAD_IS_ACTION_GROUP (self));
+
+@@ -303,8 +304,11 @@ mousepad_action_group_set_active_style_s
+ self->locked = FALSE;
+
+ /* update the setting when the active action is changed */
++ if (scheme != NULL)
++ scheme_name = gtk_source_style_scheme_get_id(scheme);
++
+ self->locked = TRUE;
+- MOUSEPAD_SETTING_SET_STRING (COLOR_SCHEME, gtk_source_style_scheme_get_id (scheme));
++ MOUSEPAD_SETTING_SET_STRING (COLOR_SCHEME, scheme_name);
+ self->locked = FALSE;
+
+ g_object_notify (G_OBJECT (self), "active-style-scheme");
diff --git a/editors/mousepad/files/patch-mousepad_mousepad-settings.c b/editors/mousepad/files/patch-mousepad_mousepad-settings.c
new file mode 100644
index 000000000000..bbd300c6b4c0
--- /dev/null
+++ b/editors/mousepad/files/patch-mousepad_mousepad-settings.c
@@ -0,0 +1,11 @@
+--- mousepad/mousepad-settings.c.orig 2014-09-01 20:50:07 UTC
++++ mousepad/mousepad-settings.c
+@@ -298,7 +298,7 @@ void
+ mousepad_setting_set_string (const gchar *path,
+ const gchar *value)
+ {
+- mousepad_setting_set (path, "s", value);
++ mousepad_setting_set (path, "s", value != NULL ? value : "");
+ }
+
+
diff --git a/editors/mousepad/files/patch-mousepad_mousepad-view.c b/editors/mousepad/files/patch-mousepad_mousepad-view.c
new file mode 100644
index 000000000000..f11878902ee5
--- /dev/null
+++ b/editors/mousepad/files/patch-mousepad_mousepad-view.c
@@ -0,0 +1,12 @@
+--- mousepad/mousepad-view.c.orig 2014-09-01 20:50:07 UTC
++++ mousepad/mousepad-view.c
+@@ -257,7 +257,8 @@ mousepad_view_buffer_changed (MousepadVi
+ GtkSourceStyleScheme *scheme;
+
+ manager = gtk_source_style_scheme_manager_get_default ();
+- scheme = gtk_source_style_scheme_manager_get_scheme (manager, view->color_scheme);
++ scheme = gtk_source_style_scheme_manager_get_scheme (manager,
++ view->color_scheme ? view->color_scheme : "");
+ gtk_source_buffer_set_style_scheme (buffer, scheme);
+
+ gtk_source_buffer_set_highlight_matching_brackets (buffer, view->match_braces);
diff --git a/editors/mousepad/files/patch-mousepad_mousepad-window.c b/editors/mousepad/files/patch-mousepad_mousepad-window.c
new file mode 100644
index 000000000000..66b112e28197
--- /dev/null
+++ b/editors/mousepad/files/patch-mousepad_mousepad-window.c
@@ -0,0 +1,18 @@
+--- mousepad/mousepad-window.c.orig 2014-09-01 20:58:02 UTC
++++ mousepad/mousepad-window.c
+@@ -717,12 +717,13 @@ mousepad_window_action_group_style_schem
+ MousepadActionGroup *group)
+ {
+ GtkSourceStyleScheme *scheme;
+- const gchar *scheme_id;
++ const gchar *scheme_id = NULL;
+ gint npages, i;
+
+ /* get the new active language */
+ scheme = mousepad_action_group_get_active_style_scheme (group);
+- scheme_id = gtk_source_style_scheme_get_id (scheme);
++ if (scheme != NULL)
++ scheme_id = gtk_source_style_scheme_get_id (scheme);
+
+ /* update the color scheme on all the documents */
+ npages = gtk_notebook_get_n_pages (GTK_NOTEBOOK (window->notebook));