diff options
author | Levi Bard <levibard@mono-cvs.ximian.com> | 2009-09-11 20:14:10 +0400 |
---|---|---|
committer | Levi Bard <levibard@mono-cvs.ximian.com> | 2009-09-11 20:14:10 +0400 |
commit | 75ff6c92e4fbec7e6beaa73d85501ef9b6eaaa34 (patch) | |
tree | e5f7e78cea247d39146ffb66fcaac536e33169b4 /extras/ValaBinding | |
parent | 6ecdeafefa61249008912a1c77d84cdb29f4c3ef (diff) |
Allow vala files to be edited without a vsc-shell installation.
svn path=/trunk/monodevelop/; revision=141777
Diffstat (limited to 'extras/ValaBinding')
-rw-r--r-- | extras/ValaBinding/ChangeLog | 5 | ||||
-rw-r--r-- | extras/ValaBinding/Parser/ProjectInformation.cs | 22 |
2 files changed, 17 insertions, 10 deletions
diff --git a/extras/ValaBinding/ChangeLog b/extras/ValaBinding/ChangeLog index caa6d7eb16..e83f71f381 100644 --- a/extras/ValaBinding/ChangeLog +++ b/extras/ValaBinding/ChangeLog @@ -1,3 +1,8 @@ +2009-09-11 Levi Bard <taktaktaktaktaktaktaktaktaktak@gmail.com> + + * Parser/ProjectInformation.cs: Allow vala files to be edited + without a vsc-shell installation. Reported by Andy Selvig. + 2009-08-26 Lluis Sanchez Gual <lluis@novell.com> * configure.in: diff --git a/extras/ValaBinding/Parser/ProjectInformation.cs b/extras/ValaBinding/Parser/ProjectInformation.cs index bdf39271e2..2295b24905 100644 --- a/extras/ValaBinding/Parser/ProjectInformation.cs +++ b/extras/ValaBinding/Parser/ProjectInformation.cs @@ -590,16 +590,18 @@ namespace MonoDevelop.ValaBinding.Parser public List<CodeNode> GetClassesForFile (string file) { List<CodeNode> classes = new List<CodeNode> (); - AddFile (file); - CodeNode node = null; - - lock(p){ p.StandardInput.WriteLine ("reparse both"); } - - foreach (string result in ParseCommand ("get-classes {0}", file)) { - Console.WriteLine ("get-classes: got {0}", result); - node = ParseType (string.Empty, result); - if(null != node && node.IsContainerType) { - classes.Add (node); + if (null != p) { + AddFile (file); + CodeNode node = null; + + lock(p){ p.StandardInput.WriteLine ("reparse both"); } + + foreach (string result in ParseCommand ("get-classes {0}", file)) { + Console.WriteLine ("get-classes: got {0}", result); + node = ParseType (string.Empty, result); + if(null != node && node.IsContainerType) { + classes.Add (node); + } } } |