[epiphany/wip/bookmarks: 12/17] bookmarks-popover: Fix tooltip positioning



commit ea6427723412c60de7fd110dabe32ef2fbd40bd2
Author: Iulian Radu <iulian radu67 gmail com>
Date:   Mon Aug 22 19:50:06 2016 +0300

    bookmarks-popover: Fix tooltip positioning

 src/ephy-toolbar.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/ephy-toolbar.c b/src/ephy-toolbar.c
index 12bea4f..5ec4332 100644
--- a/src/ephy-toolbar.c
+++ b/src/ephy-toolbar.c
@@ -640,6 +640,12 @@ add_bookmark_button_clicked_cb (EphyLocationEntry *entry,
   gtk_entry_get_icon_area (GTK_ENTRY (entry),
                            GTK_ENTRY_ICON_SECONDARY,
                            &rectangle);
+
+  /* FIXME: GTK+ sets "margin-left: 6px" for the icon. Add 3px to the
+   * rectangle so the popover is centered on the star.
+   */
+  rectangle.x = rectangle.x + 3;
+
   gtk_popover_set_pointing_to (GTK_POPOVER (popover), &rectangle);
   grid = ephy_bookmark_properties_grid_new (bookmark,
                                             EPHY_BOOKMARK_PROPERTIES_GRID_TYPE_POPOVER,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]