Commit fb6e939d authored by Ramiro Estrugo's avatar Ramiro Estrugo Committed by Ramiro Estrugo
Browse files

Update these items to properly use the canvas pixbuf beast.

2000-06-30  Ramiro Estrugo  <ramiro@eazel.com>

* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-edge.c:
(nautilus_druid_page_edge_construct):
* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-finish.c:
(nautilus_druid_page_finish_configure_size),
(nautilus_druid_page_finish_construct),
(nautilus_druid_page_finish_set_logo),
(nautilus_druid_page_finish_set_watermark):
* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-standard.c:
(nautilus_druid_page_standard_construct):
* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-start.c:
(nautilus_druid_page_start_construct):
Update these items to properly use the canvas pixbuf beast.
parent 735131f1
2000-06-30 Ramiro Estrugo <ramiro@eazel.com>
* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-edge.c:
(nautilus_druid_page_edge_construct):
* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-finish.c:
(nautilus_druid_page_finish_configure_size),
(nautilus_druid_page_finish_construct),
(nautilus_druid_page_finish_set_logo),
(nautilus_druid_page_finish_set_watermark):
* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-standard.c:
(nautilus_druid_page_standard_construct):
* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-start.c:
(nautilus_druid_page_start_construct):
Update these items to properly use the canvas pixbuf beast.
2000-06-30 Ramiro Estrugo <ramiro@eazel.com>
* cut-n-paste-code/widgets/nautilus-druid/nautilus-druid-page-edge.c:
......
......@@ -239,7 +239,7 @@ nautilus_druid_page_edge_construct (NautilusDruidPageEdge *druid_page_edge)
druid_page_edge->_priv->logo_item =
gnome_canvas_item_new (gnome_canvas_root (GNOME_CANVAS (druid_page_edge->_priv->canvas)),
gnome_canvas_pixbuf_get_type (),
"x_set", TRUE, "y_set", TRUE,
"x_in_pixels", TRUE, "y_in_pixels", TRUE,
NULL);
if (druid_page_edge->logo_image != NULL)
......@@ -249,7 +249,7 @@ nautilus_druid_page_edge_construct (NautilusDruidPageEdge *druid_page_edge)
druid_page_edge->_priv->watermark_item =
gnome_canvas_item_new (gnome_canvas_root (GNOME_CANVAS (druid_page_edge->_priv->canvas)),
gnome_canvas_pixbuf_get_type (),
"x_set", TRUE, "y_set", TRUE,
"x_in_pixels", TRUE, "y_in_pixels", TRUE,
NULL);
if (druid_page_edge->watermark_image != NULL)
......
......@@ -184,13 +184,11 @@ nautilus_druid_page_finish_configure_size (NautilusDruidPageFinish *druid_page_f
gnome_canvas_item_set (druid_page_finish->_priv->logo_item,
"x", (gfloat) width - GNOME_PAD - LOGO_WIDTH,
"y", (gfloat) GNOME_PAD,
"anchor", GTK_ANCHOR_NORTH_WEST,
"width", (gfloat) LOGO_WIDTH,
"height", (gfloat) LOGO_WIDTH, NULL);
gnome_canvas_item_set (druid_page_finish->_priv->watermark_item,
"x", 0.0,
"y", watermark_ypos,
"anchor", GTK_ANCHOR_NORTH_WEST,
"width", watermark_width,
"height", watermark_height,
NULL);
......@@ -221,14 +219,24 @@ nautilus_druid_page_finish_construct (NautilusDruidPageFinish *druid_page_finish
gnome_canvas_rect_get_type (), NULL);
druid_page_finish->_priv->logo_item =
gnome_canvas_item_new (gnome_canvas_root (GNOME_CANVAS (druid_page_finish->_priv->canvas)),
gnome_canvas_image_get_type (), NULL);
gnome_canvas_pixbuf_get_type (),
"x_in_pixels", TRUE, "y_in_pixels", TRUE,
NULL);
if (druid_page_finish->logo_image != NULL)
gnome_canvas_item_set (druid_page_finish->_priv->logo_item,
"image", druid_page_finish->logo_image, NULL);
"pixbuf", druid_page_finish->logo_image, NULL);
druid_page_finish->_priv->watermark_item =
gnome_canvas_item_new (gnome_canvas_root (GNOME_CANVAS (druid_page_finish->_priv->canvas)),
gnome_canvas_image_get_type (),
"image", druid_page_finish->watermark_image, NULL);
gnome_canvas_pixbuf_get_type (),
"x_in_pixels", TRUE, "y_in_pixels", TRUE,
NULL);
if (druid_page_finish->watermark_image != NULL)
gnome_canvas_item_set (druid_page_finish->_priv->watermark_item,
"pixbuf", druid_page_finish->watermark_image, NULL);
druid_page_finish->_priv->title_item =
gnome_canvas_item_new (gnome_canvas_root (GNOME_CANVAS (druid_page_finish->_priv->canvas)),
gnome_canvas_text_get_type (),
......@@ -486,9 +494,13 @@ nautilus_druid_page_finish_set_logo (NautilusDruidPageFinish *druid_pag
g_return_if_fail (druid_page_finish != NULL);
g_return_if_fail (NAUTILUS_IS_DRUID_PAGE_FINISH (druid_page_finish));
if (druid_page_finish->logo_image)
gdk_pixbuf_unref (druid_page_finish->logo_image);
druid_page_finish->logo_image = logo_image;
gdk_pixbuf_ref (logo_image);
gnome_canvas_item_set (druid_page_finish->_priv->logo_item,
"image", druid_page_finish->logo_image, NULL);
"pixbuf", druid_page_finish->logo_image, NULL);
}
void
nautilus_druid_page_finish_set_watermark (NautilusDruidPageFinish *druid_page_finish,
......@@ -497,7 +509,11 @@ nautilus_druid_page_finish_set_watermark (NautilusDruidPageFinish *druid_pag
g_return_if_fail (druid_page_finish != NULL);
g_return_if_fail (NAUTILUS_IS_DRUID_PAGE_FINISH (druid_page_finish));
if (druid_page_finish->watermark_image)
gdk_pixbuf_unref (druid_page_finish->watermark_image);
druid_page_finish->watermark_image = watermark;
gdk_pixbuf_ref (watermark);
gnome_canvas_item_set (druid_page_finish->_priv->watermark_item,
"image", druid_page_finish->watermark_image, NULL);
"pixbuf", druid_page_finish->watermark_image, NULL);
}
......@@ -225,7 +225,7 @@ nautilus_druid_page_standard_construct (NautilusDruidPageStandard *druid_page_st
druid_page_standard->_priv->logo_item =
gnome_canvas_item_new (gnome_canvas_root (GNOME_CANVAS (druid_page_standard->_priv->canvas)),
gnome_canvas_pixbuf_get_type (),
"x_set", TRUE, "y_set", TRUE,
"x_in_pixels", TRUE, "y_in_pixels", TRUE,
NULL);
if (druid_page_standard->logo_image != NULL) {
......
......@@ -236,7 +236,7 @@ nautilus_druid_page_start_construct (NautilusDruidPageStart *druid_page_start)
druid_page_start->_priv->logo_item =
gnome_canvas_item_new (gnome_canvas_root (GNOME_CANVAS (druid_page_start->_priv->canvas)),
gnome_canvas_pixbuf_get_type (),
"x_set", TRUE, "y_set", TRUE,
"x_in_pixels", TRUE, "y_in_pixels", TRUE,
NULL);
if (druid_page_start->logo_image != NULL)
......@@ -246,7 +246,7 @@ nautilus_druid_page_start_construct (NautilusDruidPageStart *druid_page_start)
druid_page_start->_priv->watermark_item =
gnome_canvas_item_new (gnome_canvas_root (GNOME_CANVAS (druid_page_start->_priv->canvas)),
gnome_canvas_pixbuf_get_type (),
"x_set", TRUE, "y_set", TRUE,
"x_in_pixels", TRUE, "y_in_pixels", TRUE,
NULL);
if (druid_page_start->watermark_image != NULL)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment