aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorClaudio Saavedra <csaavedra@igalia.com>2012-09-04 03:32:04 +0800
committerClaudio Saavedra <csaavedra@igalia.com>2012-09-04 03:54:45 +0800
commit51864e36d205e10752753605ca0592f39f000606 (patch)
treedb92d913dfb355f98241e69adab25e8adff49530
parentdeb576b24db205cf13651c5ab04b9b3696fbfb99 (diff)
downloadgsoc2013-epiphany-51864e36d205e10752753605ca0592f39f000606.tar.gz
gsoc2013-epiphany-51864e36d205e10752753605ca0592f39f000606.tar.zst
gsoc2013-epiphany-51864e36d205e10752753605ca0592f39f000606.zip
ephy-removable-pixbuf-renderer: do not emit delete on click if policy is NEVER
It makes no sense to emit the delete signal if the delete button is not rendered at all.
-rw-r--r--lib/widgets/ephy-removable-pixbuf-renderer.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/widgets/ephy-removable-pixbuf-renderer.c b/lib/widgets/ephy-removable-pixbuf-renderer.c
index 8c113a0df..c0199ebb7 100644
--- a/lib/widgets/ephy-removable-pixbuf-renderer.c
+++ b/lib/widgets/ephy-removable-pixbuf-renderer.c
@@ -119,6 +119,9 @@ ephy_removable_pixbuf_renderer_activate (GtkCellRenderer *cell,
GdkEventButton *ev = (GdkEventButton *) gtk_get_current_event();
EphyRemovablePixbufRendererPrivate *priv = EPHY_REMOVABLE_PIXBUF_RENDERER (cell)->priv;
+ if (priv->policy == EPHY_REMOVABLE_PIXBUF_RENDER_NEVER)
+ return FALSE;
+
get_icon_rectangle (widget, cell, cell_area, priv->close_icon, &icon_area);
if (icon_area.x <= ev->x && ev->x <= icon_area.x + icon_area.width &&
icon_area.y <= ev->y && ev->y <= icon_area.y + icon_area.height) {