return ;
}
+ /**
+ * perhaps we should select the default in the window somewhere...
+ */
public string firstBuildModule()
{
-
+ var iter = this.compilegroups.map_iterator();
+ while(iter.next()) {
+
+ if (iter.get_value().name == "__default__") {
+ continue;
+ }
+
+ return iter.get_value().name;
+ }
+ return "";
}
}
}
+ /**
+ * get a list of files for a folder..
+ *
+ * - in the project manager this has to list all possible compilable
+ * files - eg. exclue XXX.vala.c or XXX.c with the same name as
+ * a vala file (so to ignore the generated files)
+ *
+ * - for the editor navigation - this should exclude all files that
+ * are vala based on a bjs file..
+ *
+ */
public Gee.ArrayList<string> files(string in_path)
try {
var file_enum = dir.enumerate_children(
- GLib.FileAttribute.STANDARD_DISPLAY_NAME,
+ GLib.FileAttribute.STANDARD_DISPLAY_NAME,
GLib.FileQueryInfoFlags.NONE,
null
);
// any other valid types???
}
+
+ } catch(Error e) {
+ GLib.warning("oops - something went wrong scanning the projects\n");
+ }
+
// add the cfiles to ret - if they do not have a vala...
- for (var i = 0; i < cfiles.size; i ++) {
-
- var vv = (new Regex("\\.c$")).replace(
- cfiles.get(i), cfiles.get(i).length, 0, ".vala");
-
- if (ret.index_of( vv) > -1) {
- continue;
- }
- ret.add(cfiles.get(i));
+ for (var i = 0; i < cfiles.size; i ++) {
+
+ var fn = cfiles.get(i);
+ vv = fn;
+ try {
+ vv = (new Regex("\\.c$")).replace( fn, fn, 0, ".vala");
+ } catch (Error e) {
+ continue;
}
+
-
- } catch(Error e) {
- GLib.warning("oops - something went wrong scanning the projects\n");
+ if (ret.index_of( vv) > -1) {
+ continue;
+ }
+ ret.add(fn);
}
+
+
GLib.debug("SCAN %s = returning %d", dirname, ret.size);
return ret;