diff options
author | Owen W. Taylor <[email protected]> | 2014-09-27 17:06:36 +0300 |
---|---|---|
committer | Victor Kareh <[email protected]> | 2018-08-28 09:38:37 -0400 |
commit | c9c3f858e28edf0856a263941007401923adbabd (patch) | |
tree | 702b2c5d7a41d8ea9b72ef5d2c11ad8116bab136 /src/ui/theme-parser.c | |
parent | 37fecf49392eb10ada1f4bf481d6ad6be56891dd (diff) | |
download | marco-c9c3f858e28edf0856a263941007401923adbabd.tar.bz2 marco-c9c3f858e28edf0856a263941007401923adbabd.tar.xz |
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:
<window version=">= 3.2" type="attached" style_set="[name]"/>
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.
Diffstat (limited to 'src/ui/theme-parser.c')
-rw-r--r-- | src/ui/theme-parser.c | 5 |
1 files changed, 3 insertions, 2 deletions
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"), |