[gtk+/widget-expand-3] Unify handling of GtkWindow::resizable property
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/widget-expand-3] Unify handling of GtkWindow::resizable property
- Date: Mon, 11 Oct 2010 23:47:51 +0000 (UTC)
commit 175f361d33c5065b3bcfedac6bbf751605e13317
Author: Matthias Clasen <mclasen redhat com>
Date: Mon Oct 11 17:23:01 2010 -0400
Unify handling of GtkWindow::resizable property
gtk/gtkwindow.c | 14 +++++++++-----
1 files changed, 9 insertions(+), 5 deletions(-)
---
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index 198366a..7bd04f0 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -1063,8 +1063,7 @@ gtk_window_set_property (GObject *object,
gtk_window_set_startup_id (window, g_value_get_string (value));
break;
case PROP_RESIZABLE:
- priv->resizable = g_value_get_boolean (value);
- gtk_widget_queue_resize (GTK_WIDGET (window));
+ gtk_window_set_resizable (window, g_value_get_boolean (value));
break;
case PROP_MODAL:
gtk_window_set_modal (window, g_value_get_boolean (value));
@@ -7495,11 +7494,16 @@ gtk_window_set_resizable (GtkWindow *window,
priv = window->priv;
- priv->resizable = (resizable != FALSE);
+ resizable = (resizable != FALSE);
- g_object_notify (G_OBJECT (window), "resizable");
+ if (priv->resizable != resizable)
+ {
+ priv->resizable = (resizable != FALSE);
- gtk_widget_queue_resize_no_redraw (GTK_WIDGET (window));
+ g_object_notify (G_OBJECT (window), "resizable");
+
+ gtk_widget_queue_resize_no_redraw (GTK_WIDGET (window));
+ }
}
/**
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]