[Xfce4-commits] <xfdesktop:xfce-4.8> Properly invalidate tooltips on file changes.
Jannis Pohlmann
noreply at xfce.org
Sun Jan 30 14:36:06 CET 2011
Updating branch refs/heads/xfce-4.8
to e0fa75600471bc83b7b3049f9a2d53aa355cd109 (commit)
from dde9240481e70a2b63dc16b0f3afe353448f60ae (commit)
commit e0fa75600471bc83b7b3049f9a2d53aa355cd109
Author: Jannis Pohlmann <jannis at xfce.org>
Date: Sun Jan 30 14:34:52 2011 +0100
Properly invalidate tooltips on file changes.
NEWS | 1 +
src/xfdesktop-regular-file-icon.c | 4 ++++
src/xfdesktop-special-file-icon.c | 1 +
3 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/NEWS b/NEWS
index 6e686c8..bfe9fd5 100644
--- a/NEWS
+++ b/NEWS
@@ -9,6 +9,7 @@ Xfdesktop 4.x.y
* Implement monitoring for special file icons (bug #6986).
* Implement open and empty actions for the trash.
* Fix crash when cancelling a file download (bug #6876).
+ * Properly invalidate tooltips on file changes.
Xfdesktop 4.8.0
diff --git a/src/xfdesktop-regular-file-icon.c b/src/xfdesktop-regular-file-icon.c
index b360f7f..840a098 100644
--- a/src/xfdesktop-regular-file-icon.c
+++ b/src/xfdesktop-regular-file-icon.c
@@ -577,6 +577,10 @@ xfdesktop_regular_file_icon_update_file_info(XfdesktopFileIcon *icon,
/* no change, release the new display name */
g_free (new_display_name);
}
+
+ /* invalidate the tooltip */
+ g_free(regular_file_icon->priv->tooltip);
+ regular_file_icon->priv->tooltip = NULL;
/* not really easy to check if this changed or not, so just invalidate it */
xfdesktop_regular_file_icon_invalidate_pixbuf(regular_file_icon);
diff --git a/src/xfdesktop-special-file-icon.c b/src/xfdesktop-special-file-icon.c
index 8f0990c..1226adf 100644
--- a/src/xfdesktop-special-file-icon.c
+++ b/src/xfdesktop-special-file-icon.c
@@ -583,6 +583,7 @@ xfdesktop_special_file_icon_changed(GFileMonitor *monitor,
}
/* invalidate the tooltip */
+ g_free(special_file_icon->priv->tooltip);
special_file_icon->priv->tooltip = NULL;
/* update the icon */
More information about the Xfce4-commits
mailing list