{
"listeners" : {
"button_press_event" : " ( ev) => {\n //console.log(\"button press?\");\n \n \n if (ev.type != Gdk.EventType.BUTTON_PRESS || ev.button != 3) {\n //print(\"click\" + ev.type);\n return false;\n }\n //Gtk.TreePath res;\n //if (!this.el.get_path_at_pos((int)ev.x,(int)ev.y, out res, null, null, null) ) {\n // return true;\n //}\n \n // this.el.get_selection().select_path(res);\n \n //if (!this.get('/LeftTreeMenu').el) { \n // this.get('/LeftTreeMenu').init(); \n // }\n \n _this.targets_tree_menu.el.set_screen(Gdk.Screen.get_default());\n _this.targets_tree_menu.el.show_all();\n _this.targets_tree_menu.el.popup(null, null, null, 3, ev.time);\n // print(\"click:\" + res.path.to_string());\n return true;\n}",
- "cursor_changed" : " ( ) => {\n\n if (this.cursor != \"\") {\n // save the values..\n }\n \n // load the new values.\n \n\n\n\n }"
+ "cursor_changed" : " ( ) => {\n\n if (this.cursor != \"\") {\n // save the values..\n }\n \n // load the new values.\n \n\n Gtk.TreeModel mod;\n Gtk.TreeIter iter;\n if (!_this.el.get_selection().get_selected(out mod, out iter)) {\n print(\"nothing selected\\n\");\n return;\n }\n\n \n // add the directory..\n \n \n GLib.Value val;\n mod.get_value(iter,0, out val);\n var fn = (string) val;\n \n this.cursor = fn;\n \n // _this.default_directory_tree_store.load();\n\n }"
},
"id" : "targets_tree",
+ "# string cursor" : "",
"* pack" : "add",
"xtype" : "TreeView",
"$ xns" : "Gtk",
// my vars (def)
+ public string cursor;
// ctor
public Xcls_targets_tree(ValaProjectSettings _owner )
// load the new values.
+ Gtk.TreeModel mod;
+ Gtk.TreeIter iter;
+ if (!_this.el.get_selection().get_selected(out mod, out iter)) {
+ print("nothing selected\n");
+ return;
+ }
+
+ // add the directory..
+
+
+ GLib.Value val;
+ mod.get_value(iter,0, out val);
+ var fn = (string) val;
+
+ this.cursor = fn;
+
+ // _this.default_directory_tree_store.load();
});
}