Commit graph

16 commits

Author SHA1 Message Date
Jens Granseuer
543251c2c6 [typing-break] Reset timer after suspend
This patch does 2 things:
1) Defines a DrwTimer that we use instead of GTimer. This is just a thin
wrapper around g_get_current_time, and it means we can accurately track
typing/idle periods based on real-world wall-clock time, which GTimer is
apparently not intended to do.

2) The typing monitor has some complicated state handling where it transitions
between an IDLE state and a TYPING state. This transition is based on running a
callback once per second, and checking whether any keystrokes have been
recorded since the last time the callback was called. The actual idle *time* is
tracked separately, independently of these two states, but only when we are in
the IDLE *state* was the idle *time* checked to see if we should reset the
break timer. This leads to a race condition -- if we suspend while in the
TYPING state, then eventually we will wake up, notice that no key press has
happened in the last second, *reset the idle timer*, transition to the IDLE
state, and then check the amount of time on the idle timer. We will thus never
notice the amount of time that the computer was suspended.

I considered making the IDLE/TYPING transition code smarter, but it turns out
the desired behavior for the two states is entirely identical anyway, so rather
than adding more complexity to this pointless code, I just diked it out and
replaced them both by a single state called RUNNING.

Closes bug #430797.
2009-11-11 19:39:57 +01:00
Thomas Wood
5d882a3bdd Automatically generate .gitignore files with git.mk
Add git.mk and include it in all Makefiles to generate .gitignore files
2009-07-16 00:38:51 +01:00
Jens Granseuer
1a01a9a670 Patch by: Maxim Ermilov <zaspire@rambler.ru>
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)

svn path=/trunk/; revision=9224
2009-01-31 16:29:35 +00:00
Jens Granseuer
93832db960 new Tango-style icons by David Prieto <frandavid100@gmail.com> (bug
2008-03-24  Jens Granseuer  <jensgr@gmx.net>

	* bar*.png: new Tango-style icons by David Prieto
	<frandavid100@gmail.com> (bug #523965)

	* drw-break-window.c: (drw_break_window_init): replace custom stop icon
	by gtk-stop stock icon
	* Makefile.am:
	* stop.png: remove

svn path=/trunk/; revision=8591
2008-03-24 18:11:37 +00:00
Michael Terry
6b9550b491 use icon theme for app icons, bug #450777
svn path=/trunk/; revision=7784
2007-06-26 23:29:58 +00:00
Ross Burton
9843f45f54 Don't use libgnome in typing-break (#443554)
svn path=/trunk/; revision=7690
2007-06-05 15:44:40 +00:00
Christian Persch
43d40d7a0a Don't define directories in configure. Remove some obsolete defines, and
2007-02-02  Christian Persch  <chpe@svn.gnome.org>

	* Makefile.am:
	* capplets/about-me/Makefile.am:
	* capplets/about-me/gnome-about-me-password.c: (passdlg_init):
	* capplets/about-me/gnome-about-me.c: (about_me_setup_dialog):
	* capplets/accessibility/at-properties/Makefile.am:
	* capplets/accessibility/keyboard/Makefile.am:
	* capplets/accessibility/keyboard/accessibility-keyboard.c:
	(setup_accessX_dialog):
	* capplets/background/Makefile.am:
	* capplets/background/gnome-wp-capplet.c: (gnome_wp_create_dialog):
	* capplets/common/Makefile.am:
	* capplets/common/capplet-util.c: (capplet_set_icon):
	* capplets/default-applications/Makefile.am:
	* capplets/display/Makefile.am:
	* capplets/file-types/Makefile.am:
	* capplets/file-types/file-types-capplet.c: (create_dialog):
	* capplets/file-types/mime-category-edit-dialog.c:
	(mime_category_edit_dialog_init):
	* capplets/file-types/mime-edit-dialog.c: (mime_edit_dialog_init):
	* capplets/file-types/service-edit-dialog.c:
	(service_edit_dialog_init):
	* capplets/font/Makefile.am:
	* capplets/keybindings/Makefile.am:
	* capplets/keybindings/gnome-keybinding-properties.c:
	(create_dialog):
	* capplets/keyboard/Makefile.am:
	* capplets/keyboard/gnome-keyboard-properties-xkblt.c:
	(xkb_layout_choose):
	* capplets/keyboard/gnome-keyboard-properties-xkbmc.c:
	(choose_model):
	* capplets/keyboard/gnome-keyboard-properties.c: (create_dialog):
	* capplets/localization/Makefile.am:
	* capplets/localization/gnome-localization-properties.c:
	(create_dialog):
	* capplets/mime-type/Makefile.am:
	* capplets/mouse/Makefile.am:
	* capplets/mouse/gnome-mouse-properties.c: (create_dialog):
	* capplets/network/Makefile.am:
	* capplets/network/gnome-network-preferences.c:
	(cb_http_details_button_clicked), (main):
	* capplets/rollback/Makefile.am:
	* capplets/sound/Makefile.am:
	* capplets/sound/sound-properties-capplet.c: (create_dialog),
	(device_test_button_clicked):
	* capplets/theme-switcher/Makefile.am:
	* capplets/ui-properties/Makefile.am:
	* capplets/ui-properties/gnome-ui-properties.c: (create_dialog):
	* capplets/url-properties/Makefile.am:
	* capplets/windows/Makefile.am:
	* capplets/wm-properties/wm-desktops/Makefile.am:
	* configure.in:
	* gnome-settings-daemon/Makefile.am:
	* gnome-settings-daemon/actions/Makefile.am:
	* gnome-settings-daemon/gnome-settings-xmodmap.c:
	(gnome_settings_modmap_dialog_call):
	* gnome-settings-daemon/gnome-settings-xrdb.c:
	* gnome-settings-daemon/gsd-media-keys-window.c: (action_changed),
	(gsd_media_keys_window_init):
	* gnome-settings-daemon/xrdb/Makefile.am:
	* typing-break/Makefile.am:
	* vfs-methods/themus/Makefile.am: Don't define directories in
	configure. Remove some obsolete defines, and use the standard
	installation paths. Bug #395383.

svn path=/trunk/; revision=7226
2007-02-02 18:12:40 +00:00
Christian Persch
c19d6d800d Fix localedir defines. Bug #395383.
2007-01-31  Christian Persch  <chpe@svn.gnome.org>

	* capplets/accessibility/at-properties/Makefile.am:
	* capplets/accessibility/keyboard/Makefile.am:
	* capplets/background/Makefile.am:
	* capplets/common/Makefile.am:
	* capplets/default-applications/Makefile.am:
	* capplets/display/Makefile.am:
	* capplets/font/Makefile.am:
	* capplets/keybindings/Makefile.am:
	* capplets/keyboard/Makefile.am:
	* capplets/mouse/Makefile.am:
	* capplets/network/Makefile.am:
	* capplets/theme-switcher/Makefile.am:
	* capplets/ui-properties/Makefile.am:
	* capplets/windows/Makefile.am:
	* configure.in:
	* gnome-settings-daemon/Makefile.am:
	* libbackground/Makefile.am:
	* libwindow-settings/Makefile.am:
	* typing-break/Makefile.am:
	* vfs-methods/fontilus/Makefile.am:
	* vfs-methods/themus/Makefile.am: Fix localedir defines. Bug #395383.

svn path=/trunk/; revision=7219
2007-01-31 21:09:43 +00:00
Vincent Untz
0bbfe98c03 set default window icon and application name install icons use
2007-01-09  Vincent Untz <vuntz@gnome.org>

	* main.c: (main): set default window icon and application name
	* Makefile.am: install icons
	* drwright.c: (popup_about_cb): use gtk_about_dialog_show()
	* typing-monitor.png:
	* typing-monitor.svn: new
	Fix bug #348641, icon by Andreas Nilsson <nisses.mail@home.se>, patch
	by Luca Cavalli <luca.cavalli@gmail.com>

svn path=/trunk/; revision=7124
2007-01-09 19:13:39 +00:00
Kjartan Maraas
422223acaf Don't redefine GNOMELOCALEDIR. Don't use a const char * to allocate and
2006-11-15  Kjartan Maraas  <kmaraas@gnome.org>

	* Makefile.am: Don't redefine GNOMELOCALEDIR.
	* drw-break-window.c: (postpone_entry_activate_cb):
	Don't use a const char * to allocate and free strings.
2006-11-15 17:21:53 +00:00
Vincent Untz
1c194b74dc Fixes #348639
2006-07-25  Vincent Untz <vuntz@gnome.org>

	Fixes #348639

	* Makefile.am:
	* drwrigth.c: use GtkStatusIcon instead of libegg.

	* eggtrayicon.c: removed.
2006-07-25 19:33:48 +00:00
Rodrigo Moya
83f0ec0aea Fixes #326141
2006-01-09  Rodrigo Moya <rodrigo@novell.com>

	Fixes #326141

	* drwright.c (popup_preferences_cb):
	* egg-spawn.[ch]:
	* Makefile.am: kill egg_spawn_* functions, use gdk_spawn_* instead.
2006-01-09 12:22:34 +00:00
Jody Goldberg
9a9008178d merge and update patch from
http://bugzilla.gnome.org/show_bug.cgi?id=134895
2004-03-31 21:30:23 +00:00
Richard Hult
05294ea934 Multihead support, fixes bug #119827.
2003-08-24  Richard Hult  <richard@imendio.com>

	* Makefile.am:
	* drw-break-window.c:
	* drwright.c: Multihead support, fixes bug #119827.
2003-08-24 16:29:20 +00:00
Richard Hult
f39c8ca372 Remove this and use gnome-i18n.h instead.
2003-06-27  Richard Hult  <richard@imendio.com>

	* typing-break/drw-intl.h: Remove this and use gnome-i18n.h
	instead.

	* typing-break/Makefile.am: Remove drw-intl.h

	* typing-break/drwright.c:
	* typing-break/drwright.h:
	* typing-break/drw-break-window.c: Merge in changes from drwright.
2003-06-27 15:47:32 +00:00
Jonathan Blandford
56057239d5 added the typing break to CVS from drwright.
Thu Jun 26 07:38:45 2003  Jonathan Blandford  <jrb@gnome.org>

	* typing-break/drwright.c: added the typing break to CVS from
	drwright.
2003-06-26 11:40:10 +00:00