Builder4/ValaProjectSettings.bjs
authorAlan Knowles <alan@roojs.com>
Wed, 19 Nov 2014 09:35:20 +0000 (17:35 +0800)
committerAlan Knowles <alan@roojs.com>
Wed, 19 Nov 2014 09:35:20 +0000 (17:35 +0800)
Builder4/ValaProjectSettings.vala

Builder4/ValaProjectSettings.bjs
Builder4/ValaProjectSettings.vala

index 209d01a..7d6ec4b 100644 (file)
                                                 },
                                                 {
                                                     "listeners" : {
-                                                        "activate" : "()  => {\n    \n    var  chooser = new Gtk.FileChooserDialog (\n\t\"Add a directory\", _this.window.el, Gtk.FileChooserAction.SELECT_FOLDER ,\n\t\"_Cancel\",\n\tGtk.ResponseType.CANCEL,\n\t\"_Add\",\n\tGtk.ResponseType.ACCEPT);\n    if (chooser.run () != Gtk.ResponseType.ACCEPT) {\n        chooser.close ();\n           return;\n       }\n       chooser.close ();\n       // add the directory..\n       var fn = _this.project.relPath(chooser.get_filename());\n       _this.project.compilegroups.get(\"_default_\").sources.add(fn);\n       _this.default_directory_tree_store.load();\n}"
+                                                        "activate" : "()  => {\n    \n    var  chooser = new Gtk.FileChooserDialog (\n\t\"Add a directory\", _this.window.el, Gtk.FileChooserAction.OPEN ,\n\t\"_Cancel\",\n\tGtk.ResponseType.CANCEL,\n\t\"_Add\",\n\tGtk.ResponseType.ACCEPT);\n    if (chooser.run () != Gtk.ResponseType.ACCEPT) {\n        chooser.close ();\n           return;\n       }\n       chooser.close ();\n       // add the directory..\n       var fn = _this.project.relPath(chooser.get_filename());\n       _this.project.compilegroups.get(\"_default_\").sources.add(fn);\n       _this.default_directory_tree_store.load();\n}"
                                                     },
                                                     "* pack" : "add",
                                                     "xtype" : "MenuItem",
index 82b18be..6303410 100644 (file)
@@ -752,7 +752,7 @@ public class ValaProjectSettings : Object
             this.el.activate.connect( ()  => {
                 
                 var  chooser = new Gtk.FileChooserDialog (
-               "Add a directory", _this.window.el, Gtk.FileChooserAction.SELECT_FOLDER ,
+               "Add a directory", _this.window.el, Gtk.FileChooserAction.OPEN ,
                "_Cancel",
                Gtk.ResponseType.CANCEL,
                "_Add",