From b0ffe16f909faf030a451d60b238681e22840c75 Mon Sep 17 00:00:00 2001 From: Kristian Rietveld Date: Wed, 22 Dec 2010 16:56:44 +0100 Subject: [PATCH] quartz: introduce GdkQuartzWindow (as a subclass of GdkWindow) --- gdk/quartz/gdkwindow-quartz.c | 31 +++++++++++++++++++++++++++++++ gdk/quartz/gdkwindow-quartz.h | 13 +++++++++++++ 2 files changed, 44 insertions(+) diff --git a/gdk/quartz/gdkwindow-quartz.c b/gdk/quartz/gdkwindow-quartz.c index 6b85ef5d65..a4c84cd28e 100644 --- a/gdk/quartz/gdkwindow-quartz.c +++ b/gdk/quartz/gdkwindow-quartz.c @@ -63,6 +63,37 @@ static FullscreenSavedGeometry *get_fullscreen_geometry (GdkWindow *window); GDK_WINDOW_TYPE (window) != GDK_WINDOW_FOREIGN && \ GDK_WINDOW_TYPE (window) != GDK_WINDOW_OFFSCREEN) +/* + * GdkQuartzWindow + */ + +struct _GdkQuartzWindow +{ + GdkWindow parent; +}; + +struct _GdkQuartzWindowClass +{ + GdkWindowClass parent_class; +}; + +G_DEFINE_TYPE (GdkQuartzWindow, gdk_quartz_window, GDK_TYPE_WINDOW); + +static void +gdk_quartz_window_class_init (GdkQuartzWindowClass *quartz_window_class) +{ +} + +static void +gdk_quartz_window_init (GdkQuartzWindow *quartz_window) +{ +} + + +/* + * GdkQuartzWindowImpl + */ + NSView * gdk_quartz_window_get_nsview (GdkWindow *window) { diff --git a/gdk/quartz/gdkwindow-quartz.h b/gdk/quartz/gdkwindow-quartz.h index f55bbb33e9..0987b7ea06 100644 --- a/gdk/quartz/gdkwindow-quartz.h +++ b/gdk/quartz/gdkwindow-quartz.h @@ -27,6 +27,19 @@ G_BEGIN_DECLS +#define GDK_TYPE_QUARTZ_WINDOW (gdk_quartz_window_get_type ()) +#define GDK_QUARTZ_WINDOW(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GDK_TYPE_QUARTZ_WINDOW, GdkQuartzWindow)) +#define GDK_QUARTZ_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDK_TYPE_QUARTZ_WINDOW, GdkQuartzWindowClass)) +#define GDK_IS_QUARTZ_WINDOW(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GDK_TYPE_QUARTZ_WINDOW)) +#define GDK_IS_QUARTZ_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GDK_TYPE_QUARTZ_WINDOW)) +#define GDK_QUARTZ_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GDK_TYPE_QUARTZ_WINDOW, GdkQuartzWindowClass)) + +typedef struct _GdkQuartzWindow GdkQuartzWindow; +typedef struct _GdkQuartzWindowClass GdkQuartzWindowClass; + +GType gdk_quartz_window_get_type (void); + + /* Window implementation for Quartz */