[tomboy] Always show icons for note items in recent notes menu (#590653)



commit f560d6be5421da13d286868a6a5e4cc0a5b81a99
Author: Sandy Armstrong <sanfordarmstrong gmail com>
Date:   Mon Sep 21 20:03:15 2009 -0700

    Always show icons for note items in recent notes menu (#590653)
    
    Add new SetAlwaysShowImage extension method to ImageMenuItem in
    local gtk-sharp-beans (has also gone upstream, thanks sde).

 Tomboy/Makefile.am |    5 +++++
 Tomboy/Tray.cs     |    5 ++++-
 configure.in       |    5 +++++
 3 files changed, 14 insertions(+), 1 deletions(-)
---
diff --git a/Tomboy/Makefile.am b/Tomboy/Makefile.am
index 10a7386..4371b3a 100644
--- a/Tomboy/Makefile.am
+++ b/Tomboy/Makefile.am
@@ -70,6 +70,10 @@ if FIXED_GTKSPELL
 FIXED_GTKSPELL_CSFLAGS = -define:FIXED_GTKSPELL
 endif
 
+if HAS_GTK_2_16
+HAS_GTK_2_16_FLAGS = -define:HAS_GTK_2_16
+endif
+
 CSFLAGS = 				\
 	-debug				\
 	-define:DEBUG 			\
@@ -81,6 +85,7 @@ CSFLAGS = 				\
 	$(WIN_CSFLAGS) 		\
 	$(FIXED_PANELAPPLET_CSFLAGS)	\
 	$(FIXED_GTKSPELL_CSFLAGS) \
+	$(HAS_GTK_2_16_FLAGS) \
 	$(CSC_DEFINES)
 
 CSFILES = 					\
diff --git a/Tomboy/Tray.cs b/Tomboy/Tray.cs
index c063287..174db53 100644
--- a/Tomboy/Tray.cs
+++ b/Tomboy/Tray.cs
@@ -2,6 +2,7 @@ using System;
 using System.Collections.Generic;
 using Mono.Unix;
 using System.Runtime.InteropServices;
+using GtkBeans;
 
 namespace Tomboy
 {
@@ -31,7 +32,9 @@ namespace Tomboy
 		{
 			this.note = note;
 			Image = new Gtk.Image (note_icon);
-
+#if HAS_GTK_2_16
+			this.SetAlwaysShowImage (true);
+#endif
 			if (show_pin) {
 				Gtk.HBox box = new Gtk.HBox (false, 0);
 				Gtk.Widget child = Child;
diff --git a/configure.in b/configure.in
index 7d3d970..885e92b 100644
--- a/configure.in
+++ b/configure.in
@@ -60,6 +60,11 @@ PKG_CHECK_MODULES(LIBTOMBOY,
 AC_SUBST(LIBTOMBOY_CFLAGS)
 AC_SUBST(LIBTOMBOY_LIBS)
 
+if pkg-config --atleast-version=2.16 gtk+-2.0; then
+	HAS_GTK_2_16=yes
+fi
+AM_CONDITIONAL(HAS_GTK_2_16, test "x$HAS_GTK_2_16" = "xyes")
+
 #
 # Use pkg-config to check for the panel applet server directory if
 # specified by --enable-panelapplet-srvdir-check.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]