--- a/JavaRelease.st Wed Mar 13 17:05:05 2013 +0100
+++ b/JavaRelease.st Fri Mar 15 17:42:25 2013 +0100
@@ -1486,7 +1486,7 @@
"Return path to java home (either JDK or JRE) based on values in registry.
If not on windows or registry key not found, return nil"
- |entry vsn home |
+ |entry vsn home prg|
OperatingSystem isMSWINDOWSlike ifFalse:[ ^ nil ].
vsn := '1.7'.
@@ -1504,6 +1504,12 @@
(home notNil and:[(home := home asFilename) exists]) ifTrue:[ ^ home ].
].
+ (prg := OperatingSystem getEnvironment:'ProgramFiles(x86)') notEmptyOrNil ifTrue:[
+ (home := prg asFilename / 'Java' / 'jre7') exists ifTrue:[ ^ home ].
+ ].
+ (prg := OperatingSystem getEnvironment:'ProgramFiles') notEmptyOrNil ifTrue:[
+ (home := prg asFilename / 'Java' / 'jre7') exists ifTrue:[ ^ home ].
+ ].
^nil
"Created: / 16-02-2013 / 02:52:41 / Jan Vrany <jan.vrany@fit.cvut.cz>"
@@ -1777,11 +1783,11 @@
!JavaRelease class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libjava/JavaRelease.st,v 1.8 2013-02-25 19:38:21 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libjava/JavaRelease.st,v 1.9 2013-03-15 16:42:25 cg Exp $'
!
version_CVS
- ^ '$Header: /cvs/stx/stx/libjava/JavaRelease.st,v 1.8 2013-02-25 19:38:21 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libjava/JavaRelease.st,v 1.9 2013-03-15 16:42:25 cg Exp $'
!
version_SVN