After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 685747 - Show URI in the statusbar on snapshot hover
Show URI in the statusbar on snapshot hover
Status: RESOLVED FIXED
Product: epiphany
Classification: Core
Component: Overview
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Epiphany Maintainers
Epiphany Maintainers
Depends on:
Blocks:
 
 
Reported: 2012-10-08 20:00 UTC by Xan Lopez
Modified: 2014-03-06 09:05 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
e-overview: add a statusbar for hovered icons (3.81 KB, patch)
2012-12-09 15:28 UTC, Diego Escalante Urrelo (not reading bugmail)
none Details | Review
EphyOverview not expanding, why oh why? (83.55 KB, image/png)
2012-12-09 15:39 UTC, Diego Escalante Urrelo (not reading bugmail)
  Details
e-embed: use an overlay for the overview (2.11 KB, patch)
2012-12-09 17:59 UTC, Diego Escalante Urrelo (not reading bugmail)
none Details | Review
e-embed: only add one statusbar timeout at a time (1.10 KB, patch)
2012-12-09 18:00 UTC, Diego Escalante Urrelo (not reading bugmail)
committed Details | Review
e-overview: add a statusbar for hovered icons (2.34 KB, patch)
2012-12-09 18:04 UTC, Diego Escalante Urrelo (not reading bugmail)
none Details | Review
wrong bg color when GtkOverlay is set to OSD (86.23 KB, image/png)
2012-12-09 18:50 UTC, Diego Escalante Urrelo (not reading bugmail)
  Details
e-overview: add a statusbar for hovered icons (3.32 KB, patch)
2012-12-09 20:09 UTC, Diego Escalante Urrelo (not reading bugmail)
reviewed Details | Review
e-embed: hide progress for about and ephy-about (835 bytes, patch)
2012-12-09 20:10 UTC, Diego Escalante Urrelo (not reading bugmail)
reviewed Details | Review
e-embed: use an overlay for the overview (2.02 KB, patch)
2012-12-10 10:56 UTC, Diego Escalante Urrelo (not reading bugmail)
accepted-commit_now Details | Review
difference in borders (4.11 KB, image/png)
2012-12-10 16:55 UTC, Diego Escalante Urrelo (not reading bugmail)
  Details
e-overview: add a statusbar for hovered icons (3.30 KB, patch)
2012-12-11 14:01 UTC, Diego Escalante Urrelo (not reading bugmail)
none Details | Review
e-overview: add a statusbar for hovered icons (3.38 KB, patch)
2012-12-11 14:10 UTC, Diego Escalante Urrelo (not reading bugmail)
reviewed Details | Review
e-embed: use an overlay for the overview (3.06 KB, patch)
2012-12-11 17:38 UTC, Diego Escalante Urrelo (not reading bugmail)
committed Details | Review
e-embed: hide progress for about and ephy-about (903 bytes, patch)
2012-12-11 17:38 UTC, Diego Escalante Urrelo (not reading bugmail)
committed Details | Review
e-overview: add a statusbar for hovered icons (2.40 KB, patch)
2012-12-11 17:39 UTC, Diego Escalante Urrelo (not reading bugmail)
rejected Details | Review
e-overview: add a statusbar for hovered icons (7.21 KB, patch)
2012-12-12 15:44 UTC, Diego Escalante Urrelo (not reading bugmail)
reviewed Details | Review
e-overview: add a statusbar for hovered icons (6.50 KB, patch)
2012-12-12 17:01 UTC, Diego Escalante Urrelo (not reading bugmail)
none Details | Review
e-overview: add a statusbar for hovered icons (6.82 KB, patch)
2012-12-12 18:02 UTC, Diego Escalante Urrelo (not reading bugmail)
accepted-commit_now Details | Review
e-overview: add a statusbar for hovered icons (6.86 KB, patch)
2012-12-19 18:40 UTC, Diego Escalante Urrelo (not reading bugmail)
needs-work Details | Review

Description Xan Lopez 2012-10-08 20:00:17 UTC
Like we do in links. I think it makes sense, and I kind of miss it.
Comment 1 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 14:23:06 UTC
Giving this a shot.
Comment 2 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 15:28:42 UTC
Created attachment 231078 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.
=

I need a hand with getting the overlay widget to expand vertically and
horizontally. If you apply the patch and hover you'll see that the
overlay widget is not expanding, therefor the bar looks ugly :(
Comment 3 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 15:39:04 UTC
Created attachment 231079 [details]
EphyOverview not expanding, why oh why?
Comment 4 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 17:59:24 UTC
Created attachment 231083 [details] [review]
e-embed: use an overlay for the overview

-

Needed to get the following simple(r) solution: instead of adding
another overlay and floating bar we reuse the one in EphyEmbed.
Comment 5 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 18:00:34 UTC
Created attachment 231084 [details] [review]
e-embed: only add one statusbar timeout at a time

Otherwise the statusbar can disappear even if it has a valid message
being displayed.

--

Bug in e-embed. The statusbar code was able to install more than one
timeout at a time, turning useless the safeguard of removing it when
adding a valuable message that we don't want to suddenly disappear.
Comment 6 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 18:04:06 UTC
Created attachment 231085 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.

--

This should be ok. Works as expected: you get the statusbar on the
bottom of the window everytime you hover a thumbnail.

The same NautilusFloatingBar from EphyEmbed is reused via
ephy_web_view_set_link_message().

I need help fixing the theming! Because of the GTK_STYLE_CLASS_OSD added
to the GtkOverlay in EphyEmbed, the background of EphyOverview is a
shade of grey. I am pretty sure our theming experts can fix this in a
second :-). Help me!
Comment 7 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 18:50:02 UTC
Created attachment 231088 [details]
wrong bg color when GtkOverlay is set to OSD

This is the theming issue I am seeing with a fresh jhbuild.
Comment 8 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 20:09:51 UTC
Created attachment 231097 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.
--

Cosimo pushed a theme fix that has no issue with this updated patch.
Comment 9 Diego Escalante Urrelo (not reading bugmail) 2012-12-09 20:10:14 UTC
Created attachment 231099 [details] [review]
e-embed: hide progress for about and ephy-about

--
Prevent the progress bar from popping in the overview and other places.
Comment 10 Diego Escalante Urrelo (not reading bugmail) 2012-12-10 10:56:02 UTC
Created attachment 231137 [details] [review]
e-embed: use an overlay for the overview

--

Update to correctly bind the properties. Fixes visibility in webapp
mode.
Comment 11 Diego Escalante Urrelo (not reading bugmail) 2012-12-10 16:55:20 UTC
Created attachment 231165 [details]
difference in borders
Comment 12 Claudio Saavedra 2012-12-11 12:33:55 UTC
Review of attachment 231097 [details] [review]:

::: embed/ephy-overview.c
@@ +103,3 @@
+                          -1);
+
+      if (url && (g_strcmp0 (current, url) != 0 || current == NULL))

Something here feels redundant. If url is not NULL and current and url are the same, then current can't be NULL, right?
Comment 13 Claudio Saavedra 2012-12-11 12:35:04 UTC
Review of attachment 231084 [details] [review]:

Seems to make sense.
Comment 14 Diego Escalante Urrelo (not reading bugmail) 2012-12-11 14:00:19 UTC
(In reply to comment #12)
> Review of attachment 231097 [details] [review]:
> 
> ::: embed/ephy-overview.c
> @@ +103,3 @@
> +                          -1);
> +
> +      if (url && (g_strcmp0 (current, url) != 0 || current == NULL))
> 
> Something here feels redundant. If url is not NULL and current and url are the
> same, then current can't be NULL, right?

Yes, you are right. Updating.
Comment 15 Diego Escalante Urrelo (not reading bugmail) 2012-12-11 14:01:49 UTC
Created attachment 231259 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.
--

Updated for the redundancy issue in if().
Comment 16 Diego Escalante Urrelo (not reading bugmail) 2012-12-11 14:10:10 UTC
Created attachment 231260 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.

--

Due to recent changes an include for ephy-embed was missing.
Claudio's comment is addressed.
Comment 17 Claudio Saavedra 2012-12-11 16:55:10 UTC
Review of attachment 231099 [details] [review]:

::: embed/ephy-embed.c
@@ +817,1 @@
     return;

What has this to do with this bug?
Comment 18 Claudio Saavedra 2012-12-11 16:57:54 UTC
Review of attachment 231137 [details] [review]:

Looks good.
Comment 19 Diego Escalante Urrelo (not reading bugmail) 2012-12-11 16:58:53 UTC
(In reply to comment #17)
> Review of attachment 231099 [details] [review]:
> 
> ::: embed/ephy-embed.c
> @@ +817,1 @@
>      return;
> 
> What has this to do with this bug?

Because the EphyWebView is now not hidden when the overview widget is visible, you can see the load progress of the overview which looks weird because it's a flash like it was for blank pages.
Comment 20 Claudio Saavedra 2012-12-11 17:04:59 UTC
Review of attachment 231260 [details] [review]:

Looks good.

::: embed/ephy-embed.c
@@ +928,1 @@
   gtk_overlay_add_overlay (GTK_OVERLAY (overlay), priv->progress);

Explain to me why is necessary. Better, explain it in the commit message :)
Comment 21 Claudio Saavedra 2012-12-11 17:05:17 UTC
Review of attachment 231260 [details] [review]:

Looks good.

::: embed/ephy-embed.c
@@ +928,1 @@
   gtk_overlay_add_overlay (GTK_OVERLAY (overlay), priv->progress);

Explain to me why is necessary. Better, explain it in the commit message :)
Comment 22 Claudio Saavedra 2012-12-11 17:05:18 UTC
Review of attachment 231260 [details] [review]:

Looks good.

::: embed/ephy-embed.c
@@ +928,1 @@
   gtk_overlay_add_overlay (GTK_OVERLAY (overlay), priv->progress);

Explain to me why is necessary. Better, explain it in the commit message :)
Comment 23 Diego Escalante Urrelo (not reading bugmail) 2012-12-11 17:38:18 UTC
Created attachment 231291 [details] [review]
e-embed: use an overlay for the overview

Moves the GTK_STYLE_CLASS_OSD from the overlay to the progressbar, to
avoid wrongly theming the EphyOverview.
The class is necessary for theming the progressbar correctly.

This permits reusing elements of EphyEmbed more easily.
Comment 24 Diego Escalante Urrelo (not reading bugmail) 2012-12-11 17:38:51 UTC
Created attachment 231292 [details] [review]
e-embed: hide progress for about and ephy-about

The progressbar should only react to pages, not special locations.
Comment 25 Diego Escalante Urrelo (not reading bugmail) 2012-12-11 17:39:57 UTC
Created attachment 231293 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.
Comment 26 Claudio Saavedra 2012-12-11 17:48:57 UTC
Review of attachment 231292 [details] [review]:

::: embed/ephy-embed.c
@@ +822,1 @@
     return;

okay
Comment 27 Claudio Saavedra 2012-12-11 18:09:04 UTC
Review of attachment 231293 [details] [review]:

::: embed/ephy-overview.c
@@ +89,3 @@
+
+  /* embed → paned → overlay in embed → overview */
+  embed = gtk_widget_get_parent (gtk_widget_get_parent (gtk_widget_get_parent (GTK_WIDGET (overview))));

I think we should find a way to do this without such a hack.

@@ +105,3 @@
+
+      if (url && g_strcmp0 (current, url) != 0)
+

So, I think that this set_link_message() API shouldn't be in ephy_web_view() but wherever the actual tooltip is handled (is it EphyEmbed, no?). Then, both EphyWebView and EphyOverview should have either a signal or a property to advertise it ("someone's hovering on this link and we think someone might be interested in displaying this -- somehow, but it's not my business"). Then EphyEmbed would of course be listening to that signal / property changes and set the link-message.
Comment 28 Claudio Saavedra 2012-12-11 18:11:36 UTC
Review of attachment 231291 [details] [review]:

Okay
Comment 29 Diego Escalante Urrelo (not reading bugmail) 2012-12-11 18:17:14 UTC
(In reply to comment #27)
> Review of attachment 231293 [details] [review]:
> 
> ::: embed/ephy-overview.c
> @@ +89,3 @@
> +
> +  /* embed → paned → overlay in embed → overview */
> +  embed = gtk_widget_get_parent (gtk_widget_get_parent (gtk_widget_get_parent
> (GTK_WIDGET (overview))));
> 
> I think we should find a way to do this without such a hack.
> 
> @@ +105,3 @@
> +
> +      if (url && g_strcmp0 (current, url) != 0)
> +
> 
> So, I think that this set_link_message() API shouldn't be in ephy_web_view()
> but wherever the actual tooltip is handled (is it EphyEmbed, no?). Then, both
> EphyWebView and EphyOverview should have either a signal or a property to
> advertise it ("someone's hovering on this link and we think someone might be
> interested in displaying this -- somehow, but it's not my business"). Then
> EphyEmbed would of course be listening to that signal / property changes and
> set the link-message.

That's the current API actually.

There's EphyWebView::status-message (triggered by setting link-message).
EphyEmbed listens to that and reacts.

EphyOverview could have a ::status-message too and we can make EphyEmbed listen to that.
Comment 30 Claudio Saavedra 2012-12-11 18:39:42 UTC
That sounds much better.
Comment 31 Diego Escalante Urrelo (not reading bugmail) 2012-12-12 15:44:15 UTC
Created attachment 231387 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.

Adds ::status-message to EphyOverview, mimicking EphyWebView's same
property. EphyEmbed listens to both properties and updates its statusbar
when any of those changes.
Comment 32 Claudio Saavedra 2012-12-12 15:51:17 UTC
Review of attachment 231387 [details] [review]:

This is looking much better! Just a couple of comments:

::: embed/ephy-embed.c
@@ +990,3 @@
+  priv->overview_status_handler_id = g_signal_connect (priv->overview, "notify::status-message",
+                                                       G_CALLBACK (status_message_notify_cb),
+                                                       embed);

I'm wondering whether you need to make sure to clean this up when the visibility of the overview is toggled?

::: embed/ephy-overview.c
@@ +124,3 @@
+    if (overview->priv->status_message)
+      g_free (overview->priv->status_message);
+

Here you check for NULL before calling g_free()...

@@ +198,3 @@
+  switch (prop_id) {
+    case PROP_STATUS_MESSAGE:
+    default:

Is this necessary if the property is read-only?

@@ +211,3 @@
+
+  g_free (priv->status_message);
+                            guint prop_id,

..but you don't check here. Do you need to at all? :)
Comment 33 Diego Escalante Urrelo (not reading bugmail) 2012-12-12 17:01:09 UTC
Created attachment 231393 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.

Adds ::status-message to EphyOverview, mimicking EphyWebView's same
property. EphyEmbed listens to both properties and updates its statusbar
when any of those changes.
--

Updated for comments. I don't think we should worry about the motion
callback on the hidden widget. If we discover that the callback is
called even when the widget is hidden, then we can report a GTK+ bug.

Consider bug #690110, which removes ::link-message and makes EphyWebView
correctly report link messages. Without that patch, we would only get
status related messages (Loading gnome.org…)

Thanks for the reviews :).
Comment 34 Diego Escalante Urrelo (not reading bugmail) 2012-12-12 18:02:23 UTC
Created attachment 231401 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.

Adds ::status-message to EphyOverview, mimicking EphyWebView's same
property. EphyEmbed listens to both properties and updates its statusbar
when any of those changes.

---

Addresses your IRC comment.
When going out of the overview_mode, we unset the statusbar message.

What do you think?
Comment 35 Claudio Saavedra 2012-12-14 09:40:02 UTC
Review of attachment 231401 [details] [review]:

Looks good, besides the comment. I think we can push this after you fix that.

::: embed/ephy-overview.c
@@ +94,3 @@
+    GtkTreeModel *model;
+    GtkTreeIter iter;
+    model = gd_main_view_get_model (GD_MAIN_VIEW (gtk_widget_get_parent (widget)));

Why can't you get the model from the iconview itself?
Comment 36 Claudio Saavedra 2012-12-14 09:40:03 UTC
Review of attachment 231401 [details] [review]:

Looks good, besides the comment. I think we can push this after you fix that.

::: embed/ephy-overview.c
@@ +94,3 @@
+    GtkTreeModel *model;
+    GtkTreeIter iter;
+    model = gd_main_view_get_model (GD_MAIN_VIEW (gtk_widget_get_parent (widget)));

Why can't you get the model from the iconview itself?
Comment 37 Claudio Saavedra 2012-12-19 09:04:41 UTC
Are you committing this?
Comment 38 Diego Escalante Urrelo (not reading bugmail) 2012-12-19 14:38:35 UTC
To commit this I need to know if bug #690110 removing ::link-message is going in too.

The difference is that if that patch is not accepted I have to add an
  if EPHY_IS_OVERVIEW
    g_object_get ("status-message")
  else EPHY_IS_WEB_VIEW
    ephy_web_view_get_status_message ()

The reason is that API in EphyWebView is returning *either* of ::link-message or ::status-message, whichever is not NULL.

I opted for removing ::link-message because the distinction between messages coming from load events (status-message) and hover events (link-message) is never used.

What do you think? I rather commit the other patch but I can understand if you prefer more time to review the other one.

Btw, I locally fixed your comment about getting the model. Thanks for the review
Comment 39 Xan Lopez 2012-12-19 18:02:30 UTC
(In reply to comment #38)
> To commit this I need to know if bug #690110 removing ::link-message is going
> in too.
> 
> The difference is that if that patch is not accepted I have to add an
>   if EPHY_IS_OVERVIEW
>     g_object_get ("status-message")
>   else EPHY_IS_WEB_VIEW
>     ephy_web_view_get_status_message ()
> 
> The reason is that API in EphyWebView is returning *either* of ::link-message
> or ::status-message, whichever is not NULL.
> 
> I opted for removing ::link-message because the distinction between messages
> coming from load events (status-message) and hover events (link-message) is
> never used.
> 
> What do you think? I rather commit the other patch but I can understand if you
> prefer more time to review the other one.
> 
> Btw, I locally fixed your comment about getting the model. Thanks for the
> review

Let's get this in without waiting for the other patch, because I'm not really sure we want to get rid of the distinction.
Comment 40 Diego Escalante Urrelo (not reading bugmail) 2012-12-19 18:40:25 UTC
Created attachment 231922 [details] [review]
e-overview: add a statusbar for hovered icons

Show the URL of the icon in a floating statusbar, like in regular
websites.

Adds ::status-message to EphyOverview, mimicking EphyWebView's same
property. EphyEmbed listens to both properties and updates its statusbar
when any of those changes.
--

Updated for Claudio's model comment and not using the link-message patch.
Comment 41 Claudio Saavedra 2012-12-19 21:48:27 UTC
(In reply to comment #39)
 
> Let's get this in without waiting for the other patch, because I'm not really
> sure we want to get rid of the distinction.

Could you please explain in the other bug report why you don't see this possible?
Comment 42 Xan Lopez 2013-01-04 16:59:49 UTC
(In reply to comment #41)
> Could you please explain in the other bug report why you don't see this
> possible?

FWIW I'm not saying it's not possible, I'm only saying that the distinction between those things is real regardless of whether we are making a good use of it right now or not. So we should think it through a bit more before getting rid of it (ie, no "this is unused right now" but "this is unused and we really should never need it to know the difference).
Comment 43 Xan Lopez 2013-01-04 17:03:02 UTC
Review of attachment 231922 [details] [review]:

::: embed/ephy-overview.c
@@ +200,3 @@
 
+  object_class->finalize  = ephy_overview_finalize;
+  object_class->get_property = ephy_overview_get_property;

Hey, wow, if we are bothering to make this a property we should really implement 'set_property' and use it instead of hacking around internally to set the data.
Comment 44 Diego Escalante Urrelo (not reading bugmail) 2013-01-04 21:19:05 UTC
Attachment 231084 [details] pushed as 2a5f103 - e-embed: only add one statusbar timeout at a time
Attachment 231291 [details] pushed as 1777a51 - e-embed: use an overlay for the overview
Attachment 231292 [details] pushed as 5032d8a - e-embed: hide progress for about and ephy-about

Committed this ones that are independent of the final patch.
Note: Cosimo has a small patch for a 1px line that appears with this
change just on top of the statusbar. I'm pinging him about this, he was
waiting for me to commit this part.
Comment 45 Diego Escalante Urrelo (not reading bugmail) 2013-01-04 22:11:06 UTC
I found a problem in the implementation, suggestions welcome:

1. Hover a thumbnail in the overview you get, say "http://twitter.com"
2. Click it, you get "Loading twitter.com"
3. You move the mouse out (when the thumbnail is gone, or to a blank space while it is still visible), the tooltip disappears completely

So, in certain situations hovering-out of a thumbnail in the overview can destroy the "Loading…" tooltip, and since that is set only once you lose feedback about the page status.
Comment 46 Lorenzo Tilve 2014-03-06 09:05:12 UTC
With the new HTML implementation of the overview, the snapshots are now working as standard links, showing the target on the statusbar when overing them.