[gnome-panel/gtk3] Remove unneeded method free_prepared_resources()
- From: Carlos Garcia Campos <carlosgc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-panel/gtk3] Remove unneeded method free_prepared_resources()
- Date: Mon, 17 Jan 2011 16:45:10 +0000 (UTC)
commit a3a45469ed96d0047fe834bbdf107731ead23459
Author: Carlos Garcia Campos <carlosgc gnome org>
Date: Mon Jan 17 17:43:45 2011 +0100
Remove unneeded method free_prepared_resources()
It breaks the background when it's a solid color without alpha resetting
the color to 0,0,0
gnome-panel/panel-background.c | 28 ++--------------------------
1 files changed, 2 insertions(+), 26 deletions(-)
---
diff --git a/gnome-panel/panel-background.c b/gnome-panel/panel-background.c
index 75c9d34..e5c2244 100644
--- a/gnome-panel/panel-background.c
+++ b/gnome-panel/panel-background.c
@@ -40,26 +40,6 @@ static void load_background_file (PanelBackground *background);
static void
-free_prepared_resources (PanelBackground *background)
-{
- background->prepared = FALSE;
-
- switch (background->type) {
- case PANEL_BACK_NONE:
- break;
- case PANEL_BACK_COLOR:
- if (!background->has_alpha)
- background->color.red = background->color.green = background->color.blue = 0.;
- break;
- case PANEL_BACK_IMAGE:
- break;
- default:
- g_assert_not_reached ();
- break;
- }
-}
-
-static void
set_pixbuf_background (PanelBackground *background)
{
g_assert (background->composited_pattern != NULL);
@@ -76,8 +56,6 @@ panel_background_prepare (PanelBackground *background)
if (!background->transformed)
return FALSE;
- free_prepared_resources (background);
-
effective_type = panel_background_effective_type (background);
switch (effective_type) {
@@ -127,8 +105,7 @@ panel_background_prepare (PanelBackground *background)
static void
free_composited_resources (PanelBackground *background)
{
- free_prepared_resources (background);
-
+ background->prepared = FALSE;
background->composited = FALSE;
if (background->composited_pattern)
@@ -754,8 +731,7 @@ panel_background_realized (PanelBackground *background,
void
panel_background_unrealized (PanelBackground *background)
{
- free_prepared_resources (background);
-
+ background->prepared = FALSE;
if (background->window)
g_object_unref (background->window);
background->window = NULL;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]