tools/JavaSourceHighlighter.st
changeset 3103 a7d69709920f
parent 3101 446b34b9a386
--- a/tools/JavaSourceHighlighter.st	Tue May 13 11:49:43 2014 +0100
+++ b/tools/JavaSourceHighlighter.st	Wed May 14 00:07:29 2014 +0100
@@ -221,6 +221,11 @@
     preferences isNil ifTrue:[
         preferences := UserPreferences current.
     ].
+
+    JavaVM booted ifFalse:[
+        ^ self format: source string.
+    ].
+
     cacheIt := class notNil and: [class isBehavior and:[class theNonMetaclass isJavaClass]].
     cacheIt ifTrue:[
         document := JavaSourceDocument cachedDocumentFor: class theNonMetaclass.
@@ -251,7 +256,7 @@
     self doLexicalHighlightingOnly ifTrue:[          
         sourceText := self format: source string.
     ] ifFalse:[
-        JavaVM booted ifFalse:[JavaVM boot].
+
         sourceUnit := (Java classForName:'stx.libjava.tools.Source') new.
         sourceUnit setContents: source string.
         JavaCompiler synchronized:[
@@ -288,7 +293,7 @@
     ]
 
     "Created: / 04-08-2011 / 23:44:52 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-    "Modified: / 09-04-2014 / 09:54:41 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 13-05-2014 / 23:45:00 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 formatClassDefinition:source in:class elementsInto: els