gnome-control-center r9224 - in trunk: . typing-break
- From: jensg svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-control-center r9224 - in trunk: . typing-break
- Date: Sat, 31 Jan 2009 16:29:35 +0000 (UTC)
Author: jensg
Date: Sat Jan 31 16:29:35 2009
New Revision: 9224
URL: http://svn.gnome.org/viewvc/gnome-control-center?rev=9224&view=rev
Log:
2009-01-31 Jens Granseuer <jensgr gmx net>
Patch by: Maxim Ermilov <zaspire rambler ru>
* configure.in: add optional dependency on libcanberra-gtk for bug
#169473
2009-01-31 Jens Granseuer <jensgr gmx net>
Patch by: Maxim Ermilov <zaspire rambler ru>
* Makefile.am:
* drw-break-window.c: (drw_break_window_init), (clock_timeout_cb):
play a sound when the display is locked or unlocked (bug #169473)
Modified:
trunk/ChangeLog
trunk/configure.in
trunk/typing-break/ChangeLog
trunk/typing-break/Makefile.am
trunk/typing-break/drw-break-window.c
Modified: trunk/configure.in
==============================================================================
--- trunk/configure.in (original)
+++ trunk/configure.in Sat Jan 31 16:29:35 2009
@@ -60,6 +60,13 @@
AC_SUBST(TYPING_BREAK)
AC_SUBST(SCREENSAVER_LIBS)
+PKG_CHECK_MODULES(LIBCANBERRA_GTK, libcanberra-gtk, [
+ CANBERRA_GTK=1
+ AC_SUBST(LIBCANBERRA_GTK_CFLAGS)
+ AC_SUBST(LIBCANBERRA_GTK_LIBS)
+ ], [])
+AM_CONDITIONAL(HAVE_LIBCANBERRA_GTK, test "x$CANBERRA_GTK" = "x1")
+
AM_CONDITIONAL(HAVE_TYPING_BREAK, test $TYPING_BREAK = typing-break)
dnl keyboard-properties-capplet
Modified: trunk/typing-break/Makefile.am
==============================================================================
--- trunk/typing-break/Makefile.am (original)
+++ trunk/typing-break/Makefile.am Sat Jan 31 16:29:35 2009
@@ -23,6 +23,11 @@
gnome_typing_monitor_LDADD = @TYPING_LIBS@ @SCREENSAVER_LIBS@
+if HAVE_LIBCANBERRA_GTK
+ gnome_typing_monitor_CFLAGS += -DHAVE_CANBERRA_GTK @LIBCANBERRA_GTK_CFLAGS@
+ gnome_typing_monitor_LDADD += @LIBCANBERRA_GTK_LIBS@
+endif
+
imagedir = $(pkgdatadir)/pixmaps
dist_image_DATA = bar.png bar-red.png bar-green.png bar-disabled.png ocean-stripes.png
Modified: trunk/typing-break/drw-break-window.c
==============================================================================
--- trunk/typing-break/drw-break-window.c (original)
+++ trunk/typing-break/drw-break-window.c Sat Jan 31 16:29:35 2009
@@ -28,6 +28,10 @@
#include <gdk/gdkkeysyms.h>
#include <gconf/gconf-client.h>
+#ifdef HAVE_CANBERRA_GTK
+#include <canberra-gtk.h>
+#endif
+
#include "drwright.h"
#include "drw-utils.h"
#include "drw-break-window.h"
@@ -274,6 +278,9 @@
priv->clock_timeout_id = g_timeout_add (1000,
(GSourceFunc) clock_timeout_cb,
window);
+#ifdef HAVE_CANBERRA_GTK
+ ca_context_play (ca_gtk_context_get (), 0, CA_PROP_EVENT_ID, "desktop-screen-lock", NULL);
+#endif
}
static void
@@ -385,6 +392,9 @@
*/
priv->clock_timeout_id = 0;
+#ifdef HAVE_CANBERRA_GTK
+ ca_context_play (ca_gtk_context_get (), 0, CA_PROP_EVENT_ID, "alarm-clock-elapsed", NULL);
+#endif
g_signal_emit (window, signals[DONE], 0, NULL);
return FALSE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]