From 105b82040826bd4215b17250001d110645e51e09 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Orsini Date: Thu, 26 Apr 2012 10:26:47 +0000 Subject: [PATCH] improved notification (added psensor icon). --- NEWS | 1 + configure | 20 ++++++++++---------- po/Makefile.in | 2 +- src/ui.h | 2 ++ src/ui_notify.c | 6 +++--- 5 files changed, 17 insertions(+), 14 deletions(-) diff --git a/NEWS b/NEWS index a3f9f60..d224bb5 100644 --- a/NEWS +++ b/NEWS @@ -35,6 +35,7 @@ ** psensor: added the degree sign before the temperature symbols. ** psensor: alarm limit edition using the temperature unit set in the global pref. +** psensor: improved notification (added psensor icon). * v0.6.2.17 diff --git a/configure b/configure index 2e3736d..3b50131 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.68 for psensor 0.7.0.0a. +# Generated by GNU Autoconf 2.68 for psensor 0.7.0.x. # # Report bugs to . # @@ -560,8 +560,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='psensor' PACKAGE_TARNAME='psensor' -PACKAGE_VERSION='0.7.0.0a' -PACKAGE_STRING='psensor 0.7.0.0a' +PACKAGE_VERSION='0.7.0.x' +PACKAGE_STRING='psensor 0.7.0.x' PACKAGE_BUGREPORT='jeanfi@gmail.com' PACKAGE_URL='http://wpitchoune.net/psensor' @@ -1360,7 +1360,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures psensor 0.7.0.0a to adapt to many kinds of systems. +\`configure' configures psensor 0.7.0.x to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1434,7 +1434,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of psensor 0.7.0.0a:";; + short | recursive ) echo "Configuration of psensor 0.7.0.x:";; esac cat <<\_ACEOF @@ -1576,7 +1576,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -psensor configure 0.7.0.0a +psensor configure 0.7.0.x generated by GNU Autoconf 2.68 Copyright (C) 2010 Free Software Foundation, Inc. @@ -1999,7 +1999,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by psensor $as_me 0.7.0.0a, which was +It was created by psensor $as_me 0.7.0.x, which was generated by GNU Autoconf 2.68. Invocation command line was $ $0 $@ @@ -2816,7 +2816,7 @@ fi # Define the identity of the package. PACKAGE='psensor' - VERSION='0.7.0.0a' + VERSION='0.7.0.x' cat >>confdefs.h <<_ACEOF @@ -9181,7 +9181,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by psensor $as_me 0.7.0.0a, which was +This file was extended by psensor $as_me 0.7.0.x, which was generated by GNU Autoconf 2.68. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -9248,7 +9248,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -psensor config.status 0.7.0.0a +psensor config.status 0.7.0.x configured by $0, generated by GNU Autoconf 2.68, with options \\"\$ac_cs_config\\" diff --git a/po/Makefile.in b/po/Makefile.in index a11af2b..4cfde9c 100644 --- a/po/Makefile.in +++ b/po/Makefile.in @@ -11,7 +11,7 @@ # Origin: gettext-0.16 PACKAGE = psensor -VERSION = 0.7.0.0a +VERSION = 0.7.0.x PACKAGE_BUGREPORT = jeanfi@gmail.com SHELL = /bin/sh diff --git a/src/ui.h b/src/ui.h index b78fab2..f9e40d1 100644 --- a/src/ui.h +++ b/src/ui.h @@ -30,6 +30,8 @@ #include "psensor.h" +#define PSENSOR_ICON "psensor" + struct ui_psensor { struct psensor **sensors; diff --git a/src/ui_notify.c b/src/ui_notify.c index c92b5fb..fd80885 100644 --- a/src/ui_notify.c +++ b/src/ui_notify.c @@ -64,11 +64,11 @@ void ui_notify(struct psensor *sensor, struct ui_psensor *ui) */ #if NOTIFY_CHECK_VERSION(0, 7, 0) notif = notify_notification_new - (_("Temperature alert"), name, NULL); + (_("Temperature alert"), name, PSENSOR_ICON); #else notif = notify_notification_new(_("Temperature alert"), name, - NULL, + PSENSOR_ICON, GTK_WIDGET(ui->main_window)); #endif log_debug("notif_notification_new %s", sensor->name); @@ -77,6 +77,6 @@ void ui_notify(struct psensor *sensor, struct ui_psensor *ui) g_object_unref(notif); } else { - log_printf(LOG_ERR, "notify not initted"); + log_printf(LOG_ERR, "notify not initialized"); } } -- 2.7.4