diff -Nru banshee-community-extensions-1.5.5/aclocal.m4 banshee-community-extensions-1.6.0/aclocal.m4 --- banshee-community-extensions-1.5.5/aclocal.m4 2010-03-11 05:58:41.000000000 +0000 +++ banshee-community-extensions-1.6.0/aclocal.m4 2010-03-31 19:47:48.000000000 +0100 @@ -9702,6 +9702,7 @@ ]) # _AM_PROG_TAR m4_include([build/m4/extensions/alarmclock.m4]) +m4_include([build/m4/extensions/appindicator.m4]) m4_include([build/m4/extensions/awn.m4]) m4_include([build/m4/extensions/banshee.m4]) m4_include([build/m4/extensions/clutterflow.m4]) diff -Nru banshee-community-extensions-1.5.5/AUTHORS banshee-community-extensions-1.6.0/AUTHORS --- banshee-community-extensions-1.5.5/AUTHORS 2010-03-10 00:39:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/AUTHORS 2010-03-31 19:37:31.000000000 +0100 @@ -1,6 +1,7 @@ Extension Maintainers: AlarmClock Bertrand Lorentz + AppIndicator Sense Hofstede Awn Marcos Almeida Jr ClutterFlow Mathijs Dumon CoverWallpaper David Corrales @@ -23,5 +24,7 @@ Gabriel Burt Other Contributors: + Alex Launi + Andrés G. Aragoneses Chow Loong Jin Patrick van Staveren diff -Nru banshee-community-extensions-1.5.5/build/m4/extensions/appindicator.m4 banshee-community-extensions-1.6.0/build/m4/extensions/appindicator.m4 --- banshee-community-extensions-1.5.5/build/m4/extensions/appindicator.m4 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/build/m4/extensions/appindicator.m4 2010-03-31 19:37:31.000000000 +0100 @@ -0,0 +1,25 @@ +AC_DEFUN([BCE_APPINDICATOR], +[ + BCE_ARG_DISABLE([AppIndicator], [try]) + + BCE_CHECK_EXTENSION_DEP([AppIndicator], [APPINDICATORSHARP], + [appindicator-sharp-0.1], + [AppIndicator-sharp was not found. Please install it or disable the AppIndicator extension by passing --disable-appindicator]) + + BCE_CHECK_EXTENSION_DEP([AppIndicator], [NOTIFYSHARP], + [notify-sharp], + [Notify-sharp was not found. Please install it or disable the AppIndicator extension by passing --disable-appindicator]) + + if test "x$enable_AppIndicator" = "xtry" \ + && test "x$have_APPINDICATORSHARP" = "xyes" \ + && test "x$have_NOTIFYSHARP" = "xyes"; then + enable_AppIndicator=yes + fi + + if test "x$enable_AppIndicator" = "xyes"; then + AM_CONDITIONAL(ENABLE_APPINDICATOR, true) + else + enable_AppIndicator=no + AM_CONDITIONAL(ENABLE_APPINDICATOR, false) + fi +]) diff -Nru banshee-community-extensions-1.5.5/build/m4/extensions/ubuntuonemusicstore.m4 banshee-community-extensions-1.6.0/build/m4/extensions/ubuntuonemusicstore.m4 --- banshee-community-extensions-1.5.5/build/m4/extensions/ubuntuonemusicstore.m4 2010-03-11 05:58:07.000000000 +0000 +++ banshee-community-extensions-1.6.0/build/m4/extensions/ubuntuonemusicstore.m4 2010-03-26 22:39:26.000000000 +0000 @@ -1,6 +1,6 @@ AC_DEFUN([BCE_U1MS], [ - BCE_ARG_DISABLE([UbuntuOneMusicStore], [no]) + BCE_ARG_DISABLE([UbuntuOneMusicStore], [try]) BCE_CHECK_EXTENSION_DEP([UbuntuOneMusicStore], [BANSHEE_155], [banshee-1-thickclient >= 1.5.5], @@ -11,6 +11,7 @@ [UbuntuOne-sharp was not found. Please install it or disable the UbuntuOneMusicStore extension by passing --disable-ubuntuonemusicstore]) if test "x$enable_UbuntuOneMusicStore" = "xtry" \ + && test "x$have_BANSHEE_155" = "xyes" \ && test "x$have_UBUNTUONESHARP" = "xyes"; then enable_UbuntuOneMusicStore=yes fi @@ -18,6 +19,7 @@ if test "x$enable_UbuntuOneMusicStore" = "xyes"; then AM_CONDITIONAL(ENABLE_U1MS, true) else + enable_UbuntuOneMusicStore=no AM_CONDITIONAL(ENABLE_U1MS, false) fi ]) diff -Nru banshee-community-extensions-1.5.5/build/m4/Makefile.in banshee-community-extensions-1.6.0/build/m4/Makefile.in --- banshee-community-extensions-1.5.5/build/m4/Makefile.in 2010-03-11 06:03:34.000000000 +0000 +++ banshee-community-extensions-1.6.0/build/m4/Makefile.in 2010-03-31 19:47:51.000000000 +0100 @@ -35,6 +35,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -70,6 +71,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -185,6 +188,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/build/Makefile.in banshee-community-extensions-1.6.0/build/Makefile.in --- banshee-community-extensions-1.5.5/build/Makefile.in 2010-03-11 06:03:34.000000000 +0000 +++ banshee-community-extensions-1.6.0/build/Makefile.in 2010-03-31 19:47:51.000000000 +0100 @@ -35,6 +35,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -82,6 +83,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -197,6 +200,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/configure banshee-community-extensions-1.6.0/configure --- banshee-community-extensions-1.5.5/configure 2010-03-11 05:58:43.000000000 +0000 +++ banshee-community-extensions-1.6.0/configure 2010-03-31 19:47:50.000000000 +0100 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.63 for banshee-community-extensions 1.5.5. +# Generated by GNU Autoconf 2.63 for banshee-community-extensions 1.6.0. # # Report bugs to . # @@ -745,8 +745,8 @@ # Identity of this package. PACKAGE_NAME='banshee-community-extensions' PACKAGE_TARNAME='banshee-community-extensions' -PACKAGE_VERSION='1.5.5' -PACKAGE_STRING='banshee-community-extensions 1.5.5' +PACKAGE_VERSION='1.6.0' +PACKAGE_STRING='banshee-community-extensions 1.6.0' PACKAGE_BUGREPORT='http://bugzilla.gnome.org/enter_bug.cgi?product=banshee&component=Community%20Extensions' # Factoring default headers for most tests. @@ -852,6 +852,12 @@ CLUTTER_SHARP_CFLAGS ENABLE_AWN_FALSE ENABLE_AWN_TRUE +ENABLE_APPINDICATOR_FALSE +ENABLE_APPINDICATOR_TRUE +NOTIFYSHARP_LIBS +NOTIFYSHARP_CFLAGS +APPINDICATORSHARP_LIBS +APPINDICATORSHARP_CFLAGS ENABLE_ALARMCLOCK_FALSE ENABLE_ALARMCLOCK_TRUE NUNIT_LIBS @@ -1049,6 +1055,7 @@ enable_release enable_tests enable_alarmclock +enable_appindicator enable_awn enable_clutterflow enable_coverwallpaper @@ -1081,6 +1088,10 @@ BANSHEE_LIBS NUNIT_CFLAGS NUNIT_LIBS +APPINDICATORSHARP_CFLAGS +APPINDICATORSHARP_LIBS +NOTIFYSHARP_CFLAGS +NOTIFYSHARP_LIBS CLUTTER_SHARP_CFLAGS CLUTTER_SHARP_LIBS BANSHEE_NOWPLAYING_CFLAGS @@ -1659,7 +1670,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 banshee-community-extensions 1.5.5 to adapt to many kinds of systems. +\`configure' configures banshee-community-extensions 1.6.0 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1730,7 +1741,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of banshee-community-extensions 1.5.5:";; + short | recursive ) echo "Configuration of banshee-community-extensions 1.6.0:";; esac cat <<\_ACEOF @@ -1753,6 +1764,7 @@ --enable-release Use release configuration --enable-tests Enable NUnit tests --disable-alarmclock Do not build the AlarmClock extension + --disable-appindicator Do not build the AppIndicator extension --disable-awn Do not build the Awn extension --disable-clutterflow Do not build the ClutterFlow extension --disable-coverwallpaper @@ -1806,6 +1818,14 @@ NUNIT_CFLAGS C compiler flags for NUNIT, overriding pkg-config NUNIT_LIBS linker flags for NUNIT, overriding pkg-config + APPINDICATORSHARP_CFLAGS + C compiler flags for APPINDICATORSHARP, overriding pkg-config + APPINDICATORSHARP_LIBS + linker flags for APPINDICATORSHARP, overriding pkg-config + NOTIFYSHARP_CFLAGS + C compiler flags for NOTIFYSHARP, overriding pkg-config + NOTIFYSHARP_LIBS + linker flags for NOTIFYSHARP, overriding pkg-config CLUTTER_SHARP_CFLAGS C compiler flags for CLUTTER_SHARP, overriding pkg-config CLUTTER_SHARP_LIBS @@ -1920,7 +1940,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -banshee-community-extensions configure 1.5.5 +banshee-community-extensions configure 1.6.0 generated by GNU Autoconf 2.63 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1934,7 +1954,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by banshee-community-extensions $as_me 1.5.5, which was +It was created by banshee-community-extensions $as_me 1.6.0, which was generated by GNU Autoconf 2.63. Invocation command line was $ $0 $@ @@ -2651,7 +2671,7 @@ # Define the identity of the package. PACKAGE='banshee-community-extensions' - VERSION='1.5.5' + VERSION='1.6.0' cat >>confdefs.h <<_ACEOF @@ -5311,13 +5331,13 @@ else lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:5314: $ac_compile\"" >&5) + (eval echo "\"\$as_me:5334: $ac_compile\"" >&5) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&5 - (eval echo "\"\$as_me:5317: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval echo "\"\$as_me:5337: $NM \\\"conftest.$ac_objext\\\"\"" >&5) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&5 - (eval echo "\"\$as_me:5320: output\"" >&5) + (eval echo "\"\$as_me:5340: output\"" >&5) cat conftest.out >&5 if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" @@ -6522,7 +6542,7 @@ ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 6525 "configure"' > conftest.$ac_ext + echo '#line 6545 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -8375,11 +8395,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:8378: $lt_compile\"" >&5) + (eval echo "\"\$as_me:8398: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:8382: \$? = $ac_status" >&5 + echo "$as_me:8402: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -8714,11 +8734,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:8717: $lt_compile\"" >&5) + (eval echo "\"\$as_me:8737: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:8721: \$? = $ac_status" >&5 + echo "$as_me:8741: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -8819,11 +8839,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:8822: $lt_compile\"" >&5) + (eval echo "\"\$as_me:8842: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:8826: \$? = $ac_status" >&5 + echo "$as_me:8846: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -8874,11 +8894,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:8877: $lt_compile\"" >&5) + (eval echo "\"\$as_me:8897: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:8881: \$? = $ac_status" >&5 + echo "$as_me:8901: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -11674,7 +11694,7 @@ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11677 "configure" +#line 11697 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -11770,7 +11790,7 @@ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11773 "configure" +#line 11793 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -15627,6 +15647,201 @@ + # Check whether --enable-appindicator was given. +if test "${enable_appindicator+set}" = set; then + enableval=$enable_appindicator; enable_AppIndicator=$enableval +else + enable_AppIndicator=try + +fi + + + + + +pkg_failed=no +{ $as_echo "$as_me:$LINENO: checking for APPINDICATORSHARP" >&5 +$as_echo_n "checking for APPINDICATORSHARP... " >&6; } + +if test -n "$APPINDICATORSHARP_CFLAGS"; then + pkg_cv_APPINDICATORSHARP_CFLAGS="$APPINDICATORSHARP_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"appindicator-sharp-0.1\"") >&5 + ($PKG_CONFIG --exists --print-errors "appindicator-sharp-0.1") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_APPINDICATORSHARP_CFLAGS=`$PKG_CONFIG --cflags "appindicator-sharp-0.1" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$APPINDICATORSHARP_LIBS"; then + pkg_cv_APPINDICATORSHARP_LIBS="$APPINDICATORSHARP_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"appindicator-sharp-0.1\"") >&5 + ($PKG_CONFIG --exists --print-errors "appindicator-sharp-0.1") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_APPINDICATORSHARP_LIBS=`$PKG_CONFIG --libs "appindicator-sharp-0.1" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + APPINDICATORSHARP_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "appindicator-sharp-0.1" 2>&1` + else + APPINDICATORSHARP_PKG_ERRORS=`$PKG_CONFIG --print-errors "appindicator-sharp-0.1" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$APPINDICATORSHARP_PKG_ERRORS" >&5 + + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } + have_APPINDICATORSHARP=no +elif test $pkg_failed = untried; then + have_APPINDICATORSHARP=no +else + APPINDICATORSHARP_CFLAGS=$pkg_cv_APPINDICATORSHARP_CFLAGS + APPINDICATORSHARP_LIBS=$pkg_cv_APPINDICATORSHARP_LIBS + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + have_APPINDICATORSHARP=yes +fi + + + + if test "x$enable_AppIndicator" = "xyes" -a "x$have_APPINDICATORSHARP" = "xno"; then + { { $as_echo "$as_me:$LINENO: error: AppIndicator-sharp was not found. Please install it or disable the AppIndicator extension by passing --disable-appindicator" >&5 +$as_echo "$as_me: error: AppIndicator-sharp was not found. Please install it or disable the AppIndicator extension by passing --disable-appindicator" >&2;} + { (exit 1); exit 1; }; } + fi + + + + +pkg_failed=no +{ $as_echo "$as_me:$LINENO: checking for NOTIFYSHARP" >&5 +$as_echo_n "checking for NOTIFYSHARP... " >&6; } + +if test -n "$NOTIFYSHARP_CFLAGS"; then + pkg_cv_NOTIFYSHARP_CFLAGS="$NOTIFYSHARP_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"notify-sharp\"") >&5 + ($PKG_CONFIG --exists --print-errors "notify-sharp") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_NOTIFYSHARP_CFLAGS=`$PKG_CONFIG --cflags "notify-sharp" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$NOTIFYSHARP_LIBS"; then + pkg_cv_NOTIFYSHARP_LIBS="$NOTIFYSHARP_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"notify-sharp\"") >&5 + ($PKG_CONFIG --exists --print-errors "notify-sharp") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_NOTIFYSHARP_LIBS=`$PKG_CONFIG --libs "notify-sharp" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + NOTIFYSHARP_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "notify-sharp" 2>&1` + else + NOTIFYSHARP_PKG_ERRORS=`$PKG_CONFIG --print-errors "notify-sharp" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$NOTIFYSHARP_PKG_ERRORS" >&5 + + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } + have_NOTIFYSHARP=no +elif test $pkg_failed = untried; then + have_NOTIFYSHARP=no +else + NOTIFYSHARP_CFLAGS=$pkg_cv_NOTIFYSHARP_CFLAGS + NOTIFYSHARP_LIBS=$pkg_cv_NOTIFYSHARP_LIBS + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + have_NOTIFYSHARP=yes +fi + + + + if test "x$enable_AppIndicator" = "xyes" -a "x$have_NOTIFYSHARP" = "xno"; then + { { $as_echo "$as_me:$LINENO: error: Notify-sharp was not found. Please install it or disable the AppIndicator extension by passing --disable-appindicator" >&5 +$as_echo "$as_me: error: Notify-sharp was not found. Please install it or disable the AppIndicator extension by passing --disable-appindicator" >&2;} + { (exit 1); exit 1; }; } + fi + + + if test "x$enable_AppIndicator" = "xtry" \ + && test "x$have_APPINDICATORSHARP" = "xyes" \ + && test "x$have_NOTIFYSHARP" = "xyes"; then + enable_AppIndicator=yes + fi + + if test "x$enable_AppIndicator" = "xyes"; then + if true; then + ENABLE_APPINDICATOR_TRUE= + ENABLE_APPINDICATOR_FALSE='#' +else + ENABLE_APPINDICATOR_TRUE='#' + ENABLE_APPINDICATOR_FALSE= +fi + + else + enable_AppIndicator=no + if false; then + ENABLE_APPINDICATOR_TRUE= + ENABLE_APPINDICATOR_FALSE='#' +else + ENABLE_APPINDICATOR_TRUE='#' + ENABLE_APPINDICATOR_FALSE= +fi + + fi + + + # Check whether --enable-awn was given. if test "${enable_awn+set}" = set; then enableval=$enable_awn; enable_Awn=$enableval @@ -17226,7 +17441,7 @@ if test "${enable_ubuntuonemusicstore+set}" = set; then enableval=$enable_ubuntuonemusicstore; enable_UbuntuOneMusicStore=$enableval else - enable_UbuntuOneMusicStore=no + enable_UbuntuOneMusicStore=try fi @@ -17389,6 +17604,7 @@ if test "x$enable_UbuntuOneMusicStore" = "xtry" \ + && test "x$have_BANSHEE_155" = "xyes" \ && test "x$have_UBUNTUONESHARP" = "xyes"; then enable_UbuntuOneMusicStore=yes fi @@ -17403,6 +17619,7 @@ fi else + enable_UbuntuOneMusicStore=no if false; then ENABLE_U1MS_TRUE= ENABLE_U1MS_FALSE='#' @@ -17527,7 +17744,7 @@ -ac_config_files="$ac_config_files Makefile build/Makefile build/m4/Makefile build/m4/shave/shave build/m4/shave/shave-libtool po/Makefile.in src/Makefile src/AssemblyInfo.cs src/AlarmClock/Makefile src/Awn/Makefile src/ClutterFlow/Makefile src/ClutterFlow/Banshee.ClutterFlow/Makefile src/ClutterFlow/ClutterFlow/Makefile src/CoverWallpaper/Makefile src/LCD/Makefile src/Lirc/Makefile src/Lirc/lirc-glue/Makefile src/Lirc/Banshee.Lirc/Makefile src/Lirc/GUITestHarness/Makefile src/Lirc/NUnitTests/Makefile src/LiveRadio/Makefile src/Lyrics/Makefile src/Magnatune/Makefile src/Mirage/Makefile src/Mirage/libmirageaudio/Makefile src/Mirage/Mirage/Makefile src/Mirage/Banshee.Mirage/Makefile src/Mirage/Test/Makefile src/RadioStationFetcher/Makefile src/StreamRecorder/Makefile src/Telepathy/Makefile src/Telepathy/Banshee.Telepathy/Makefile src/UbuntuOneMusicStore/Makefile" +ac_config_files="$ac_config_files Makefile build/Makefile build/m4/Makefile build/m4/shave/shave build/m4/shave/shave-libtool po/Makefile.in src/Makefile src/AppIndicator/Makefile src/AssemblyInfo.cs src/AlarmClock/Makefile src/Awn/Makefile src/ClutterFlow/Makefile src/ClutterFlow/Banshee.ClutterFlow/Makefile src/ClutterFlow/ClutterFlow/Makefile src/CoverWallpaper/Makefile src/LCD/Makefile src/Lirc/Makefile src/Lirc/lirc-glue/Makefile src/Lirc/Banshee.Lirc/Makefile src/Lirc/GUITestHarness/Makefile src/Lirc/NUnitTests/Makefile src/LiveRadio/Makefile src/Lyrics/Makefile src/Magnatune/Makefile src/Mirage/Makefile src/Mirage/libmirageaudio/Makefile src/Mirage/Mirage/Makefile src/Mirage/Banshee.Mirage/Makefile src/Mirage/Test/Makefile src/RadioStationFetcher/Makefile src/StreamRecorder/Makefile src/Telepathy/Makefile src/Telepathy/Banshee.Telepathy/Makefile src/UbuntuOneMusicStore/Makefile" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure @@ -17728,6 +17945,20 @@ Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi +if test -z "${ENABLE_APPINDICATOR_TRUE}" && test -z "${ENABLE_APPINDICATOR_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"ENABLE_APPINDICATOR\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"ENABLE_APPINDICATOR\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${ENABLE_APPINDICATOR_TRUE}" && test -z "${ENABLE_APPINDICATOR_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"ENABLE_APPINDICATOR\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"ENABLE_APPINDICATOR\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi if test -z "${ENABLE_AWN_TRUE}" && test -z "${ENABLE_AWN_FALSE}"; then { { $as_echo "$as_me:$LINENO: error: conditional \"ENABLE_AWN\" was never defined. Usually this means the macro was only invoked conditionally." >&5 @@ -18232,7 +18463,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by banshee-community-extensions $as_me 1.5.5, which was +This file was extended by banshee-community-extensions $as_me 1.6.0, which was generated by GNU Autoconf 2.63. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -18295,7 +18526,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_version="\\ -banshee-community-extensions config.status 1.5.5 +banshee-community-extensions config.status 1.6.0 configured by $0, generated by GNU Autoconf 2.63, with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" @@ -18685,6 +18916,7 @@ "build/m4/shave/shave-libtool") CONFIG_FILES="$CONFIG_FILES build/m4/shave/shave-libtool" ;; "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; + "src/AppIndicator/Makefile") CONFIG_FILES="$CONFIG_FILES src/AppIndicator/Makefile" ;; "src/AssemblyInfo.cs") CONFIG_FILES="$CONFIG_FILES src/AssemblyInfo.cs" ;; "src/AlarmClock/Makefile") CONFIG_FILES="$CONFIG_FILES src/AlarmClock/Makefile" ;; "src/Awn/Makefile") CONFIG_FILES="$CONFIG_FILES src/Awn/Makefile" ;; @@ -20213,6 +20445,7 @@ Extensions: Alarm Clock: ${enable_AlarmClock} + AppIndicator: ${enable_AppIndicator} Awn: ${enable_Awn} ClutterFlow: ${enable_ClutterFlow} CoverWallpaper: ${enable_CoverWallpaper} diff -Nru banshee-community-extensions-1.5.5/configure.ac banshee-community-extensions-1.6.0/configure.ac --- banshee-community-extensions-1.5.5/configure.ac 2010-03-10 00:37:53.000000000 +0000 +++ banshee-community-extensions-1.6.0/configure.ac 2010-03-31 19:46:21.000000000 +0100 @@ -1,5 +1,5 @@ AC_PREREQ(2.52) -AC_INIT([banshee-community-extensions], 1.5.5, +AC_INIT([banshee-community-extensions], 1.6.0, [http://bugzilla.gnome.org/enter_bug.cgi?product=banshee&component=Community%20Extensions]) AM_INIT_AUTOMAKE([1.9 dist-bzip2 tar-ustar dist-zip foreign]) @@ -70,6 +70,7 @@ dnl Extensions BCE_ALARMCLOCK +BCE_APPINDICATOR BCE_AWN BCE_CLUTTERFLOW BCE_COVERWALLPAPER @@ -115,6 +116,7 @@ po/Makefile.in src/Makefile +src/AppIndicator/Makefile src/AssemblyInfo.cs src/AlarmClock/Makefile @@ -165,6 +167,7 @@ Extensions: Alarm Clock: ${enable_AlarmClock} + AppIndicator: ${enable_AppIndicator} Awn: ${enable_Awn} ClutterFlow: ${enable_ClutterFlow} CoverWallpaper: ${enable_CoverWallpaper} diff -Nru banshee-community-extensions-1.5.5/debian/banshee-extension-appindicator.install banshee-community-extensions-1.6.0/debian/banshee-extension-appindicator.install --- banshee-community-extensions-1.5.5/debian/banshee-extension-appindicator.install 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/banshee-extension-appindicator.install 2010-04-06 13:24:17.000000000 +0100 @@ -0,0 +1 @@ +/usr/lib/banshee-1/Extensions/Banshee.AppIndicator.* diff -Nru banshee-community-extensions-1.5.5/debian/banshee-extension-liveradio.install banshee-community-extensions-1.6.0/debian/banshee-extension-liveradio.install --- banshee-community-extensions-1.5.5/debian/banshee-extension-liveradio.install 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/banshee-extension-liveradio.install 2010-04-06 13:24:17.000000000 +0100 @@ -0,0 +1 @@ +/usr/lib/banshee-1/Extensions/Banshee.LiveRadio.* diff -Nru banshee-community-extensions-1.5.5/debian/changelog banshee-community-extensions-1.6.0/debian/changelog --- banshee-community-extensions-1.5.5/debian/changelog 2010-04-06 13:24:16.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/changelog 2010-04-06 13:24:17.000000000 +0100 @@ -1,43 +1,53 @@ -banshee-community-extensions (1.5.5-1ubuntu1~hyper1~karmic) karmic; urgency=low +banshee-community-extensions (1.6.0-1ubuntu1~hyper1~karmic) karmic; urgency=low * Backport to karmic, changes: + debian/control, debian/rules: - - Disable u1ms + - Disable u1ms and appindicator - Revert -cil-dev transition - -- Chow Loong Jin Wed, 24 Mar 2010 14:15:04 +0800 + -- Chow Loong Jin Tue, 06 Apr 2010 18:16:41 +0800 -banshee-community-extensions (1.5.5-1ubuntu1) lucid; urgency=low +banshee-community-extensions (1.6.0-1ubuntu1) lucid; urgency=low - * Changes from Debian not yet uploaded: - + debian/control: - - Fix double "and" in the description of -empathy - * Ubuntu-specific changes: - + debian/control, rules: - - Enable banshee-extension-{ubuntuonemusicstore,lirc} - + Fixes needs-packaging bug (LP: #537691) + * debian/(control, rules): + + Enable AppIndicator, Lirc and U1MS extensions + * Fixes needs-packaging bug (LP: #537691) + + -- Chow Loong Jin Sun, 04 Apr 2010 18:17:28 +0800 + +banshee-community-extensions (1.6.0-1) unstable; urgency=low + + * New upstream release + * debian/(control, banshee-extension-appindicator.install): + + Add Application Indicator package and build-depends (commented out + because these dependencies are not present in Debian yet) + * debian/copyright: + + Document more MIT/X11 files in Mirage's source + + Document LGPL-3 files in Banshee.Telepathy + + Document bundled NDesk.DBus in Banshee.Telepathy + + Document Banshee.Lirc copyrights + * debian/rules: + + --disable-appindicator + * debian/patches/*, debian/control, debian/rules: + + Drop all patches, applied upstream and/or not needed any more + + De-quiltify package - -- Chow Loong Jin Wed, 24 Mar 2010 13:53:06 +0800 + -- Chow Loong Jin Sun, 04 Apr 2010 18:00:24 +0800 -banshee-community-extensions (1.5.5-1) unstable; urgency=low - - * Initial release (LP: #537691) - - -- Chow Loong Jin Wed, 17 Mar 2010 00:50:46 +0800 - -banshee-community-extensions (1.5.4-1~hyper2~karmic) karmic; urgency=low +banshee-community-extensions (1.5.5-2) unstable; urgency=low * debian/control: - + Shift awn dependency to banshee-extension-awn - * debian/patches/01_random-by-similar.patch: - + Fix crash with random-by-similar + + Fix double "and" in the description of -empathy + + Add lsb-release to build-dep + * debian/(control, rules, banshee-extension-liveradio.install): + + Enable and add banshee-extension-liveradio package + * debian/copyright: + + Update (document src/LiveRadio/* and src/CoverWallpaper/*) - -- Chow Loong Jin Wed, 03 Mar 2010 00:53:41 +0800 + -- Chow Loong Jin Thu, 25 Mar 2010 11:17:11 +0800 -banshee-community-extensions (1.5.4-1~hyper1~karmic) karmic; urgency=low - - * Backport to karmic, changes: - + Revert -cil-dev transition +banshee-community-extensions (1.5.5-1) unstable; urgency=low - -- Chow Loong Jin Sun, 28 Feb 2010 17:30:19 +0800 + * Initial release (Closes: #570329) + -- Chow Loong Jin Fri, 12 Mar 2010 21:36:21 +0800 diff -Nru banshee-community-extensions-1.5.5/debian/control banshee-community-extensions-1.6.0/debian/control --- banshee-community-extensions-1.5.5/debian/control 2010-04-06 13:24:16.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/control 2010-04-06 13:24:17.000000000 +0100 @@ -6,8 +6,8 @@ Build-Depends: debhelper (>= 7.0.50), cli-common-dev (>= 0.5.7), mono-devel (>= 2.4.2.3), - quilt (>= 0.46-7~), autotools-dev, + lsb-release, banshee (>= 1.5.5), pkg-config, liblircclient-dev (>= 0.8.6), @@ -35,11 +35,13 @@ Package: banshee-community-extensions Architecture: all Depends: banshee-extension-alarm (>= ${source:Version}), +# banshee-extension-appindicator (>= ${source:Version}), banshee-extension-awn (>= ${source:Version}), # banshee-extension-clutterflow (>= ${source:Version}), banshee-extension-coverwallpaper (>= ${source:Version}), banshee-extension-lcd (>= ${source:Version}), banshee-extension-lirc (>= ${source:Version}), + banshee-extension-liveradio (>= ${source:Version}), banshee-extension-lyrics (>= ${source:Version}), banshee-extension-magnatune (>= ${source:Version}), banshee-extension-mirage (>= ${source:Version}), @@ -75,6 +77,19 @@ . Banshee is a media management and playback application for the GNOME desktop. +# Package: banshee-extension-appindicator +# Architecture: all +# Depends: banshee (>= ${banshee:Version}), +# banshee-extensions-common (= ${source:Version}), +# indicator-applet, indicator-application, +# ${cli:Depends}, ${misc:Depends} +# Description: Application Indicator extension for Banshee +# This package provides integration for Banshee with Application Indicators, +# which is a replacement for the notification area in Ubuntu, as a way to add +# menus in the panel. +# . +# Banshee is a media management and playback application for the GNOME desktop. + Package: banshee-extension-awn Architecture: all Depends: banshee (>= ${banshee:Version}), @@ -133,6 +148,27 @@ . Banshee is a media management and playback application for the GNOME desktop. +Package: banshee-extension-liveradio +Architecture: all +Depends: banshee (>= ${banshee:Version}), + banshee-extensions-common (= ${source:Version}), + ${cli:Depends}, ${misc:Depends} +Description: LiveRadio extension for Banshee + The LiveRadio extension for Banshee is a browser for online Internet station + directories integrated into the Banshee media player. It currently supports + live365.com, shoutcast.com and xiph.org, but its plugin-like code structure can + easily be extended to support just about any directory. + . + LiveRadio has the follwing features: + * Browse and query three online internet radio directories: + – live365.com + – shoutcast.com + – xiph.org + * Retrieve stream information and play the stream + * Add your favorite streams to your list of Internet Radio stations in Banshee + . + Banshee is a media management and playback application for the GNOME desktop. + Package: banshee-extension-lyrics Architecture: all Depends: banshee (>= ${banshee:Version}), diff -Nru banshee-community-extensions-1.5.5/debian/copyright banshee-community-extensions-1.6.0/debian/copyright --- banshee-community-extensions-1.5.5/debian/copyright 2010-04-06 13:24:16.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/copyright 2010-04-06 13:24:17.000000000 +0100 @@ -14,17 +14,35 @@ Copyright: 2008-2009, Bertrand Lorentz 2009-2009, Patrick van Staveren +Files: src/AppIndicator/* +Copyright: 2010, Sense Hofstede + 2005-2009, Novell, Inc. + 2006-2007, Sebastian Dröge +X-Comment: Code originally from Banshee.NotificationArea which is in Banshee's + source tree + Files: src/Awn/* Copyright: Marcos Almeida Jr. Files: src/ClutterFlow/* Copyright: 2010, Mathijs Dumon +Files: src/CoverWallpaper/* +Copyright: 2009, David Corrales + Files: src/LCD/* Copyright: 2010, André Gaul Files: src/Lirc/* -Copyright: Jean-Baptiste Lab +Copyright: 2010, Jean-Baptiste Lab + 2006, Patrick van Staveren +X-Comment: Code was merged in from + http://code.google.com/p/banshee-unofficial-plugins/ and copyright + information found in the debian/copyright of that source tree + +Files: src/LiveRadio/* +Copyright: 2008, Novel, Inc. + 2010, Frank Ziegler Files: src/Lyrics/* Copyright: 2009, Christian Martellini @@ -37,7 +55,9 @@ 2008, Bertrand Lorentz License: GPL-2+ -Files: src/Mirage/Banshee.Mirage/RandomBySimilar.cs +Files: src/Mirage/Banshee.Mirage/RandomBySimilar.cs, + src/Mirage/Banshee.Mirage/Seed.cs, + src/Mirage/Banshee.Mirage/Tests/SimilarityTests.cs Copyright: 2010, Novell, Inc. License: MIT/X11 @@ -49,8 +69,18 @@ 2009, Frank Ziegler Files: src/Telepathy/* -Copyright: 2006-2009, Alp Toker - 2009, Neil Loknath +Copyright: 2009, Neil Loknath + +Files: src/Telepathy/MissionControl.cs + src/Telepathy/Telepathy.cs +Copyright: 2009, Neil Loknath +License: LGPL-3+ + +Files: src/Telepathy/NDesk.DBus/* +Copyright: 2006-2008, Alp Toker +X-Comment: Currently needs bundling due to an unknown commit which fixes a crash + in this extension. Once this commit is identified and cherry-picked + or a snapshot is uploaded, this will be excluded from build. Files: src/UbuntuOneMusicStore/* Copyright: 2010, Jo Shields diff -Nru banshee-community-extensions-1.5.5/debian/patches/01_magnatune-unicode-ftb.patch banshee-community-extensions-1.6.0/debian/patches/01_magnatune-unicode-ftb.patch --- banshee-community-extensions-1.5.5/debian/patches/01_magnatune-unicode-ftb.patch 2010-04-06 13:24:16.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/patches/01_magnatune-unicode-ftb.patch 1970-01-01 01:00:00.000000000 +0100 @@ -1,28 +0,0 @@ -commit 039ca32b6787bf06a52e12d51952c4453e1c6bbe -Author: Gabriel Burt -Date: Thu Mar 11 09:07:24 2010 -0800 - - [Magnatune] Replace unicode char with \u expansion - -diff --git a/src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs b/src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs -index ecb54b2..a5bf178 100644 ---- a/src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs -+++ b/src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs -@@ -66,7 +66,7 @@ namespace Banshee.Magnatune { - this.username.CanFocus = true; - this.username.Name = "username"; - this.username.IsEditable = true; -- this.username.InvisibleChar = '●'; -+ this.username.InvisibleChar = '\u25cf'; - this.hbox2.Add(this.username); - Gtk.Box.BoxChild w3 = ((Gtk.Box.BoxChild)(this.hbox2[this.username])); - w3.Position = 1; -@@ -94,7 +94,7 @@ namespace Banshee.Magnatune { - this.password.Name = "password"; - this.password.IsEditable = true; - this.password.Visibility = false; -- this.password.InvisibleChar = '●'; -+ this.password.InvisibleChar = '\u25cf'; - this.hbox1.Add(this.password); - Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(this.hbox1[this.password])); - w6.Position = 1; diff -Nru banshee-community-extensions-1.5.5/debian/patches/99_ignore-quilt.patch banshee-community-extensions-1.6.0/debian/patches/99_ignore-quilt.patch --- banshee-community-extensions-1.5.5/debian/patches/99_ignore-quilt.patch 2010-04-06 13:24:16.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/patches/99_ignore-quilt.patch 1970-01-01 01:00:00.000000000 +0100 @@ -1,8 +0,0 @@ -Index: banshee-community-extensions/po/POTFILES.skip -=================================================================== ---- banshee-community-extensions.orig/po/POTFILES.skip 2010-03-02 20:35:44.504963615 +0800 -+++ banshee-community-extensions/po/POTFILES.skip 2010-03-02 20:35:52.141964035 +0800 -@@ -1,2 +1,3 @@ - build/extension-template/Banshee.Template/TemplateSource.cs - src/Lirc/GUITestHarness/gtk-gui/MainWindow.cs -+.pc diff -Nru banshee-community-extensions-1.5.5/debian/patches/series banshee-community-extensions-1.6.0/debian/patches/series --- banshee-community-extensions-1.5.5/debian/patches/series 2010-04-06 13:24:16.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/patches/series 1970-01-01 01:00:00.000000000 +0100 @@ -1,2 +0,0 @@ -01_magnatune-unicode-ftb.patch -99_ignore-quilt.patch diff -Nru banshee-community-extensions-1.5.5/debian/rules banshee-community-extensions-1.6.0/debian/rules --- banshee-community-extensions-1.5.5/debian/rules 2010-04-06 13:24:16.000000000 +0100 +++ banshee-community-extensions-1.6.0/debian/rules 2010-04-06 13:24:17.000000000 +0100 @@ -6,20 +6,20 @@ BANSHEE_VERSION = $(shell pkg-config --modversion banshee-1-thickclient) # disable clutterflow and lirc due to dependencies missing -# disable liveradio due to its alpha status override_dh_auto_configure: dh_auto_configure -- \ --with-vendor-build-id="`lsb_release -ds`" \ --enable-gnome \ --enable-schemas-install \ --enable-alarmclock \ + --disable-appindicator \ --enable-awn \ --disable-clutterflow \ --enable-coverwallpaper \ --enable-lcd \ --enable-lirc \ --enable-lyrics \ - --disable-liveradio \ + --enable-liveradio \ --enable-magnatune \ --enable-mirage \ --enable-radiostationfetcher \ @@ -36,4 +36,4 @@ dh_gencontrol %: - dh --with=quilt $@ + dh $@ diff -Nru banshee-community-extensions-1.5.5/Makefile.in banshee-community-extensions-1.6.0/Makefile.in --- banshee-community-extensions-1.5.5/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -40,6 +40,7 @@ install-sh ltmain.sh missing ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -99,6 +100,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -214,6 +217,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/NEWS banshee-community-extensions-1.6.0/NEWS --- banshee-community-extensions-1.5.5/NEWS 2010-03-10 17:56:08.000000000 +0000 +++ banshee-community-extensions-1.6.0/NEWS 2010-03-31 19:46:08.000000000 +0100 @@ -1,4 +1,32 @@ ============================== +Version 1.6.0 - March 31, 2010 +============================== + +Contributors: +Alex Launi, Alexander Kojevnikov, Andrés G. Aragoneses, Bertrand Lorentz, +Frank Ziegler, Gabriel Burt, Jo Shields, Mathijs Dumon, Sense Hofstede + +New: +* [AppIndicator] use the new application indicator area available in Ubuntu. + +Enhancements: +* [ClutterFlow] Added an alphabet bar to the scrollbar for fast browsing +* [Lyrics] Add www.lyricsplugin.com support + +Bugs Fixed: +* [ClutterFlow] Fix shade bug when there's no shader support +* [ClutterFlow] Fix party-mode transition, fixed wrong slider label +* [ClutterFlow] Fix small bug, now stores user sorting setting +* [ClutterFlow] Fix asynchronous clone creation when user clicks album currently not centered +* [ClutterFlow] Fix fullscreen bug, fixing internationalisation strings (again) +* [I18N] Replace all Catalog calls with calls to the Mono.Addins localizer +* [Magnatune] Replace unicode char with \u expansion +* [Mirage] Only load RandomBySimilar if Mirage working +* [StreamRecorder] Added "unchanged" encoder to record streams as they are +* [StreamRecorder] fixed encoder choose to not include plugins that are not found +* [StreamRecorder] updated deprecated lame gstreamer plugin to lamemp3enc + +============================== Version 1.5.5 - March 10, 2010 ============================== diff -Nru banshee-community-extensions-1.5.5/po/POTFILES.in banshee-community-extensions-1.6.0/po/POTFILES.in --- banshee-community-extensions-1.5.5/po/POTFILES.in 2010-03-10 18:14:18.000000000 +0000 +++ banshee-community-extensions-1.6.0/po/POTFILES.in 2010-03-31 19:37:31.000000000 +0100 @@ -2,11 +2,11 @@ # Please keep this file in alphabetical order; run ./sort-potfiles # after adding files here. [encoding: UTF-8] - src/AlarmClock/Banshee.AlarmClock/AlarmClockService.cs src/AlarmClock/Banshee.AlarmClock/AlarmConfigDialog.cs src/AlarmClock/Banshee.AlarmClock/ConfigurationDialog.cs src/AlarmClock/Banshee.AlarmClock/SleepTimerConfigDialog.cs +src/AppIndicator/Banshee.AppIndicator/AppIndicatorService.cs src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowContents.cs src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowSchemas.cs src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowService.cs @@ -27,6 +27,7 @@ src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsWindow.cs src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsDownloadJob.cs src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsService.cs +src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsWebSource.cs src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs src/Mirage/Banshee.Mirage/AnalyzeLibraryJob.cs src/Mirage/Banshee.Mirage/DistanceCalculator.cs diff -Nru banshee-community-extensions-1.5.5/README banshee-community-extensions-1.6.0/README --- banshee-community-extensions-1.5.5/README 2010-03-10 18:01:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/README 2010-03-31 19:37:31.000000000 +0100 @@ -35,6 +35,10 @@ Banshee 1.5.4 and its devel packages are required. Some extensions have specific requirements. +AppIndicator + appindicator-sharp + notify-sharp + ClutterFlow clutter-sharp clutter-gtk-sharp diff -Nru banshee-community-extensions-1.5.5/src/AlarmClock/Banshee.AlarmClock/AlarmClockService.cs banshee-community-extensions-1.6.0/src/AlarmClock/Banshee.AlarmClock/AlarmClockService.cs --- banshee-community-extensions-1.5.5/src/AlarmClock/Banshee.AlarmClock/AlarmClockService.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/AlarmClock/Banshee.AlarmClock/AlarmClockService.cs 2010-03-26 22:37:09.000000000 +0000 @@ -30,7 +30,7 @@ using System; using System.Threading; using Gtk; -using Mono.Unix; +using Mono.Addins; using Hyena; using Banshee.Base; @@ -68,20 +68,20 @@ actions.Add (new ActionEntry [] { new ActionEntry ("AlarmClockAction", null, - Catalog.GetString ("Alarm Clock"), null, + AddinManager.CurrentLocalizer.GetString ("Alarm Clock"), null, null, null), new ActionEntry ("SetSleepTimerAction", null, - Catalog.GetString ("Sleep Timer..."), null, - Catalog.GetString ("Set the sleep timer value"), OnSetSleepTimer), + AddinManager.CurrentLocalizer.GetString ("Sleep Timer..."), null, + AddinManager.CurrentLocalizer.GetString ("Set the sleep timer value"), OnSetSleepTimer), new ActionEntry ("SetAlarmAction", null, - Catalog.GetString ("Alarm..."), null, - Catalog.GetString ("Set the alarm time"), OnSetAlarm), + AddinManager.CurrentLocalizer.GetString ("Alarm..."), null, + AddinManager.CurrentLocalizer.GetString ("Set the alarm time"), OnSetAlarm), new ActionEntry ("AlarmClockConfigureAction", Stock.Properties, - Catalog.GetString ("_Configure..."), null, - Catalog.GetString ("Configure the Alarm Clock plugin"), OnConfigure) + AddinManager.CurrentLocalizer.GetString ("_Configure..."), null, + AddinManager.CurrentLocalizer.GetString ("Configure the Alarm Clock plugin"), OnConfigure) }); action_service.UIManager.InsertActionGroup (actions, 0); diff -Nru banshee-community-extensions-1.5.5/src/AlarmClock/Banshee.AlarmClock/AlarmConfigDialog.cs banshee-community-extensions-1.6.0/src/AlarmClock/Banshee.AlarmClock/AlarmConfigDialog.cs --- banshee-community-extensions-1.5.5/src/AlarmClock/Banshee.AlarmClock/AlarmConfigDialog.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/AlarmClock/Banshee.AlarmClock/AlarmConfigDialog.cs 2010-03-26 22:37:09.000000000 +0000 @@ -29,7 +29,7 @@ using System; using Gtk; -using Mono.Unix; +using Mono.Addins; namespace Banshee.AlarmClock { @@ -59,10 +59,10 @@ spbMinute = new SpinButton (0, 59, 1); spbMinute.WidthChars = 2; - isEnabled = new CheckButton (Catalog.GetString ("Enable Alarm")); + isEnabled = new CheckButton (AddinManager.CurrentLocalizer.GetString ("Enable Alarm")); HBox time_box = new HBox (); - time_box.PackStart (new Label (Catalog.GetString ("Set Time: "))); + time_box.PackStart (new Label (AddinManager.CurrentLocalizer.GetString ("Set Time: "))); time_box.PackStart (spbHour); time_box.PackStart (new Label (" : ")); time_box.PackStart (spbMinute); diff -Nru banshee-community-extensions-1.5.5/src/AlarmClock/Banshee.AlarmClock/ConfigurationDialog.cs banshee-community-extensions-1.6.0/src/AlarmClock/Banshee.AlarmClock/ConfigurationDialog.cs --- banshee-community-extensions-1.5.5/src/AlarmClock/Banshee.AlarmClock/ConfigurationDialog.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/AlarmClock/Banshee.AlarmClock/ConfigurationDialog.cs 2010-03-26 22:37:09.000000000 +0000 @@ -29,7 +29,7 @@ using System; using Gtk; -using Mono.Unix; +using Mono.Addins; namespace Banshee.AlarmClock { @@ -46,7 +46,7 @@ { this.plugin = plugin; - Title = Catalog.GetString ("Alarm Clock configuration"); + Title = AddinManager.CurrentLocalizer.GetString ("Alarm Clock configuration"); HasSeparator = false; BorderWidth = 5; @@ -62,23 +62,23 @@ VBox fade_big_box = new VBox (); VBox fade_start_box = new VBox (); - fade_start_box.PackEnd (new Label (Catalog.GetString ("Start"))); + fade_start_box.PackEnd (new Label (AddinManager.CurrentLocalizer.GetString ("Start"))); fade_start_box.PackStart (fade_start, false, false, 3); VBox fade_end_box = new VBox (); - fade_end_box.PackEnd (new Label (Catalog.GetString ("End"))); + fade_end_box.PackEnd (new Label (AddinManager.CurrentLocalizer.GetString ("End"))); fade_end_box.PackStart (fade_end, false, false, 3); HBox fade_box_group = new HBox (); fade_box_group.PackStart (fade_start_box); fade_box_group.PackStart (fade_end_box); - Label volume_label = new Label (Catalog.GetString ("Volume")); + Label volume_label = new Label (AddinManager.CurrentLocalizer.GetString ("Volume")); volume_label.UseMarkup = true; fade_big_box.PackStart (volume_label, false, true, 3); fade_big_box.PackStart (fade_box_group); - Label duration_label = new Label (Catalog.GetString ("Duration:")); - Label duration_seconds_label = new Label (Catalog.GetString (" (seconds)")); + Label duration_label = new Label (AddinManager.CurrentLocalizer.GetString ("Duration:")); + Label duration_seconds_label = new Label (AddinManager.CurrentLocalizer.GetString (" (seconds)")); duration_label.UseMarkup = true; duration_seconds_label.UseMarkup = true; HBox duration_box = new HBox (); @@ -87,16 +87,16 @@ duration_box.PackStart (duration_seconds_label, false, true, 3); fade_big_box.PackStart (duration_box); - Frame alarm_fade_frame = new Frame (Catalog.GetString ("Fade-In Adjustment")); + Frame alarm_fade_frame = new Frame (AddinManager.CurrentLocalizer.GetString ("Fade-In Adjustment")); alarm_fade_frame.Add (fade_big_box); alarm_fade_frame.ShowAll (); HBox command_box = new HBox (); - command_box.PackStart (new Label (Catalog.GetString ("Command:")), false, false, 3); + command_box.PackStart (new Label (AddinManager.CurrentLocalizer.GetString ("Command:")), false, false, 3); command_entry = new Entry (); command_box.PackStart (command_entry, true, true, 3); - Frame alarm_misc_frame = new Frame (Catalog.GetString ("Command To Execute:")); + Frame alarm_misc_frame = new Frame (AddinManager.CurrentLocalizer.GetString ("Command To Execute:")); alarm_misc_frame.Add (command_box); alarm_misc_frame.ShowAll (); diff -Nru banshee-community-extensions-1.5.5/src/AlarmClock/Banshee.AlarmClock/SleepTimerConfigDialog.cs banshee-community-extensions-1.6.0/src/AlarmClock/Banshee.AlarmClock/SleepTimerConfigDialog.cs --- banshee-community-extensions-1.5.5/src/AlarmClock/Banshee.AlarmClock/SleepTimerConfigDialog.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/AlarmClock/Banshee.AlarmClock/SleepTimerConfigDialog.cs 2010-03-26 22:37:09.000000000 +0000 @@ -29,7 +29,7 @@ using System; using Gtk; -using Mono.Unix; +using Mono.Addins; namespace Banshee.AlarmClock { @@ -44,7 +44,7 @@ { this.plugin = plugin; - Title = Catalog.GetString ("Sleep Timer"); + Title = AddinManager.CurrentLocalizer.GetString ("Sleep Timer"); WidthRequest = 250; HeightRequest = 150; VBox.Spacing = 10; @@ -64,9 +64,9 @@ sleepHour.WidthChars = 2; sleepMin.WidthChars = 2; - Label prefix = new Label (Catalog.GetString ("Sleep Timer :")); + Label prefix = new Label (AddinManager.CurrentLocalizer.GetString ("Sleep Timer :")); Label separator = new Label (":"); - Label comment = new Label (Catalog.GetString ("(set to 0:00 to disable)")); + Label comment = new Label (AddinManager.CurrentLocalizer.GetString ("(set to 0:00 to disable)")); comment.UseMarkup = true; Button OK = new Button (Gtk.Stock.Ok); diff -Nru banshee-community-extensions-1.5.5/src/AlarmClock/Makefile.in banshee-community-extensions-1.6.0/src/AlarmClock/Makefile.in --- banshee-community-extensions-1.5.5/src/AlarmClock/Makefile.in 2010-03-11 06:03:34.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/AlarmClock/Makefile.in 2010-03-31 19:47:51.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/AlarmClock ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/AppIndicator/AppIndicator.addin.xml banshee-community-extensions-1.6.0/src/AppIndicator/AppIndicator.addin.xml --- banshee-community-extensions-1.5.5/src/AppIndicator/AppIndicator.addin.xml 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/AppIndicator/AppIndicator.addin.xml 2010-03-31 19:37:31.000000000 +0100 @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + diff -Nru banshee-community-extensions-1.5.5/src/AppIndicator/Banshee.AppIndicator/AppIndicatorService.cs banshee-community-extensions-1.6.0/src/AppIndicator/Banshee.AppIndicator/AppIndicatorService.cs --- banshee-community-extensions-1.5.5/src/AppIndicator/Banshee.AppIndicator/AppIndicatorService.cs 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/AppIndicator/Banshee.AppIndicator/AppIndicatorService.cs 2010-03-31 19:37:31.000000000 +0100 @@ -0,0 +1,431 @@ +// +// AppIndicatorService.cs +// +// Authors: +// Sense Hofstede +// Aaron Bockover +// Sebastian Dröge +// Alexander Hixon +// +// Copyright (C) 2010 Sense Hofstede +// Copyright (C) 2005-2008 Novell, Inc. +// Copyright (C) 2006-2007 Sebastian Dröge +// +// Permission is hereby granted, free of charge, to any person obtaining +// a copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to +// permit persons to whom the Software is furnished to do so, subject to +// the following conditions: +// +// The above copyright notice and this permission notice shall be +// included in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +// + +using System; +using Mono.Addins; + +using AppIndicator; +using Gtk; +using Notifications; + +using Banshee.Base; +using Banshee.Gui; +using Banshee.ServiceStack; +using Banshee.Collection; +using Banshee.Collection.Gui; +using Banshee.Configuration; +using Banshee.MediaEngine; + +namespace Banshee.AppIndicator +{ + public class AppIndicatorService : IExtensionService + { + private BansheeActionGroup actions; + private ArtworkManager artwork_manager_service; + private Notification current_nf; + private TrackInfo current_track; + private bool disposed; + private GtkElementsService elements_service; + private ApplicationIndicator indicator; + private InterfaceActionService interface_action_service; + private string notify_last_artist; + private string notify_last_title; + private bool show_notifications; + private int ui_manager_id; + + private const int icon_size = 42; + + public AppIndicatorService () + { + } + + void IExtensionService.Initialize () + { + elements_service = ServiceManager.Get (); + interface_action_service = ServiceManager.Get (); + + if (!ServiceStartup ()) { + ServiceManager.ServiceStarted += OnServiceStarted; + } + } + + private void OnServiceStarted (ServiceStartedArgs args) + { + if (args.Service is Banshee.Gui.InterfaceActionService) { + interface_action_service = (InterfaceActionService)args.Service; + } else if (args.Service is GtkElementsService) { + elements_service = (GtkElementsService)args.Service; + } + + ServiceStartup (); + } + + private bool ServiceStartup () + { + if (elements_service == null || interface_action_service == null) { + return false; + } + + Initialize (); + + ServiceManager.ServiceStarted -= OnServiceStarted; + + return true; + } + + private void Initialize () + { + interface_action_service.GlobalActions.Add (new ActionEntry [] { + new ActionEntry ("CloseAction", Stock.Close, + AddinManager.CurrentLocalizer.GetString ("_Close"), "W", + AddinManager.CurrentLocalizer.GetString ("Close"), CloseWindow) + }); + + actions = new BansheeActionGroup (interface_action_service, "AppIndicator"); + actions.Add (new ToggleActionEntry [] { + new ToggleActionEntry ("ShowHideAction", null, + AddinManager.CurrentLocalizer.GetString ("_Show Banshee"), null, + AddinManager.CurrentLocalizer.GetString ("Show the Banshee main window"), ToggleShowHide, PrimaryWindowVisible) + }); + + interface_action_service.AddActionGroup (actions); + ui_manager_id = (int)interface_action_service.UIManager.AddUiFromResource ("AppIndicatorMenu.xml"); + + ServiceManager.PlayerEngine.ConnectEvent (OnPlayerEvent, + PlayerEvent.StartOfStream | + PlayerEvent.EndOfStream | + PlayerEvent.TrackInfoUpdated | + PlayerEvent.StateChange); + + artwork_manager_service = ServiceManager.Get (); + artwork_manager_service.AddCachedSize (icon_size); + + // Forcefully load this + show_notifications = ShowNotifications; + + DrawAppIndicator (); + } + + public void Dispose () + { + if (disposed) { + return; + } + + if (current_nf != null) { + try { + current_nf.Close (); + } catch {} + } + + // Hide the AppIndicator before disposing + indicator.Status = Status.Passive; + indicator.Dispose(); + indicator = null; + + ServiceManager.PlayerEngine.DisconnectEvent (OnPlayerEvent); + + elements_service.PrimaryWindowClose = null; + + Gtk.Action close_action = interface_action_service.GlobalActions["CloseAction"]; + if (close_action != null) { + interface_action_service.GlobalActions.Remove (close_action); + } + + if (ui_manager_id >= 0) { + interface_action_service.RemoveActionGroup ("AppIndicator"); + interface_action_service.UIManager.RemoveUi ((uint)ui_manager_id); + ui_manager_id = -1; + } + + elements_service = null; + interface_action_service = null; + + disposed = true; + } + + private bool OnPrimaryWindowClose () + { + CloseWindow (null, null); + return true; + } + + private void CloseWindow (object o, EventArgs args) + { + try { + if (NotifyOnCloseSchema.Get ()) { + Notification nf = new Notification ( + AddinManager.CurrentLocalizer.GetString ("Still Running"), + AddinManager.CurrentLocalizer.GetString ( + "Banshee was closed to the notification area. " + + "Use the Quit option to end your session."), + "media-player-banshee"); + nf.Urgency = Urgency.Low; + nf.Show (); + + NotifyOnCloseSchema.Set (false); + } + } catch (Exception e) { + Hyena.Log.Warning ("Error while trying to notify of window close.", e.Message, false); + } + + PrimaryWindowVisible = false; + } + + private bool DrawAppIndicator () + { + try { + indicator = new ApplicationIndicator ("banshee", + Banshee.ServiceStack.Application.IconName, + Category.ApplicationStatus); + + // Load the menu + Menu menu = (Menu) interface_action_service.UIManager.GetWidget("/AppIndicatorTrayMenu"); + menu.Show (); + + indicator.Menu = menu; + + // Show the tray icon + indicator.Status = Status.Active; + + if (!QuitOnCloseSchema.Get ()) { + RegisterCloseHandler (); + } + } catch (Exception e) { + Hyena.Log.Warning ("Error while trying to create the Application Indicator.", e.Message, false); + return false; + } + + return true; + } + + private void OnPlayerEvent (PlayerEventArgs args) + { + switch (args.Event) { + case PlayerEvent.StartOfStream: + if (current_nf != null) { + current_nf.Close (); + current_nf = null; + } + current_track = ServiceManager.PlayerEngine.CurrentTrack; + ShowTrackNotification (); + break; + case PlayerEvent.TrackInfoUpdated: + current_track = ServiceManager.PlayerEngine.CurrentTrack; + ShowTrackNotification (); + break; + case PlayerEvent.EndOfStream: + if (current_nf != null) { + current_nf.Close (); + current_nf = null; + } + current_track = null; + break; + } + } + + private string GetByFrom (string artist, string display_artist, string album, string display_album) + { + bool has_artist = !String.IsNullOrEmpty (artist); + bool has_album = !String.IsNullOrEmpty (album); + + string markup = null; + if (has_artist && has_album) { + // Translators: {0} and {1} are Artist Name and + // Album Title, respectively; + // e.g. 'by Parkway Drive from Killing with a Smile' + markup = String.Format (AddinManager.CurrentLocalizer.GetString ("by '{0}' from '{1}'"), + display_artist, display_album); + } else if (has_album) { + // Translators: {0} is for Album Title; + // e.g. 'from Killing with a Smile' + markup = String.Format (AddinManager.CurrentLocalizer.GetString ("from '{0}'"), + display_album); + } else { + // Translators: {0} is for Artist Name; + // e.g. 'by Parkway Drive' + markup = String.Format(AddinManager.CurrentLocalizer.GetString ("by '{0}'"), + display_artist); + } + return markup; + } + + private void ToggleShowHide (object o, EventArgs args) + { + PrimaryWindowVisible = ((ToggleAction)actions["ShowHideAction"]).Active; + } + + private void ShowTrackNotification () + { + // This has to happen before the next if, otherwise the last_* members aren't set correctly. + if (current_track == null || (notify_last_title == current_track.DisplayTrackTitle + && notify_last_artist == current_track.DisplayArtistName)) { + return; + } + + notify_last_title = current_track.DisplayTrackTitle; + notify_last_artist = current_track.DisplayArtistName; + + if (!show_notifications) { + return; + } + + foreach (var window in elements_service.ContentWindows) { + if (window.HasToplevelFocus) { + return; + } + } + + string message = GetByFrom ( + current_track.ArtistName, current_track.DisplayArtistName, + current_track.AlbumTitle, current_track.DisplayAlbumTitle); + + Gdk.Pixbuf image = null; + + if (artwork_manager_service != null) { + image = artwork_manager_service.LookupPixbuf (current_track.ArtworkId); + } + + if (image == null) { + image = IconThemeUtils.LoadIcon (48, "audio-x-generic"); + if (image != null) { + image.ScaleSimple (icon_size, icon_size, Gdk.InterpType.Bilinear); + } + } + + try { + if (current_nf == null) { + current_nf = new Notification (current_track.DisplayTrackTitle, message, image); + } else { + current_nf.Summary = current_track.DisplayTrackTitle; + current_nf.Body = message; + current_nf.Icon = image; + } + + current_nf.Urgency = Urgency.Low; + current_nf.Timeout = 4500; + + current_nf.Show (); + + } catch (Exception e) { + Hyena.Log.Warning ("Cannot show notification", e.Message, false); + } + } + + private void RegisterCloseHandler () + { + if (elements_service.PrimaryWindowClose == null) { + elements_service.PrimaryWindowClose = OnPrimaryWindowClose; + } + } + + private void UnregisterCloseHandler () + { + if (elements_service.PrimaryWindowClose != null) { + elements_service.PrimaryWindowClose = null; + } + } + + public bool PrimaryWindowVisible { + get { + return elements_service.PrimaryWindow.Visible; + } + + set { + elements_service.PrimaryWindow.SetVisible(value); + ((ToggleAction)actions["ShowHideAction"]).Active = value; + } + } + + public bool ShowNotifications { + get { + show_notifications = ShowNotificationsSchema.Get (); + return show_notifications; + } + + set { + ShowNotificationsSchema.Set (value); + show_notifications = value; + } + } + + public bool QuitOnClose { + get { + return QuitOnCloseSchema.Get (); + } + + set { + QuitOnCloseSchema.Set (value); + if (value) { + UnregisterCloseHandler (); + } else { + RegisterCloseHandler (); + } + } + } + + string IService.ServiceName { + get { return "AppIndicatorService"; } + } + + public static readonly SchemaEntry EnabledSchema = new SchemaEntry ( + "plugins.app_indicator", "enabled", + true, + "Plugin enabled", + "Notification area plugin enabled" + ); + + public static readonly SchemaEntry ShowNotificationsSchema = new SchemaEntry ( + "plugins.app_indicator", "show_notifications", + true, + "Show notifications", + "Show information notifications when item starts playing" + ); + + public static readonly SchemaEntry NotifyOnCloseSchema = new SchemaEntry ( + "plugins.app_indicator", "notify_on_close", + true, + "Show a notification when closing main window", + "When the main window is closed, show a notification stating this has happened." + ); + + public static readonly SchemaEntry QuitOnCloseSchema = new SchemaEntry ( + "plugins.app_indicator", "quit_on_close", + false, + "Quit on close", + "Quit instead of hide to notification area on close" + ); + + + } +} diff -Nru banshee-community-extensions-1.5.5/src/AppIndicator/Makefile.am banshee-community-extensions-1.6.0/src/AppIndicator/Makefile.am --- banshee-community-extensions-1.5.5/src/AppIndicator/Makefile.am 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/AppIndicator/Makefile.am 2010-03-31 19:37:31.000000000 +0100 @@ -0,0 +1,14 @@ +ASSEMBLY = Banshee.AppIndicator +LINK = $(BANSHEE_LIBS) $(APPINDICATORSHARP_LIBS) $(NOTIFYSHARP_LIBS) + +SOURCES = Banshee.AppIndicator/AppIndicatorService.cs + +RESOURCES = \ + AppIndicator.addin.xml \ + Resources/AppIndicatorMenu.xml + +if ENABLE_APPINDICATOR +include $(top_srcdir)/build/build.mk +else +EXTRA_DIST = $(SOURCES) $(RESOURCES) +endif diff -Nru banshee-community-extensions-1.5.5/src/AppIndicator/Makefile.in banshee-community-extensions-1.6.0/src/AppIndicator/Makefile.in --- banshee-community-extensions-1.5.5/src/AppIndicator/Makefile.in 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/AppIndicator/Makefile.in 2010-03-31 19:47:51.000000000 +0100 @@ -0,0 +1,574 @@ +# Makefile.in generated by automake 1.10.1 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/build/build.environment.mk \ + $(top_srcdir)/build/build.mk \ + $(top_srcdir)/build/build.rules.mk +@ENABLE_APPINDICATOR_TRUE@@ENABLE_TESTS_TRUE@am__append_1 = " $(NUNIT_LIBS) $(MONO_NUNIT_LIBS)" +subdir = src/AppIndicator +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ + $(top_srcdir)/build/m4/extensions/awn.m4 \ + $(top_srcdir)/build/m4/extensions/banshee.m4 \ + $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ + $(top_srcdir)/build/m4/extensions/common.m4 \ + $(top_srcdir)/build/m4/extensions/coverwallpaper.m4 \ + $(top_srcdir)/build/m4/extensions/lcd.m4 \ + $(top_srcdir)/build/m4/extensions/lirc.m4 \ + $(top_srcdir)/build/m4/extensions/liveradio.m4 \ + $(top_srcdir)/build/m4/extensions/lyrics.m4 \ + $(top_srcdir)/build/m4/extensions/magnatune.m4 \ + $(top_srcdir)/build/m4/extensions/mirage.m4 \ + $(top_srcdir)/build/m4/extensions/radiostationfetcher.m4 \ + $(top_srcdir)/build/m4/extensions/streamrecorder.m4 \ + $(top_srcdir)/build/m4/extensions/telepathy.m4 \ + $(top_srcdir)/build/m4/extensions/ubuntuonemusicstore.m4 \ + $(top_srcdir)/build/m4/shave/shave.m4 \ + $(top_srcdir)/build/m4/shamrock/expansions.m4 \ + $(top_srcdir)/build/m4/shamrock/i18n.m4 \ + $(top_srcdir)/build/m4/shamrock/mono.m4 \ + $(top_srcdir)/build/m4/shamrock/nunit.m4 \ + $(top_srcdir)/build/m4/shamrock/programs.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +am__installdirs = "$(DESTDIR)$(moduledir)" +moduleSCRIPT_INSTALL = $(INSTALL_SCRIPT) +SCRIPTS = $(module_SCRIPTS) +DIST_SOURCES = +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ACLOCAL_AMFLAGS = @ACLOCAL_AMFLAGS@ +ALL_LINGUAS = @ALL_LINGUAS@ +AMTAR = @AMTAR@ +AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BANSHEE_155_CFLAGS = @BANSHEE_155_CFLAGS@ +BANSHEE_155_LIBS = @BANSHEE_155_LIBS@ +BANSHEE_CFLAGS = @BANSHEE_CFLAGS@ +BANSHEE_LIBS = @BANSHEE_LIBS@ +BANSHEE_NOWPLAYING_CFLAGS = @BANSHEE_NOWPLAYING_CFLAGS@ +BANSHEE_NOWPLAYING_LIBS = @BANSHEE_NOWPLAYING_LIBS@ +BUILD_HOST_CPU = @BUILD_HOST_CPU@ +BUILD_HOST_OS = @BUILD_HOST_OS@ +BUILD_TIME = @BUILD_TIME@ +BUILD_VENDOR_ID = @BUILD_VENDOR_ID@ +CATALOGS = @CATALOGS@ +CATOBJEXT = @CATOBJEXT@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CLUTTER_SHARP_CFLAGS = @CLUTTER_SHARP_CFLAGS@ +CLUTTER_SHARP_LIBS = @CLUTTER_SHARP_LIBS@ +CONFIG_STATUS_DEPENDENCIES = @CONFIG_STATUS_DEPENDENCIES@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CYGPATH_W = @CYGPATH_W@ +DATADIRNAME = @DATADIRNAME@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +ENABLE_RELEASE = @ENABLE_RELEASE@ +EXEEXT = @EXEEXT@ +EXTENSION_DIR = @EXTENSION_DIR@ +F77 = @F77@ +FC = @FC@ +FFTW3F_CFLAGS = @FFTW3F_CFLAGS@ +FFTW3F_LIBS = @FFTW3F_LIBS@ +FGREP = @FGREP@ +GCONFSHARP_CFLAGS = @GCONFSHARP_CFLAGS@ +GCONFSHARP_LIBS = @GCONFSHARP_LIBS@ +GCONFTOOL = @GCONFTOOL@ +GCONF_SCHEMA_CONFIG_SOURCE = @GCONF_SCHEMA_CONFIG_SOURCE@ +GCONF_SCHEMA_FILE_DIR = @GCONF_SCHEMA_FILE_DIR@ +GCONF_SHARP_20_CFLAGS = @GCONF_SHARP_20_CFLAGS@ +GCONF_SHARP_20_LIBS = @GCONF_SHARP_20_LIBS@ +GETTEXT_PACKAGE = @GETTEXT_PACKAGE@ +GLIB_CFLAGS = @GLIB_CFLAGS@ +GLIB_LIBS = @GLIB_LIBS@ +GMCS_FLAGS = @GMCS_FLAGS@ +GMOFILES = @GMOFILES@ +GMSGFMT = @GMSGFMT@ +GREP = @GREP@ +GSTREAMER_CFLAGS = @GSTREAMER_CFLAGS@ +GSTREAMER_LIBS = @GSTREAMER_LIBS@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +INSTOBJEXT = @INSTOBJEXT@ +INTLLIBS = @INTLLIBS@ +INTLTOOL_CAVES_RULE = @INTLTOOL_CAVES_RULE@ +INTLTOOL_DESKTOP_RULE = @INTLTOOL_DESKTOP_RULE@ +INTLTOOL_DIRECTORY_RULE = @INTLTOOL_DIRECTORY_RULE@ +INTLTOOL_EXTRACT = @INTLTOOL_EXTRACT@ +INTLTOOL_KBD_RULE = @INTLTOOL_KBD_RULE@ +INTLTOOL_KEYS_RULE = @INTLTOOL_KEYS_RULE@ +INTLTOOL_MERGE = @INTLTOOL_MERGE@ +INTLTOOL_OAF_RULE = @INTLTOOL_OAF_RULE@ +INTLTOOL_PERL = @INTLTOOL_PERL@ +INTLTOOL_POLICY_RULE = @INTLTOOL_POLICY_RULE@ +INTLTOOL_PONG_RULE = @INTLTOOL_PONG_RULE@ +INTLTOOL_PROP_RULE = @INTLTOOL_PROP_RULE@ +INTLTOOL_SCHEMAS_RULE = @INTLTOOL_SCHEMAS_RULE@ +INTLTOOL_SERVER_RULE = @INTLTOOL_SERVER_RULE@ +INTLTOOL_SERVICE_RULE = @INTLTOOL_SERVICE_RULE@ +INTLTOOL_SHEET_RULE = @INTLTOOL_SHEET_RULE@ +INTLTOOL_SOUNDLIST_RULE = @INTLTOOL_SOUNDLIST_RULE@ +INTLTOOL_THEME_RULE = @INTLTOOL_THEME_RULE@ +INTLTOOL_UI_RULE = @INTLTOOL_UI_RULE@ +INTLTOOL_UPDATE = @INTLTOOL_UPDATE@ +INTLTOOL_XAM_RULE = @INTLTOOL_XAM_RULE@ +INTLTOOL_XML_NOMERGE_RULE = @INTLTOOL_XML_NOMERGE_RULE@ +INTLTOOL_XML_RULE = @INTLTOOL_XML_RULE@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSAMPLERATE_CFLAGS = @LIBSAMPLERATE_CFLAGS@ +LIBSAMPLERATE_LIBS = @LIBSAMPLERATE_LIBS@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +MAINT = @MAINT@ +MAKEFLAGS = @MAKEFLAGS@ +MAKEINFO = @MAKEINFO@ +MCS = @MCS@ +MKDIR_P = @MKDIR_P@ +MONO = @MONO@ +MONO_CFLAGS = @MONO_CFLAGS@ +MONO_LIBS = @MONO_LIBS@ +MONO_MODULE_CFLAGS = @MONO_MODULE_CFLAGS@ +MONO_MODULE_LIBS = @MONO_MODULE_LIBS@ +MSGFMT = @MSGFMT@ +MSGFMT_OPTS = @MSGFMT_OPTS@ +MSGMERGE = @MSGMERGE@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ +NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ +NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ +NUNIT_CFLAGS = @NUNIT_CFLAGS@ +NUNIT_LIBS = @NUNIT_LIBS@ +OBJC = @OBJC@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +POFILES = @POFILES@ +POSUB = @POSUB@ +PO_IN_DATADIR_FALSE = @PO_IN_DATADIR_FALSE@ +PO_IN_DATADIR_TRUE = @PO_IN_DATADIR_TRUE@ +Q = @Q@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +UBUNTUONESHARP_CFLAGS = @UBUNTUONESHARP_CFLAGS@ +UBUNTUONESHARP_LIBS = @UBUNTUONESHARP_LIBS@ +USE_NLS = @USE_NLS@ +V = @V@ +VERSION = @VERSION@ +WEBKIT_SHARP_CFLAGS = @WEBKIT_SHARP_CFLAGS@ +WEBKIT_SHARP_LIBS = @WEBKIT_SHARP_LIBS@ +XGETTEXT = @XGETTEXT@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +expanded_bindir = @expanded_bindir@ +expanded_datadir = @expanded_datadir@ +expanded_libdir = @expanded_libdir@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +lt_ECHO = @lt_ECHO@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +shavedir = @shavedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +ASSEMBLY = Banshee.AppIndicator +LINK = $(BANSHEE_LIBS) $(APPINDICATORSHARP_LIBS) $(NOTIFYSHARP_LIBS) \ + $(am__append_1) +SOURCES = Banshee.AppIndicator/AppIndicatorService.cs +RESOURCES = \ + AppIndicator.addin.xml \ + Resources/AppIndicatorMenu.xml + + +# Initializers +@ENABLE_APPINDICATOR_TRUE@MONO_BASE_PATH = +@ENABLE_APPINDICATOR_TRUE@MONO_ADDINS_PATH = + +# All extensions are libraries +@ENABLE_APPINDICATOR_TRUE@TARGET = library +@ENABLE_APPINDICATOR_TRUE@DIR_BIN = $(top_builddir)/bin + +# Install Paths +@ENABLE_APPINDICATOR_TRUE@DEFAULT_INSTALL_DIR = $(pkglibdir) +@ENABLE_APPINDICATOR_TRUE@EXTENSIONS_INSTALL_DIR = $(DEFAULT_INSTALL_DIR)/Extensions +@ENABLE_APPINDICATOR_TRUE@UNIQUE_FILTER_PIPE = tr [:space:] \\n | sort | uniq +@ENABLE_APPINDICATOR_TRUE@BUILD_DATA_DIR = $(top_builddir)/bin/share/$(PACKAGE) +@ENABLE_APPINDICATOR_TRUE@SOURCES_BUILD = $(addprefix $(srcdir)/, \ +@ENABLE_APPINDICATOR_TRUE@ $(SOURCES)) \ +@ENABLE_APPINDICATOR_TRUE@ $(top_srcdir)/src/AssemblyInfo.cs +@ENABLE_APPINDICATOR_TRUE@RESOURCES_EXPANDED = $(addprefix $(srcdir)/, $(RESOURCES)) +@ENABLE_APPINDICATOR_TRUE@RESOURCES_BUILD = $(foreach resource, $(RESOURCES_EXPANDED), \ +@ENABLE_APPINDICATOR_TRUE@ -resource:$(resource),$(notdir $(resource))) + +@ENABLE_APPINDICATOR_TRUE@INSTALL_ICONS = $(top_srcdir)/build/private-icon-theme-installer "$(mkinstalldirs)" "$(INSTALL_DATA)" +@ENABLE_APPINDICATOR_TRUE@THEME_ICONS_SOURCE = $(wildcard $(srcdir)/ThemeIcons/*/*/*.png) $(wildcard $(srcdir)/ThemeIcons/scalable/*/*.svg) +@ENABLE_APPINDICATOR_TRUE@THEME_ICONS_RELATIVE = $(subst $(srcdir)/ThemeIcons/, , $(THEME_ICONS_SOURCE)) +@ENABLE_APPINDICATOR_TRUE@ASSEMBLY_EXTENSION = $(strip $(patsubst library, dll, $(TARGET))) +@ENABLE_APPINDICATOR_TRUE@ASSEMBLY_FILE = $(top_builddir)/bin/$(ASSEMBLY).$(ASSEMBLY_EXTENSION) +@ENABLE_APPINDICATOR_TRUE@INSTALL_DIR_RESOLVED = $(firstword $(subst , $(DEFAULT_INSTALL_DIR), $(INSTALL_DIR))) +@ENABLE_APPINDICATOR_TRUE@@ENABLE_TESTS_TRUE@ENABLE_TESTS_FLAG = "-define:ENABLE_TESTS" +@ENABLE_APPINDICATOR_TRUE@FILTERED_LINK = $(shell echo "$(LINK)" | $(UNIQUE_FILTER_PIPE)) +@ENABLE_APPINDICATOR_TRUE@DEP_LINK = $(shell echo "$(LINK)" | $(UNIQUE_FILTER_PIPE) | sed s,-r:,,g | grep '$(top_builddir)/bin/') +@ENABLE_APPINDICATOR_TRUE@OUTPUT_FILES = \ +@ENABLE_APPINDICATOR_TRUE@ $(ASSEMBLY_FILE) \ +@ENABLE_APPINDICATOR_TRUE@ $(ASSEMBLY_FILE).mdb + +@ENABLE_APPINDICATOR_TRUE@moduledir = $(EXTENSION_DIR) +@ENABLE_APPINDICATOR_TRUE@module_SCRIPTS = $(OUTPUT_FILES) +@ENABLE_APPINDICATOR_FALSE@EXTRA_DIST = $(SOURCES) $(RESOURCES) +@ENABLE_APPINDICATOR_TRUE@EXTRA_DIST = $(SOURCES_BUILD) $(RESOURCES_EXPANDED) $(THEME_ICONS_SOURCE) +@ENABLE_APPINDICATOR_TRUE@CLEANFILES = $(OUTPUT_FILES) +@ENABLE_APPINDICATOR_TRUE@DISTCLEANFILES = *.pidb +@ENABLE_APPINDICATOR_TRUE@MAINTAINERCLEANFILES = Makefile.in +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/build/build.mk $(top_srcdir)/build/build.environment.mk $(top_srcdir)/build/build.rules.mk $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ + && exit 0; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/AppIndicator/Makefile'; \ + cd $(top_srcdir) && \ + $(AUTOMAKE) --foreign src/AppIndicator/Makefile +.PRECIOUS: Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +install-moduleSCRIPTS: $(module_SCRIPTS) + @$(NORMAL_INSTALL) + test -z "$(moduledir)" || $(MKDIR_P) "$(DESTDIR)$(moduledir)" + @list='$(module_SCRIPTS)'; for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f $$d$$p; then \ + f=`echo "$$p" | sed 's|^.*/||;$(transform)'`; \ + echo " $(moduleSCRIPT_INSTALL) '$$d$$p' '$(DESTDIR)$(moduledir)/$$f'"; \ + $(moduleSCRIPT_INSTALL) "$$d$$p" "$(DESTDIR)$(moduledir)/$$f"; \ + else :; fi; \ + done + +uninstall-moduleSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(module_SCRIPTS)'; for p in $$list; do \ + f=`echo "$$p" | sed 's|^.*/||;$(transform)'`; \ + echo " rm -f '$(DESTDIR)$(moduledir)/$$f'"; \ + rm -f "$(DESTDIR)$(moduledir)/$$f"; \ + done + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +tags: TAGS +TAGS: + +ctags: CTAGS +CTAGS: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ + fi; \ + cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ + else \ + test -f $(distdir)/$$file \ + || cp -p $$d/$$file $(distdir)/$$file \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(SCRIPTS) +installdirs: + for dir in "$(DESTDIR)$(moduledir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + `test -z '$(STRIP)' || \ + echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install +mostlyclean-generic: + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." + -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) +@ENABLE_APPINDICATOR_FALSE@uninstall-local: +@ENABLE_APPINDICATOR_FALSE@install-data-local: +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +info: info-am + +info-am: + +install-data-am: install-data-local install-moduleSCRIPTS + +install-dvi: install-dvi-am + +install-exec-am: + +install-html: install-html-am + +install-info: install-info-am + +install-man: + +install-pdf: install-pdf-am + +install-ps: install-ps-am + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-local uninstall-moduleSCRIPTS + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + distclean distclean-generic distclean-libtool distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-data-local install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-moduleSCRIPTS install-pdf install-pdf-am install-ps \ + install-ps-am install-strip installcheck installcheck-am \ + installdirs maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am uninstall uninstall-am uninstall-local \ + uninstall-moduleSCRIPTS + + +@ENABLE_APPINDICATOR_TRUE@all: $(ASSEMBLY_FILE) theme-icons + +@ENABLE_APPINDICATOR_TRUE@run: +@ENABLE_APPINDICATOR_TRUE@ @pushd $(top_builddir); \ +@ENABLE_APPINDICATOR_TRUE@ make run \ +@ENABLE_APPINDICATOR_TRUE@ popd; + +@ENABLE_APPINDICATOR_TRUE@build-debug: +@ENABLE_APPINDICATOR_TRUE@ @echo $(DEP_LINK) + +@ENABLE_APPINDICATOR_TRUE@$(ASSEMBLY_FILE).mdb: $(ASSEMBLY_FILE) + +@ENABLE_APPINDICATOR_TRUE@$(ASSEMBLY_FILE): $(SOURCES_BUILD) $(RESOURCES_EXPANDED) $(DEP_LINK) +@ENABLE_APPINDICATOR_TRUE@ @mkdir -p $(top_builddir)/bin +@ENABLE_APPINDICATOR_TRUE@ $(MCS) \ +@ENABLE_APPINDICATOR_TRUE@ $(GMCS_FLAGS) \ +@ENABLE_APPINDICATOR_TRUE@ $(ENABLE_TESTS_FLAG) \ +@ENABLE_APPINDICATOR_TRUE@ $(ASSEMBLY_BUILD_FLAGS) \ +@ENABLE_APPINDICATOR_TRUE@ -debug -target:$(TARGET) -out:$@ \ +@ENABLE_APPINDICATOR_TRUE@ $(BUILD_DEFINES) \ +@ENABLE_APPINDICATOR_TRUE@ $(FILTERED_LINK) $(RESOURCES_BUILD) $(SOURCES_BUILD) +@ENABLE_APPINDICATOR_TRUE@ @if [ -e $(srcdir)/$(notdir $@.config) ]; then \ +@ENABLE_APPINDICATOR_TRUE@ cp $(srcdir)/$(notdir $@.config) $(top_builddir)/bin; \ +@ENABLE_APPINDICATOR_TRUE@ fi; +@ENABLE_APPINDICATOR_TRUE@ @if [ ! -z "$(EXTRA_BUNDLE)" ]; then \ +@ENABLE_APPINDICATOR_TRUE@ cp $(EXTRA_BUNDLE) $(top_builddir)/bin; \ +@ENABLE_APPINDICATOR_TRUE@ fi; + +@ENABLE_APPINDICATOR_TRUE@theme-icons: $(THEME_ICONS_SOURCE) +@ENABLE_APPINDICATOR_TRUE@ @$(INSTALL_ICONS) -il "$(BUILD_DATA_DIR)" "$(srcdir)" $(THEME_ICONS_RELATIVE) + +@ENABLE_APPINDICATOR_TRUE@install-data-local: $(THEME_ICONS_SOURCE) +@ENABLE_APPINDICATOR_TRUE@ @$(INSTALL_ICONS) -i "$(DESTDIR)$(pkgdatadir)" "$(srcdir)" $(THEME_ICONS_RELATIVE) + +@ENABLE_APPINDICATOR_TRUE@uninstall-local: $(THEME_ICONS_SOURCE) +@ENABLE_APPINDICATOR_TRUE@ @$(INSTALL_ICONS) -u "$(DESTDIR)$(pkgdatadir)" "$(srcdir)" $(THEME_ICONS_RELATIVE) +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff -Nru banshee-community-extensions-1.5.5/src/AppIndicator/Resources/AppIndicatorMenu.xml banshee-community-extensions-1.6.0/src/AppIndicator/Resources/AppIndicatorMenu.xml --- banshee-community-extensions-1.5.5/src/AppIndicator/Resources/AppIndicatorMenu.xml 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/AppIndicator/Resources/AppIndicatorMenu.xml 2010-03-31 19:37:31.000000000 +0100 @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff -Nru banshee-community-extensions-1.5.5/src/AssemblyInfo.cs banshee-community-extensions-1.6.0/src/AssemblyInfo.cs --- banshee-community-extensions-1.5.5/src/AssemblyInfo.cs 2010-03-11 06:03:41.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/AssemblyInfo.cs 2010-03-31 19:48:00.000000000 +0100 @@ -1,5 +1,5 @@ using System.Reflection; using System.Runtime.CompilerServices; -[assembly: AssemblyVersion("1.5.5")] +[assembly: AssemblyVersion("1.6.0")] diff -Nru banshee-community-extensions-1.5.5/src/Awn/Makefile.in banshee-community-extensions-1.6.0/src/Awn/Makefile.in --- banshee-community-extensions-1.5.5/src/Awn/Makefile.in 2010-03-11 06:03:34.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Awn/Makefile.in 2010-03-31 19:47:52.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/Awn ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/AlbumLoader.cs banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/AlbumLoader.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/AlbumLoader.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/AlbumLoader.cs 2010-03-31 19:37:31.000000000 +0100 @@ -35,10 +35,97 @@ namespace Banshee.ClutterFlow { - - public abstract class BansheeActorLoader : ActorLoader where TGen : ICacheableItem, new() { + + public interface ISortComparer : IComparer + { + string GetSortLabel (T obj); + } + + public abstract class AlbumComparer : ISortComparer + { + protected virtual string GetTitle (AlbumInfo obj) + { + return (obj.TitleSort ?? obj.Title ?? obj.DisplayTitle ?? ""); + } + + protected virtual string GetArtist (AlbumInfo obj) + { + return (obj.ArtistNameSort ?? obj.ArtistName ?? obj.DisplayArtistName ?? ""); + } + + public abstract int Compare (AlbumInfo x, AlbumInfo y); + public abstract string GetSortLabel (AlbumInfo obj); + } + + public class AlbumAlbumComparer : AlbumComparer + { + + public override string GetSortLabel (AlbumInfo obj) + { + if (obj!=null) { + return obj.TitleSort ?? obj.Title ?? "?"; + } else + return "?"; + } + + public override int Compare (AlbumInfo x, AlbumInfo y) + { + string tx = GetTitle(x) + GetArtist(x); + string ty = GetTitle(y) + GetArtist(y); + return tx.CompareTo(ty); + } + } + public class AlbumArtistComparer : AlbumComparer + { + public override string GetSortLabel (AlbumInfo obj) + { + if (obj!=null) { + return obj.ArtistNameSort ?? obj.ArtistName ?? "?"; + } else + return "?"; + } + + public override int Compare (AlbumInfo x, AlbumInfo y) + { + string tx = GetArtist(x) + GetTitle(x); + string ty = GetArtist(y) + GetTitle(y); + return tx.CompareTo(ty); + } + } + + public enum SortOptions { Artist = 0 , Album = 1 } + + public abstract class BansheeActorLoader : ActorLoader where TGen : ICacheableItem, new() + { + + #region Fields + #pragma warning disable 0067 + public event EventHandler SortingChanged; + #pragma warning restore 0067 + protected void InvokeSortingChanged () + { + ClutterFlowSchemas.SortBy.Set (Enum.GetName(typeof(SortOptions), SortBy)); + if (SortingChanged!=null) SortingChanged (this, EventArgs.Empty); + } + + protected SortOptions sort_by = (SortOptions) Enum.Parse(typeof(SortOptions), ClutterFlowSchemas.SortBy.Get ()); + public virtual SortOptions SortBy { + get { return sort_by; } + set { + if (value!=sort_by) { + sort_by = value; + RefreshCoverManager (); + InvokeSortingChanged (); + } + } + } + + protected abstract ISortComparer Comparer { get; } + private int count; //previous model count + + protected List index_map; //maps list indeces to model indeces private FilterListModel model; public virtual FilterListModel Model { @@ -61,24 +148,46 @@ } } } - + #endregion + public BansheeActorLoader (CoverManager coverManager) : base (coverManager) { } public override void Dispose () { Model = null; base.Dispose (); } + + public override List GetActors (System.Action method_call) + { + SortedList list = + new SortedList(Comparer); + if (Model!=null) { + for (int i = 1; i < Model.Count; i++) + AddActorToList(Model[i], list); + index_map = new List(list.Values.Count); + for (int i = 0; i < list.Values.Count; i++) { + ClutterFlowBaseActor actor = list.Values[i]; + index_map.Add(actor.Index); + actor.Index = i; + if (method_call!=null) method_call(actor); + } + } + return new List(list.Values); + } + + public virtual int ConvertIndexToModelIndex (int index) + { + return (index_map!=null && index_map.Count > index) ? index_map[index] : 0; + } #region Event Handlers protected void OnModelClearedHandler (object o, EventArgs args) { - //Hyena.Log.Information ("OnModelClearedHandler called"); RefreshCoverManager (); } protected void OnModelReloadedHandler (object o, EventArgs args) { - //Hyena.Log.Information ("OnModelReloadedHandler called"); if (count!=model.Count) { count=model.Count; RefreshCoverManager (); @@ -97,7 +206,23 @@ } #endregion - #region Fields + #region Fields + protected static ISortComparer sort_by_name = new AlbumAlbumComparer (); + protected static ISortComparer sort_by_arst = new AlbumArtistComparer (); + + protected override ISortComparer Comparer { + get { + switch (SortBy) { + case SortOptions.Album: + return sort_by_name; + case SortOptions.Artist: + return sort_by_arst; + default: + return sort_by_name; + } + } + } + public ClutterFlowAlbum CurrentActor { get { return (ClutterFlowAlbum) coverManager.CurrentCover; } } @@ -124,24 +249,14 @@ { } - public override List GetActors (System.Action method_call) - { - List list = new List(); - if (Model!=null) for (int i = 1; i < Model.Count; i++) { - ClutterFlowBaseActor actor = AddActorToList(Model[i], list); - if (method_call!=null) method_call(actor); - } - return list; - } - public virtual void ScrollTo (AlbumInfo generator) { coverManager.Timeline.Timeout = 500; //give 'm some time to load the song etc. ScrollTo (ClutterFlowAlbum.CreateCacheKey (generator)); } - - protected override ClutterFlowBaseActor AddActorToList (AlbumInfo generator, List list) - { + + protected override ClutterFlowBaseActor AddActorToList (AlbumInfo generator, SortedList list) + { string key = ClutterFlowAlbum.CreateCacheKey(generator); ClutterFlowBaseActor actor = Cache.ContainsKey (key) ? Cache[key] : null; if (actor==null) { @@ -149,8 +264,9 @@ actor.Hide (); Cache.Add (key, actor); } - actor.Index = list.Count; - list.Add(actor); + actor.SortLabel = Comparer.GetSortLabel(generator); + list.Add (generator, actor); + actor.Index = list.Count; return actor; } diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlow.addin.xml banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlow.addin.xml --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlow.addin.xml 2010-03-01 19:53:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlow.addin.xml 2010-03-31 19:37:31.000000000 +0100 @@ -1,7 +1,7 @@ external_filter; //this is actually fetched from the MusicLibrary //PLAYBACK RELATED: - private TrackInfo previous_track; + private TrackInfo transitioned_track; private bool IsParentSource { get { return ServiceManager.PlaybackController.Source!=null && ServiceManager.PlaybackController.Source.Parent==source; } @@ -148,6 +154,7 @@ ServiceManager.SourceManager.ActiveSourceChanged -= HandleActiveSourceChanged; ServiceManager.PlaybackController.TrackStarted -= OnPlaybackControllerTrackStarted; ServiceManager.PlaybackController.SourceChanged -= OnPlaybackSourceChanged; + ServiceManager.PlayerEngine.DisconnectEvent (OnPlayerEvent); Reset (); if (filter_view.Parent!=null) frame.Remove (filter_view); @@ -215,6 +222,7 @@ #endregion #region View Setup + protected void InitializeInterface () { SetupMainView (); @@ -224,7 +232,7 @@ protected void SetupMainView () { main_view = new TrackListView (); - main_view.HeaderVisible = true; //TODO copy this from FilteredListSourceContents? + main_view.HeaderVisible = true; main_expander = CreateScrollableExpander (main_view); main_expander.Expanded = ClutterFlowSchemas.ExpandTrackList.Get (); } @@ -235,18 +243,14 @@ filter_view.FSButton.IsActive = IsFullscreen; filter_view.PMButton.IsActive = InPartyMode; filter_view.LabelTrackIsVisible = ClutterFlowSchemas.DisplayTitle.Get () && IsFullscreen; + filter_view.SortButton.IsActive = (ClutterFlowSchemas.SortBy.Get () != ClutterFlowSchemas.SortBy.DefaultValue); } private Expander CreateScrollableExpander (Widget view) { ScrolledWindow window = null; - // See revision http://git.gnome.org/browse/banshee/commit/?id=2b7789ea563319fa7196e50b76b2b561d699fd71 -#if BANSHEE_V152 - if (Banshee.Base.ApplicationContext.CommandLine.Contains ("smooth-scroll")) { -#else if (ApplicationContext.CommandLine.Contains ("smooth-scroll")) { -#endif window = new SmoothScrolledWindow (); } else { window = new ScrolledWindow (); @@ -256,7 +260,7 @@ window.HscrollbarPolicy = PolicyType.Automatic; window.VscrollbarPolicy = PolicyType.Automatic; - Expander expander = new Expander(Catalog.GetString ("Track list")); + Expander expander = new Expander(AddinManager.CurrentLocalizer.GetString ("Track list")); expander.Add(window); return expander; @@ -396,11 +400,6 @@ ShowPack (); } - - protected bool is_fullscreen = false; - public bool IsFullscreen { - get { return is_fullscreen; } - } #endregion #region Playback Handling @@ -410,11 +409,13 @@ FilterView.UpdatedAlbum += HandleUpdatedAlbum; FilterView.PMButton.Toggled += HandlePMButtonToggled; FilterView.FSButton.Toggled += HandleFSButtonToggled; + FilterView.SortButton.Toggled += HandleSortButtonToggled; - ServiceManager.SourceManager.ActiveSourceChanged += HandleActiveSourceChanged; + ServiceManager.SourceManager.ActiveSourceChanged += HandleActiveSourceChanged; ServiceManager.PlaybackController.TrackStarted += OnPlaybackControllerTrackStarted; + ServiceManager.PlayerEngine.ConnectEvent (OnPlayerEvent); ServiceManager.PlaybackController.SourceChanged += OnPlaybackSourceChanged; - + FilterView.AlbumLoader.SortingChanged += HandleSortingChanged; } private void HandleUpdatedAlbum(object sender, EventArgs e) @@ -443,14 +444,36 @@ service.ViewActions.Fullscreen (FilterView.FSButton.IsActive); } + + private void HandleSortButtonToggled (object sender, EventArgs e) + { + if (!FilterView.SortButton.IsActive) + FilterView.AlbumLoader.SortBy = SortOptions.Artist; + else + FilterView.AlbumLoader.SortBy = SortOptions.Album; + } + + + private void HandleSortingChanged (object sender, EventArgs e) + { + if (FilterView.AlbumLoader.SortBy.GetType () == typeof(AlbumArtistComparer)) + FilterView.SortButton.IsActive = false; + else + FilterView.SortButton.IsActive = true; + } + private void HandleActiveSourceChanged (SourceEventArgs args) { FilterView.PMButton.SetSilent (InPartyMode); - } + } + private void OnPlayerEvent (PlayerEventArgs args) + { + CheckForSwitch (); + } private void OnPlaybackControllerTrackStarted (object o, EventArgs args) - { + { CheckForSwitch (); - } + } private void OnPlaybackSourceChanged (object o, EventArgs args) { FilterView.PMButton.SetSilent (InPartyMode); @@ -462,18 +485,21 @@ /// private void CheckForSwitch () { - TrackInfo current_track = ServiceManager.PlaybackController.CurrentTrack; - if (current_track != null && previous_track != current_track) { - if (IsActiveSource) - FilterView.LabelTrack.SetValueWithAnim (current_track.TrackNumber + " - " + current_track.TrackTitle); - if (InPartyMode) { - DatabaseAlbumInfo album = DatabaseAlbumInfo.FindOrCreate ( - DatabaseArtistInfo.FindOrCreate (current_track.AlbumArtist, current_track.AlbumArtistSort), - current_track.AlbumTitle, current_track.AlbumTitleSort, current_track.IsCompilation); - FilterView.AlbumLoader.ScrollTo(album); + ThreadAssist.ProxyToMain (delegate { + TrackInfo current_track = ServiceManager.PlaybackController.CurrentTrack; + if (current_track != null && transitioned_track != current_track) { + if (IsActiveSource) + FilterView.LabelTrack.SetValueWithAnim (current_track.TrackNumber + " - " + current_track.TrackTitle); + if (InPartyMode) { + DatabaseAlbumInfo album = DatabaseAlbumInfo.FindOrCreate ( + DatabaseArtistInfo.FindOrCreate (current_track.AlbumArtist, current_track.AlbumArtistSort), + current_track.AlbumTitle, current_track.AlbumTitleSort, current_track.IsCompilation); + FilterView.AlbumLoader.ScrollTo(album); + } + transitioned_track = ServiceManager.PlayerEngine.CurrentTrack; } - } - previous_track = current_track; + + }); } private void UpdatePlayback () @@ -489,7 +515,6 @@ else ServiceManager.PlaybackController.Next(); } - //source.OnUpdated (); FIXME } #endregion @@ -517,7 +542,7 @@ } } - TrackView.SetModel (TrackModel); + main_view.SetModel (TrackModel); FilterView.SetModel (external_filter); return true; @@ -549,7 +574,7 @@ AlbumInfo album = FilterView.ActiveAlbum; if (album!=null) { external_filter.Selection.Clear (false); - external_filter.Selection.Select (FilterView.ActiveIndex+1); + external_filter.Selection.Select (FilterView.ActiveModelIndex); } } protected void SelectAllTracks () diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowSchemas.cs banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowSchemas.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowSchemas.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowSchemas.cs 2010-03-31 19:37:31.000000000 +0100 @@ -26,7 +26,8 @@ using System; -using Banshee.I18n; +using Mono.Addins; + using Banshee.Configuration; using Banshee.Preferences; @@ -39,28 +40,29 @@ public static class ClutterFlowSchemas { internal static void AddToSection (Section section, SchemaEntry entry, SchemaPreferenceUpdatedHandler func) { - section.Add (new SchemaPreference (entry, entry.ShortDescription, entry.LongDescription, func)); + SchemaPreference pref = new SchemaPreference (entry, entry.ShortDescription, entry.LongDescription, func); + section.Add (pref); } internal static readonly SchemaEntry DragSensitivity = new SchemaEntry( "clutterflow", "drag_sensitivity", 3, 1, 20, - Catalog.GetString ("Sensitivity for album dragging"), - Catalog.GetString ("Sets the sensitivity with which albums scroll when dragged, higher values mean faster scrolling") + AddinManager.CurrentLocalizer.GetString ("Sensitivity for album dragging"), + AddinManager.CurrentLocalizer.GetString ("Sets the sensitivity with which albums scroll when dragged, higher values mean faster scrolling") ); internal static readonly SchemaEntry ThreadedArtwork = new SchemaEntry( "clutterflow", "threaded_artwork", true, - Catalog.GetString ("Enable threaded loading of artwork"), - Catalog.GetString ("If enabled ClutterFlow will use threading to load it's artwork") + AddinManager.CurrentLocalizer.GetString ("Enable threaded loading of artwork"), + AddinManager.CurrentLocalizer.GetString ("If enabled ClutterFlow will use threading to load it's artwork") ); internal static readonly SchemaEntry ExpandTrackList = new SchemaEntry( "clutterflow", "expand_track_list", true, - Catalog.GetString ("Unfolds the track list"), - Catalog.GetString ("If checked it will display the track list when not in fullscreen mode") + AddinManager.CurrentLocalizer.GetString ("Unfolds the track list"), + AddinManager.CurrentLocalizer.GetString ("If checked it will display the track list when not in fullscreen mode") ); internal static readonly SchemaEntry OldShowBrowser = new SchemaEntry( @@ -80,105 +82,57 @@ internal static readonly SchemaEntry InstantPlayback = new SchemaEntry( "clutterflow", "instant_playback", true, - Catalog.GetString ("Immediately apply playback mode changes"), - Catalog.GetString ("Starts playing a new song immediately after the playback mode changed (Party Mode or Album Mode)") + AddinManager.CurrentLocalizer.GetString ("Immediately apply playback mode changes"), + AddinManager.CurrentLocalizer.GetString ("Starts playing a new song immediately after the playback mode changed (Party Mode or Album Mode)") ); internal static readonly SchemaEntry DisplayLabel = new SchemaEntry( "clutterflow", "display_album_label", true, - Catalog.GetString ("Display album _label"), - Catalog.GetString ("Wether or not the album label needs to be shown above the artwork") + AddinManager.CurrentLocalizer.GetString ("Display album _label"), + AddinManager.CurrentLocalizer.GetString ("Wether or not the album label needs to be shown above the artwork") ); internal static readonly SchemaEntry DisplayTitle = new SchemaEntry( "clutterflow", "display_track_title", true, - Catalog.GetString ("Display track _title"), - Catalog.GetString ("Wether or not the album title needs to be shown above the artwork in fullscreen mode") + AddinManager.CurrentLocalizer.GetString ("Display track _title"), + AddinManager.CurrentLocalizer.GetString ("Wether or not the album title needs to be shown above the artwork in fullscreen mode") ); internal static readonly SchemaEntry TextureSize = new SchemaEntry( "clutterflow", "texture_size", 128, 32, 512, - Catalog.GetString ("Texture size in pixels"), - Catalog.GetString ("The in-memory size of the cover textures in pixels") + AddinManager.CurrentLocalizer.GetString ("Texture size in pixels"), + AddinManager.CurrentLocalizer.GetString ("The in-memory size of the cover textures in pixels") ); internal static readonly SchemaEntry MinCoverSize = new SchemaEntry( "clutterflow", "min_cover_size", 64, 64, 128, - Catalog.GetString ("Minimal cover size in pixels"), - Catalog.GetString ("The on-stage minimal cover size in pixels") + AddinManager.CurrentLocalizer.GetString ("Minimal cover size in pixels"), + AddinManager.CurrentLocalizer.GetString ("The on-stage minimal cover size in pixels") ); internal static readonly SchemaEntry MaxCoverSize = new SchemaEntry( "clutterflow", "max_cover_size", 256, 128, 512, - Catalog.GetString ("Maximal cover size in pixels"), - Catalog.GetString ("The on-stage minimal cover size in pixels") + AddinManager.CurrentLocalizer.GetString ("Maximal cover size in pixels"), + AddinManager.CurrentLocalizer.GetString ("The on-stage minimal cover size in pixels") ); internal static readonly SchemaEntry VisibleCovers = new SchemaEntry( "clutterflow", "visbible_covers", 7, 1, 15, - Catalog.GetString ("Number of visible covers at the side"), - Catalog.GetString ("The number of covers that need to be displayed on the stage (at one side)") + AddinManager.CurrentLocalizer.GetString ("Number of visible covers at the side"), + AddinManager.CurrentLocalizer.GetString ("The number of covers that need to be displayed on the stage (at one side)") ); - } - - /*public class ClutterFlowSource : Source, IDisposable//, ITrackModelSource - { - - private ClutterFlowInterface clutter_flow_interface; - - public ClutterFlowSource () : base("ClutterFlow", "ClutterFlow", 0) - { - - TypeUniqueId = "ClutterFlow"; - Properties.SetString ("Icon.Name", "clutterflow-icon"); - Properties.Set ("Nereid.SourceContents.HeaderVisible", true); - - clutter_flow_interface = new ClutterFlowInterface (); - - - - //Properties.Set ("Nereid.SourceContents", clutter_flow_interface); - //SetParentSource(ServiceManager.SourceManager.MusicLibrary); - //Parent.AddChildSource(this); - //ServiceManager.SourceManager.AddSource (this); - - InstallPreferences (); - //CreateAlbumListModel (); - - //Reload(); - } - public void Dispose () - { - if (clutter_flow_interface != null) { - clutter_flow_interface.Destroy (); - clutter_flow_interface.Dispose (); - clutter_flow_interface = null; - } - UninstallPreferences (); - } - - #region FullScreen Overrides - public override void Activate () - { - if (clutter_flow_interface != null) { - clutter_flow_interface.OverrideFullscreen (); - } - } - - public override void Deactivate () - { - if (clutter_flow_interface != null) { - clutter_flow_interface.RelinquishFullscreen (); - } - } - #endregion - - }*/ + internal static readonly SchemaEntry SortBy = new SchemaEntry( + "clutterflow", "sort_by", + (string) Enum.GetName (typeof(SortOptions), SortOptions.Artist), + AddinManager.CurrentLocalizer.GetString ("Sort covers by"), + AddinManager.CurrentLocalizer.GetString ("Selects on what basis covers should be sorted") + ); + } } diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowService.cs banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowService.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowService.cs 2010-03-01 19:53:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowService.cs 2010-03-31 19:37:31.000000000 +0100 @@ -27,6 +27,7 @@ using System; using System.Collections.Generic; using Gtk; +using Mono.Addins; using Hyena; @@ -34,7 +35,6 @@ using Banshee.ServiceStack; using Banshee.Gui; -using Banshee.I18n; using Banshee.Library; using Banshee.Sources; using Banshee.Sources.Gui; @@ -228,8 +228,8 @@ clutterflow_actions = new ActionGroup ("ClutterFlowView"); ToggleActionEntry [] tae = new ToggleActionEntry [] { new ToggleActionEntry ("ClutterFlowVisibleAction", null, - Catalog.GetString ("Show ClutterFlow Browser"), null, - Catalog.GetString ("Show or hide the ClutterFlow browser"), + AddinManager.CurrentLocalizer.GetString ("Show ClutterFlow Browser"), null, + AddinManager.CurrentLocalizer.GetString ("Show or hide the ClutterFlow browser"), null, ClutterFlowSchemas.ShowClutterFlow.Get ()) }; clutterflow_actions.Add (tae); @@ -321,10 +321,11 @@ protected void InstallPreferences () { if (!pref_installed) { - pref_page = preference_service.Add(new Page("clutterflow", Catalog.GetString ("ClutterFlow"), 10)); + pref_page = preference_service.Add(new Page("clutterflow", + AddinManager.CurrentLocalizer.GetString ("ClutterFlow"), 10)); general = pref_page.Add (new Section ("general", - Catalog.GetString ("General"), 1)); + AddinManager.CurrentLocalizer.GetString ("General"), 1)); ClutterFlowSchemas.AddToSection (general, ClutterFlowSchemas.InstantPlayback, UpdateLabelVisibility); ClutterFlowSchemas.AddToSection (general, ClutterFlowSchemas.DisplayLabel, UpdateLabelVisibility); ClutterFlowSchemas.AddToSection (general, ClutterFlowSchemas.DisplayTitle, UpdateTitleVisibility); @@ -333,7 +334,7 @@ ClutterFlowSchemas.AddToSection (general, ClutterFlowSchemas.ThreadedArtwork, UpdateThreadedArtwork); dimensions = pref_page.Add (new Section ("dimensions", - Catalog.GetString ("Dimensions"), 2)); + AddinManager.CurrentLocalizer.GetString ("Dimensions"), 2)); ClutterFlowSchemas.AddToSection (dimensions, ClutterFlowSchemas.MinCoverSize, UpdateMinCoverSize); ClutterFlowSchemas.AddToSection (dimensions, ClutterFlowSchemas.MaxCoverSize, UpdateMinCoverSize); ClutterFlowSchemas.AddToSection (dimensions, ClutterFlowSchemas.TextureSize, UpdateMinCoverSize); @@ -346,6 +347,7 @@ private void LoadPreferences () { + UpdateThreadedArtwork (); UpdateDragSensitivity (); UpdateLabelVisibility (); UpdateTitleVisibility (); @@ -354,7 +356,7 @@ UpdateMaxCoverSize (); UpdateTextureSize (); } - + private void UpdateThreadedArtwork () { diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowView.cs banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowView.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowView.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ClutterFlowView.cs 2010-03-31 19:37:31.000000000 +0100 @@ -41,6 +41,7 @@ using ClutterFlow; using ClutterFlow.Captions; using ClutterFlow.Slider; +using ClutterFlow.Alphabet; using Banshee.ClutterFlow.Buttons; @@ -57,18 +58,28 @@ public AlbumInfo ActiveAlbum { get { return activeAlbum; } protected set { activeAlbum = value; } - } + } private int activeIndex = -1; public int ActiveIndex { get { return activeIndex; } protected set { activeIndex = value; } } + public int ActiveModelIndex { + get { + int ret = AlbumLoader.ConvertIndexToModelIndex (ActiveIndex); + Console.WriteLine ("ActiveModelIndex_get will return " + ret); + return ret; + } + } public AlbumInfo CurrentAlbum { get { return albumLoader.CurrentAlbum; } } public int CurrentIndex { get { return albumLoader.CurrentIndex; } } + public int CurrentModelIndex { + get { return AlbumLoader.ConvertIndexToModelIndex (CurrentIndex); } + } #endregion #region General @@ -128,6 +139,10 @@ public FullscreenButton FSButton { get { return fs_button; } } + private SortButton sort_button; + public SortButton SortButton { + get { return sort_button; } + } private CoverCaption caption_cover; public CoverCaption LabelCover { get { return caption_cover; } @@ -188,7 +203,7 @@ #region Initialisation public ClutterFlowView () : base () { - SetSizeRequest (500, 300); + SetSizeRequest (300, 200); Clutter.Global.MotionEventsEnabled = true; coverManager = new CoverManager(); @@ -261,9 +276,9 @@ protected void SetupSlider () { - slider = new ClutterFlowSlider (Stage.Width, Stage.Height, coverManager); + slider = new ClutterFlowSlider (400, 40, coverManager); Stage.Add (slider); - } + } protected void SetupLabels () { caption_cover = new CoverCaption (coverManager, "Sans Bold 10", new Clutter.Color(1.0f,1.0f,1.0f,1.0f)); @@ -277,8 +292,9 @@ { pm_button = new PartyModeButton (); fs_button = new FullscreenButton (); + sort_button = new SortButton (); - widget_bar = new ClutterWidgetBar (new Actor[] { pm_button, fs_button }); + widget_bar = new ClutterWidgetBar (new Actor[] { pm_button, fs_button, sort_button }); widget_bar.ShowAll (); Stage.Add (widget_bar); widget_bar.SetPosition (5, 5); diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/FullscreenButton.cs banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/FullscreenButton.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/FullscreenButton.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/FullscreenButton.cs 2010-03-31 19:37:31.000000000 +0100 @@ -40,16 +40,16 @@ { } - public FullscreenButton() : this (false) + public FullscreenButton () : this (false) { } #region Rendering - private void Render(Clutter.CairoTexture texture, int with_state, bool outwards) + private void Render (Clutter.CairoTexture texture, int with_state, bool outwards) { - texture.Clear(); - Cairo.Context context = texture.Create(); + texture.Clear (); + Cairo.Context context = texture.Create (); double lwidth = 1; double hlwidth = lwidth*0.5; @@ -74,8 +74,8 @@ context.NewPath (); double margin = 2 + hlwidth ; - PointD center = new PointD(texture.Width*0.5, texture.Height*0.5); - PointD transl = new PointD(center.X - margin, -(center.Y - margin)); + PointD center = new PointD (texture.Width*0.5, texture.Height*0.5); + PointD transl = new PointD (center.X - margin, -(center.Y - margin)); context.LineWidth = lwidth; sat = (with_state==1 ? 0.0 : 1.0); context.SetSourceRGB (sat,sat,sat); diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/Makefile.am banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/Makefile.am --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/Makefile.am 2010-03-10 18:07:07.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/Makefile.am 2010-03-31 19:37:31.000000000 +0100 @@ -3,19 +3,22 @@ ASSEMBLY_GCONF_SCHEMA = banshee-plugin-alarm.schemas.in SOURCES = \ - ClutterFlowService.cs \ - ClutterFlowContents.cs \ - ClutterFlowSchemas.cs \ - ClutterFlowAlbum.cs \ - AlbumLoader.cs \ - ClutterFlowView.cs \ - PartyModeButton.cs \ - FullscreenButton.cs \ - ArtworkLookup.cs \ - FloatingQueue.cs + AlbumLoader.cs \ + ArtworkLookup.cs \ + ClutterFlowAlbum.cs \ + ClutterFlowContents.cs \ + ClutterFlowSchemas.cs \ + ClutterFlowService.cs \ + ClutterFlowView.cs \ + FloatingQueue.cs \ + FullscreenButton.cs \ + PartyModeButton.cs \ + SortButton.cs RESOURCES = \ - ClutterFlow.addin.xml + ClutterFlow.addin.xml \ + ThemeIcons/22x22/clutterflow-icon.png \ + ThemeIcons/256x256/clutterflow-large.png if ENABLE_CLUTTERFLOW include $(top_srcdir)/build/build.mk diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/Makefile.in banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/Makefile.in --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/Makefile.in 2010-03-11 06:03:34.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/Makefile.in 2010-03-31 19:47:52.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/ClutterFlow/Banshee.ClutterFlow ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ @@ -289,19 +294,22 @@ $(am__append_1) ASSEMBLY_GCONF_SCHEMA = banshee-plugin-alarm.schemas.in SOURCES = \ - ClutterFlowService.cs \ - ClutterFlowContents.cs \ - ClutterFlowSchemas.cs \ - ClutterFlowAlbum.cs \ - AlbumLoader.cs \ - ClutterFlowView.cs \ - PartyModeButton.cs \ - FullscreenButton.cs \ - ArtworkLookup.cs \ - FloatingQueue.cs + AlbumLoader.cs \ + ArtworkLookup.cs \ + ClutterFlowAlbum.cs \ + ClutterFlowContents.cs \ + ClutterFlowSchemas.cs \ + ClutterFlowService.cs \ + ClutterFlowView.cs \ + FloatingQueue.cs \ + FullscreenButton.cs \ + PartyModeButton.cs \ + SortButton.cs RESOURCES = \ - ClutterFlow.addin.xml + ClutterFlow.addin.xml \ + ThemeIcons/22x22/clutterflow-icon.png \ + ThemeIcons/256x256/clutterflow-large.png # Initializers diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/SortButton.cs banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/SortButton.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/SortButton.cs 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/SortButton.cs 2010-03-31 19:37:31.000000000 +0100 @@ -0,0 +1,130 @@ + + +using System; + +using Cairo; + +using Clutter; + +using ClutterFlow; +using ClutterFlow.Buttons; + +namespace Banshee.ClutterFlow.Buttons +{ + + public class SortButton : ClutterToggleButton + { + + public SortButton (bool toggled) : base (25, 25, toggled) + { + } + + public SortButton () : this (false) + { + } + + #region Rendering + private void Render(Clutter.CairoTexture texture, int with_state, bool outwards) + { + + texture.Clear(); + Cairo.Context context = texture.Create(); + + + + double alpha_f = with_state == 0 ? 0.5 : (with_state == 1 ? 0.8 : 1); + + double lwidth = 1; + double hlwidth = lwidth*0.5; + context.LineWidth = lwidth; + + if (outwards) { + context.MoveTo (texture.Width*0.5-texture.Height*0.45, texture.Height*0.9); + context.CurveTo (texture.Width*0.3, texture.Height, texture.Width*0.6, texture.Height, texture.Width*0.5+texture.Height*0.45, texture.Height*0.9); + context.ArcNegative (texture.Width*0.5, texture.Height*0.9, texture.Height*0.45, 0, Math.PI); + context.ClosePath (); + Gradient g1 = new LinearGradient (0, texture.Height/2, 0, texture.Height); + g1.AddColorStop (0, new Cairo.Color (0.6, 0.6, 0.6, 1.0*alpha_f)); + g1.AddColorStop (1.0, new Cairo.Color (1.0, 1.0, 1.0, 1.0*alpha_f)); + context.Pattern = g1; + context.FillPreserve (); + context.SetSourceRGBA (1.0, 1.0, 1.0, 1.0*alpha_f); + context.Stroke (); + ((IDisposable) g1).Dispose (); + + context.Arc (Width*0.5, Height*0.33+lwidth, Height*0.33, 0, Math.PI*2); + context.ClosePath (); + context.Operator = Operator.Source; + Gradient g2 = new RadialGradient (texture.Width*0.5, texture.Height*0.25, 0, texture.Width*0.5, texture.Height*0.25, texture.Width*0.5); + g2.AddColorStop (0, new Cairo.Color (1.0, 1.0, 1.0, 1.0*alpha_f)); + g2.AddColorStop (1.0, new Cairo.Color (0.6, 0.6, 0.6, 1.0*alpha_f)); + context.Pattern = g2; + //context.SetSourceRGBA (1.0, 1.0, 1.0, 1.0*alpha_f); + context.FillPreserve (); + Gradient g3 = new LinearGradient (0, 0, 0, texture.Height*0.5); + g3.AddColorStop (0, new Cairo.Color (1.0, 1.0, 1.0, 1.0*alpha_f)); + g3.AddColorStop (1.0, new Cairo.Color (0, 0, 0, 1.0*alpha_f)); + context.Pattern = g3; + //context.SetSourceRGBA (1.0, 1.0, 1.0, 1.0*alpha_f); + context.Stroke (); + ((IDisposable) g2).Dispose (); + ((IDisposable) g3).Dispose (); + + + } else { + Cairo.PointD c = new Cairo.PointD (texture.Width*0.5, texture.Height*0.5); + double max_r = Math.Min (c.X, c.Y) - hlwidth; + + context.Arc (c.X, c.Y, max_r, 0, Math.PI*2); + context.ArcNegative (c.X, c.Y, max_r*0.25, Math.PI*2, 0); + context.ClosePath (); + context.SetSourceRGBA (0.5, 0.5, 0.5, 1.0*alpha_f); + context.StrokePreserve (); + Gradient g1 = new LinearGradient (0, texture.Height, texture.Width, 0); + g1.AddColorStop(0, new Cairo.Color (1.0, 1.0, 1.0, 1.0*alpha_f)); + g1.AddColorStop(0.5, new Cairo.Color (0.7, 0.7, 0.7, 1.0*alpha_f)); + g1.AddColorStop(1, new Cairo.Color (0.9, 0.9, 0.9, 1.0*alpha_f)); + context.Pattern = g1; + context.Fill (); + ((IDisposable) g1).Dispose (); + + context.ArcNegative (c.X, c.Y, max_r*0.25+lwidth, Math.PI*1.75, Math.PI*0.75); + context.Arc (c.X, c.Y, max_r, Math.PI*0.75, Math.PI*1.75); + context.ClosePath (); + Gradient g2 = new LinearGradient (c.X, c.Y, c.X*0.35, c.Y*0.35); + g2.AddColorStop(0, new Cairo.Color (1.0, 1.0, 1.0, 1.0*alpha_f)); + g2.AddColorStop(1, new Cairo.Color (1.0, 1.0, 1.0, 0.0)); + context.Pattern = g2; + context.Fill (); + ((IDisposable) g2).Dispose (); + + context.ArcNegative (c.X, c.Y, max_r*0.25+lwidth, Math.PI*2, 0); + context.Arc (c.X, c.Y, max_r*0.45, 0, Math.PI*2); + context.SetSourceRGBA (1.0, 1.0, 1.0, 0.8*alpha_f); + context.Fill (); + + context.Arc (c.X, c.Y, max_r-lwidth, 0, Math.PI*2); + Gradient g3 = new LinearGradient (0, texture.Height, texture.Width, 0); + g3.AddColorStop(0, new Cairo.Color (1.0, 1.0, 1.0, 0.0)); + g3.AddColorStop(1, new Cairo.Color (0.9, 0.9, 0.9, 1.0*alpha_f)); + context.Pattern = g3; + context.Stroke (); + ((IDisposable) g3).Dispose (); + } + + ((IDisposable) context.Target).Dispose (); + ((IDisposable) context).Dispose (); + } + + protected override void CreatePassiveTexture (Clutter.CairoTexture texture, int with_state) + { + Render (texture, with_state, true); + } + + protected override void CreateActiveTexture (Clutter.CairoTexture texture, int with_state) + { + Render (texture, with_state, false); + } + #endregion + } +} Binary files /tmp/W0QhM5ESO4/banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ThemeIcons/22x22/clutterflow-icon.png and /tmp/TadR8LjKdY/banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ThemeIcons/22x22/clutterflow-icon.png differ Binary files /tmp/W0QhM5ESO4/banshee-community-extensions-1.5.5/src/ClutterFlow/Banshee.ClutterFlow/ThemeIcons/256x256/clutterflow-large.png and /tmp/TadR8LjKdY/banshee-community-extensions-1.6.0/src/ClutterFlow/Banshee.ClutterFlow/ThemeIcons/256x256/clutterflow-large.png differ diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ActorLoader.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ActorLoader.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ActorLoader.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ActorLoader.cs 2010-03-31 19:37:31.000000000 +0100 @@ -79,8 +79,6 @@ protected virtual void RefreshCoverManager () { CoverManager.ReloadCovers (); - /*if (coverManager.Enabled) coverManager.ReloadCovers (); - else coverManager.NeedsReloading = true;*/ } public virtual List GetActors (System.Action method_call) @@ -88,7 +86,7 @@ throw new System.NotImplementedException(); } - protected virtual ClutterFlowBaseActor AddActorToList(TGen generator, List list) { + protected virtual ClutterFlowBaseActor AddActorToList(TGen generator, SortedList list) { throw new System.NotImplementedException(); } diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/AlphabetBar.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/AlphabetBar.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/AlphabetBar.cs 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/AlphabetBar.cs 2010-03-23 16:37:38.000000000 +0000 @@ -0,0 +1,145 @@ + +using System; +using System.Collections.Generic; +using Clutter; +using ClutterFlow.Buttons; + +namespace ClutterFlow.Alphabet +{ + + public class AlphabetEventArgs : EventArgs + { + protected AlphabetChars letter = AlphabetChars.unkown; + public AlphabetChars Letter { + get { return letter; } + } + + public AlphabetEventArgs (AlphabetChars letter) : base () + { + this.letter = letter; + } + } + + + public class AlphabetBar : Clutter.Group + { + + #region Events + public event EventHandler LetterClicked; + protected void InvokeLetterClicked (AlphabetChars letter) + { + if (LetterClicked!=null) LetterClicked (this, new AlphabetEventArgs (letter)); + } + #endregion + + #region Fields + protected CairoTexture background; + + protected Dictionary buttons = new Dictionary(Enum.GetValues(typeof(AlphabetChars)).Length); + public AlphabetButton this [AlphabetChars index] { + get { return buttons[index]; } + } + + protected double Margin { + get { return Width * 0.075; } + } + + #endregion Fields + + #region Initialisation + public AlphabetBar (uint width, uint height) + { + this.SetSize (width, height); + + InitBackground (); + InitButtons (); + + ShowAll (); + } + + protected virtual void InitBackground () + { + background = new CairoTexture ((uint) Width,(uint) Height); + Add (background); + + SetupBackground (); + background.Show (); + } + + protected virtual void SetupBackground () + { + background.Clear(); + Cairo.Context context = background.Create(); + + double lwidth = 1; + double hlwidth = lwidth*0.5; + + double margin = Margin; + + //left curvature: + context.MoveTo (-hlwidth, -hlwidth); + context.CurveTo (margin*0.33, -hlwidth, + margin*0.5, Height*0.4, + margin*0.5, Height*0.5); + context.CurveTo (margin*0.5, Height*0.6, + margin*0.66, Height-hlwidth, + margin-hlwidth, Height-hlwidth); + + + //straight bottom: + context.LineTo (Width-margin-hlwidth, Height-hlwidth); + + //right curvature: + context.CurveTo (Width-margin*0.66, Height - hlwidth, + Width-margin*0.5, Height*0.6, + Width-margin*0.5, Height*0.5); + context.CurveTo (Width-margin*0.5, Height*0.4, + Width-margin*0.33, -hlwidth, + Width-hlwidth, -hlwidth); + + //straight top: + context.LineTo (-hlwidth, -hlwidth); + context.ClosePath (); + + context.LineWidth = lwidth; + context.SetSourceRGBA (1.0, 1.0, 1.0, 1.0); + context.StrokePreserve (); + context.SetSourceRGBA (1.0, 1.0, 1.0, 0.10); + context.Fill (); + + ((IDisposable) context.Target).Dispose(); + ((IDisposable) context).Dispose(); + } + + protected virtual void InitButtons () + { + Array values = Enum.GetValues(typeof(AlphabetChars)); + + int x_step = (int) ((Width * 0.950) / values.Length); + uint b_width = (uint) x_step; + uint b_height = (uint) (Height - 2); + + int x = (int) (Margin*0.5f + x_step); + int y = (int) (Height * 0.5)+2; + + foreach (AlphabetChars key in values) { + buttons[key] = new AlphabetButton (b_width, b_height, key); + buttons[key].ButtonReleaseEvent += HandleButtonReleaseEvent; + Add (buttons[key]); + buttons[key].SetAnchorPoint ((float) buttons[key].Width*0.5f, (float) buttons[key].Height*0.5f); + buttons[key].SetPosition (x, y); + x += x_step; + } + } + #endregion + + #region Event Handling + protected void HandleButtonReleaseEvent (object o, ButtonReleaseEventArgs args) + { + if (o is AlphabetButton) { + InvokeLetterClicked ((o as AlphabetButton).Letter); + } + } + #endregion + } +} diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/AlphabetButton.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/AlphabetButton.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/AlphabetButton.cs 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/AlphabetButton.cs 2010-03-23 16:37:38.000000000 +0000 @@ -0,0 +1,126 @@ + +using System; + +using Cairo; + +using Clutter; +using ClutterFlow.Buttons; + +namespace ClutterFlow.Alphabet +{ + + + public enum AlphabetChars { + unkown=0x003F, A=0x0041, B=0x0042, + C=0x0043, D=0x0044, E=0x0045, + F=0x0046, G=0x0047, H=0x0048, + I=0x0049, J=0x004A, K=0x004B, + L=0x004C, M=0x004D, N=0x004E, + O=0x004F, P=0x0050, Q=0x0051, + R=0x0052, S=0x0053, T=0x0054, + U=0x0055, V=0x0056, W=0x0057, + X=0x0058, Y=0x0059, Z=0x005A + } + + public class AlphabetButton : Buttons.ClutterButtonState + { + + #region Fields + protected override int MaxState { + get { return 7; } + } + + protected Text label; + + protected AlphabetChars letter = AlphabetChars.unkown; + public virtual AlphabetChars Letter { + get { return letter; } + set { + if (letter!=value) { + letter = value; + label.Value = ((char) letter).ToString (); + Update (); + } + } + } + + public virtual bool Disabled { + get { return (State & 4) == 4; } + set { + if (value) { + State |= 4; + Reactive = false; + BubbleEvents = false; + } else { + State &= ~4; + Reactive = true; + BubbleEvents = true; + } + Update (); + } + } + #endregion + + #region Initialization + public AlphabetButton (uint width, uint height, AlphabetChars letter) + { + this.SetSize (width, height); + this.letter = letter; + + Initialise (); + } + + protected override void Initialise () + { + base.Initialise (); + this.Reactive = !Disabled; + this.BubbleEvents = !Disabled; + + label = new Text(GetFontName (), ((char) letter).ToString (), GetFontColor ()); + Add (label); + Update (); + } + + #endregion + + #region Update + public override void Update () + { + this.Reactive = !Disabled; + this.BubbleEvents = !Disabled; + + label.FontName = GetFontName (); + label.SetAnchorPoint (label.Width*0.5f, label.Height*0.5f+2); + label.SetPosition (this.Width*0.5f,this.Height*0.5f); + label.SetColor (GetFontColor ()); + label.ShowAll(); + } + + Clutter.Color[] colors; + + protected string GetFontName () + { + return "Sans " + ((state & 5)==1 ? "Bold" : "Normal") + " " + ((int) ((float)Height*0.75f)).ToString (); + } + + protected Clutter.Color GetFontColor () + { + if (colors==null) { + colors = new Clutter.Color[4]; + colors[0] = new Clutter.Color (1.0f, 1.0f, 1.0f, 0.6f); + colors[1] = new Clutter.Color (1.0f, 1.0f, 1.0f, 0.75f); + colors[2] = new Clutter.Color (1.0f, 1.0f, 1.0f, 0.9f); + colors[3] = new Clutter.Color (0.0f, 0.0f, 0.0f, 0.75f); + } + if (state>=4) + return colors[3]; + else if (state >= 2) + return colors[2]; + else if (state == 1) + return colors[1]; + else + return colors[0]; + } + #endregion + } +} diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterButton.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterButton.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterButton.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterButton.cs 2010-03-23 16:37:38.000000000 +0000 @@ -33,19 +33,12 @@ public abstract class ClutterButtonState : Group { + #region Fields protected bool bubble = false; public virtual bool BubbleEvents { get { return bubble; } set { bubble = value; } } - - protected virtual void Initialise () { - IsReactive = true; - ButtonPressEvent += HandleButtonPressEvent; - ButtonReleaseEvent += HandleButtonReleaseEvent; - EnterEvent += HandleEnterEvent; - LeaveEvent += HandleLeaveEvent; - } protected int state = 0; protected abstract int MaxState { get; } @@ -65,7 +58,21 @@ } } } + #endregion + + #region Methods + protected virtual void Initialise () { + IsReactive = true; + ButtonPressEvent += HandleButtonPressEvent; + ButtonReleaseEvent += HandleButtonReleaseEvent; + EnterEvent += HandleEnterEvent; + LeaveEvent += HandleLeaveEvent; + } + public abstract void Update(); + #endregion + + #region Event Handling protected virtual void HandleEnterEvent(object o, EnterEventArgs args) { State |= 1; @@ -89,8 +96,7 @@ State &= ~1; args.RetVal = !BubbleEvents; } - - public abstract void Update(); + #endregion } public class ClutterButton : ClutterButtonState @@ -102,18 +108,18 @@ } protected CairoTexture[] textures; - protected virtual int GetTextureIndex(int state) { - return ((state == 3) ? 2 : state); + protected virtual int GetTextureIndex(int with_state) { + return ((with_state == 3) ? 2 : with_state); } public virtual CairoTexture StateTexture { - get { return textures[GetTextureIndex(state)]; } + get { return textures[GetTextureIndex(State)]; } } #endregion #region Initialization protected ClutterButton (uint width, uint height, int state, bool init) : base () { - this.state = state; + this.State = state; this.SetSize (width, height); if (init) Initialise (); diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterFlowActor.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterFlowActor.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterFlowActor.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterFlowActor.cs 2010-03-31 19:37:31.000000000 +0100 @@ -29,7 +29,6 @@ using System.Collections.Generic; using Gdk; -//using Cairo; using Clutter; using Cogl; @@ -240,7 +239,7 @@ } } - public int CompareTo (IIndexable obj) { + public virtual int CompareTo (IIndexable obj) { if (obj.Index==-1 && this.Index!=-1) return 1; return obj.Index - this.Index; @@ -565,7 +564,8 @@ #endregion #region Behaviour Functions - public void SetShade (byte opacity, bool left) { + public void SetShade (byte opacity, bool left) + { if (!has_shader) { shade.Opacity = opacity; if (left) @@ -575,30 +575,48 @@ } } - public ClutterFlowActor CreateClickClone () { - coverManager.Behaviour.CreateClickedCloneAnimation (this); + public ClutterFlowActor CreateClickClone () + { + if (CoverManager.CurrentCover!=this) + CoverManager.NewCurrentCover += HandleNewCurrentCover; + else + coverManager.Behaviour.CreateClickedCloneAnimation (this); return this; } + + private void HandleNewCurrentCover (ClutterFlowBaseActor Actor, EventArgs args) + { + if (CoverManager.CurrentCover==this) { + CoverManager.NewCurrentCover -= HandleNewCurrentCover; + coverManager.Behaviour.CreateClickedCloneAnimation (this, CoverManager.MaxAnimationSpan); + } + } protected virtual void SlideIn () { - //FIXME: we should not shift the shade along!! if (!shifted_outwards) return; shifted_outwards = false; - Animatev ((ulong) Clutter.AnimationMode.EaseOutBack.value__, CoverManager.MaxAnimationSpan, new string[] { "anchor-x" }, new GLib.Value ((float) Width*0.5f)); + Animation anm = Animatev ((ulong) Clutter.AnimationMode.EaseOutBack.value__, CoverManager.MaxAnimationSpan, + new string[] { "anchor-x" }, new GLib.Value ((float) Width*0.5f)); + if (!has_shader) + shade.AnimateWithTimelinev ((ulong) Clutter.AnimationMode.EaseOutSine.value__, anm.Timeline, + new string[] { "anchor-x" }, new GLib.Value (0.0f)); } protected virtual void SlideOut () { - //FIXME: we should not shift the shade along!! if (shifted_outwards) return; shifted_outwards = true; float x, y, z; double angle = GetRotation(RotateAxis.Y, out x, out y, out z); float new_anchor_x = (float) (Width * (0.5f + 1.6f*Math.Tan (angle))); - Animatev ((ulong) Clutter.AnimationMode.EaseOutBack.value__, CoverManager.MaxAnimationSpan, new string[] { "anchor-x" }, new GLib.Value ((float) new_anchor_x)); + Animation anm = Animatev ((ulong) Clutter.AnimationMode.EaseOutBack.value__, CoverManager.MaxAnimationSpan, + new string[] { "anchor-x" }, new GLib.Value ((float) new_anchor_x)); + if (!has_shader) + shade.AnimateWithTimelinev ((ulong) Clutter.AnimationMode.EaseOutSine.value__, anm.Timeline, + new string[] { "anchor-x" }, new GLib.Value ((float) -new_anchor_x*0.5f)); } #endregion diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterFlowSlider.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterFlowSlider.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterFlowSlider.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterFlowSlider.cs 2010-03-31 19:37:31.000000000 +0100 @@ -24,20 +24,23 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. +using System; + +using Clutter; using ClutterFlow; -using System; +using ClutterFlow.Alphabet; namespace ClutterFlow.Slider { - public class ClutterFlowSlider : ClutterSlider + public class ClutterFlowSlider : Group { - + #region Fields protected CoverManager coverManager; public CoverManager CoverManager { - get { return CoverManager; } + get { return coverManager; } set { if (value!=coverManager) { if (coverManager!=null) { @@ -48,53 +51,117 @@ if (coverManager!=null) { coverManager.CoversChanged += HandleCoversChanged; coverManager.TargetIndexChanged += HandleTargetIndexChanged; + coverManager.LetterLookupChanged += HandleLetterLookupChanged; } } } } + + protected ClutterSlider slider; + protected AlphabetBar alphabet; + + #endregion - public ClutterFlowSlider (float width, float height, CoverManager coverManager) : base (width, height) + #region Initialisation + public ClutterFlowSlider (float width, float height, CoverManager coverManager) { + this.IsReactive = true; this.CoverManager = coverManager; - this.SliderHasChanged += HandleSliderHasChanged; - this.SliderHasMoved += HandleSliderHasMoved; + this.SetSize (width, height); + this.EnterEvent += HandleEnterEvent; + this.LeaveEvent += HandleLeaveEvent; + + InitChildren (); + Update (); } + + protected virtual void InitChildren () + { + slider = new ClutterSlider (Width, Height*0.6f); + slider.SetAnchorPoint (0, 0); + slider.SetPosition (0, 0); + slider.SliderHasChanged += HandleSliderHasChanged; + slider.SliderHasMoved += HandleSliderHasMoved; + Add (slider); + slider.Show (); + + alphabet = new AlphabetBar ((uint) (Width-Height*1.5), (uint) (Height*0.4f)); + alphabet.SetAnchorPoint (alphabet.Width*0.5f, alphabet.Height); + alphabet.SetPosition (Width*0.5f, Height); + alphabet.LetterClicked += HandleAlphabetLetterClicked; + Add (alphabet); + alphabet.Opacity = (byte) 0; + alphabet.Show (); + } + #endregion - public override void Update () + public void Update () { if (Stage!=null) { - SetAnchorPoint(Width*0.5f, Height*0.5f); - SetPosition(coverManager.Behaviour.CenterX, Math.Min(coverManager.Behaviour.CenterY + coverManager.Behaviour.CoverWidth * 1.25f, Stage.Height - Height)); + SetAnchorPoint(Width*0.5f, Height); + //Console.WriteLine ("ClutterFlowSlider.Update, Width = " + Width + " coverManager.Behaviour.CenterX = " + coverManager.Behaviour.CenterX); + SetPosition(coverManager.Behaviour.CenterX, Math.Min(coverManager.Behaviour.CenterY + coverManager.Behaviour.CoverWidth * 1.5f, Stage.Height)); } - base.Update (); + slider.Update (); + } + + + #region Event Handling + protected void HandleEnterEvent (object o, EnterEventArgs args) + { + alphabet.Animatev ((ulong) AnimationMode.EaseOutExpo.value__, CoverManager.MaxAnimationSpan, new string[] { "opacity" }, new GLib.Value((byte) 255)); + args.RetVal = true; } + protected void HandleLeaveEvent (object o, LeaveEventArgs args) + { + alphabet.Animatev ((ulong) AnimationMode.EaseOutExpo.value__, CoverManager.MaxAnimationSpan, new string[] { "opacity" }, new GLib.Value((byte) 0)); + args.RetVal = true; + } + protected void HandleCoversChanged (object sender, EventArgs e) { - UpdateBounds (coverManager.TotalCovers, coverManager.TargetIndex); + slider.UpdateBounds (coverManager.TotalCovers, coverManager.TargetIndex); } bool ignoreTargetIndexOnce = false; protected void HandleTargetIndexChanged(object sender, EventArgs e) { - if (coverManager.TargetActor!=null) - this.handle.Button.Label = coverManager.TargetActor.SortLabel.ToUpper ().Substring (0,1); - else - this.handle.Button.Label = "?"; + if (coverManager.TargetActor!=null) { + slider.Label = coverManager.TargetActor.SortLabel.ToUpper ().Substring (0,1); + } else + slider.Label = "?"; if (!ignoreTargetIndexOnce) - HandlePostionFromIndex = coverManager.TargetIndex; + slider.HandlePostionFromIndex = coverManager.TargetIndex; ignoreTargetIndexOnce = false; } protected void HandleSliderHasMoved(object sender, EventArgs e) { ignoreTargetIndexOnce = true; - coverManager.TargetIndex = HandlePostionFromIndex; + coverManager.TargetIndex = slider.HandlePostionFromIndex; } protected void HandleSliderHasChanged(object sender, EventArgs e) { - coverManager.TargetIndex = HandlePostionFromIndex; + coverManager.TargetIndex = slider.HandlePostionFromIndex; } + + protected void HandleAlphabetLetterClicked (object sender, AlphabetEventArgs e) + { + ignoreTargetIndexOnce = false; + /*Console.WriteLine ("HandleAlphabetLetterClicked e.Letter = " + e.Letter); + Console.WriteLine ("CoverManager.LetterLookup is " + (CoverManager.LetterLookup == null ? "null" : "not null")); + Console.WriteLine ("CoverManager.LetterLookup.ContainsKey(e.Letter) = " + CoverManager.LetterLookup.ContainsKey(e.Letter)); + Console.WriteLine ("CoverManager.LetterLookup[e.Letter] = " + CoverManager.LetterLookup[e.Letter]);*/ + CoverManager.TargetIndex = CoverManager.LetterLookup[e.Letter]; + } + + protected void HandleLetterLookupChanged (object sender, EventArgs e) + { + foreach (AlphabetChars key in Enum.GetValues(typeof(AlphabetChars))) + alphabet[key].Disabled = CoverManager.LetterLookup[key]==-1; + } + #endregion } } diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterSlider.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterSlider.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterSlider.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterSlider.cs 2010-03-23 16:37:38.000000000 +0000 @@ -36,7 +36,7 @@ public class ClutterSlider : Group { - + #region Events public event EventHandler SliderHasMoved; void HandleSliderHasMoved(object sender, EventArgs e) { @@ -48,7 +48,9 @@ SetPostionFromIndexSilently(HandlePostionFromIndex); if (SliderHasChanged!=null) SliderHasChanged(this, System.EventArgs.Empty); } + #endregion + #region Fields protected CairoTexture outline; protected ClutterArrowButton arrow_left; protected ClutterArrowButton arrow_right; @@ -69,12 +71,57 @@ } } - public void UpdateBounds(int count, int index) { + public string Label { + get { return handle.Button.Label; } + set { handle.Button.Label = value; } + } + + public uint SliderWidth { + get { return (uint) (Width - Height*1.5f); } + } + #endregion + + #region Initialisation + public ClutterSlider (float width, float height) : base() + { + //this.IsReactive = true; + this.SetSize(width, height); + + handle = new ClutterSliderHandle((float) arrow_width*0.5f + line_width*2, 0, (float) SliderWidth, (float) Height, 0); + handle.SliderHasChanged += HandleSliderHasChanged; + handle.SliderHasMoved += HandleSliderHasMoved; + handle.BubbleEvents = true; + Add(handle); + + outline = new CairoTexture (SliderWidth, (uint) Height); + Add(outline); + outline.SetAnchorPoint (outline.Width*0.5f, outline.Height*0.5f); + outline.SetPosition (Width*0.5f, Height*0.5f); + + arrow_left = new ClutterArrowButton((uint) arrow_width,(uint) arrow_height, 0, 0x03); + arrow_left.ButtonPressEvent += HandleLeftArrowButtonPressEvent; + Add (arrow_left); + arrow_left.SetPosition (0,0); + + arrow_right = new ClutterArrowButton ((uint) arrow_width,(uint) arrow_height, 0, 0x01); + arrow_right.ButtonPressEvent += HandleRightArrowButtonPressEvent; + Add (arrow_right); + arrow_right.SetPosition ((float) (Width-arrow_width),0); + + Update (); + ShowAll (); + } + #endregion + + #region Index & Bounds methods + public void UpdateBounds(int count, int index) + { this.count = count; HandlePostionFromIndex = index; } - public int HandlePostionFromIndex { + public int HandlePostionFromIndex + { get { return (int) Math.Round(handle.Value * (float)(count-1)); } @@ -92,46 +139,17 @@ if (value < 0) value = 0; handle.SetValueSilently ((float) value / (float) (count-1)); } + #endregion -#region Initialisation - public ClutterSlider(float width, float height) : base() { - this.IsReactive = true; - //SetDimensions(width, height); - - uint slider_w = (uint) (max_width - 2*(arrow_width + margin)); - - handle = new ClutterSliderHandle((float) (arrow_width + margin), 0, (float) slider_w, (float) max_height, 0); - handle.SliderHasChanged += HandleSliderHasChanged; - handle.SliderHasMoved += HandleSliderHasMoved; - Add(handle); - - outline = new CairoTexture(slider_w,(uint) max_height); - Add(outline); - outline.SetPosition((float) (arrow_width + margin),0); - - arrow_left = new ClutterArrowButton((uint) arrow_width,(uint) arrow_height, 0, 0x03); - arrow_left.ButtonPressEvent += HandleLeftArrowButtonPressEvent; - Add(arrow_left); - arrow_left.SetPosition(0,0); - - arrow_right = new ClutterArrowButton((uint) arrow_width,(uint) arrow_height, 0, 0x01); - arrow_right.ButtonPressEvent += HandleRightArrowButtonPressEvent; - Add(arrow_right); - arrow_right.SetPosition((float) (max_width-arrow_width),0); - - Update(); - ShowAll(); - } - - #region Arrow Events - void HandleLeftArrowButtonPressEvent(object o, ButtonPressEventArgs args) + #region Events + protected void HandleLeftArrowButtonPressEvent(object o, ButtonPressEventArgs args) { if (args.Event.ClickCount==1 || args.Event.ClickCount%2!=1) HandlePostionFromIndex -= 1; args.RetVal = true; } - void HandleRightArrowButtonPressEvent(object o, ButtonPressEventArgs args) + protected void HandleRightArrowButtonPressEvent(object o, ButtonPressEventArgs args) { if (args.Event.ClickCount==1 || args.Event.ClickCount%2!=1) HandlePostionFromIndex += 1; @@ -139,26 +157,25 @@ } #endregion -#endregion - -#region Rendering - - private const double max_width = 400; - private const double max_height = 26; - private const double margin = -max_height*0.5; - - private const double arc_radius = max_height*0.5; - private const double arrow_height = max_height; - private const double arrow_width = arrow_height*1.25; + #region Rendering + private double arrow_height { + get { return Height; } + } + private double arrow_width { + get { return arrow_height*1.25; } + } + private int line_width { + get { return 1; } + } public virtual void Update() { outline.Clear(); Cairo.Context context = outline.Create(); - context.LineWidth = 1; + context.LineWidth = line_width; context.MoveTo(outline.Height*0.5, 0.5); - context.Arc(outline.Width-outline.Height*0.5,outline.Height*0.5,(outline.Height-1)*0.5,1.5*Math.PI,0.5*Math.PI); - context.Arc(outline.Height*0.5,outline.Height*0.5,(outline.Height-1)*0.5,0.5*Math.PI,1.5*Math.PI); + context.Arc(outline.Width-outline.Height*0.5,outline.Height*0.5,(outline.Height-line_width)*0.5,1.5*Math.PI,0.5*Math.PI); + context.Arc(outline.Height*0.5,outline.Height*0.5,(outline.Height-line_width)*0.5,0.5*Math.PI,1.5*Math.PI); context.ClosePath(); context.SetSourceRGBA(1.0,1.0,1.0,0.2); context.FillPreserve(); @@ -173,6 +190,6 @@ arrow_left.Update(); arrow_right.Update(); } -#endregion + #endregion } } \ No newline at end of file diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterSliderHandleButton.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterSliderHandleButton.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterSliderHandleButton.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterSliderHandleButton.cs 2010-03-23 16:37:38.000000000 +0000 @@ -78,12 +78,5 @@ ((IDisposable) context.Target).Dispose(); ((IDisposable) context).Dispose(); } - - protected override void HandleButtonPressEvent (object o, Clutter.ButtonPressEventArgs args) - { - base.HandleButtonPressEvent (o, args); - args.RetVal = false; - } - } } \ No newline at end of file diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterSliderHandle.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterSliderHandle.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/ClutterSliderHandle.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/ClutterSliderHandle.cs 2010-03-23 16:37:38.000000000 +0000 @@ -56,6 +56,11 @@ #endregion #region Fields + protected bool bubble = false; + public virtual bool BubbleEvents { + get { return bubble; } + set { bubble = value; } + } protected ClutterSliderHandleButton button; public ClutterSliderHandleButton Button { @@ -94,6 +99,7 @@ SetSize(width, height); button = new ClutterSliderHandleButton((uint) Height,(uint) Height,state); + button.BubbleEvents = true; Add(button); button.Show(); UpdatePosition(); @@ -118,7 +124,7 @@ protected virtual void HandleEnterEvent (object o, EnterEventArgs args) { button.State |= 1; - args.RetVal = true; + args.RetVal = !BubbleEvents; } public new void SetSize (float width, float height) @@ -159,7 +165,7 @@ protected virtual void HandleLeaveEvent (object o, LeaveEventArgs args) { button.State &= 2; - args.RetVal = true; + args.RetVal = !BubbleEvents; } protected void HandleMotionEvent (object o, MotionEventArgs args) diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/CoverManager.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/CoverManager.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/CoverManager.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/CoverManager.cs 2010-03-31 19:37:31.000000000 +0100 @@ -28,6 +28,8 @@ using System; using System.Collections.Generic; +using ClutterFlow.Alphabet; + using Clutter; using Gtk; using GLib; @@ -65,15 +67,23 @@ } public event EventHandler TextureSizeChanged; - protected void InvokeTextureSizeChanged () { + protected void InvokeTextureSizeChanged () + { //TODO use a timeout here, if the function is called mutliple times shortly after another, we don't get endless recalculation if (TextureSizeChanged!=null) TextureSizeChanged (this, EventArgs.Empty); } - public EventHandler VisibleCoversChanged; - protected void InvokeVisibleCoversChanged () { - if (VisibleCoversChanged!=null) VisibleCoversChanged(this, EventArgs.Empty);; + public event EventHandler VisibleCoversChanged; + protected void InvokeVisibleCoversChanged () + { + if (VisibleCoversChanged!=null) VisibleCoversChanged(this, EventArgs.Empty); } + + public event EventHandler LetterLookupChanged; + protected void InvokeLetterLookupChanged () + { + if (LetterLookupChanged!=null) LetterLookupChanged(this, EventArgs.Empty);; + } #endregion @@ -95,6 +105,29 @@ internal set { actorLoader = value; } } + public Dictionary letter_lookup; + public Dictionary LetterLookup { + get { return letter_lookup; } + } + + public void ResetLetterLookup () { + letter_lookup = new Dictionary(); + foreach (AlphabetChars key in Enum.GetValues(typeof(AlphabetChars))) + letter_lookup.Add(key, -1); + Console.WriteLine ("ResetLetterLookup called, letter_lookup is " + (letter_lookup == null ? "null" : "not null")); + } + public void UpdateLetterLookup (ClutterFlowBaseActor actor) { + string label = actor.SortLabel.ToUpper (); + char letter = label.Length>0 ? char.Parse(label.Substring (0,1)) : '?'; + AlphabetChars key; + if (char.IsLetter(letter)) + key = (AlphabetChars) letter; + else + key = AlphabetChars.unkown; + if (letter_lookup[key]==-1) + letter_lookup[key] = actor.Index; + } + protected FlowBehaviour behaviour; public FlowBehaviour Behaviour { get { return behaviour; } @@ -267,12 +300,6 @@ int old_target_index = CurrentCover!=null ? covers.IndexOf (CurrentCover) : 0; // the old current index int new_target_index = 0; // the newly calculated index bool keep_current = false; // wether or not to keep the current cover centered - - /* Bugs: - * FIXED - when a search is cleared (or reduced) the TargetIndex is set to 4, never to the correct cover - * FIXED - when searching fast visible covers stay visible - * FIXED - when no results are found, no matches should be displayed - */ List old_covers = new List(SafeGetRange(covers, old_target_index - HalfVisCovers - 1, visibleCovers + 2)); foreach (ClutterFlowBaseActor actor in covers) { @@ -282,13 +309,17 @@ actor.Data.Add ("isOldCover", true); } - + ResetLetterLookup (); List persistent_covers = new List(); - covers = actorLoader.GetActors (delegate (ClutterFlowBaseActor actor) { + + covers = new List(actorLoader.GetActors (delegate (ClutterFlowBaseActor actor) { if (actor.Data.ContainsKey ("isOldCover")) persistent_covers.Add (actor); if (CurrentCover==actor) keep_current = true; - }); + + UpdateLetterLookup (actor); + })); + InvokeLetterLookupChanged (); if (covers.Count==0) { InstallEmptyActor (); @@ -353,7 +384,9 @@ Behaviour.FadeCoversInAndOut (old_covers, truly_pers, new_covers, update_target); } else { //Console.WriteLine("Loading Covers"); - covers = actorLoader.GetActors (null); + ResetLetterLookup (); + covers = actorLoader.GetActors (UpdateLetterLookup); + InvokeLetterLookupChanged (); TargetIndex = 0; Timeline.JumpToTarget (); if (covers==null || covers.Count==0) { diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/FlowBehaviour.cs banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/FlowBehaviour.cs --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/FlowBehaviour.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/FlowBehaviour.cs 2010-03-23 16:37:38.000000000 +0000 @@ -522,25 +522,37 @@ FadeCoversInAndOut (transition_queue.Dequeue()); } - public void CreateClickedCloneAnimation (ClutterFlowBaseActor actor) { + public void CreateClickedCloneAnimation (ClutterFlowBaseActor actor, uint delay) + { if (actor.Parent!=null) { Clone clone = new Clone(actor); MoveAndRotateActorCentrally (clone, 0); double scaleX, scaleY; actor.GetScale (out scaleX, out scaleY); clone.SetScale (scaleX, scaleY); ((Container) actor.Parent).Add (clone); - clone.ShowAll (); + clone.Hide (); clone.Opacity = 255; - clone.Raise (actor); - Animation anmn = clone.Animatev ((ulong) AnimationMode.EaseInExpo.value__, CoverManager.MaxAnimationSpan*4, new string[] { "opacity" }, new GLib.Value ((byte) 50)); + clone.Depth = ZNear+1; + Timeline timeline = new Timeline (CoverManager.MaxAnimationSpan*4); + timeline.Delay = delay; + timeline.AddMarkerAtTime ("start", 1); + timeline.MarkerReached += delegate { + clone.ShowAll (); + }; + Animation anmn = clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, timeline, new string[] { "opacity" }, new GLib.Value ((byte) 50)); + clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, timeline, new string[] { "scale-x" }, new GLib.Value (scaleX*2)); + clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, timeline, new string[] { "scale-y" }, new GLib.Value (scaleY*2)); + clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, timeline, new string[] { "fixed::anchor-x" }, new GLib.Value (clone.Width/2)); + clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, timeline, new string[] { "fixed::anchor-y" }, new GLib.Value (clone.Height/4)); anmn.Completed += HandleClickedCloneCompleted; - clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, anmn.Timeline, new string[] { "scale-x" }, new GLib.Value (scaleX*2)); - clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, anmn.Timeline, new string[] { "scale-y" }, new GLib.Value (scaleY*2)); - clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, anmn.Timeline, new string[] { "fixed::anchor-x" }, new GLib.Value (clone.Width/2)); - clone.AnimateWithTimelinev ((ulong) AnimationMode.EaseInExpo.value__, anmn.Timeline, new string[] { "fixed::anchor-y" }, new GLib.Value (clone.Height/4)); } } + public void CreateClickedCloneAnimation (ClutterFlowBaseActor actor) + { + CreateClickedCloneAnimation (actor, 0); + } + protected void HandleClickedCloneCompleted (object sender, EventArgs e) { if (sender is Animation && (sender as Animation).Object is Actor) { diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/Makefile.am banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/Makefile.am --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/Makefile.am 2010-03-10 18:04:37.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/Makefile.am 2010-03-31 19:37:31.000000000 +0100 @@ -3,25 +3,27 @@ GMCS_FLAGS = -unsafe SOURCES = \ - ClutterSlider.cs \ - ClutterSliderHandleButton.cs \ - ClutterButton.cs \ - ClutterSliderHandle.cs \ - ClutterArrowButton.cs \ - ClutterHelper.cs \ - ClutterFlowSlider.cs \ - ClutterFlowTimeline.cs \ - CoverCaption.cs \ - CoverManager.cs \ - FlowBehaviour.cs \ - ClutterFlowActor.cs \ - ClutterFlowFixedActor.cs \ - ActorLoader.cs \ - ClutterWidgetBar.cs \ - ClutterGenericButton.cs \ - ClutterToggleButton.cs \ - TrackCaption.cs \ - Caption.cs + ActorLoader.cs \ + AlphabetBar.cs \ + AlphabetButton.cs \ + Caption.cs \ + ClutterArrowButton.cs \ + ClutterButton.cs \ + ClutterFlowActor.cs \ + ClutterFlowFixedActor.cs \ + ClutterFlowSlider.cs \ + ClutterFlowTimeline.cs \ + ClutterGenericButton.cs \ + ClutterHelper.cs \ + ClutterSlider.cs \ + ClutterSliderHandle.cs \ + ClutterSliderHandleButton.cs \ + ClutterToggleButton.cs \ + ClutterWidgetBar.cs \ + CoverCaption.cs \ + CoverManager.cs \ + FlowBehaviour.cs \ + TrackCaption.cs if ENABLE_CLUTTERFLOW include $(top_srcdir)/build/build.mk diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/Makefile.in banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/Makefile.in --- banshee-community-extensions-1.5.5/src/ClutterFlow/ClutterFlow/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/ClutterFlow/Makefile.in 2010-03-31 19:47:52.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/ClutterFlow/ClutterFlow ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ @@ -287,25 +292,27 @@ LINK = $(CLUTTER_SHARP_LIBS) -r:Mono.Cairo -pkg:gtk-sharp-2.0 \ $(am__append_1) SOURCES = \ - ClutterSlider.cs \ - ClutterSliderHandleButton.cs \ - ClutterButton.cs \ - ClutterSliderHandle.cs \ - ClutterArrowButton.cs \ - ClutterHelper.cs \ - ClutterFlowSlider.cs \ - ClutterFlowTimeline.cs \ - CoverCaption.cs \ - CoverManager.cs \ - FlowBehaviour.cs \ - ClutterFlowActor.cs \ - ClutterFlowFixedActor.cs \ - ActorLoader.cs \ - ClutterWidgetBar.cs \ - ClutterGenericButton.cs \ - ClutterToggleButton.cs \ - TrackCaption.cs \ - Caption.cs + ActorLoader.cs \ + AlphabetBar.cs \ + AlphabetButton.cs \ + Caption.cs \ + ClutterArrowButton.cs \ + ClutterButton.cs \ + ClutterFlowActor.cs \ + ClutterFlowFixedActor.cs \ + ClutterFlowSlider.cs \ + ClutterFlowTimeline.cs \ + ClutterGenericButton.cs \ + ClutterHelper.cs \ + ClutterSlider.cs \ + ClutterSliderHandle.cs \ + ClutterSliderHandleButton.cs \ + ClutterToggleButton.cs \ + ClutterWidgetBar.cs \ + CoverCaption.cs \ + CoverManager.cs \ + FlowBehaviour.cs \ + TrackCaption.cs # Initializers diff -Nru banshee-community-extensions-1.5.5/src/ClutterFlow/Makefile.in banshee-community-extensions-1.6.0/src/ClutterFlow/Makefile.in --- banshee-community-extensions-1.5.5/src/ClutterFlow/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/ClutterFlow/Makefile.in 2010-03-31 19:47:52.000000000 +0100 @@ -35,6 +35,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -82,6 +83,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -197,6 +200,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/CoverWallpaper/Banshee.CoverWallpaper.addin.xml banshee-community-extensions-1.6.0/src/CoverWallpaper/Banshee.CoverWallpaper.addin.xml --- banshee-community-extensions-1.5.5/src/CoverWallpaper/Banshee.CoverWallpaper.addin.xml 2010-03-01 19:53:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/CoverWallpaper/Banshee.CoverWallpaper.addin.xml 2010-03-26 22:37:09.000000000 +0000 @@ -11,6 +11,8 @@ url="http://code.google.com/p/banshee-unofficial-plugins/" defaultEnabled="false"> + + diff -Nru banshee-community-extensions-1.5.5/src/CoverWallpaper/Makefile.in banshee-community-extensions-1.6.0/src/CoverWallpaper/Makefile.in --- banshee-community-extensions-1.5.5/src/CoverWallpaper/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/CoverWallpaper/Makefile.in 2010-03-31 19:47:52.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/CoverWallpaper ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/LCD/Banshee.LCD/ConfigurationDialog.cs banshee-community-extensions-1.6.0/src/LCD/Banshee.LCD/ConfigurationDialog.cs --- banshee-community-extensions-1.5.5/src/LCD/Banshee.LCD/ConfigurationDialog.cs 2010-02-17 20:56:20.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/LCD/Banshee.LCD/ConfigurationDialog.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,7 +28,7 @@ using System; using Gtk; -using Mono.Unix; +using Mono.Addins; namespace Banshee.LCD { @@ -43,7 +43,7 @@ public ConfigurationDialog (LCDService plugin) { this.plugin = plugin; - Title = Catalog.GetString ("LCD configuration"); + Title = AddinManager.CurrentLocalizer.GetString ("LCD configuration"); BorderWidth = 5; HasSeparator = false; Resizable = false; @@ -51,20 +51,20 @@ VBox lcdproc_box = new VBox (); HBox host_box = new HBox (); - host_box.PackStart (new Label (Catalog.GetString ("Hostname:")), false, false, 3); + host_box.PackStart (new Label (AddinManager.CurrentLocalizer.GetString ("Hostname:")), false, false, 3); host_entry = new Entry (); host_box.PackStart (host_entry, true, true, 3); host_entry.Text = this.plugin.Host; host_entry.Changed += new EventHandler (Host_Changed); HBox port_box = new HBox (); - port_box.PackStart (new Label (Catalog.GetString ("Port:")), false, false, 3); + port_box.PackStart (new Label (AddinManager.CurrentLocalizer.GetString ("Port:")), false, false, 3); port_spin = new SpinButton (1, 65535, 1); port_box.PackStart (port_spin, true, true, 3); port_spin.Value = this.plugin.Port; port_spin.Changed += new EventHandler (Port_Changed); - Frame lcdproc_frame = new Frame (Catalog.GetString ("LCDProc Daemon:")); + Frame lcdproc_frame = new Frame (AddinManager.CurrentLocalizer.GetString ("LCDProc Daemon:")); lcdproc_box.PackStart (host_box); lcdproc_box.PackStart (port_box); lcdproc_frame.Add (lcdproc_box); diff -Nru banshee-community-extensions-1.5.5/src/LCD/Banshee.LCD/LCDService.cs banshee-community-extensions-1.6.0/src/LCD/Banshee.LCD/LCDService.cs --- banshee-community-extensions-1.5.5/src/LCD/Banshee.LCD/LCDService.cs 2010-02-17 20:56:20.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/LCD/Banshee.LCD/LCDService.cs 2010-03-26 22:37:09.000000000 +0000 @@ -30,7 +30,7 @@ using System.Collections.Generic; //using System.Threading; -using Mono.Unix; +using Mono.Addins; using Gtk; @@ -67,11 +67,11 @@ actions = new ActionGroup ("LCD"); actions.Add (new ActionEntry [] { new ActionEntry ("LCDAction", null, - Catalog.GetString ("LCD"), null, + AddinManager.CurrentLocalizer.GetString ("LCD"), null, null, null), new ActionEntry ("LCDConfigureAction", Stock.Properties, - Catalog.GetString ("_Configure..."), null, - Catalog.GetString ("Configure the LCD plugin"), OnConfigure) + AddinManager.CurrentLocalizer.GetString ("_Configure..."), null, + AddinManager.CurrentLocalizer.GetString ("Configure the LCD plugin"), OnConfigure) }); action_service.UIManager.InsertActionGroup (actions, 0); ui_manager_id = action_service.UIManager.AddUiFromResource ("LCDMenu.xml"); diff -Nru banshee-community-extensions-1.5.5/src/LCD/Makefile.in banshee-community-extensions-1.6.0/src/LCD/Makefile.in --- banshee-community-extensions-1.5.5/src/LCD/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/LCD/Makefile.in 2010-03-31 19:47:52.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/LCD ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Lirc/Banshee.Lirc/Banshee.Lirc.addin.xml banshee-community-extensions-1.6.0/src/Lirc/Banshee.Lirc/Banshee.Lirc.addin.xml --- banshee-community-extensions-1.5.5/src/Lirc/Banshee.Lirc/Banshee.Lirc.addin.xml 2010-02-22 23:43:25.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lirc/Banshee.Lirc/Banshee.Lirc.addin.xml 2010-03-26 22:37:09.000000000 +0000 @@ -12,6 +12,8 @@ url="" defaultEnabled="false"> + + diff -Nru banshee-community-extensions-1.5.5/src/Lirc/Banshee.Lirc/Makefile.in banshee-community-extensions-1.6.0/src/Lirc/Banshee.Lirc/Makefile.in --- banshee-community-extensions-1.5.5/src/Lirc/Banshee.Lirc/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lirc/Banshee.Lirc/Makefile.in 2010-03-31 19:47:52.000000000 +0100 @@ -41,6 +41,7 @@ subdir = src/Lirc/Banshee.Lirc ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -86,6 +87,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -201,6 +204,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Lirc/GUITestHarness/Makefile.in banshee-community-extensions-1.6.0/src/Lirc/GUITestHarness/Makefile.in --- banshee-community-extensions-1.5.5/src/Lirc/GUITestHarness/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lirc/GUITestHarness/Makefile.in 2010-03-31 19:47:53.000000000 +0100 @@ -35,6 +35,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -69,6 +70,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -184,6 +187,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Lirc/lirc-glue/Makefile.in banshee-community-extensions-1.6.0/src/Lirc/lirc-glue/Makefile.in --- banshee-community-extensions-1.5.5/src/Lirc/lirc-glue/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lirc/lirc-glue/Makefile.in 2010-03-31 19:47:54.000000000 +0100 @@ -36,6 +36,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -102,6 +103,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -217,6 +220,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Lirc/Makefile.in banshee-community-extensions-1.6.0/src/Lirc/Makefile.in --- banshee-community-extensions-1.5.5/src/Lirc/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lirc/Makefile.in 2010-03-31 19:47:53.000000000 +0100 @@ -35,6 +35,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ChangeLog ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -82,6 +83,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -197,6 +200,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Lirc/NUnitTests/Makefile.in banshee-community-extensions-1.6.0/src/Lirc/NUnitTests/Makefile.in --- banshee-community-extensions-1.5.5/src/Lirc/NUnitTests/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lirc/NUnitTests/Makefile.in 2010-03-31 19:47:53.000000000 +0100 @@ -35,6 +35,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -69,6 +70,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -184,6 +187,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/LiveRadio/Banshee.LiveRadio/LiveRadioFilterView.cs banshee-community-extensions-1.6.0/src/LiveRadio/Banshee.LiveRadio/LiveRadioFilterView.cs --- banshee-community-extensions-1.5.5/src/LiveRadio/Banshee.LiveRadio/LiveRadioFilterView.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/LiveRadio/Banshee.LiveRadio/LiveRadioFilterView.cs 2010-03-23 16:37:38.000000000 +0000 @@ -64,7 +64,6 @@ private ListView genre_view; private Entry query_input; private Button query_button; - private SearchEntry fake_search_entry; /// /// Event is raised when a genre is clicked in the genre choose box @@ -98,8 +97,6 @@ query_box.BorderWidth = 1; query_input = new Entry (); query_input.KeyReleaseEvent += OnInputKeyReleaseEvent; - query_input.FocusInEvent += OnQueryFocusInEvent; - query_input.FocusOutEvent += OnQueryFocusOutEvent; query_button = new Button (Stock.Find); query_button.Clicked += OnViewQuerySent; query_box.PackStart (query_input, true, true, 5); @@ -111,80 +108,6 @@ } /// - /// Removes the hack that prevents the "s" key capture - /// - /// - /// A -- not used - /// - /// - /// A -- not used - /// - void OnQueryFocusOutEvent (object o, FocusOutEventArgs args) - { - Widget w = this.Parent.Parent.Parent; - if (w is Container) - { - SearchEntry searchEntry = WidgetFindRecursive (w as Container, "Banshee_Widgets_SearchEntry") as SearchEntry; - fake_search_entry.Destroy (); - searchEntry.Visible = true; - } - } - - /// - /// Finds one widget inside the container for that part of its name matches the searcharg - /// - /// - /// A that contains the elements to be recursivly searched - /// - /// - /// A that contains the name or part of the name of the widget to be found - /// - /// - /// A that matches the search criteria. If there are more than one widget in the - /// container, it cannot be definately said which one will be returned - /// - private Widget WidgetFindRecursive (Container c, string searcharg) - { - foreach (Widget cw in c.Children) - { - if (cw.Name.Contains (searcharg)) return cw; - if (cw is Container) - { - Widget res = WidgetFindRecursive (cw as Container, searcharg); - if (res != null) return res; - } - } - return null; - } - - /// - /// Captures the Entry's FocusIn event to apply a hack to prevent capturing the "S" key - /// - /// - /// A -- not used - /// - /// - /// A -- not used - /// - void OnQueryFocusInEvent (object o, FocusInEventArgs args) - { - Widget w = this.Parent.Parent.Parent; - if (w is Container) - { - SearchEntry searchEntry = WidgetFindRecursive (w as Container, "Banshee_Widgets_SearchEntry") as SearchEntry; - if (searchEntry != null) - { - fake_search_entry = new SearchEntry (); - fake_search_entry.SetSizeRequest (260, -1); - (searchEntry.Parent as HBox).PackStart (fake_search_entry, false, false, 0); - fake_search_entry.Sensitive = false; - fake_search_entry.Show (); - searchEntry.Visible = false; - } - } - } - - /// /// Captures the press of the RETURN key within the query field and delegates to OnViewQuerySent /// /// diff -Nru banshee-community-extensions-1.5.5/src/LiveRadio/Banshee.LiveRadio/LiveRadioSource.cs banshee-community-extensions-1.6.0/src/LiveRadio/Banshee.LiveRadio/LiveRadioSource.cs --- banshee-community-extensions-1.5.5/src/LiveRadio/Banshee.LiveRadio/LiveRadioSource.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/LiveRadio/Banshee.LiveRadio/LiveRadioSource.cs 2010-03-23 16:37:38.000000000 +0000 @@ -54,8 +54,13 @@ /// The main class of the LiveRadio Extension. It creates a new primary source in the source trees and adds /// child sources for each internet radio plugin detected. /// - /// TODO: - /// * edit PO files + /// TODO by priority: + /// * combined search/results for all plugins + /// * add option to use system proxy -- move to banshee.io.httprequest + /// * use Mono.Addins for plugins + /// * save/cancel/apply button in config -> close -> save changes immediately + /// ** not sure if this can be done safely, configuration widget delivered + /// by plugins, might need to extend interface or move logic completely to plugin /// public class LiveRadioSource : PrimarySource, IDisposable { diff -Nru banshee-community-extensions-1.5.5/src/LiveRadio/Makefile.in banshee-community-extensions-1.6.0/src/LiveRadio/Makefile.in --- banshee-community-extensions-1.5.5/src/LiveRadio/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/LiveRadio/Makefile.in 2010-03-31 19:47:54.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/LiveRadio ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsDownloadJob.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsDownloadJob.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsDownloadJob.cs 2010-02-15 19:05:50.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsDownloadJob.cs 2010-03-26 22:37:09.000000000 +0000 @@ -1,7 +1,7 @@ using System; -using Mono.Unix; +using Mono.Addins; using Banshee.Base; using Banshee.ServiceStack; @@ -17,7 +17,7 @@ { public class LyricsDownloadJob : DbIteratorJob { - public LyricsDownloadJob (bool force) : base(Catalog.GetString ("Downloading Lyrics")) + public LyricsDownloadJob (bool force) : base (AddinManager.CurrentLocalizer.GetString ("Downloading Lyrics")) { PriorityHints = PriorityHints.LongRunning; IsBackground = true; @@ -61,7 +61,8 @@ DbId = reader.Get (0), }; - Status = String.Format (Catalog.GetString ("{0} - {1}"), track.ArtistName, track.TrackTitle); + Status = String.Format (AddinManager.CurrentLocalizer.GetString ("{0} - {1}"), + track.ArtistName, track.TrackTitle); DownloadLyrics (track); } diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsManager.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsManager.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsManager.cs 2010-02-15 19:05:50.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsManager.cs 2010-03-26 22:37:09.000000000 +0000 @@ -25,18 +25,14 @@ // using System; -using System.Threading; using System.Collections.Generic; -using Mono.Unix; - using Banshee.Networking; using Banshee.ServiceStack; using Banshee.Collection; using Banshee.Lyrics.Sources; using Banshee.Lyrics.IO; -using Banshee.Lyrics.Gui; using Banshee.Streaming; using Hyena; @@ -80,6 +76,7 @@ sourceList.Add (new Lyriki ()); sourceList.Add (new AutoLyrics ()); sourceList.Add (new LyricWiki ()); + sourceList.Add (new LyricsPlugin ()); } internal static LyricsManager Instance { diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsService.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsService.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsService.cs 2010-02-15 19:05:50.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics/LyricsService.cs 2010-03-26 22:37:09.000000000 +0000 @@ -30,7 +30,7 @@ using Gtk; -using Mono.Unix; +using Mono.Addins; using Banshee.Gui; using Banshee.Sources; @@ -168,17 +168,17 @@ lyrics_action_group.Add (new ActionEntry[] { new ActionEntry ("LyricsAction", null, - Catalog.GetString ("L_yrics"), null, - Catalog.GetString ("Manage Lyrics"), null), + AddinManager.CurrentLocalizer.GetString ("L_yrics"), null, + AddinManager.CurrentLocalizer.GetString ("Manage Lyrics"), null), new ActionEntry ("FetchLyricsAction", null, - Catalog.GetString ("_Download Lyrics"), null, - Catalog.GetString ("Download lyrics for all tracks"), OnFetchLyrics) + AddinManager.CurrentLocalizer.GetString ("_Download Lyrics"), null, + AddinManager.CurrentLocalizer.GetString ("Download lyrics for all tracks"), OnFetchLyrics) }); lyrics_action_group.Add (new ToggleActionEntry[] { new ToggleActionEntry ("ShowLyricsAction", null, - Catalog.GetString ("Show Lyrics"), "T", - Catalog.GetString ("Show Lyrics in a separate window"), null, false) }); + AddinManager.CurrentLocalizer.GetString ("Show Lyrics"), "T", + AddinManager.CurrentLocalizer.GetString ("Show Lyrics in a separate window"), null, false) }); lyrics_action_group.GetAction ("ShowLyricsAction").Activated += OnToggleWindow; lyrics_action_group.GetAction ("ShowLyricsAction").Sensitive = ServiceManager.PlayerEngine.CurrentTrack != null ? true : false; diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/ContextPage.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/ContextPage.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/ContextPage.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/ContextPage.cs 2010-03-26 22:37:09.000000000 +0000 @@ -25,9 +25,7 @@ // using System; -using Mono.Unix; - -using Banshee.Lyrics.Gui; +using Mono.Addins; using Banshee.ContextPane; @@ -44,7 +42,7 @@ public ContextPage () { Id = "lyrics"; - Name = Catalog.GetString ("Lyrics"); + Name = AddinManager.CurrentLocalizer.GetString ("Lyrics"); IconNames = new string[] { "preferences-desktop-font" , "gtk-edit" }; } diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsBrowser.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsBrowser.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsBrowser.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsBrowser.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,7 +28,7 @@ using System; using System.Text; -using Mono.Unix; +using Mono.Addins; using System.Threading; using WebKit; using Banshee.ServiceStack; @@ -61,7 +61,7 @@ if (!IsValidUri (request.Uri)) { return -1; } - if (request.Uri == Catalog.GetString ("add")) { + if (request.Uri == AddinManager.CurrentLocalizer.GetString ("add")) { AddLinkClicked (this, null); } else { LyricsManager.Instance.FetchLyricsFromLyrc (request.Uri); @@ -111,7 +111,7 @@ } else if (args.lyrics != null) { browser_str = Utils.ToHtml(args.lyrics); } else { - browser_str = Catalog.GetString ("No lyrics found."); + browser_str = AddinManager.CurrentLocalizer.GetString ("No lyrics found."); } LoadString (browser_str); @@ -120,14 +120,14 @@ private string GetSuggestionString (string lyrics_suggestion) { StringBuilder sb = new StringBuilder (); - sb.Append ("" + Catalog.GetString ("No lyrics found.") + ""); + sb.Append ("" + AddinManager.CurrentLocalizer.GetString ("No lyrics found.") + ""); if (InsertModeAvailable) { - sb.Append ("
"); - sb.Append (Catalog.GetString ("Click here to manually add a new lyric")); + sb.Append ("
"); + sb.Append (AddinManager.CurrentLocalizer.GetString ("Click here to manually add a new lyric")); sb.Append (""); } sb.Append ("

"); - sb.Append (Catalog.GetString ("Suggestions:")); + sb.Append (AddinManager.CurrentLocalizer.GetString ("Suggestions:")); sb.Append (lyrics_suggestion); return sb.ToString (); @@ -135,7 +135,8 @@ public void OnLoading (object o, EventArgs args) { - String str = "
" + Catalog.GetString ("Loading...") + "
"; + String str = "
" + + AddinManager.CurrentLocalizer.GetString ("Loading...") + "
"; LoadString(str); } diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsPane.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsPane.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsPane.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsPane.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,7 +28,7 @@ using System; -using Mono.Unix; +using Mono.Addins; using Banshee.ContextPane; @@ -105,7 +105,7 @@ private void UpdateLabel () { if (!string.IsNullOrEmpty (track_title)) { - label.Text = "" + track_title + Catalog.GetString (" lyric") + ""; + label.Text = "" + track_title + AddinManager.CurrentLocalizer.GetString (" lyric") + ""; label.UseMarkup = true; } this.ShowAll (); diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsWindow.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsWindow.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsWindow.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Gui/LyricsWindow.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,7 +28,7 @@ using System.IO; using System.Threading; -using Mono.Unix; +using Mono.Addins; using Gtk; using Gdk; @@ -80,10 +80,10 @@ } string window_title = ServiceManager.PlayerEngine.CurrentTrack.TrackTitle; - string by_str = " " + Catalog.GetString ("by") + " "; + string by_str = " " + AddinManager.CurrentLocalizer.GetString ("by") + " "; string artist = ServiceManager.PlayerEngine.CurrentTrack.ArtistName; if (artist == null) { - artist = Catalog.GetString ("Unknown Artist"); + artist = AddinManager.CurrentLocalizer.GetString ("Unknown Artist"); } window_title += by_str + artist; this.Title = window_title; diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Network/HttpUtils.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Network/HttpUtils.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Network/HttpUtils.cs 2010-03-01 19:53:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Network/HttpUtils.cs 2010-03-18 22:47:33.000000000 +0000 @@ -33,12 +33,12 @@ { public class HttpUtils { - public static string ReadHtmlContent (String url) + public static string ReadHtmlContent (String url, Encoding encoding) { string html = null; try { - html = GetHtml (url); + html = GetHtml (url, encoding); } catch (Exception e) { Hyena.Log.DebugFormat ("{0}, {1}", e.Message, url); @@ -47,7 +47,7 @@ return html; } - private static string GetHtml (string url) + private static string GetHtml (string url, Encoding encoding) { HttpWebRequest request = (HttpWebRequest)WebRequest.Create (url); request.Timeout = 6000; @@ -61,23 +61,24 @@ } } - HttpWebResponse response = (HttpWebResponse)request.GetResponse (); - if (response.ContentLength == 0) { - return null; - } - - StreamReader reader; - if (response.ContentType.Contains ("utf")) { - reader = new StreamReader (response.GetResponseStream ()); - } else { - reader = new StreamReader (response.GetResponseStream (), Encoding.GetEncoding ("iso-8859-1")); - } + using (var response = (HttpWebResponse)request.GetResponse ()) { + if (response.ContentLength == 0) { + return null; + } - //read all bytes from the stream - string source = reader.ReadToEnd (); - reader.Close (); + if (encoding == null) { + if (response.ContentType.Contains ("utf")) { + encoding = Encoding.UTF8; + } else { + encoding = Encoding.GetEncoding ("iso-8859-1"); + } + } - return source; + using (var reader = new StreamReader (response.GetResponseStream (), encoding)) { + // Read all bytes from the stream + return reader.ReadToEnd (); + } + } } } } \ No newline at end of file diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/AutoLyrics.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/AutoLyrics.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/AutoLyrics.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/AutoLyrics.cs 2010-03-26 22:37:09.000000000 +0000 @@ -24,9 +24,7 @@ // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // -using System; using System.Text.RegularExpressions; -using Mono.Unix; namespace Banshee.Lyrics.Sources { diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LeosLyrics.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LeosLyrics.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LeosLyrics.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LeosLyrics.cs 2010-03-18 22:47:33.000000000 +0000 @@ -66,7 +66,7 @@ string search_url = string.Format ("http://api.leoslyrics.com/api_search.php?auth=duane&artist={0}&songtitle={1}", artist, title); - string xml = HttpUtils.ReadHtmlContent (search_url); + string xml = HttpUtils.ReadHtmlContent (search_url, null); return xml; } @@ -74,7 +74,7 @@ { /*query for the lyric xml */ string lyric_url = "http://api.leoslyrics.com/api_lyrics.php?auth=duane&hid=" + hid; - string lyric_xml = HttpUtils.ReadHtmlContent (lyric_url); + string lyric_xml = HttpUtils.ReadHtmlContent (lyric_url, null); if (lyric_xml == null) { return null; } diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/Lyrc.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/Lyrc.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/Lyrc.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/Lyrc.cs 2010-03-26 22:37:09.000000000 +0000 @@ -24,11 +24,9 @@ // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // -using System; using System.Web; using System.Text.RegularExpressions; -using Mono.Unix; namespace Banshee.Lyrics.Sources { diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsPlugin.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsPlugin.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsPlugin.cs 1970-01-01 01:00:00.000000000 +0100 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsPlugin.cs 2010-03-18 22:47:33.000000000 +0000 @@ -0,0 +1,79 @@ +// +// Author: +// Alexander Kojevnikov +// +// Copyright (C) 2010 Alexander Kojevnikov +// +// Permission is hereby granted, free of charge, to any person obtaining +// a copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to +// permit persons to whom the Software is furnished to do so, subject to +// the following conditions: +// +// The above copyright notice and this permission notice shall be +// included in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +// + +using System; +using System.Web; +using System.Text; +using System.Text.RegularExpressions; + +namespace Banshee.Lyrics.Sources +{ + public class LyricsPlugin : LyricsWebSource + { + public LyricsPlugin () + { + base.regexLyric = new Regex ( + @"
(.*?)
", + RegexOptions.Multiline | RegexOptions.IgnoreCase | RegexOptions.Singleline); + } + + public override string Name { + get { return "LyricsPlugin"; } + } + + public override string Url { + get { return "http://www.lyricsplugin.com"; } + } + + public override string GetLyrics (string artist, string title) + { + string lyrics = base.GetLyrics (artist, title); + + if (lyrics == null || lyrics.Trim().Length == 0) { + return null; + } + + return lyrics; + } + + protected override string GetLyricUrl (string artist, string title) + { + string url_artist = HttpUtility.UrlEncode (CleanArtistName (artist)); + string url_title = HttpUtility.UrlEncode (CleanSongTitle (title)); + return String.Format ("{0}/plugin/?title={1}&artist={2}", Url, url_title, url_artist); + } + + protected override string GetSuggestionUrl (string artist, string title) + { + return null; + } + + protected override Encoding Encoding { + get { return Encoding.UTF8; } + } + + } +} \ No newline at end of file diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsWebSource.cs banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsWebSource.cs --- banshee-community-extensions-1.5.5/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsWebSource.cs 2010-02-15 19:05:49.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsWebSource.cs 2010-03-26 22:37:09.000000000 +0000 @@ -24,9 +24,10 @@ // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // using System; +using System.Text; using System.Text.RegularExpressions; -using Mono.Unix; +using Mono.Addins; using Banshee.IO; @@ -46,7 +47,8 @@ public string Credits { get { - return string.Format ("Powered by {0} ({1})", Name, Url); + return string.Format (AddinManager.CurrentLocalizer.GetString ("Powered by {0} ({1})"), + Name, Url); } } @@ -94,6 +96,10 @@ return title.EndsWith (" ") ? title.Substring (0, title.Length - 1) : title; } + protected virtual Encoding Encoding { + get { return null; } + } + /*parse the content of an url using a regular expression to filter the content */ public string ParseUrl (string url, Regex r) { @@ -101,7 +107,7 @@ return null; } - string html = HttpUtils.ReadHtmlContent (url); + string html = HttpUtils.ReadHtmlContent (url, this.Encoding); if (html == null) { return null; } diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Makefile.am banshee-community-extensions-1.6.0/src/Lyrics/Makefile.am --- banshee-community-extensions-1.5.5/src/Lyrics/Makefile.am 2010-02-15 19:05:50.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Makefile.am 2010-03-18 22:47:33.000000000 +0000 @@ -15,6 +15,7 @@ Banshee.Lyrics/Banshee.Lyrics.Sources/ILyricsSource.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/LeosLyrics.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/Lyrc.cs \ + Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsPlugin.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsWebSource.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/LyricWiki.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/Lyriki.cs \ diff -Nru banshee-community-extensions-1.5.5/src/Lyrics/Makefile.in banshee-community-extensions-1.6.0/src/Lyrics/Makefile.in --- banshee-community-extensions-1.5.5/src/Lyrics/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Lyrics/Makefile.in 2010-03-31 19:47:54.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/Lyrics ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ @@ -300,6 +305,7 @@ Banshee.Lyrics/Banshee.Lyrics.Sources/ILyricsSource.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/LeosLyrics.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/Lyrc.cs \ + Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsPlugin.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/LyricsWebSource.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/LyricWiki.cs \ Banshee.Lyrics/Banshee.Lyrics.Sources/Lyriki.cs \ diff -Nru banshee-community-extensions-1.5.5/src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs banshee-community-extensions-1.6.0/src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs --- banshee-community-extensions-1.5.5/src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Magnatune/Banshee.Magnatune/gtk-gui/Magnatune.Configuration.cs 2010-03-11 17:06:49.000000000 +0000 @@ -66,7 +66,7 @@ this.username.CanFocus = true; this.username.Name = "username"; this.username.IsEditable = true; - this.username.InvisibleChar = '●'; + this.username.InvisibleChar = '\u25cf'; this.hbox2.Add(this.username); Gtk.Box.BoxChild w3 = ((Gtk.Box.BoxChild)(this.hbox2[this.username])); w3.Position = 1; @@ -94,7 +94,7 @@ this.password.Name = "password"; this.password.IsEditable = true; this.password.Visibility = false; - this.password.InvisibleChar = '●'; + this.password.InvisibleChar = '\u25cf'; this.hbox1.Add(this.password); Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(this.hbox1[this.password])); w6.Position = 1; diff -Nru banshee-community-extensions-1.5.5/src/Magnatune/Magnatune.addin.xml banshee-community-extensions-1.6.0/src/Magnatune/Magnatune.addin.xml --- banshee-community-extensions-1.5.5/src/Magnatune/Magnatune.addin.xml 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Magnatune/Magnatune.addin.xml 2010-03-26 22:37:09.000000000 +0000 @@ -11,6 +11,8 @@ url="http://magnatune.code.worldmaker.net/" defaultEnabled="false"> + + diff -Nru banshee-community-extensions-1.5.5/src/Magnatune/Makefile.in banshee-community-extensions-1.6.0/src/Magnatune/Makefile.in --- banshee-community-extensions-1.5.5/src/Magnatune/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Magnatune/Makefile.in 2010-03-31 19:47:54.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/Magnatune ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Makefile.am banshee-community-extensions-1.6.0/src/Makefile.am --- banshee-community-extensions-1.5.5/src/Makefile.am 2010-03-10 00:39:52.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Makefile.am 2010-03-31 19:37:31.000000000 +0100 @@ -1,5 +1,6 @@ SUBDIRS = \ AlarmClock \ + AppIndicator \ Awn \ ClutterFlow \ CoverWallpaper \ diff -Nru banshee-community-extensions-1.5.5/src/Makefile.in banshee-community-extensions-1.6.0/src/Makefile.in --- banshee-community-extensions-1.5.5/src/Makefile.in 2010-03-11 06:03:35.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Makefile.in 2010-03-31 19:47:54.000000000 +0100 @@ -36,6 +36,7 @@ $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -83,6 +84,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -198,6 +201,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ @@ -291,6 +296,7 @@ top_srcdir = @top_srcdir@ SUBDIRS = \ AlarmClock \ + AppIndicator \ Awn \ ClutterFlow \ CoverWallpaper \ diff -Nru banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/Banshee.Mirage.addin.xml banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/Banshee.Mirage.addin.xml --- banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/Banshee.Mirage.addin.xml 2010-02-22 23:46:32.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/Banshee.Mirage.addin.xml 2010-03-26 22:37:09.000000000 +0000 @@ -10,7 +10,7 @@ url="http://hop.at/mirage/" defaultEnabled="false"> - + diff -Nru banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/DistanceCalculator.cs banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/DistanceCalculator.cs --- banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/DistanceCalculator.cs 2010-03-09 21:45:54.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/DistanceCalculator.cs 2010-03-26 22:37:09.000000000 +0000 @@ -4,7 +4,7 @@ using System.Collections.Generic; using Mirage; -using Mono.Unix; +using Mono.Addins; namespace Banshee.Mirage { @@ -45,7 +45,7 @@ internal static double total_ms = 0; internal static double total_read_ms = 0; - internal static string notify_string = Catalog.GetString ("The Mirage extension is still analyzing your songs. Until its finished, shuffle and fill by similar may not perform properly."); + internal static string notify_string = AddinManager.CurrentLocalizer.GetString ("The Mirage extension is still analyzing your songs. Until its finished, shuffle and fill by similar may not perform properly."); private static object Distance (object seed_id_obj, object scms_obj) { diff -Nru banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/Makefile.in banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/Makefile.in --- banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/Makefile.in 2010-03-31 19:47:54.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/Mirage/Banshee.Mirage ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/MiragePlugin.cs banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/MiragePlugin.cs --- banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/MiragePlugin.cs 2010-03-09 21:45:54.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/MiragePlugin.cs 2010-03-31 19:37:31.000000000 +0100 @@ -56,14 +56,20 @@ InterfaceActionService action_service; internal static bool Debug; - + + static bool initialized = false; + + static MiragePlugin instance = null; + void IExtensionService.Initialize () { - action_service = ServiceManager.Get (); + if (instance != null) + throw new InvalidOperationException ("A MiragePlugin instance is already in use"); - Debug = ApplicationContext.CommandLine.Contains ("debug-mirage"); + Init (); + + action_service = ServiceManager.Get (); - Analyzer.Init (); TrackAnalysis.Init (); MigrateLegacyDb (); DistanceCalculator.Init (); @@ -73,6 +79,20 @@ if (!ServiceStartup ()) { ServiceManager.SourceManager.SourceAdded += OnSourceAdded; } + + instance = this; + } + + internal static void Init () + { + if (initialized) + return; + + Debug = ApplicationContext.CommandLine.Contains ("debug-mirage"); + + Analyzer.Init (); + + initialized = true; } private void OnSourceAdded (SourceAddedArgs args) @@ -115,6 +135,8 @@ action_service.UIManager.RemoveUi (uiManagerId); action_service.UIManager.RemoveActionGroup (actions); + + instance = null; } private void ScanLibrary () diff -Nru banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/RandomBySimilar.cs banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/RandomBySimilar.cs --- banshee-community-extensions-1.5.5/src/Mirage/Banshee.Mirage/RandomBySimilar.cs 2010-03-10 18:21:47.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/Banshee.Mirage/RandomBySimilar.cs 2010-03-31 19:37:31.000000000 +0100 @@ -34,7 +34,7 @@ using Banshee.Collection; using Banshee.PlaybackController; using Banshee.ServiceStack; -using Mono.Unix; +using Mono.Addins; using Mirage; namespace Banshee.Mirage @@ -51,9 +51,11 @@ public RandomBySimilar () : base ("mirage_similar") { - Label = Catalog.GetString ("Shuffle by Similar"); - Adverb = Catalog.GetString ("by similar"); - Description = Catalog.GetString ("Play songs similar to those already played"); + MiragePlugin.Init (); + + Label = AddinManager.CurrentLocalizer.GetString ("Shuffle by Similar"); + Adverb = AddinManager.CurrentLocalizer.GetString ("by similar"); + Description = AddinManager.CurrentLocalizer.GetString ("Play songs similar to those already played"); // TODO Mirage's PlaylistGeneratorSource ensures no more than 50% of tracks are by same artist Condition = "mirage.Status = 0 AND CoreTracks.ArtistID NOT IN (?) AND Distance > 0"; diff -Nru banshee-community-extensions-1.5.5/src/Mirage/libmirageaudio/Makefile.in banshee-community-extensions-1.6.0/src/Mirage/libmirageaudio/Makefile.in --- banshee-community-extensions-1.5.5/src/Mirage/libmirageaudio/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/libmirageaudio/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -38,6 +38,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -118,6 +119,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -233,6 +236,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Mirage/Makefile.in banshee-community-extensions-1.6.0/src/Mirage/Makefile.in --- banshee-community-extensions-1.5.5/src/Mirage/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/Makefile.in 2010-03-31 19:47:54.000000000 +0100 @@ -36,6 +36,7 @@ AUTHORS COPYING ChangeLog NEWS ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -83,6 +84,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -198,6 +201,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Mirage/Mirage/Makefile.in banshee-community-extensions-1.6.0/src/Mirage/Mirage/Makefile.in --- banshee-community-extensions-1.5.5/src/Mirage/Mirage/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/Mirage/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -41,6 +41,7 @@ subdir = src/Mirage/Mirage ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -86,6 +87,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -201,6 +204,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Mirage/Test/Makefile.in banshee-community-extensions-1.6.0/src/Mirage/Test/Makefile.in --- banshee-community-extensions-1.5.5/src/Mirage/Test/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Mirage/Test/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -35,6 +35,7 @@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -69,6 +70,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -184,6 +187,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/RadioStationFetcher/Makefile.in banshee-community-extensions-1.6.0/src/RadioStationFetcher/Makefile.in --- banshee-community-extensions-1.5.5/src/RadioStationFetcher/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/RadioStationFetcher/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/RadioStationFetcher ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/Encoder.cs banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/Encoder.cs --- banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/Encoder.cs 2010-02-20 23:27:58.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/Encoder.cs 2010-03-31 19:37:31.000000000 +0100 @@ -30,6 +30,9 @@ namespace Banshee.Streamrecorder { + /// + /// Class describing an (Audio) Encoder to use in a gstreamer pipeline + /// public class Encoder { @@ -38,10 +41,37 @@ private string file_extension; private bool is_preferred; + /// + /// Constructor + /// + /// + /// A giving the encoder a unique name + /// + /// + /// The to be integrated into a pipeline using the encoder. Must start with a "!" to connect to the pipeline and must not end with "!" + /// + /// + /// A to contain the file extension of the resulting (audio) file, including the "." + /// public Encoder (string name, string pipeline, string file_extension) : this(name, pipeline, file_extension, false) { } + /// + /// Constructor + /// + /// + /// A giving the encoder a unique name + /// + /// + /// The to be integrated into a pipeline using the encoder. Must start with a "!" to connect to the pipeline and must not end with "!" + /// + /// + /// A to contain the file extension of the resulting (audio) file, including the "." + /// + /// + /// A that indicates this encoder is preferred to others + /// public Encoder (string name, string pipeline, string file_extension, bool is_preferred) { this.name = name; diff -Nru banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/PlayerAudioTee.cs banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/PlayerAudioTee.cs --- banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/PlayerAudioTee.cs 2010-02-20 23:27:58.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/PlayerAudioTee.cs 2010-03-31 19:37:31.000000000 +0100 @@ -33,16 +33,37 @@ namespace Banshee.Streamrecorder { + /// + /// An object to capsule the gstreamer audio tee of the player and provide functionality to attach and remove a pipeline + /// public class PlayerAudioTee : Bin { private bool attached; + /// + /// Constructor + /// + /// + /// A referencing an audio player tee element + /// public PlayerAudioTee (IntPtr audiotee) : base(audiotee) { attached = false; } + /// + /// Attaches a pipeline/bin to the audio player tee, optionally using pad blocking + /// + /// + /// A to attach to the player tee + /// + /// + /// A indicating whether to use pad blocking or not + /// + /// + /// A -- always true + /// public bool AddBin (Bin bin, bool use_pad_block) { Bin[] user_bins = new Bin[2] { new Bin (this.ToIntPtr ()), bin }; @@ -66,18 +87,25 @@ return true; } + /// + /// Helper function to really attach a bin to the audio player tee + /// + /// + /// A referencing the pad that may need to be unblocked + /// + /// + /// A indicating if the pad is blocked + /// + /// + /// A containing references to the bin and the audio tee + /// private void ReallyAddBin (IntPtr pad, bool blocked, IntPtr user_data) { - Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee] START" + (blocked ? " (blocked)" : " (unblocked)")); - GCHandle gch = GCHandle.FromIntPtr (user_data); Bin[] user_bins = (Gst.Bin[])gch.Target; Bin fixture = user_bins[0]; Bin element = user_bins[1]; - Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee] path for fixture: " + fixture.GetPathString ()); - Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee] path for element: " + element.GetPathString ()); - Element queue; Element audioconvert; Bin bin; @@ -93,8 +121,6 @@ return; } - Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee]adding tee " + element.GetPathString ()); - /* set up containing bin */ bin = new Bin (); queue = ElementFactory.Make ("queue"); @@ -130,13 +156,20 @@ AddRemoveBinDone (IntPtr.Zero, false, ghost_pad.ToIntPtr ()); } - Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee] END"); - } - /* - * Pipeline RemoveTee - */ + /// + /// Removes a pipeline/bin from the audio player tee, optionally using pad blocking + /// + /// + /// The to remove + /// + /// + /// A indicating whether to use pad blocking or not + /// + /// + /// A -- always true + /// public bool RemoveBin (Bin bin, bool use_pad_block) { IntPtr user_data = bin.ToIntPtr (); @@ -157,6 +190,18 @@ return true; } + /// + /// Helper function to really remove the bin from the audio player tee + /// + /// + /// A referencing the pad that may need to be unblocked + /// + /// + /// A indicating if the pad is blocked + /// + /// + /// A containing a reference to the bin + /// private void ReallyRemoveBin (IntPtr pad, bool blocked, IntPtr user_data) { Bin element = new Bin (user_data); @@ -169,8 +214,7 @@ Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee] element empty, assume disposed, exiting: " + element_path); return; } - Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee] removing tee " + element_path); - + bin = new Bin (element.GetParent ().ToIntPtr ()); bin.Ref (); @@ -185,12 +229,24 @@ /* if we're supposed to be playing, unblock the sink */ if (blocked) { - Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee]unblocking pad after removing tee"); + Hyena.Log.Debug ("[Streamrecorder.PlayerAudioTee] unblocking pad after removing tee"); new Pad (pad).SetBlockedAsync (false, AddRemoveBinDone, IntPtr.Zero); } } + /// + /// Helper function to revive the player pipeline after add/remove operations + /// + /// + /// A referencing the pad that might have been blocked + /// + /// + /// A indicating whether the pad was blocked + /// + /// + /// A referencing the new (ghost) pad that waits for an event or Zero for removed bins + /// public void AddRemoveBinDone (IntPtr pad, bool blocked, IntPtr new_pad) { IntPtr segment; @@ -203,6 +259,12 @@ new Pad (new_pad).SendEvent (segment); } + /// + /// Indicates if a (recording) pipeline is attached to this player tee + /// + /// + /// A indicating whether a (recording) pipeline is attached to this player tee + /// public bool IsAttached () { return attached; diff -Nru banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/Recorder.cs banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/Recorder.cs --- banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/Recorder.cs 2010-02-24 18:09:38.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/Recorder.cs 2010-03-31 19:37:31.000000000 +0100 @@ -37,6 +37,10 @@ namespace Banshee.Streamrecorder { + + /// + /// A Recorder object that uses a GStreamerMiniBinding to enable recoding of the player pipeline by attaching to the player audio tee + /// public class Recorder { private string output_directory; @@ -52,7 +56,7 @@ private List encoders = new List (); private bool has_lame; private const string lame_name = "LAME MP3 Audio Encoder"; - private const string lame_pipeline = "! lame name=audio_encoder ! id3v2mux name=tagger "; + private const string lame_pipeline = "! lamemp3enc name=audio_encoder ! id3v2mux name=tagger "; private const string lame_extension = ".mp3"; private bool has_vorbis; private const string vorbis_name = "Ogg/Vorbis Audio Encoder"; @@ -62,62 +66,83 @@ private const string flac_name = "FLAC Audio Encoder"; private const string flac_pipeline = "! flacenc name=audio_encoder ! flactag name=tagger "; private const string flac_extension = ".flac"; - private bool has_level; + /// + /// Constructor -- creates a new Recorder that will use the GStreamerMiniBinding to connect itself to the player tee for recording streams + /// public Recorder () { - if (Marshaller.Initialize ()) { - has_lame = Marshaller.CheckGstPlugin ("lame") && Marshaller.CheckGstPlugin ("id3v2mux"); - Hyena.Log.Information ("[Streamrecorder] GstPlugin lame" + (has_lame ? "" : " not") + " found"); - encoders.Add (new Encoder (lame_name, lame_pipeline, lame_extension)); - - has_vorbis = Marshaller.CheckGstPlugin ("vorbisenc") && Marshaller.CheckGstPlugin ("oggmux") && Marshaller.CheckGstPlugin ("oggmux"); - Hyena.Log.Information ("[Streamrecorder] GstPlugin vorbis" + (has_vorbis ? "" : " not") + " found"); - encoders.Add (new Encoder (vorbis_name, vorbis_pipeline, vorbis_extension, true)); - - has_flac = Marshaller.CheckGstPlugin ("flacenc") && Marshaller.CheckGstPlugin ("flactag"); - Hyena.Log.Information ("[Streamrecorder] GstPlugin flac" + (has_flac ? "" : " not") + " found"); - encoders.Add (new Encoder (flac_name, flac_pipeline, flac_extension)); - - has_level = Marshaller.CheckGstPlugin ("level"); - Hyena.Log.Information ("[Streamrecorder] GstPlugin level" + (has_level ? "" : " not") + " found"); - Hyena.Log.Debug ("[Streamrecorder] gstreamer initialized"); - } else { - Hyena.Log.Debug ("[Streamrecorder] an error occurred during gstreamer initialization, aborting."); + try + { + if (Marshaller.Initialize ()) { + encoders.Add (new Encoder ("None (unchanged stream)", "! identity ", null)); + + has_lame = Marshaller.CheckGstPlugin ("lame") && Marshaller.CheckGstPlugin ("id3v2mux"); + Hyena.Log.Debug ("[Streamrecorder] GstPlugin lame" + (has_lame ? "" : " not") + " found"); + if (has_lame) encoders.Add (new Encoder (lame_name, lame_pipeline, lame_extension)); + + has_vorbis = Marshaller.CheckGstPlugin ("vorbisenc") && Marshaller.CheckGstPlugin ("oggmux") && Marshaller.CheckGstPlugin ("oggmux"); + Hyena.Log.Debug ("[Streamrecorder] GstPlugin vorbis" + (has_vorbis ? "" : " not") + " found"); + if (has_vorbis) encoders.Add (new Encoder (vorbis_name, vorbis_pipeline, vorbis_extension, true)); + + has_flac = Marshaller.CheckGstPlugin ("flacenc") && Marshaller.CheckGstPlugin ("flactag"); + Hyena.Log.Debug ("[Streamrecorder] GstPlugin flac" + (has_flac ? "" : " not") + " found"); + if (has_flac) encoders.Add (new Encoder (flac_name, flac_pipeline, flac_extension)); + + } else { + Hyena.Log.Debug ("[Streamrecorder] an error occurred during gstreamer initialization, aborting."); + } + } catch (Exception e) { + Hyena.Log.Information ("[Streamrecorder] An exception occurred during gstreamer initialization"); + Hyena.Log.Debug (e.StackTrace); } + } + /// + /// Creates a new recoding pipeline with the best (by user preference) available encoder + /// + /// + /// A , true if the pipeline was successfully created, false otherwise. + /// public bool Create () { - Hyena.Log.Debug ("[Streamrecoder.Recorder] START"); - audiotee = new PlayerAudioTee (ServiceManager.PlayerEngine.ActiveEngine.GetBaseElements ()[2]); - string bin_description = BuildPipeline (); - - if (bin_description.Equals ("")) { + + try { + audiotee = new PlayerAudioTee (ServiceManager.PlayerEngine.ActiveEngine.GetBaseElements ()[2]); + + if (bin_description.Equals ("")) { + return false; + } + + encoder_bin = Parse.BinFromDescription (bin_description, true); + + tagger = new TagSetter (encoder_bin.GetByInterface (TagSetter.GetType ())); + file_sink = encoder_bin.GetByName ("file_sink").ToFileSink (); + + file_sink.Location = output_file + file_extension; + file_sink.SetBooleanProperty ("sync", true); + file_sink.SetBooleanProperty ("async", false); + + GLib.Object.GetObject (file_sink.ToIntPtr ()).AddNotification ("allow-overwrite", OnAllowOverwrite); + + ghost_pad = encoder_bin.GetStaticPad ("sink").ToGhostPad (); + } catch (Exception e) { + Hyena.Log.InformationFormat ("[Streamrecorder] An exception occurred during pipeline construction: {0}", bin_description); + Hyena.Log.Debug (e.StackTrace); return false; } - encoder_bin = Parse.BinFromDescription (bin_description, true); - - Hyena.Log.Debug ("[Streamrecoder.Recorder] encoder_bin created: " + encoder_bin.GetPathString ()); - - tagger = new TagSetter (encoder_bin.GetByInterface (TagSetter.GetType ())); - file_sink = encoder_bin.GetByName ("file_sink").ToFileSink (); - - file_sink.Location = output_file + file_extension; - file_sink.SetBooleanProperty ("sync", true); - file_sink.SetBooleanProperty ("async", false); - - GLib.Object.GetObject (file_sink.ToIntPtr ()).AddNotification ("allow-overwrite", OnAllowOverwrite); - - ghost_pad = encoder_bin.GetStaticPad ("sink").ToGhostPad (); - - Hyena.Log.Debug ("[Streamrecoder.Recorder] END"); - return true; } + /// + /// Helper function to build the actual pipeline string + /// + /// + /// A containing the pipeline description + /// private string BuildPipeline () { string pipeline = ""; @@ -127,16 +152,35 @@ if (encoder != null) { pipeline = pipeline_start + encoder.Pipeline + pipeline_end; - file_extension = encoder.FileExtension; + if (String.IsNullOrEmpty (encoder.FileExtension)) + { + string trackuri = Banshee.ServiceStack.ServiceManager.PlaybackController.CurrentTrack.Uri.ToString (); + int ind = trackuri.LastIndexOf ('.'); + file_extension = trackuri.Substring (ind); + } else { + file_extension = encoder.FileExtension; + } } return pipeline; } + /// + /// List of available encoders + /// public List Encoders { get { return encoders; } } + /// + /// Sets the prefered encoder for the Recorder to use + /// + /// + /// A containing the Name of the encoder that is requested + /// + /// + /// A containing the Name of the encoder that will be used + /// public string SetActiveEncoder (string active_encoder) { string ret = null; @@ -156,6 +200,12 @@ return ret; } + /// + /// Helper function returning the first preferred encoder from the list of encoders + /// + /// + /// The first object that is preferred in the list of encoders or null, if there is none. + /// private Encoder GetFirstPreferredEncoder () { foreach (Encoder encoder in encoders) { @@ -165,6 +215,12 @@ return null; } + /// + /// Helper function returning the first available encoder, using preferred encoders first + /// + /// + /// An object or null, if there is no encoders in the list + /// public Encoder GetFirstAvailableEncoder () { Encoder encoder = GetFirstPreferredEncoder (); @@ -174,70 +230,127 @@ return encoder; } + /// + /// Function to control behaviour when files would be overwritten. Should never be called in current code conditions. + /// + /// + /// A -- not used + /// + /// + /// A -- not used + /// private void OnAllowOverwrite (object o, GLib.NotifyArgs args) { - Hyena.Log.Debug ("[Recorder] Called"); + return; } + /// + /// Starts recording of the current stream by creating and attaching a new Recorder pipeline to the player audio tee + /// + /// + /// A inidicating if pad blocking should be used + /// public void StartRecording (bool blocked) { - Hyena.Log.Debug ("[Recorder] START"); - if (audiotee != null && !audiotee.IsNull () && audiotee.IsAttached () && encoder_bin != null && !encoder_bin.IsNull ()) { - audiotee.RemoveBin (encoder_bin, blocked); + try { + audiotee.RemoveBin (encoder_bin, blocked); + } catch (Exception e) { + Hyena.Log.Information ("[Streamrecorder] An exception occurred during gstreamer operation"); + Hyena.Log.Debug (e.StackTrace); + } } - + if (Create ()) { - audiotee.AddBin (encoder_bin, blocked); + try { + audiotee.AddBin (encoder_bin, blocked); + } catch (Exception e) { + Hyena.Log.Information ("[Streamrecorder] An exception occurred during gstreamer operation"); + Hyena.Log.Debug (e.StackTrace); + } } - Hyena.Log.Debug ("[Recorder] END"); + Hyena.Log.Debug ("[Recorder] Recording started"); } + /// + /// Stops recording of the current stream by removing the Recorder pipeline from the player audio tee + /// + /// + /// A inidicating if pad blocking should be used + /// public void StopRecording (bool blocked) { - Hyena.Log.Debug ("[Recorder] STOPPED"); - if (encoder_bin != null && !encoder_bin.IsNull () && audiotee != null && !audiotee.IsNull () && audiotee.IsAttached ()) { - audiotee.RemoveBin (encoder_bin, blocked); + try { + audiotee.RemoveBin (encoder_bin, blocked); + Hyena.Log.Debug ("[Recorder] Recording stopped"); + } catch (Exception e) { + Hyena.Log.Information ("[Streamrecorder] An exception occurred during gstreamer operation"); + Hyena.Log.Debug (e.StackTrace); + } } - } + /// + /// Adds Metadata tags to the recorded file using GStreamer TagSetter interface and splits files if requested + /// + /// + /// A containing the current stream and its metadata + /// + /// + /// A indicating whether the recorded files are to be split + /// + /// + /// A indicating if tagging was successful + /// public bool AddStreamTags (TrackInfo track, bool splitfiles) { - Hyena.Log.Debug ("[Recorder] START"); - if (track == null || tagger == null) return false; if (tagger.IsNull ()) { - Hyena.Log.Debug ("[Recorder]tagger is null, not tagging!"); + Hyena.Log.Debug ("[Recorder] tagger is null, not tagging!"); return false; } - - TagList taglist = new TagList (); - if (track.TrackTitle != null) - taglist.AddStringValue (TagMergeMode.ReplaceAll, "title", track.TrackTitle); - if (track.Genre != null) - taglist.AddStringValue (TagMergeMode.ReplaceAll, "genre", track.Genre); - if (track.ArtistName != null) - taglist.AddStringValue (TagMergeMode.ReplaceAll, "artist", track.ArtistName); - if (track.AlbumArtist != null) - taglist.AddStringValue (TagMergeMode.ReplaceAll, "album-artist", track.AlbumArtist); - - tagger.MergeTags (taglist, TagMergeMode.ReplaceAll); - + + try { + TagList taglist = new TagList (); + if (track.TrackTitle != null) + taglist.AddStringValue (TagMergeMode.ReplaceAll, "title", track.TrackTitle); + if (track.Genre != null) + taglist.AddStringValue (TagMergeMode.ReplaceAll, "genre", track.Genre); + if (track.ArtistName != null) + taglist.AddStringValue (TagMergeMode.ReplaceAll, "artist", track.ArtistName); + if (track.AlbumArtist != null) + taglist.AddStringValue (TagMergeMode.ReplaceAll, "album-artist", track.AlbumArtist); + + tagger.MergeTags (taglist, TagMergeMode.ReplaceAll); + } catch (Exception e) { + Hyena.Log.Information ("[Streamrecorder] An exception occurred during gstreamer operation"); + Hyena.Log.Debug (e.StackTrace); + } + if (splitfiles && file_sink != null && track.ArtistName != null && track.ArtistName.Length > 0) { SetMetadataFilename (track.TrackTitle, track.ArtistName); SetNewTrackLocation (output_file + file_extension); } - Hyena.Log.Debug ("[Recorder] END"); - return true; } + /// + /// Creates a new filename from title and artist + /// + /// + /// A containing the track title + /// + /// + /// A containing the track artist + /// + /// + /// A the new filename including the directory and file extension + /// public string SetMetadataFilename (string title, string artist) { string new_name = artist + "_-_" + title; @@ -252,17 +365,41 @@ return output_file; } + /// + /// Sets the output directory and filename for recording + /// + /// + /// A containing the output directory + /// + /// + /// A containing the output filename that will be used if no metadata filenames are used + /// public void SetOutputParameters (string directory, string filename) { SetOutputDirectory (directory); SetOutputFile (filename); } + /// + /// Helper function to set the output directory + /// + /// + /// A containing the output directory + /// private void SetOutputDirectory (string directory) { output_directory = directory; } + /// + /// Helper function to set the output filename, removing invalid characters + /// + /// + /// A containing the desired filename including extension + /// + /// + /// A containing the cleaned filename that will be used + /// private string SetOutputFile (string fullfilename) { string cleanfilename = fullfilename; @@ -274,17 +411,27 @@ return cleanfilename; } - + /// + /// Changes the location of the file being recorded while recording is in progress, splitting the file at the current stream location + /// + /// + /// A containing the full new filename and path + /// private void SetNewTrackLocation (string new_location) { - Pad teepad = ghost_pad.GetPeer (); - teepad.SetBlocked (true); - encoder_bin.SendEvent (Marshaller.NewEOSEvent ()); - encoder_bin.SetState (State.Null); - file_sink.Location = new_location; - encoder_bin.SetState (State.Ready); - encoder_bin.SetState (State.Playing); - teepad.SetBlocked (false); + try { + Pad teepad = ghost_pad.GetPeer (); + teepad.SetBlocked (true); + encoder_bin.SendEvent (Marshaller.NewEOSEvent ()); + encoder_bin.SetState (State.Null); + file_sink.Location = new_location; + encoder_bin.SetState (State.Ready); + encoder_bin.SetState (State.Playing); + teepad.SetBlocked (false); + } catch (Exception e) { + Hyena.Log.Information ("[Streamrecorder] An exception occurred during gstreamer operation"); + Hyena.Log.Debug (e.StackTrace); + } } } diff -Nru banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/RippedFileScanner.cs banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/RippedFileScanner.cs --- banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/RippedFileScanner.cs 2010-02-20 23:27:58.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/RippedFileScanner.cs 2010-03-31 19:37:31.000000000 +0100 @@ -38,6 +38,10 @@ namespace Banshee.Streamrecorder { + + /// + /// Ripped File Scanner written by Akseli Mantila to integrate recorded files into the music library + /// public class RippedFileScanner { public static Thread folder_scanner = null; diff -Nru banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/StreamrecorderConfigDialog.cs banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/StreamrecorderConfigDialog.cs --- banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/StreamrecorderConfigDialog.cs 2010-02-20 23:27:58.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/StreamrecorderConfigDialog.cs 2010-03-31 19:37:31.000000000 +0100 @@ -39,6 +39,10 @@ namespace Banshee.Streamrecorder { + + /// + /// A dialog to control StreamRecorder options + /// public class StreamrecorderConfigDialog : Gtk.Dialog { StreamrecorderService streamrecorder_service; @@ -55,6 +59,24 @@ Gtk.Button save_button = new Gtk.Button (Gtk.Stock.Save); Gtk.ComboBox encoderbox = new Gtk.ComboBox (); + /// + /// Constructor + /// + /// + /// The that is being configured + /// + /// + /// A containing the previously configured output directory + /// + /// + /// A containing the previously configured encoder + /// + /// + /// A indicating whether file scanning was previously enabled + /// + /// + /// A indicating whether file splitting was previously enabled + /// public StreamrecorderConfigDialog (StreamrecorderService service, string previous_output_folder, string previous_encoder, bool is_importing_enabled, bool is_splitting_enabled) { streamrecorder_service = service; @@ -160,16 +182,32 @@ ShowAll (); } + /// + /// Handles click on the Cancel button + /// + /// + /// A -- not used + /// + /// + /// A -- not used + /// private void OnCancelButtonClicked (object o, EventArgs a) { Destroy (); } + /// + /// Sets the configuration and saves it to SchemaEntries + /// + /// + /// A -- not used + /// + /// + /// A -- not used + /// private void OnSaveButtonClicked (object o, EventArgs a) { - Hyena.Log.DebugFormat ("[StreamrecorderConfigDialog] dir: {0}", output_folder.Text); - Hyena.Log.DebugFormat ("[StreamrecorderConfigDialog] enc: {0}", encoderbox.ActiveText); - + StreamrecorderService.IsImportingEnabledEntry.Set (enable_import_ripped_songs.Active.ToString ()); streamrecorder_service.IsImportingEnabled = enable_import_ripped_songs.Active.ToString ().Equals ("True") ? true : false; @@ -190,6 +228,15 @@ Destroy (); } + /// + /// Handles click to the output folder choose button + /// + /// + /// A -- not used + /// + /// + /// A -- not used + /// private void OnChooseOutputFolderButtonClicked (object o, EventArgs a) { FileChooserDialog output_folder_chooser = new FileChooserDialog ("Choose output folder", this, FileChooserAction.SelectFolder, "Cancel", ResponseType.Cancel, "Open", ResponseType.Accept); @@ -203,15 +250,19 @@ output_folder_chooser.Destroy (); } + /// + /// Validates the choosen output folder + /// + /// + /// A returns true if the output folder is valid, false otherwise + /// private bool ValidateOutputFolderField () { if (Banshee.IO.Directory.Exists (output_folder.Text.Trim ())) { - Hyena.Log.Debug ("[StreamrecorderConfigDialog] VALID!"); return true; } try { Banshee.IO.Directory.Create (output_folder.Text); - Hyena.Log.Debug ("[StreamrecorderConfigDialog] VALID!"); return true; } catch { Hyena.Log.Debug ("[StreamrecorderConfigDialog] NOT VALID!"); diff -Nru banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/StreamrecorderService.cs banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/StreamrecorderService.cs --- banshee-community-extensions-1.5.5/src/StreamRecorder/Banshee.Streamrecorder/StreamrecorderService.cs 2010-02-24 18:09:38.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/StreamRecorder/Banshee.Streamrecorder/StreamrecorderService.cs 2010-03-31 19:37:31.000000000 +0100 @@ -48,6 +48,10 @@ namespace Banshee.Streamrecorder { + + /// + /// Extension Service class that adds the functionality to Banshee Media Player to record live (non-local) streams to files + /// public class StreamrecorderService : IExtensionService, IDisposable { private Recorder recorder; @@ -62,25 +66,24 @@ private TrackInfo track = null; private string active_encoder; - + /// + /// Constructor -- loads previous configuration + /// public StreamrecorderService () { - Hyena.Log.Debug ("[StreamrecorderService] START"); - recording = IsRecordingEnabledEntry.Get ().Equals ("True") ? true : false; output_directory = OutputDirectoryEntry.Get (); is_importing_enabled = IsImportingEnabledEntry.Get ().Equals ("True") ? true : false; is_splitting_enabled = IsFileSplittingEnabledEntry.Get ().Equals ("True") ? true : false; active_encoder = ActiveEncoderEntry.Get (); ui_button_id = 0; - - Hyena.Log.Debug ("[StreamrecorderService] END"); } + /// + /// Initialize the service, creating the Recorder object, connecting events and adding GUI elements + /// void IExtensionService.Initialize () { - Hyena.Log.Debug ("[StreamrecorderService] START"); - recorder = new Recorder (); active_encoder = recorder.SetActiveEncoder (active_encoder); @@ -119,46 +122,45 @@ action_service.UIManager.InsertActionGroup (actions, 0); ui_menu_id = action_service.UIManager.AddUiFromResource ("StreamrecorderMenu.xml"); - //not yet set on init, skipping - //PrimarySource primary_source = action_service.GlobalActions.ActivePrimarySource; - - //if (primary_source != null && primary_source.IsLocal) - //{ - // ui_button_id = action_service.UIManager.AddUiFromResource ("StreamrecorderButton.xml"); - //} - - Hyena.Log.Debug ("[StreamrecorderService] END"); } + /// + /// Watches source changes and dynamically adds/removes the record button in the toolbar + /// + /// + /// A -- not used + /// void OnSourceChanged (Sources.SourceEventArgs args) { - Hyena.Log.Debug ("[StreamrecorderService] START"); PrimarySource primary_source = action_service.GlobalActions.ActivePrimarySource; if (primary_source == null) { - Hyena.Log.Debug ("[StreamrecorderService] not a primary source END"); return; } if (!primary_source.IsLocal && ui_button_id == 0) { - Hyena.Log.Debug ("[StreamrecorderService] adding record button"); ui_button_id = action_service.UIManager.AddUiFromResource ("StreamrecorderButton.xml"); } if (primary_source.IsLocal && ui_button_id > 0) { - Hyena.Log.Debug ("[StreamrecorderService] removing record button"); action_service.UIManager.RemoveUi(ui_button_id); ui_button_id = 0; } - Hyena.Log.Debug ("[StreamrecorderService] END"); } + /// + /// Activates stream recording + /// + /// + /// A -- not used + /// + /// + /// A -- not used + /// public void OnActivateStreamrecorder (object o, EventArgs ea) { - Hyena.Log.Debug ("[StreamrecorderService] START"); - if (!recording) { StartRecording (); } else { @@ -168,18 +170,27 @@ recording = !recording; IsRecordingEnabledEntry.Set (recording.ToString ()); - Hyena.Log.Debug ("[StreamrecorderService] END"); } + /// + /// Triggers configuration, shows the configuration dialog + /// + /// + /// A -- not used + /// + /// + /// A -- not used + /// public void OnConfigure (object o, EventArgs ea) { new StreamrecorderConfigDialog (this, output_directory, active_encoder, is_importing_enabled, is_splitting_enabled); } + /// + /// Disposes the StreamRecorder service, stops recording, disconnects events, and removes GUI elements + /// public void Dispose () { - Log.Debug ("Disposing Streamrecorder plugin"); - StopRecording (); action_service.UIManager.RemoveUi (ui_menu_id); if (ui_button_id > 0) @@ -190,10 +201,19 @@ actions = null; } + /// + /// The service name + /// string IService.ServiceName { get { return "StreamrecorderService"; } } + /// + /// Helper function to indicate if the current track can be recorded safely + /// + /// + /// A indicating whether it is safe to record the current track or not + /// private bool IsCurrentTrackRecordable () { if (Banshee.ServiceStack.ServiceManager.PlaybackController.CurrentTrack != null @@ -204,6 +224,12 @@ return false; } + /// + /// Handles Metadata changes initiating tagging and file spliting + /// + /// + /// A -- not used + /// private void OnMetadata (PlayerEventArgs args) { if (recording) { @@ -212,6 +238,12 @@ } } + /// + /// Handles EndOfStream events and stops recording + /// + /// + /// A + /// private void OnEndOfStream (PlayerEventArgs args) { if (recording) { @@ -219,6 +251,12 @@ } } + /// + /// Handles Player state changes and Stops recording if appropriate + /// + /// + /// A + /// private void OnStateChange (PlayerEventArgs args) { if (ServiceManager.PlayerEngine.CurrentState == PlayerState.Idle && recording) { @@ -226,6 +264,9 @@ } } + /// + /// Starts recording of the current stream if track is recordable + /// private void StartRecording () { @@ -248,6 +289,9 @@ } } + /// + /// stops recording of the current track + /// private void StopRecording () { recorder.StopRecording ((ServiceManager.PlayerEngine.CurrentState == PlayerState.Playing)); @@ -255,20 +299,33 @@ StopFolderScanner (); } + /// + /// starts the folder scanner + /// public void StartFolderScanner () { RippedFileScanner.StartScanner (); } + /// + /// stops the folder scanner + /// public void StopFolderScanner () { RippedFileScanner.StopScanner (); } + /// + /// Initializes all parameters for recording a track + /// + /// + /// A that is to be recorded + /// + /// + /// A indicating if all parameters could successfully be initialized + /// private bool InitStreamrecorderProcess (TrackInfo track_in) { - Hyena.Log.DebugFormat ("[StreamrecorderService] START dir: '{0}'", output_directory); - active_encoder = recorder.SetActiveEncoder (active_encoder); if (String.IsNullOrEmpty (output_directory)) { @@ -277,12 +334,11 @@ } if (track_in == null) { - Hyena.Log.Debug ("[StreamrecorderService] END. Recording not ready"); return false; } if (track_in.Uri == null || track_in.Uri.IsLocalPath) { - Hyena.Log.Debug ("[StreamrecorderService] END. Not recording local files"); + Hyena.Log.Debug ("[StreamrecorderService] Not recording local files"); return false; } @@ -303,10 +359,15 @@ RippedFileScanner.SetScanDirectory (output_directory); - Hyena.Log.Debug ("[StreamrecorderService] END. Recording ready"); return true; } + /// + /// Retrieves an array containing the Names of available encoders + /// + /// + /// A containing the Names of available encoders + /// public string[] GetEncoders () { List encoders = recorder.Encoders; @@ -317,6 +378,9 @@ return encoder_names; } + /// + /// The output directory for recorded files + /// public string OutputDirectory { get { return output_directory; } set { @@ -325,8 +389,6 @@ this.output_directory = value; - Hyena.Log.DebugFormat ("[StreamrecorderService] ", value); - if (String.IsNullOrEmpty (this.output_directory)) { this.output_directory = Banshee.ServiceStack.ServiceManager.SourceManager.MusicLibrary.BaseDirectory + Path.DirectorySeparatorChar + "ripped"; @@ -341,16 +403,25 @@ } } + /// + /// the Name of the configured encoder + /// public string ActiveEncoder { get { return active_encoder; } set { active_encoder = value; } } + /// + /// Indicator if recorded tracks are imported into the music library + /// public bool IsImportingEnabled { get { return is_importing_enabled; } set { is_importing_enabled = value; } } + /// + /// Indicator if files should be split by metadata if available + /// public bool IsFileSplittingEnabled { get { return is_splitting_enabled; } set { is_splitting_enabled = value; } diff -Nru banshee-community-extensions-1.5.5/src/StreamRecorder/Makefile.in banshee-community-extensions-1.6.0/src/StreamRecorder/Makefile.in --- banshee-community-extensions-1.5.5/src/StreamRecorder/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/StreamRecorder/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/StreamRecorder ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.addin.xml banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.addin.xml --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.addin.xml 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.addin.xml 2010-03-26 22:37:09.000000000 +0000 @@ -11,6 +11,8 @@ url="http://banshee-project.org/" defaultEnabled="false"> + + diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactContainerSource.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactContainerSource.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactContainerSource.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactContainerSource.cs 2010-03-26 22:37:09.000000000 +0000 @@ -27,7 +27,7 @@ // using System; -using Mono.Unix; +using Mono.Addins; using Banshee.Configuration; using Banshee.Sources; @@ -55,7 +55,7 @@ public static event EventHandler DownloadingAllowedChanged; public static event EventHandler StreamingAllowedChanged; - public ContactContainerSource (TelepathyService service) : base (Catalog.GetString ("Contacts"), "Contacts", 1000) + public ContactContainerSource (TelepathyService service) : base (AddinManager.CurrentLocalizer.GetString ("Contacts"), "Contacts", 1000) { TelepathyService = service; TypeUniqueId = "telepathy-container"; diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactSource.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactSource.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactSource.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactSource.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,7 +28,7 @@ using System; using System.Collections.Generic; -using Mono.Unix; +using Mono.Addins; using Hyena.Data.Sqlite; using Hyena; @@ -84,7 +84,7 @@ private SourceMessage response_message; private bool getting_response = false; - public ContactSource (Contact contact) : base (Catalog.GetString ("Contact"), + public ContactSource (Contact contact) : base (AddinManager.CurrentLocalizer.GetString ("Contact"), String.Format ("{0} ({1})", contact != null ? contact.Name : String.Empty, contact != null ? contact.Status.ToString () : String.Empty), @@ -95,7 +95,7 @@ Contact.ContactUpdated += OnContactUpdated; Hyena.Log.DebugFormat ("ContactSource created for {0}", Contact.Name); - //Properties.SetString ("UnmapSourceActionLabel", Catalog.GetString ("Disconnect")); + //Properties.SetString ("UnmapSourceActionLabel", AddinManager.CurrentLocalizer.GetString ("Disconnect")); //Properties.SetString ("UnmapSourceActionIconName", "gtk-disconnect"); Properties.SetString ("Icon.Name", "stock_person"); Properties.SetString ("ActiveSourceUIResource", "ActiveSourceUI.xml"); @@ -319,15 +319,15 @@ response_message.ClearActions (); string status_name = String.Format ("{0}", GLib.Markup.EscapeText (Name)); - string message = String.Format (Catalog.GetString ("{0} is requesting to browse your library"), Contact.Name); + string message = String.Format (AddinManager.CurrentLocalizer.GetString ("{0} is requesting to browse your library"), Contact.Name); response_message.Text = String.Format (GLib.Markup.EscapeText (message), status_name); - response_message.AddAction (new MessageAction (Catalog.GetString ("Accept"), + response_message.AddAction (new MessageAction (AddinManager.CurrentLocalizer.GetString ("Accept"), delegate { tube_manager.AcceptBrowseRequest (); ResetResponseMessage (); })); - response_message.AddAction (new MessageAction (Catalog.GetString ("Reject"), + response_message.AddAction (new MessageAction (AddinManager.CurrentLocalizer.GetString ("Reject"), delegate { tube_manager.RejectBrowseRequest (); ResetResponseMessage (); @@ -335,7 +335,7 @@ response_message.ThawNotify (); TelepathyNotification.Create ().Show (Contact.Name, - Catalog.GetString ("is requesting to browse your Banshee library")); + AddinManager.CurrentLocalizer.GetString ("is requesting to browse your Banshee library")); // show notify bubble every 30 seconds System.Timers.Timer notify_timer = new System.Timers.Timer (30000); @@ -344,7 +344,7 @@ notify_timer.Stop (); } else { TelepathyNotification.Create ().Show (Contact.Name, - Catalog.GetString ("is requesting to browse your Banshee library")); + AddinManager.CurrentLocalizer.GetString ("is requesting to browse your Banshee library")); } }; notify_timer.AutoReset = true; @@ -384,7 +384,7 @@ HideStatus (); break; case TubeManager.State.Waiting: - SetStatus (Catalog.GetString ("Waiting for response from contact..."), false); + SetStatus (AddinManager.CurrentLocalizer.GetString ("Waiting for response from contact..."), false); break; //case TubeManager.State.PermissionNotGranted: //case TubeManager.State.PermissionGranted: @@ -392,13 +392,13 @@ if (Count > 0) { CleanUpData (); } - SetStatus (Catalog.GetString ("Loading..."), false); + SetStatus (AddinManager.CurrentLocalizer.GetString ("Loading..."), false); break; case TubeManager.State.LoadedMetadata: - SetStatus (Catalog.GetString ("All tracks downloaded. Loading..."), false); + SetStatus (AddinManager.CurrentLocalizer.GetString ("All tracks downloaded. Loading..."), false); break; case TubeManager.State.LoadingPlaylists: - SetStatus (Catalog.GetString ("Loading playlists..."), false); + SetStatus (AddinManager.CurrentLocalizer.GetString ("Loading playlists..."), false); break; //case TubeManager.State.Loaded: } @@ -410,13 +410,13 @@ switch (error_args.error) { case TubeManager.ErrorReason.ClosedBeforeDownloaded: - SetStatus (Catalog.GetString ("A problem occured while downloading this contact's library"), true); + SetStatus (AddinManager.CurrentLocalizer.GetString ("A problem occured while downloading this contact's library"), true); break; case TubeManager.ErrorReason.ErrorDuringLoad: - SetStatus (Catalog.GetString ("An error occurred while loading data"), true); + SetStatus (AddinManager.CurrentLocalizer.GetString ("An error occurred while loading data"), true); break; case TubeManager.ErrorReason.ErrorDuringPlaylistLoad: - SetStatus (Catalog.GetString ("An error occurred while loading playlists"), true); + SetStatus (AddinManager.CurrentLocalizer.GetString ("An error occurred while loading playlists"), true); break; } } @@ -436,7 +436,7 @@ } else { TelepathyNotification.Create ().Show (Contact.Name, - Catalog.GetString ("is no longer sharing their Banshee library with you")); + AddinManager.CurrentLocalizer.GetString ("is no longer sharing their Banshee library with you")); } } @@ -461,7 +461,7 @@ LibraryDownload d = track_args.download as LibraryDownload; ThreadAssist.ProxyToMain (delegate { - SetStatus (String.Format (Catalog.GetString ("Loading {0} of {1}"), + SetStatus (String.Format (AddinManager.CurrentLocalizer.GetString ("Loading {0} of {1}"), CalculateLoadingTracks (chunk.Length, d.TotalExpected), d.TotalExpected), false); }); @@ -498,7 +498,7 @@ LibraryDownload d = track_args.download as LibraryDownload; ThreadAssist.ProxyToMain (delegate { - SetStatus (String.Format (Catalog.GetString ("Loading {0} of {1}"), + SetStatus (String.Format (AddinManager.CurrentLocalizer.GetString ("Loading {0} of {1}"), CalculateLoadingTracks (chunk.Length, d.TotalExpected), d.TotalExpected), false); }); diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactTrackInfo.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactTrackInfo.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactTrackInfo.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/ContactTrackInfo.cs 2010-03-26 22:37:09.000000000 +0000 @@ -30,14 +30,12 @@ using System.IO; using System.Collections.Generic; using System.Reflection; -using Mono.Unix; using Hyena; using Banshee.Base; using Banshee.Collection; using Banshee.Collection.Database; -using Banshee.ServiceStack; using Banshee.Telepathy.DBus; using Banshee.Telepathy.API; diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TelepathyDownload.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TelepathyDownload.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TelepathyDownload.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TelepathyDownload.cs 2010-03-26 22:37:09.000000000 +0000 @@ -27,7 +27,7 @@ // using System; -using Mono.Unix; +using Mono.Addins; using Banshee.Base; using Banshee.Collection.Database; @@ -104,7 +104,8 @@ if (base.Start ()) { FileTransfer.Start (); TelepathyNotification.Create ().Show (FileTransfer.Contact.Name, - String.Format (Catalog.GetString ("is sending {0} with Banshee"), FileTransfer.Filename)); + String.Format (AddinManager.CurrentLocalizer.GetString ("is sending {0} with Banshee"), + FileTransfer.Filename)); return true; } } diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TelepathyUpload.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TelepathyUpload.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TelepathyUpload.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TelepathyUpload.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,7 +28,7 @@ using System; using System.Collections.Generic; -using Mono.Unix; +using Mono.Addins; using Hyena; @@ -100,7 +100,8 @@ if (FileTransfer != null) { SetTransferFilename (FileTransfer); TelepathyNotification.Create ().Show (FileTransfer.Contact.Name, - String.Format (Catalog.GetString ("is downloading {0} with Banshee"), FileTransfer.Filename)); + String.Format (AddinManager.CurrentLocalizer.GetString ("is downloading {0} with Banshee"), + FileTransfer.Filename)); return base.Start (); } diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TubeManager.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TubeManager.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TubeManager.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Data/TubeManager.cs 2010-03-26 22:37:09.000000000 +0000 @@ -27,20 +27,9 @@ // using System; -using System.Timers; using System.Collections.Generic; -using Mono.Unix; -using Hyena.Data.Sqlite; -using Banshee.Base; -using Banshee.Collection; -using Banshee.Collection.Database; -using Banshee.Gui.Dialogs; -using Banshee.Library; -using Banshee.Sources; -using Banshee.ServiceStack; -using Banshee.Telepathy.Gui; using Banshee.Telepathy.DBus; using Banshee.Telepathy.Net; diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/ContactRequestDialog.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/ContactRequestDialog.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/ContactRequestDialog.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/ContactRequestDialog.cs 2010-03-26 22:37:09.000000000 +0000 @@ -27,7 +27,7 @@ // using System; -using Mono.Unix; +using Mono.Addins; using Gtk; namespace Banshee.Telepathy.Gui @@ -39,7 +39,7 @@ public ContactRequestDialog (string contact_name) : base () { - Title = Catalog.GetString ("Contact Request"); + Title = AddinManager.CurrentLocalizer.GetString ("Contact Request"); HasSeparator = false; BorderWidth = 5; @@ -64,7 +64,7 @@ hbox.PackStart (image, false, false, 0); hbox.PackStart (vbox, true, true, 0); - message = new Label (String.Format (Catalog.GetString ("{0} would like to browse your music library."), contact_name)); + message = new Label (String.Format (AddinManager.CurrentLocalizer.GetString ("{0} would like to browse your music library."), contact_name)); message.Xalign = 0.0f; message.Show (); @@ -80,7 +80,7 @@ VBox.PackEnd (bottom_box, false, false, 0); Button accept_button = new Button (); - accept_button.Label = Catalog.GetString ("Accept"); + accept_button.Label = AddinManager.CurrentLocalizer.GetString ("Accept"); accept_button.ShowAll (); accept_button.Activated += delegate { //login_form.Save (); @@ -91,7 +91,7 @@ AddActionWidget (accept_button, ResponseType.Accept); Button reject_button = new Button (); - reject_button.Label = Catalog.GetString ("Reject"); + reject_button.Label = AddinManager.CurrentLocalizer.GetString ("Reject"); reject_button.ShowAll (); reject_button.Activated += delegate { //login_form.Save (); diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/ContactSourceContents.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/ContactSourceContents.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/ContactSourceContents.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/ContactSourceContents.cs 2010-03-26 22:37:09.000000000 +0000 @@ -31,7 +31,7 @@ using System.Collections.Generic; using Gtk; -using Mono.Unix; +using Mono.Addins; using Banshee.Collection; using Banshee.Collection.Gui; @@ -98,7 +98,7 @@ } if (contacts == null) { - contacts = new TitledList (Catalog.GetString ("Contacts")); + contacts = new TitledList (AddinManager.CurrentLocalizer.GetString ("Contacts")); contacts.PackStart (contacts_view, true, true, 0); contacts_view.Show (); diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/DownloadManagerUi.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/DownloadManagerUi.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/DownloadManagerUi.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/DownloadManagerUi.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,7 +28,7 @@ using System; -using Mono.Unix; +using Mono.Addins; using Hyena; using Hyena.Jobs; @@ -41,22 +41,20 @@ { public class DownloadManagerUi : TransferManagerUi { - //private TelepathyService service = null; private readonly TelepathyDownloadManager download_manager = new TelepathyDownloadManager (); - private Banshee.Library.LibraryImportManager import_manager = null; + private Banshee.Library.LibraryImportManager import_manager = null; public DownloadManagerUi () : base () { - //this.service = service; - Title = Catalog.GetString ("Download(s) from Contacts"); - CancelMessage = Catalog.GetString ("Downloads are in progress. Would you like to cancel them?"); + Title = AddinManager.CurrentLocalizer.GetString ("Download(s) from Contacts"); + CancelMessage = AddinManager.CurrentLocalizer.GetString ("Downloads are in progress. Would you like to cancel them?"); download_manager.Updated += OnUpdated; download_manager.Completed += OnCompleted; download_manager.TransferCompleted += OnTransferCompleted; - - import_manager = new Banshee.Library.LibraryImportManager (true); + + import_manager = new Banshee.Library.LibraryImportManager (true); } public TelepathyDownloadManager DownloadManager { @@ -75,8 +73,6 @@ private void ImportTrack (string path) { - //Banshee.Library.LibraryImportManager import_manager = ServiceManager.Get (); - if (import_manager.ImportTrack (path) != null) { import_manager.NotifyAllSources (); } diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TelepathyActions.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TelepathyActions.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TelepathyActions.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TelepathyActions.cs 2010-03-26 22:37:09.000000000 +0000 @@ -29,7 +29,7 @@ using System; using Gtk; -using Mono.Unix; +using Mono.Addins; using Banshee.Collection; using Banshee.Collection.Database; @@ -60,43 +60,43 @@ Add (new ActionEntry [] { new ActionEntry ("DownloadTrackAction", null, - Catalog.GetString ("Download Track(s)"), null, - Catalog.GetString ("Download selected tracks to your computer"), + AddinManager.CurrentLocalizer.GetString ("Download Track(s)"), null, + AddinManager.CurrentLocalizer.GetString ("Download selected tracks to your computer"), OnDownloadTrack) }); Add (new ActionEntry [] { new ActionEntry ("CancelDownloadTrackAction", null, - Catalog.GetString ("Cancel Download(s)"), null, - Catalog.GetString ("Cancel download of selected tracks to your computer"), + AddinManager.CurrentLocalizer.GetString ("Cancel Download(s)"), null, + AddinManager.CurrentLocalizer.GetString ("Cancel download of selected tracks to your computer"), OnCancelDownloadTrack) }); Add (new ActionEntry [] { new ActionEntry ("CancelBrowseRequest", null, - Catalog.GetString ("Cancel Browse Request"), "c", - Catalog.GetString ("Cancel pending request to browse a contact's library"), + AddinManager.CurrentLocalizer.GetString ("Cancel Browse Request"), "c", + AddinManager.CurrentLocalizer.GetString ("Cancel pending request to browse a contact's library"), OnCancelBrowseRequest) }); Add (new ToggleActionEntry [] { new ToggleActionEntry ("AllowDownloadsAction", null, - Catalog.GetString ("Allow Downloads"), null, - Catalog.GetString ("Allow file downloads when sharing libraries"), + AddinManager.CurrentLocalizer.GetString ("Allow Downloads"), null, + AddinManager.CurrentLocalizer.GetString ("Allow file downloads when sharing libraries"), OnAllowDownloads, ContactContainerSource.AllowDownloadsSchema.Get ()) }); Add (new ToggleActionEntry [] { new ToggleActionEntry ("AllowStreamingAction", null, - Catalog.GetString ("Allow Streaming"), null, - Catalog.GetString ("Allow streaming when sharing libraries"), + AddinManager.CurrentLocalizer.GetString ("Allow Streaming"), null, + AddinManager.CurrentLocalizer.GetString ("Allow streaming when sharing libraries"), OnAllowStreaming, ContactContainerSource.AllowStreamingSchema.Get ()) }); Add (new ToggleActionEntry [] { new ToggleActionEntry ("ShareCurrentlyPlayingAction", null, - Catalog.GetString ("Share Currently Playing"), null, - Catalog.GetString ("Set Empathy presence message to what you're currently playing"), + AddinManager.CurrentLocalizer.GetString ("Share Currently Playing"), null, + AddinManager.CurrentLocalizer.GetString ("Set Empathy presence message to what you're currently playing"), OnShareCurrentlyPlaying, ContactContainerSource.ShareCurrentlyPlayingSchema.Get ()) }); @@ -139,7 +139,7 @@ //Log.Debug (String.Format ("{0} announcing", ContactContainerSource.ShareCurrentlyPlayingSchema.Get ())); if (announcer != null && ContactContainerSource.ShareCurrentlyPlayingSchema.Get ()) { if (track != null) { - announcer.Announce (String.Format (Catalog.GetString ("Currently playing {0} by {1} from {2}"), + announcer.Announce (String.Format (AddinManager.CurrentLocalizer.GetString ("Currently playing {0} by {1} from {2}"), track.TrackTitle, track.ArtistName, track.AlbumTitle)); } } diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TelepathyNotification.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TelepathyNotification.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TelepathyNotification.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TelepathyNotification.cs 2010-03-26 22:37:09.000000000 +0000 @@ -27,7 +27,6 @@ // using System; -using Mono.Unix; using Gdk; using Notifications; @@ -112,13 +111,13 @@ current_nf.Urgency = Urgency.Low; current_nf.Timeout = 4500; // if (!current_track.IsLive && ActionsSupported && interface_action_service.PlaybackActions["NextAction"].Sensitive) { - // current_nf.AddAction ("skip-song", Catalog.GetString("Skip this item"), OnSongSkipped); + // current_nf.AddAction ("skip-song", AddinManager.CurrentLocalizer.GetString ("Skip this item"), OnSongSkipped); // } current_nf.Show (); Hyena.Log.Debug ("Showing notification"); } catch (Exception e) { Console.WriteLine (e.StackTrace); - Hyena.Log.Warning (Catalog.GetString ("Cannot show notification"), e.Message, false); + Hyena.Log.Warning ("Cannot show notification", e.Message, false); } } } diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TransferManagerUi.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TransferManagerUi.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TransferManagerUi.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/TransferManagerUi.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,7 +28,7 @@ using System; -using Mono.Unix; +using Mono.Addins; using Hyena.Jobs; using Banshee.ServiceStack; @@ -47,20 +47,20 @@ Initialize (); } - private string title = Catalog.GetString ("Transfer(s) to Contacts"); + private string title = AddinManager.CurrentLocalizer.GetString ("Transfer(s) to Contacts"); public string Title { get { return title; } protected set { title = value; } } - private string cancel_message = Catalog.GetString ( + private string cancel_message = AddinManager.CurrentLocalizer.GetString ( "File transfers are in progress. Would you like to cancel them?"); public string CancelMessage { get { return cancel_message; } protected set { cancel_message = value; } } - private string progress_message = Catalog.GetString ("Transferring {0} of {1}"); + private string progress_message = AddinManager.CurrentLocalizer.GetString ("Transferring {0} of {1}"); public string ProgressMessage { get { return progress_message; } set { progress_message = value; } @@ -128,7 +128,7 @@ return; } - user_job = new UserJob (Title, Catalog.GetString ("Initializing")); + user_job = new UserJob (Title, AddinManager.CurrentLocalizer.GetString ("Initializing")); user_job.SetResources (Resource.Cpu, Resource.Disk); user_job.PriorityHints = PriorityHints.SpeedSensitive | PriorityHints.DataLossIfStopped; user_job.IconNames = new string [] { Gtk.Stock.Network }; diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/UploadManagerUi.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/UploadManagerUi.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/UploadManagerUi.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Gui/UploadManagerUi.cs 2010-03-26 22:37:09.000000000 +0000 @@ -26,19 +26,8 @@ // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // -using System; -using Mono.Unix; - -using Hyena; - -using Banshee.Base; -using Banshee.ServiceStack; -using Banshee.Telepathy; using Banshee.Telepathy.Data; -using Banshee.Telepathy.API; -using Banshee.Telepathy.API.Dispatchables; - namespace Banshee.Telepathy.Gui { public class UploadManagerUi : TransferManagerUi diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Net/StreamingHTTPProxyServer.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Net/StreamingHTTPProxyServer.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Net/StreamingHTTPProxyServer.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Net/StreamingHTTPProxyServer.cs 2010-03-26 22:37:09.000000000 +0000 @@ -29,14 +29,10 @@ using System; using System.IO; using System.Text; -using System.Web; using System.Net; using System.Net.Sockets; -using System.Threading; -using System.Collections; using Banshee.Collection; -using Banshee.Sources; using Banshee.Telepathy.Data; using Banshee.Web; diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Net/StreamingServer.cs banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Net/StreamingServer.cs --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Net/StreamingServer.cs 2010-03-09 21:40:10.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Banshee.Telepathy.Net/StreamingServer.cs 2010-03-26 22:37:09.000000000 +0000 @@ -29,13 +29,9 @@ using System; using System.IO; using System.Text; -using System.Web; using System.Net; using System.Net.Sockets; -using System.Threading; -using System.Collections; -using Banshee.Collection; using Banshee.Collection.Database; using Banshee.Web; diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Makefile.in banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Makefile.in --- banshee-community-extensions-1.5.5/src/Telepathy/Banshee.Telepathy/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Banshee.Telepathy/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -41,6 +41,7 @@ subdir = src/Telepathy/Banshee.Telepathy ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -86,6 +87,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -201,6 +204,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/Telepathy/Makefile.in banshee-community-extensions-1.6.0/src/Telepathy/Makefile.in --- banshee-community-extensions-1.5.5/src/Telepathy/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/Telepathy/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -36,6 +36,7 @@ AUTHORS ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -83,6 +84,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -198,6 +201,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/UbuntuOneMusicStore/Banshee.UbuntuOneMusicStore/UbuntuOneMusicStoreSource.cs banshee-community-extensions-1.6.0/src/UbuntuOneMusicStore/Banshee.UbuntuOneMusicStore/UbuntuOneMusicStoreSource.cs --- banshee-community-extensions-1.5.5/src/UbuntuOneMusicStore/Banshee.UbuntuOneMusicStore/UbuntuOneMusicStoreSource.cs 2010-03-11 05:58:07.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/UbuntuOneMusicStore/Banshee.UbuntuOneMusicStore/UbuntuOneMusicStoreSource.cs 2010-03-26 22:37:09.000000000 +0000 @@ -28,41 +28,33 @@ using System; -using Mono.Unix; +using Mono.Addins; using Gdk; +using Hyena; + using Banshee.Base; +using Banshee.Collection; +using Banshee.Gui; +using Banshee.ServiceStack; using Banshee.Sources; using Banshee.Sources.Gui; -// Other namespaces you might want: -using Banshee.ServiceStack; -using Banshee.Preferences; -using Banshee.MediaEngine; -using Banshee.Gui; -using Banshee.PlaybackController; -using Banshee.Collection; - namespace Banshee.UbuntuOneMusicStore { - // We are inheriting from Source, the top-level, most generic type of Source. - // Other types include (inheritance indicated by indentation): - // DatabaseSource - generic, DB-backed Track source; used by PlaylistSource - // PrimarySource - 'owns' tracks, used by DaapSource, DapSource - // LibrarySource - used by Music, Video, Podcasts, and Audiobooks public class UbuntuOneMusicStoreSource : Source { // In the sources TreeView, sets the order value for this source, small on top const int sort_order = 190; - public UbuntuOneMusicStoreSource () : base (Catalog.GetString ("Ubuntu One Music Store"), Catalog.GetString ("Ubuntu One Music Store"), sort_order) + public UbuntuOneMusicStoreSource () : base (AddinManager.CurrentLocalizer.GetString ("Ubuntu One Music Store"), AddinManager.CurrentLocalizer.GetString ("Ubuntu One Music Store"), sort_order) { Pixbuf icon = new Pixbuf (System.Reflection.Assembly.GetExecutingAssembly () .GetManifestResourceStream ("ubuntuone.png")); Properties.Set ("Icon.Pixbuf_22", icon.ScaleSimple (22, 22, InterpType.Bilinear)); Properties.Set ("Nereid.SourceContents", new CustomView ()); - Hyena.Log.Debug ("U1MS: Initialized"); + Log.Debug ("U1MS: Initialized"); } // A count of 0 will be hidden in the source TreeView @@ -84,11 +76,11 @@ private void PlayMP3Preview (object Sender, UbuntuOne.PreviewMp3Args a) { - Hyena.Log.Debug ("U1MS: Playing preview: ", a.Url ); + Log.Debug ("U1MS: Playing preview: ", a.Url ); TrackInfo PreviewTrack = new TrackInfo (); PreviewTrack.TrackTitle = a.Title; - PreviewTrack.ArtistName = "Track Preview"; - PreviewTrack.AlbumTitle = "Ubuntu One Music Store"; + PreviewTrack.ArtistName = AddinManager.CurrentLocalizer.GetString ("Track Preview"); + PreviewTrack.AlbumTitle = AddinManager.CurrentLocalizer.GetString ("Ubuntu One Music Store"); PreviewTrack.Uri = new SafeUri (a.Url); ServiceManager.PlayerEngine.OpenPlay (PreviewTrack); ServiceManager.PlaybackController.StopWhenFinished = true; @@ -96,15 +88,15 @@ private void AddDownloadToLibrary (object Sender, UbuntuOne.DownloadFinishedArgs a) { - Hyena.Log.Debug ("U1MS: Track downloaded: ", a.Path); + Log.Debug ("U1MS: Track downloaded: ", a.Path); ServiceManager.Get ().ImportTrack (new SafeUri (a.Path)); ServiceManager.Get ().NotifyAllSources (); } private void PlayU1MSLibrary (object Sender, UbuntuOne.PlayLibraryArgs a) { - Hyena.Log.Debug ("U1MS: Playing from library: ", a.Path); - Hyena.Log.Debug ("U1MS: U1 library location: ", U1LibraryLocation); + Log.Debug ("U1MS: Playing from library: ", a.Path); + Log.Debug ("U1MS: U1 library location: ", U1LibraryLocation); int track_id = Banshee.Collection.Database.DatabaseTrackInfo.GetTrackIdForUri (System.IO.Path.Combine (U1LibraryLocation, a.Path)); if (track_id > 0) { @@ -116,10 +108,10 @@ private void U1MSUrlLoaded (object Sender, UbuntuOne.UrlLoadedArgs a) { - Hyena.Log.Debug ("U1MS: Url Loaded: ", a.Url); + Log.Debug ("U1MS: Url Loaded: ", a.Url); } } - + private class CustomView : ISourceContents { StoreWrapper store = new StoreWrapper (); @@ -129,6 +121,5 @@ public Gtk.Widget Widget { get { return store; } } public ISource Source { get { return null; } } } - } } diff -Nru banshee-community-extensions-1.5.5/src/UbuntuOneMusicStore/Makefile.in banshee-community-extensions-1.6.0/src/UbuntuOneMusicStore/Makefile.in --- banshee-community-extensions-1.5.5/src/UbuntuOneMusicStore/Makefile.in 2010-03-11 06:03:36.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/UbuntuOneMusicStore/Makefile.in 2010-03-31 19:47:55.000000000 +0100 @@ -40,6 +40,7 @@ subdir = src/UbuntuOneMusicStore ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/m4/extensions/alarmclock.m4 \ + $(top_srcdir)/build/m4/extensions/appindicator.m4 \ $(top_srcdir)/build/m4/extensions/awn.m4 \ $(top_srcdir)/build/m4/extensions/banshee.m4 \ $(top_srcdir)/build/m4/extensions/clutterflow.m4 \ @@ -77,6 +78,8 @@ ALL_LINGUAS = @ALL_LINGUAS@ AMTAR = @AMTAR@ AM_MAKEFLAGS = @AM_MAKEFLAGS@ +APPINDICATORSHARP_CFLAGS = @APPINDICATORSHARP_CFLAGS@ +APPINDICATORSHARP_LIBS = @APPINDICATORSHARP_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -192,6 +195,8 @@ MSGMERGE = @MSGMERGE@ NM = @NM@ NMEDIT = @NMEDIT@ +NOTIFYSHARP_CFLAGS = @NOTIFYSHARP_CFLAGS@ +NOTIFYSHARP_LIBS = @NOTIFYSHARP_LIBS@ NOTIFY_SHARP_CFLAGS = @NOTIFY_SHARP_CFLAGS@ NOTIFY_SHARP_LIBS = @NOTIFY_SHARP_LIBS@ NUNIT_CFLAGS = @NUNIT_CFLAGS@ diff -Nru banshee-community-extensions-1.5.5/src/UbuntuOneMusicStore/UbuntuOneMusicStore.addin.xml banshee-community-extensions-1.6.0/src/UbuntuOneMusicStore/UbuntuOneMusicStore.addin.xml --- banshee-community-extensions-1.5.5/src/UbuntuOneMusicStore/UbuntuOneMusicStore.addin.xml 2010-03-11 05:58:07.000000000 +0000 +++ banshee-community-extensions-1.6.0/src/UbuntuOneMusicStore/UbuntuOneMusicStore.addin.xml 2010-03-18 22:47:33.000000000 +0000 @@ -8,7 +8,7 @@ category="Community Extensions" description="This extension grants access to the Ubuntu One Music Store, powered by 7digital." author="Jo Shields" - url="http://one.ubuntu.com.org/" + url="http://one.ubuntu.com/" defaultEnabled="false">