[baobab] Ringschart: hardcode subfolder tip timeout
- From: Stefano Facchini <sfacchini src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [baobab] Ringschart: hardcode subfolder tip timeout
- Date: Mon, 8 Jul 2013 20:12:22 +0000 (UTC)
commit 6c4c583c1c070906774b05ae059f63a382855492
Author: Stefano Facchini <stefano facchini gmail com>
Date: Mon Jul 8 22:00:39 2013 +0200
Ringschart: hardcode subfolder tip timeout
The gtk-tooltip-timeout setting is being deprecated in favor of a hardcoded value.
We hardcode our timeout to twice the GTK+ value.
src/baobab-ringschart.vala | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/baobab-ringschart.vala b/src/baobab-ringschart.vala
index 5f9bdc8..45a46b8 100644
--- a/src/baobab-ringschart.vala
+++ b/src/baobab-ringschart.vala
@@ -48,7 +48,9 @@ namespace Baobab {
const double ITEM_MIN_ANGLE = 0.03;
const double EDGE_ANGLE = 0.004;
- int subtip_timeout;
+ // Twice the GTK+ tooltip timeout
+ const int SUBTIP_TIMEOUT = 1000;
+
uint tips_timeout_id = 0;
bool drawing_subtips = false;
List<ChartItem> subtip_items;
@@ -67,7 +69,7 @@ namespace Baobab {
subtip_items = null;
if (highlighted_item != null) {
- tips_timeout_id = Timeout.add (subtip_timeout, () => {
+ tips_timeout_id = Timeout.add (SUBTIP_TIMEOUT, () => {
drawing_subtips = true;
queue_draw ();
return false;
@@ -76,8 +78,6 @@ namespace Baobab {
}
construct {
- subtip_timeout = Gtk.Settings.get_default ().gtk_tooltip_timeout * 2;
-
notify["max-depth"].connect (subtips_update);
notify["highlighted-item"].connect (subtips_update);
notify["root"].connect (subtips_update);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]