Package: gtkpbbuttons
Version: 0.6.8-3
Followup-For: Bug #296913

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Here is a patch for this bug. It's against 0.6.8-3

It adds a file to the Xsession system. The behaviour can be changed
with a global and user configuration file (both are included).
I've tested it and it's working as it is intended :-)

bye, Martin

- -- System Information:
Debian Release: testing/unstable
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: powerpc (ppc)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.17.2
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)

Versions of packages gtkpbbuttons depends on:
ii  gtkpbbuttons-common          0.6.8-3     GTK client for pbbuttonsd -- theme
ii  libatk1.0-0                  1.11.4-3    The ATK accessibility toolkit
ii  libaudiofile0                0.2.6-6     Open-source version of SGI's audio
ii  libc6                        2.3.6-15    GNU C Library: Shared libraries
ii  libcairo2                    1.2.0-2     The Cairo 2D vector graphics libra
ii  libfontconfig1               2.3.2-7     generic font configuration library
ii  libglib2.0-0                 2.10.3-2    The GLib library of C routines
ii  libgtk2.0-0                  2.8.18-1    The GTK+ graphical user interface 
ii  libpango1.0-0                1.12.3-1    Layout and rendering of internatio
ii  libpopt0                     1.10-2      lib for parsing cmdline parameters
ii  libx11-6                     2:1.0.0-7   X11 client-side library
ii  libxcursor1                  1.1.5.2-5   X cursor management library
ii  libxext6                     1:1.0.0-4   X11 miscellaneous extension librar
ii  libxfixes3                   1:3.0.1.2-4 X11 miscellaneous 'fixes' extensio
ii  libxi6                       1:1.0.0-5   X11 Input extension library
ii  libxinerama1                 1:1.0.1-4   X11 Xinerama extension library
ii  libxrandr2                   2:1.1.0.2-4 X11 RandR extension library
ii  libxrender1                  1:0.9.0.2-4 X Rendering Extension client libra
ii  pbbuttonsd                   0.7.5-2     PBButtons daemon to handle special
ii  ucf                          2.0012      Update Configuration File: preserv

gtkpbbuttons recommends no packages.

- -- no debconf information

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (GNU/Linux)

iD8DBQFEt3ZGOvJj+wS6JuIRAkR0AKDHgGeJqotmjtsY2a8zT3Ru36aIMQCeMW61
K1U+cQcDOnghvxWQIIZncKQ=
=G8Ek
-----END PGP SIGNATURE-----
diff -Nru debian.orig/99gtkpbbuttons gtkpbbuttons-0.6.8/debian/99gtkpbbuttons
--- debian.orig/99gtkpbbuttons  1970-01-01 01:00:00.000000000 +0100
+++ gtkpbbuttons-0.6.8/debian/99gtkpbbuttons    2006-07-14 12:18:03.000000000 
+0200
@@ -0,0 +1,25 @@
+# Xsession file for gtkpbbuttons
+# this file is sourced, not executed
+#
+
+# defaults
+THEME=Classic
+START=1
+
+# read default configuration
+if [ -f /etc/default/gtkpbbuttons ]
+then
+. /etc/default/gtkpbbuttons
+fi
+
+# read user configuration
+if [ -f ~/.gtkpbbuttons ]
+then
+. ~/.gtkpbbuttons
+fi
+
+# start gtkpbbuttons
+if [ $START == 1 ]
+then
+    /usr/bin/gtkpbbuttons -d -t $THEME
+fi
diff -Nru debian.orig/README.Debian gtkpbbuttons-0.6.8/debian/README.Debian
--- debian.orig/README.Debian   1970-01-01 01:00:00.000000000 +0100
+++ gtkpbbuttons-0.6.8/debian/README.Debian     2006-07-14 12:40:27.000000000 
+0200
@@ -0,0 +1,4 @@
+gtkpbbuttons have a global configuration file in /etc/defaults now.
+To change you personal settings copy
+/usr/share/doc/gtkpbbuttons/examples/gtkpbbuttons to ~/.gtkpbbuttons
+
diff -Nru debian.orig/control gtkpbbuttons-0.6.8/debian/control
--- debian.orig/control 2006-07-11 17:05:29.000000000 +0200
+++ gtkpbbuttons-0.6.8/debian/control   2006-07-13 19:56:21.000000000 +0200
@@ -7,7 +7,7 @@
 
 Package: gtkpbbuttons
 Architecture: i386 powerpc
-Depends: ${shlibs:Depends}, pbbuttonsd (>= 0.6.7), gtkpbbuttons-common
+Depends: ${shlibs:Depends}, pbbuttonsd (>= 0.6.7), gtkpbbuttons-common, ucf
 Conflicts: gtkpbbuttons-gnome
 Description: GTK client for pbbuttonsd
  This client for pbbuttonsd displays small popup windows each time a
diff -Nru debian.orig/docs gtkpbbuttons-0.6.8/debian/docs
--- debian.orig/docs    2006-07-11 17:05:29.000000000 +0200
+++ gtkpbbuttons-0.6.8/debian/docs      2006-07-14 12:37:22.000000000 +0200
@@ -1,3 +1,5 @@
 BUGS
 README
 TODO
+debian/README.Debian
+
diff -Nru debian.orig/examples/gtkpbbuttons 
gtkpbbuttons-0.6.8/debian/examples/gtkpbbuttons
--- debian.orig/examples/gtkpbbuttons   1970-01-01 01:00:00.000000000 +0100
+++ gtkpbbuttons-0.6.8/debian/examples/gtkpbbuttons     2006-07-14 
11:54:32.000000000 +0200
@@ -0,0 +1,10 @@
+# user configuration file for gtkpbbuttons
+# copy this file to ~/.gtkpbbuttons
+# this file is sourced into /etc/X11/Xsession.d/99gtkpbbuttons
+# and overrides the settings in /etc/default/gtkpbbuttons
+
+# start gtkpbbuttons? Use 0 to disable
+START=1
+
+# all directories of /usr/share/gtkpbbuttons/themes are valid
+THEME=Classic
diff -Nru debian.orig/gtkpbbuttons.examples 
gtkpbbuttons-0.6.8/debian/gtkpbbuttons.examples
--- debian.orig/gtkpbbuttons.examples   1970-01-01 01:00:00.000000000 +0100
+++ gtkpbbuttons-0.6.8/debian/gtkpbbuttons.examples     2006-07-14 
10:54:49.000000000 +0200
@@ -0,0 +1 @@
+debian/examples/gtkpbbuttons
diff -Nru debian.orig/gtkpbbuttons.install 
gtkpbbuttons-0.6.8/debian/gtkpbbuttons.install
--- debian.orig/gtkpbbuttons.install    2006-07-11 17:05:29.000000000 +0200
+++ gtkpbbuttons-0.6.8/debian/gtkpbbuttons.install      2006-07-14 
11:44:29.000000000 +0200
@@ -1,2 +1,3 @@
 debian/tmp/usr/bin
 debian/tmp/usr/share/lintian
+debian/99gtkpbbuttons /etc/X11/Xsession.d
diff -Nru debian.orig/gtkpbbuttons.postinst 
gtkpbbuttons-0.6.8/debian/gtkpbbuttons.postinst
--- debian.orig/gtkpbbuttons.postinst   1970-01-01 01:00:00.000000000 +0100
+++ gtkpbbuttons-0.6.8/debian/gtkpbbuttons.postinst     2006-07-14 
11:55:23.000000000 +0200
@@ -0,0 +1,43 @@
+#! /bin/sh
+#
+# postinst script for gtkpbbuttons
+#
+
+set -e
+
+configfile='/etc/default/gtkpbbuttons';
+tmpfile=`/bin/tempfile -m 644`;
+
+case $1 in
+        configure|reconfigure)
+
+#       . /usr/share/debconf/confmodule
+
+        /bin/cat << EOT > $tmpfile
+# gtkpbbuttons defaults
+# THEME set the default theme, can be overwritten by ~/.gtkpbbuttons
+# This file is sourced into /etc/X11/Xsession.d/99gtkpbbuttons
+
+# start gtkpbbuttons? Use 0 to disable
+START=1
+
+# THEME can be everything in /usr/share/gtkpbbuttons/themes
+THEME=Classic
+
+EOT
+
+        /usr/bin/ucf --three-way --debconf-ok $tmpfile $configfile
+        /bin/rm $tmpfile
+  exit 0
+        ;;
+
+        *)
+                echo "postinst called with unknown argument \`$1'" 1>&2
+                exit 1
+                ;;
+esac
+
+#DEBHELPER#
+
+exit 0
+
diff -Nru debian.orig/gtkpbbuttons.postrm 
gtkpbbuttons-0.6.8/debian/gtkpbbuttons.postrm
--- debian.orig/gtkpbbuttons.postrm     1970-01-01 01:00:00.000000000 +0100
+++ gtkpbbuttons-0.6.8/debian/gtkpbbuttons.postrm       2006-07-14 
12:27:32.000000000 +0200
@@ -0,0 +1,35 @@
+#! /bin/sh
+# 
+# prerm script for gtkpbbuttons
+#
+
+set -e
+
+case "$1" in
+       purge)
+               
+               if [ -x /usr/bin/ucf ] ; then 
+
+                       /usr/bin/ucf --purge /etc/default/gtkpbbuttons
+                       rm -f /etc/default/gtkpbbuttons
+
+               fi
+
+               ;;
+
+       remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+               ;;
+
+       *)
+               echo "prerm called with unknown argument \`$1'" >&2
+               exit 1
+
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
+

Reply via email to