diff options
author | Tomas O'Connor <toconnor@openoffice.org> | 2003-01-16 10:42:48 +0000 |
---|---|---|
committer | Tomas O'Connor <toconnor@openoffice.org> | 2003-01-16 10:42:48 +0000 |
commit | dbae842f902660c416abcc68da7f8b701921368f (patch) | |
tree | 3d64e3c40cd28bb23b65f2b62e83048c6ed36497 /scripting/java/org/openoffice/netbeans/modules/office/utils | |
parent | Replaced full offapi.db with minimal Scripting Framework db. (diff) | |
download | core-dbae842f902660c416abcc68da7f8b701921368f.tar.gz core-dbae842f902660c416abcc68da7f8b701921368f.zip |
IssueZilla 10024 - improve generation of paths and urls for office installation
Diffstat (limited to 'scripting/java/org/openoffice/netbeans/modules/office/utils')
-rw-r--r-- | scripting/java/org/openoffice/netbeans/modules/office/utils/ManifestParser.java | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/scripting/java/org/openoffice/netbeans/modules/office/utils/ManifestParser.java b/scripting/java/org/openoffice/netbeans/modules/office/utils/ManifestParser.java index 5a9d5de54015..1101ad3d9cf3 100644 --- a/scripting/java/org/openoffice/netbeans/modules/office/utils/ManifestParser.java +++ b/scripting/java/org/openoffice/netbeans/modules/office/utils/ManifestParser.java @@ -2,9 +2,9 @@ * * $RCSfile: ManifestParser.java,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: toconnor $ $Date: 2002-11-13 17:44:39 $ + * last change: $Author: toconnor $ $Date: 2003-01-16 11:42:48 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -75,6 +75,7 @@ import org.openide.xml.XMLUtil; import org.openoffice.netbeans.modules.office.options.OfficeSettings; import org.openoffice.idesupport.xml.XMLParser; +import org.openoffice.idesupport.SVersionRCFile; public class ManifestParser implements XMLParser { @@ -98,13 +99,14 @@ public class ManifestParser implements XMLParser { Document result = null; try { + SVersionRCFile.OfficeInstallation oi = + new SVersionRCFile.OfficeInstallation( + OfficeSettings.getDefault().getOfficeDirectory()); + String id = oi.getURL("share/dtd/officedocument/1_0/"); + is = new InputSource(inputStream); - is.setSystemId("file://" + - OfficeSettings.getDefault().getOfficeDirectory() + - File.separator + "share" + - File.separator + "dtd" + - File.separator + "officedocument" + - File.separator + "1_0" + File.separator); + is.setSystemId(id); + result = XMLUtil.parse(is, false, false, null, null); } catch (IOException ioe) { |