add "resizable" property

2001-06-26  Havoc Pennington  <hp@redhat.com>

	* gtk/gtkwindow.c (gtk_window_class_init): add "resizable"
	property
This commit is contained in:
Havoc Pennington 2001-06-26 19:23:46 +00:00 committed by Havoc Pennington
parent 94f7d7e604
commit db0fe66110
8 changed files with 53 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2001-06-26 Havoc Pennington <hp@redhat.com>
* gtk/gtkwindow.c (gtk_window_class_init): add "resizable"
property
Tue Jun 26 12:59:28 2001 Jonathan Blandford <jrb@redhat.com>
* gtk/gtktreemodelsort.c (gtk_tree_model_sort_set_model): fix

View File

@ -1,3 +1,8 @@
2001-06-26 Havoc Pennington <hp@redhat.com>
* gtk/gtkwindow.c (gtk_window_class_init): add "resizable"
property
Tue Jun 26 12:59:28 2001 Jonathan Blandford <jrb@redhat.com>
* gtk/gtktreemodelsort.c (gtk_tree_model_sort_set_model): fix

View File

@ -1,3 +1,8 @@
2001-06-26 Havoc Pennington <hp@redhat.com>
* gtk/gtkwindow.c (gtk_window_class_init): add "resizable"
property
Tue Jun 26 12:59:28 2001 Jonathan Blandford <jrb@redhat.com>
* gtk/gtktreemodelsort.c (gtk_tree_model_sort_set_model): fix

View File

@ -1,3 +1,8 @@
2001-06-26 Havoc Pennington <hp@redhat.com>
* gtk/gtkwindow.c (gtk_window_class_init): add "resizable"
property
Tue Jun 26 12:59:28 2001 Jonathan Blandford <jrb@redhat.com>
* gtk/gtktreemodelsort.c (gtk_tree_model_sort_set_model): fix

View File

@ -1,3 +1,8 @@
2001-06-26 Havoc Pennington <hp@redhat.com>
* gtk/gtkwindow.c (gtk_window_class_init): add "resizable"
property
Tue Jun 26 12:59:28 2001 Jonathan Blandford <jrb@redhat.com>
* gtk/gtktreemodelsort.c (gtk_tree_model_sort_set_model): fix

View File

@ -1,3 +1,8 @@
2001-06-26 Havoc Pennington <hp@redhat.com>
* gtk/gtkwindow.c (gtk_window_class_init): add "resizable"
property
Tue Jun 26 12:59:28 2001 Jonathan Blandford <jrb@redhat.com>
* gtk/gtktreemodelsort.c (gtk_tree_model_sort_set_model): fix

View File

@ -1,3 +1,8 @@
2001-06-26 Havoc Pennington <hp@redhat.com>
* gtk/gtkwindow.c (gtk_window_class_init): add "resizable"
property
Tue Jun 26 12:59:28 2001 Jonathan Blandford <jrb@redhat.com>
* gtk/gtktreemodelsort.c (gtk_tree_model_sort_set_model): fix

View File

@ -69,6 +69,7 @@ enum {
PROP_AUTO_SHRINK,
PROP_ALLOW_SHRINK,
PROP_ALLOW_GROW,
PROP_RESIZABLE,
PROP_MODAL,
PROP_WIN_POS,
PROP_DEFAULT_WIDTH,
@ -357,6 +358,14 @@ gtk_window_class_init (GtkWindowClass *klass)
TRUE,
G_PARAM_READWRITE));
g_object_class_install_property (gobject_class,
PROP_RESIZABLE,
g_param_spec_boolean ("resizable",
_("Resizable"),
_("If TRUE, users can resize the window."),
TRUE,
G_PARAM_READWRITE));
g_object_class_install_property (gobject_class,
PROP_MODAL,
g_param_spec_boolean ("modal",
@ -596,6 +605,12 @@ gtk_window_set_property (GObject *object,
case PROP_ALLOW_GROW:
window->allow_grow = g_value_get_boolean (value);
gtk_widget_queue_resize (GTK_WIDGET (window));
g_object_notify (G_OBJECT (window), "resizable");
break;
case PROP_RESIZABLE:
window->allow_grow = g_value_get_boolean (value);
gtk_widget_queue_resize (GTK_WIDGET (window));
g_object_notify (G_OBJECT (window), "allow_grow");
break;
case PROP_MODAL:
gtk_window_set_modal (window, g_value_get_boolean (value));
@ -645,6 +660,9 @@ gtk_window_get_property (GObject *object,
case PROP_ALLOW_GROW:
g_value_set_boolean (value, window->allow_grow);
break;
case PROP_RESIZABLE:
g_value_set_boolean (value, window->allow_grow);
break;
case PROP_MODAL:
g_value_set_boolean (value, window->modal);
break;