mirror of
https://github.com/brl/mutter.git
synced 2024-11-25 01:20:42 -05:00
Since Patrick Niklaus's checkin of 2008-08-14 dealt with windows with no
2008-10-15 Thomas Thurman <tthurman@gnome.org> Since Patrick Niklaus's checkin of 2008-08-14 dealt with windows with no icons not using fallback icons, we don't need fallback icons. * src/ui/theme.h: remove fallback icons from struct. * src/core/iconcache.c (meta_read_icons): don't look for fallbacks. * src/*/ui.[ch] (meta_ui_get_fallback_icons): removed * src/ui/theme-parser.c (typedef, parse_toplevel_element): don't parse fallback specifications. svn path=/trunk/; revision=3958
This commit is contained in:
parent
b1b8d51264
commit
7d67a9aee9
11
ChangeLog
11
ChangeLog
@ -1,3 +1,14 @@
|
||||
2008-10-15 Thomas Thurman <tthurman@gnome.org>
|
||||
|
||||
Since Patrick Niklaus's checkin of 2008-08-14 dealt with windows with
|
||||
no icons not using fallback icons, we don't need fallback icons.
|
||||
|
||||
* src/ui/theme.h: remove fallback icons from struct.
|
||||
* src/core/iconcache.c (meta_read_icons): don't look for fallbacks.
|
||||
* src/*/ui.[ch] (meta_ui_get_fallback_icons): removed
|
||||
* src/ui/theme-parser.c (typedef, parse_toplevel_element): don't
|
||||
parse fallback specifications.
|
||||
|
||||
2008-10-13 Thomas Thurman <tthurman@gnome.org>
|
||||
|
||||
* po/POTFILES.in: add screen-bindings.h
|
||||
|
@ -816,16 +816,6 @@ meta_read_icons (MetaScreen *screen,
|
||||
|
||||
if (icon_cache->want_fallback &&
|
||||
icon_cache->origin < USING_FALLBACK_ICON)
|
||||
{
|
||||
GdkPixbuf *fallback_icon;
|
||||
GdkPixbuf *fallback_mini_icon;
|
||||
|
||||
fallback_icon = NULL;
|
||||
fallback_mini_icon = NULL;
|
||||
|
||||
meta_ui_get_fallback_icons(&fallback_icon, &fallback_mini_icon);
|
||||
|
||||
if (fallback_icon == NULL || fallback_mini_icon == NULL)
|
||||
{
|
||||
get_fallback_icons (screen,
|
||||
iconp,
|
||||
@ -834,12 +824,6 @@ meta_read_icons (MetaScreen *screen,
|
||||
mini_iconp,
|
||||
ideal_mini_width,
|
||||
ideal_mini_height);
|
||||
}
|
||||
|
||||
if (fallback_icon != NULL)
|
||||
*iconp = fallback_icon;
|
||||
if (fallback_mini_icon != NULL)
|
||||
*mini_iconp = fallback_mini_icon;
|
||||
|
||||
replace_cache (icon_cache, USING_FALLBACK_ICON,
|
||||
*iconp, *mini_iconp);
|
||||
|
@ -204,9 +204,6 @@ MetaUIDirection meta_ui_get_direction (void);
|
||||
|
||||
GdkPixbuf *meta_ui_get_pixbuf_from_pixmap (Pixmap pmap);
|
||||
|
||||
void meta_ui_get_fallback_icons (GdkPixbuf **fallback_icon_p,
|
||||
GdkPixbuf **fallback_mini_icon_p);
|
||||
|
||||
#include "tabpopup.h"
|
||||
|
||||
#endif
|
||||
|
@ -72,9 +72,8 @@ typedef enum
|
||||
STATE_FRAME,
|
||||
/* assigning style sets to windows */
|
||||
STATE_WINDOW,
|
||||
/* and menu icons */
|
||||
/* things we don't use any more but we can still parse: */
|
||||
STATE_MENU_ICON,
|
||||
/* fallback icons */
|
||||
STATE_FALLBACK
|
||||
} ParseState;
|
||||
|
||||
@ -1218,40 +1217,9 @@ parse_toplevel_element (GMarkupParseContext *context,
|
||||
}
|
||||
else if (ELEMENT_IS ("fallback"))
|
||||
{
|
||||
const char *icon = NULL;
|
||||
const char *mini_icon = NULL;
|
||||
|
||||
if (!locate_attributes (context, element_name, attribute_names, attribute_values,
|
||||
error,
|
||||
"icon", &icon,
|
||||
"mini_icon", &mini_icon,
|
||||
NULL))
|
||||
return;
|
||||
|
||||
if (icon)
|
||||
{
|
||||
if (info->theme->fallback_icon != NULL)
|
||||
{
|
||||
set_error (error, context, G_MARKUP_ERROR, G_MARKUP_ERROR_PARSE,
|
||||
_("Theme already has a fallback icon"));
|
||||
return;
|
||||
}
|
||||
|
||||
info->theme->fallback_icon = meta_theme_load_image(info->theme, icon, 64, error);
|
||||
}
|
||||
|
||||
if (mini_icon)
|
||||
{
|
||||
if (info->theme->fallback_mini_icon != NULL)
|
||||
{
|
||||
set_error (error, context, G_MARKUP_ERROR, G_MARKUP_ERROR_PARSE,
|
||||
_("Theme already has a fallback mini_icon"));
|
||||
return;
|
||||
}
|
||||
|
||||
info->theme->fallback_mini_icon = meta_theme_load_image(info->theme, mini_icon, 16, error);
|
||||
}
|
||||
|
||||
/* Not supported any more, but we have to parse it if they include it,
|
||||
* for backwards compatibility.
|
||||
*/
|
||||
push_state (info, STATE_FALLBACK);
|
||||
}
|
||||
else
|
||||
|
@ -805,8 +805,6 @@ struct _MetaTheme
|
||||
GHashTable *style_sets_by_name;
|
||||
MetaFrameStyleSet *style_sets_by_type[META_FRAME_TYPE_LAST];
|
||||
|
||||
GdkPixbuf *fallback_icon, *fallback_mini_icon;
|
||||
|
||||
GQuark quark_width;
|
||||
GQuark quark_height;
|
||||
GQuark quark_object_width;
|
||||
|
13
src/ui/ui.c
13
src/ui/ui.c
@ -997,16 +997,3 @@ meta_ui_get_pixbuf_from_pixmap (Pixmap pmap)
|
||||
|
||||
return pixbuf;
|
||||
}
|
||||
|
||||
void
|
||||
meta_ui_get_fallback_icons (GdkPixbuf **fallback_icon_p,
|
||||
GdkPixbuf **fallback_mini_icon_p)
|
||||
{
|
||||
MetaTheme *theme = meta_theme_get_current ();
|
||||
|
||||
if (fallback_icon_p)
|
||||
*fallback_icon_p = theme->fallback_icon;
|
||||
|
||||
if (fallback_mini_icon_p)
|
||||
*fallback_mini_icon_p = theme->fallback_mini_icon;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user