From 4aa59684778afde8374477831b779c6255d9fe45 Mon Sep 17 00:00:00 2001 From: Alberto Garcia Date: Mon, 20 Apr 2009 12:40:52 +0200 Subject: [PATCH] 2009-04-20 Alberto Garcia * src/hildon-gtk.h * src/hildon-gtk.c (+hildon_gtk_window_set_do_not_disturb): New API to set the do-not-disturb flag. Fixes: NB#110959 (Add API to set the do-not-disturb flag to a window) --- ChangeLog | 9 +++++++++ src/hildon-gtk.c | 19 +++++++++++++++++++ src/hildon-gtk.h | 4 ++++ 3 files changed, 32 insertions(+) diff --git a/ChangeLog b/ChangeLog index 407a298..eae735d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,14 @@ 2009-04-20 Alberto Garcia + * src/hildon-gtk.h + * src/hildon-gtk.c + (+hildon_gtk_window_set_do_not_disturb): + New API to set the do-not-disturb flag. + + Fixes: NB#110959 (Add API to set the do-not-disturb flag to a window) + +2009-04-20 Alberto Garcia + * examples/hildon-progress-indicator-example.c: Fix example * src/hildon-gtk.c (set_clear_window_flag) diff --git a/src/hildon-gtk.c b/src/hildon-gtk.c index 4953add..b051279 100644 --- a/src/hildon-gtk.c +++ b/src/hildon-gtk.c @@ -364,6 +364,25 @@ hildon_gtk_window_set_progress_indicator (GtkWindow *window, } /** + * hildon_gtk_window_set_do_not_disturb: + * @window: a #GtkWindow + * @dndflag: %TRUE to set the "do-not-disturb" flag, %FALSE to clear it + * + * This function tells the window manager to set (or clear) the + * "do-not-disturb" flag on @window. + * + * Note that @window must be realized for this to work. + * + * Since: 2.2 + **/ +void +hildon_gtk_window_set_do_not_disturb (GtkWindow *window, + gboolean dndflag) +{ + set_clear_window_flag (window, "_HILDON_DO_NOT_DISTURB", dndflag); +} + +/** * hildon_gtk_hscale_new: * * Creates a new horizontal scale widget that lets the user select diff --git a/src/hildon-gtk.h b/src/hildon-gtk.h index 15dd935..dff7fbb 100644 --- a/src/hildon-gtk.h +++ b/src/hildon-gtk.h @@ -66,6 +66,10 @@ void hildon_gtk_window_set_progress_indicator (GtkWindow *window, guint state); +void +hildon_gtk_window_set_do_not_disturb (GtkWindow *window, + gboolean dndflag); + GtkWidget* hildon_gtk_hscale_new (void); -- 1.7.9.5