[mutter] core: Remove useless meta_invalidate_default_icons implementation
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] core: Remove useless meta_invalidate_default_icons implementation
- Date: Mon, 14 Jul 2014 16:16:04 +0000 (UTC)
commit df9a5f867f522c77a90c1bcc448e8aca5d2edb99
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Mon Jul 14 11:59:42 2014 -0400
core: Remove useless meta_invalidate_default_icons implementation
This code was supposed to refresh our default icons when the theme
changed, but it actually was a no-op, since the default icons are cached
in a static variable in MetaUI.
I'm not sure the fact that the fallback icons don't update when the
theme changes is an important enough use case to keep working, but I'm
keeping the skeleton function there in case somebody wants to actually
fix it properly.
src/core/core.c | 21 +--------------------
src/core/window-private.h | 2 --
src/core/window.c | 3 ++-
3 files changed, 3 insertions(+), 23 deletions(-)
---
diff --git a/src/core/core.c b/src/core/core.c
index cbb006a..e603af8 100644
--- a/src/core/core.c
+++ b/src/core/core.c
@@ -495,24 +495,5 @@ meta_core_set_screen_cursor (Display *xdisplay,
void
meta_invalidate_default_icons (void)
{
- MetaDisplay *display = meta_get_display ();
- GSList *windows;
- GSList *l;
-
- if (display == NULL)
- return; /* We can validly be called before the display is opened. */
-
- windows = meta_display_list_windows (display, META_LIST_DEFAULT);
- for (l = windows; l != NULL; l = l->next)
- {
- MetaWindow *window = (MetaWindow*)l->data;
-
- if (window->icon_cache.origin == USING_FALLBACK_ICON)
- {
- meta_icon_cache_free (&(window->icon_cache));
- meta_window_update_icon_now (window);
- }
- }
-
- g_slist_free (windows);
+ /* XXX: Actually invalidate the icons when they're used. */
}
diff --git a/src/core/window-private.h b/src/core/window-private.h
index ddc0a75..70ebb30 100644
--- a/src/core/window-private.h
+++ b/src/core/window-private.h
@@ -632,8 +632,6 @@ void meta_window_stack_just_below (MetaWindow *window,
void meta_window_set_user_time (MetaWindow *window,
guint32 timestamp);
-void meta_window_update_icon_now (MetaWindow *window);
-
void meta_window_update_for_monitors_changed (MetaWindow *window);
void meta_window_update_on_all_workspaces (MetaWindow *window);
diff --git a/src/core/window.c b/src/core/window.c
index 0cffc9f..6395f40 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -117,6 +117,7 @@ static void unminimize_window_and_all_transient_parents (MetaWindow *window);
static void meta_window_propagate_focus_appearance (MetaWindow *window,
gboolean focused);
+static void meta_window_update_icon_now (MetaWindow *window);
/* Idle handlers for the three queues (run with meta_later_add()). The
* "data" parameter in each case will be a GINT_TO_POINTER of the
@@ -4822,7 +4823,7 @@ redraw_icon (MetaWindow *window)
meta_ui_queue_frame_draw (window->screen->ui, window->frame->xwindow);
}
-void
+static void
meta_window_update_icon_now (MetaWindow *window)
{
GdkPixbuf *icon;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]