[evince] ev-view: don't show tooltips for empty annotations
- From: Nelson Benítez León <nbenitez src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evince] ev-view: don't show tooltips for empty annotations
- Date: Mon, 25 Dec 2017 08:29:53 +0000 (UTC)
commit de9657875d6da3a14ec3ac852079cdcb00d74f6f
Author: Nelson Benítez León <nbenitezl+gnome gmail com>
Date: Sun Dec 10 17:03:30 2017 +0500
ev-view: don't show tooltips for empty annotations
Empty annotations can be quite common, eg. when
adding highlight annotations where the user doesn't
enter a comment.
So don't show show empty tooltips as they are useless.
https://bugzilla.gnome.org/show_bug.cgi?id=772621
libview/ev-view.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/libview/ev-view.c b/libview/ev-view.c
index bb63b50..5a19a75 100644
--- a/libview/ev-view.c
+++ b/libview/ev-view.c
@@ -4752,7 +4752,8 @@ ev_view_query_tooltip (GtkWidget *widget,
if (annot) {
const gchar *contents;
- if ((contents = ev_annotation_get_contents (annot))) {
+ contents = ev_annotation_get_contents (annot);
+ if (contents && *contents != '\0') {
GdkRectangle annot_area;
get_annot_area (view, x, y, annot, &annot_area);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]