From c9c3f858e28edf0856a263941007401923adbabd Mon Sep 17 00:00:00 2001 From: "Owen W. Taylor" Date: Sat, 27 Sep 2014 17:06:36 +0300 Subject: Add frame type for attached modal dialogs Add a new frame type META_FRAME_TYPE_ATTACHED which is used for attached modal dialogs. The theme format version is bumped to 3.2, and attached windows can have borders defined in a metacity-theme-3.xml as: If no style is defined for "attached", drawing will fall back to the "border" type. https://bugzilla.gnome.org/show_bug.cgi?id=592382 NOTE: Patch copied from mutter and adapted for metacity. --- src/ui/theme-parser.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/ui/theme-parser.c') diff --git a/src/ui/theme-parser.c b/src/ui/theme-parser.c index 38c1e664..e3c044f9 100644 --- a/src/ui/theme-parser.c +++ b/src/ui/theme-parser.c @@ -38,7 +38,7 @@ * look out for. */ #define THEME_MAJOR_VERSION 3 -#define THEME_MINOR_VERSION 1 +#define THEME_MINOR_VERSION 2 #define THEME_VERSION (1000 * THEME_MAJOR_VERSION + THEME_MINOR_VERSION) #define MARCO_THEME_FILENAME_FORMAT "metacity-theme-%d.xml" @@ -1277,7 +1277,8 @@ parse_toplevel_element (GMarkupParseContext *context, type = meta_frame_type_from_string (type_name); - if (type == META_FRAME_TYPE_LAST) + if (type == META_FRAME_TYPE_LAST || + (type == META_FRAME_TYPE_ATTACHED && peek_required_version (info) < 3002)) { set_error (error, context, G_MARKUP_ERROR, G_MARKUP_ERROR_PARSE, _("Unknown type \"%s\" on <%s> element"), -- cgit v1.2.1