From 58a0b9083b6bb3838176ed77c7870bb2aacb967f Mon Sep 17 00:00:00 2001 From: Jesse Keating Date: Fri, 7 Nov 2008 03:39:09 +0000 Subject: [PATCH 1/4] Initialize branch F-10 for xfce4-systemload-plugin --- branch | 1 + 1 file changed, 1 insertion(+) create mode 100644 branch diff --git a/branch b/branch new file mode 100644 index 0000000..dc32377 --- /dev/null +++ b/branch @@ -0,0 +1 @@ +F-10 From 99a9f0689f14fe8a2139507571f1beeebf1a4ff1 Mon Sep 17 00:00:00 2001 From: Christoph Wickert Date: Wed, 9 Sep 2009 21:17:48 +0000 Subject: [PATCH 2/4] - Bring back tooltips in GTK >= 2.16 (#508637, bugzilla.xfce.org #5175) - Fix bar colors (#505214, bugzilla.xfce.org #1889) - Fix wrong free memory value (bugzilla.xfce.org #4215) --- ...stemload-plugin-0.4.2-fix-bar-colors.patch | 59 +++++++++++++++++++ ...in-0.4.2-fix-wrong-free-memory-value.patch | 42 +++++++++++++ xfce4-systemload-plugin-0.4.2-tooltip.patch | 23 ++++++++ xfce4-systemload-plugin.spec | 46 ++++++++++++--- 4 files changed, 161 insertions(+), 9 deletions(-) create mode 100644 xfce4-systemload-plugin-0.4.2-fix-bar-colors.patch create mode 100644 xfce4-systemload-plugin-0.4.2-fix-wrong-free-memory-value.patch create mode 100644 xfce4-systemload-plugin-0.4.2-tooltip.patch diff --git a/xfce4-systemload-plugin-0.4.2-fix-bar-colors.patch b/xfce4-systemload-plugin-0.4.2-fix-bar-colors.patch new file mode 100644 index 0000000..27d3e81 --- /dev/null +++ b/xfce4-systemload-plugin-0.4.2-fix-bar-colors.patch @@ -0,0 +1,59 @@ +diff -u panel-plugin/systemload.c panel-plugin/systemload.c +--- panel-plugin/systemload.c (working copy) ++++ panel-plugin/systemload.c (working copy) +@@ -256,17 +256,16 @@ + gtk_container_add(GTK_CONTAINER(global->monitor[count]->ebox), + GTK_WIDGET(global->monitor[count]->box)); + +- rc = gtk_widget_get_modifier_style(GTK_WIDGET(global->monitor[count]->status)); +- if (!rc) { +- rc = gtk_rc_style_new(); +- } +- if (rc) { +- rc->color_flags[GTK_STATE_PRELIGHT] |= GTK_RC_BG; +- rc->bg[GTK_STATE_PRELIGHT] = +- global->monitor[count]->options.color; +- } +- +- gtk_widget_modify_style(GTK_WIDGET(global->monitor[count]->status), rc); ++ gtk_widget_modify_bg(GTK_WIDGET(global->monitor[count]->status), ++ GTK_STATE_PRELIGHT, ++ &global->monitor[count]->options.color); ++ gtk_widget_modify_bg(GTK_WIDGET(global->monitor[count]->status), ++ GTK_STATE_SELECTED, ++ &global->monitor[count]->options.color); ++ gtk_widget_modify_base(GTK_WIDGET(global->monitor[count]->status), ++ GTK_STATE_SELECTED, ++ &global->monitor[count]->options.color); ++ + gtk_widget_show(GTK_WIDGET(global->monitor[count]->status)); + + gtk_box_pack_start(GTK_BOX(global->monitor[count]->box), +@@ -384,18 +383,15 @@ + gtk_label_set_text(GTK_LABEL(global->monitor[count]->label), + global->monitor[count]->options.label_text); + +- gtk_widget_hide(GTK_WIDGET(global->monitor[count]->status)); +- rc = gtk_widget_get_modifier_style(GTK_WIDGET(global->monitor[count]->status)); +- if (!rc) { +- rc = gtk_rc_style_new(); +- } +- +- if (rc) { +- rc->color_flags[GTK_STATE_PRELIGHT] |= GTK_RC_BG; +- rc->bg[GTK_STATE_PRELIGHT] = global->monitor[count]->options.color; +- } +- +- gtk_widget_modify_style(GTK_WIDGET(global->monitor[count]->status), rc); ++ gtk_widget_modify_bg(GTK_WIDGET(global->monitor[count]->status), ++ GTK_STATE_PRELIGHT, ++ &global->monitor[count]->options.color); ++ gtk_widget_modify_bg(GTK_WIDGET(global->monitor[count]->status), ++ GTK_STATE_SELECTED, ++ &global->monitor[count]->options.color); ++ gtk_widget_modify_base(GTK_WIDGET(global->monitor[count]->status), ++ GTK_STATE_SELECTED, ++ &global->monitor[count]->options.color); + + if(global->monitor[count]->options.enabled) + { diff --git a/xfce4-systemload-plugin-0.4.2-fix-wrong-free-memory-value.patch b/xfce4-systemload-plugin-0.4.2-fix-wrong-free-memory-value.patch new file mode 100644 index 0000000..9a75370 --- /dev/null +++ b/xfce4-systemload-plugin-0.4.2-fix-wrong-free-memory-value.patch @@ -0,0 +1,42 @@ +diff -Nur -x '*.orig' -x '*~' xfce4-systemload-plugin-0.4.2/panel-plugin/memswap.c xfce4-systemload-plugin-0.4.2.new/panel-plugin/memswap.c +--- xfce4-systemload-plugin-0.4.2/panel-plugin/memswap.c 2007-01-17 19:01:09.000000000 +0100 ++++ xfce4-systemload-plugin-0.4.2.new/panel-plugin/memswap.c 2008-03-08 12:16:34.000000000 +0100 +@@ -48,6 +48,7 @@ + static unsigned long MTotal = 0; + static unsigned long MFree = 0; + static unsigned long MCached = 0; ++static unsigned long MBuffers = 0; + static unsigned long MUsed = 0; + static unsigned long STotal = 0; + static unsigned long SFree = 0; +@@ -57,8 +58,8 @@ + { + int fd; + size_t n; +- int o_MTotal, o_MFree, o_MCached, o_STotal, o_SFree; +- char *b_MTotal, *b_MFree, *b_MCached, *b_STotal, *b_SFree; ++ int o_MTotal, o_MFree, o_MCached, o_MBuffers, o_STotal, o_SFree; ++ char *b_MTotal, *b_MFree, *b_MCached, *b_MBuffers, *b_STotal, *b_SFree; + + if ((fd = open("/proc/meminfo", O_RDONLY)) < 0) + { +@@ -87,6 +88,10 @@ + if (b_MCached) + o_MCached = sscanf(b_MCached + strlen("Cached"), ": %lu", &MCached); + ++ b_MBuffers = strstr(MemInfoBuf, "Buffers"); ++ if (b_MBuffers) ++ o_MBuffers = sscanf(b_MBuffers + strlen("Buffers"), ": %lu", &MBuffers); ++ + b_STotal = strstr(MemInfoBuf, "SwapTotal"); + if (b_STotal) + o_STotal = sscanf(b_STotal + strlen("SwapTotal"), ": %lu", &STotal); +@@ -95,7 +100,7 @@ + if (b_SFree) + o_SFree = sscanf(b_SFree + strlen("SwapFree"), ": %lu", &SFree); + +- MFree += MCached; ++ MFree = MFree + MCached + MBuffers; + MUsed = MTotal - MFree; + SUsed = STotal - SFree; + *mem = MUsed * 100 / MTotal; diff --git a/xfce4-systemload-plugin-0.4.2-tooltip.patch b/xfce4-systemload-plugin-0.4.2-tooltip.patch new file mode 100644 index 0000000..d407678 --- /dev/null +++ b/xfce4-systemload-plugin-0.4.2-tooltip.patch @@ -0,0 +1,23 @@ +diff --git a/panel-plugin/systemload.c b/panel-plugin/systemload.c +index cc96ec4..027e8fe 100644 +--- a/panel-plugin/systemload.c ++++ b/panel-plugin/systemload.c +@@ -315,11 +315,18 @@ monitor_control_new(XfcePanelPlugin *plugin) + { + int count; + t_global_monitor *global; ++ GtkSettings *settings; + + tooltips = gtk_tooltips_new (); + g_object_ref (tooltips); + gtk_object_sink (GTK_OBJECT (tooltips)); + ++ /* reduce the default tooltip timeout to be smaller than the update ++ * interval otherwise we won't see tooltips on GTK 2.16 or newer */ ++ settings = gtk_settings_get_default(); ++ if (g_object_class_find_property(G_OBJECT_GET_CLASS(settings), "gtk-tooltip-timeout")) ++ g_object_set(settings, "gtk-tooltip-timeout", UPDATE_TIMEOUT - 10, NULL); ++ + global = g_new(t_global_monitor, 1); + global->plugin = plugin; + global->timeout_id = 0; diff --git a/xfce4-systemload-plugin.spec b/xfce4-systemload-plugin.spec index 50636f7..b37d296 100644 --- a/xfce4-systemload-plugin.spec +++ b/xfce4-systemload-plugin.spec @@ -1,12 +1,21 @@ Name: xfce4-systemload-plugin Version: 0.4.2 -Release: 4%{?dist} +Release: 8%{?dist} Summary: Systemload monitor for the Xfce panel Group: User Interface/Desktops License: BSD URL: http://goodies.xfce.org/projects/panel-plugins/%{name} Source0: http://goodies.xfce.org/releases/%{name}/%{name}-%{version}.tar.bz2 +# allow custom bar colors in all themes +# http://bugzilla.xfce.org/show_bug.cgi?id=1889 +Patch0: %{name}-0.4.2-fix-bar-colors.patch +# memory usage in plugin is different from `free' output +# http://bugzilla.xfce.org/show_bug.cgi?id=4215 +Patch1: %{name}-0.4.2-fix-wrong-free-memory-value.patch +# make tooltips work with GTK 2.16 +# http://bugzilla.xfce.org/show_bug.cgi?id=5175 +Patch2: %{name}-0.4.2-tooltip.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: xfce4-panel-devel >= 4.3.99.1, libxfcegui4-devel >= 4.3.99.1, libxml2-devel @@ -19,6 +28,11 @@ load, the memory in use, the swap space and the system uptime. %prep %setup -q +%patch0 -p0 -b .colors +%patch1 -p1 -b .free +%if 0%{?fedora} >= 11 +%patch2 -p1 -b .tooltip +%endif %build %configure --disable-static @@ -39,32 +53,46 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/xfce4/panel-plugins/*.desktop %changelog +* Wed Sep 09 2009 Christoph Wickert - 0.4.2-8 +- Bring back tooltips in GTK >= 2.16 (#508637, bugzilla.xfce.org #5175) +- Fix bar colors (#505214, bugzilla.xfce.org #1889) +- Fix wrong free memory value (bugzilla.xfce.org #4215) + +* Mon Jul 27 2009 Fedora Release Engineering - 0.4.2-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Thu Feb 26 2009 Fedora Release Engineering - 0.4.2-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Sun Jan 18 2009 Christoph Wickert - 0.4.2-5 +- Rebuild for Xfce 4.6 (Beta 3) + * Mon Feb 18 2008 Fedora Release Engineering - 0.4.2-4 - Autorebuild for GCC 4.3 -* Sat Aug 25 2007 Christoph Wickert - 0.4.2-3 +* Sat Aug 25 2007 Christoph Wickert - 0.4.2-3 - Rebuild for BuildID feature -* Sat Apr 28 2007 Christoph Wickert - 0.4.2-2 +* Sat Apr 28 2007 Christoph Wickert - 0.4.2-2 - Rebuild for Xfce 4.4.1 -* Mon Jan 22 2007 Christoph Wickert - 0.4.2-1 +* Mon Jan 22 2007 Christoph Wickert - 0.4.2-1 - Update to 0.4.2 on Xfce 4.4. -* Fri Dec 22 2006 Christoph Wickert - 0.4.1-1 +* Fri Dec 22 2006 Christoph Wickert - 0.4.1-1 - Update to 0.4.1. -* Thu Oct 05 2006 Christoph Wickert - 0.4.0-3 +* Thu Oct 05 2006 Christoph Wickert - 0.4.0-3 - Bump release for devel checkin. -* Wed Sep 13 2006 Christoph Wickert - 0.4.0-2 +* Wed Sep 13 2006 Christoph Wickert - 0.4.0-2 - Rebuild for XFCE 4.3.99.1. - BR perl(XML::Parser). -* Mon Sep 04 2006 Christoph Wickert - 0.4.0-1 +* Mon Sep 04 2006 Christoph Wickert - 0.4.0-1 - Update to 0.4.0 on XFCE 4.3.90.2. -* Mon Sep 04 2006 Christoph Wickert - 0.3.6-7 +* Mon Sep 04 2006 Christoph Wickert - 0.3.6-7 - Mass rebuild for Fedora Core 6. * Tue Apr 11 2006 Christoph Wickert - 0.3.6-6 From 33fc8b2574d2d3b24798819778163c5eaae2672b Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Thu, 26 Nov 2009 01:32:07 +0000 Subject: [PATCH 3/4] Fix typo that causes a failure to update the common directory. (releng #2781) --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 7b006cd..4414bc1 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ NAME := xfce4-systemload-plugin SPECFILE = $(firstword $(wildcard *.spec)) define find-makefile-common -for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done +for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done endef MAKEFILE_COMMON := $(shell $(find-makefile-common)) From c53c713482e2f9b401415fc79d07fbddf3f62918 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Thu, 29 Jul 2010 15:47:45 +0000 Subject: [PATCH 4/4] dist-git conversion --- .cvsignore => .gitignore | 0 Makefile | 21 --------------------- branch | 1 - 3 files changed, 22 deletions(-) rename .cvsignore => .gitignore (100%) delete mode 100644 Makefile delete mode 100644 branch diff --git a/.cvsignore b/.gitignore similarity index 100% rename from .cvsignore rename to .gitignore diff --git a/Makefile b/Makefile deleted file mode 100644 index 4414bc1..0000000 --- a/Makefile +++ /dev/null @@ -1,21 +0,0 @@ -# Makefile for source rpm: xfce4-systemload-plugin -# $Id$ -NAME := xfce4-systemload-plugin -SPECFILE = $(firstword $(wildcard *.spec)) - -define find-makefile-common -for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done -endef - -MAKEFILE_COMMON := $(shell $(find-makefile-common)) - -ifeq ($(MAKEFILE_COMMON),) -# attept a checkout -define checkout-makefile-common -test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2 -endef - -MAKEFILE_COMMON := $(shell $(checkout-makefile-common)) -endif - -include $(MAKEFILE_COMMON) diff --git a/branch b/branch deleted file mode 100644 index dc32377..0000000 --- a/branch +++ /dev/null @@ -1 +0,0 @@ -F-10