Adding upstream version 0.9.0. upstream/0.9.0
authorAndriy Grytsenko <andrej@rep.kiev.ua>
Sat, 19 Nov 2016 19:36:48 +0000 (21:36 +0200)
committerAndriy Grytsenko <andrej@rep.kiev.ua>
Sat, 19 Nov 2016 19:36:48 +0000 (21:36 +0200)
136 files changed:
AUTHORS
ChangeLog
Makefile.in
TODO
aclocal.m4
config.h.in
configure
configure.ac
data/Makefile.in
data/two_panels/panels/top.in
data/ui/launchtaskbar.glade
data/ui/launchtaskbar.ui
data/ui/netstatus.glade
data/ui/netstatus.ui
lxpanel.pc.in
m4/intltool.m4 [deleted file]
man/Makefile.in
man/lxpanel.1
man/lxpanelctl.1
plugins/Makefile.am
plugins/Makefile.in
plugins/batt/batt.c
plugins/batt/batt_sys.c
plugins/batt/batt_sys.h
plugins/cpu/cpu.c
plugins/dclock.c
plugins/deskno/deskno.c
plugins/dirmenu.c
plugins/kbled/kbled.c
plugins/launch-button.c [new file with mode: 0644]
plugins/launch-button.h [new file with mode: 0644]
plugins/launchtaskbar.c
plugins/monitors/monitors.c
plugins/netstat/netstat.c
plugins/netstat/nsconfig.h
plugins/netstatus/netstatus-icon.c
plugins/netstatus/netstatus.c
plugins/pager.c
plugins/space.c [deleted file]
plugins/task-button.c [new file with mode: 0644]
plugins/task-button.h [new file with mode: 0644]
plugins/volume/volume-impl.c [deleted file]
plugins/volume/volume-impl.h [deleted file]
plugins/volume/volume.c [deleted file]
plugins/volume/volume_xpm.h [deleted file]
plugins/volumealsa/volumealsa.c
plugins/weather/weatherwidget.c
plugins/weather/yahooutil.c
plugins/wincmd.c
plugins/xkb/xkb-plugin.c
po/POTFILES.in
po/POTFILES.skip
po/af.po
po/ar.po
po/be.po
po/bg.po
po/bn.po
po/bn_IN.po
po/ca.po
po/cs.po
po/da.po
po/de.po
po/el.po
po/en_GB.po
po/es.po
po/et.po
po/eu.po
po/fa.po
po/fi.po
po/fo.po
po/fr.po
po/frp.po
po/gl.po
po/he.po
po/hr.po
po/hu.po
po/id.po
po/is.po
po/it.po
po/ja.po
po/kk.po
po/km.po
po/ko.po
po/lg.po
po/lt.po
po/lv.po
po/ml.po
po/ms.po
po/nb.po
po/nl.po
po/nn.po
po/pa.po
po/pl.po
po/ps.po
po/pt.po
po/pt_BR.po
po/ro.po
po/ru.po
po/sk.po
po/sl.po
po/sr.po
po/sr@latin.po
po/sv.po
po/te.po
po/th.po
po/tr.po
po/tt_RU.po
po/ug.po
po/uk.po
po/ur.po
po/ur_PK.po
po/vi.po
po/zh_CN.po
po/zh_HK.po
po/zh_TW.po
src/Makefile.am
src/Makefile.in
src/configurator.c
src/gtk-compat.h
src/gtk-run.c
src/icon-grid.c
src/icon-grid.h
src/input-button.c
src/lxpanelctl.c
src/lxpanelctl.h
src/main.c
src/misc.c
src/misc.h
src/panel-plugin-move.c [new file with mode: 0644]
src/panel.c
src/panel.h
src/plugin.c
src/plugin.h
src/private.h
src/space.c [new file with mode: 0644]
src/space.h [new file with mode: 0644]

diff --git a/AUTHORS b/AUTHORS
index c97ec8c..6875223 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -15,6 +15,10 @@ LXPanel - Lightweight X11 desktop panel
     Piotr Sipika <piotr.sipika@gmail.com>
     Raimar Bühmann <raimar@buehmann.de>
     Peter <ombalaxitabou@users.sf.net>
+    Balló György <ballogyor@gmail.com>
+    Rafał Mużyło <galtgendo@gmail.com>
+    Charles Lehner <cel10@users.sf.net>
+    Stanislav Kozina, Ersin <xersin@users.sf.net>
 
 [History]
 LXPanel is a derivative work from fbpanel [1] written by Anatoly Asviyan,
index 6f7561b..6cdf16a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,8 +1,95 @@
+0.9.0
+-------------------------------------------------------------------------
+* Added support for laptops with multiple batteries.
+* Added a way to scroll through workspaces by using the scroll wheel over
+    the deskno plugin.
+* Bunch of fixes for GTK+ 3.0 compatibility.
+* Fixed outdated lxpanel man page.
+* Fixed weather locations query (since YQL was changed recently).
+* Converted space plugin into internal PanelSpace widget in liblxpanel.
+* Converted task button into widget class to avoid ambiguous code.
+* Added support for third-party plugins localized descriptions.
+* Implemented "lxpanelctl command ..." to send message to panel plugin.
+* Added APIs for PanelIconGrid to draw focus on drop.
+* Converted launch button into widget class for more easy management.
+* Adjusted PanelIconGrid: min spacing is now 1, no_window flag is now
+    left unset by default, spacing is taken into account on overall size
+    to be consistent on chosen orientation.
+* Implemented dropping file or folder onto launch bar to create launcher.
+* Implemented dragging launchers around launchbars (between panels too).
+* Implemented dropping file or folder onto free panel space to create
+    launcher.
+* Implemented dragging launchers from launchbar to some free panel space.
+    When launcher dropped onto another place and former place's launchbar
+    becomes empty, it will not be replaced with a bootstrapping icon (as
+    it happens when last launcher is removed via configuration dialog)
+    but launchbar will be removed from the panel instead, that behavior
+    is more obvious and sensible.
+* Added stripping scheme from URI menu://applications/... when a launcher
+    is created, only menu-id itself should be used.
+* Implemented moving plugins across panel by means of middle button drag
+    and drop, i.e. middle-click it then drag, and plugin will follow the
+    mouse until middle button is released.
+* Merged 'volume' and 'volumealsa' plugins into single plugin which uses
+    the same interface but different driver, in dependency on how it was
+    built - either OSS or ALSA interface is used. Name 'volume' is used
+    for simplicity while 'volumealsa' is supported for compatibility.
+* Made default channel in 'volume' plugin definable in config. If there
+    is no config statement then plugin finds first usable one, the same
+    as before.
+* Made clicks for Toggle Mute, Show Slider and Open Mixer actions of the
+    'volume' plugin configurable. Defaults are the same: left-click shows
+    slider, middle-click toggles mute state.
+* Added support for 'PCM' and 'Headphone' channels for OSS mixer.
+* Added support for other (not default one) ALSA cards in 'volume' plugin
+    via 'CardNumber' setting.
+* Added hotkey support into 'volume' plugin to be able to use multimedia
+    keys for volume changing directly by plugin.
+* Fixed missing libkeybinder initialization (keybinding did not work).
+* Fixed check for attempt to add a binding for the same hotkey which is
+    already bound elsewhere.
+* Added a configuration dialog to the 'volume' plugin with all the new
+    settings available to choose and set, including preset of discovered
+    mixers, with ability to type own command as well.
+* Fixed crash on action on task window which was deleted while task menu
+    is still opened.
+* Fixed "dynamic" panel width allocation.
+* Fixed PanelIconGrid allocation in rigth-to-left languages, it was wrong
+    so some icons might be invisible or placed under other plugins.
+* Removed call to gtk_widget_set_style() from volume slider to fix colors
+    of current theme.
+* Changed icon size handling on task bar - it may now maintain the same
+    size as rest of icons. It may affect users who are used to have them
+    smaller, it's why this feature was made configurable, corresponding
+    config variable is UseSmallerIcons and default is 1 (old behavior).
+* Changed volume slider popup behavior - it now hides when loses focus.
+* Fixed invalid memory access in weather plugin.
+* Fixed incorrect reporting units on "Feel" value in weather plugin. YQL
+    always reports Fahrenheit degrees there.
+* Added a safeguard on menu cache returning items with empty Exec line.
+* Fixed maximizing windows using task bar, GDK functions not always work.
+* Fixed wrong bind of preferences dialog to the panel, which resulted in
+    other dialogs appear on the same workspace where preferences was.
+* Expanded launch buttons active area to launchbar borders so if clicked
+    even into desktop corner, it should activate button at that corner.
+* Fixed few memory leaks in 'batt' plugin.
+* Removed unwanted conversions with energy for charge in 'batt' plugin
+    which will mess up tooltip indications, and may make rate/percentage
+    calculations invalid.
+* Replaced Xclimsg() with Xclimsgx() to be screen aware with X11 message.
+* Added a workaround for WM like MWM which does not properly resize down
+    widgets of panel kind. It still leaves artefacts but is better now.
+* Added a workaround on GtkBox behavior which does not send allocation
+    requests to children in some cases, so resizing of launchtaskbar on
+    panel height change was broken.
+* Fixed PanelIconGrid layout on vertical panels with more than 1 column.
+
 0.8.2
 -------------------------------------------------------------------------
 * Fixed crash in taskbar plugin after number of desktops was updated.
 * Fixed incorrect panel geometry initialization.
 * Fixed crash with invalid size of icon in _NET_WM_ICON property.
+* Fixed memory leak on 'indicator' plugin destruction.
 * Replaced old commands:
     - Use notify send instead of xmessage
     - Use nm-connection-editor instead of network-admin
index edfaa15..a7eb286 100644 (file)
@@ -86,12 +86,12 @@ DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
        $(top_srcdir)/data/two_panels/panels/top.in \
        $(top_srcdir)/data/two_panels/panels/bottom.in AUTHORS COPYING \
        ChangeLog README TODO ar-lib compile config.guess config.sub \
-       depcomp install-sh missing ltmain.sh
+       install-sh missing ltmain.sh
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/m4/intltool.m4 \
-       $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
-       $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
-       $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+       $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+       $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+       $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
@@ -231,7 +231,6 @@ am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
 distcleancheck_listfiles = find . -type f -print
 ACLOCAL = @ACLOCAL@
 ALL_LINGUAS = @ALL_LINGUAS@
-ALL_PLUGINS_LIST = @ALL_PLUGINS_LIST@
 AMTAR = @AMTAR@
 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APPLET_CFLAGS = @APPLET_CFLAGS@
@@ -365,6 +364,7 @@ datarootdir = @datarootdir@
 docdir = @docdir@
 dvidir = @dvidir@
 exec_prefix = @exec_prefix@
+gtk_module = @gtk_module@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
diff --git a/TODO b/TODO
index 413bf75..1443db5 100644 (file)
--- a/TODO
+++ b/TODO
@@ -1,10 +1,6 @@
-* drag & drop plugins via middle button
 * "Move" option in plugin context menu
-* "lxpanelctl command ..."
 * LXPanelPluginInit::activatable flag to allow activation with hotkey
-* drag & drop launchers (LauncherButton widget as "application/x-lxpanel-launcher")
 * accessibility (keys-only; single-button-mouse; special devices)
-* 'volumealsa' improvements
 * compose new custom launcher in launchbar config dialog
 * special launchers support ()
 * launchbar template with LockScreen and Shutdown
 * hotkeys for launchers
 * support rounded corners
 * support keywords in gtk-run
-* convert Task into GtkWidget and use it to emit signals for menus and buttons
+* standalone run application with history shared with panel?
+* "lxpanelctl restart" with panel not running starts it?
 * make click-wait-release popdown popups similarly to as GtkMenuShell does
 * make lxpanel multiscreen-aware (build fb_ev_* and get_net_* into lxpanel)
 * improve startup time (move every non-instant operation into idle callback)
-* merge 'volume' into 'volumealsa' to have the same interface
 * support custom timezone in the 'dclock'
 * decide 'netstat' vs 'netstatus'
 * optional libnotify support (useful for battery and volume plugins)
 * pull improvements from Raspbian
 * add Most Recent support into 'menu' plugin
+* check and use weather-* standard themed icons for weather plugin
+* "Remove this Launch Button" option in launchbar context menu
+* 'usb-unmount' plugin
+* in 0.10.0 fix "GTK2+" string to just "GTK+"
+* show/hide Raise/Restore/Maximize/Iconify in button menu depending on task
+* get rid of GDK_ROOT_WINDOW() and gdk_get_default_root_window() and a_WM_STATE
index cffd875..41909d5 100644 (file)
@@ -456,6 +456,221 @@ sed 's/^/| /' conftest.foo >&AS_MESSAGE_LOG_FD
 fi])
 
 
+
+dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
+# serial 42 IT_PROG_INTLTOOL
+AC_DEFUN([IT_PROG_INTLTOOL], [
+AC_PREREQ([2.50])dnl
+AC_REQUIRE([AM_NLS])dnl
+
+case "$am__api_version" in
+    1.[01234])
+       AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
+    ;;
+    *)
+    ;;
+esac
+
+INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
+INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
+INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
+if test -n "$1"; then
+    AC_MSG_CHECKING([for intltool >= $1])
+    AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
+    test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
+       AC_MSG_ERROR([Your intltool is too old.  You need intltool $1 or later.])
+fi
+
+AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
+AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
+AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
+if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
+    AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
+fi
+
+if test -z "$AM_DEFAULT_VERBOSITY"; then
+  AM_DEFAULT_VERBOSITY=1
+fi
+AC_SUBST([AM_DEFAULT_VERBOSITY])
+
+INTLTOOL_V_MERGE='$(INTLTOOL__v_MERGE_$(V))'
+INTLTOOL__v_MERGE_='$(INTLTOOL__v_MERGE_$(AM_DEFAULT_VERBOSITY))'
+INTLTOOL__v_MERGE_0='@echo "  ITMRG " [$]@;'
+AC_SUBST(INTLTOOL_V_MERGE)
+AC_SUBST(INTLTOOL__v_MERGE_)
+AC_SUBST(INTLTOOL__v_MERGE_0)
+
+INTLTOOL_V_MERGE_OPTIONS='$(intltool__v_merge_options_$(V))'
+intltool__v_merge_options_='$(intltool__v_merge_options_$(AM_DEFAULT_VERBOSITY))'
+intltool__v_merge_options_0='-q'
+AC_SUBST(INTLTOOL_V_MERGE_OPTIONS)
+AC_SUBST(intltool__v_merge_options_)
+AC_SUBST(intltool__v_merge_options_0)
+
+  INTLTOOL_DESKTOP_RULE='%.desktop:   %.desktop.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+     INTLTOOL_KEYS_RULE='%.keys:      %.keys.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+     INTLTOOL_PROP_RULE='%.prop:      %.prop.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+      INTLTOOL_OAF_RULE='%.oaf:       %.oaf.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -p $(top_srcdir)/po $< [$]@'
+     INTLTOOL_PONG_RULE='%.pong:      %.pong.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+   INTLTOOL_SERVER_RULE='%.server:    %.server.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+    INTLTOOL_SHEET_RULE='%.sheet:     %.sheet.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+       INTLTOOL_UI_RULE='%.ui:        %.ui.in        $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+      INTLTOOL_XML_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+if test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge 5000; then
+      INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u --no-translations $< [$]@'
+else
+      INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)_it_tmp_dir=tmp.intltool.[$][$]RANDOM && mkdir [$][$]_it_tmp_dir && LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u [$][$]_it_tmp_dir $< [$]@ && rmdir [$][$]_it_tmp_dir'
+fi
+      INTLTOOL_XAM_RULE='%.xam:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+      INTLTOOL_KBD_RULE='%.kbd:       %.kbd.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+    INTLTOOL_CAVES_RULE='%.caves:     %.caves.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+  INTLTOOL_SCHEMAS_RULE='%.schemas:   %.schemas.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+    INTLTOOL_THEME_RULE='%.theme:     %.theme.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
+    INTLTOOL_SERVICE_RULE='%.service: %.service.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
+   INTLTOOL_POLICY_RULE='%.policy:    %.policy.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
+
+_IT_SUBST(INTLTOOL_DESKTOP_RULE)
+_IT_SUBST(INTLTOOL_DIRECTORY_RULE)
+_IT_SUBST(INTLTOOL_KEYS_RULE)
+_IT_SUBST(INTLTOOL_PROP_RULE)
+_IT_SUBST(INTLTOOL_OAF_RULE)
+_IT_SUBST(INTLTOOL_PONG_RULE)
+_IT_SUBST(INTLTOOL_SERVER_RULE)
+_IT_SUBST(INTLTOOL_SHEET_RULE)
+_IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
+_IT_SUBST(INTLTOOL_UI_RULE)
+_IT_SUBST(INTLTOOL_XAM_RULE)
+_IT_SUBST(INTLTOOL_KBD_RULE)
+_IT_SUBST(INTLTOOL_XML_RULE)
+_IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
+_IT_SUBST(INTLTOOL_CAVES_RULE)
+_IT_SUBST(INTLTOOL_SCHEMAS_RULE)
+_IT_SUBST(INTLTOOL_THEME_RULE)
+_IT_SUBST(INTLTOOL_SERVICE_RULE)
+_IT_SUBST(INTLTOOL_POLICY_RULE)
+
+# Check the gettext tools to make sure they are GNU
+AC_PATH_PROG(XGETTEXT, xgettext)
+AC_PATH_PROG(MSGMERGE, msgmerge)
+AC_PATH_PROG(MSGFMT, msgfmt)
+AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
+if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
+    AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
+fi
+xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
+mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
+mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
+if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
+    AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
+fi
+
+AC_PATH_PROG(INTLTOOL_PERL, perl)
+if test -z "$INTLTOOL_PERL"; then
+   AC_MSG_ERROR([perl not found])
+fi
+AC_MSG_CHECKING([for perl >= 5.8.1])
+$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
+if test $? -ne 0; then
+   AC_MSG_ERROR([perl 5.8.1 is required for intltool])
+else
+   IT_PERL_VERSION=`$INTLTOOL_PERL -e "printf '%vd', $^V"`
+   AC_MSG_RESULT([$IT_PERL_VERSION])
+fi
+if test "x$2" != "xno-xml"; then
+   AC_MSG_CHECKING([for XML::Parser])
+   if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
+       AC_MSG_RESULT([ok])
+   else
+       AC_MSG_ERROR([XML::Parser perl module is required for intltool])
+   fi
+fi
+
+# Substitute ALL_LINGUAS so we can use it in po/Makefile
+AC_SUBST(ALL_LINGUAS)
+
+# Set DATADIRNAME correctly if it is not set yet
+# (copied from glib-gettext.m4)
+if test -z "$DATADIRNAME"; then
+  AC_LINK_IFELSE(
+    [AC_LANG_PROGRAM([[]],
+                     [[extern int _nl_msg_cat_cntr;
+                       return _nl_msg_cat_cntr]])],
+    [DATADIRNAME=share],
+    [case $host in
+    *-*-solaris*)
+    dnl On Solaris, if bind_textdomain_codeset is in libc,
+    dnl GNU format message catalog is always supported,
+    dnl since both are added to the libc all together.
+    dnl Hence, we'd like to go with DATADIRNAME=share
+    dnl in this case.
+    AC_CHECK_FUNC(bind_textdomain_codeset,
+      [DATADIRNAME=share], [DATADIRNAME=lib])
+    ;;
+    *)
+    [DATADIRNAME=lib]
+    ;;
+    esac])
+fi
+AC_SUBST(DATADIRNAME)
+
+IT_PO_SUBDIR([po])
+
+])
+
+
+# IT_PO_SUBDIR(DIRNAME)
+# ---------------------
+# All po subdirs have to be declared with this macro; the subdir "po" is
+# declared by IT_PROG_INTLTOOL.
+#
+AC_DEFUN([IT_PO_SUBDIR],
+[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
+dnl
+dnl The following CONFIG_COMMANDS should be executed at the very end
+dnl of config.status.
+AC_CONFIG_COMMANDS_PRE([
+  AC_CONFIG_COMMANDS([$1/stamp-it], [
+    if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
+       AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
+    fi
+    rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
+    >"$1/stamp-it.tmp"
+    [sed '/^#/d
+        s/^[[].*] *//
+        /^[    ]*$/d
+       '"s|^|  $ac_top_srcdir/|" \
+      "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
+    ]
+    [sed '/^POTFILES =/,/[^\\]$/ {
+               /^POTFILES =/!d
+               r $1/POTFILES
+         }
+        ' "$1/Makefile.in" >"$1/Makefile"]
+    rm -f "$1/Makefile.tmp"
+    mv "$1/stamp-it.tmp" "$1/stamp-it"
+  ])
+])dnl
+])
+
+# _IT_SUBST(VARIABLE)
+# -------------------
+# Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
+#
+AC_DEFUN([_IT_SUBST],
+[
+AC_SUBST([$1])
+m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
+]
+)
+
+# deprecated macros
+AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
+# A hint is needed for aclocal from Automake <= 1.9.4:
+# AC_DEFUN([AC_PROG_INTLTOOL], ...)
+
+
 # nls.m4 serial 5 (gettext-0.18)
 dnl Copyright (C) 1995-2003, 2005-2006, 2008-2014 Free Software Foundation,
 dnl Inc.
@@ -1891,7 +2106,6 @@ AC_SUBST([am__tar])
 AC_SUBST([am__untar])
 ]) # _AM_PROG_TAR
 
-m4_include([m4/intltool.m4])
 m4_include([m4/libtool.m4])
 m4_include([m4/ltoptions.m4])
 m4_include([m4/ltsugar.m4])
index c79ebf7..79bd049 100644 (file)
@@ -1,5 +1,8 @@
 /* config.h.in.  Generated from configure.ac by autoheader.  */
 
+/* Define to disable using ALSA in 'volume' plugin. */
+#undef DISABLE_ALSA
+
 /* Disable menu related routines */
 #undef DISABLE_MENU
 
index cb83f44..4e14a31 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for lxpanel 0.8.2.
+# Generated by GNU Autoconf 2.69 for lxpanel 0.9.0.
 #
 # Report bugs to <http://lxde.org/>.
 #
@@ -590,8 +590,8 @@ MAKEFLAGS=
 # Identity of this package.
 PACKAGE_NAME='lxpanel'
 PACKAGE_TARNAME='lxpanel'
-PACKAGE_VERSION='0.8.2'
-PACKAGE_STRING='lxpanel 0.8.2'
+PACKAGE_VERSION='0.9.0'
+PACKAGE_STRING='lxpanel 0.9.0'
 PACKAGE_BUGREPORT='http://lxde.org/'
 PACKAGE_URL=''
 
@@ -654,7 +654,6 @@ XMKMF
 LIBXML2_LIBS
 LIBXML2_CFLAGS
 PLUGINS_LIST
-ALL_PLUGINS_LIST
 BUILD_PLUGIN_LOADER_FALSE
 BUILD_PLUGIN_LOADER_TRUE
 BUILD_OSS_PLUGINS_FALSE
@@ -675,6 +674,7 @@ ENABLE_INDICATOR_SUPPORT_FALSE
 ENABLE_INDICATOR_SUPPORT_TRUE
 KEYBINDER_LIBS
 KEYBINDER_CFLAGS
+gtk_module
 PACKAGE_LIBS
 PACKAGE_CFLAGS
 PKG_CONFIG_LIBDIR
@@ -1415,7 +1415,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures lxpanel 0.8.2 to adapt to many kinds of systems.
+\`configure' configures lxpanel 0.9.0 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1489,7 +1489,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of lxpanel 0.8.2:";;
+     short | recursive ) echo "Configuration of lxpanel 0.9.0:";;
    esac
   cat <<\_ACEOF
 
@@ -1531,8 +1531,8 @@ Optional Packages:
                          'all' builds all plugins (default), 'none' builds none
                          plugins prefixed with '-' are not built
                          Possible plugins are:
-                         netstatus, netstat, volume, volumealsa, cpu, deskno, batt,
-                         kbled, xkb, thermal, cpufreq, monitors, indicator, weather
+                         netstatus, netstat, volume, cpu, deskno, batt, kbled,
+                         xkb, thermal, cpufreq, monitors, indicator, weather
 
   --with-x                use the X Window System
 
@@ -1639,7 +1639,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-lxpanel configure 0.8.2
+lxpanel configure 0.9.0
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2008,7 +2008,7 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by lxpanel $as_me 0.8.2, which was
+It was created by lxpanel $as_me 0.9.0, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -2871,7 +2871,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='lxpanel'
- VERSION='0.8.2'
+ VERSION='0.9.0'
 
 
 cat >>confdefs.h <<_ACEOF
 
 
 if test "x$enable_gtk3" = "xyes" ; then
-  pkg_modules="$pkg_modules gtk+-3.0 libfm-gtk3 >= 1.2.0 libwnck-3.0"
+  gtk_module="gtk+-3.0"
+  pkg_modules="$pkg_modules $gtk_module libfm-gtk3 >= 1.2.0 libwnck-3.0"
   keybinder_module=keybinder-3.0
 else
-  pkg_modules="$pkg_modules gtk+-2.0 >= 2.18.0 libfm-gtk >= 1.2.0 libwnck-1.0"
+  gtk_module="gtk+-2.0 >= 2.18.0"
+  pkg_modules="$pkg_modules $gtk_module libfm-gtk >= 1.2.0 libwnck-1.0"
   keybinder_module=keybinder
 fi
 
@@ -12700,6 +12702,7 @@ fi
 
 
 
+
 pkg_failed=no
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for KEYBINDER" >&5
 $as_echo_n "checking for KEYBINDER... " >&6; }
@@ -13286,7 +13289,6 @@ fi
 plugin_netstatus=
 plugin_netstat=
 plugin_volume=
-plugin_volumealsa=
 plugin_cpu=
 plugin_deskno=
 plugin_batt=
@@ -13318,7 +13320,6 @@ ALL_PLUGINS_LIST="netstatus netstat volume volumealsa cpu deskno batt kbled xkb
 
 
 
-
 if test "$plugins" != "none"; then
     plugins=`echo $plugins | sed 's/,/ /g'`
     for plugin in $plugins
@@ -13367,16 +13368,11 @@ $as_echo "$plugins" >&6; }
 fi
 
 if test x"$compile_alsa" = "xno"; then
-    if test ! -z $plugin_volumealsa; then
-        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no ALSA headers/libraries found!" >&5
-$as_echo "no ALSA headers/libraries found!" >&6; }
-        plugin_volumealsa=
-    fi
-else
-        plugin_volume=
-fi
-if test ! -z $plugin_volume; then
-    for ac_header in sys/soundcard.h linux/soundcard.h
+
+$as_echo "#define DISABLE_ALSA 1" >>confdefs.h
+
+    if test -n $plugin_volume; then
+        for ac_header in sys/soundcard.h linux/soundcard.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
 
 done
 
-    if test x$ac_cv_header_sys_soundcard_h = xno && test x$ac_cv_header_linux_soundcard_h = xno; then
-        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no OSS headers found!" >&5
+        if test x$ac_cv_header_sys_soundcard_h = xno && test x$ac_cv_header_linux_soundcard_h = xno; then
+            { $as_echo "$as_me:${as_lineno-$LINENO}: result: no OSS headers found!" >&5
 $as_echo "no OSS headers found!" >&6; }
-        plugin_volume=
+            plugin_volume=
+        fi
+    fi
+else
+        if test -n $plugin_volumealsa; then
+        plugin_volume=volume.la
     fi
 fi
 
@@ -13404,7 +13405,6 @@ PLUGINS_LIST="\
     $plugin_netstatus \
     $plugin_netstat \
     $plugin_volume \
-    $plugin_volumealsa \
     $plugin_cpu \
     $plugin_deskno \
     $plugin_batt \
@@ -15721,7 +15721,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by lxpanel $as_me 0.8.2, which was
+This file was extended by lxpanel $as_me 0.9.0, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -15787,7 +15787,7 @@ _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-lxpanel config.status 0.8.2
+lxpanel config.status 0.9.0
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 
@@ -17608,12 +17608,8 @@ $as_echo "    netstatus - Monitor networking status" >&6; }
 $as_echo "    netstat - Monitor networking status" >&6; }
     fi
     if test x"$plugin_volume" != x; then
-        { $as_echo "$as_me:${as_lineno-$LINENO}: result:     volume - Display and adjust volume of sound card for OSS" >&5
-$as_echo "    volume - Display and adjust volume of sound card for OSS" >&6; }
-    fi
-    if test x"$plugin_volumealsa" != x; then
-        { $as_echo "$as_me:${as_lineno-$LINENO}: result:     volumealsa - Display and adjust volume of sound card for ALSA" >&5
-$as_echo "    volumealsa - Display and adjust volume of sound card for ALSA" >&6; }
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result:     volume - Display and adjust volume of sound card" >&5
+$as_echo "    volume - Display and adjust volume of sound card" >&6; }
     fi
     if test x"$plugin_cpu" != x; then
         { $as_echo "$as_me:${as_lineno-$LINENO}: result:     cpu - Display CPU loading" >&5
index 106f219..7543495 100644 (file)
@@ -1,5 +1,5 @@
 AC_PREREQ(2.53)
-AC_INIT(lxpanel, 0.8.2, http://lxde.org/)
+AC_INIT(lxpanel, 0.9.0, http://lxde.org/)
 AM_INIT_AUTOMAKE([-Wall foreign subdir-objects no-dist-gzip dist-xz])
 AC_CONFIG_HEADER([config.h])
 AC_CONFIG_MACRO_DIR([m4])
@@ -34,10 +34,12 @@ AC_HELP_STRING([--enable-gtk3],[enable to use gtk-3.0 instead of gtk-2.0]),
 esac],[])
 
 if test "x$enable_gtk3" = "xyes" ; then
-  pkg_modules="$pkg_modules gtk+-3.0 libfm-gtk3 >= 1.2.0 libwnck-3.0"
+  gtk_module="gtk+-3.0"
+  pkg_modules="$pkg_modules $gtk_module libfm-gtk3 >= 1.2.0 libwnck-3.0"
   keybinder_module=keybinder-3.0
 else
-  pkg_modules="$pkg_modules gtk+-2.0 >= 2.18.0 libfm-gtk >= 1.2.0 libwnck-1.0"
+  gtk_module="gtk+-2.0 >= 2.18.0"
+  pkg_modules="$pkg_modules $gtk_module libfm-gtk >= 1.2.0 libwnck-1.0"
   keybinder_module=keybinder
 fi
 
@@ -48,6 +50,7 @@ pkg_modules="$pkg_modules \
 PKG_CHECK_MODULES(PACKAGE, [$pkg_modules])
 AC_SUBST(PACKAGE_CFLAGS)
 AC_SUBST(PACKAGE_LIBS)
+AC_SUBST(gtk_module)
 
 PKG_CHECK_MODULES(KEYBINDER, [$keybinder_module])
 AC_SUBST(KEYBINDER_CFLAGS)
@@ -188,7 +191,6 @@ dnl Here are plugin listing.
 plugin_netstatus=
 plugin_netstat=
 plugin_volume=
-plugin_volumealsa=
 plugin_cpu=
 plugin_deskno=
 plugin_batt=
@@ -206,8 +208,8 @@ AC_ARG_WITH(plugins,
 [                         'all' builds all plugins (default), 'none' builds none ]
 [                         plugins prefixed with '-' are not built]
 [                         Possible plugins are: ]
-[                         netstatus, netstat, volume, volumealsa, cpu, deskno, batt,]
-[                         kbled, xkb, thermal, cpufreq, monitors, indicator, weather]
+[                         netstatus, netstat, volume, cpu, deskno, batt, kbled,]
+[                         xkb, thermal, cpufreq, monitors, indicator, weather]
 , plugins="$withval",[plugins="all"])
 
 if test x"$plugins" != xall -a x"$plugins" != xnone; then
@@ -218,7 +220,6 @@ if test x"$plugins" != xall -a x"$plugins" != xnone; then
 fi
 
 ALL_PLUGINS_LIST="netstatus netstat volume volumealsa cpu deskno batt kbled xkb thermal cpufreq monitors indicator weather"
-AC_SUBST(ALL_PLUGINS_LIST)
 
 AC_DEFUN([check_plugin_name],[
     plugin_found=false
@@ -259,19 +260,18 @@ fi
 
 dnl FIXME: OSS/ALSA checking
 if test x"$compile_alsa" = "xno"; then
-    if test ! -z $plugin_volumealsa; then
-        AC_MSG_RESULT([no ALSA headers/libraries found!])
-        plugin_volumealsa=
+    AC_DEFINE(DISABLE_ALSA, [1], [Define to disable using ALSA in 'volume' plugin.])
+    if test -n $plugin_volume; then
+        AC_CHECK_HEADERS([sys/soundcard.h linux/soundcard.h])
+        if test x$ac_cv_header_sys_soundcard_h = xno && test x$ac_cv_header_linux_soundcard_h = xno; then
+            AC_MSG_RESULT([no OSS headers found!])
+            plugin_volume=
+        fi
     fi
 else
-    dnl force OSS plugin to <null>
-    plugin_volume=
-fi
-if test ! -z $plugin_volume; then
-    AC_CHECK_HEADERS([sys/soundcard.h linux/soundcard.h])
-    if test x$ac_cv_header_sys_soundcard_h = xno && test x$ac_cv_header_linux_soundcard_h = xno; then
-        AC_MSG_RESULT([no OSS headers found!])
-        plugin_volume=
+    dnl use $plugin_volumealsa for backward compatibility
+    if test -n $plugin_volumealsa; then
+        plugin_volume=volume.la
     fi
 fi
 
@@ -284,7 +284,6 @@ PLUGINS_LIST="\
     $plugin_netstatus \
     $plugin_netstat \
     $plugin_volume \
-    $plugin_volumealsa \
     $plugin_cpu \
     $plugin_deskno \
     $plugin_batt \
@@ -421,10 +420,7 @@ echo Building dynamic plugins:
         AC_MSG_RESULT([    netstat - Monitor networking status])
     fi
     if test x"$plugin_volume" != x; then
-        AC_MSG_RESULT([    volume - Display and adjust volume of sound card for OSS])
-    fi
-    if test x"$plugin_volumealsa" != x; then
-        AC_MSG_RESULT([    volumealsa - Display and adjust volume of sound card for ALSA])
+        AC_MSG_RESULT([    volume - Display and adjust volume of sound card])
     fi
     if test x"$plugin_cpu" != x; then
         AC_MSG_RESULT([    cpu - Display CPU loading])
index f4d0017..6f40031 100644 (file)
@@ -81,10 +81,10 @@ host_triplet = @host@
 subdir = data
 DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/m4/intltool.m4 \
-       $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
-       $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
-       $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+       $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+       $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+       $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -149,7 +149,6 @@ am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ALL_LINGUAS = @ALL_LINGUAS@
-ALL_PLUGINS_LIST = @ALL_PLUGINS_LIST@
 AMTAR = @AMTAR@
 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APPLET_CFLAGS = @APPLET_CFLAGS@
@@ -283,6 +282,7 @@ datarootdir = @datarootdir@
 docdir = @docdir@
 dvidir = @dvidir@
 exec_prefix = @exec_prefix@
+gtk_module = @gtk_module@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
index 6052a56..647bf3b 100644 (file)
@@ -76,7 +76,12 @@ Plugin {
 }
 
 Plugin {
-    type = volumealsa
+    type = volume
+    Config {
+        VolumeMuteKey = XF86AudioMute
+        VolumeDownKey = XF86AudioLowerVolume
+        VolumeUpKey = XF86AudioRaiseVolume
+    }
 }
 
 Plugin {
index 0eac29e..41a79b3 100644 (file)
@@ -8,7 +8,8 @@
     <property name="page_increment">10</property>
   </object>
   <object class="GtkAdjustment" id="adjustment_spacing">
-    <property name="upper">1000</property>
+    <property name="lower">1</property>
+    <property name="upper">100</property>
     <property name="step_increment">1</property>
     <property name="page_increment">10</property>
   </object>
                   </packing>
                 </child>
                 <child>
+                  <object class="GtkCheckButton" id="checkbutton_use_smaller_icons">
+                    <property name="label" translatable="yes">Show task icons smaller than rest of panel icons</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">False</property>
+                    <property name="draw_indicator">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">True</property>
+                    <property name="fill">True</property>
+                    <property name="position">9</property>
+                  </packing>
+                </child>
+                <child>
                   <object class="GtkHBox" id="hbox2">
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
                   <packing>
                     <property name="expand">True</property>
                     <property name="fill">True</property>
-                    <property name="position">9</property>
+                    <property name="position">10</property>
                   </packing>
                 </child>
                 <child>
                   <packing>
                     <property name="expand">True</property>
                     <property name="fill">True</property>
-                    <property name="position">10</property>
+                    <property name="position">11</property>
                   </packing>
                 </child>
               </object>
index 0c5d6d3..b6df51e 100644 (file)
@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?><interface><requires lib="gtk+" version="2.16"/>
-<object class="GtkAdjustment" id="adjustment_max_width"><property name="upper">1000</property><property name="step_increment">1</property><property name="page_increment">10</property></object><object class="GtkAdjustment" id="adjustment_spacing"><property name="upper">1000</property><property name="step_increment">1</property><property name="page_increment">10</property></object><object class="GtkListStore" id="defined_store"><columns>
+<object class="GtkAdjustment" id="adjustment_max_width"><property name="upper">1000</property><property name="step_increment">1</property><property name="page_increment">10</property></object><object class="GtkAdjustment" id="adjustment_spacing"><property name="lower">1</property><property name="upper">100</property><property name="step_increment">1</property><property name="page_increment">10</property></object><object class="GtkListStore" id="defined_store"><columns>
 <column type="GdkPixbuf"/>
 <column type="gchararray"/>
 <column type="gchararray"/>
-<column type="gpointer"/></columns></object><object class="GtkDialog" id="dlg"><property name="can_focus">False</property><property name="border_width">10</property><property name="title" translatable="yes">Application Launch and Task Bar</property><property name="window_position">center</property><property name="default_width">640</property><property name="default_height">440</property><property name="type_hint">dialog</property><child internal-child="vbox"><object class="GtkVBox" id="dialog-vbox"><property name="visible">True</property><property name="can_focus">False</property><property name="spacing">6</property><child><object class="GtkHBox" id="hbox_mode"><property name="visible">True</property><property name="can_focus">False</property><property name="spacing">12</property><child><object class="GtkLabel" id="label5"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes" comments="Launchtaskbar mode: launchbar, taskbar, or combined">&lt;b&gt;Mode:&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkComboBox" id="combobox_mode"><property name="visible">True</property><property name="can_focus">False</property><property name="model">liststore_mode</property><child><object class="GtkCellRendererText" id="cellrenderertext1"/><attributes><attribute name="text">0</attribute></attributes></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkNotebook" id="notebook"><property name="visible">True</property><property name="can_focus">True</property><child><object class="GtkHBox" id="hbox1"><property name="visible">True</property><property name="can_focus">False</property><property name="spacing">12</property><child><object class="GtkVBox" id="vbox_defined"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkScrolledWindow" id="scroll1"><property name="visible">True</property><property name="can_focus">True</property><property name="hscrollbar_policy">automatic</property><property name="vscrollbar_policy">automatic</property><property name="shadow_type">etched-in</property><child><object class="GtkTreeView" id="defined_view"><property name="visible">True</property><property name="can_focus">True</property><property name="model">defined_store</property><property name="headers_clickable">False</property><property name="search_column">1</property><child><object class="GtkTreeViewColumn" id="defined_col"><property name="title" translatable="yes">Launchers</property><property name="expand">True</property></object></child></object></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkLabel" id="label_def_app_exec"><property name="visible">True</property><property name="can_focus">False</property><property name="ellipsize">end</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">1</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkVBox" id="vbox1"><property name="visible">True</property><property name="can_focus">False</property><property name="spacing">6</property><child><object class="GtkButton" id="button_add"><property name="label">gtk-add</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkButton" id="button_remove"><property name="label">gtk-remove</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">1</property></packing></child><child><object class="GtkButton" id="button_up"><property name="label">gtk-go-up</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">2</property></packing></child><child><object class="GtkButton" id="button_down"><property name="label">gtk-go-down</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">3</property></packing></child></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">1</property></packing></child><child><object class="GtkVBox" id="vbox_menu"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkScrolledWindow" id="menu_view_window"><property name="visible">True</property><property name="can_focus">True</property><property name="hscrollbar_policy">automatic</property><property name="vscrollbar_policy">automatic</property><property name="shadow_type">etched-in</property><child><placeholder/></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkLabel" id="label_menu_app_exec"><property name="visible">True</property><property name="can_focus">False</property><property name="ellipsize">end</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">1</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">2</property></packing></child></object></child><child type="tab"><object class="GtkLabel" id="label1"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes">&lt;b&gt;Launchbar&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="tab_fill">False</property></packing></child><child><object class="GtkVBox" id="vbox2"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkCheckButton" id="checkbutton_show_tooltips"><property name="label" translatable="yes">Show tooltips</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_icons_only"><property name="label" translatable="yes">Icons only</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">1</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_flat_buttons"><property name="label" translatable="yes">Flat buttons</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">2</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_show_all_desks"><property name="label" translatable="yes">Show windows from all desktops</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">3</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_same_monitor_only"><property name="label" translatable="yes">Only show windows on the same monitor as the task bar</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">4</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_mouse_wheel"><property name="label" translatable="yes">Use mouse wheel</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">5</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_urgency_hint"><property name="label" translatable="yes">Flash when there is any window requiring attention</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">6</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_grouped_tasks"><property name="label" translatable="yes">Combine multiple application windows into a single button</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">7</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_disable_taskbar_upscale"><property name="label" translatable="yes">Disable enlargement for small task icons</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">8</property></packing></child><child><object class="GtkHBox" id="hbox2"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkLabel" id="label3"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes">Maximum width of task button</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="padding">2</property><property name="position">0</property></packing></child><child><object class="GtkSpinButton" id="spinbutton_max_width"><property name="visible">True</property><property name="can_focus">True</property><property name="invisible_char">•</property><property name="primary_icon_activatable">False</property><property name="secondary_icon_activatable">False</property><property name="primary_icon_sensitive">True</property><property name="secondary_icon_sensitive">True</property><property name="adjustment">adjustment_max_width</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="padding">3</property><property name="position">1</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">9</property></packing></child><child><object class="GtkHBox" id="hbox3"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkLabel" id="label4"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes">Spacing</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="padding">2</property><property name="position">0</property></packing></child><child><object class="GtkSpinButton" id="spinbutton_spacing"><property name="visible">True</property><property name="can_focus">True</property><property name="invisible_char">•</property><property name="primary_icon_activatable">False</property><property name="secondary_icon_activatable">False</property><property name="primary_icon_sensitive">True</property><property name="secondary_icon_sensitive">True</property><property name="adjustment">adjustment_spacing</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="padding">3</property><property name="position">1</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">10</property></packing></child></object><packing><property name="position">1</property></packing></child><child type="tab"><object class="GtkLabel" id="label2"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes">&lt;b&gt;Taskbar&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="position">1</property><property name="tab_fill">False</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">1</property></packing></child><child internal-child="action_area"><object class="GtkHButtonBox" id="dialog-action_area"><property name="visible">True</property><property name="can_focus">False</property><property name="layout_style">end</property><child><object class="GtkButton" id="close"><property name="label">gtk-close</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child></object><packing><property name="expand">False</property><property name="fill">True</property><property name="pack_type">end</property><property name="position">2</property></packing></child></object></child><action-widgets><action-widget response="-7">close</action-widget></action-widgets></object><object class="GtkListStore" id="liststore_mode"><columns>
+<column type="gpointer"/></columns></object><object class="GtkDialog" id="dlg"><property name="can_focus">False</property><property name="border_width">10</property><property name="title" translatable="yes">Application Launch and Task Bar</property><property name="window_position">center</property><property name="default_width">640</property><property name="default_height">440</property><property name="type_hint">dialog</property><child internal-child="vbox"><object class="GtkVBox" id="dialog-vbox"><property name="visible">True</property><property name="can_focus">False</property><property name="spacing">6</property><child><object class="GtkHBox" id="hbox_mode"><property name="visible">True</property><property name="can_focus">False</property><property name="spacing">12</property><child><object class="GtkLabel" id="label5"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes" comments="Launchtaskbar mode: launchbar, taskbar, or combined">&lt;b&gt;Mode:&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkComboBox" id="combobox_mode"><property name="visible">True</property><property name="can_focus">False</property><property name="model">liststore_mode</property><child><object class="GtkCellRendererText" id="cellrenderertext1"/><attributes><attribute name="text">0</attribute></attributes></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkNotebook" id="notebook"><property name="visible">True</property><property name="can_focus">True</property><child><object class="GtkHBox" id="hbox1"><property name="visible">True</property><property name="can_focus">False</property><property name="spacing">12</property><child><object class="GtkVBox" id="vbox_defined"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkScrolledWindow" id="scroll1"><property name="visible">True</property><property name="can_focus">True</property><property name="hscrollbar_policy">automatic</property><property name="vscrollbar_policy">automatic</property><property name="shadow_type">etched-in</property><child><object class="GtkTreeView" id="defined_view"><property name="visible">True</property><property name="can_focus">True</property><property name="model">defined_store</property><property name="headers_clickable">False</property><property name="search_column">1</property><child><object class="GtkTreeViewColumn" id="defined_col"><property name="title" translatable="yes">Launchers</property><property name="expand">True</property></object></child></object></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkLabel" id="label_def_app_exec"><property name="visible">True</property><property name="can_focus">False</property><property name="ellipsize">end</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">1</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkVBox" id="vbox1"><property name="visible">True</property><property name="can_focus">False</property><property name="spacing">6</property><child><object class="GtkButton" id="button_add"><property name="label">gtk-add</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkButton" id="button_remove"><property name="label">gtk-remove</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">1</property></packing></child><child><object class="GtkButton" id="button_up"><property name="label">gtk-go-up</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">2</property></packing></child><child><object class="GtkButton" id="button_down"><property name="label">gtk-go-down</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">3</property></packing></child></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">1</property></packing></child><child><object class="GtkVBox" id="vbox_menu"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkScrolledWindow" id="menu_view_window"><property name="visible">True</property><property name="can_focus">True</property><property name="hscrollbar_policy">automatic</property><property name="vscrollbar_policy">automatic</property><property name="shadow_type">etched-in</property><child><placeholder/></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkLabel" id="label_menu_app_exec"><property name="visible">True</property><property name="can_focus">False</property><property name="ellipsize">end</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="position">1</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">2</property></packing></child></object></child><child type="tab"><object class="GtkLabel" id="label1"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes">&lt;b&gt;Launchbar&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="tab_fill">False</property></packing></child><child><object class="GtkVBox" id="vbox2"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkCheckButton" id="checkbutton_show_tooltips"><property name="label" translatable="yes">Show tooltips</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">0</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_icons_only"><property name="label" translatable="yes">Icons only</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">1</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_flat_buttons"><property name="label" translatable="yes">Flat buttons</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">2</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_show_all_desks"><property name="label" translatable="yes">Show windows from all desktops</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">3</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_same_monitor_only"><property name="label" translatable="yes">Only show windows on the same monitor as the task bar</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">4</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_mouse_wheel"><property name="label" translatable="yes">Use mouse wheel</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">5</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_urgency_hint"><property name="label" translatable="yes">Flash when there is any window requiring attention</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">6</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_grouped_tasks"><property name="label" translatable="yes">Combine multiple application windows into a single button</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">7</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_disable_taskbar_upscale"><property name="label" translatable="yes">Disable enlargement for small task icons</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">8</property></packing></child><child><object class="GtkCheckButton" id="checkbutton_use_smaller_icons"><property name="label" translatable="yes">Show task icons smaller than rest of panel icons</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">False</property><property name="draw_indicator">True</property></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">9</property></packing></child><child><object class="GtkHBox" id="hbox2"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkLabel" id="label3"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes">Maximum width of task button</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="padding">2</property><property name="position">0</property></packing></child><child><object class="GtkSpinButton" id="spinbutton_max_width"><property name="visible">True</property><property name="can_focus">True</property><property name="invisible_char">•</property><property name="primary_icon_activatable">False</property><property name="secondary_icon_activatable">False</property><property name="primary_icon_sensitive">True</property><property name="secondary_icon_sensitive">True</property><property name="adjustment">adjustment_max_width</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="padding">3</property><property name="position">1</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">10</property></packing></child><child><object class="GtkHBox" id="hbox3"><property name="visible">True</property><property name="can_focus">False</property><child><object class="GtkLabel" id="label4"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes">Spacing</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="padding">2</property><property name="position">0</property></packing></child><child><object class="GtkSpinButton" id="spinbutton_spacing"><property name="visible">True</property><property name="can_focus">True</property><property name="invisible_char">•</property><property name="primary_icon_activatable">False</property><property name="secondary_icon_activatable">False</property><property name="primary_icon_sensitive">True</property><property name="secondary_icon_sensitive">True</property><property name="adjustment">adjustment_spacing</property></object><packing><property name="expand">False</property><property name="fill">True</property><property name="padding">3</property><property name="position">1</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">11</property></packing></child></object><packing><property name="position">1</property></packing></child><child type="tab"><object class="GtkLabel" id="label2"><property name="visible">True</property><property name="can_focus">False</property><property name="label" translatable="yes">&lt;b&gt;Taskbar&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="position">1</property><property name="tab_fill">False</property></packing></child></object><packing><property name="expand">True</property><property name="fill">True</property><property name="position">1</property></packing></child><child internal-child="action_area"><object class="GtkHButtonBox" id="dialog-action_area"><property name="visible">True</property><property name="can_focus">False</property><property name="layout_style">end</property><child><object class="GtkButton" id="close"><property name="label">gtk-close</property><property name="visible">True</property><property name="can_focus">True</property><property name="receives_default">True</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child></object><packing><property name="expand">False</property><property name="fill">True</property><property name="pack_type">end</property><property name="position">2</property></packing></child></object></child><action-widgets><action-widget response="-7">close</action-widget></action-widgets></object><object class="GtkListStore" id="liststore_mode"><columns>
 <column type="gchararray"/></columns><data><row><col id="0" translatable="yes">Only Application Launch Bar</col></row><row><col id="0" translatable="yes">Only Task Bar (Window List)</col></row><row><col id="0" translatable="yes">Integrated Application Launch Bar and Task Bar</col></row></data></object><object class="GtkTreeStore" id="menu_store"><columns>
 <column type="GdkPixbuf"/>
 <column type="gchararray"/>
index fc956d3..8dc995a 100644 (file)
@@ -8,7 +8,6 @@
     <property name="window_position">center</property>
     <property name="default_width">300</property>
     <property name="type_hint">dialog</property>
-    <property name="has_separator">False</property>
     <child internal-child="vbox">
       <object class="GtkVBox" id="dialog-vbox2">
         <property name="visible">True</property>
index 8d18249..b252b9c 100644 (file)
@@ -1,2 +1,2 @@
 <?xml version="1.0"?><interface><requires lib="gtk+" version="2.16"/>
-<object class="GtkDialog" id="network_status_dialog"><property name="border_width">5</property><property name="resizable">False</property><property name="window_position">center</property><property name="default_width">300</property><property name="type_hint">dialog</property><property name="has_separator">False</property><child internal-child="vbox"><object class="GtkVBox" id="dialog-vbox2"><property name="visible">True</property><property name="spacing">2</property><child><object class="GtkNotebook" id="notebook1"><property name="visible">True</property><property name="can_focus">True</property><property name="border_width">5</property><child><object class="GtkVBox" id="vbox1"><property name="visible">True</property><property name="border_width">12</property><property name="spacing">18</property><child><object class="GtkVBox" id="connection_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="label3"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Connection&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox6"><property name="visible">True</property><child><object class="GtkLabel" id="label43"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="connection_hbox"><property name="visible">True</property><property name="spacing">12</property><child><object class="GtkTable" id="connection_table"><property name="visible">True</property><property name="n_rows">2</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="label5"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Status:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="status_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="label16"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">_Name:</property><property name="use_underline">True</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkComboBox" id="name_combo"><property name="visible">True</property><property name="can_focus">False</property><property name="has_entry">True</property><child internal-child="entry"><object class="GtkEntry" id="combobox-entry"><property name="can_focus">True</property></object></child></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options"></property><property name="y_options"></property></packing></child></object><packing><property name="position">0</property></packing></child><child><placeholder/></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">0</property></packing></child><child><object class="GtkVBox" id="activity_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="label4"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Activity&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox8"><property name="visible">True</property><child><object class="GtkLabel" id="label44"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkTable" id="table2"><property name="visible">True</property><property name="n_rows">2</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="received_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="sent_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="label11"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Received:</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="label12"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Sent:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">1</property></packing></child><child><object class="GtkVBox" id="signal_strength_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="label48"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Signal Strength&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox14"><property name="visible">True</property><child><object class="GtkLabel" id="label49"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox15"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkProgressBar" id="signal_strength_bar"><property name="visible">True</property><property name="pulse_step">0.10000000149</property></object><packing><property name="position">0</property></packing></child><child><object class="GtkLabel" id="signal_strength_label"><property name="visible">True</property><property name="label" translatable="yes">0%</property></object><packing><property name="expand">False</property><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">2</property></packing></child></object></child><child type="tab"><object class="GtkLabel" id="label1"><property name="visible">True</property><property name="label" translatable="yes">General</property></object><packing><property name="tab_fill">False</property></packing></child><child><object class="GtkVBox" id="vbox2"><property name="visible">True</property><property name="border_width">12</property><property name="spacing">18</property><child><object class="GtkVBox" id="inet4_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="label25"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Internet Protocol (IPv4)&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox11"><property name="visible">True</property><child><object class="GtkLabel" id="label45"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkTable" id="inet4_table"><property name="visible">True</property><property name="n_rows">4</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="inet4_addr_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Address:</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_dest_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Destination:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_bcast_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Broadcast:</property></object><packing><property name="top_attach">2</property><property name="bottom_attach">3</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_mask_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Subnet Mask:</property></object><packing><property name="top_attach">3</property><property name="bottom_attach">4</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_addr_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_dest_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_bcast_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">2</property><property name="bottom_attach">3</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_mask_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">3</property><property name="bottom_attach">4</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">0</property></packing></child><child><object class="GtkVBox" id="inet6_frame"><property name="spacing">6</property><child><object class="GtkLabel" id="label26"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Internet Protocol (IPv6)&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox12"><property name="visible">True</property><child><object class="GtkLabel" id="label46"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkTable" id="table5"><property name="visible">True</property><property name="n_rows">2</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="label39"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Address:</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="label40"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Scope:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet6_addr_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet6_scope_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">1</property></packing></child><child><object class="GtkVBox" id="dev_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="dev_label"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Network Device&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox13"><property name="visible">True</property><child><object class="GtkLabel" id="label47"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkTable" id="table6"><property name="visible">True</property><property name="n_rows">2</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="dev_addr_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Address:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="dev_addr_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="dev_type_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="dev_type_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Type:</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">2</property></packing></child></object><packing><property name="position">1</property></packing></child><child type="tab"><object class="GtkLabel" id="label2"><property name="visible">True</property><property name="label" translatable="yes">Support</property></object><packing><property name="position">1</property><property name="tab_fill">False</property></packing></child></object><packing><property name="position">1</property></packing></child><child internal-child="action_area"><object class="GtkHButtonBox" id="dialog-action_area2"><property name="visible">True</property><property name="layout_style">end</property><child><object class="GtkButton" id="helpbutton1"><property name="label">gtk-help</property><property name="can_focus">True</property><property name="can_default">True</property><property name="has_default">True</property><property name="receives_default">False</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkButton" id="configure_button"><property name="visible">True</property><property name="can_focus">True</property><property name="can_default">True</property><property name="receives_default">False</property><child><object class="GtkAlignment" id="alignment2"><property name="visible">True</property><property name="xscale">0</property><property name="yscale">0</property><child><object class="GtkHBox" id="hbox5"><property name="visible">True</property><property name="spacing">2</property><child><object class="GtkImage" id="image2"><property name="visible">True</property><property name="stock">gtk-preferences</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkLabel" id="label42"><property name="visible">True</property><property name="label" translatable="yes">Con_figure</property><property name="use_underline">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">1</property></packing></child></object></child></object></child></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">1</property></packing></child><child><object class="GtkButton" id="close_button"><property name="label">gtk-close</property><property name="visible">True</property><property name="can_focus">True</property><property name="can_default">True</property><property name="has_default">True</property><property name="receives_default">False</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">2</property></packing></child></object><packing><property name="expand">False</property><property name="pack_type">end</property><property name="position">0</property></packing></child></object></child><action-widgets><action-widget response="-11">helpbutton1</action-widget><action-widget response="0">configure_button</action-widget><action-widget response="-7">close_button</action-widget></action-widgets></object></interface>
+<object class="GtkDialog" id="network_status_dialog"><property name="border_width">5</property><property name="resizable">False</property><property name="window_position">center</property><property name="default_width">300</property><property name="type_hint">dialog</property><child internal-child="vbox"><object class="GtkVBox" id="dialog-vbox2"><property name="visible">True</property><property name="spacing">2</property><child><object class="GtkNotebook" id="notebook1"><property name="visible">True</property><property name="can_focus">True</property><property name="border_width">5</property><child><object class="GtkVBox" id="vbox1"><property name="visible">True</property><property name="border_width">12</property><property name="spacing">18</property><child><object class="GtkVBox" id="connection_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="label3"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Connection&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox6"><property name="visible">True</property><child><object class="GtkLabel" id="label43"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="connection_hbox"><property name="visible">True</property><property name="spacing">12</property><child><object class="GtkTable" id="connection_table"><property name="visible">True</property><property name="n_rows">2</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="label5"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Status:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="status_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="label16"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">_Name:</property><property name="use_underline">True</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkComboBox" id="name_combo"><property name="visible">True</property><property name="can_focus">False</property><property name="has_entry">True</property><child internal-child="entry"><object class="GtkEntry" id="combobox-entry"><property name="can_focus">True</property></object></child></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options"></property><property name="y_options"></property></packing></child></object><packing><property name="position">0</property></packing></child><child><placeholder/></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">0</property></packing></child><child><object class="GtkVBox" id="activity_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="label4"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Activity&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox8"><property name="visible">True</property><child><object class="GtkLabel" id="label44"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkTable" id="table2"><property name="visible">True</property><property name="n_rows">2</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="received_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="sent_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="label11"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Received:</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="label12"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Sent:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">1</property></packing></child><child><object class="GtkVBox" id="signal_strength_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="label48"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Signal Strength&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox14"><property name="visible">True</property><child><object class="GtkLabel" id="label49"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox15"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkProgressBar" id="signal_strength_bar"><property name="visible">True</property><property name="pulse_step">0.10000000149</property></object><packing><property name="position">0</property></packing></child><child><object class="GtkLabel" id="signal_strength_label"><property name="visible">True</property><property name="label" translatable="yes">0%</property></object><packing><property name="expand">False</property><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">2</property></packing></child></object></child><child type="tab"><object class="GtkLabel" id="label1"><property name="visible">True</property><property name="label" translatable="yes">General</property></object><packing><property name="tab_fill">False</property></packing></child><child><object class="GtkVBox" id="vbox2"><property name="visible">True</property><property name="border_width">12</property><property name="spacing">18</property><child><object class="GtkVBox" id="inet4_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="label25"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Internet Protocol (IPv4)&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox11"><property name="visible">True</property><child><object class="GtkLabel" id="label45"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkTable" id="inet4_table"><property name="visible">True</property><property name="n_rows">4</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="inet4_addr_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Address:</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_dest_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Destination:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_bcast_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Broadcast:</property></object><packing><property name="top_attach">2</property><property name="bottom_attach">3</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_mask_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Subnet Mask:</property></object><packing><property name="top_attach">3</property><property name="bottom_attach">4</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_addr_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_dest_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_bcast_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">2</property><property name="bottom_attach">3</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet4_mask_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">3</property><property name="bottom_attach">4</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">0</property></packing></child><child><object class="GtkVBox" id="inet6_frame"><property name="spacing">6</property><child><object class="GtkLabel" id="label26"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Internet Protocol (IPv6)&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox12"><property name="visible">True</property><child><object class="GtkLabel" id="label46"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkTable" id="table5"><property name="visible">True</property><property name="n_rows">2</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="label39"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Address:</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="label40"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Scope:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet6_addr_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="inet6_scope_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">1</property></packing></child><child><object class="GtkVBox" id="dev_frame"><property name="visible">True</property><property name="spacing">6</property><child><object class="GtkLabel" id="dev_label"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">&lt;b&gt;Network Device&lt;/b&gt;</property><property name="use_markup">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkHBox" id="hbox13"><property name="visible">True</property><child><object class="GtkLabel" id="label47"><property name="visible">True</property><property name="label">    </property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkTable" id="table6"><property name="visible">True</property><property name="n_rows">2</property><property name="n_columns">2</property><property name="column_spacing">12</property><property name="row_spacing">6</property><child><object class="GtkLabel" id="dev_addr_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Address:</property></object><packing><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="dev_addr_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="top_attach">1</property><property name="bottom_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="dev_type_label"><property name="visible">True</property><property name="can_focus">True</property><property name="xalign">0</property><property name="selectable">True</property></object><packing><property name="left_attach">1</property><property name="right_attach">2</property><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child><child><object class="GtkLabel" id="dev_type_title"><property name="visible">True</property><property name="xalign">0</property><property name="label" translatable="yes">Type:</property></object><packing><property name="x_options">GTK_FILL</property><property name="y_options"></property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="position">1</property></packing></child></object><packing><property name="expand">False</property><property name="position">2</property></packing></child></object><packing><property name="position">1</property></packing></child><child type="tab"><object class="GtkLabel" id="label2"><property name="visible">True</property><property name="label" translatable="yes">Support</property></object><packing><property name="position">1</property><property name="tab_fill">False</property></packing></child></object><packing><property name="position">1</property></packing></child><child internal-child="action_area"><object class="GtkHButtonBox" id="dialog-action_area2"><property name="visible">True</property><property name="layout_style">end</property><child><object class="GtkButton" id="helpbutton1"><property name="label">gtk-help</property><property name="can_focus">True</property><property name="can_default">True</property><property name="has_default">True</property><property name="receives_default">False</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkButton" id="configure_button"><property name="visible">True</property><property name="can_focus">True</property><property name="can_default">True</property><property name="receives_default">False</property><child><object class="GtkAlignment" id="alignment2"><property name="visible">True</property><property name="xscale">0</property><property name="yscale">0</property><child><object class="GtkHBox" id="hbox5"><property name="visible">True</property><property name="spacing">2</property><child><object class="GtkImage" id="image2"><property name="visible">True</property><property name="stock">gtk-preferences</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">0</property></packing></child><child><object class="GtkLabel" id="label42"><property name="visible">True</property><property name="label" translatable="yes">Con_figure</property><property name="use_underline">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">1</property></packing></child></object></child></object></child></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">1</property></packing></child><child><object class="GtkButton" id="close_button"><property name="label">gtk-close</property><property name="visible">True</property><property name="can_focus">True</property><property name="can_default">True</property><property name="has_default">True</property><property name="receives_default">False</property><property name="use_stock">True</property></object><packing><property name="expand">False</property><property name="fill">False</property><property name="position">2</property></packing></child></object><packing><property name="expand">False</property><property name="pack_type">end</property><property name="position">0</property></packing></child></object></child><action-widgets><action-widget response="-11">helpbutton1</action-widget><action-widget response="0">configure_button</action-widget><action-widget response="-7">close_button</action-widget></action-widgets></object></interface>
index be761a6..81ce11c 100644 (file)
@@ -6,6 +6,6 @@ pluginsdir=${pkglibdir}/plugins
 
 Name: lxpanel
 Description: A lightweight X11 desktop panel
-Requires: gtk+-2.0 libfm >= 1.2.0
+Requires: @gtk_module@ libfm >= 1.2.0
 Version: @VERSION@
 Libs: -L${pkglibdir} -llxpanel
diff --git a/m4/intltool.m4 b/m4/intltool.m4
deleted file mode 100644 (file)
index 33353ed..0000000
+++ /dev/null
@@ -1,237 +0,0 @@
-## intltool.m4 - Configure intltool for the target system. -*-Shell-script-*-
-## Copyright (C) 2001 Eazel, Inc.
-## Author: Maciej Stachowiak <mjs@noisehavoc.org>
-##         Kenneth Christiansen <kenneth@gnu.org>
-##
-## This program is free software; you can redistribute it and/or modify
-## it under the terms of the GNU General Public License as published by
-## the Free Software Foundation; either version 2 of the License, or
-## (at your option) any later version.
-##
-## This program is distributed in the hope that it will be useful, but
-## WITHOUT ANY WARRANTY; without even the implied warranty of
-## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-## General Public License for more details.
-##
-## You should have received a copy of the GNU General Public License
-## along with this program; if not, write to the Free Software
-## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-##
-## As a special exception to the GNU General Public License, if you
-## distribute this file as part of a program that contains a
-## configuration script generated by Autoconf, you may include it under
-## the same distribution terms that you use for the rest of that program.
-
-dnl IT_PROG_INTLTOOL([MINIMUM-VERSION], [no-xml])
-# serial 42 IT_PROG_INTLTOOL
-AC_DEFUN([IT_PROG_INTLTOOL], [
-AC_PREREQ([2.50])dnl
-AC_REQUIRE([AM_NLS])dnl
-
-case "$am__api_version" in
-    1.[01234])
-       AC_MSG_ERROR([Automake 1.5 or newer is required to use intltool])
-    ;;
-    *)
-    ;;
-esac
-
-INTLTOOL_REQUIRED_VERSION_AS_INT=`echo $1 | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
-INTLTOOL_APPLIED_VERSION=`intltool-update --version | head -1 | cut -d" " -f3`
-INTLTOOL_APPLIED_VERSION_AS_INT=`echo $INTLTOOL_APPLIED_VERSION | awk -F. '{ print $ 1 * 1000 + $ 2 * 100 + $ 3; }'`
-if test -n "$1"; then
-    AC_MSG_CHECKING([for intltool >= $1])
-    AC_MSG_RESULT([$INTLTOOL_APPLIED_VERSION found])
-    test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge "$INTLTOOL_REQUIRED_VERSION_AS_INT" ||
-       AC_MSG_ERROR([Your intltool is too old.  You need intltool $1 or later.])
-fi
-
-AC_PATH_PROG(INTLTOOL_UPDATE, [intltool-update])
-AC_PATH_PROG(INTLTOOL_MERGE, [intltool-merge])
-AC_PATH_PROG(INTLTOOL_EXTRACT, [intltool-extract])
-if test -z "$INTLTOOL_UPDATE" -o -z "$INTLTOOL_MERGE" -o -z "$INTLTOOL_EXTRACT"; then
-    AC_MSG_ERROR([The intltool scripts were not found. Please install intltool.])
-fi
-
-if test -z "$AM_DEFAULT_VERBOSITY"; then
-  AM_DEFAULT_VERBOSITY=1
-fi
-AC_SUBST([AM_DEFAULT_VERBOSITY])
-
-INTLTOOL_V_MERGE='$(INTLTOOL__v_MERGE_$(V))'
-INTLTOOL__v_MERGE_='$(INTLTOOL__v_MERGE_$(AM_DEFAULT_VERBOSITY))'
-INTLTOOL__v_MERGE_0='@echo "  ITMRG " [$]@;'
-AC_SUBST(INTLTOOL_V_MERGE)
-AC_SUBST(INTLTOOL__v_MERGE_)
-AC_SUBST(INTLTOOL__v_MERGE_0)
-
-INTLTOOL_V_MERGE_OPTIONS='$(intltool__v_merge_options_$(V))'
-intltool__v_merge_options_='$(intltool__v_merge_options_$(AM_DEFAULT_VERBOSITY))'
-intltool__v_merge_options_0='-q'
-AC_SUBST(INTLTOOL_V_MERGE_OPTIONS)
-AC_SUBST(intltool__v_merge_options_)
-AC_SUBST(intltool__v_merge_options_0)
-
-  INTLTOOL_DESKTOP_RULE='%.desktop:   %.desktop.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-INTLTOOL_DIRECTORY_RULE='%.directory: %.directory.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-     INTLTOOL_KEYS_RULE='%.keys:      %.keys.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -k -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-     INTLTOOL_PROP_RULE='%.prop:      %.prop.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-      INTLTOOL_OAF_RULE='%.oaf:       %.oaf.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -p $(top_srcdir)/po $< [$]@'
-     INTLTOOL_PONG_RULE='%.pong:      %.pong.in      $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-   INTLTOOL_SERVER_RULE='%.server:    %.server.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -o -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-    INTLTOOL_SHEET_RULE='%.sheet:     %.sheet.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-INTLTOOL_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-       INTLTOOL_UI_RULE='%.ui:        %.ui.in        $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-      INTLTOOL_XML_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-if test "$INTLTOOL_APPLIED_VERSION_AS_INT" -ge 5000; then
-      INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u --no-translations $< [$]@'
-else
-      INTLTOOL_XML_NOMERGE_RULE='%.xml:       %.xml.in       $(INTLTOOL_MERGE) ; $(INTLTOOL_V_MERGE)_it_tmp_dir=tmp.intltool.[$][$]RANDOM && mkdir [$][$]_it_tmp_dir && LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u [$][$]_it_tmp_dir $< [$]@ && rmdir [$][$]_it_tmp_dir'
-fi
-      INTLTOOL_XAM_RULE='%.xam:       %.xml.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-      INTLTOOL_KBD_RULE='%.kbd:       %.kbd.in       $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -m -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-    INTLTOOL_CAVES_RULE='%.caves:     %.caves.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-  INTLTOOL_SCHEMAS_RULE='%.schemas:   %.schemas.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -s -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-    INTLTOOL_THEME_RULE='%.theme:     %.theme.in     $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@' 
-    INTLTOOL_SERVICE_RULE='%.service: %.service.in   $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -d -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
-   INTLTOOL_POLICY_RULE='%.policy:    %.policy.in    $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po) ; $(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< [$]@'
-
-_IT_SUBST(INTLTOOL_DESKTOP_RULE)
-_IT_SUBST(INTLTOOL_DIRECTORY_RULE)
-_IT_SUBST(INTLTOOL_KEYS_RULE)
-_IT_SUBST(INTLTOOL_PROP_RULE)
-_IT_SUBST(INTLTOOL_OAF_RULE)
-_IT_SUBST(INTLTOOL_PONG_RULE)
-_IT_SUBST(INTLTOOL_SERVER_RULE)
-_IT_SUBST(INTLTOOL_SHEET_RULE)
-_IT_SUBST(INTLTOOL_SOUNDLIST_RULE)
-_IT_SUBST(INTLTOOL_UI_RULE)
-_IT_SUBST(INTLTOOL_XAM_RULE)
-_IT_SUBST(INTLTOOL_KBD_RULE)
-_IT_SUBST(INTLTOOL_XML_RULE)
-_IT_SUBST(INTLTOOL_XML_NOMERGE_RULE)
-_IT_SUBST(INTLTOOL_CAVES_RULE)
-_IT_SUBST(INTLTOOL_SCHEMAS_RULE)
-_IT_SUBST(INTLTOOL_THEME_RULE)
-_IT_SUBST(INTLTOOL_SERVICE_RULE)
-_IT_SUBST(INTLTOOL_POLICY_RULE)
-
-# Check the gettext tools to make sure they are GNU
-AC_PATH_PROG(XGETTEXT, xgettext)
-AC_PATH_PROG(MSGMERGE, msgmerge)
-AC_PATH_PROG(MSGFMT, msgfmt)
-AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
-if test -z "$XGETTEXT" -o -z "$MSGMERGE" -o -z "$MSGFMT"; then
-    AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
-fi
-xgversion="`$XGETTEXT --version|grep '(GNU ' 2> /dev/null`"
-mmversion="`$MSGMERGE --version|grep '(GNU ' 2> /dev/null`"
-mfversion="`$MSGFMT --version|grep '(GNU ' 2> /dev/null`"
-if test -z "$xgversion" -o -z "$mmversion" -o -z "$mfversion"; then
-    AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
-fi
-
-AC_PATH_PROG(INTLTOOL_PERL, perl)
-if test -z "$INTLTOOL_PERL"; then
-   AC_MSG_ERROR([perl not found])
-fi
-AC_MSG_CHECKING([for perl >= 5.8.1])
-$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
-if test $? -ne 0; then
-   AC_MSG_ERROR([perl 5.8.1 is required for intltool])
-else
-   IT_PERL_VERSION=`$INTLTOOL_PERL -e "printf '%vd', $^V"`
-   AC_MSG_RESULT([$IT_PERL_VERSION])
-fi
-if test "x$2" != "xno-xml"; then
-   AC_MSG_CHECKING([for XML::Parser])
-   if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
-       AC_MSG_RESULT([ok])
-   else
-       AC_MSG_ERROR([XML::Parser perl module is required for intltool])
-   fi
-fi
-
-# Substitute ALL_LINGUAS so we can use it in po/Makefile
-AC_SUBST(ALL_LINGUAS)
-
-# Set DATADIRNAME correctly if it is not set yet
-# (copied from glib-gettext.m4)
-if test -z "$DATADIRNAME"; then
-  AC_LINK_IFELSE(
-    [AC_LANG_PROGRAM([[]],
-                     [[extern int _nl_msg_cat_cntr;
-                       return _nl_msg_cat_cntr]])],
-    [DATADIRNAME=share],
-    [case $host in
-    *-*-solaris*)
-    dnl On Solaris, if bind_textdomain_codeset is in libc,
-    dnl GNU format message catalog is always supported,
-    dnl since both are added to the libc all together.
-    dnl Hence, we'd like to go with DATADIRNAME=share
-    dnl in this case.
-    AC_CHECK_FUNC(bind_textdomain_codeset,
-      [DATADIRNAME=share], [DATADIRNAME=lib])
-    ;;
-    *)
-    [DATADIRNAME=lib]
-    ;;
-    esac])
-fi
-AC_SUBST(DATADIRNAME)
-
-IT_PO_SUBDIR([po])
-
-])
-
-
-# IT_PO_SUBDIR(DIRNAME)
-# ---------------------
-# All po subdirs have to be declared with this macro; the subdir "po" is
-# declared by IT_PROG_INTLTOOL.
-#
-AC_DEFUN([IT_PO_SUBDIR],
-[AC_PREREQ([2.53])dnl We use ac_top_srcdir inside AC_CONFIG_COMMANDS.
-dnl
-dnl The following CONFIG_COMMANDS should be executed at the very end
-dnl of config.status.
-AC_CONFIG_COMMANDS_PRE([
-  AC_CONFIG_COMMANDS([$1/stamp-it], [
-    if [ ! grep "^# INTLTOOL_MAKEFILE$" "$1/Makefile.in" > /dev/null ]; then
-       AC_MSG_ERROR([$1/Makefile.in.in was not created by intltoolize.])
-    fi
-    rm -f "$1/stamp-it" "$1/stamp-it.tmp" "$1/POTFILES" "$1/Makefile.tmp"
-    >"$1/stamp-it.tmp"
-    [sed '/^#/d
-        s/^[[].*] *//
-        /^[    ]*$/d
-       '"s|^|  $ac_top_srcdir/|" \
-      "$srcdir/$1/POTFILES.in" | sed '$!s/$/ \\/' >"$1/POTFILES"
-    ]
-    [sed '/^POTFILES =/,/[^\\]$/ {
-               /^POTFILES =/!d
-               r $1/POTFILES
-         }
-        ' "$1/Makefile.in" >"$1/Makefile"]
-    rm -f "$1/Makefile.tmp"
-    mv "$1/stamp-it.tmp" "$1/stamp-it"
-  ])
-])dnl
-])
-
-# _IT_SUBST(VARIABLE)
-# -------------------
-# Abstract macro to do either _AM_SUBST_NOTMAKE or AC_SUBST
-#
-AC_DEFUN([_IT_SUBST],
-[
-AC_SUBST([$1])
-m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([$1])])
-]
-)
-
-# deprecated macros
-AU_ALIAS([AC_PROG_INTLTOOL], [IT_PROG_INTLTOOL])
-# A hint is needed for aclocal from Automake <= 1.9.4:
-# AC_DEFUN([AC_PROG_INTLTOOL], ...)
-
index 6060310..01007e5 100644 (file)
@@ -80,10 +80,10 @@ host_triplet = @host@
 subdir = man
 DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/m4/intltool.m4 \
-       $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
-       $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
-       $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+       $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+       $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+       $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -144,7 +144,6 @@ am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ALL_LINGUAS = @ALL_LINGUAS@
-ALL_PLUGINS_LIST = @ALL_PLUGINS_LIST@
 AMTAR = @AMTAR@
 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APPLET_CFLAGS = @APPLET_CFLAGS@
@@ -278,6 +277,7 @@ datarootdir = @datarootdir@
 docdir = @docdir@
 dvidir = @dvidir@
 exec_prefix = @exec_prefix@
+gtk_module = @gtk_module@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
index 3046d66..b5110be 100644 (file)
@@ -7,7 +7,7 @@
 .\"    Source: http://LXDE.org
 .\"  Language: English
 .\"
-.TH "LXPANEL" "1" "March 2, 2008" "http://LXDE\&.org" "http://LXDE.org"
+.TH "LXPANEL" "1" "February, 2016" "http://LXDE\&.org" "http://LXDE.org"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -32,6 +32,7 @@ lxpanel \- a lightweight GTK2\-based panel for the LXDE desktop\&.
 .SH "SYNOPSIS"
 .HP \w'\fBlxpanel\fR\ 'u
 \fBlxpanel\fR
+[ options ]
 .SH "DESCRIPTION"
 .PP
 This manual page documents briefly the
@@ -161,42 +162,39 @@ Print help on the options\&.
 Print the program version\&.
 .RE
 .PP
-\fB\-\-log \fR\fB\fIlevel\fR\fR
-.RS 4
-Set the logging level in the range 0 (silent) through 5 (verbose)\&.
-.RE
-.PP
 \fB\-p \fR\fB\fINAME\fR\fR, \fB\-\-profile \fR\fB\fINAME\fR\fR
 .RS 4
 Set the profile to be loaded\&.
 .RE
 .SH "FILES"
 .PP
-~/\&.config/lxpanel/\fIPROFILE\fR
+~/\&.config/lxpanel/\fIPROFILE\fR/
 .RS 4
-config file, can be edited by preference dialog\&.
+config files directory, can be edited by preference dialog\&.
 .RE
-.SH "SEE ALSO"
 .PP
-lxsession (1), lxpanelctl (1)\&.
+~/\&.config/lxpanel/\fIPROFILE\fR/gtkrc
+.RS 4
+optional GTK+ 2.0 RC file to alterate appearance, can be used to create custom panel style\&.
+.RE
+.SH "SEE ALSO"
+.BR lxpanelctl (1)
 .SH "AUTHOR"
 .PP
-This manual page was written by paulliu
-grandpaul@gmail\&.com
-for the
-Debian
-system (but may be used by others)\&. Permission is granted to copy, distribute and/or modify this document under the terms of the
-GNU
-General Public License, Version 2 any later version published by the Free Software Foundation\&.
+The \fBlxpanel\fR is written by great LXDE developers team under lead of
+Hong Jen Yee (PCMan) since 2006.
 .PP
-On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common\-licenses/GPL\&.
-.SH "AUTHOR"
+This manual page was written by paulliu (\fBYing\-Chun Liu\fR)
+<grandpaul@gmail\&.com> for the Debian system (but may be used by others)\&.
+Permission is granted to copy, distribute and/or modify this document under the terms of the
+GNU General Public License, Version 2 any later version published by the Free Software Foundation\&.
 .PP
-\fBYing\-Chun Liu\fR
-.RS 4
-Author.
-.RE
+On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common\-licenses/GPL-2\&.
+.PP
+Updated by Andriy Grytsenko (LStranger)\&.
 .SH "COPYRIGHT"
 .br
 Copyright \(co 2008 paulliu
 .br
+Copyright \(co 2016 LStranger
+.br
index 0780bee..d3a5dee 100644 (file)
@@ -7,7 +7,7 @@
 .\"    Source: http://LXDE.org
 .\"  Language: English
 .\"
-.TH "LXPANEL" "1" "March 2, 2008" "http://LXDE\&.org" "http://LXDE.org"
+.TH "LXPANEL" "1" "March, 2016" "http://LXDE\&.org" "http://LXDE.org"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -66,6 +66,13 @@ Restart lxpanel\&.
 .RS 4
 Exit lxpanel\&.
 .RE
+.PP
+\fBcommand \fR[\fB\-\-panel=\fR[\fIN\fR:]\fIedge\fR] \fIplugin\fR \fIcommand\fR
+.RS 4
+Send a \fIcommand\fR to a \fIplugin\fR\&. Optionally monitor number \fIN\fR
+(in range 1 to 8) and \fIedge\fR (left, right, top or bottom) can be set,
+otherwise \fIcommand\fR will be send to first \fIplugin\fR found in any panel\&.
+.RE
 .SH "SEE ALSO"
 .PP
 lxpanel (1)\&.
@@ -79,7 +86,9 @@ system (but may be used by others)\&. Permission is granted to copy, distribute
 GNU
 General Public License, Version 2 any later version published by the Free Software Foundation\&.
 .PP
-On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common\-licenses/GPL\&.
+On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common\-licenses/GPL-2\&.
+.PP
+Updated by Andriy Grytsenko (LStranger)\&.
 .SH "AUTHOR"
 .PP
 \fBYing\-Chun Liu\fR
@@ -90,3 +99,5 @@ Author.
 .br
 Copyright \(co 2008 paulliu
 .br
+Copyright \(co 2016 LStranger
+.br
index 04e3187..497dbea 100644 (file)
@@ -35,9 +35,10 @@ PLUGINS_SOURCES = \
        dclock.c \
        dirmenu.c \
        launchtaskbar.c \
+       task-button.c \
+       launch-button.c \
        pager.c \
        separator.c \
-       space.c \
        tray.c \
        wincmd.c \
        $(MENU_SOURCES)
@@ -68,7 +69,6 @@ EXTRA_LTLIBRARIES = \
        netstatus.la \
        thermal.la \
        volume.la \
-       volumealsa.la \
        weather.la \
        xkb.la
 
@@ -131,15 +131,11 @@ netstatus_la_CFLAGS = \
 # thermal
 thermal_la_SOURCES = thermal/thermal.c
 
-# volume (OSS)
-volume_la_SOURCES = \
-       volume/volume-impl.c \
-       volume/volume.c
-volume_la_CFLAGS = -I$(srcdir)/volume
-
-# volumealsa
-volumealsa_la_SOURCES = volumealsa/volumealsa.c
-volumealsa_la_LIBADD = -lasound
+# volume
+volume_la_SOURCES = volumealsa/volumealsa.c
+if BUILD_ALSA_PLUGINS
+volume_la_LIBADD = -lasound
+endif
 
 # weather
 weather_la_SOURCES = \
@@ -317,8 +313,6 @@ EXTRA_DIST = \
        netstatus/netstatus-iface.h \
        netstatus/netstatus-sysdeps.h \
        netstatus/netstatus-util.h \
-       volume/volume_xpm.h \
-       volume/volume-impl.h \
        weather/logutil.h \
        weather/httputil.h \
        weather/yahooutil.h \
@@ -328,6 +322,8 @@ EXTRA_DIST = \
        xkb/xkb.h \
        $(flags_DATA) \
        $(xkeyboardconfig_DATA) \
+       task-button.h \
+       launch-button.h \
        icon.xpm
 
 install-exec-hook:
index ce5a687..c2d0b42 100644 (file)
@@ -83,10 +83,10 @@ subdir = plugins
 DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
        $(top_srcdir)/depcomp
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/m4/intltool.m4 \
-       $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
-       $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
-       $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+       $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+       $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+       $(top_srcdir)/configure.ac
 am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
        $(ACLOCAL_M4)
 mkinstalldirs = $(install_sh) -d
@@ -102,16 +102,17 @@ am__v_AR_1 =
 libbuiltin_plugins_a_AR = $(AR) $(ARFLAGS)
 libbuiltin_plugins_a_DEPENDENCIES =
 am__libbuiltin_plugins_a_SOURCES_DIST = dclock.c dirmenu.c \
-       launchtaskbar.c pager.c separator.c space.c tray.c wincmd.c \
-       menu.c
+       launchtaskbar.c task-button.c launch-button.c pager.c \
+       separator.c tray.c wincmd.c menu.c
 @ENABLE_MENU_CACHE_TRUE@am__objects_1 =  \
 @ENABLE_MENU_CACHE_TRUE@       libbuiltin_plugins_a-menu.$(OBJEXT)
 am__objects_2 = libbuiltin_plugins_a-dclock.$(OBJEXT) \
        libbuiltin_plugins_a-dirmenu.$(OBJEXT) \
        libbuiltin_plugins_a-launchtaskbar.$(OBJEXT) \
+       libbuiltin_plugins_a-task-button.$(OBJEXT) \
+       libbuiltin_plugins_a-launch-button.$(OBJEXT) \
        libbuiltin_plugins_a-pager.$(OBJEXT) \
        libbuiltin_plugins_a-separator.$(OBJEXT) \
-       libbuiltin_plugins_a-space.$(OBJEXT) \
        libbuiltin_plugins_a-tray.$(OBJEXT) \
        libbuiltin_plugins_a-wincmd.$(OBJEXT) $(am__objects_1)
 am_libbuiltin_plugins_a_OBJECTS = $(am__objects_2)
@@ -204,16 +205,9 @@ netstatus_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
 thermal_la_LIBADD =
 am_thermal_la_OBJECTS = thermal/thermal.lo
 thermal_la_OBJECTS = $(am_thermal_la_OBJECTS)
-volume_la_LIBADD =
-am_volume_la_OBJECTS = volume/volume_la-volume-impl.lo \
-       volume/volume_la-volume.lo
+volume_la_DEPENDENCIES =
+am_volume_la_OBJECTS = volumealsa/volumealsa.lo
 volume_la_OBJECTS = $(am_volume_la_OBJECTS)
-volume_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
-       $(LIBTOOLFLAGS) --mode=link $(CCLD) $(volume_la_CFLAGS) \
-       $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
-volumealsa_la_DEPENDENCIES =
-am_volumealsa_la_OBJECTS = volumealsa/volumealsa.lo
-volumealsa_la_OBJECTS = $(am_volumealsa_la_OBJECTS)
 weather_la_DEPENDENCIES = $(am__DEPENDENCIES_1)
 am_weather_la_OBJECTS = weather/weather_la-logutil.lo \
        weather/weather_la-httputil.lo weather/weather_la-yahooutil.lo \
@@ -269,16 +263,14 @@ SOURCES = $(libbuiltin_plugins_a_SOURCES) $(batt_la_SOURCES) \
        $(indicator_la_SOURCES) $(kbled_la_SOURCES) \
        $(monitors_la_SOURCES) $(netstat_la_SOURCES) \
        $(netstatus_la_SOURCES) $(thermal_la_SOURCES) \
-       $(volume_la_SOURCES) $(volumealsa_la_SOURCES) \
-       $(weather_la_SOURCES) $(xkb_la_SOURCES)
+       $(volume_la_SOURCES) $(weather_la_SOURCES) $(xkb_la_SOURCES)
 DIST_SOURCES = $(am__libbuiltin_plugins_a_SOURCES_DIST) \
        $(batt_la_SOURCES) $(cpu_la_SOURCES) $(cpufreq_la_SOURCES) \
        $(deskno_la_SOURCES) $(indicator_la_SOURCES) \
        $(kbled_la_SOURCES) $(monitors_la_SOURCES) \
        $(netstat_la_SOURCES) $(netstatus_la_SOURCES) \
        $(thermal_la_SOURCES) $(volume_la_SOURCES) \
-       $(volumealsa_la_SOURCES) $(weather_la_SOURCES) \
-       $(xkb_la_SOURCES)
+       $(weather_la_SOURCES) $(xkb_la_SOURCES)
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -308,7 +300,6 @@ DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 pkglibdir = $(libdir)/lxpanel/plugins
 ACLOCAL = @ACLOCAL@
 ALL_LINGUAS = @ALL_LINGUAS@
-ALL_PLUGINS_LIST = @ALL_PLUGINS_LIST@
 AMTAR = @AMTAR@
 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 APPLET_CFLAGS = @APPLET_CFLAGS@
@@ -442,6 +433,7 @@ datarootdir = @datarootdir@
 docdir = @docdir@
 dvidir = @dvidir@
 exec_prefix = @exec_prefix@
+gtk_module = @gtk_module@
 host = @host@
 host_alias = @host_alias@
 host_cpu = @host_cpu@
@@ -498,9 +490,10 @@ PLUGINS_SOURCES = \
        dclock.c \
        dirmenu.c \
        launchtaskbar.c \
+       task-button.c \
+       launch-button.c \
        pager.c \
        separator.c \
-       space.c \
        tray.c \
        wincmd.c \
        $(MENU_SOURCES)
@@ -525,7 +518,6 @@ EXTRA_LTLIBRARIES = \
        netstatus.la \
        thermal.la \
        volume.la \
-       volumealsa.la \
        weather.la \
        xkb.la
 
@@ -592,16 +584,9 @@ netstatus_la_CFLAGS = \
 # thermal
 thermal_la_SOURCES = thermal/thermal.c
 
-# volume (OSS)
-volume_la_SOURCES = \
-       volume/volume-impl.c \
-       volume/volume.c
-
-volume_la_CFLAGS = -I$(srcdir)/volume
-
-# volumealsa
-volumealsa_la_SOURCES = volumealsa/volumealsa.c
-volumealsa_la_LIBADD = -lasound
+# volume
+volume_la_SOURCES = volumealsa/volumealsa.c
+@BUILD_ALSA_PLUGINS_TRUE@volume_la_LIBADD = -lasound
 
 # weather
 weather_la_SOURCES = \
@@ -782,8 +767,6 @@ EXTRA_DIST = \
        netstatus/netstatus-iface.h \
        netstatus/netstatus-sysdeps.h \
        netstatus/netstatus-util.h \
-       volume/volume_xpm.h \
-       volume/volume-impl.h \
        weather/logutil.h \
        weather/httputil.h \
        weather/yahooutil.h \
@@ -793,6 +776,8 @@ EXTRA_DIST = \
        xkb/xkb.h \
        $(flags_DATA) \
        $(xkeyboardconfig_DATA) \
+       task-button.h \
+       launch-button.h \
        icon.xpm
 
 @BUILD_PLUGIN_LOADER_TRUE@DYNAMIC_PLUGINS_INSTALLED = $(DYNAMIC_PLUGINS:.la=.so)
@@ -1006,19 +991,6 @@ thermal/thermal.lo: thermal/$(am__dirstamp) \
 
 thermal.la: $(thermal_la_OBJECTS) $(thermal_la_DEPENDENCIES) $(EXTRA_thermal_la_DEPENDENCIES) 
        $(AM_V_CCLD)$(LINK)  $(thermal_la_OBJECTS) $(thermal_la_LIBADD) $(LIBS)
-volume/$(am__dirstamp):
-       @$(MKDIR_P) volume
-       @: > volume/$(am__dirstamp)
-volume/$(DEPDIR)/$(am__dirstamp):
-       @$(MKDIR_P) volume/$(DEPDIR)
-       @: > volume/$(DEPDIR)/$(am__dirstamp)
-volume/volume_la-volume-impl.lo: volume/$(am__dirstamp) \
-       volume/$(DEPDIR)/$(am__dirstamp)
-volume/volume_la-volume.lo: volume/$(am__dirstamp) \
-       volume/$(DEPDIR)/$(am__dirstamp)
-
-volume.la: $(volume_la_OBJECTS) $(volume_la_DEPENDENCIES) $(EXTRA_volume_la_DEPENDENCIES) 
-       $(AM_V_CCLD)$(volume_la_LINK)  $(volume_la_OBJECTS) $(volume_la_LIBADD) $(LIBS)
 volumealsa/$(am__dirstamp):
        @$(MKDIR_P) volumealsa
        @: > volumealsa/$(am__dirstamp)
@@ -1028,8 +1000,8 @@ volumealsa/$(DEPDIR)/$(am__dirstamp):
 volumealsa/volumealsa.lo: volumealsa/$(am__dirstamp) \
        volumealsa/$(DEPDIR)/$(am__dirstamp)
 
-volumealsa.la: $(volumealsa_la_OBJECTS) $(volumealsa_la_DEPENDENCIES) $(EXTRA_volumealsa_la_DEPENDENCIES) 
-       $(AM_V_CCLD)$(LINK)  $(volumealsa_la_OBJECTS) $(volumealsa_la_LIBADD) $(LIBS)
+volume.la: $(volume_la_OBJECTS) $(volume_la_DEPENDENCIES) $(EXTRA_volume_la_DEPENDENCIES) 
+       $(AM_V_CCLD)$(LINK)  $(volume_la_OBJECTS) $(volume_la_LIBADD) $(LIBS)
 weather/$(am__dirstamp):
        @$(MKDIR_P) weather
        @: > weather/$(am__dirstamp)
@@ -1088,8 +1060,6 @@ mostlyclean-compile:
        -rm -f netstatus/*.lo
        -rm -f thermal/*.$(OBJEXT)
        -rm -f thermal/*.lo
-       -rm -f volume/*.$(OBJEXT)
-       -rm -f volume/*.lo
        -rm -f volumealsa/*.$(OBJEXT)
        -rm -f volumealsa/*.lo
        -rm -f weather/*.$(OBJEXT)
@@ -1102,11 +1072,12 @@ distclean-compile:
 
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-dclock.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-dirmenu.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-launch-button.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-launchtaskbar.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-menu.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-pager.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-separator.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-space.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-task-button.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-tray.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbuiltin_plugins_a-wincmd.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@batt/$(DEPDIR)/batt_la-batt.Plo@am__quote@
@@ -1131,8 +1102,6 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote@netstatus/$(DEPDIR)/netstatus_la-netstatus-util.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@netstatus/$(DEPDIR)/netstatus_la-netstatus.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@thermal/$(DEPDIR)/thermal.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@volume/$(DEPDIR)/volume_la-volume-impl.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@volume/$(DEPDIR)/volume_la-volume.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@volumealsa/$(DEPDIR)/volumealsa.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@weather/$(DEPDIR)/weather_la-forecast.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@weather/$(DEPDIR)/weather_la-httputil.Plo@am__quote@
@@ -1210,6 +1179,34 @@ libbuiltin_plugins_a-launchtaskbar.obj: launchtaskbar.c
 @AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -c -o libbuiltin_plugins_a-launchtaskbar.obj `if test -f 'launchtaskbar.c'; then $(CYGPATH_W) 'launchtaskbar.c'; else $(CYGPATH_W) '$(srcdir)/launchtaskbar.c'; fi`
 
+libbuiltin_plugins_a-task-button.o: task-button.c
+@am__fastdepCC_TRUE@   $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -MT libbuiltin_plugins_a-task-button.o -MD -MP -MF $(DEPDIR)/libbuiltin_plugins_a-task-button.Tpo -c -o libbuiltin_plugins_a-task-button.o `test -f 'task-button.c' || echo '$(srcdir)/'`task-button.c
+@am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) $(DEPDIR)/libbuiltin_plugins_a-task-button.Tpo $(DEPDIR)/libbuiltin_plugins_a-task-button.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(AM_V_CC)source='task-button.c' object='libbuiltin_plugins_a-task-button.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -c -o libbuiltin_plugins_a-task-button.o `test -f 'task-button.c' || echo '$(srcdir)/'`task-button.c
+
+libbuiltin_plugins_a-task-button.obj: task-button.c
+@am__fastdepCC_TRUE@   $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -MT libbuiltin_plugins_a-task-button.obj -MD -MP -MF $(DEPDIR)/libbuiltin_plugins_a-task-button.Tpo -c -o libbuiltin_plugins_a-task-button.obj `if test -f 'task-button.c'; then $(CYGPATH_W) 'task-button.c'; else $(CYGPATH_W) '$(srcdir)/task-button.c'; fi`
+@am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) $(DEPDIR)/libbuiltin_plugins_a-task-button.Tpo $(DEPDIR)/libbuiltin_plugins_a-task-button.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(AM_V_CC)source='task-button.c' object='libbuiltin_plugins_a-task-button.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -c -o libbuiltin_plugins_a-task-button.obj `if test -f 'task-button.c'; then $(CYGPATH_W) 'task-button.c'; else $(CYGPATH_W) '$(srcdir)/task-button.c'; fi`
+
+libbuiltin_plugins_a-launch-button.o: launch-button.c
+@am__fastdepCC_TRUE@   $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -MT libbuiltin_plugins_a-launch-button.o -MD -MP -MF $(DEPDIR)/libbuiltin_plugins_a-launch-button.Tpo -c -o libbuiltin_plugins_a-launch-button.o `test -f 'launch-button.c' || echo '$(srcdir)/'`launch-button.c
+@am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) $(DEPDIR)/libbuiltin_plugins_a-launch-button.Tpo $(DEPDIR)/libbuiltin_plugins_a-launch-button.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(AM_V_CC)source='launch-button.c' object='libbuiltin_plugins_a-launch-button.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -c -o libbuiltin_plugins_a-launch-button.o `test -f 'launch-button.c' || echo '$(srcdir)/'`launch-button.c
+
+libbuiltin_plugins_a-launch-button.obj: launch-button.c
+@am__fastdepCC_TRUE@   $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -MT libbuiltin_plugins_a-launch-button.obj -MD -MP -MF $(DEPDIR)/libbuiltin_plugins_a-launch-button.Tpo -c -o libbuiltin_plugins_a-launch-button.obj `if test -f 'launch-button.c'; then $(CYGPATH_W) 'launch-button.c'; else $(CYGPATH_W) '$(srcdir)/launch-button.c'; fi`
+@am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) $(DEPDIR)/libbuiltin_plugins_a-launch-button.Tpo $(DEPDIR)/libbuiltin_plugins_a-launch-button.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(AM_V_CC)source='launch-button.c' object='libbuiltin_plugins_a-launch-button.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -c -o libbuiltin_plugins_a-launch-button.obj `if test -f 'launch-button.c'; then $(CYGPATH_W) 'launch-button.c'; else $(CYGPATH_W) '$(srcdir)/launch-button.c'; fi`
+
 libbuiltin_plugins_a-pager.o: pager.c
 @am__fastdepCC_TRUE@   $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -MT libbuiltin_plugins_a-pager.o -MD -MP -MF $(DEPDIR)/libbuiltin_plugins_a-pager.Tpo -c -o libbuiltin_plugins_a-pager.o `test -f 'pager.c' || echo '$(srcdir)/'`pager.c
 @am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) $(DEPDIR)/libbuiltin_plugins_a-pager.Tpo $(DEPDIR)/libbuiltin_plugins_a-pager.Po
@@ -1238,20 +1235,6 @@ libbuiltin_plugins_a-separator.obj: separator.c
 @AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -c -o libbuiltin_plugins_a-separator.obj `if test -f 'separator.c'; then $(CYGPATH_W) 'separator.c'; else $(CYGPATH_W) '$(srcdir)/separator.c'; fi`
 
-libbuiltin_plugins_a-space.o: space.c
-@am__fastdepCC_TRUE@   $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -MT libbuiltin_plugins_a-space.o -MD -MP -MF $(DEPDIR)/libbuiltin_plugins_a-space.Tpo -c -o libbuiltin_plugins_a-space.o `test -f 'space.c' || echo '$(srcdir)/'`space.c
-@am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) $(DEPDIR)/libbuiltin_plugins_a-space.Tpo $(DEPDIR)/libbuiltin_plugins_a-space.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(AM_V_CC)source='space.c' object='libbuiltin_plugins_a-space.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -c -o libbuiltin_plugins_a-space.o `test -f 'space.c' || echo '$(srcdir)/'`space.c
-
-libbuiltin_plugins_a-space.obj: space.c
-@am__fastdepCC_TRUE@   $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -MT libbuiltin_plugins_a-space.obj -MD -MP -MF $(DEPDIR)/libbuiltin_plugins_a-space.Tpo -c -o libbuiltin_plugins_a-space.obj `if test -f 'space.c'; then $(CYGPATH_W) 'space.c'; else $(CYGPATH_W) '$(srcdir)/space.c'; fi`
-@am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) $(DEPDIR)/libbuiltin_plugins_a-space.Tpo $(DEPDIR)/libbuiltin_plugins_a-space.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(AM_V_CC)source='space.c' object='libbuiltin_plugins_a-space.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -c -o libbuiltin_plugins_a-space.obj `if test -f 'space.c'; then $(CYGPATH_W) 'space.c'; else $(CYGPATH_W) '$(srcdir)/space.c'; fi`
-
 libbuiltin_plugins_a-tray.o: tray.c
 @am__fastdepCC_TRUE@   $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libbuiltin_plugins_a_CFLAGS) $(CFLAGS) -MT libbuiltin_plugins_a-tray.o -MD -MP -MF $(DEPDIR)/libbuiltin_plugins_a-tray.Tpo -c -o libbuiltin_plugins_a-tray.o `test -f 'tray.c' || echo '$(srcdir)/'`tray.c
 @am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) $(DEPDIR)/libbuiltin_plugins_a-tray.Tpo $(DEPDIR)/libbuiltin_plugins_a-tray.Po
@@ -1406,20 +1389,6 @@ netstatus/netstatus_la-netstatus-util.lo: netstatus/netstatus-util.c
 @AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(netstatus_la_CFLAGS) $(CFLAGS) -c -o netstatus/netstatus_la-netstatus-util.lo `test -f 'netstatus/netstatus-util.c' || echo '$(srcdir)/'`netstatus/netstatus-util.c
 
-volume/volume_la-volume-impl.lo: volume/volume-impl.c
-@am__fastdepCC_TRUE@   $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(volume_la_CFLAGS) $(CFLAGS) -MT volume/volume_la-volume-impl.lo -MD -MP -MF volume/$(DEPDIR)/volume_la-volume-impl.Tpo -c -o volume/volume_la-volume-impl.lo `test -f 'volume/volume-impl.c' || echo '$(srcdir)/'`volume/volume-impl.c
-@am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) volume/$(DEPDIR)/volume_la-volume-impl.Tpo volume/$(DEPDIR)/volume_la-volume-impl.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(AM_V_CC)source='volume/volume-impl.c' object='volume/volume_la-volume-impl.lo' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(volume_la_CFLAGS) $(CFLAGS) -c -o volume/volume_la-volume-impl.lo `test -f 'volume/volume-impl.c' || echo '$(srcdir)/'`volume/volume-impl.c
-
-volume/volume_la-volume.lo: volume/volume.c
-@am__fastdepCC_TRUE@   $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(volume_la_CFLAGS) $(CFLAGS) -MT volume/volume_la-volume.lo -MD -MP -MF volume/$(DEPDIR)/volume_la-volume.Tpo -c -o volume/volume_la-volume.lo `test -f 'volume/volume.c' || echo '$(srcdir)/'`volume/volume.c
-@am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) volume/$(DEPDIR)/volume_la-volume.Tpo volume/$(DEPDIR)/volume_la-volume.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(AM_V_CC)source='volume/volume.c' object='volume/volume_la-volume.lo' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@      DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@  $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(volume_la_CFLAGS) $(CFLAGS) -c -o volume/volume_la-volume.lo `test -f 'volume/volume.c' || echo '$(srcdir)/'`volume/volume.c
-
 weather/weather_la-logutil.lo: weather/logutil.c
 @am__fastdepCC_TRUE@   $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(weather_la_CFLAGS) $(CFLAGS) -MT weather/weather_la-logutil.lo -MD -MP -MF weather/$(DEPDIR)/weather_la-logutil.Tpo -c -o weather/weather_la-logutil.lo `test -f 'weather/logutil.c' || echo '$(srcdir)/'`weather/logutil.c
 @am__fastdepCC_TRUE@   $(AM_V_at)$(am__mv) weather/$(DEPDIR)/weather_la-logutil.Tpo weather/$(DEPDIR)/weather_la-logutil.Plo
@@ -1498,7 +1467,6 @@ clean-libtool:
        -rm -rf netstat/.libs netstat/_libs
        -rm -rf netstatus/.libs netstatus/_libs
        -rm -rf thermal/.libs thermal/_libs
-       -rm -rf volume/.libs volume/_libs
        -rm -rf volumealsa/.libs volumealsa/_libs
        -rm -rf weather/.libs weather/_libs
        -rm -rf xkb/.libs xkb/_libs
@@ -1682,8 +1650,6 @@ distclean-generic:
        -rm -f netstatus/$(am__dirstamp)
        -rm -f thermal/$(DEPDIR)/$(am__dirstamp)
        -rm -f thermal/$(am__dirstamp)
-       -rm -f volume/$(DEPDIR)/$(am__dirstamp)
-       -rm -f volume/$(am__dirstamp)
        -rm -f volumealsa/$(DEPDIR)/$(am__dirstamp)
        -rm -f volumealsa/$(am__dirstamp)
        -rm -f weather/$(DEPDIR)/$(am__dirstamp)
@@ -1702,7 +1668,7 @@ clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \
        clean-pkglibLTLIBRARIES mostlyclean-am
 
 distclean: distclean-am
-       -rm -rf ./$(DEPDIR) batt/$(DEPDIR) cpu/$(DEPDIR) cpufreq/$(DEPDIR) deskno/$(DEPDIR) indicator/$(DEPDIR) kbled/$(DEPDIR) monitors/$(DEPDIR) netstat/$(DEPDIR) netstatus/$(DEPDIR) thermal/$(DEPDIR) volume/$(DEPDIR) volumealsa/$(DEPDIR) weather/$(DEPDIR) xkb/$(DEPDIR)
+       -rm -rf ./$(DEPDIR) batt/$(DEPDIR) cpu/$(DEPDIR) cpufreq/$(DEPDIR) deskno/$(DEPDIR) indicator/$(DEPDIR) kbled/$(DEPDIR) monitors/$(DEPDIR) netstat/$(DEPDIR) netstatus/$(DEPDIR) thermal/$(DEPDIR) volumealsa/$(DEPDIR) weather/$(DEPDIR) xkb/$(DEPDIR)
        -rm -f Makefile
 distclean-am: clean-am distclean-compile distclean-generic \
        distclean-tags
@@ -1749,7 +1715,7 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-am
-       -rm -rf ./$(DEPDIR) batt/$(DEPDIR) cpu/$(DEPDIR) cpufreq/$(DEPDIR) deskno/$(DEPDIR) indicator/$(DEPDIR) kbled/$(DEPDIR) monitors/$(DEPDIR) netstat/$(DEPDIR) netstatus/$(DEPDIR) thermal/$(DEPDIR) volume/$(DEPDIR) volumealsa/$(DEPDIR) weather/$(DEPDIR) xkb/$(DEPDIR)
+       -rm -rf ./$(DEPDIR) batt/$(DEPDIR) cpu/$(DEPDIR) cpufreq/$(DEPDIR) deskno/$(DEPDIR) indicator/$(DEPDIR) kbled/$(DEPDIR) monitors/$(DEPDIR) netstat/$(DEPDIR) netstatus/$(DEPDIR) thermal/$(DEPDIR) volumealsa/$(DEPDIR) weather/$(DEPDIR) xkb/$(DEPDIR)
        -rm -f Makefile
 maintainer-clean-am: distclean-am maintainer-clean-generic
 
index 4afb2c6..988d9fd 100644 (file)
@@ -5,6 +5,8 @@
  * Copyright (C) 2008 by Hong Jen Yee <pcman.tw@gmail.com>
  * Copyright (C) 2009 by Juergen Hoetzel <juergen@archlinux.org>
  * Copyright (C) 2014 by Andriy Grytsenko <andrej@rep.kiev.ua>
+ *               2015 Balló György <ballogyor@gmail.com>
+ *               2015 Stanislav Kozina, Ersin <xersin@users.sf.net>
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -33,7 +35,6 @@
 /* FIXME:
  *  Here are somethings need to be improvec:
  *  1. Replace pthread stuff with gthread counterparts for portability.
- *  3. Add an option to hide the plugin when AC power is used or there is no battery.
  *  4. Handle failure gracefully under systems other than Linux.
 */
 
@@ -84,6 +85,7 @@ typedef struct {
         wasCharging,
         width,
         hide_if_no_battery;
+    int battery_number;
     sem_t alarmProcessLock;
     battery* b;
     gboolean has_ac_adapter;
@@ -145,14 +147,18 @@ static gchar* make_tooltip(lx_battery* lx_b, gboolean isCharging)
         return NULL;
 
     if (isCharging) {
-        int hours = lx_b->b->seconds / 3600;
-        int left_seconds = lx_b->b->seconds - 3600 * hours;
-        int minutes = left_seconds / 60;
-        tooltip = g_strdup_printf(
-                _("Battery: %d%% charged, %d:%02d until full"),
-                lx_b->b->percentage,
-                hours,
-                minutes );
+        if (lx_b->b->seconds > 0) {
+            int hours = lx_b->b->seconds / 3600;
+            int left_seconds = lx_b->b->seconds - 3600 * hours;
+            int minutes = left_seconds / 60;
+            tooltip = g_strdup_printf(
+                    _("Battery %d: %d%% charged, %d:%02d until full"),
+                    lx_b->battery_number, lx_b->b->percentage,
+                    hours,
+                    minutes );
+        }
+        else
+            goto _charged;
     } else {
         /* if we have enough rate information for battery */
         if (lx_b->b->percentage != 100) {
@@ -160,14 +166,15 @@ static gchar* make_tooltip(lx_battery* lx_b, gboolean isCharging)
             int left_seconds = lx_b->b->seconds - 3600 * hours;
             int minutes = left_seconds / 60;
             tooltip = g_strdup_printf(
-                    _("Battery: %d%% charged, %d:%02d left"),
-                    lx_b->b->percentage,
+                    _("Battery %d: %d%% charged, %d:%02d left"),
+                    lx_b->battery_number, lx_b->b->percentage,
                     hours,
                     minutes );
         } else {
+_charged:
             tooltip = g_strdup_printf(
-                    _("Battery: %d%% charged"),
-                    100 );
+                    _("Battery %d: %d%% charged"),
+                    lx_b->battery_number, lx_b->b->percentage);
         }
     }
 
@@ -331,7 +338,7 @@ static int update_timout(lx_battery *lx_b) {
         battery_free(lx_b->b);
 
         /* maybe in the mean time a battery has been inserted. */
-        lx_b->b = battery_get();
+        lx_b->b = battery_get(lx_b->battery_number);
     }
 
     update_display( lx_b, TRUE );
@@ -393,9 +400,17 @@ static gint configureEvent(GtkWidget *widget, GdkEventConfigure *event,
 }
 
 
+#if GTK_CHECK_VERSION(3, 0, 0)
+static gint draw(GtkWidget *widget, cairo_t *cr, lx_battery *lx_b) {
+#else
 static gint exposeEvent(GtkWidget *widget, GdkEventExpose *event, lx_battery *lx_b) {
+#endif
 
     ENTER;
+
+#if GTK_CHECK_VERSION(3, 0, 0)
+    cairo_set_source_rgb(cr, 0, 0, 0); // FIXME: set black color from the style
+#else
     cairo_t *cr = gdk_cairo_create(gtk_widget_get_window(widget));
     GtkStyle *style = gtk_widget_get_style(lx_b->drawingArea);
 
@@ -403,11 +418,14 @@ static gint exposeEvent(GtkWidget *widget, GdkEventExpose *event, lx_battery *lx
     cairo_clip(cr);
 
     gdk_cairo_set_source_color(cr, &style->black);
+#endif
     cairo_set_source_surface(cr, lx_b->pixmap, 0, 0);
     cairo_paint(cr);
 
     check_cairo_status(cr);
+#if !GTK_CHECK_VERSION(3, 0, 0)
     cairo_destroy(cr);
+#endif
 
     RET(FALSE);
 }
@@ -436,8 +454,10 @@ static GtkWidget * constructor(LXPanel *panel, config_setting_t *settings)
 
     lx_b = g_new0(lx_battery, 1);
 
-    /* get available battery */
-    lx_b->b = battery_get ();
+    /* get requested battery */
+    if (config_setting_lookup_int(settings, "BatteryNumber", &tmp_int))
+        lx_b->battery_number = MAX(0, tmp_int);
+    lx_b->b = battery_get(lx_b->battery_number);
 
     p = gtk_event_box_new();
     lxpanel_plugin_set_data(p, lx_b, destructor);
@@ -445,7 +465,9 @@ static GtkWidget * constructor(LXPanel *panel, config_setting_t *settings)
 
     lx_b->box = GTK_CONTAINER(p);
     lx_b->drawingArea = gtk_drawing_area_new();
-    gtk_widget_add_events( lx_b->drawingArea, GDK_BUTTON_PRESS_MASK );
+    gtk_widget_add_events(lx_b->drawingArea, GDK_BUTTON_PRESS_MASK |
+                                             GDK_BUTTON_RELEASE_MASK |
+                                             GDK_BUTTON_MOTION_MASK);
 
     gtk_container_add(lx_b->box, lx_b->drawingArea);
 
@@ -507,8 +529,13 @@ static GtkWidget * constructor(LXPanel *panel, config_setting_t *settings)
 
     g_signal_connect (G_OBJECT (lx_b->drawingArea),"configure-event",
           G_CALLBACK (configureEvent), (gpointer) lx_b);
+#if GTK_CHECK_VERSION(3, 0, 0)
+    g_signal_connect (G_OBJECT (lx_b->drawingArea), "draw",
+          G_CALLBACK(draw), (gpointer) lx_b);
+#else
     g_signal_connect (G_OBJECT (lx_b->drawingArea), "expose-event",
           G_CALLBACK (exposeEvent), (gpointer) lx_b);
+#endif
 
     /* Apply more default options */
     if (! lx_b->alarmCommand)
@@ -599,6 +626,10 @@ static gboolean applyConfig(gpointer user_data)
 
     lx_battery *b = lxpanel_plugin_get_data(user_data);
 
+    /* Update the battery we monitor */
+    battery_free(b->b);
+    b->b = battery_get(b->battery_number);
+
     /* Update colors */
     if (b->backgroundColor &&
             gdk_color_parse(b->backgroundColor, &b->background))
@@ -654,6 +685,9 @@ static gboolean applyConfig(gpointer user_data)
     config_group_set_int(b->settings, "Size", b->thickness);
     config_group_set_int(b->settings, "ShowExtendedInformation",
                          b->show_extended_information);
+    config_group_set_int(b->settings, "BatteryNumber", b->battery_number);
+
+    update_display(b, TRUE);
 
     RET(FALSE);
 }
@@ -676,6 +710,7 @@ static GtkWidget *config(LXPanel *panel, GtkWidget *p) {
             "", panel_config_int_button_new(_("Size"), (int *)&b->thickness,
                                             1, 50), CONF_TYPE_EXTERNAL,
             _("Show Extended Information"), &b->show_extended_information, CONF_TYPE_BOOL,
+            _("Number of battery to monitor"), &b->battery_number, CONF_TYPE_INT,
             NULL);
 }
 
index 64f5ce0..154bd3d 100644 (file)
@@ -3,6 +3,7 @@
  *
  *      Copyright 2009 Juergen Hötzel <juergen@archlinux.org>
  *                2015 Henry Gebhardt <hsggebhardt@googlemail.com>
+ *                2015 Stanislav Kozina, Ersin <xersin@users.sf.net>
  *
  *     Parts shameless stolen and glibified from acpi package
  *     Copyright (C) 2001  Grahame Bowland <grahame@angrygoats.net>
@@ -40,7 +41,7 @@ battery* battery_new() {
     static int battery_num = 1;
     battery * b = g_new0 ( battery, 1 );
     b->type_battery = TRUE;
-    b->capacity_unit = "mAh";
+    //b->capacity_unit = "mAh";
     b->energy_full = -1;
     b->charge_full = -1;
     b->voltage_now = -1;
@@ -54,7 +55,7 @@ battery* battery_new() {
     b->battery_num = battery_num;
     b->seconds = -1;
     b->percentage = -1;
-    b->poststr = NULL;
+    //b->poststr = NULL;
     battery_num++;
     return b;
 }
@@ -63,20 +64,17 @@ battery* battery_new() {
 static gchar* parse_info_file(battery *b, char *sys_file)
 {
     char *buf = NULL;
-    gchar *value = NULL;
-    GString *filename = g_string_new(ACPI_PATH_SYS_POWER_SUPPY);
+    GString *filename = g_string_new(ACPI_PATH_SYS_POWER_SUPPLY);
 
     g_string_append_printf (filename, "/%s/%s", b->path, sys_file);
 
     if (g_file_get_contents(filename->str, &buf, NULL, NULL) == TRUE) {
-        value = g_strdup( buf );
-        value = g_strstrip( value );
-        g_free( buf );
+        g_strstrip( buf );
     }
 
     g_string_free(filename, TRUE);
 
-    return value;
+    return buf;
 }
 
 /* get_gint_from_infofile():
@@ -86,11 +84,13 @@ static gchar* parse_info_file(battery *b, char *sys_file)
 static gint get_gint_from_infofile(battery *b, gchar *sys_file)
 {
     gchar *file_content = parse_info_file(b, sys_file);
+    gint value = -1;
 
     if (file_content != NULL)
-        return atoi(file_content) / 1000;
+        value = atoi(file_content) / 1000;
+    g_free(file_content);
 
-    return -1;
+    return value;
 }
 
 static gchar* get_gchar_from_infofile(battery *b, gchar *sys_file)
@@ -98,6 +98,7 @@ static gchar* get_gchar_from_infofile(battery *b, gchar *sys_file)
     return parse_info_file(b, sys_file);
 }
 
+#if 0 /* never used */
 void battery_print(battery *b, int show_capacity)
 {
     if ( b->type_battery )
@@ -142,14 +143,14 @@ void battery_print(battery *b, int show_capacity)
         }
     }
 }
-
+#endif
 
 static gboolean battery_inserted(gchar* path)
 {
     if (path == NULL)
         return FALSE;
 
-    GString *dirname = g_string_new(ACPI_PATH_SYS_POWER_SUPPY);
+    GString *dirname = g_string_new(ACPI_PATH_SYS_POWER_SUPPLY);
     GDir *dir;
 
     g_string_append_printf (dirname, "/%s/", path);
@@ -196,19 +197,21 @@ battery* battery_update(battery *b)
 
     gctmp = get_gchar_from_infofile(b, "type");
     b->type_battery = gctmp ? (strcasecmp(gctmp, "battery") == 0) : TRUE;
+    g_free(gctmp);
 
+    g_free(b->state);
     b->state = get_gchar_from_infofile(b, "status");
     if (!b->state)
         b->state = get_gchar_from_infofile(b, "state");
     if (!b->state) {
         if (b->charge_now != -1 || b->energy_now != -1
                 || b->charge_full != -1 || b->energy_full != -1)
-            b->state = "available";
+            b->state = g_strdup("available");
         else
-            b->state = "unavailable";
+            b->state = g_strdup("unavailable");
     }
 
-
+#if 0 /* those conversions might be good for text prints but are pretty wrong for tooltip and calculations */
     /* convert energy values (in mWh) to charge values (in mAh) if needed and possible */
 
     if (b->energy_full != -1 && b->charge_full == -1) {
@@ -247,7 +250,7 @@ battery* battery_update(battery *b)
         if (b->voltage_now != -1 && b->voltage_now != 0)
             b->current_now = b->power_now * 1000 / b->voltage_now;
     }
-
+#endif
 
     if (b->charge_full < MIN_CAPACITY)
         b->percentage = 0;
@@ -260,26 +263,26 @@ battery* battery_update(battery *b)
 
 
     if (b->current_now == -1) {
-        b->poststr = "rate information unavailable";
+        //b->poststr = "rate information unavailable";
         b->seconds = -1;
     } else if (!strcasecmp(b->state, "charging")) {
         if (b->current_now > MIN_PRESENT_RATE) {
             b->seconds = 3600 * (b->charge_full - b->charge_now) / b->current_now;
-            b->poststr = " until charged";
+            //b->poststr = " until charged";
         } else {
-            b->poststr = "charging at zero rate - will never fully charge.";
+            //b->poststr = "charging at zero rate - will never fully charge.";
             b->seconds = -1;
         }
     } else if (!strcasecmp(b->state, "discharging")) {
         if (b->current_now > MIN_PRESENT_RATE) {
             b->seconds = 3600 * b->charge_now / b->current_now;
-            b->poststr = " remaining";
+            //b->poststr = " remaining";
         } else {
-            b->poststr = "discharging at zero rate - will never fully discharge.";
+            //b->poststr = "discharging at zero rate - will never fully discharge.";
             b->seconds = -1;
         }
     } else {
-        b->poststr = NULL;
+        //b->poststr = NULL;
         b->seconds = -1;
     }
 
@@ -287,29 +290,68 @@ battery* battery_update(battery *b)
 }
 
 
-battery *battery_get() {
+battery *battery_get(int battery_number) {
     GError * error = NULL;
     const gchar *entry;
-    GDir * dir = g_dir_open( ACPI_PATH_SYS_POWER_SUPPY, 0, &error );
+    gchar *batt_name = NULL;
+    gchar *batt_path = NULL;
+    GDir * dir = g_dir_open( ACPI_PATH_SYS_POWER_SUPPLY, 0, &error );
     battery *b = NULL;
+    int i;
+
     if ( dir == NULL )
     {
         g_warning( "NO ACPI/sysfs support in kernel: %s", error->message );
         return NULL;
     }
+
+    /* Try the expected path in sysfs first */
+    batt_name = g_strdup_printf(ACPI_BATTERY_DEVICE_NAME "%d", battery_number);
+    batt_path = g_strdup_printf(ACPI_PATH_SYS_POWER_SUPPLY "/%s", batt_name);
+    if (g_file_test(batt_path, G_FILE_TEST_IS_DIR) == TRUE) {
+        b = battery_new();
+        b->path = g_strdup( batt_name);
+        battery_update ( b );
+
+        if (!b->type_battery) {
+            g_warning( "Not a battery: %s", batt_path );
+            battery_free(b);
+            b = NULL;
+        }
+    }
+
+    g_free(batt_name);
+    g_free(batt_path);
+
+    if (b != NULL)
+        goto done;
+
+    /*
+     * We didn't find the expected path in sysfs.
+     * Walk the dir and blindly return n-th entry.
+     */
+    i = 0;
     while ( ( entry = g_dir_read_name (dir) ) != NULL )
     {
         b = battery_new();
         b->path = g_strdup( entry );
         battery_update ( b );
-        if ( b->type_battery == TRUE )
-            break;
-        /* ignore non-batteries */
-        else {
-            g_free(b);
-            b = NULL;
+
+        /* We're looking for a battery with the selected ID */
+        if (b->type_battery == TRUE) {
+            if (i == battery_number)
+                break;
+            i++;
         }
+        battery_free(b);
+        b = NULL;
     }
+    if (b != NULL)
+        g_warning( "Battery entry " ACPI_BATTERY_DEVICE_NAME "%d not found, using %s",
+            battery_number, b->path);
+    else
+        g_warning( "Battery %d not found", battery_number );
+done:
     g_dir_close( dir );
     return b;
 }
@@ -318,6 +360,7 @@ void battery_free(battery* bat)
 {
     if (bat) {
         g_free(bat->path);
+        g_free(bat->state);
         g_free(bat);
     }
 }
index ad2bdbe..4d75449 100644 (file)
@@ -2,6 +2,7 @@
  *      batt_sys.h
  *
  *      Copyright 2009 Juergen Hötzel <juergen@archlinux.org>
+ *                2015 Stanislav Kozina, Ersin <xersin@users.sf.net>
  *
  *      This program is free software; you can redistribute it and/or modify
  *      it under the terms of the GNU General Public License as published by
@@ -25,7 +26,8 @@
 
 
 #define BUF_SIZE 1024
-#define ACPI_PATH_SYS_POWER_SUPPY   "/sys/class/power_supply"
+#define ACPI_PATH_SYS_POWER_SUPPLY  "/sys/class/power_supply"
+#define ACPI_BATTERY_DEVICE_NAME    "BAT"
 #define MIN_CAPACITY    0.01
 #define MIN_PRESENT_RATE 0.01
 #define BATTERY_DESC   "Battery"
@@ -49,14 +51,15 @@ typedef struct battery {
     /* extra info */
     int seconds;
     int percentage;
-    char *state, *poststr;
-    char* capacity_unit;
+    char *state;
+    //const char *poststr;
+    //const char *capacity_unit;
     int type_battery;
 } battery;
 
-battery *battery_get();
+battery *battery_get(int);
 battery *battery_update( battery *b );
-void battery_print(battery *b, int show_capacity);
+//void battery_print(battery *b, int show_capacity);
 gboolean battery_is_charging( battery *b );
 gint battery_get_remaining( battery *b );
 void battery_free(battery* bat);
index 3867e89..8cf3c09 100644 (file)
@@ -9,6 +9,7 @@
  *               2012-2013 Henry Gebhardt <hsggebhardt@gmail.com>
  *               2013 Marko Rauhamaa <marko@pacujo.net>
  *               2014 Andriy Grytsenko <andrej@rep.kiev.ua>
+ *               2015 Rafał Mużyło <galtgendo@gmail.com>
  *
  * This file is a part of LXPanel project.
  *
@@ -69,7 +70,11 @@ typedef struct {
 static void redraw_pixmap(CPUPlugin * c);
 static gboolean cpu_update(CPUPlugin * c);
 static gboolean configure_event(GtkWidget * widget, GdkEventConfigure * event, CPUPlugin * c);
+#if !GTK_CHECK_VERSION(3, 0, 0)
 static gboolean expose_event(GtkWidget * widget, GdkEventExpose * event, CPUPlugin * c);
+#else
+static gboolean draw(GtkWidget * widget, cairo_t * cr, CPUPlugin * c);
+#endif
 
 static void cpu_destructor(gpointer user_data);
 
@@ -217,22 +222,32 @@ static gboolean configure_event(GtkWidget * widget, GdkEventConfigure * event, C
 }
 
 /* Handler for expose_event on drawing area. */
+#if !GTK_CHECK_VERSION(3, 0, 0)
 static gboolean expose_event(GtkWidget * widget, GdkEventExpose * event, CPUPlugin * c)
+#else
+static gboolean draw(GtkWidget * widget, cairo_t * cr, CPUPlugin * c)
+#endif
 {
     /* Draw the requested part of the pixmap onto the drawing area.
      * Translate it in both x and y by the border size. */
     if (c->pixmap != NULL)
     {
+#if !GTK_CHECK_VERSION(3, 0, 0)
         cairo_t * cr = gdk_cairo_create(gtk_widget_get_window(widget));
         GtkStyle * style = gtk_widget_get_style(c->da);
         gdk_cairo_region(cr, event->region);
         cairo_clip(cr);
         gdk_cairo_set_source_color(cr, &style->black);
+#else
+        cairo_set_source_rgb(cr, 0, 0, 0); // FIXME: use black color from style
+#endif
         cairo_set_source_surface(cr, c->pixmap,
               BORDER_SIZE, BORDER_SIZE);
         cairo_paint(cr);
         /* check_cairo_status(cr); */
+#if !GTK_CHECK_VERSION(3, 0, 0)
         cairo_destroy(cr);
+#endif
     }
     return FALSE;
 }
@@ -249,10 +264,11 @@ static GtkWidget *cpu_constructor(LXPanel *panel, config_setting_t *settings)
     gtk_widget_set_has_window(p, FALSE);
     lxpanel_plugin_set_data(p, c, cpu_destructor);
 
-    /* Allocate drawing area as a child of top level widget.  Enable button press events. */
+    /* Allocate drawing area as a child of top level widget. */
     c->da = gtk_drawing_area_new();
+    gtk_widget_add_events(c->da, GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK |
+                                 GDK_BUTTON_MOTION_MASK);
     gtk_widget_set_size_request(c->da, 40, PANEL_HEIGHT_DEFAULT);
-    gtk_widget_add_events(c->da, GDK_BUTTON_PRESS_MASK);
     gtk_container_add(GTK_CONTAINER(p), c->da);
 
     /* Clone a graphics context and set "green" as its foreground color.
@@ -261,7 +277,11 @@ static GtkWidget *cpu_constructor(LXPanel *panel, config_setting_t *settings)
 
     /* Connect signals. */
     g_signal_connect(G_OBJECT(c->da), "configure-event", G_CALLBACK(configure_event), (gpointer) c);
+#if !GTK_CHECK_VERSION(3, 0, 0)
     g_signal_connect(G_OBJECT(c->da), "expose-event", G_CALLBACK(expose_event), (gpointer) c);
+#else
+    g_signal_connect(G_OBJECT(c->da), "draw", G_CALLBACK(draw), (gpointer) c);
+#endif
 
     /* Show the widget.  Connect a timer to refresh the statistics. */
     gtk_widget_show(c->da);
index 57bf5b7..d934427 100644 (file)
@@ -8,7 +8,7 @@
  *               2012 Michael Rawson <michaelrawson76@gmail.com>
  *               2012-2014 Henry Gebhardt <hsggebhardt@gmail.com>
  *               2012 Piotr Sipika <Piotr.Sipika@gmail.com>
- *               2014-2015 Andriy Grytsenko <andrej@rep.kiev.ua>
+ *               2014-2016 Andriy Grytsenko <andrej@rep.kiev.ua>
  *
  * This file is a part of LXPanel project.
  *
@@ -88,7 +88,7 @@ static GtkWidget * dclock_create_calendar(DClockPlugin * dc)
     gtk_container_set_border_width(GTK_CONTAINER(win), 5);
     gtk_window_set_skip_taskbar_hint(GTK_WINDOW(win), TRUE);
     gtk_window_set_skip_pager_hint(GTK_WINDOW(win), TRUE);
-    gtk_window_set_type_hint(GTK_WINDOW(win), GDK_WINDOW_TYPE_HINT_UTILITY);
+    gtk_window_set_type_hint(GTK_WINDOW(win), GDK_WINDOW_TYPE_HINT_DIALOG);
     gtk_window_stick(GTK_WINDOW(win));
 
     /* Create a vertical box as a child of the window. */
@@ -114,9 +114,13 @@ static GtkWidget * dclock_create_calendar(DClockPlugin * dc)
 /* Handler for "button-press-event" event from main widget. */
 static gboolean dclock_button_press_event(GtkWidget * widget, GdkEventButton * evt, LXPanel * panel)
 {
-    DClockPlugin * dc = lxpanel_plugin_get_data(widget);
+    DClockPlugin * dc;
+
+    if (evt->button != 1)
+        return FALSE;
 
     /* If an action is set, execute it. */
+    dc = lxpanel_plugin_get_data(widget);
     if (dc->action != NULL)
         fm_launch_command_simple(NULL, NULL, 0, dc->action, NULL);
 
index 253a70a..74ef750 100644 (file)
@@ -5,6 +5,7 @@
  *               2006 Jim Huang <jserv.tw@gmail.com>
  *               2009 Marty Jack <martyj19@comcast.net>
  *               2014 Andriy Grytsenko <andrej@rep.kiev.ua>
+ *               2016 Charles Lehner <cel10@users.sf.net>
  *
  * This file is a part of LXPanel project.
  *
@@ -98,11 +99,37 @@ static gboolean deskno_button_press_event(GtkWidget * widget, GdkEventButton * e
     int desknum = get_net_current_desktop();
     int desks = get_net_number_of_desktops();
     int newdesk = desknum + 1;
+    Screen *xscreen = GDK_SCREEN_XSCREEN(gtk_widget_get_screen(widget));
     if (newdesk >= desks)
         newdesk = 0;
 
     /* Ask the window manager to make the new desktop current. */
-    Xclimsg(GDK_ROOT_WINDOW(), a_NET_CURRENT_DESKTOP, newdesk, 0, 0, 0, 0);
+    Xclimsgx(xscreen, RootWindowOfScreen(xscreen), a_NET_CURRENT_DESKTOP, newdesk, 0, 0, 0, 0);
+    return TRUE;
+}
+
+/* Handler for scroll events on the plugin */
+static gboolean deskno_scrolled(GtkWidget * p, GdkEventScroll * ev, DesknoPlugin * dc)
+{
+    int desknum = get_net_current_desktop();
+    int desks = get_net_number_of_desktops();
+    Screen *xscreen = GDK_SCREEN_XSCREEN(gtk_widget_get_screen(p));
+
+    switch (ev->direction) {
+        case GDK_SCROLL_DOWN:
+            desknum++;
+            break;
+        case GDK_SCROLL_UP:
+            desknum--;
+            break;
+        default:
+            return FALSE;
+    }
+
+    if (desknum < 0 || desknum >= desks)
+        return TRUE;
+
+    Xclimsgx(xscreen, RootWindowOfScreen(xscreen), a_NET_CURRENT_DESKTOP, desknum, 0, 0, 0, 0);
     return TRUE;
 }
 
@@ -140,6 +167,9 @@ static GtkWidget *deskno_constructor(LXPanel *panel, config_setting_t *settings)
     g_signal_connect(G_OBJECT(fbev), "desktop-names", G_CALLBACK(deskno_redraw), (gpointer) dc);
     g_signal_connect(G_OBJECT(fbev), "number-of-desktops", G_CALLBACK(deskno_redraw), (gpointer) dc);
 
+    gtk_widget_add_events(p, GDK_SCROLL_MASK);
+    g_signal_connect(G_OBJECT(p), "scroll-event", G_CALLBACK(deskno_scrolled), (gpointer) dc);
+
     /* Initialize value and show the widget. */
     deskno_redraw(NULL, dc);
     gtk_widget_show_all(p);
@@ -150,10 +180,12 @@ static GtkWidget *deskno_constructor(LXPanel *panel, config_setting_t *settings)
 static void deskno_destructor(gpointer user_data)
 {
     DesknoPlugin * dc = (DesknoPlugin *) user_data;
+    GtkWidget * p = gtk_widget_get_parent(dc->label);
 
     /* Disconnect signal from window manager event object. */
     g_signal_handlers_disconnect_by_func(G_OBJECT(fbev), deskno_name_update, dc);
     g_signal_handlers_disconnect_by_func(G_OBJECT(fbev), deskno_redraw, dc);
+    g_signal_handlers_disconnect_by_func(G_OBJECT(p), deskno_scrolled, dc);
 
     /* Deallocate all memory. */
     if (dc->desktop_labels != NULL)
index 14ac92c..c7dbfbd 100644 (file)
@@ -5,7 +5,7 @@
  *               2009-2010 Marty Jack <martyj19@comcast.net>
  *               2010 Julien Lavergne <julien.lavergne@gmail.com>
  *               2013 Henry Gebhardt <hsggebhardt@gmail.com>
- *               2014 Andriy Grytsenko <andrej@rep.kiev.ua>
+ *               2014-2016 Andriy Grytsenko <andrej@rep.kiev.ua>
  *
  * This file is a part of LXPanel project.
  *
@@ -250,12 +250,18 @@ static gboolean dirmenu_button_press_event(GtkWidget * widget, GdkEventButton *
     if (event->button == 1)
     {
         dirmenu_show_menu(widget, dm, event->button, event->time);
+        return TRUE;
     }
-    else
+    return FALSE;
+}
+
+static gboolean dirmenu_button_release_event(GtkWidget * widget, GdkEventButton * event, DirMenuPlugin * dm)
+{
+    if (event->button == 2)
     {
         fm_terminal_launch(dm->path, NULL);
     }
-    return TRUE;
+    return FALSE;
 }
 
 /* Plugin constructor. */
@@ -291,6 +297,9 @@ static GtkWidget *dirmenu_constructor(LXPanel *panel, config_setting_t *settings
     /* Initialize the widget. */
     dirmenu_apply_configuration(p);
 
+    g_signal_connect(G_OBJECT(p), "button-release-event",
+                     G_CALLBACK(dirmenu_button_release_event), dm);
+
     /* Show the widget and return. */
     return p;
 }
index 511dad8..4c78c71 100644 (file)
@@ -134,7 +134,7 @@ static GtkWidget *kbled_constructor(LXPanel *panel, config_setting_t *settings)
     p = panel_icon_grid_new(panel_get_orientation(panel),
                             panel_get_icon_size(panel),
                             panel_get_icon_size(panel),
-                            0, 0, panel_get_height(panel));
+                            1, 0, panel_get_height(panel));
     lxpanel_plugin_set_data(p, kl, kbled_destructor);
 
     /* Then allocate three images for the three indications, but make them visible only when the configuration requests. */
@@ -219,7 +219,7 @@ static void kbled_panel_configuration_changed(LXPanel *panel, GtkWidget *p)
     panel_icon_grid_set_geometry(PANEL_ICON_GRID(p), panel_get_orientation(panel),
                                  panel_get_icon_size(panel),
                                  panel_get_icon_size(panel),
-                                 0, 0, panel_get_height(panel));
+                                 1, 0, panel_get_height(panel));
 
     /* Do a full redraw. */
     int current_state = kl->current_state;
diff --git a/plugins/launch-button.c b/plugins/launch-button.c
new file mode 100644 (file)
index 0000000..1e6fbe0
--- /dev/null
@@ -0,0 +1,242 @@
+/**
+ * Copyright (C) 2016 Andriy Grytsenko <andrej@rep.kiev.ua>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "launch-button.h"
+#include "misc.h"
+
+#include <string.h>
+
+/* Representative of one launch button.
+ * Note that the launch parameters come from the specified desktop file, or from the configuration file.
+ * This structure is also used during the "add to launchtaskbar" dialog to hold menu items. */
+struct _LaunchButton
+{
+    GtkEventBox parent;
+    LXPanel * panel;                    /* Back pointer to panel (grandparent widget) */
+    GtkWidget * plugin;                 /* Back pointer to the plugin */
+    FmJob * job;                        /* Async job to retrieve file info */
+    FmFileInfo * fi;                    /* Launcher application descriptor */
+    config_setting_t * settings;        /* Button settings */
+};
+
+
+static void launch_button_job_finished(FmJob *job, LaunchButton *self)
+{
+    GtkWidget *image;
+
+    if (self->job == NULL)
+        return; // duplicate call? seems a bug in libfm
+
+    if (FM_IS_FILE_INFO_JOB(job))
+    {
+        /* absolute path */
+        self->fi = fm_file_info_list_pop_head(FM_FILE_INFO_JOB(job)->file_infos);
+    }
+    else
+    {
+        /* search for id */
+        self->fi = fm_file_info_list_pop_head(FM_DIR_LIST_JOB(job)->files);
+    }
+    self->job = NULL;
+    g_object_unref(job);
+    if (self->fi == NULL)
+    {
+        g_warning("launchbar: desktop entry does not exist");
+        return;
+    }
+    image = lxpanel_image_new_for_fm_icon(self->panel, fm_file_info_get_icon(self->fi),
+                                          -1, NULL);
+    lxpanel_button_compose(GTK_WIDGET(self), image, NULL, NULL);
+    gtk_widget_set_tooltip_text(GTK_WIDGET(self), fm_file_info_get_disp_name(self->fi));
+}
+
+
+/* -----------------------------------------------------------------------------
+ * Class implementation
+ */
+
+G_DEFINE_TYPE(LaunchButton, launch_button, GTK_TYPE_EVENT_BOX)
+
+static void launch_button_dispose(GObject *object)
+{
+    LaunchButton *self = (LaunchButton *)object;
+
+    if (self->job)
+    {
+        g_signal_handlers_disconnect_by_func(self->job,
+                                             launch_button_job_finished, object);
+        fm_job_cancel(self->job);
+        self->job = NULL;
+    }
+
+    if (self->fi)
+    {
+        fm_file_info_unref(self->fi);
+        self->fi = NULL;
+    }
+
+    G_OBJECT_CLASS(launch_button_parent_class)->dispose(object);
+}
+
+static gboolean launch_button_release_event(GtkWidget *widget, GdkEventButton *event)
+{
+    LaunchButton *btn = PANEL_LAUNCH_BUTTON(widget);
+
+    if (event->button == 1) /* left button */
+    {
+        if (btn->job) /* The job is still running */
+            ;
+        else if (btn->fi == NULL)  /* The bootstrap button */
+            lxpanel_plugin_show_config_dialog(btn->plugin);
+        else
+            lxpanel_launch_path(btn->panel, fm_file_info_get_path(btn->fi));
+        return TRUE;
+    }
+    return FALSE;
+}
+
+static void launch_button_init(LaunchButton *self)
+{
+    gtk_container_set_border_width(GTK_CONTAINER(self), 0);
+    gtk_widget_set_can_focus(GTK_WIDGET(self), FALSE);
+}
+
+static void launch_button_class_init(LaunchButtonClass *klass)
+{
+    GObjectClass *object_class = G_OBJECT_CLASS(klass);
+    GtkWidgetClass *widget_class = GTK_WIDGET_CLASS(klass);
+
+    object_class->dispose = launch_button_dispose;
+    widget_class->button_release_event = launch_button_release_event;
+}
+
+
+/* -----------------------------------------------------------------------------
+ * Interface functions
+ */
+
+/* creates new button */
+LaunchButton *launch_button_new(LXPanel *panel, GtkWidget *plugin, FmPath *id,
+                                config_setting_t *settings)
+{
+    LaunchButton *self = g_object_new(PANEL_TYPE_LAUNCH_BUTTON, NULL);
+    GtkWidget *image;
+
+    self->panel = panel;
+    self->plugin = plugin;
+    self->settings = settings;
+    if (id == NULL)
+    {
+        /* a bootstrap button */
+        image = lxpanel_image_new_for_icon(panel, GTK_STOCK_ADD, -1, NULL);
+        lxpanel_button_compose(GTK_WIDGET(self), image, NULL, NULL);
+    }
+    else
+    {
+        /* g_debug("LaunchButton: trying file %s in scheme %s", fm_path_get_basename(id),
+                fm_path_get_basename(fm_path_get_scheme_path(id))); */
+        if (fm_path_is_native(id) ||
+            strncmp(fm_path_get_basename(fm_path_get_scheme_path(id)), "search:", 7) != 0)
+        {
+            FmFileInfoJob *job = fm_file_info_job_new(NULL, FM_FILE_INFO_JOB_NONE);
+
+            fm_file_info_job_add(job, id);
+            self->job = FM_JOB(job);
+        }
+        else /* it is a search job */
+        {
+            FmDirListJob *job = fm_dir_list_job_new2(id, FM_DIR_LIST_JOB_FAST);
+
+            self->job = FM_JOB(job);
+        }
+        g_signal_connect(self->job, "finished",
+                         G_CALLBACK(launch_button_job_finished), self);
+        if (!fm_job_run_async(self->job))
+        {
+            g_object_unref(self->job);
+            self->job = NULL;
+            gtk_widget_destroy(GTK_WIDGET(self));
+            g_warning("launchbar: problem running file search job");
+            return NULL;
+        }
+    }
+    return self;
+}
+
+FmFileInfo *launch_button_get_file_info(LaunchButton *btn)
+{
+    if (PANEL_IS_LAUNCH_BUTTON(btn))
+        return btn->fi;
+    return NULL;
+}
+
+const char *launch_button_get_disp_name(LaunchButton *btn)
+{
+    if (PANEL_IS_LAUNCH_BUTTON(btn) && btn->fi != NULL)
+        return fm_file_info_get_disp_name(btn->fi);
+    return NULL;
+}
+
+FmIcon *launch_button_get_icon(LaunchButton *btn)
+{
+    if (PANEL_IS_LAUNCH_BUTTON(btn) && btn->fi != NULL)
+        return fm_file_info_get_icon(btn->fi);
+    return NULL;
+}
+
+config_setting_t *launch_button_get_settings(LaunchButton *btn)
+{
+    if (PANEL_IS_LAUNCH_BUTTON(btn))
+        return btn->settings;
+    return NULL;
+}
+
+void launch_button_set_settings(LaunchButton *btn, config_setting_t *settings)
+{
+    if (PANEL_IS_LAUNCH_BUTTON(btn))
+        btn->settings = settings;
+}
+
+/**
+ * launch_button_wait_load
+ * @btn: a button instance
+ *
+ * If @btn does not have pending file info then returns. Otherwise waits
+ * for it. If loading the info failed then destroys @btn and associated
+ * settings.
+ *
+ * Returns: %TRUE if button is fully loaded.
+ *
+ * Since: 0.9.0
+ */
+gboolean launch_button_wait_load(LaunchButton *btn)
+{
+    if (!PANEL_IS_LAUNCH_BUTTON(btn) || btn->job == NULL)
+        return TRUE;
+    if (fm_job_run_sync(btn->job))
+        return TRUE;
+
+    if (btn->settings)
+        config_setting_destroy(btn->settings);
+    gtk_widget_destroy(GTK_WIDGET(btn));
+    return FALSE;
+}
diff --git a/plugins/launch-button.h b/plugins/launch-button.h
new file mode 100644 (file)
index 0000000..d84bc9b
--- /dev/null
@@ -0,0 +1,59 @@
+/**
+ * Copyright (C) 2016 Andriy Grytsenko <andrej@rep.kiev.ua>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+#ifndef __LAUNCH_BUTTON_H__
+#define __LAUNCH_BUTTON_H__ 1
+
+#include "plugin.h"
+
+#include <gtk/gtk.h>
+
+G_BEGIN_DECLS
+
+#define PANEL_TYPE_LAUNCH_BUTTON           (launch_button_get_type())
+#define PANEL_LAUNCH_BUTTON(obj)           (G_TYPE_CHECK_INSTANCE_CAST((obj), \
+                                            PANEL_TYPE_LAUNCH_BUTTON, LaunchButton))
+#define PANEL_LAUNCH_BUTTON_CLASS(klass)   (G_TYPE_CHECK_CLASS_CAST((klass), \
+                                            PANEL_TYPE_LAUNCH_BUTTON, LaunchButtonClass))
+#define PANEL_IS_LAUNCH_BUTTON(obj)        (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
+                                            PANEL_TYPE_LAUNCH_BUTTON))
+#define PANEL_IS_LAUNCH_BUTTON_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), \
+                                             PANEL_TYPE_LAUNCH_BUTTON))
+
+extern GType launch_button_get_type        (void) G_GNUC_CONST;
+
+typedef struct _LaunchButton                LaunchButton;
+typedef struct _LaunchButtonClass           LaunchButtonClass;
+
+struct _LaunchButtonClass
+{
+    GtkEventBoxClass parent_class;
+};
+
+/* creates new button */
+LaunchButton *launch_button_new(LXPanel *panel, GtkWidget *plugin, FmPath *path, config_setting_t *settings);
+FmFileInfo *launch_button_get_file_info(LaunchButton *btn);
+const char *launch_button_get_disp_name(LaunchButton *btn);
+FmIcon *launch_button_get_icon(LaunchButton *btn);
+config_setting_t *launch_button_get_settings(LaunchButton *btn);
+void launch_button_set_settings(LaunchButton *btn, config_setting_t *settings);
+gboolean launch_button_wait_load(LaunchButton *btn);
+
+G_END_DECLS
+
+#endif /* __LAUNCH_BUTTON_H__ */
index 8ad7ea1..81af676 100644 (file)
  *               2012-2014 Giuseppe Penone <giuspen@gmail.com>
  *               2013 Vincenzo di Cicco <enzodicicco@gmail.com>
  *               2013 Rouslan <rouslan-k@users.sourceforge.net>
- *               2014-2015 Andriy Grytsenko <andrej@rep.kiev.ua>
+ *               2014-2016 Andriy Grytsenko <andrej@rep.kiev.ua>
  *               2014 Vladimír Pýcha <vpycha@gmail.com>
  *               2014 Raimar Bühmann <raimar@buehmann.de>
  *               2014 Andy Balaam <axis3x3@users.sf.net>
+ *               2015 Balló György <ballogyor@gmail.com>
+ *               2015 Rafał Mużyło <galtgendo@gmail.com>
  *
  * This file is a part of LXPanel project.
  *
@@ -75,7 +77,8 @@
 #include "misc.h"
 #include "ev.h"
 #include "plugin.h"
-#include "icon.xpm"
+#include "task-button.h"
+#include "launch-button.h"
 #include "icon-grid.h"
 #ifndef DISABLE_MENU
 # include "menu-policy.h"
@@ -101,92 +104,33 @@ typedef enum {
 
 typedef struct LaunchTaskBarPlugin LaunchTaskBarPlugin;
 
-/* Structure representing a class.  This comes from WM_CLASS, and should identify windows that come from an application. */
-typedef struct _task_class {
-    struct _task_class *p_taskclass_flink; /* Forward link */
-    char * res_class;                      /* Class name */
-    struct _task * p_task_head;            /* Head of list of tasks with this class */
-    struct _task * p_task_visible;         /* Task that is visible in current desktop, if any */
-    char * visible_name;                   /* Name that will be visible for grouped tasks */
-    int visible_count;                     /* Count of tasks that are visible in current desktop */
-} TaskClass;
-
-/* Structure representing a "task", an open window. */
-typedef struct _task {
-    struct _task * p_task_flink_xwid;       /* Forward link to next task in X window ID order */
-    LaunchTaskBarPlugin * tb;               /* Back pointer to plugin */
-    Window win;                             /* X window ID */
-    char * name;                            /* Taskbar label when normal, from WM_NAME or NET_WM_NAME */
-    char * name_iconified;                  /* Taskbar label when iconified */
-    char * exec_bin;                        /* Exec bin associated to Window */
-    Atom name_source;                       /* Atom that is the source of taskbar label */
-    TaskClass * p_taskclass;                /* Class, from WM_CLASS */
-    struct _task * p_task_flink_same_class; /* Forward link to task in same class */
-    GtkWidget * button;                     /* Button representing task in taskbar */
-    GtkWidget * image;                      /* Icon for task, child of button */
-    Atom image_source;                      /* Atom that is the source of taskbar icon */
-    GtkWidget * label;                      /* Label for task, child of button */
-    GtkWidget * menu_item;                  /* Menu item for grouped task after click */
-    gint desktop;                           /* Desktop that contains task, needed to switch to it on Raise */
-    gint monitor;                           /* Monitor that the window is on or closest to */
-    guint flash_timeout;                    /* Timer for urgency notification */
-    unsigned int focused                :1; /* True if window has focus */
-    unsigned int iconified              :1; /* True if window is iconified, from WM_STATE */
-    unsigned int urgency                :1; /* True if window has an urgency hint, from WM_HINTS */
-    unsigned int flash_state            :1; /* One-bit counter to flash taskbar */
-    unsigned int entered_state          :1; /* True if cursor is inside taskbar button */
-    unsigned int present_in_client_list :1; /* State during WM_CLIENT_LIST processing to detect deletions */
-} Task; /* FIXME: convert it into GtkWidget, eliminate button and menu_item */
-
-/* Representative of one launch button.
- * Note that the launch parameters come from the specified desktop file, or from the configuration file.
- * This structure is also used during the "add to launchtaskbar" dialog to hold menu items. */
-typedef struct {
-    LaunchTaskBarPlugin * p;            /* Back pointer to plugin */
-    GtkWidget * widget;                 /* Pointer to button */
-    FmFileInfo * fi;                    /* Launcher application descriptor */
-    config_setting_t * settings;        /* Pointer to settings */
-    FmDndDest * dd;                     /* Drag and drop support */
-} LaunchButton; /* FIXME: convert it into GtkWidget, button itself */
-
 /* Private context for taskbar plugin. */
 struct LaunchTaskBarPlugin {
     /* LAUNCHBAR */
     GtkWidget *lb_icon_grid;         /* Icon grid managing the container */
-    GSList        *buttons;          /* Launchbar buttons */
-    LaunchButton  *bootstrap_button; /* Bootstrapping button for empty launchtaskbar */
     GtkWidget     *p_button_add, *p_button_remove, *p_label_menu_app_exec, *p_label_def_app_exec;
+    FmDndDest *dd;                 /* Drag & drop on launchbar */
+    GtkWidget *last_lb_drag_dest;  /* Last launch button near drag on launchbar */
+    PanelIconGridDropPosition last_lb_drag_pos;
+    gboolean in_drag;              /* TRUE if some launcher is being dragged */
+    FmPath *dragged_launcher;      /* Path of launcher currently being dragged */
+    int drag_start_x, drag_start_y; /* Drag start coordinates */
     /* TASKBAR */
-    Task * p_task_list;            /* List of tasks to be displayed in taskbar */
-    TaskClass * p_taskclass_list;  /* Window class list */
     GtkWidget * tb_icon_grid;      /* Manager for taskbar buttons */
-    GtkWidget * menu;              /* Popup menu for task control (Close, Raise, etc.) */
-    GtkWidget * group_menu;        /* Popup menu for grouping selection */
-    GtkWidget * workspace_menu0;   /* "Workspace 1" menu item */
-    GdkPixbuf * fallback_pixbuf;   /* Fallback task icon when none is available */
     int number_of_desktops;        /* Number of desktops, from NET_WM_NUMBER_OF_DESKTOPS */
     int current_desktop;           /* Current desktop, from NET_WM_CURRENT_DESKTOP */
-    Task * focused;                /* Task that has focus */
-    Task * focused_previous;       /* Task that had focus just before panel got it */
-    Task * menutask;               /* Task for which popup menu is open */
     guint dnd_delay_timer;         /* Timer for drag and drop delay */
     gboolean dnd_task_moving;      /* User is currently moving a task button */
     int icon_size;                 /* Size of task icons */
-    gboolean show_all_desks;       /* User preference: show windows from all desktops */
-    gboolean tooltips;             /* User preference: show tooltips */
-    gboolean icons_only;           /* User preference: show icons only, omit name */
-    gboolean use_mouse_wheel;      /* User preference: scroll wheel does iconify and raise */
-    gboolean use_urgency_hint;     /* User preference: windows with urgency will flash */
-    gboolean flat_button;          /* User preference: taskbar buttons have visible background */
     gboolean grouped_tasks;        /* User preference: windows from same task are grouped onto a single button */
-    gboolean same_monitor_only;    /* User preference: only show windows that are in the same monitor as the taskbar */
-    gboolean disable_taskbar_upscale; /* User preference: don't upscale taskbar icons */
+    TaskShowFlags flags;        /* User preferences flags */
     int task_width_max;            /* Maximum width of a taskbar button in horizontal orientation */
     int spacing;                   /* Spacing between taskbar buttons */
-    gboolean use_net_active;       /* NET_WM_ACTIVE_WINDOW is supported by the window manager */
-    gboolean net_active_checked;   /* True if use_net_active is valid */
+    guint flash_timeout;        /* Timer for urgency notification */
+    gboolean flash_state;       /* One-bit counter to flash taskbar */
     /* COMMON */
 #ifndef DISABLE_MENU
+    FmPath * path;              /* Current menu item path */
     GtkWidget       *p_menuitem_lock_tbp;
     GtkWidget       *p_menuitem_unlock_tbp;
     GtkWidget       *p_menuitem_new_instance;
@@ -205,11 +149,11 @@ struct LaunchTaskBarPlugin {
     gboolean         lb_built;
     gboolean         tb_built;
     gboolean         fixed_mode;        /* if mode cannot be changed */
+    int              w, h;              /* override GtkBox bug with allocation */
 };
 
 static gchar *launchtaskbar_rc = "style 'launchtaskbar-style' = 'theme-panel'\n"
         "{\n"
-        "GtkWidget::focus-line-width=0\n"
         "GtkWidget::focus-padding=0\n"
         "GtkButton::default-border={0,0,0,0}\n"
         "GtkButton::default-outside-border={0,0,0,0}\n"
@@ -226,57 +170,79 @@ static gchar *launchtaskbar_rc = "style 'launchtaskbar-style' = 'theme-panel'\n"
 
 static void launchtaskbar_destructor(gpointer user_data);
 
+static LaunchButton *launchbar_exec_bin_exists(LaunchTaskBarPlugin *lb, FmPath *path);
+static void launchbar_remove_button(LaunchTaskBarPlugin *ltbp, LaunchButton *btn);
+
 static void taskbar_redraw(LaunchTaskBarPlugin * tb);
-static void task_delete(LaunchTaskBarPlugin * tb, Task * tk, gboolean unlink, gboolean remove);
-static GdkPixbuf * task_update_icon(LaunchTaskBarPlugin * tb, Task * tk, Atom source);
-static void flash_window_update(Task * tk);
-static void taskbar_button_enter(GtkWidget * widget, Task * tk);
-static void taskbar_button_leave(GtkWidget * widget, Task * tk);
-static gboolean flash_window_timeout(gpointer tk);
-static void task_group_menu_destroy(LaunchTaskBarPlugin * tb);
-static gboolean taskbar_popup_activate_event(GtkWidget * widget, GdkEventButton * event, Task * tk);
-static void taskbar_update_style(LaunchTaskBarPlugin * tb);
 static void taskbar_net_client_list(GtkWidget * widget, LaunchTaskBarPlugin * tb);
 static void taskbar_net_current_desktop(GtkWidget * widget, LaunchTaskBarPlugin * tb);
 static void taskbar_net_number_of_desktops(GtkWidget * widget, LaunchTaskBarPlugin * tb);
 static void taskbar_net_active_window(GtkWidget * widget, LaunchTaskBarPlugin * tb);
-static gboolean task_has_urgency(Task * tk);
 static GdkFilterReturn taskbar_event_filter(XEvent * xev, GdkEvent * event, LaunchTaskBarPlugin * tb);
-static void taskbar_make_menu(LaunchTaskBarPlugin * tb);
 static void taskbar_window_manager_changed(GdkScreen * screen, LaunchTaskBarPlugin * tb);
 static void taskbar_apply_configuration(LaunchTaskBarPlugin * ltbp);
+static void taskbar_add_task_button(LaunchTaskBarPlugin * tb, TaskButton * task);
 
-static void f_get_exec_cmd_from_pid(GPid pid, gchar *buffer_128, const gchar *proc_file)
-{
-    buffer_128[0] = '\0';
-    FILE *pipe;
-    gchar  command[64];
-    snprintf(command, 64, "cat /proc/%u/%s", pid, proc_file);
-    pipe = popen(command, "r");
-    if(pipe == NULL)
-        g_warning("ltbp: popen '%s'", command);
-    else if(fgets(buffer_128, 128, pipe) == NULL)
-        g_warning("ltbp: fgets '%s'", command);
-    else
+#define taskbar_reset_menu(tb) if (tb->tb_built) task_button_reset_menu(tb->tb_icon_grid)
+
+
+#ifndef DISABLE_MENU
+static char *task_get_cmdline(Window win, LaunchTaskBarPlugin *ltbp)
+{
+    GPid pid = get_net_wm_pid(win);
+    char proc_path[64];
+    gchar *cmdline = NULL;
+    gchar *p_char = NULL;
+
+    snprintf(proc_path, sizeof(proc_path),
+             G_DIR_SEPARATOR_S "proc" G_DIR_SEPARATOR_S "%lu" G_DIR_SEPARATOR_S "cmdline",
+             (gulong)pid);
+    g_file_get_contents(proc_path, &cmdline, NULL, NULL);
+    if (cmdline)
     {
-        gchar *p_char = strchr(buffer_128, '\n');
+        p_char = strchr(cmdline, '\n');
         if(p_char != NULL) *p_char = '\0';
+        p_char = strrchr(cmdline, G_DIR_SEPARATOR);
+        if (p_char != NULL) p_char++;
+        else p_char = cmdline;
+        if(strcmp(p_char, "python") == 0)
+        {
+            snprintf(proc_path, sizeof(proc_path),
+                     G_DIR_SEPARATOR_S "proc" G_DIR_SEPARATOR_S "%lu" G_DIR_SEPARATOR_S "comm",
+                     (gulong)pid);
+            g_free(cmdline);
+            cmdline = NULL;
+            g_file_get_contents(proc_path, &cmdline, NULL, NULL);
+            if (cmdline)
+            {
+                p_char = strchr(cmdline, '\n');
+                if(p_char != NULL) *p_char = '\0';
+            }
+        }
+        else
+        {
+            p_char = g_key_file_get_string(ltbp->p_key_file_special_cases,
+                                           "special_cases", p_char, NULL);
+            if (p_char != NULL) /* found this key */
+            {
+                g_free(cmdline);
+                cmdline = p_char;
+            }
+        }
     }
-    if(pipe != NULL) pclose(pipe);
+    return cmdline;
 }
 
-#ifndef DISABLE_MENU
-static FmFileInfo *f_find_menu_launchbutton_recursive(const char *exec_bin)
+static FmPath *f_find_menu_launchbutton_recursive(Window win, LaunchTaskBarPlugin *ltbp)
 {
     MenuCache *mc;
     guint32 flags;
     GSList *apps, *l;
     size_t len;
+    char *exec_bin = task_get_cmdline(win, ltbp);
     const char *exec, *short_exec;
     char *str_path;
-    FmPath *path;
-    FmFileInfoJob *job;
-    FmFileInfo *fi = NULL;
+    FmPath *path = NULL;
 
     /* FIXME: cache it in Task object */
     mc = panel_menu_cache_new(&flags);
@@ -303,7 +269,7 @@ static FmFileInfo *f_find_menu_launchbutton_recursive(const char *exec_bin)
     if (l == NULL) for (l = apps; l; l = l->next)
     {
         exec = menu_cache_app_get_exec(MENU_CACHE_APP(l->data));
-        if (exec[0] != '/' && strncmp(exec, short_exec, len) == 0 &&
+        if (exec && exec[0] != '/' && strncmp(exec, short_exec, len) == 0 &&
             (exec[len] == ' ' || exec[len] == 0))
             break;
     }
@@ -315,7 +281,7 @@ static FmFileInfo *f_find_menu_launchbutton_recursive(const char *exec_bin)
         for (l = apps; l; l = l->next)
         {
             exec = menu_cache_app_get_exec(MENU_CACHE_APP(l->data));
-            if (exec[0] == '/' && strncmp(exec, exec_bin, len) == 0 &&
+            if (exec && exec[0] == '/' && strncmp(exec, exec_bin, len) == 0 &&
                 (exec[len] == ' ' || exec[len] == 0))
                 break;
         }
@@ -325,244 +291,480 @@ static FmFileInfo *f_find_menu_launchbutton_recursive(const char *exec_bin)
         str_path = menu_cache_dir_make_path(MENU_CACHE_DIR(l->data));
         path = fm_path_new_relative(fm_path_get_apps_menu(), str_path+13); /* skip /Applications */
         g_free(str_path);
-        job = fm_file_info_job_new(NULL, FM_FILE_INFO_JOB_NONE);
-        fm_file_info_job_add(job, path);
-        fm_path_unref(path);
-        if (!fm_job_run_sync(FM_JOB(job)))
-            g_warning("launchtaskbar: problem running file info job");
-        else
-            fi = fm_file_info_list_pop_head(job->file_infos);
-        g_object_unref(job);
     }
     g_slist_foreach(apps, (GFunc)menu_cache_item_unref, NULL);
     g_slist_free(apps);
     menu_cache_unref(mc);
-    g_debug("f_find_menu_launchbutton_recursive: search '%s' found=%d", exec_bin, (fi != NULL));
-    return fi;
+    g_debug("f_find_menu_launchbutton_recursive: search '%s' found=%d", exec_bin, (path != NULL));
+    g_free(exec_bin);
+    return path;
 }
 #endif
 
-/* Deallocate a LaunchButton. */
-static void launchbutton_free(LaunchButton * btn)
+static void launchbar_remove_bootstrap(LaunchTaskBarPlugin *ltbp)
 {
-    if (btn->fi)
-        fm_file_info_unref(btn->fi);
-    if (btn->dd)
-        g_object_unref(btn->dd);
-    g_free(btn);
-}
+    GList *btns = gtk_container_get_children(GTK_CONTAINER(ltbp->lb_icon_grid));
+    GList *l;
 
-/* Handler for "button-press-event" event from launchtaskbar button. */
-static gboolean launchbutton_press_event(GtkWidget * widget, GdkEventButton * event, LaunchButton * b)
-{
-    if (event->button == 1 && event->type == GDK_BUTTON_PRESS) /* left button */
-    {
-        if (b->fi == NULL)  /* The bootstrap button */
-            lxpanel_plugin_show_config_dialog(b->p->plugin);
-        else
-            lxpanel_launch_path(b->p->panel, fm_file_info_get_path(b->fi));
-        return TRUE;
-    }
-    return FALSE;
+    for (l = btns; l; l = l->next)
+        if (launch_button_get_settings(l->data) == NULL)
+        {
+            gtk_widget_destroy(l->data);
+            g_debug("launchtaskbar: removed bootstrap button %p", l->data);
+        }
+    g_list_free(btns);
 }
 
-/* Handler for "drag-motion" event from launchtaskbar button. */
-static gboolean launchbutton_drag_motion_event(
-    GtkWidget * widget,
-    GdkDragContext * context,
-    gint x,
-    gint y,
-    guint time,
-    LaunchButton * b)
+static void launchbar_check_bootstrap(LaunchTaskBarPlugin *lb)
 {
-    GdkAtom target;
-    GdkDragAction action = 0;
+    LaunchButton *btn;
 
-    fm_dnd_dest_set_dest_file(b->dd, b->fi);
-    target = fm_dnd_dest_find_target(b->dd, context);
-    if (target != GDK_NONE && fm_dnd_dest_is_target_supported(b->dd, target))
-        action = fm_dnd_dest_get_default_action(b->dd, context, target);
-    gdk_drag_status(context, action, time);
-    /* g_debug("launchbutton_drag_motion_event: act=%u",action); */
-    return (action != 0);
+    if (panel_icon_grid_get_n_children(PANEL_ICON_GRID(lb->lb_icon_grid)) > 0)
+        return;
+    btn = launch_button_new(lb->panel, lb->plugin, NULL, NULL);
+    gtk_container_add(GTK_CONTAINER(lb->lb_icon_grid), GTK_WIDGET(btn));
+    g_debug("launchtaskbar: added bootstrap button %p", btn);
 }
 
-/* Build the graphic elements for the bootstrap launchtaskbar button. */
-static void launchbutton_build_bootstrap(LaunchTaskBarPlugin *lb)
+static void launchbar_remove_launcher(LaunchTaskBarPlugin *ltbp, FmPath *path)
 {
-    if(lb->bootstrap_button == NULL)
-    {
-        /* Build a button that has the stock "Add" icon.
-         * The "desktop-id" being NULL is the marker that this is the bootstrap button. */
-        lb->bootstrap_button = g_new0(LaunchButton, 1);
-        lb->bootstrap_button->p = lb;
-
-        /* Create an event box. */
-        lb->bootstrap_button->widget = lxpanel_button_new_for_icon(lb->panel,
-                                                                   GTK_STOCK_ADD,
-                                                                   NULL, NULL);
-        g_signal_connect(lb->bootstrap_button->widget, "button-press-event",
-                         G_CALLBACK(launchbutton_press_event), lb->bootstrap_button);
-
-        /* Add the bootstrap button to the icon grid.  By policy it is empty at this point. */
-        gtk_container_add(GTK_CONTAINER(lb->lb_icon_grid), lb->bootstrap_button->widget);
-        //plugin_widget_set_background(lb->bootstrap_button->widget, lb->panel);
-    }
-    else
-        gtk_widget_show(lb->bootstrap_button->widget);
+    LaunchButton *btn = launchbar_exec_bin_exists(ltbp, path);
+
+    if (btn != NULL)
+        launchbar_remove_button(ltbp, btn);
 }
 
-#ifndef DISABLE_MENU
-static LaunchButton *launchbar_exec_bin_exists(LaunchTaskBarPlugin *lb, FmFileInfo *fi)
+
+/* Process drag & drop launchers between panels and places */
+/* targets are added to FmDndDest, also only targets for GtkTreeDragSource */
+enum {
+    LAUNCHBUTTON_DND_TARGET = N_FM_DND_DEST_DEFAULT_TARGETS
+};
+
+/* Target types for dragging items of list */
+static const GtkTargetEntry dnd_targets[] = {
+    { "application/x-lxpanel-launcher", GTK_TARGET_SAME_APP, LAUNCHBUTTON_DND_TARGET }
+};
+
+static GdkAtom launch_button_dnd_atom;
+static GtkTargetList *drag_src_target_list = NULL;
+
+
+/* source side -- form and send path */
+static gboolean on_launchbar_drag_source(GtkWidget *widget, GdkEvent *event,
+                                         LaunchTaskBarPlugin *lb)
 {
-    LaunchButton *ret_val = NULL;
-    FmPath *path;
-    GSList* l;
+    PanelIconGrid *ig;
+    GtkWidget *btn;
+    PanelIconGridDropPosition pos;
+    FmFileInfo *fi;
+    GdkWindow *win;
+    gdouble x, y;
+#if !GTK_CHECK_VERSION(2, 22, 0)
+    gint px, py;
+#endif
 
-    if (!fi)
-        return NULL;
-    path = fm_file_info_get_path(fi);
-    for(l = lb->buttons; l != NULL; l = l->next)
+    switch (event->type)
     {
-        LaunchButton *btn = (LaunchButton *)l->data;
-        if (btn->fi && fm_path_equal(path, fm_file_info_get_path(btn->fi)))
+    case GDK_BUTTON_PRESS:
+        if (event->button.button != 1)
+            break;
+        if (lb->in_drag)
+            break;
+        if (lb->dragged_launcher)
+            fm_path_unref(lb->dragged_launcher);
+        lb->dragged_launcher = NULL;
+        /* check if it is a launcher where the drag begins */
+        ig = PANEL_ICON_GRID(widget);
+        win = event->button.window;
+        x = event->button.x;
+        y = event->button.y;
+        while (win != NULL && win != gtk_widget_get_window(widget))
         {
-            ret_val = btn;
+#if GTK_CHECK_VERSION(2, 22, 0)
+            gdk_window_coords_to_parent(win, x, y, &x, &y);
+            win = gdk_window_get_effective_parent(win);
+#else
+            gdk_window_get_position(win, &px, &py);
+            x += px;
+            y += py;
+            win = gdk_window_get_parent(win);
+#endif
+        }
+        if (win == NULL)
+            /* this should never happen */
+            break;
+        if (!panel_icon_grid_get_dest_at_pos(ig, (int)x, (int)y, &btn, &pos) ||
+            !PANEL_IS_LAUNCH_BUTTON(btn))
+            break;
+        /* remember the current coordinates and the launcher */
+        fi = launch_button_get_file_info((LaunchButton *)btn);
+        if (fi == NULL)
+            break;
+        lb->dragged_launcher = fm_path_ref(fm_file_info_get_path(fi));
+        lb->drag_start_x = event->button.x;
+        lb->drag_start_y = event->button.y;
+        if (pos != PANEL_ICON_GRID_DROP_INTO)
+            break;
+        /* g_debug("started dragging button #%d at %d,%d", panel_icon_grid_get_child_position(ig, btn), (int)x, (int)y); */
+        lb->in_drag = TRUE;
+        break;
+    case GDK_BUTTON_RELEASE:
+        if (event->button.button != 1)
             break;
+        /* forget the drag state */
+        lb->in_drag = FALSE;
+        /* if user clicked somewhere on border, he/she expects nearest
+           application to be launched, see LP bug #824071. If click was
+           delivered here, it already missed the button, so handle it */
+        if (lb->dragged_launcher &&
+            /* if it was clicked outside button and didn't moved */
+            !gtk_drag_check_threshold(widget, lb->drag_start_x, lb->drag_start_y,
+                                      event->button.x, event->button.y))
+        {
+            /* g_debug("outside click detected"); */
+            lxpanel_launch_path(lb->panel, lb->dragged_launcher);
+        }
+        break;
+    case GDK_MOTION_NOTIFY:
+        if ((event->motion.state & GDK_BUTTON1_MASK) == 0)
+            break;
+        /* if in drag state then check for threshold */
+        if (lb->in_drag &&
+            gtk_drag_check_threshold(widget, lb->drag_start_x, lb->drag_start_y,
+                                     event->motion.x, event->motion.y))
+        {
+            lb->in_drag = FALSE;
+            if (G_UNLIKELY(drag_src_target_list == NULL))
+                drag_src_target_list = gtk_target_list_new(dnd_targets,
+                                                           G_N_ELEMENTS(dnd_targets));
+#if GTK_CHECK_VERSION(3, 10, 0)
+            gtk_drag_begin_with_coordinates(widget, drag_src_target_list,
+                                            GDK_ACTION_MOVE, 1, event,
+                                            event->motion.x, event->motion.y);
+#else
+            gtk_drag_begin(widget, drag_src_target_list, GDK_ACTION_MOVE,
+                           1, event);
+#endif
+            return TRUE;
         }
+        break;
+    default: ;
     }
-    return ret_val;
+    return FALSE;
 }
-#endif
 
-static void launchbar_update_after_taskbar_class_added(LaunchTaskBarPlugin *ltbp, Task *tk)
+static void on_launchbar_drag_begin(GtkWidget *widget, GdkDragContext *context,
+                                    LaunchTaskBarPlugin *lb)
 {
-    GPid   pid = get_net_wm_pid(tk->win);
-    gchar  exec_bin_full[128];
-    f_get_exec_cmd_from_pid(pid, exec_bin_full, "cmdline");
-    gchar *p_char = strrchr(exec_bin_full, '/');
-    if(p_char == NULL) p_char = exec_bin_full;
-    else p_char++;
-    g_free(tk->exec_bin);
-    if(strcmp(p_char, "python") == 0)
-    {
-        f_get_exec_cmd_from_pid(pid, exec_bin_full, "comm");
-    }
-    else
-    {
-        tk->exec_bin = g_key_file_get_string(ltbp->p_key_file_special_cases,
-                                             "special_cases", p_char, NULL);
-        if (tk->exec_bin != NULL) /* found this key */
-            return;
-    }
-    tk->exec_bin = g_strdup(exec_bin_full);
+    /* setup the drag icon from the launcher */
+    LaunchButton *btn = launchbar_exec_bin_exists(lb, lb->dragged_launcher);
 
-#ifdef DEBUG
-    if(ltbp->mode == LAUNCHTASKBAR)
+    if (btn)
     {
-        FmFileInfo *fi = f_find_menu_launchbutton_recursive(tk->exec_bin);
-        LaunchButton *btn = launchbar_exec_bin_exists(ltbp, fi);
-        g_print("\nTB '%s' OPEN (pid=%u), in LB: %c\n",
-            tk->exec_bin, pid, btn != NULL ? 'Y':'N');
-        if (fi)
-            fm_file_info_unref(fi);
-    }
+        FmIcon *icon = launch_button_get_icon(btn);
+
+        if (icon)
+#if GTK_CHECK_VERSION(3, 2, 0)
+            gtk_drag_set_icon_gicon(context, fm_icon_get_gicon(icon), 0, 0);
+#else
+        {
+            gint w;
+            GdkPixbuf *pix;
+            gtk_icon_size_lookup(GTK_ICON_SIZE_DND, &w, NULL);
+            pix = fm_pixbuf_from_icon(icon, w);
+            if (pix)
+            {
+                gtk_drag_set_icon_pixbuf(context, pix, 0, 0);
+                g_object_unref(pix);
+            }
+        }
 #endif
+    }
 }
 
-static void launchbar_update_after_taskbar_class_removed(LaunchTaskBarPlugin *ltbp, Task *tk)
+static void on_launchbar_drag_data_get(GtkWidget *widget, GdkDragContext *context,
+                                       GtkSelectionData *sel_data,
+                                       guint info, guint time,
+                                       LaunchTaskBarPlugin *lb)
 {
-#ifdef DEBUG
-    if(ltbp->mode == LAUNCHTASKBAR)
+    char *path_str;
+
+    switch(info)
     {
-        FmFileInfo *fi = f_find_menu_launchbutton_recursive(tk->exec_bin);
-        LaunchButton *btn = launchbar_exec_bin_exists(ltbp, fi);
-        g_print("\nTB '%s' CLOSE, in LB: %c\n", tk->exec_bin, btn != NULL ? 'Y':'N');
-        if (fi)
-            fm_file_info_unref(fi);
+    case LAUNCHBUTTON_DND_TARGET:
+        if (lb->dragged_launcher == NULL)
+            break;
+        /* create a path_str for currently dragged launcher */
+        path_str = fm_path_to_str(lb->dragged_launcher);
+        /* save it into selection */
+        gtk_selection_data_set(sel_data, launch_button_dnd_atom, 8,
+                               (guchar *)path_str, strlen(path_str));
+        g_free(path_str);
+        break;
+    default: ;
     }
-#endif
 }
 
-/* Build the graphic elements for a launchtaskbar button.  The desktop_id field is already established. */
-/* NOTE: this func consumes reference on fi */
-static LaunchButton *launchbutton_for_file_info(LaunchTaskBarPlugin * lb, FmFileInfo * fi)
+static void on_launchbar_drag_data_delete(GtkWidget *widget,
+                                          GdkDragContext *context,
+                                          LaunchTaskBarPlugin *lb)
 {
-    LaunchButton *btn;
-    GtkWidget *button;
-
-    if (fi == NULL)
+    /* check if remembered data are still valid and remove appropriate child */
+    if (lb->dragged_launcher == NULL)
+        return;
+    launchbar_remove_launcher(lb, lb->dragged_launcher);
+    fm_path_unref(lb->dragged_launcher);
+    lb->dragged_launcher = NULL;
+    if (lb->mode == LAUNCHBAR)
     {
-        g_warning("launchbar: desktop entry does not exist\n");
-        return NULL;
+        /* destroy empty plugin if it is in LAUNCHBAR mode */
+        if (panel_icon_grid_get_n_children(PANEL_ICON_GRID(lb->lb_icon_grid)) == 0)
+            lxpanel_remove_plugin(lb->panel, lb->plugin);
     }
+    else
+        launchbar_check_bootstrap(lb);
+}
 
-    /* Allocate the LaunchButton structure. */
-    btn = g_new0(LaunchButton, 1);
-    btn->p = lb;
-    btn->fi = fi;
+static void on_launchbar_drag_end(GtkWidget *widget, GdkDragContext *context,
+                                  LaunchTaskBarPlugin *lb)
+{
+    /* forget the currently dragged launcher */
+    if (lb->dragged_launcher)
+        fm_path_unref(lb->dragged_launcher);
+    lb->dragged_launcher = NULL;
+}
 
-    /* Create a button with the specified icon. */
-    button = lxpanel_button_new_for_fm_icon(lb->panel, fm_file_info_get_icon(fi),
-                                            NULL, NULL);
-    btn->widget = button;
 
-    gtk_widget_set_tooltip_text(button, fm_file_info_get_disp_name(fi));
+/* destination side -- process data */
+static gboolean on_launchbar_drag_drop(GtkWidget *widget, GdkDragContext *context,
+                                       gint x, gint y, guint time,
+                                       LaunchTaskBarPlugin *lb)
+{
+    GdkAtom target;
 
-    /* Add the button to the icon grid. */
-    gtk_container_add(GTK_CONTAINER(lb->lb_icon_grid), button);
+    target = gtk_drag_dest_find_target(widget, context, NULL);
+    if (target == launch_button_dnd_atom)
+    {
+        /* request for data, it will be processed on "drag-data-received" signal */
+        gtk_drag_get_data(widget, context, launch_button_dnd_atom, time);
+        return TRUE;
+    }
+    target = fm_dnd_dest_find_target(lb->dd, context);
+    if (G_LIKELY(target != GDK_NONE))
+        return fm_dnd_dest_drag_drop(lb->dd, context, target, x, y, time);
+    return FALSE;
+}
 
-    /* Drag and drop support. */
-    btn->dd = fm_dnd_dest_new_with_handlers(button);
+static void on_launchbar_drag_data_received(GtkWidget *widget,
+                                            GdkDragContext *context, gint x,
+                                            gint y, GtkSelectionData *sel_data,
+                                            guint info, guint time,
+                                            LaunchTaskBarPlugin *lb)
+{
+    PanelIconGrid *ig = PANEL_ICON_GRID(widget);
+    GtkWidget *btn;
+    PanelIconGridDropPosition pos;
+    int i;
+    const char *path_str;
+    FmPath *path;
+    config_setting_t *s;
 
-    /* Connect signals. */
-    g_signal_connect(button, "button-press-event", G_CALLBACK(launchbutton_press_event), (gpointer) btn);
-    g_signal_connect(button, "drag-motion", G_CALLBACK(launchbutton_drag_motion_event), btn);
+    switch(info)
+    {
+    case LAUNCHBUTTON_DND_TARGET:
+        if (panel_icon_grid_get_dest_at_pos(ig, x, y, &btn, &pos) &&
+            PANEL_IS_LAUNCH_BUTTON(btn) && (pos != PANEL_ICON_GRID_DROP_INTO ||
+            launch_button_get_settings((LaunchButton *)btn) == NULL))
+        {
+            /* it is destined to some position, calculate it */
+            i = panel_icon_grid_get_child_position(ig, btn);
+            g_return_if_fail(i >= 0);
+            if (pos == PANEL_ICON_GRID_DROP_LEFT_AFTER ||
+                pos == PANEL_ICON_GRID_DROP_RIGHT_AFTER)
+                i++;
+            /* get data from selection */
+            path_str = (char *)gtk_selection_data_get_data(sel_data);
+            if (!path_str)
+                break;
+            /* g_debug("dropping dragged button to %d position", i); */
+            path = fm_path_new_for_str(path_str);
+            /* create new LaunchButton */
+            s = config_group_add_subgroup(lb->settings, "Button");
+            if (fm_path_equal(fm_path_get_scheme_path(path), fm_path_get_apps_menu()))
+                config_group_set_string(s, "id", fm_path_get_basename(path));
+            else
+                config_group_set_string(s, "id", path_str);
+            btn = GTK_WIDGET(launch_button_new(lb->panel, lb->plugin, path, s));
+            fm_path_unref(path);
+            if (btn)
+            {
+                /* position it and send confirmation to remove it from former place */
+                gtk_container_add(GTK_CONTAINER(lb->lb_icon_grid), btn);
+                panel_icon_grid_reorder_child(PANEL_ICON_GRID(lb->lb_icon_grid),
+                                              btn, i);
+                config_setting_move_elem(s, config_setting_get_parent(s), i);
+                lxpanel_config_save(lb->panel);
+                launchbar_remove_bootstrap(lb);
+                gtk_drag_finish(context, TRUE, TRUE, time);
+                break;
+            }
+            /* failed to create button - should be impossible though */
+            config_setting_destroy(s);
+        }
+        gtk_drag_finish(context, FALSE, FALSE, time);
+        break;
+    default:
+        fm_dnd_dest_drag_data_received(lb->dd, context, x, y, sel_data, info, time);
+    }
+}
 
-    /* If the list goes from null to non-null, remove the bootstrap button. */
-    if ((lb->buttons == NULL) && (lb->bootstrap_button != NULL))
-        gtk_widget_hide(lb->bootstrap_button->widget);
+/* Handler for "drag-motion" event from launchtaskbar button. */
+static gboolean on_launchbar_drag_motion(
+    GtkWidget * widget,
+    GdkDragContext * context,
+    gint x,
+    gint y,
+    guint time,
+    LaunchTaskBarPlugin * b)
+{
+    GdkAtom target;
+    GdkDragAction action = 0, lb_atom_action = 0;
+    GtkWidget *btn;
+    FmFileInfo *fi = NULL;
+    PanelIconGridDropPosition pos;
 
-    /* Append at end of list to preserve configured order. */
-    lb->buttons = g_slist_append(lb->buttons, btn);
+    if (!panel_icon_grid_get_dest_at_pos(PANEL_ICON_GRID(b->lb_icon_grid), x, y,
+                                         &btn, &pos) || !btn)
+    {
+        panel_icon_grid_set_drag_dest(PANEL_ICON_GRID(b->lb_icon_grid), NULL, 0);
+        fm_dnd_dest_set_dest_file(b->dd, NULL);
+        gdk_drag_status(context, 0, time);
+        return TRUE;
+    }
+    b->last_lb_drag_dest = btn;
+    b->last_lb_drag_pos = pos;
+    panel_icon_grid_set_drag_dest(PANEL_ICON_GRID(b->lb_icon_grid), btn, pos);
+    if (PANEL_IS_LAUNCH_BUTTON(btn))
+    {
+        if (launch_button_get_settings((LaunchButton *)btn) == NULL)
+        {
+            /* bootstrap button */
+            b->last_lb_drag_pos = PANEL_ICON_GRID_DROP_LEFT_BEFORE;
+            lb_atom_action = GDK_ACTION_MOVE;
+        }
+        else if (pos == PANEL_ICON_GRID_DROP_INTO)
+            fi = launch_button_get_file_info((LaunchButton *)btn);
+        else
+            lb_atom_action = GDK_ACTION_MOVE;
+    }
+    fm_dnd_dest_set_dest_file(b->dd, fi);
+    target = fm_dnd_dest_find_target(b->dd, context);
+    if (target == GDK_NONE)
+    {
+        target = gtk_drag_dest_find_target(widget, context, NULL);
+        if (target == launch_button_dnd_atom)
+            action = lb_atom_action; /* action was set above */
+    }
+    else if (fm_dnd_dest_is_target_supported(b->dd, target))
+    {
+        action = fm_dnd_dest_get_default_action(b->dd, context, target);
+        if (fi == NULL && PANEL_IS_LAUNCH_BUTTON(btn))
+            /* dropping on free place */
+            action = GDK_ACTION_COPY;
+    }
+    gdk_drag_status(context, action, time);
+    /* g_debug("launchbutton_drag_motion_event: act=%u",action); */
+    return TRUE;
+}
 
-    /* Show the widget and return. */
-    //plugin_widget_set_background(button, lb->panel);
-    return btn;
+static void on_launchbar_drag_leave(GtkWidget * widget, GdkDragContext * drag_context,
+                                    guint time, LaunchTaskBarPlugin * lb)
+{
+    fm_dnd_dest_drag_leave(lb->dd, drag_context, time);
+    panel_icon_grid_set_drag_dest(PANEL_ICON_GRID(lb->lb_icon_grid), NULL, 0);
+    fm_dnd_dest_set_dest_file(lb->dd, NULL);
 }
 
-static LaunchButton *launchbutton_build_gui(LaunchTaskBarPlugin * lb, FmPath * id)
+static gboolean on_launchbar_files_dropped(FmDndDest *dd, int x, int y, GdkDragAction action,
+                                           FmDndDestTargetType info_type,
+                                           FmPathList *files, LaunchTaskBarPlugin *lb)
 {
-    /* Try to get the file data */
-    FmFileInfoJob *job = fm_file_info_job_new(NULL, FM_FILE_INFO_JOB_NONE);
-    FmFileInfo *fi;
+    FmPath *path;
+    LaunchButton *btn;
+    char *path_str;
+    config_setting_t *s;
+    int i;
 
-    fm_file_info_job_add(job, id);
-    if (!fm_job_run_sync(FM_JOB(job)))
+    if (action != GDK_ACTION_COPY)
+        return FALSE;
+    path = fm_path_list_peek_head(files);
+    if (!path)
+        return FALSE;
+    if (!lb->last_lb_drag_dest)
+        return FALSE;
+    i = panel_icon_grid_get_child_position(PANEL_ICON_GRID(lb->lb_icon_grid),
+                                           lb->last_lb_drag_dest);
+    lb->last_lb_drag_dest = NULL;
+    if (i < 0)
+        return FALSE;
+    switch (lb->last_lb_drag_pos)
     {
-        g_warning("launchbar: problem running file info job\n");
-        g_object_unref(job);
-        return NULL;
+    case PANEL_ICON_GRID_DROP_LEFT_AFTER:
+    case PANEL_ICON_GRID_DROP_RIGHT_AFTER:
+        i++;
+        break;
+    case PANEL_ICON_GRID_DROP_LEFT_BEFORE:
+    case PANEL_ICON_GRID_DROP_RIGHT_BEFORE:
+        break;
+    default:
+        return FALSE;
+    }
+    s = config_group_add_subgroup(lb->settings, "Button");
+    if (fm_path_equal(fm_path_get_scheme_path(path), fm_path_get_apps_menu()))
+        config_group_set_string(s, "id", fm_path_get_basename(path));
+    else
+    {
+        path_str = fm_path_to_str(path);
+        /* g_debug("*** path '%s' pos %d", path_str, i); */
+        config_group_set_string(s, "id", path_str);
+        g_free(path_str);
+    }
+    btn = launch_button_new(lb->panel, lb->plugin, path, s);
+    if (btn)
+    {
+        gtk_container_add(GTK_CONTAINER(lb->lb_icon_grid), GTK_WIDGET(btn));
+        panel_icon_grid_reorder_child(PANEL_ICON_GRID(lb->lb_icon_grid),
+                                      GTK_WIDGET(btn), i);
+        config_setting_move_elem(s, config_setting_get_parent(s), i);
+        lxpanel_config_save(lb->panel);
+        launchbar_remove_bootstrap(lb);
     }
-    fi = fm_file_info_list_pop_head(job->file_infos);
-    g_object_unref(job);
-    return launchbutton_for_file_info(lb, fi);
+    else
+        config_setting_destroy(s);
+    return TRUE;
 }
 
-static LaunchButton *launchbutton_search_and_build_gui(LaunchTaskBarPlugin * lb, FmPath * id)
+static LaunchButton *launchbar_exec_bin_exists(LaunchTaskBarPlugin *lb, FmPath *path)
 {
-    FmDirListJob *job = fm_dir_list_job_new2(id, FM_DIR_LIST_JOB_FAST);
+    LaunchButton *ret_val = NULL;
+    GList *children, *l;
     FmFileInfo *fi;
 
-    if (!fm_job_run_sync(FM_JOB(job)))
-    {
-        g_warning("launchbar: problem running file search job\n");
-        g_object_unref(job);
+    if (!path)
         return NULL;
+    children = gtk_container_get_children(GTK_CONTAINER(lb->lb_icon_grid));
+    for (l = children; l != NULL; l = l->next)
+    {
+        fi = launch_button_get_file_info(PANEL_LAUNCH_BUTTON(l->data));
+        if (fi && fm_path_equal(path, fm_file_info_get_path(fi)))
+        {
+            ret_val = l->data;
+            break;
+        }
     }
-    fi = fm_file_info_list_pop_head(job->files);
-    g_object_unref(job);
-    return launchbutton_for_file_info(lb, fi);
+    g_list_free(children);
+    return ret_val;
 }
 
 /* Read the configuration file entry for a launchtaskbar button and create it. */
@@ -582,24 +784,22 @@ static gboolean launchbutton_constructor(LaunchTaskBarPlugin * lb, config_settin
     {
         str_path = expand_tilda(str);
         path = fm_path_new_for_path(str_path);
-        btn = launchbutton_build_gui(lb, path);
     }
     else if (strchr(str, '/') != NULL)
     {
         path = fm_path_new_for_str(str);
         /* FIXME: check if str contains invalid path */
-        btn = launchbutton_build_gui(lb, path);
     }
     else
     {
         str_path = g_strdup_printf("search://menu://applications/?recursive=1&show_hidden=1&name=%s", str);
         path = fm_path_new_for_uri(str_path);
-        btn = launchbutton_search_and_build_gui(lb, path);
     }
+    btn = launch_button_new(lb->panel, lb->plugin, path, s);
     g_free(str_path);
     fm_path_unref(path);
     if (btn)
-        btn->settings = s;
+        gtk_container_add(GTK_CONTAINER(lb->lb_icon_grid), GTK_WIDGET(btn));
     return (btn != NULL);
 }
 
@@ -664,9 +864,10 @@ static void launchtaskbar_constructor_add_default_special_case(LaunchTaskBarPlug
     g_key_file_set_value(ltbp->p_key_file_special_cases, "special_cases", tk_exec, mb_exec);
 }
 
-static void launchtaskbar_constructor_launch(LaunchTaskBarPlugin *ltbp, gboolean build_bootstrap)
+static void launchtaskbar_constructor_launch(LaunchTaskBarPlugin *ltbp)
 {
     config_setting_t *settings;
+    guint i = 0;
 
     if(!ltbp->lb_built)
     {
@@ -676,9 +877,8 @@ static void launchtaskbar_constructor_launch(LaunchTaskBarPlugin *ltbp, gboolean
         if (settings && config_setting_is_list(settings))
         {
             config_setting_t *s;
-            guint i;
 
-            for (i = 0; (s = config_setting_get_elem(settings, i)) != NULL; )
+            while ((s = config_setting_get_elem(settings, i)) != NULL)
             {
                 if (strcmp(config_setting_get_name(s), "Button") != 0)
                 {
@@ -697,15 +897,101 @@ static void launchtaskbar_constructor_launch(LaunchTaskBarPlugin *ltbp, gboolean
                     i++;
             }
         }
-        if(build_bootstrap)
+        if (i == 0)
         {
-            if(ltbp->buttons == NULL)
-                launchbutton_build_bootstrap(ltbp);
+            /* build bootstrap button */
+            launchbar_check_bootstrap(ltbp);
         }
+        /* Drag and drop support. */
+        g_signal_connect(ltbp->lb_icon_grid, "button-press-event",
+                         G_CALLBACK(on_launchbar_drag_source), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "button-release-event",
+                         G_CALLBACK(on_launchbar_drag_source), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "motion-notify-event",
+                         G_CALLBACK(on_launchbar_drag_source), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "drag-begin",
+                         G_CALLBACK(on_launchbar_drag_begin), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "drag-data-get",
+                         G_CALLBACK(on_launchbar_drag_data_get), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "drag-data-delete",
+                         G_CALLBACK(on_launchbar_drag_data_delete), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "drag-end",
+                         G_CALLBACK(on_launchbar_drag_end), ltbp);
+        ltbp->dd = fm_dnd_dest_new(ltbp->lb_icon_grid);
+        fm_dnd_dest_add_targets(ltbp->lb_icon_grid, dnd_targets,
+                                G_N_ELEMENTS(dnd_targets));
+        g_signal_connect(ltbp->lb_icon_grid, "drag-motion",
+                         G_CALLBACK(on_launchbar_drag_motion), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "drag-drop",
+                         G_CALLBACK(on_launchbar_drag_drop), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "drag-data-received",
+                         G_CALLBACK(on_launchbar_drag_data_received), ltbp);
+        g_signal_connect(ltbp->lb_icon_grid, "drag-leave",
+                         G_CALLBACK(on_launchbar_drag_leave), ltbp);
+        g_signal_connect(ltbp->dd, "files-dropped",
+                         G_CALLBACK(on_launchbar_files_dropped), ltbp);
+        launch_button_dnd_atom = gdk_atom_intern("application/x-lxpanel-launcher", FALSE);
     }
     gtk_widget_set_visible(ltbp->lb_icon_grid, TRUE);
 }
 
+static void flash_window_update_iter(GtkWidget *widget, gpointer data)
+{
+    task_button_set_flash_state(PANEL_TASK_BUTTON(widget), GPOINTER_TO_INT(data));
+}
+
+static gboolean flash_window_timeout(gpointer user_data)
+{
+    LaunchTaskBarPlugin *tb;
+
+    if (g_source_is_destroyed(g_main_current_source()))
+        return FALSE;
+    tb = user_data;
+    tb->flash_state = !tb->flash_state;
+    gtk_container_foreach(GTK_CONTAINER(tb->tb_icon_grid),
+                          flash_window_update_iter, GINT_TO_POINTER(tb->flash_state));
+    return TRUE;
+}
+
+static void on_gtk_cursor_blink_time_changed(GObject *gsettings, GParamSpec *pspec,
+                                             LaunchTaskBarPlugin *tb)
+{
+    gint interval;
+
+    if (tb->flash_timeout == 0) /* nothing to do? */
+        return;
+    g_source_remove(tb->flash_timeout);
+    g_object_get(gtk_widget_get_settings(GTK_WIDGET(tb)), "gtk-cursor-blink-time",
+                 &interval, NULL);
+    tb->flash_timeout = g_timeout_add(interval / 2, flash_window_timeout, tb);
+}
+
+/* Set an urgency timer on a task. */
+static void set_timer_on_task(LaunchTaskBarPlugin *tb)
+{
+    gint interval;
+
+    if (tb->flash_timeout != 0)
+        return;
+    g_object_get(gtk_widget_get_settings(GTK_WIDGET(tb->plugin)),
+                 "gtk-cursor-blink-time", &interval, NULL);
+    g_signal_connect(gtk_widget_get_settings(GTK_WIDGET(tb->plugin)),
+                     "notify::gtk-cursor-blink-time",
+                     G_CALLBACK(on_gtk_cursor_blink_time_changed), tb);
+    tb->flash_timeout = g_timeout_add(interval / 2, flash_window_timeout, tb);
+}
+
+static void reset_timer_on_task(LaunchTaskBarPlugin *tb)
+{
+    if (tb->flash_timeout == 0)
+        return;
+    g_source_remove(tb->flash_timeout);
+    tb->flash_timeout = 0;
+    g_signal_handlers_disconnect_by_func(gtk_widget_get_settings(GTK_WIDGET(tb->plugin)),
+                                         on_gtk_cursor_blink_time_changed, tb);
+}
+
+
 static void launchtaskbar_constructor_task(LaunchTaskBarPlugin *ltbp)
 {
     if(!ltbp->tb_built)
@@ -717,34 +1003,37 @@ static void launchtaskbar_constructor_task(LaunchTaskBarPlugin *ltbp)
 
         /* Parse configuration now */
         if (config_setting_lookup_int(s, "tooltips", &tmp_int))
-            ltbp->tooltips = (tmp_int != 0);
+            ltbp->flags.tooltips = (tmp_int != 0);
         if (config_setting_lookup_int(s, "IconsOnly", &tmp_int))
-            ltbp->icons_only = (tmp_int != 0);
+            ltbp->flags.icons_only = (tmp_int != 0);
         if (config_setting_lookup_int(s, "ShowAllDesks", &tmp_int))
-            ltbp->show_all_desks = (tmp_int != 0);
+            ltbp->flags.show_all_desks = (tmp_int != 0);
         if (config_setting_lookup_int(s, "SameMonitorOnly", &tmp_int))
-            ltbp->same_monitor_only = (tmp_int != 0);
+            ltbp->flags.same_monitor_only = (tmp_int != 0);
         if (config_setting_lookup_int(s, "DisableUpscale", &tmp_int))
-            ltbp->disable_taskbar_upscale = (tmp_int != 0);
+            ltbp->flags.disable_taskbar_upscale = (tmp_int != 0);
         config_setting_lookup_int(s, "MaxTaskWidth", &ltbp->task_width_max);
         config_setting_lookup_int(s, "spacing", &ltbp->spacing);
         if (config_setting_lookup_int(s, "UseMouseWheel", &tmp_int))
-            ltbp->use_mouse_wheel = (tmp_int != 0);
+            ltbp->flags.use_mouse_wheel = (tmp_int != 0);
         if (config_setting_lookup_int(s, "UseUrgencyHint", &tmp_int))
-            ltbp->use_urgency_hint = (tmp_int != 0);
+            ltbp->flags.use_urgency_hint = (tmp_int != 0);
         if (config_setting_lookup_int(s, "FlatButton", &tmp_int))
-            ltbp->flat_button = (tmp_int != 0);
+            ltbp->flags.flat_button = (tmp_int != 0);
         if (config_setting_lookup_int(s, "GroupedTasks", &tmp_int))
             ltbp->grouped_tasks = (tmp_int != 0);
+        if (config_setting_lookup_int(s, "UseSmallerIcons", &tmp_int))
+            ltbp->flags.use_smaller_icons = (tmp_int != 0);
 
         /* Make container for task buttons as a child of top level widget. */
         ltbp->tb_icon_grid = panel_icon_grid_new(panel_get_orientation(ltbp->panel),
-                                                 ltbp->task_width_max,
-                                                 ltbp->icon_size, ltbp->spacing, 0,
+                                                 ((ltbp->flags.icons_only) ? ltbp->icon_size + ICON_ONLY_EXTRA : ltbp->task_width_max),
+                                                 ((ltbp->flags.icons_only) ? ltbp->icon_size + ICON_ONLY_EXTRA : ltbp->icon_size + ICON_BUTTON_TRIM),
+                                                 ltbp->spacing, 0,
                                                  panel_get_height(ltbp->panel));
         panel_icon_grid_set_constrain_width(PANEL_ICON_GRID(ltbp->tb_icon_grid), TRUE);
         gtk_box_pack_start(GTK_BOX(ltbp->plugin), ltbp->tb_icon_grid, TRUE, TRUE, 0);
-        taskbar_update_style(ltbp);
+        /* taskbar_update_style(ltbp); */
 
         /* Add GDK event filter. */
         gdk_window_add_filter(NULL, (GdkFilterFunc) taskbar_event_filter, ltbp);
@@ -757,14 +1046,13 @@ static void launchtaskbar_constructor_task(LaunchTaskBarPlugin *ltbp)
         g_signal_connect(G_OBJECT(fbev), "number-of-desktops", G_CALLBACK(taskbar_net_number_of_desktops), (gpointer) ltbp);
         g_signal_connect(G_OBJECT(fbev), "client-list", G_CALLBACK(taskbar_net_client_list), (gpointer) ltbp);
 
-        /* Make right-click menu for task buttons.
-         * It is retained for the life of the taskbar and will be shown as needed.
-         * Number of desktops and edge is needed for this operation. */
-        taskbar_make_menu(ltbp);
-
         /* Connect a signal to be notified when the window manager changes.  This causes re-evaluation of the "use_net_active" status. */
         g_signal_connect(ltbp->screen, "window-manager-changed", G_CALLBACK(taskbar_window_manager_changed), ltbp);
 
+        /* Start blinking timeout if configured */
+        if (ltbp->flags.use_urgency_hint)
+            set_timer_on_task(ltbp);
+
         /* Fetch the client list and redraw the taskbar.  Then determine what window has focus. */
         taskbar_net_client_list(NULL, ltbp);
         taskbar_net_active_window(NULL, ltbp);
@@ -772,12 +1060,35 @@ static void launchtaskbar_constructor_task(LaunchTaskBarPlugin *ltbp)
     gtk_widget_set_visible(ltbp->tb_icon_grid, TRUE);
 }
 
+/* Override GtkBox bug - it does not always propagate allocation to children */
+static void on_size_allocation(GtkWidget *widget, GtkAllocation *a, LaunchTaskBarPlugin *ltbp)
+{
+    if (ltbp->w != a->width || ltbp->h != a->height)
+    {
+        ltbp->w = a->width;
+        ltbp->h = a->height;
+        if (ltbp->lb_built && gtk_widget_get_visible(ltbp->lb_icon_grid))
+            panel_icon_grid_set_geometry(PANEL_ICON_GRID(ltbp->lb_icon_grid),
+                                         panel_get_orientation(ltbp->panel),
+                                         ltbp->icon_size, ltbp->icon_size,
+                                         3, 0, panel_get_height(ltbp->panel));
+        if (ltbp->tb_built && gtk_widget_get_visible(ltbp->tb_icon_grid))
+            panel_icon_grid_set_geometry(PANEL_ICON_GRID(ltbp->tb_icon_grid),
+                                         panel_get_orientation(ltbp->panel),
+                                         ((ltbp->flags.icons_only) ? ltbp->icon_size + ICON_ONLY_EXTRA : ltbp->task_width_max),
+                                         ((ltbp->flags.icons_only) ? ltbp->icon_size + ICON_ONLY_EXTRA : ltbp->icon_size + ICON_BUTTON_TRIM),
+                                         ltbp->spacing, 0,
+                                         panel_get_height(ltbp->panel));
+    }
+}
+
 /* Plugin constructor. */
 static GtkWidget *_launchtaskbar_constructor(LXPanel *panel, config_setting_t *settings,
                                              LtbMode mode)
 {
     GtkWidget *p;
     LaunchTaskBarPlugin *ltbp;
+    int height;
 
     gtk_rc_parse_string(launchtaskbar_rc);
 
@@ -790,13 +1101,14 @@ static GtkWidget *_launchtaskbar_constructor(LXPanel *panel, config_setting_t *s
 
     /* Initialize to defaults. */
     ltbp->icon_size         = panel_get_icon_size(panel);
-    ltbp->tooltips          = TRUE;
-    ltbp->icons_only        = FALSE;
-    ltbp->show_all_desks    = TRUE;
+    ltbp->flags.tooltips    = TRUE;
+    ltbp->flags.icons_only  = FALSE;
+    ltbp->flags.show_all_desks = TRUE;
     ltbp->task_width_max    = TASK_WIDTH_MAX;
     ltbp->spacing           = 1;
-    ltbp->use_mouse_wheel   = TRUE;
-    ltbp->use_urgency_hint  = TRUE;
+    ltbp->flags.use_mouse_wheel = TRUE;
+    ltbp->flags.use_urgency_hint = TRUE;
+    ltbp->flags.use_smaller_icons = TRUE;
     ltbp->grouped_tasks     = FALSE;
     ltbp->fixed_mode        = (mode == LAUNCHBAR) || (mode == TASKBAR);
 
@@ -821,22 +1133,26 @@ static GtkWidget *_launchtaskbar_constructor(LXPanel *panel, config_setting_t *s
     ltbp->plugin = p = panel_box_new(panel, FALSE, 5);
     lxpanel_plugin_set_data(p, ltbp, launchtaskbar_destructor);
     /* Allocate an icon grid manager to manage the container. */
+    height = panel_get_height(panel);
     ltbp->lb_icon_grid = panel_icon_grid_new(panel_get_orientation(panel),
                                              ltbp->icon_size, ltbp->icon_size,
-                                             3, 0, panel_get_height(panel));
+                                             3, 0, height);
     gtk_box_pack_start(GTK_BOX(p), ltbp->lb_icon_grid, FALSE, TRUE, 0);
 
+    /* Setup override on GtkBox bug */
+    g_signal_connect(p, "size-allocate", G_CALLBACK(on_size_allocation), ltbp);
+
     /* Read parameters from the configuration file. */
     config_setting_lookup_int(settings, "LaunchTaskBarMode", &ltbp->mode);
     switch (ltbp->mode) {
     case LAUNCHBAR:
-        launchtaskbar_constructor_launch(ltbp, TRUE/*build_bootstrap*/);
+        launchtaskbar_constructor_launch(ltbp);
         gtk_widget_set_name(p, "launchbar");
         break;
     default:
         ltbp->mode = LAUNCHTASKBAR; /* reset invalid value */
     case LAUNCHTASKBAR:
-        launchtaskbar_constructor_launch(ltbp, TRUE/*build_bootstrap*/);
+        launchtaskbar_constructor_launch(ltbp);
         gtk_widget_set_name(p, "launchtaskbar");
     case TASKBAR:
         launchtaskbar_constructor_task(ltbp);
@@ -854,15 +1170,14 @@ static GtkWidget *launchtaskbar_constructor(LXPanel *panel, config_setting_t *se
 
 static void launchtaskbar_destructor_launch(LaunchTaskBarPlugin *ltbp)
 {
-    /* Free the launchbar. */
-    g_slist_foreach(ltbp->buttons, (GFunc) launchbutton_free, NULL);
-
-    /* Free the bootstrap button if it exists. */
-    if(ltbp->bootstrap_button != NULL)
+    if (ltbp->dd)
     {
-        launchbutton_free(ltbp->bootstrap_button);
-        ltbp->bootstrap_button = NULL;
+        g_signal_handlers_disconnect_by_func(ltbp->dd, on_launchbar_files_dropped, ltbp);
+        g_object_unref(ltbp->dd);
     }
+    /* do not disconnect handler on child widget - it is already destroyed */
+    if (ltbp->dragged_launcher)
+        fm_path_unref(ltbp->dragged_launcher);
 }
 
 static void launchtaskbar_destructor_task(LaunchTaskBarPlugin *ltbp)
@@ -879,22 +1194,12 @@ static void launchtaskbar_destructor_task(LaunchTaskBarPlugin *ltbp)
     /* Remove "window-manager-changed" handler. */
     g_signal_handlers_disconnect_by_func(ltbp->screen, taskbar_window_manager_changed, ltbp);
 
-    /* Deallocate task list - widgets are already destroyed there. */
-    while(ltbp->p_task_list != NULL)
-        task_delete(ltbp, ltbp->p_task_list, TRUE, FALSE);
-
-    /* Deallocate class list. */
-    while(ltbp->p_taskclass_list != NULL)
-    {
-        TaskClass * tc = ltbp->p_taskclass_list;
-        ltbp->p_taskclass_list = tc->p_taskclass_flink;
-        g_free(tc->res_class);
-        g_free(tc);
-    }
-
-    /* Deallocate other memory. */
-    gtk_widget_destroy(ltbp->menu);
-    task_group_menu_destroy(ltbp);
+    /* Stop blinking timeout */
+    reset_timer_on_task(ltbp);
+#ifndef DISABLE_MENU
+    if (ltbp->path)
+        fm_path_unref(ltbp->path);
+#endif
 }
 
 /* Plugin destructor. */
@@ -922,26 +1227,38 @@ static void _launchbar_configure_add(GtkTreeView *menu_view, LaunchTaskBarPlugin
     FmPath * sel_path = fm_app_menu_view_dup_selected_app_desktop_path(menu_view);
     LaunchButton * btn;
 
-    if (sel_path != NULL && (btn = launchbutton_build_gui(ltbp, sel_path)) != NULL)
+    if (sel_path != NULL &&
+        (btn = launch_button_new(ltbp->panel, ltbp->plugin, sel_path, NULL)) != NULL &&
+        launch_button_wait_load(btn))
     {
         GtkListStore * list = GTK_LIST_STORE(gtk_tree_view_get_model(defined_view));
         GtkTreeIter it;
         GdkPixbuf* pix;
         char *path;
+        config_setting_t *settings;
+        gtk_container_add(GTK_CONTAINER(ltbp->lb_icon_grid), GTK_WIDGET(btn));
         gtk_list_store_append(list, &it);
-        pix = fm_pixbuf_from_icon(fm_file_info_get_icon(btn->fi), PANEL_ICON_SIZE);
+        pix = fm_pixbuf_from_icon(launch_button_get_icon(btn), PANEL_ICON_SIZE);
         gtk_list_store_set(list, &it,
             COL_ICON, pix,
-            COL_TITLE, fm_file_info_get_disp_name(btn->fi),
+            COL_TITLE, launch_button_get_disp_name(btn),
             COL_BTN, btn,
             -1);
         g_object_unref(pix);
-        path = fm_path_to_str(sel_path);
-        /* g_debug("*** path '%s'",path); */
-        btn->settings = config_group_add_subgroup(ltbp->settings, "Button");
-        config_group_set_string(btn->settings, "id", path);
-        g_free(path);
+        settings = config_group_add_subgroup(ltbp->settings, "Button");
+        if (fm_path_equal(fm_path_get_scheme_path(sel_path), fm_path_get_apps_menu()))
+            config_group_set_string(settings, "id", fm_path_get_basename(sel_path));
+        else
+        {
+            path = fm_path_to_str(sel_path);
+            /* g_debug("*** path '%s'",path); */
+            config_group_set_string(settings, "id", path);
+            g_free(path);
+        }
+        launch_button_set_settings(btn, settings);
+        lxpanel_config_save(ltbp->panel);
         fm_path_unref(sel_path);
+        launchbar_remove_bootstrap(ltbp);
     }
 }
 
@@ -955,13 +1272,9 @@ static void launchbar_configure_add_button(GtkButton * widget, LaunchTaskBarPlug
 
 static void  launchbar_remove_button(LaunchTaskBarPlugin *ltbp, LaunchButton *btn)
 {
-    ltbp->buttons = g_slist_remove(ltbp->buttons, btn);
-    gtk_widget_destroy(btn->widget);
-    config_setting_destroy(btn->settings);
-    launchbutton_free(btn);
-    /* Put the bootstrap button back if the list becomes empty. */
-    if(ltbp->buttons == NULL)
-        launchbutton_build_bootstrap(ltbp);
+    config_setting_destroy(launch_button_get_settings(btn));
+    lxpanel_config_save(ltbp->panel);
+    gtk_widget_destroy(GTK_WIDGET(btn));
 }
 
 /* Handler for "clicked" action on launchtaskbar configuration dialog "Remove" button. */
@@ -981,6 +1294,7 @@ static void launchbar_configure_remove_button(GtkButton * widget, LaunchTaskBarP
         gtk_widget_set_visible(ltbp->p_label_def_app_exec, FALSE);
 
         launchbar_remove_button(ltbp, btn);
+        launchbar_check_bootstrap(ltbp);
     }
 }
 
@@ -1004,14 +1318,12 @@ static void launchbar_configure_move_up_button(GtkButton * widget, LaunchTaskBar
                 /* We have found a selected button that can be moved.
                  * Reorder it in the icon grid, the data structure, and the view. */
                 int i = gtk_tree_path_get_indices(path)[0];
-                ltbp->buttons = g_slist_remove(ltbp->buttons, btn);
-                ltbp->buttons = g_slist_insert(ltbp->buttons, btn, i);
+                config_setting_t *settings = launch_button_get_settings(btn);
                 gtk_list_store_move_before(GTK_LIST_STORE(list), &it, &it2);
                 panel_icon_grid_reorder_child(PANEL_ICON_GRID(ltbp->lb_icon_grid),
-                                              btn->widget, i);
-                config_setting_move_elem(btn->settings,
-                                         config_setting_get_parent(btn->settings),
-                                         i);
+                                              GTK_WIDGET(btn), i);
+                config_setting_move_elem(settings,
+                                         config_setting_get_parent(settings), i);
             }
         }
         gtk_tree_path_free(path);
@@ -1039,14 +1351,12 @@ static void launchbar_configure_move_down_button(GtkButton * widget, LaunchTaskB
                 /* We have found a selected button that can be moved.
                  * Reorder it in the icon grid, the data structure, and the view. */
                 int i = gtk_tree_path_get_indices(path)[0];
-                ltbp->buttons = g_slist_remove(ltbp->buttons, btn);
-                ltbp->buttons = g_slist_insert(ltbp->buttons, btn, i + 1);
+                config_setting_t *settings = launch_button_get_settings(btn);
                 gtk_list_store_move_after(GTK_LIST_STORE(list), &it, &it2);
                 panel_icon_grid_reorder_child(PANEL_ICON_GRID(ltbp->lb_icon_grid),
-                                              btn->widget, i);
-                config_setting_move_elem(btn->settings,
-                                         config_setting_get_parent(btn->settings),
-                                         i);
+                                              GTK_WIDGET(btn), i);
+                config_setting_move_elem(settings,
+                                         config_setting_get_parent(settings), i);
             }
         }
         gtk_tree_path_free(path);
@@ -1076,21 +1386,25 @@ static void launchbar_configure_initialize_list(LaunchTaskBarPlugin *ltbp, GtkWi
     GtkListStore* list = GTK_LIST_STORE(gtk_tree_view_get_model(view));
 
     /* Initialize from defined launchtaskbar buttons. */
-    GSList* l;
-    for (l = ltbp->buttons; l != NULL; l = l->next)
+    GList *children = gtk_container_get_children(GTK_CONTAINER(ltbp->lb_icon_grid));
+    GList *l;
+    for (l = children; l != NULL; l = l->next)
     {
         LaunchButton * btn = (LaunchButton *) l->data;
         GdkPixbuf * pix;
         GtkTreeIter it;
+        if (launch_button_get_settings(btn) == NULL) /* bootstrap button */
+            continue;
         gtk_list_store_append(list, &it);
-        pix = fm_pixbuf_from_icon(fm_file_info_get_icon(btn->fi), PANEL_ICON_SIZE);
+        pix = fm_pixbuf_from_icon(launch_button_get_icon(btn), PANEL_ICON_SIZE);
         gtk_list_store_set(list, &it,
                            COL_ICON, pix,
-                           COL_TITLE, fm_file_info_get_disp_name(btn->fi),
+                           COL_TITLE, launch_button_get_disp_name(btn),
                            COL_BTN, btn,
                            -1);
         g_object_unref(pix);
     }
+    g_list_free(children);
     g_object_set_data(G_OBJECT(dlg), "defined_view", view);
 }
 
@@ -1142,7 +1456,7 @@ static void on_combobox_mode_changed(GtkComboBox *p_combobox, gpointer p_data)
     case LAUNCHBAR:
         if (ltbp->tb_icon_grid)
             gtk_widget_set_visible(ltbp->tb_icon_grid, FALSE);
-        launchtaskbar_constructor_launch(ltbp, TRUE/*build_bootstrap*/);
+        launchtaskbar_constructor_launch(ltbp);
         plugin_set_expand_status(ltbp, FALSE);
         gtk_widget_set_name(ltbp->plugin, "launchbar");
         break;
@@ -1155,7 +1469,7 @@ static void on_combobox_mode_changed(GtkComboBox *p_combobox, gpointer p_data)
     default:
         ltbp->mode = LAUNCHTASKBAR;
     case LAUNCHTASKBAR:
-        launchtaskbar_constructor_launch(ltbp, TRUE/*build_bootstrap*/);
+        launchtaskbar_constructor_launch(ltbp);
         launchtaskbar_constructor_task(ltbp);
         plugin_set_expand_status(ltbp, TRUE);
         gtk_widget_set_name(ltbp->plugin, "launchtaskbar");
@@ -1168,73 +1482,86 @@ static void on_combobox_mode_changed(GtkComboBox *p_combobox, gpointer p_data)
 static void on_checkbutton_show_tooltips_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->tooltips = gtk_toggle_button_get_active(p_togglebutton);
-    //g_print("\nltbp->tooltips upd\n");
-    config_group_set_int(ltbp->settings, "tooltips", ltbp->tooltips);
+    ltbp->flags.tooltips = gtk_toggle_button_get_active(p_togglebutton);
+    //g_print("\nltbp->flags.tooltips upd\n");
+    config_group_set_int(ltbp->settings, "tooltips", ltbp->flags.tooltips);
     taskbar_apply_configuration(ltbp);
 }
 
 static void on_checkbutton_icons_only_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->icons_only = gtk_toggle_button_get_active(p_togglebutton);
-    //g_print("\ntb->icons_only upd\n");
-    config_group_set_int(ltbp->settings, "IconsOnly", ltbp->icons_only);
+    ltbp->flags.icons_only = gtk_toggle_button_get_active(p_togglebutton);
+    //g_print("\ntb->flags.icons_only upd\n");
+    config_group_set_int(ltbp->settings, "IconsOnly", ltbp->flags.icons_only);
     taskbar_apply_configuration(ltbp);
 }
 
 static void on_checkbutton_flat_buttons_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->flat_button = gtk_toggle_button_get_active(p_togglebutton);
-    //g_print("\ntb->flat_button upd\n");
-    config_group_set_int(ltbp->settings, "FlatButton", ltbp->flat_button);
+    ltbp->flags.flat_button = gtk_toggle_button_get_active(p_togglebutton);
+    //g_print("\ntb->flags.flat_button upd\n");
+    config_group_set_int(ltbp->settings, "FlatButton", ltbp->flags.flat_button);
     taskbar_apply_configuration(ltbp);
 }
 
 static void on_checkbutton_show_all_desks_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->show_all_desks = gtk_toggle_button_get_active(p_togglebutton);
-    //g_print("\ntb->show_all_desks upd\n");
-    config_group_set_int(ltbp->settings, "ShowAllDesks", ltbp->show_all_desks);
+    ltbp->flags.show_all_desks = gtk_toggle_button_get_active(p_togglebutton);
+    //g_print("\ntb->flags.show_all_desks upd\n");
+    config_group_set_int(ltbp->settings, "ShowAllDesks", ltbp->flags.show_all_desks);
     taskbar_apply_configuration(ltbp);
 }
 
 static void on_checkbutton_same_monitor_only_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->same_monitor_only = gtk_toggle_button_get_active(p_togglebutton);
-    //g_print("\ntb->same_monitor_only upd\n");
-    config_group_set_int(ltbp->settings, "SameMonitorOnly", ltbp->same_monitor_only);
+    ltbp->flags.same_monitor_only = gtk_toggle_button_get_active(p_togglebutton);
+    //g_print("\ntb->flags.same_monitor_only upd\n");
+    config_group_set_int(ltbp->settings, "SameMonitorOnly", ltbp->flags.same_monitor_only);
     taskbar_apply_configuration(ltbp);
 }
 
 static void on_checkbutton_disable_taskbar_upscale_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->disable_taskbar_upscale = gtk_toggle_button_get_active(p_togglebutton);
-    //g_print("\ntb->disable_taskbar_upscale upd\n");
-    config_group_set_int(ltbp->settings, "DisableUpscale", ltbp->disable_taskbar_upscale);
+    ltbp->flags.disable_taskbar_upscale = gtk_toggle_button_get_active(p_togglebutton);
+    //g_print("\ntb->flags.disable_taskbar_upscale upd\n");
+    config_group_set_int(ltbp->settings, "DisableUpscale", ltbp->flags.disable_taskbar_upscale);
+    taskbar_apply_configuration(ltbp);
+}
+
+static void on_checkbutton_use_smaller_icons_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
+{
+    LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
+    ltbp->flags.use_smaller_icons = gtk_toggle_button_get_active(p_togglebutton);
+    config_group_set_int(ltbp->settings, "UseSmallerIcons", ltbp->flags.use_smaller_icons);
     taskbar_apply_configuration(ltbp);
 }
 
 static void on_checkbutton_mouse_wheel_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->use_mouse_wheel = gtk_toggle_button_get_active(p_togglebutton);
-    //g_print("\ntb->use_mouse_wheel upd\n");
-    config_group_set_int(ltbp->settings, "UseMouseWheel", ltbp->use_mouse_wheel);
+    ltbp->flags.use_mouse_wheel = gtk_toggle_button_get_active(p_togglebutton);
+    //g_print("\ntb->flags.use_mouse_wheel upd\n");
+    config_group_set_int(ltbp->settings, "UseMouseWheel", ltbp->flags.use_mouse_wheel);
     taskbar_apply_configuration(ltbp);
 }
 
 static void on_checkbutton_urgency_hint_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->use_urgency_hint = gtk_toggle_button_get_active(p_togglebutton);
-    //g_print("\ntb->use_urgency_hint upd\n");
-    config_group_set_int(ltbp->settings, "UseUrgencyHint", ltbp->use_urgency_hint);
+    ltbp->flags.use_urgency_hint = gtk_toggle_button_get_active(p_togglebutton);
+    //g_print("\ntb->flags.use_urgency_hint upd\n");
+    config_group_set_int(ltbp->settings, "UseUrgencyHint", ltbp->flags.use_urgency_hint);
     taskbar_apply_configuration(ltbp);
+    /* Start/stop blinking timeout if configured */
+    if (ltbp->flags.use_urgency_hint)
+        set_timer_on_task(ltbp);
+    else
+        reset_timer_on_task(ltbp);
 }
 
 static void on_checkbutton_grouped_tasks_toggled(GtkToggleButton *p_togglebutton, gpointer p_data)
@@ -1244,18 +1571,66 @@ static void on_checkbutton_grouped_tasks_toggled(GtkToggleButton *p_togglebutton
     //g_print("\ntb->grouped_tasks upd\n");
     config_group_set_int(ltbp->settings, "GroupedTasks", ltbp->grouped_tasks);
     taskbar_apply_configuration(ltbp);
-}
-
-static void on_spinbutton_max_width_value_changed(GtkSpinButton *p_spinbutton, gpointer p_data)
-{
-    LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
-    ltbp->task_width_max = gtk_spin_button_get_value(p_spinbutton);
-    //g_print("\ntb->task_width_max upd\n");
-    config_group_set_int(ltbp->settings, "MaxTaskWidth", ltbp->task_width_max);
-    taskbar_apply_configuration(ltbp);
-}
+    if (ltbp->grouped_tasks)
+    {
+        gboolean changed = FALSE;
+        GList *children, *this, *l;
+        int i = 0;
 
-static void on_spinbutton_spacing_value_changed(GtkSpinButton *p_spinbutton, gpointer p_data)
+        children = gtk_container_get_children(GTK_CONTAINER(ltbp->tb_icon_grid));
+        /* merge buttons with the same class into first of that class */
+        while ((this = g_list_nth(children, i++)))
+        {
+            for (l = this->next; l; l = l->next)
+                if (task_button_merge(this->data, l->data))
+                    changed = TRUE;
+            if (changed)
+            {
+                /* some button was consumed, need to reload buttons list */
+                g_list_free(children);
+                children = gtk_container_get_children(GTK_CONTAINER(ltbp->tb_icon_grid));
+                changed = FALSE;
+            }
+        }
+        g_list_free(children);
+    }
+    else
+    {
+        TaskButton *old_btn, *new_btn;
+        GList *children, *this;
+        int i;
+
+        children = gtk_container_get_children(GTK_CONTAINER(ltbp->tb_icon_grid));
+        /* split each button starting from last one */
+        for (this = g_list_last(children); this; this = this->prev)
+        {
+            old_btn = this->data;
+            i = panel_icon_grid_get_child_position(PANEL_ICON_GRID(ltbp->tb_icon_grid),
+                                                   GTK_WIDGET(old_btn));
+            while ((new_btn = task_button_split(old_btn)))
+            {
+                /* insert rest before old_btn */
+                taskbar_add_task_button(ltbp, new_btn);
+                panel_icon_grid_reorder_child(PANEL_ICON_GRID(ltbp->tb_icon_grid),
+                                              GTK_WIDGET(new_btn), i);
+                /* continue split with the rest */
+                old_btn = new_btn;
+            }
+        }
+        g_list_free(children);
+    }
+}
+
+static void on_spinbutton_max_width_value_changed(GtkSpinButton *p_spinbutton, gpointer p_data)
+{
+    LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
+    ltbp->task_width_max = gtk_spin_button_get_value(p_spinbutton);
+    //g_print("\ntb->task_width_max upd\n");
+    config_group_set_int(ltbp->settings, "MaxTaskWidth", ltbp->task_width_max);
+    taskbar_apply_configuration(ltbp);
+}
+
+static void on_spinbutton_spacing_value_changed(GtkSpinButton *p_spinbutton, gpointer p_data)
 {
     LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)p_data;
     ltbp->spacing = gtk_spin_button_get_value(p_spinbutton);
@@ -1289,11 +1664,12 @@ static void on_defined_view_cursor_changed(GtkTreeView *p_treeview, gpointer p_d
                                        &tree_iter_sel))
     {
         LaunchButton * p_btn;
+        FmFileInfo *fi;
         gtk_tree_model_get(p_treemodel, &tree_iter_sel, COL_BTN, &p_btn, -1);
-        if( (p_btn != NULL) && (p_btn->fi != NULL) )
+        if ((p_btn != NULL) && ((fi = launch_button_get_file_info(p_btn)) != NULL))
         {
             GString *p_gstring = g_string_new("");
-            g_string_printf(p_gstring, "<i>%s</i>", fm_file_info_get_disp_name(p_btn->fi));
+            g_string_printf(p_gstring, "<i>%s</i>", fm_file_info_get_disp_name(fi));
             gtk_label_set_markup(GTK_LABEL(lb->p_label_def_app_exec), p_gstring->str);
             g_string_free(p_gstring, TRUE/*free also gstring->str*/);
             label_set = TRUE;
@@ -1391,7 +1767,7 @@ static GtkWidget *launchtaskbar_configure(LXPanel *panel, GtkWidget *p)
 
 #define SETUP_TOGGLE_BUTTON(button,member) \
         object = gtk_builder_get_object(builder, #button); \
-        gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(object), ltbp->member); \
+        gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(object), ltbp->flags.member); \
         g_signal_connect(object, "toggled", G_CALLBACK(on_##button##_toggled), ltbp)
 
         SETUP_TOGGLE_BUTTON(checkbutton_show_tooltips, tooltips);
@@ -1401,15 +1777,18 @@ static GtkWidget *launchtaskbar_configure(LXPanel *panel, GtkWidget *p)
         SETUP_TOGGLE_BUTTON(checkbutton_same_monitor_only, same_monitor_only);
         SETUP_TOGGLE_BUTTON(checkbutton_mouse_wheel, use_mouse_wheel);
         SETUP_TOGGLE_BUTTON(checkbutton_urgency_hint, use_urgency_hint);
-        SETUP_TOGGLE_BUTTON(checkbutton_grouped_tasks, grouped_tasks);
-        //SETUP_TOGGLE_BUTTON(checkbutton_disable_taskbar_upscale, disable_taskbar_upscale);
+        SETUP_TOGGLE_BUTTON(checkbutton_disable_taskbar_upscale, disable_taskbar_upscale);
+        //SETUP_TOGGLE_BUTTON(checkbutton_use_smaller_icons, use_smaller_icons);
 #undef SETUP_TOGGLE_BUTTON
+        object = gtk_builder_get_object(builder, "checkbutton_grouped_tasks");
+        gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(object), ltbp->grouped_tasks);
+        g_signal_connect(object, "toggled", G_CALLBACK(on_checkbutton_grouped_tasks_toggled), ltbp);
         /* FIXME: for transitional period, turn into SETUP_TOGGLE_BUTTON later */
-        object = gtk_builder_get_object(builder, "checkbutton_disable_taskbar_upscale");
+        object = gtk_builder_get_object(builder, "checkbutton_use_smaller_icons");
         if (object)
         {
-            gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(object), ltbp->disable_taskbar_upscale); \
-            g_signal_connect(object, "toggled", G_CALLBACK(on_checkbutton_disable_taskbar_upscale_toggled), ltbp);
+            gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(object), ltbp->flags.use_smaller_icons);
+            g_signal_connect(object, "toggled", G_CALLBACK(on_checkbutton_use_smaller_icons_toggled), ltbp);
         }
 
 #define SETUP_SPIN_BUTTON(button,member) \
@@ -1456,198 +1835,67 @@ static void launchtaskbar_panel_configuration_changed(LXPanel *panel, GtkWidget
     /* Set orientation into the icon grid. */
     LaunchTaskBarPlugin *ltbp = lxpanel_plugin_get_data(p);
     int new_icon_size = panel_get_icon_size(panel);
+    int height = panel_get_height(panel);
 
     if (ltbp->lb_built)
         panel_icon_grid_set_geometry(PANEL_ICON_GRID(ltbp->lb_icon_grid),
                                      panel_get_orientation(panel),
-                                     new_icon_size, new_icon_size, 3, 0,
-                                     panel_get_height(panel));
-
-    /* If the icon size changed, refetch all the icons. */
-    if (new_icon_size != ltbp->icon_size)
-    {
-        Task * tk;
-        ltbp->icon_size = new_icon_size;
-        for (tk = ltbp->p_task_list; tk != NULL; tk = tk->p_task_flink_xwid)
-        {
-            GdkPixbuf * pixbuf = task_update_icon(ltbp, tk, None);
-            if (pixbuf != NULL)
-            {
-                gtk_image_set_from_pixbuf(GTK_IMAGE(tk->image), pixbuf);
-                g_object_unref(pixbuf);
-            }
-        }
-    }
+                                     new_icon_size, new_icon_size,
+                                     3, 0, height);
 
     /* Redraw all the labels.  Icon size or font color may have changed. */
     if (ltbp->tb_built)
     {
-        taskbar_update_style(ltbp);
-        taskbar_make_menu(ltbp);
+        ltbp->icon_size = new_icon_size;
+        panel_icon_grid_set_geometry(PANEL_ICON_GRID(ltbp->tb_icon_grid),
+            panel_get_orientation(panel),
+            ((ltbp->flags.icons_only) ? ltbp->icon_size + ICON_ONLY_EXTRA : ltbp->task_width_max),
+            ((ltbp->flags.icons_only) ? ltbp->icon_size + ICON_ONLY_EXTRA : ltbp->icon_size + ICON_BUTTON_TRIM),
+            ltbp->spacing, 0, height);
+        taskbar_reset_menu(ltbp);
         taskbar_redraw(ltbp);
     }
 }
 
-/* Set an urgency timer on a task. */
-static void set_timer_on_task(Task * tk)
-{
-    gint interval;
-    g_return_if_fail(tk->flash_timeout == 0);
-    g_object_get(gtk_widget_get_settings(tk->button), "gtk-cursor-blink-time", &interval, NULL);
-    tk->flash_timeout = g_timeout_add(interval / 2, flash_window_timeout, tk);
-}
-
-/* Determine if a task is visible considering only its desktop placement. */
-static gboolean task_is_visible_on_current_desktop(LaunchTaskBarPlugin * tb, Task * tk)
+static gboolean launchtaskbar_control(GtkWidget *p, const char *cmd)
 {
-    return ((tk->desktop == ALL_WORKSPACES) || (tk->desktop == tb->current_desktop) || (tb->show_all_desks) || (tk->urgency));
-}
+    LaunchTaskBarPlugin *ltbp = lxpanel_plugin_get_data(p);
 
-/* Recompute the visible task for a class when the class membership changes.
- * Also transfer the urgency state to the visible task if necessary. */
-static void recompute_group_visibility_for_class(LaunchTaskBarPlugin * tb, TaskClass * tc)
-{
-    tc->visible_count = 0;
-    tc->p_task_visible = NULL;
-    tc->visible_name = NULL;
-    Task * flashing_task = NULL;
-    gboolean class_has_urgency = FALSE;
-    Task * tk;
-    for (tk = tc->p_task_head; tk != NULL; tk = tk->p_task_flink_same_class)
+    if (ltbp->mode == LAUNCHBAR || ltbp->mode == LAUNCHTASKBAR)
     {
-        if (task_is_visible_on_current_desktop(tb, tk))
+        if (strncmp(cmd, "add ", 4) == 0)
         {
-            /* Count visible tasks and make the first visible task the one that is used for display. */
-            if (tc->visible_count == 0)
-                tc->p_task_visible = tk;
-            tc->visible_count += 1;
-
-            /* Compute summary bit for urgency anywhere in the class. */
-            if (tk->urgency && !tk->focused)
-                class_has_urgency = TRUE;
-
-            /* If there is urgency, record the currently flashing task. */
-            if (tk->flash_timeout != 0)
-                flashing_task = tk;
-
-            /* Compute the visible name.  If all visible windows have the same title, use that.
-             * Otherwise, use the class name.  This follows WNCK.
-             * Note that the visible name is not a separate string, but is set to point to one of the others. */
-            if (tc->visible_name == NULL)
-                tc->visible_name = tk->name;
-            else if ((tc->visible_name != tc->res_class)
-            && (tc->visible_name != NULL) && (tk->name != NULL)
-            && (strcmp(tc->visible_name, tk->name) != 0))
-                tc->visible_name = tc->res_class;
-        }
-    }
+            config_setting_t *s;
 
-    /* Transfer the flash timeout to the visible task. */
-    if (class_has_urgency)
-    {
-        if (flashing_task == NULL)
-        {
-            /* Set the flashing context and flash the window immediately. */
-            tc->p_task_visible->flash_state = TRUE;
-            flash_window_update(tc->p_task_visible);
-        }
-        else if (flashing_task != tc->p_task_visible)
-        {
-            /* Reset the timer on the new representative.
-             * There will be a slight hiccup on the flash cadence. */
-            g_source_remove(flashing_task->flash_timeout);
-            flashing_task->flash_timeout = 0;
-            tc->p_task_visible->flash_state = flashing_task->flash_state;
-            flashing_task->flash_state = FALSE;
-            if (tc->p_task_visible->menu_item != NULL)
-                g_object_unref(tc->p_task_visible->menu_item);
-            tc->p_task_visible->menu_item = flashing_task->menu_item;
-            flashing_task->menu_item = NULL;
-        }
-        if (tc->p_task_visible->flash_timeout == 0)
-            set_timer_on_task(tc->p_task_visible);
-    }
-    else
-    {
-        /* No task has urgency.  Cancel the timer if one is set. */
-        if (flashing_task != NULL)
-        {
-            g_source_remove(flashing_task->flash_timeout);
-            flashing_task->flash_state = FALSE;
-            flashing_task->flash_timeout = 0;
+            s = config_group_add_subgroup(ltbp->settings, "Button");
+            config_group_set_string(s, "id", &cmd[4]);
+            if (launchbutton_constructor(ltbp, s))
+            {
+                launchbar_remove_bootstrap(ltbp);
+                lxpanel_config_save(ltbp->panel);
+                return TRUE;
+            }
+            else
+                config_setting_destroy(s);
         }
     }
-}
-
-/* Recompute the visible task for all classes when the desktop changes. */
-static void recompute_group_visibility_on_current_desktop(LaunchTaskBarPlugin * tb)
-{
-    TaskClass * tc;
-    for (tc = tb->p_taskclass_list; tc != NULL; tc = tc->p_taskclass_flink)
-    {
-        recompute_group_visibility_for_class(tb, tc);
-    }
-}
-
-/* Draw the label and tooltip on a taskbar button. */
-static void task_draw_label(Task * tk)
-{
-    TaskClass * tc = tk->p_taskclass;
-    gboolean bold_style = (((tk->entered_state) || (tk->flash_state)) && (tk->tb->flat_button));
-    char *label;
-
-    if ((tk->tb->grouped_tasks) && (tc != NULL) && (tc->p_task_visible == tk) && (tc->visible_count > 1))
-    {
-        label = g_strdup_printf("(%d) %s", tc->visible_count, tc->visible_name);
-    }
-    else
-    {
-        label = g_strdup(tk->iconified ? tk->name_iconified : tk->name);
-    }
-
-    if (tk->tb->tooltips)
-        gtk_widget_set_tooltip_text(tk->button, label);
-
-    lxpanel_draw_label_text(tk->tb->panel, tk->label, label, bold_style, 1,
-            tk->tb->flat_button);
-
-    g_free(label);
-}
-
-/* Determine if a task is visible. */
-static gboolean task_is_visible(LaunchTaskBarPlugin * tb, Task * tk)
-{
-    /* Not visible due to grouping. */
-    if ((tb->grouped_tasks) && (tk->p_taskclass != NULL) && (tk->p_taskclass->p_task_visible != tk))
-        return FALSE;
-
-    /* Not on same monitor */
-    if (tb->same_monitor_only && panel_get_monitor(tb->panel) != tk->monitor
-        && panel_get_monitor(tb->panel) >= 0)
-        return FALSE;
-
-    /* Desktop placement. */
-    return task_is_visible_on_current_desktop(tb, tk);
-}
-
-/* Redraw a task button. */
-static void task_button_redraw(Task * tk, LaunchTaskBarPlugin * tb)
-{
-    if (task_is_visible(tb, tk))
-    {
-        task_draw_label(tk);
-        gtk_widget_set_visible(tk->button, TRUE);
-    }
-    else
-        gtk_widget_set_visible(tk->button, FALSE);
+    return FALSE;
 }
 
 /* Redraw all tasks in the taskbar. */
 static void taskbar_redraw(LaunchTaskBarPlugin * tb)
 {
-    Task * tk;
-    for (tk = tb->p_task_list; tk != NULL; tk = tk->p_task_flink_xwid)
-        task_button_redraw(tk, tb);
+    GList *children = gtk_container_get_children(GTK_CONTAINER(tb->tb_icon_grid));
+    GList *l;
+    guint mon = panel_get_monitor(tb->panel);
+    guint icon_size = panel_get_icon_size(tb->panel);
+
+    if (tb->flags.use_smaller_icons)
+        icon_size -= 4;
+    for (l = children; l; l = l->next)
+        task_button_update(l->data, tb->current_desktop, tb->number_of_desktops,
+                           mon, icon_size, tb->flags);
+    g_list_free(children);
 }
 
 /* Determine if a task should be visible given its NET_WM_STATE. */
@@ -1662,149 +1910,15 @@ static gboolean accept_net_wm_window_type(NetWMWindowType * nwwt)
     return ( ! ((nwwt->desktop) || (nwwt->dock) || (nwwt->splash)));
 }
 
-/* Free the names associated with a task. */
-static void task_free_names(Task * tk)
-{
-    TaskClass * tc = tk->p_taskclass;
-
-    if (tc != NULL && tk->name != NULL)
-        /* Reset the name from class */
-        if (tc->visible_name == tk->name)
-            tc->visible_name = tc->res_class;
-    g_free(tk->name);
-    g_free(tk->name_iconified);
-    tk->name = tk->name_iconified = NULL;
-}
-
-/* Set the names associated with a task.
- * This is expected to be the same as the title the window manager is displaying. */
-static void task_set_names(Task * tk, Atom source)
-{
-    char * name = NULL;
-
-    /* Try _NET_WM_VISIBLE_NAME, which supports UTF-8.
-     * If it is set, the window manager is displaying it as the window title. */
-    if ((source == None) || (source == a_NET_WM_VISIBLE_NAME))
-    {
-        name = get_utf8_property(tk->win,  a_NET_WM_VISIBLE_NAME);
-        if (name != NULL)
-            tk->name_source = a_NET_WM_VISIBLE_NAME;
-    }
-
-    /* Try _NET_WM_NAME, which supports UTF-8, but do not overwrite _NET_WM_VISIBLE_NAME. */
-    if ((name == NULL)
-    && ((source == None) || (source == a_NET_WM_NAME))
-    && ((tk->name_source == None) || (tk->name_source == a_NET_WM_NAME) || (tk->name_source == XA_WM_NAME)))
-    {
-        name = get_utf8_property(tk->win,  a_NET_WM_NAME);
-        if (name != NULL)
-            tk->name_source = a_NET_WM_NAME;
-    }
-
-    /* Try WM_NAME, which supports only ISO-8859-1, but do not overwrite _NET_WM_VISIBLE_NAME or _NET_WM_NAME. */
-    if ((name == NULL)
-    && ((source == None) || (source == XA_WM_NAME))
-    && ((tk->name_source == None) || (tk->name_source == XA_WM_NAME)))
-    {
-        name = get_textproperty(tk->win,  XA_WM_NAME);
-        if (name != NULL)
-            tk->name_source = XA_WM_NAME;
-    }
-
-    /* Set the name into the task context, and also on the tooltip. */
-    if (name != NULL)
-    {
-        task_free_names(tk);
-        tk->name = name;
-        tk->name_iconified = g_strdup_printf("[%s]", name);
-
-        /* Redraw the button. */
-        task_button_redraw(tk, tk->tb);
-    }
-}
-
-/* Unlink a task from the class list because its class changed or it was deleted. */
-static void task_unlink_class(Task * tk)
-{
-    TaskClass * tc = tk->p_taskclass;
-    if (tc != NULL)
-    {
-        /* Reset the name from class */
-        if (tc->visible_name == tk->name)
-            tc->visible_name = tc->res_class;
-
-        /* Action in Launchbar after class removed */
-        launchbar_update_after_taskbar_class_removed(tk->tb, tk);
-
-        /* Remove from per-class task list. */
-        if (tc->p_task_head == tk)
-        {
-            /* Removing the head of the list.  This causes a new task to be the visible task, so we redraw. */
-            tc->p_task_head = tk->p_task_flink_same_class;
-            if (tc->p_task_head != NULL)
-                task_button_redraw(tc->p_task_head, tk->tb);
-        }
-        else
-        {
-            /* Locate the task and its predecessor in the list and then remove it.  For safety, ensure it is found. */
-            Task * tk_pred = NULL;
-            Task * tk_cursor;
-            for (
-              tk_cursor = tc->p_task_head;
-              ((tk_cursor != NULL) && (tk_cursor != tk));
-              tk_pred = tk_cursor, tk_cursor = tk_cursor->p_task_flink_same_class) ;
-            if (tk_cursor == tk)
-                tk_pred->p_task_flink_same_class = tk->p_task_flink_same_class;
-        }
-        tk->p_task_flink_same_class = NULL;
-        tk->p_taskclass = NULL;
-
-        /* Recompute group visibility. */
-        recompute_group_visibility_for_class(tk->tb, tc);
-    }
-}
-
-/* Enter class with specified name. */
-static TaskClass * taskbar_enter_res_class(LaunchTaskBarPlugin * tb, char * res_class, gboolean * p_name_consumed)
-{
-    /* Find existing entry or insertion point. */
-    *p_name_consumed = FALSE;
-    TaskClass * tc_pred = NULL;
-    TaskClass * tc;
-    for (tc = tb->p_taskclass_list; tc != NULL; tc_pred = tc, tc = tc->p_taskclass_flink)
-    {
-        int status = strcmp(res_class, tc->res_class);
-        if (status == 0)
-            return tc;
-        if (status < 0)
-            break;
-    }
-
-    /* Insert new entry. */
-    tc = g_new0(TaskClass, 1);
-    tc->res_class = res_class;
-    *p_name_consumed = TRUE;
-    if (tc_pred == NULL)
-    {
-        tc->p_taskclass_flink = tb->p_taskclass_list;
-        tb->p_taskclass_list = tc;
-    }
-    else
-    {
-        tc->p_taskclass_flink = tc_pred->p_taskclass_flink;
-        tc_pred->p_taskclass_flink = tc;
-    }
-    return tc;
-}
-
 /* Set the class associated with a task. */
-static void task_set_class(Task * tk)
+static char *task_get_class(Window win)
 {
     /* Read the WM_CLASS property. */
     XClassHint ch;
     ch.res_name = NULL;
     ch.res_class = NULL;
-    XGetClassHint(GDK_DISPLAY_XDISPLAY(gdk_display_get_default()), tk->win, &ch);
+    char *res_class = NULL;
+    XGetClassHint(GDK_DISPLAY_XDISPLAY(gdk_display_get_default()), win, &ch);
 
     /* If the res_name was returned, free it.  We make no use of it at this time. */
     if (ch.res_name != NULL)
@@ -1817,973 +1931,183 @@ static void task_set_class(Task * tk)
     if (ch.res_class != NULL)
     {
         /* Convert the class to UTF-8 and enter it in the class table. */
-        gchar * res_class = g_locale_to_utf8(ch.res_class, -1, NULL, NULL, NULL);
-        if (res_class != NULL)
-        {
-            gboolean name_consumed;
-            TaskClass * tc = taskbar_enter_res_class(tk->tb, res_class, &name_consumed);
-            if ( ! name_consumed) g_free(res_class);
-
-            /* If the task changed class, update data structures. */
-            TaskClass * old_tc = tk->p_taskclass;
-            if (old_tc != tc)
-            {
-                /* Unlink from previous class, if any. */
-                task_unlink_class(tk);
-
-                /* Add to end of per-class task list.  Do this to keep the popup menu in order of creation. */
-                if (tc->p_task_head == NULL)
-                    tc->p_task_head = tk;
-                else
-                {
-                    Task * tk_pred;
-                    for (tk_pred = tc->p_task_head; tk_pred->p_task_flink_same_class != NULL; tk_pred = tk_pred->p_task_flink_same_class) ;
-                    tk_pred->p_task_flink_same_class = tk;
-                    task_button_redraw(tk, tk->tb);
-                }
-                tk->p_taskclass = tc;
-
-                /* Recompute group visibility. */
-                recompute_group_visibility_for_class(tk->tb, tc);
-
-                /* Action in Launchbar after class added */
-                launchbar_update_after_taskbar_class_added(tk->tb, tk);
-            }
-        }
+        res_class = g_locale_to_utf8(ch.res_class, -1, NULL, NULL, NULL);
         XFree(ch.res_class);
     }
+    return res_class;
 }
 
 /* Look up a task in the task list. */
-static Task * task_lookup(LaunchTaskBarPlugin * tb, Window win)
+static TaskButton *task_lookup(LaunchTaskBarPlugin * tb, Window win)
 {
-    Task * tk;
-    for (tk = tb->p_task_list; tk != NULL; tk = tk->p_task_flink_xwid)
+    TaskButton *task = NULL;
+    GList *children = gtk_container_get_children(GTK_CONTAINER(tb->tb_icon_grid));
+    GList *l;
+
+    for (l = children; l; l = l->next)
+        if (task_button_has_window(l->data, win))
         {
-        if (tk->win == win)
-        return tk;
-        if (tk->win > win)
+            task = l->data;
             break;
         }
-    return NULL;
+    g_list_free(children);
+    return task;
 }
 
-/* Delete a task and optionally unlink it from the task list. */
-static void task_delete(LaunchTaskBarPlugin * tb, Task * tk, gboolean unlink, gboolean remove)
-{
-    /* If we think this task had focus, remove that. */
-    if (tb->focused == tk)
-        tb->focused = NULL;
 
-    if (tb->menutask == tk)
-        tb->menutask = NULL;
+#ifndef DISABLE_MENU
+static void  on_menuitem_lock_tbp_clicked(GtkWidget * widget, LaunchTaskBarPlugin * tb);
+static void  on_menuitem_unlock_tbp_clicked(GtkWidget * widget, LaunchTaskBarPlugin * tb);
+static void  on_menuitem_new_instance_clicked(GtkWidget * widget, LaunchTaskBarPlugin * tb);
+#endif
 
-    /* If there is an urgency timeout, remove it. */
-    if (tk->flash_timeout != 0) {
-        g_source_remove(tk->flash_timeout);
-        tk->flash_timeout = 0;
-    }
+static void on_task_menu_built(GtkWidget *unused, GtkMenu *menu, LaunchTaskBarPlugin *tb)
+{
+#ifndef DISABLE_MENU
+    /* add callbacks for task-to-launcher items with weak pointers */
+    void (*_m_add)(GtkMenuShell *self, GtkWidget* child);
 
-    if (tk->menu_item)
-    {
-        g_object_unref(tk->menu_item);
-        tk->menu_item = NULL;
-    }
+    if (panel_is_at_bottom(tb->panel))
+        _m_add = gtk_menu_shell_append;
+    else
+        _m_add = gtk_menu_shell_prepend;
 
-    /* Deallocate structures. */
-    if (remove)
-    {
-        g_signal_handlers_disconnect_by_func(tk->button, taskbar_button_enter, tk);
-        g_signal_handlers_disconnect_by_func(tk->button, taskbar_button_leave, tk);
-        gtk_widget_destroy(tk->button);
-        task_unlink_class(tk);
-    }
-    task_free_names(tk);
-    g_free(tk->exec_bin);
+    tb->p_menuitem_lock_tbp = gtk_menu_item_new_with_mnemonic(_("A_dd to Launcher"));
+    g_object_add_weak_pointer(G_OBJECT(menu), (void **)&tb->p_menuitem_lock_tbp);
+    tb->p_menuitem_unlock_tbp = gtk_menu_item_new_with_mnemonic(_("Rem_ove from Launcher"));
+    g_object_add_weak_pointer(G_OBJECT(menu), (void **)&tb->p_menuitem_lock_tbp);
+    tb->p_menuitem_new_instance = gtk_menu_item_new_with_mnemonic(_("_New Instance"));
+    g_object_add_weak_pointer(G_OBJECT(menu), (void **)&tb->p_menuitem_lock_tbp);
+    tb->p_menuitem_separator = gtk_separator_menu_item_new();
+    _m_add(GTK_MENU_SHELL(menu), tb->p_menuitem_separator);
+    _m_add(GTK_MENU_SHELL(menu), tb->p_menuitem_lock_tbp);
+    _m_add(GTK_MENU_SHELL(menu), tb->p_menuitem_unlock_tbp);
+    _m_add(GTK_MENU_SHELL(menu), tb->p_menuitem_new_instance);
+    g_signal_connect(G_OBJECT(tb->p_menuitem_lock_tbp), "activate", (GCallback)on_menuitem_lock_tbp_clicked, tb);
+    g_signal_connect(G_OBJECT(tb->p_menuitem_unlock_tbp), "activate", (GCallback)on_menuitem_unlock_tbp_clicked, tb);
+    g_signal_connect(G_OBJECT(tb->p_menuitem_new_instance), "activate", (GCallback)on_menuitem_new_instance_clicked, tb);
+#endif
+}
 
-    /* If requested, unlink the task from the task list.
-     * If not requested, the caller will do this. */
-    if (unlink)
-    {
-        if (tb->p_task_list == tk)
-            tb->p_task_list = tk->p_task_flink_xwid;
-        else
-        {
-            /* Locate the task and its predecessor in the list and then remove it.  For safety, ensure it is found. */
-            Task * tk_pred = NULL;
-            Task * tk_cursor;
-            for (
-              tk_cursor = tb->p_task_list;
-              ((tk_cursor != NULL) && (tk_cursor != tk));
-              tk_pred = tk_cursor, tk_cursor = tk_cursor->p_task_flink_xwid) ;
-            if (tk_cursor == tk)
-                tk_pred->p_task_flink_xwid = tk->p_task_flink_xwid;
-        }
-    }
+static void on_task_menu_target_set(TaskButton *btn, gulong win, LaunchTaskBarPlugin *ltbp)
+{
+#ifndef DISABLE_MENU
+            if(ltbp->mode == LAUNCHTASKBAR)
+            {
+                FmPath *path = f_find_menu_launchbutton_recursive(win, ltbp);
+                LaunchButton *btn = launchbar_exec_bin_exists(ltbp, path);
+                /* FIXME: shouldn't we make file info at task button creation? */
+#ifdef DEBUG
+                g_print("\nTB '%s' right-click, in LB: %c\n", tk->exec_bin, btn != NULL ? 'Y':'N');
+#endif
+                if(btn != NULL)
+                {
+                    gtk_widget_set_visible(ltbp->p_menuitem_lock_tbp, FALSE);
+                    gtk_widget_set_visible(ltbp->p_menuitem_unlock_tbp, TRUE);
+                    gtk_widget_set_visible(ltbp->p_menuitem_new_instance, TRUE);
+                }
+                else
+                {
+                    gtk_widget_set_visible(ltbp->p_menuitem_lock_tbp, path != NULL);
+                    gtk_widget_set_visible(ltbp->p_menuitem_unlock_tbp, FALSE);
+                    gtk_widget_set_visible(ltbp->p_menuitem_new_instance, path != NULL);
+                }
+                gtk_widget_set_visible(ltbp->p_menuitem_separator, TRUE);
+                if (ltbp->path)
+                    fm_path_unref(ltbp->path);
+                ltbp->path = path;
+            }
+            else
+            {
+                gtk_widget_set_visible(ltbp->p_menuitem_lock_tbp, FALSE);
+                gtk_widget_set_visible(ltbp->p_menuitem_unlock_tbp, FALSE);
+                gtk_widget_set_visible(ltbp->p_menuitem_new_instance, FALSE);
+                gtk_widget_set_visible(ltbp->p_menuitem_separator, FALSE);
+            }
+#endif
+}
 
-    /* Deallocate the task structure. */
-    g_free(tk);
+/* Handler for "drag-motion" timeout. */
+static gboolean taskbar_button_drag_motion_timeout(LaunchTaskBarPlugin * tb)
+{
+    //guint time;
+    if (g_source_is_destroyed(g_main_current_source()))
+        return FALSE;
+    //time = gtk_get_current_event_time();
+    //task_raise_window(tk, ((time != 0) ? time : CurrentTime)); // ???
+    tb->dnd_delay_timer = 0;
+    return FALSE;
 }
 
-/* Get a pixbuf from a pixmap.
- * Originally from libwnck, Copyright (C) 2001 Havoc Pennington. */
-static GdkPixbuf * _wnck_gdk_pixbuf_get_from_pixmap(GdkScreen *screen, Pixmap xpixmap, int width, int height)
+/* Handler for "drag-motion" event from taskbar button. */
+static gboolean taskbar_button_drag_motion(GtkWidget * widget, GdkDragContext * drag_context, gint x, gint y, guint time, LaunchTaskBarPlugin * tb)
 {
-    /* Get the drawable. */
-#if GTK_CHECK_VERSION(2, 24, 0)
-    GdkDrawable * drawable = gdk_x11_window_lookup_for_display(gdk_display_get_default(), xpixmap);
-#else
-    GdkDrawable * drawable = gdk_xid_table_lookup(xpixmap);
-#endif
-    if (drawable != NULL)
-        g_object_ref(G_OBJECT(drawable));
+    GtkWidget * drag_source = gtk_drag_get_source_widget(drag_context);
+    if (drag_source != NULL && gtk_widget_get_parent(drag_source) == gtk_widget_get_parent(widget))
+    {
+        tb->dnd_task_moving = TRUE;
+        gdk_drag_status(drag_context, GDK_ACTION_MOVE, time);
+    }
     else
-        drawable = gdk_pixmap_foreign_new(xpixmap);
-
-    GdkColormap * colormap = NULL;
-    GdkPixbuf * retval = NULL;
-    if (drawable != NULL)
     {
-        /* Get the colormap.
-         * If the drawable has no colormap, use no colormap or the system colormap as recommended in the documentation of gdk_drawable_get_colormap. */
-        colormap = gdk_drawable_get_colormap(drawable);
-        gint depth = gdk_drawable_get_depth(drawable);
-        if (colormap != NULL)
-            g_object_ref(G_OBJECT(colormap));
-        else if (depth == 1)
-            colormap = NULL;
-        else
-        {
-            colormap = gdk_screen_get_system_colormap(screen);
-            g_object_ref(G_OBJECT(colormap));
-        }
-
-        /* Be sure we aren't going to fail due to visual mismatch. */
-        if ((colormap != NULL) && (gdk_visual_get_depth(gdk_colormap_get_visual(colormap)) != depth))
-        {
-            g_object_unref(G_OBJECT(colormap));
-            colormap = NULL;
-        }
+        /* Prevent excessive motion notification. */
+        if (tb->dnd_delay_timer == 0)
+            tb->dnd_delay_timer = g_timeout_add(DRAG_ACTIVE_DELAY, (GSourceFunc) taskbar_button_drag_motion_timeout, tb);
 
-        /* Do the major work. */
-        retval = gdk_pixbuf_get_from_drawable(NULL, drawable, colormap, 0, 0, 0, 0, width, height);
+        gdk_drag_status(drag_context, 0, time);
     }
-
-    /* Clean up and return. */
-    if (colormap != NULL)
-        g_object_unref(G_OBJECT(colormap));
-    if (drawable != NULL)
-        g_object_unref(G_OBJECT(drawable));
-    return retval;
+    return TRUE;
 }
 
-/* Apply a mask to a pixbuf.
- * Originally from libwnck, Copyright (C) 2001 Havoc Pennington. */
-static GdkPixbuf * apply_mask(GdkPixbuf * pixbuf, GdkPixbuf * mask)
+/* Handler for "drag-drop" event from taskbar button. */
+static gboolean taskbar_button_drag_drop(GtkWidget * widget, GdkDragContext * drag_context, gint x, gint y, guint time, LaunchTaskBarPlugin * tb)
 {
-    /* Initialize. */
-    int w = MIN(gdk_pixbuf_get_width(mask), gdk_pixbuf_get_width(pixbuf));
-    int h = MIN(gdk_pixbuf_get_height(mask), gdk_pixbuf_get_height(pixbuf));
-    GdkPixbuf * with_alpha = gdk_pixbuf_add_alpha(pixbuf, FALSE, 0, 0, 0);
-    guchar * dst = gdk_pixbuf_get_pixels(with_alpha);
-    guchar * src = gdk_pixbuf_get_pixels(mask);
-    int dst_stride = gdk_pixbuf_get_rowstride(with_alpha);
-    int src_stride = gdk_pixbuf_get_rowstride(mask);
-
-    /* Loop to do the work. */
-    int i;
-    for (i = 0; i < h; i += 1)
+    tb->dnd_task_moving = FALSE;
+    GtkWidget * drag_source = gtk_drag_get_source_widget(drag_context);
+    if (drag_source != NULL && gtk_widget_get_parent(drag_source) == gtk_widget_get_parent(widget))
     {
-        int j;
-        for (j = 0; j < w; j += 1)
+        if (drag_source != widget)
         {
-            guchar * s = src + i * src_stride + j * 3;
-            guchar * d = dst + i * dst_stride + j * 4;
-
-            /* s[0] == s[1] == s[2], they are 255 if the bit was set, 0 otherwise. */
-            d[3] = ((s[0] == 0) ? 0 : 255); /* 0 = transparent, 255 = opaque */
+            PanelIconGrid *ig = PANEL_ICON_GRID(tb->tb_icon_grid);
+            gint i = panel_icon_grid_get_child_position(ig, widget);
+            panel_icon_grid_reorder_child(ig, drag_source, i);
         }
+        gtk_drag_finish(drag_context, TRUE, TRUE, time);
+        return TRUE;
     }
 
-    return with_alpha;
+    return FALSE;
 }
 
-/* Get an icon from the window manager for a task, and scale it to a specified size. */
-static GdkPixbuf * get_wm_icon(Window task_win, guint required_width,
-                               guint required_height, Atom source,
-                               Atom * current_source, LaunchTaskBarPlugin * tb)
+/* Handler for "drag-leave" event from taskbar button. */
+static void taskbar_button_drag_leave(GtkWidget * widget, GdkDragContext * drag_context, guint time, LaunchTaskBarPlugin * tb)
 {
-    /* The result. */
-    GdkPixbuf * pixmap = NULL;
-    Atom possible_source = None;
-    int result = -1;
-    Display *xdisplay = GDK_DISPLAY_XDISPLAY(gdk_display_get_default());
-    GdkScreen *screen = gtk_widget_get_screen(tb->plugin);
-
-    if ((source == None) || (source == a_NET_WM_ICON))
+    /* Cancel the timer if set. */
+    if (tb->dnd_delay_timer != 0)
     {
-        /* Important Notes:
-         * According to freedesktop.org document:
-         * http://standards.freedesktop.org/wm-spec/wm-spec-1.4.html#id2552223
-         * _NET_WM_ICON contains an array of 32-bit packed CARDINAL ARGB.
-         * However, this is incorrect. Actually it's an array of long integers.
-         * Toolkits like gtk+ use unsigned long here to store icons.
-         * Besides, according to manpage of XGetWindowProperty, when returned format,
-         * is 32, the property data will be stored as an array of longs
-         * (which in a 64-bit application will be 64-bit values that are
-         * padded in the upper 4 bytes).
-         */
-
-        /* Get the window property _NET_WM_ICON, if possible. */
-        Atom type = None;
-        int format;
-        gulong nitems;
-        gulong bytes_after;
-        gulong * data = NULL;
-        result = XGetWindowProperty(
-            xdisplay,
-            task_win,
-            a_NET_WM_ICON,
-            0, G_MAXLONG,
-            False, XA_CARDINAL,
-            &type, &format, &nitems, &bytes_after, (void *) &data);
-
-        /* Inspect the result to see if it is usable.  If not, and we got data, free it. */
-        if ((type != XA_CARDINAL) || (nitems <= 0))
-        {
-            if (data != NULL)
-                XFree(data);
-            result = -1;
-        }
+        g_source_remove(tb->dnd_delay_timer);
+        tb->dnd_delay_timer = 0;
+    }
+    return;
+}
 
-        /* If the result is usable, extract the icon from it. */
-        if (result == Success)
-        {
-            /* Get the largest icon available, unless there is one that is the desired size. */
-            /* FIXME: should we try to find an icon whose size is closest to
-             * required_width and required_height to reduce unnecessary resizing? */
-            gulong * pdata = data;
-            gulong * pdata_end = data + nitems;
-            gulong * max_icon = NULL;
-            gulong max_w = 0;
-            gulong max_h = 0;
-            while ((pdata + 2) < pdata_end)
-            {
-                /* Extract the width and height. */
-                guint w = pdata[0];
-                guint h = pdata[1];
-                gulong size = w * h;
-                pdata += 2;
-
-                /* Bounds check the icon. Also check for invalid width and height,
-                   see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=801319 */
-                if (size == 0 || w > 1024 || h > 1024 || pdata + size > pdata_end)
-                    break;
-
-                /* Rare special case: the desired size is the same as icon size. */
-                if ((required_width == w) && (required_height == h))
-                {
-                    max_icon = pdata;
-                    max_w = w;
-                    max_h = h;
-                    break;
-                }
-
-                /* If the icon is the largest so far, capture it. */
-                if ((w > max_w) && (h > max_h))
-                {
-                    max_icon = pdata;
-                    max_w = w;
-                    max_h = h;
-                }
-                pdata += size;
-            }
-
-            /* If an icon was extracted, convert it to a pixbuf.
-             * Its size is max_w and max_h. */
-            if (max_icon != NULL)
-            {
-                /* Allocate enough space for the pixel data. */
-                gulong len = max_w * max_h;
-                guchar * pixdata = g_new(guchar, len * 4);
-
-                /* Loop to convert the pixel data. */
-                guchar * p = pixdata;
-                gulong i;
-                for (i = 0; i < len; p += 4, i += 1)
-                {
-                    guint argb = max_icon[i];
-                    guint rgba = (argb << 8) | (argb >> 24);
-                    p[0] = rgba >> 24;
-                    p[1] = (rgba >> 16) & 0xff;
-                    p[2] = (rgba >> 8) & 0xff;
-                    p[3] = rgba & 0xff;
-                }
-
-                /* Initialize a pixmap with the pixel data. */
-                pixmap = gdk_pixbuf_new_from_data(
-                    pixdata,
-                    GDK_COLORSPACE_RGB,
-                    TRUE, 8,    /* has_alpha, bits_per_sample */
-                    max_w, max_h, max_w * 4,
-                    (GdkPixbufDestroyNotify) g_free,
-                    NULL);
-                possible_source = a_NET_WM_ICON;
-            }
-        else
-            result = -1;
-
-            /* Free the X property data. */
-            XFree(data);
-        }
-    }
-
-    /* No icon available from _NET_WM_ICON.  Next try WM_HINTS, but do not overwrite _NET_WM_ICON. */
-    if ((result != Success) && (*current_source != a_NET_WM_ICON)
-    && ((source == None) || (source != a_NET_WM_ICON)))
-    {
-        XWMHints * hints = XGetWMHints(xdisplay, task_win);
-        result = (hints != NULL) ? Success : -1;
-        Pixmap xpixmap = None;
-        Pixmap xmask = None;
-
-        if (result == Success)
-        {
-            /* WM_HINTS is available.  Extract the X pixmap and mask. */
-            if ((hints->flags & IconPixmapHint))
-                xpixmap = hints->icon_pixmap;
-            if ((hints->flags & IconMaskHint))
-                xmask = hints->icon_mask;
-            XFree(hints);
-            if (xpixmap != None)
-            {
-                result = Success;
-                possible_source = XA_WM_HINTS;
-            }
-            else
-                result = -1;
-        }
-
-        if (result != Success)
-        {
-            /* No icon available from _NET_WM_ICON or WM_HINTS.  Next try KWM_WIN_ICON. */
-            Atom type = None;
-            int format;
-            gulong nitems;
-            gulong bytes_after;
-            Pixmap *icons = NULL;
-            Atom kwin_win_icon_atom = gdk_x11_get_xatom_by_name("KWM_WIN_ICON");
-            result = XGetWindowProperty(
-                xdisplay,
-                task_win,
-                kwin_win_icon_atom,
-                0, G_MAXLONG,
-                False, kwin_win_icon_atom,
-                &type, &format, &nitems, &bytes_after, (void *) &icons);
-
-            /* Inspect the result to see if it is usable.  If not, and we got data, free it. */
-            if (type != kwin_win_icon_atom)
-            {
-                if (icons != NULL)
-                    XFree(icons);
-                result = -1;
-            }
-
-            /* If the result is usable, extract the X pixmap and mask from it. */
-            if (result == Success)
-            {
-                xpixmap = icons[0];
-                xmask = icons[1];
-                if (xpixmap != None)
-                {
-                    result = Success;
-                    possible_source = kwin_win_icon_atom;
-                }
-                else
-                    result = -1;
-            }
-        }
-
-        /* If we have an X pixmap, get its geometry.*/
-        unsigned int w, h;
-        if (result == Success)
-        {
-            Window unused_win;
-            int unused;
-            unsigned int unused_2;
-            result = XGetGeometry(
-                xdisplay, xpixmap,
-                &unused_win, &unused, &unused, &w, &h, &unused_2, &unused_2) ? Success : -1;
-        }
-
-        /* If we have an X pixmap and its geometry, convert it to a GDK pixmap. */
-        if (result == Success)
-        {
-            pixmap = _wnck_gdk_pixbuf_get_from_pixmap(screen, xpixmap, w, h);
-            result = ((pixmap != NULL) ? Success : -1);
-        }
-
-        /* If we have success, see if the result needs to be masked.
-         * Failures here are implemented as nonfatal. */
-        if ((result == Success) && (xmask != None))
-        {
-            Window unused_win;
-            int unused;
-            unsigned int unused_2;
-            if (XGetGeometry(
-                xdisplay, xmask,
-                &unused_win, &unused, &unused, &w, &h, &unused_2, &unused_2))
-            {
-                /* Convert the X mask to a GDK pixmap. */
-                GdkPixbuf * mask = _wnck_gdk_pixbuf_get_from_pixmap(screen, xmask, w, h);
-                if (mask != NULL)
-                {
-                    /* Apply the mask. */
-                    GdkPixbuf * masked_pixmap = apply_mask(pixmap, mask);
-                    g_object_unref(G_OBJECT(pixmap));
-                    g_object_unref(G_OBJECT(mask));
-                    pixmap = masked_pixmap;
-                }
-            }
-        }
-    }
-
-    /* If we got a pixmap, scale it and return it. */
-    if (pixmap == NULL)
-        return NULL;
-    else
-    {
-        GdkPixbuf * ret;
-
-        *current_source = possible_source;
-        if (tb->disable_taskbar_upscale)
-        {
-            guint w = gdk_pixbuf_get_width (pixmap);
-            guint h = gdk_pixbuf_get_height (pixmap);
-            if (w <= required_width || h <= required_height)
-            {
-                return pixmap;
-            }
-        }
-        ret = gdk_pixbuf_scale_simple(pixmap, required_width, required_height,
-                                      GDK_INTERP_BILINEAR);
-        g_object_unref(pixmap);
-        return ret;
-    }
-}
-
-/* Update the icon of a task. */
-static GdkPixbuf * task_update_icon(LaunchTaskBarPlugin * tb, Task * tk, Atom source)
-{
-    /* Get the icon from the window's hints. */
-    GdkPixbuf * pixbuf = get_wm_icon(tk->win, MAX(0, tb->icon_size - ICON_BUTTON_TRIM),
-                                     MAX(0, tb->icon_size - ICON_BUTTON_TRIM),
-                                     source, &tk->image_source, tb);
-
-    /* If that fails, and we have no other icon yet, return the fallback icon. */
-    if ((pixbuf == NULL)
-    && ((source == None) || (tk->image_source == None)))
-    {
-        /* Establish the fallback task icon.  This is used when no other icon is available. */
-        if (tb->fallback_pixbuf == NULL)
-            tb->fallback_pixbuf = gdk_pixbuf_new_from_xpm_data((const char **) icon_xpm);
-        g_object_ref(tb->fallback_pixbuf);
-        pixbuf = tb->fallback_pixbuf;
-    }
-
-    /* Return what we have.  This may be NULL to indicate that no change should be made to the icon. */
-    return pixbuf;
-}
-
-/* Timer expiration for urgency notification.  Also used to draw the button in setting and clearing urgency. */
-static void flash_window_update(Task * tk)
-{
-    /* Set state on the button and redraw. */
-    if ( ! tk->tb->flat_button)
-        gtk_widget_set_state(tk->button, tk->flash_state ? GTK_STATE_SELECTED : GTK_STATE_NORMAL);
-    task_draw_label(tk);
-    if (tk->menu_item != NULL && gtk_widget_get_mapped(tk->menu_item))
-        /* if submenu exists and mapped then set state too */
-        gtk_widget_set_state(tk->menu_item, tk->flash_state ? GTK_STATE_SELECTED : GTK_STATE_NORMAL);
-
-    /* Complement the flashing context. */
-    tk->flash_state = ! tk->flash_state;
-}
-
-static gboolean flash_window_timeout(gpointer tk)
-{
-    if (g_source_is_destroyed(g_main_current_source()))
-        return FALSE;
-    flash_window_update(tk);
-    return TRUE;
-}
-
-/* Set urgency notification. */
-static void task_set_urgency(Task * tk)
-{
-    LaunchTaskBarPlugin * tb = tk->tb;
-    TaskClass * tc = tk->p_taskclass;
-    if ((tb->grouped_tasks) && (tc != NULL) && (tc->visible_count > 1))
-        recompute_group_visibility_for_class(tk->tb, tk->p_taskclass);
-    else
-    {
-        /* Set the flashing context and flash the window immediately. */
-        tk->flash_state = TRUE;
-        flash_window_update(tk);
-
-        /* Set the timer if none is set. */
-        if (tk->flash_timeout == 0)
-            set_timer_on_task(tk);
-    }
-}
-
-/* Clear urgency notification. */
-static void task_clear_urgency(Task * tk)
-{
-    LaunchTaskBarPlugin * tb = tk->tb;
-    TaskClass * tc = tk->p_taskclass;
-    if ((tb->grouped_tasks) && (tc != NULL) && (tc->visible_count > 1))
-        recompute_group_visibility_for_class(tk->tb, tk->p_taskclass);
-    else
-    {
-        /* Remove the timer if one is set. */
-        if (tk->flash_timeout != 0)
-        {
-            g_source_remove(tk->flash_timeout);
-            tk->flash_timeout = 0;
-        }
-        if (tk->menu_item)
-        {
-            g_object_unref(tk->menu_item);
-            tk->menu_item = NULL;
-        }
-
-        /* Clear the flashing context and unflash the window immediately. */
-        tk->flash_state = FALSE;
-        flash_window_update(tk);
-        tk->flash_state = FALSE;
-    }
-}
-
-/* Do the proper steps to raise a window.
- * This means removing it from iconified state and bringing it to the front.
- * We also switch the active desktop and viewport if needed. */
-static void task_raise_window(Task * tk, guint32 time)
-{
-    Display *xdisplay = GDK_DISPLAY_XDISPLAY(gdk_display_get_default());
-
-    /* Change desktop if needed. */
-    if ((tk->desktop != ALL_WORKSPACES) && (tk->desktop != tk->tb->current_desktop))
-        Xclimsg(GDK_ROOT_WINDOW(), a_NET_CURRENT_DESKTOP, tk->desktop, 0, 0, 0, 0);
-
-    /* Evaluate use_net_active if not yet done. */
-    if ( ! tk->tb->net_active_checked)
-    {
-        LaunchTaskBarPlugin * tb = tk->tb;
-        GdkAtom net_active_atom = gdk_x11_xatom_to_atom(a_NET_ACTIVE_WINDOW);
-        tb->use_net_active = gdk_x11_screen_supports_net_wm_hint(tb->screen, net_active_atom);
-        tb->net_active_checked = TRUE;
-    }
-
-    /* Raise the window.  We can use NET_ACTIVE_WINDOW if the window manager supports it.
-     * Otherwise, do it the old way with XMapRaised and XSetInputFocus. */
-    if (tk->tb->use_net_active)
-        Xclimsg(tk->win, a_NET_ACTIVE_WINDOW, 2, time, 0, 0, 0);
-    else
-    {
-#if GTK_CHECK_VERSION(2, 24, 0)
-        GdkWindow * gdkwindow = gdk_x11_window_lookup_for_display(gdk_display_get_default(), tk->win);
-#else
-        GdkWindow * gdkwindow = gdk_xid_table_lookup(tk->win);
-#endif
-        if (gdkwindow != NULL)
-            gdk_window_show(gdkwindow);
-        else
-            XMapRaised(xdisplay, tk->win);
-
-    /* There is a race condition between the X server actually executing the XMapRaised and this code executing XSetInputFocus.
-     * If the window is not viewable, the XSetInputFocus will fail with BadMatch. */
-    XWindowAttributes attr;
-    Display *xdisplay = GDK_DISPLAY_XDISPLAY(gdk_display_get_default());
-    XGetWindowAttributes(xdisplay, tk->win, &attr);
-    if (attr.map_state == IsViewable)
-            XSetInputFocus(xdisplay, tk->win, RevertToNone, time);
-    }
-
-    /* Change viewport if needed. */
-    XWindowAttributes xwa;
-    XGetWindowAttributes(xdisplay, tk->win, &xwa);
-    Xclimsg(tk->win, a_NET_DESKTOP_VIEWPORT, xwa.x, xwa.y, 0, 0, 0);
-}
-
-/* Position-calculation callback for grouped-task and window-management popup menu. */
-static void taskbar_popup_set_position(GtkWidget * menu, gint * px, gint * py, gboolean * push_in, gpointer data)
-{
-    Task * tk = (Task *) data;
-
-    /* Determine the coordinates. */
-    lxpanel_plugin_popup_set_position_helper(tk->tb->panel, tk->button, menu,
-                                             px, py);
-    *push_in = TRUE;
-}
-
-/* Handler for "activate" event from "close all windows" menu*/
-static void taskbar_close_all_windows (GtkWidget * widget, Task * tk )
-{
-    Task * tk_cursor;
-    for (tk_cursor = tk->p_taskclass->p_task_head; tk_cursor != NULL;
-            tk_cursor = tk_cursor->p_task_flink_same_class)
-    {
-        if (task_is_visible_on_current_desktop(tk->tb, tk_cursor))
-        {
-            Xclimsgwm(tk_cursor->win, a_WM_PROTOCOLS, a_WM_DELETE_WINDOW);
-        }
-    }
-    task_group_menu_destroy(tk->tb);
-}
-
-/* Remove the grouped-task popup menu from the screen. */
-static void task_group_menu_destroy(LaunchTaskBarPlugin * tb)
-{
-    if (tb->group_menu != NULL)
-    {
-        gtk_widget_destroy(tb->group_menu);
-        tb->group_menu = NULL;
-    }
-}
-
-/* Handler for "button-press-event" event from taskbar button,
- * or "activate" event from grouped-task popup menu item. */
-static gboolean taskbar_task_control_event(GtkWidget * widget, GdkEventButton * event, Task * tk, gboolean popup_menu)
-{
-    LaunchTaskBarPlugin * tb = tk->tb;
-    TaskClass * tc = tk->p_taskclass;
-    if ((tb->grouped_tasks) && (tc != NULL) && (tc->visible_count > 1) && (GTK_IS_BUTTON(widget)))
-    {
-        /* This is grouped-task representative, meaning that there is a class
-         * with at least two windows. */
-        GtkWidget * menu = NULL;
-        if( event->button == 1 ) /* Left click */
-        {
-            menu = gtk_menu_new();
-            /* Bring up a popup menu listing all the class members. */
-            Task * tk_cursor;
-            GtkWidget * flashing_menu = NULL;
-            for (tk_cursor = tc->p_task_head; tk_cursor != NULL;
-                    tk_cursor = tk_cursor->p_task_flink_same_class)
-            {
-                if (task_is_visible_on_current_desktop(tb, tk_cursor))
-                {
-                    /* The menu item has the name, or the iconified name, and
-                     * the icon of the application window. */
-                    GtkWidget * mi = gtk_image_menu_item_new_with_label(((tk_cursor->iconified) ?
-                                tk_cursor->name_iconified : tk_cursor->name));
-                    GtkWidget * im = gtk_image_new_from_pixbuf(gtk_image_get_pixbuf(
-                                GTK_IMAGE(tk_cursor->image)));
-                    gtk_image_menu_item_set_image(GTK_IMAGE_MENU_ITEM(mi), im);
-                    g_signal_connect(mi, "button-press-event",
-                            G_CALLBACK(taskbar_popup_activate_event), (gpointer) tk_cursor);
-                    gtk_menu_shell_append(GTK_MENU_SHELL(menu), mi);
-                    /* set mi as if it's urgent with reference */
-                    if (tk_cursor->menu_item != NULL)
-                        g_object_unref(tk_cursor->menu_item);
-                    tk_cursor->menu_item = NULL;
-                    if (tk_cursor->urgency && !tk_cursor->focused && flashing_menu == NULL)
-                        flashing_menu = g_object_ref_sink(mi);
-                }
-            }
-            /* since tc->visible_count > 1, tc->p_task_visible cannot be NULL */
-            g_assert(tc->p_task_visible != NULL);
-            g_assert(tc->p_task_visible->menu_item == NULL);
-            tc->p_task_visible->menu_item = flashing_menu;
-        }
-        else if(event->button == 3) /* Right click */
-        {
-            menu = gtk_menu_new();
-            GtkWidget * mi = gtk_menu_item_new_with_mnemonic (_("_Close all windows"));
-            gtk_menu_shell_append ( GTK_MENU_SHELL(menu), mi);
-            g_signal_connect( mi, "activate", G_CALLBACK(taskbar_close_all_windows), tk);
-        }
-
-        /* Show the menu.  Set context so we can find the menu later to dismiss it.
-         * Use a position-calculation callback to get the menu nicely
-         * positioned with respect to the button. */
-        if (menu) {
-            gtk_widget_show_all(menu);
-            task_group_menu_destroy(tb);
-            tb->group_menu = menu;
-            gtk_menu_popup(GTK_MENU(menu), NULL, NULL,
-                    (GtkMenuPositionFunc) taskbar_popup_set_position, (gpointer) tk,
-                    event->button, event->time);
-        }
-    }
-    else
-    {
-        /* Not a grouped-task representative, or entered from the grouped-task popup menu. */
-        Task * visible_task = (((tk->p_taskclass == NULL) || ( ! tk->tb->grouped_tasks)) ? tk : tk->p_taskclass->p_task_visible);
-        task_group_menu_destroy(tb);
-
-        if (event->button == 1)
-        {
-            Display *xdisplay = GDK_DISPLAY_XDISPLAY(gdk_display_get_default());
-            /* Left button.
-             * If the task is iconified, raise it.
-             * If the task is not iconified and has focus, iconify it.
-             * If the task is not iconified and does not have focus, raise it. */
-            if (tk->iconified)
-                task_raise_window(tk, event->time);
-            else if ((tk->focused) || (tk == tb->focused_previous))
-                XIconifyWindow(xdisplay, tk->win, DefaultScreen(xdisplay));
-            else
-                task_raise_window(tk, event->time);
-        }
-        else if (event->button == 2)
-        {
-            /* Middle button.  Toggle the shaded state of the window. */
-            Xclimsg(tk->win, a_NET_WM_STATE,
-                2,      /* a_NET_WM_STATE_TOGGLE */
-                a_NET_WM_STATE_SHADED,
-                0, 0, 0);
-        }
-        else if(event->button == 3)
-        {
-            /* Right button.  Bring up the window state popup menu. */
-            tk->tb->menutask = tk;
-#ifndef DISABLE_MENU
-            LaunchTaskBarPlugin *ltbp = (LaunchTaskBarPlugin *)tk->tb;
-            if(ltbp->mode == LAUNCHTASKBAR)
-            {
-                FmFileInfo *fi = f_find_menu_launchbutton_recursive(tk->exec_bin);
-                LaunchButton *btn = launchbar_exec_bin_exists(ltbp, fi);
-                /* FIXME: shouldn't we make file info at task button creation? */
-#ifdef DEBUG
-                g_print("\nTB '%s' right-click, in LB: %c\n", tk->exec_bin, btn != NULL ? 'Y':'N');
-#endif
-                if(btn != NULL)
-                {
-                    gtk_widget_set_visible(ltbp->p_menuitem_lock_tbp, FALSE);
-                    gtk_widget_set_visible(ltbp->p_menuitem_unlock_tbp, TRUE);
-                    gtk_widget_set_visible(ltbp->p_menuitem_new_instance, TRUE);
-                }
-                else
-                {
-                    gtk_widget_set_visible(ltbp->p_menuitem_lock_tbp, fi != NULL);
-                    gtk_widget_set_visible(ltbp->p_menuitem_unlock_tbp, FALSE);
-                    gtk_widget_set_visible(ltbp->p_menuitem_new_instance, fi != NULL);
-                }
-                gtk_widget_set_visible(ltbp->p_menuitem_separator, TRUE);
-                if (fi)
-                    fm_file_info_unref(fi);
-            }
-            else
-            {
-                gtk_widget_set_visible(ltbp->p_menuitem_lock_tbp, FALSE);
-                gtk_widget_set_visible(ltbp->p_menuitem_unlock_tbp, FALSE);
-                gtk_widget_set_visible(ltbp->p_menuitem_new_instance, FALSE);
-                gtk_widget_set_visible(ltbp->p_menuitem_separator, FALSE);
-            }
-#endif
-            if (tb->workspace_menu0)
-            {
-                GList *items = gtk_container_get_children(GTK_CONTAINER(gtk_widget_get_parent(tb->workspace_menu0)));
-                GList *item = g_list_find(items, tb->workspace_menu0);
-                int i;
-                if (item != NULL) /* else error */
-                    for (i = 0; i < tb->number_of_desktops; i++, item = item->next)
-                        gtk_widget_set_sensitive(item->data, i != tk->desktop);
-                g_list_free(items);
-            }
-            gtk_menu_popup(
-                GTK_MENU(tb->menu),
-                NULL, NULL,
-                (GtkMenuPositionFunc) taskbar_popup_set_position, (gpointer) visible_task,
-                0, event->time);
-        }
-    }
-
-    /* As a matter of policy, avoid showing selected or prelight states on flat buttons. */
-    if (tb->flat_button)
-        gtk_widget_set_state(widget, GTK_STATE_NORMAL);
-    return TRUE;
-}
-
-/* Handler for "button-press-event" event from taskbar button. */
-static gboolean taskbar_button_press_event(GtkWidget * widget, GdkEventButton * event, Task * tk)
-{
-    // needed to prevent releasing focused task button
-    return TRUE;
-}
+/* Handler for "enter" event from taskbar button.  This indicates that the cursor position has entered the button. */
+static void taskbar_button_enter(GtkWidget * widget, GdkEvent *event, LaunchTaskBarPlugin * tb)
+{
+    tb->dnd_task_moving = FALSE;
+}
 
 /* Handler for "button-release-event" event from taskbar button. */
-static gboolean taskbar_button_release_event(GtkWidget * widget, GdkEventButton * event, Task * tk)
+static gboolean taskbar_button_release_event(GtkWidget * widget, GdkEventButton * event, LaunchTaskBarPlugin * tb)
 {
-    if (!tk->tb->dnd_task_moving && tk->entered_state)
+    if (tb->dnd_task_moving)
         /* SF bug#731: don't process button release with DND. Also if button was
            released outside of widget but DND wasn't activated: this might happen
            if drag started at edge of button so drag treshold wasn't reached. */
-        return taskbar_task_control_event(widget, event, tk, FALSE);
-    return TRUE;
-}
-
-/* Handler for "activate" event from grouped-task popup menu item. */
-static gboolean taskbar_popup_activate_event(GtkWidget * widget, GdkEventButton * event, Task * tk)
-{
-    return taskbar_task_control_event(widget, event, tk, TRUE);
-}
-
-/* Handler for "drag-motion" timeout. */
-static gboolean taskbar_button_drag_motion_timeout(Task * tk)
-{
-    guint time;
-    if (g_source_is_destroyed(g_main_current_source()))
-        return FALSE;
-    time = gtk_get_current_event_time();
-    task_raise_window(tk, ((time != 0) ? time : CurrentTime));
-    tk->tb->dnd_delay_timer = 0;
-    return FALSE;
-}
-
-/* Handler for "drag-motion" event from taskbar button. */
-static gboolean taskbar_button_drag_motion(GtkWidget * widget, GdkDragContext * drag_context, gint x, gint y, guint time, Task * tk)
-{
-    GtkWidget * drag_source = gtk_drag_get_source_widget(drag_context);
-    if (drag_source != NULL && gtk_widget_get_parent(drag_source) == gtk_widget_get_parent(tk->button))
-    {
-        tk->tb->dnd_task_moving = TRUE;
-        gdk_drag_status(drag_context, GDK_ACTION_MOVE, time);
-    }
-    else
-    {
-        /* Prevent excessive motion notification. */
-        if (tk->tb->dnd_delay_timer == 0)
-            tk->tb->dnd_delay_timer = g_timeout_add(DRAG_ACTIVE_DELAY, (GSourceFunc) taskbar_button_drag_motion_timeout, tk);
-
-        gdk_drag_status(drag_context, 0, time);
-    }
-    return TRUE;
-}
-
-/* Handler for "drag-drop" event from taskbar button. */
-static gboolean taskbar_button_drag_drop(GtkWidget * widget, GdkDragContext * drag_context, gint x, gint y, guint time, Task * tk)
-{
-    tk->tb->dnd_task_moving = FALSE;
-    GtkWidget * drag_source = gtk_drag_get_source_widget(drag_context);
-    if (drag_source != NULL && gtk_widget_get_parent(drag_source) == gtk_widget_get_parent(tk->button))
-    {
-        if (drag_source != tk->button)
-        {
-            PanelIconGrid *ig = PANEL_ICON_GRID(tk->tb->tb_icon_grid);
-            gint i = panel_icon_grid_get_child_position(ig, tk->button);
-            panel_icon_grid_reorder_child(ig, drag_source, i);
-        }
-        gtk_drag_finish(drag_context, TRUE, TRUE, time);
         return TRUE;
-    }
-
     return FALSE;
 }
 
-/* Handler for "drag-leave" event from taskbar button. */
-static void taskbar_button_drag_leave(GtkWidget * widget, GdkDragContext * drag_context, guint time, Task * tk)
-{
-    /* Cancel the timer if set. */
-    if (tk->tb->dnd_delay_timer != 0)
-    {
-        g_source_remove(tk->tb->dnd_delay_timer);
-        tk->tb->dnd_delay_timer = 0;
-    }
-    return;
-}
-
-/* Handler for "enter" event from taskbar button.  This indicates that the cursor position has entered the button. */
-static void taskbar_button_enter(GtkWidget * widget, Task * tk)
-{
-    tk->tb->dnd_task_moving = FALSE;
-    tk->entered_state = TRUE;
-    if (tk->tb->flat_button)
-        gtk_widget_set_state(widget, GTK_STATE_NORMAL);
-    task_draw_label(tk);
-}
-
-/* Handler for "leave" event from taskbar button.  This indicates that the cursor position has left the button. */
-static void taskbar_button_leave(GtkWidget * widget, Task * tk)
-{
-    tk->entered_state = FALSE;
-    task_draw_label(tk);
-}
-
-/* Handler for "scroll-event" event from taskbar button. */
-static gboolean taskbar_button_scroll_event(GtkWidget * widget, GdkEventScroll&n