From 369a588e93f360877533971406de632d9a4718be Mon Sep 17 00:00:00 2001 From: Mike Kestner Date: Mon, 31 May 2004 18:48:25 +0000 Subject: [PATCH] 2004-05-31 Mike Kestner * configure.in : Bump version to 0.93 and tag. 2004-05-31 Jeroen Zwartepoorte * gtk/Gtk.metadata: unhide WidgetFlags. * gtk/Widget.custom: add setter for GdkWindow prop. Add Flags prop. * gtk/glue/widget.custom: setter for window, accessors for flags. [Fixes #59337] svn path=/trunk/gtk-sharp/; revision=28578 --- ChangeLog | 11 +++++++++++ configure.in | 2 +- doc/ChangeLog | 1 + doc/en/Gtk/Widget.xml | 40 +++++++++++++++++++++++++++------------- gtk/Gtk.metadata | 1 - gtk/Widget.custom | 21 +++++++++++++++++++++ gtk/glue/widget.c | 19 +++++++++++++++++++ 7 files changed, 80 insertions(+), 15 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8857d0d1c..653606f82 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2004-05-31 Mike Kestner + + * configure.in : Bump version to 0.93 and tag. + +2004-05-31 Jeroen Zwartepoorte + + * gtk/Gtk.metadata: unhide WidgetFlags. + * gtk/Widget.custom: add setter for GdkWindow prop. Add Flags prop. + * gtk/glue/widget.custom: setter for window, accessors for flags. + [Fixes #59337] + 2004-05-31 Jeroen Zwartepoorte * gdk/Gdk.metadata: fix membler names in WindowClass. diff --git a/configure.in b/configure.in index 4c28dcbb1..e3f99c64c 100644 --- a/configure.in +++ b/configure.in @@ -2,7 +2,7 @@ AC_INIT(README) AC_CANONICAL_SYSTEM AM_CONFIG_HEADER(config.h) -AM_INIT_AUTOMAKE(gtk-sharp, 0.92.99) +AM_INIT_AUTOMAKE(gtk-sharp, 0.93) AM_MAINTAINER_MODE API_VERSION=1.0.0.0 diff --git a/doc/ChangeLog b/doc/ChangeLog index c1aae5536..589603dec 100644 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -2,6 +2,7 @@ * en/Gdk/Rectangle.xml : docs for newly changed Isect and Union. * en/Gdk/WindowClass.xml : move existing docs to new member names. + * en/Gtk/Widget.xml : run updater for Flags prop addition. 2004-05-28 Mike Kestner diff --git a/doc/en/Gtk/Widget.xml b/doc/en/Gtk/Widget.xml index 619198078..ec5415dc9 100644 --- a/doc/en/Gtk/Widget.xml +++ b/doc/en/Gtk/Widget.xml @@ -1182,18 +1182,6 @@ - - - Property - - Gdk.Window - - - To be added - To be added: an object of type 'Gdk.Window' - To be added - - Property @@ -4674,5 +4662,31 @@ handle focus grabs. To be added + + + Property + + Gdk.Window + + + + To be added + a + To be added + + + + + Property + + System.Int32 + + + + To be added + a + To be added + + - \ No newline at end of file + diff --git a/gtk/Gtk.metadata b/gtk/Gtk.metadata index 2ad609fee..bbc8ff03a 100644 --- a/gtk/Gtk.metadata +++ b/gtk/Gtk.metadata @@ -41,7 +41,6 @@ 1 1 1 - 1 FinishEditing WidgetRemoved GetIsEditable diff --git a/gtk/Widget.custom b/gtk/Widget.custom index e4ac3f6b0..9a6b02de0 100644 --- a/gtk/Widget.custom +++ b/gtk/Widget.custom @@ -18,6 +18,8 @@ public Gdk.Rectangle Allocation { [DllImport ("gtksharpglue")] static extern IntPtr gtksharp_gtk_widget_get_window (IntPtr widget); +[DllImport ("gtksharpglue")] +static extern void gtksharp_gtk_widget_set_window (IntPtr widget, IntPtr window); public Gdk.Window GdkWindow { get { IntPtr raw_ret = gtksharp_gtk_widget_get_window (Handle); @@ -28,6 +30,10 @@ public Gdk.Window GdkWindow { } return null; } + set { + Gdk.Window window = value as Gdk.Window; + gtksharp_gtk_widget_set_window (Handle, window.Handle); + } } public void AddAccelerator (string accel_signal, AccelGroup accel_group, AccelKey accel_key) @@ -50,3 +56,18 @@ public Gtk.StateType State { return (Gtk.StateType) gtksharp_gtk_widget_get_state (Handle); } } + +[DllImport("gtksharpglue")] +static extern int gtksharp_gtk_widget_get_flags (IntPtr raw); + +[DllImport("gtksharpglue")] +static extern void gtksharp_gtk_widget_set_flags (IntPtr raw, int flags); + +public int Flags { + get { + return gtksharp_gtk_widget_get_flags (Handle); + } + set { + gtksharp_gtk_widget_set_flags (Handle, (int) value); + } +} diff --git a/gtk/glue/widget.c b/gtk/glue/widget.c index b3cd4b2bc..ef55de167 100644 --- a/gtk/glue/widget.c +++ b/gtk/glue/widget.c @@ -10,6 +10,7 @@ /* Forward declarations */ GdkRectangle *gtksharp_gtk_widget_get_allocation (GtkWidget *widget); GdkWindow *gtksharp_gtk_widget_get_window (GtkWidget *widget); +void gtksharp_gtk_widget_set_window (GtkWidget *widget, GdkWindow *window); int gtksharp_gtk_widget_get_state (GtkWidget *widget); /* */ @@ -25,8 +26,26 @@ gtksharp_gtk_widget_get_window (GtkWidget *widget) return widget->window; } +void +gtksharp_gtk_widget_set_window (GtkWidget *widget, GdkWindow *window) +{ + widget->window = window; +} + int gtksharp_gtk_widget_get_state (GtkWidget *widget) { return GTK_WIDGET_STATE (widget); } + +int +gtksharp_gtk_widget_get_flags (GtkWidget *widget) +{ + return GTK_WIDGET_FLAGS (widget); +} + +void +gtksharp_gtk_widget_set_flags (GtkWidget *widget, int flags) +{ + GTK_WIDGET_SET_FLAGS (widget, flags); +}