diff -Nru haguichi-appindicator-0.1.2/configure haguichi-appindicator-0.1.3/configure --- haguichi-appindicator-0.1.2/configure 2015-01-16 21:33:16.000000000 +0000 +++ haguichi-appindicator-0.1.3/configure 2015-02-28 11:31:26.000000000 +0000 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.68 for Haguichi-AppIndicator 0.1.2. +# Generated by GNU Autoconf 2.68 for Haguichi-AppIndicator 0.1.3. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -556,8 +556,8 @@ # Identity of this package. PACKAGE_NAME='Haguichi-AppIndicator' PACKAGE_TARNAME='haguichi-appindicator' -PACKAGE_VERSION='0.1.2' -PACKAGE_STRING='Haguichi-AppIndicator 0.1.2' +PACKAGE_VERSION='0.1.3' +PACKAGE_STRING='Haguichi-AppIndicator 0.1.3' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1213,7 +1213,7 @@ # 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 Haguichi-AppIndicator 0.1.2 to adapt to many kinds of systems. +\`configure' configures Haguichi-AppIndicator 0.1.3 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1280,7 +1280,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of Haguichi-AppIndicator 0.1.2:";; + short | recursive ) echo "Configuration of Haguichi-AppIndicator 0.1.3:";; esac cat <<\_ACEOF @@ -1387,7 +1387,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -Haguichi-AppIndicator configure 0.1.2 +Haguichi-AppIndicator configure 0.1.3 generated by GNU Autoconf 2.68 Copyright (C) 2010 Free Software Foundation, Inc. @@ -1404,7 +1404,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by Haguichi-AppIndicator $as_me 0.1.2, which was +It was created by Haguichi-AppIndicator $as_me 0.1.3, which was generated by GNU Autoconf 2.68. Invocation command line was $ $0 $@ @@ -2219,7 +2219,7 @@ # Define the identity of the package. PACKAGE='haguichi-appindicator' - VERSION='0.1.2' + VERSION='0.1.3' cat >>confdefs.h <<_ACEOF @@ -3622,7 +3622,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by Haguichi-AppIndicator $as_me 0.1.2, which was +This file was extended by Haguichi-AppIndicator $as_me 0.1.3, which was generated by GNU Autoconf 2.68. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -3675,7 +3675,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -Haguichi-AppIndicator config.status 0.1.2 +Haguichi-AppIndicator config.status 0.1.3 configured by $0, generated by GNU Autoconf 2.68, with options \\"\$ac_cs_config\\" diff -Nru haguichi-appindicator-0.1.2/configure.ac haguichi-appindicator-0.1.3/configure.ac --- haguichi-appindicator-0.1.2/configure.ac 2015-01-16 21:33:14.000000000 +0000 +++ haguichi-appindicator-0.1.3/configure.ac 2015-02-28 11:31:24.000000000 +0000 @@ -1,7 +1,7 @@ dnl Warning: This is an automatically generated file, do not edit! dnl Process this file with autoconf to produce a configure script. AC_PREREQ([2.54]) -AC_INIT([Haguichi-AppIndicator], [0.1.2]) +AC_INIT([Haguichi-AppIndicator], [0.1.3]) AM_INIT_AUTOMAKE([foreign]) AM_MAINTAINER_MODE diff -Nru haguichi-appindicator-0.1.2/debian/changelog haguichi-appindicator-0.1.3/debian/changelog --- haguichi-appindicator-0.1.2/debian/changelog 2015-01-19 10:19:36.000000000 +0000 +++ haguichi-appindicator-0.1.3/debian/changelog 2015-03-04 09:43:47.000000000 +0000 @@ -1,3 +1,9 @@ +haguichi-appindicator (0.1.3-1~webupd8~utopic) utopic; urgency=medium + + * New upstream release + + -- Alin Andrei Wed, 04 Mar 2015 11:43:56 +0200 + haguichi-appindicator (0.1.2-1~webupd8~utopic) utopic; urgency=medium * New upstream release diff -Nru haguichi-appindicator-0.1.2/src/Main.cs haguichi-appindicator-0.1.3/src/Main.cs --- haguichi-appindicator-0.1.2/src/Main.cs 2015-01-16 21:33:13.000000000 +0000 +++ haguichi-appindicator-0.1.3/src/Main.cs 2015-02-28 11:31:23.000000000 +0000 @@ -18,6 +18,7 @@ */ using AppIndicator; +using Gdk; using Gtk; using Mono.Unix; using System; @@ -46,8 +47,35 @@ "haguichi-disconnected", Category.ApplicationStatus ); - indicator.Status = Status.Passive; + indicator.Status = AppIndicator.Status.Passive; indicator.Menu = menu; + indicator.ScrollEvent += delegate ( object o, AppIndicator.ScrollEventArgs args ) + { + // Workaround for bug in libappindicator + // https://bugs.launchpad.net/ubuntu/+source/libappindicator/+bug/1071738 + + ScrollDirection scrollDirection; + + try + { + // this works for versions >= 12.10.1+13.10.20130920-0ubuntu4.1 + scrollDirection = args.Direction; + } + catch ( InvalidCastException ) + { + // older versions will throw exception because the old type was uint + scrollDirection = ( ScrollDirection ) ( uint ) args.Args[1]; + } + + if ( scrollDirection == ScrollDirection.Up ) + { + Platform.AppSession.Show (); + } + else if ( scrollDirection == ScrollDirection.Down ) + { + Platform.AppSession.Hide (); + } + }; Application.Run ();