diff options
author | Matthias Clasen <mclasen@redhat.com> | 2020-03-09 12:03:48 -0700 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2020-03-12 15:30:11 -0400 |
commit | 641c8f325239a075b41c00d436ab8cb8f1b26531 (patch) | |
tree | 644994289a0d8859d39d1a638677d5d83c98d0c5 | |
parent | f020d77a23e3f55ed960843a9bfbdf1fec06a501 (diff) | |
download | gtk+-641c8f325239a075b41c00d436ab8cb8f1b26531.tar.gz |
Drop mwm hints from api
The GdkWMDecoration and GdkWMFunction enums
are no longer used in the api, so move them
to the x11 backend where they are used.
-rw-r--r-- | gdk/gdksurface.h | 53 | ||||
-rw-r--r-- | gdk/x11/gdksurface-x11.c | 21 |
2 files changed, 21 insertions, 53 deletions
diff --git a/gdk/gdksurface.h b/gdk/gdksurface.h index 7a43059c78..cd11aa368f 100644 --- a/gdk/gdksurface.h +++ b/gdk/gdksurface.h @@ -76,59 +76,6 @@ typedef enum GDK_HINT_USER_SIZE = 1 << 8 } GdkSurfaceHints; -/* The next two enumeration values current match the - * Motif constants. If this is changed, the implementation - * of gdk_surface_set_decorations/gdk_surface_set_functions - * will need to change as well. - */ -/** - * GdkWMDecoration: - * @GDK_DECOR_ALL: all decorations should be applied. - * @GDK_DECOR_BORDER: a frame should be drawn around the surface. - * @GDK_DECOR_RESIZEH: the frame should have resize handles. - * @GDK_DECOR_TITLE: a titlebar should be placed above the surface. - * @GDK_DECOR_MENU: a button for opening a menu should be included. - * @GDK_DECOR_MINIMIZE: a minimize button should be included. - * @GDK_DECOR_MAXIMIZE: a maximize button should be included. - * - * These are hints originally defined by the Motif toolkit. - * The window manager can use them when determining how to decorate - * the surface. The hint must be set before mapping the surface. - */ -typedef enum -{ - GDK_DECOR_ALL = 1 << 0, - GDK_DECOR_BORDER = 1 << 1, - GDK_DECOR_RESIZEH = 1 << 2, - GDK_DECOR_TITLE = 1 << 3, - GDK_DECOR_MENU = 1 << 4, - GDK_DECOR_MINIMIZE = 1 << 5, - GDK_DECOR_MAXIMIZE = 1 << 6 -} GdkWMDecoration; - -/** - * GdkWMFunction: - * @GDK_FUNC_ALL: all functions should be offered. - * @GDK_FUNC_RESIZE: the surface should be resizable. - * @GDK_FUNC_MOVE: the surface should be movable. - * @GDK_FUNC_MINIMIZE: the surface should be minimizable. - * @GDK_FUNC_MAXIMIZE: the surface should be maximizable. - * @GDK_FUNC_CLOSE: the surface should be closable. - * - * These are hints originally defined by the Motif toolkit. The window manager - * can use them when determining the functions to offer for the surface. The - * hint must be set before mapping the surface. - */ -typedef enum -{ - GDK_FUNC_ALL = 1 << 0, - GDK_FUNC_RESIZE = 1 << 1, - GDK_FUNC_MOVE = 1 << 2, - GDK_FUNC_MINIMIZE = 1 << 3, - GDK_FUNC_MAXIMIZE = 1 << 4, - GDK_FUNC_CLOSE = 1 << 5 -} GdkWMFunction; - /** * GdkSurfaceEdge: * @GDK_SURFACE_EDGE_NORTH_WEST: the top left corner. diff --git a/gdk/x11/gdksurface-x11.c b/gdk/x11/gdksurface-x11.c index f67573ee6b..1be2f82acc 100644 --- a/gdk/x11/gdksurface-x11.c +++ b/gdk/x11/gdksurface-x11.c @@ -3496,6 +3496,17 @@ gdk_surface_set_mwm_hints (GdkSurface *surface, XFree (hints); } +typedef enum +{ + GDK_DECOR_ALL = 1 << 0, + GDK_DECOR_BORDER = 1 << 1, + GDK_DECOR_RESIZEH = 1 << 2, + GDK_DECOR_TITLE = 1 << 3, + GDK_DECOR_MENU = 1 << 4, + GDK_DECOR_MINIMIZE = 1 << 5, + GDK_DECOR_MAXIMIZE = 1 << 6 +} GdkWMDecoration; + static void gdk_x11_surface_set_decorations (GdkSurface *surface, GdkWMDecoration decorations) @@ -3540,6 +3551,16 @@ gdk_x11_surface_get_decorations(GdkSurface *surface, return result; } +typedef enum +{ + GDK_FUNC_ALL = 1 << 0, + GDK_FUNC_RESIZE = 1 << 1, + GDK_FUNC_MOVE = 1 << 2, + GDK_FUNC_MINIMIZE = 1 << 3, + GDK_FUNC_MAXIMIZE = 1 << 4, + GDK_FUNC_CLOSE = 1 << 5 +} GdkWMFunction; + static void gdk_x11_surface_set_functions (GdkSurface *surface, GdkWMFunction functions) |