[baobab/wip/vala: 36/39] Sync the chart root to the treeview selection.
- From: Paolo Borelli <pborelli src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [baobab/wip/vala: 36/39] Sync the chart root to the treeview selection.
- Date: Sat, 4 Feb 2012 10:01:39 +0000 (UTC)
commit 5ed2a8a4fa2356dab52273d07112b62a389ab7e8
Author: Paolo Borelli <pborelli gnome org>
Date: Sun Jan 29 18:25:42 2012 +0100
Sync the chart root to the treeview selection.
src/baobab-window.vala | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/src/baobab-window.vala b/src/baobab-window.vala
index b15b1de..89bbacb 100644
--- a/src/baobab-window.vala
+++ b/src/baobab-window.vala
@@ -294,6 +294,16 @@ namespace Baobab {
}
}
});
+
+ var selection = treeview.get_selection ();
+ selection.changed.connect (() => {
+ Gtk.TreeIter iter;
+ if (selection.get_selected (null, out iter)) {
+ var path = scanner.get_path (iter);
+ rings_chart.set_root (path);
+ treemap_chart.set_root (path);
+ }
+ });
}
void message (string primary_msg, string secondary_msg, Gtk.MessageType type) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]