Author: jsc
Date: Wed Jun  4 14:43:45 2014
New Revision: 1600243

URL: http://svn.apache.org/r1600243
Log:
adapt plugin to work with NB 8 and AOO 4.x

Modified:
    openoffice/devtools/netbeansintegration/trunk/manifest.mf
    openoffice/devtools/netbeansintegration/trunk/nbproject/genfiles.properties
    openoffice/devtools/netbeansintegration/trunk/nbproject/project.properties
    openoffice/devtools/netbeansintegration/trunk/nbproject/project.xml
    
openoffice/devtools/netbeansintegration/trunk/project_templates/ComponentProject/nbproject/
   (props changed)
    
openoffice/devtools/netbeansintegration/trunk/project_templates/ComponentProject/nbproject/build-uno-impl.xml
    
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/build-uno-impl.xml
    
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/project.properties
    
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/InstallationFinder.java
    
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/Loader.java
    
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKey.java
    
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKeyException.java
    
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/ConfigurationSettings.java
    
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/IxLocator.java
    
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/MacLocator.java
    
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/util/listeners/BackgroundIdlCompilation.java

Modified: openoffice/devtools/netbeansintegration/trunk/manifest.mf
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/manifest.mf?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- openoffice/devtools/netbeansintegration/trunk/manifest.mf (original)
+++ openoffice/devtools/netbeansintegration/trunk/manifest.mf Wed Jun  4 
14:43:45 2014
@@ -4,7 +4,7 @@ OpenIDE-Module-Layer: org/openoffice/ext
 OpenIDE-Module-Localizing-Bundle: org/openoffice/extensions/Bundle.properties
 OpenIDE-Module-Requires: org.netbeans.api.javahelp.Help
 OpenIDE-Module-Install: org/openoffice/extensions/config/OOoModuleInstall.class
-OpenIDE-Module-Specification-Version: 4.0.5
+OpenIDE-Module-Specification-Version: 4.0.6
 
 Name: org/openoffice/extensions/filetypes/odf/OdfDataLoader.class
 OpenIDE-Module-Class: Loader

Modified: 
openoffice/devtools/netbeansintegration/trunk/nbproject/genfiles.properties
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/nbproject/genfiles.properties?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- openoffice/devtools/netbeansintegration/trunk/nbproject/genfiles.properties 
(original)
+++ openoffice/devtools/netbeansintegration/trunk/nbproject/genfiles.properties 
Wed Jun  4 14:43:45 2014
@@ -3,6 +3,6 @@ build.xml.script.CRC32=71d946a9
 build.xml.stylesheet.CRC32=1101b4cf
 # This file is used by a NetBeans-based IDE to track changes in generated 
files such as build-impl.xml.
 # Do not edit this file. You may delete it but then the IDE will never 
regenerate such files for you.
-nbproject/build-impl.xml.data.CRC32=0253561d
+nbproject/build-impl.xml.data.CRC32=ccd43d4d
 nbproject/build-impl.xml.script.CRC32=0f0c9cde
-nbproject/[email protected]
+nbproject/[email protected]

Modified: 
openoffice/devtools/netbeansintegration/trunk/nbproject/project.properties
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/nbproject/project.properties?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- openoffice/devtools/netbeansintegration/trunk/nbproject/project.properties 
(original)
+++ openoffice/devtools/netbeansintegration/trunk/nbproject/project.properties 
Wed Jun  4 14:43:45 2014
@@ -3,7 +3,7 @@ javac.source=1.6
 javahelp.hs=extensions-hs.xml
 license.file=license.txt
 nbm.homepage=http://wiki.openoffice.org/wiki/OpenOffice_NetBeans_Integration
-nbm.module.author=Sun Microsystems, Inc.
+nbm.module.author=Apache OpenOffice
 # testing paths
 # for Testing on NB 6.1 set jemmy home and jellytools home after installing 
jemmy/jelly plugins
 #mytestbase.dir=${nbplatform.default.netbeans.dest.dir}/testtools

Modified: openoffice/devtools/netbeansintegration/trunk/nbproject/project.xml
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/nbproject/project.xml?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- openoffice/devtools/netbeansintegration/trunk/nbproject/project.xml 
(original)
+++ openoffice/devtools/netbeansintegration/trunk/nbproject/project.xml Wed Jun 
 4 14:43:45 2014
@@ -34,6 +34,12 @@
                     </run-dependency>
                 </dependency>
                 <dependency>
+                    <code-name-base>org.netbeans.libs.junit4</code-name-base>
+                    <build-prerequisite/>
+                    <compile-dependency/>
+                    <run-dependency/>
+                </dependency>
+                <dependency>
                     
<code-name-base>org.netbeans.modules.editor</code-name-base>
                     <build-prerequisite/>
                     <compile-dependency/>
@@ -87,6 +93,15 @@
                     </run-dependency>
                 </dependency>
                 <dependency>
+                    
<code-name-base>org.netbeans.modules.nbjunit</code-name-base>
+                    <build-prerequisite/>
+                    <compile-dependency/>
+                    <run-dependency>
+                        <release-version>1</release-version>
+                        <specification-version>1.83.1</specification-version>
+                    </run-dependency>
+                </dependency>
+                <dependency>
                     
<code-name-base>org.netbeans.modules.options.api</code-name-base>
                     <build-prerequisite/>
                     <compile-dependency/>
@@ -234,6 +249,10 @@
                         
<code-name-base>org.netbeans.libs.junit4</code-name-base>
                         <compile-dependency/>
                     </test-dependency>
+                    <test-dependency>
+                        
<code-name-base>org.netbeans.modules.nbjunit</code-name-base>
+                        <compile-dependency/>
+                    </test-dependency>
                 </test-type>
                 <test-type>
                     <name>qa-functional</name>

Propchange: 
openoffice/devtools/netbeansintegration/trunk/project_templates/ComponentProject/nbproject/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Wed Jun  4 14:43:45 2014
@@ -0,0 +1 @@
+private

Modified: 
openoffice/devtools/netbeansintegration/trunk/project_templates/ComponentProject/nbproject/build-uno-impl.xml
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/project_templates/ComponentProject/nbproject/build-uno-impl.xml?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/project_templates/ComponentProject/nbproject/build-uno-impl.xml
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/project_templates/ComponentProject/nbproject/build-uno-impl.xml
 Wed Jun  4 14:43:45 2014
@@ -159,7 +159,7 @@
 
     <!-- 
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 -->    
 
-    <target name="jar" 
depends="-uno-project-init,uno-idl-compile,-jar-idl-types,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-do-openoffice-manifest,-post-jar">
+    <target name="jar" 
depends="-uno-project-init,uno-idl-compile,-jar-idl-types,compile,-pre-jar,-do-jar-jar,-do-openoffice-manifest,-post-jar">
         <jar basedir="${build.classes.dir}" compress="true" filesonly="true" 
manifest="${build.dir}/MANIFEST.MF" jarfile="${dist.jar}" 
excludes="**/*.xml,**/*.txt,${idl.file.list},${build.classes.excludes}"/>
     </target>
 

Modified: 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/build-uno-impl.xml
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/build-uno-impl.xml?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/build-uno-impl.xml
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/build-uno-impl.xml
 Wed Jun  4 14:43:45 2014
@@ -24,7 +24,7 @@
     </target>
        
     <!-- jar including manifest: usr's own or a created one -->
-    <target name="jar" 
depends="-uno-project-init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-do-openoffice-manifest,-post-jar">
+    <target name="jar" 
depends="-uno-project-init,compile,-pre-jar,-do-jar-jar,-do-openoffice-manifest,-post-jar">
         <jar basedir="${build.classes.dir}" 
manifest="${build.dir}/MANIFEST.MF" filesonly="true" compress="true" 
jarfile="${dist.jar}">
             <fileset refid="bootstrap.glue.code"/>
         </jar>
@@ -58,7 +58,7 @@
     <!-- build list for external jars: Apache OpenOffice jars have to be 
excluded -->
     <target name="-build-filelist">
         <property file="nbproject/project-uno.properties"/>
-        <zipfileset id="zip.file.list" dir="${dist.dir}/lib" 
excludes="${exclude.office.jars}" includes="**/*.jar" casesensitive="yes"/>
+        <zipfileset id="zip.file.list" dir="${dist.dir}/lib" 
excludes="${exclude.office.jars}" includes="**/*.jar" casesensitive="yes" 
erroronmissingdir="false"/>
         <property name="file.list" refid="zip.file.list"/>
         <condition property="do.external.jars">
             <length string="${file.list}" when="greater" length="0"/>

Modified: 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/project.properties
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/project.properties?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/project.properties
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/nbproject/project.properties
 Wed Jun  4 14:43:45 2014
@@ -1,4 +1,4 @@
-application.args=
+application.args=__UnoPackage__.__UnoClientMain__
 build.classes.dir=${build.dir}/classes
 build.classes.excludes=**/*.java,**/*.form
 # This directory is removed when the project is cleaned:

Modified: 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/InstallationFinder.java
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/InstallationFinder.java?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/InstallationFinder.java
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/InstallationFinder.java
 Wed Jun  4 14:43:45 2014
@@ -19,14 +19,13 @@
  * 
  *************************************************************/
 
+
+
 package com.sun.star.lib.loader;
 
-import java.io.BufferedInputStream;
-import java.io.BufferedOutputStream;
 import java.io.BufferedReader;
 import java.io.File;
 import java.io.FileInputStream;
-import java.io.FileOutputStream;
 import java.io.InputStream;
 import java.io.InputStreamReader;
 import java.io.IOException;
@@ -189,7 +188,8 @@ final class InstallationFinder {
      */    
     private static String getPathFromWindowsRegistry() {
 
-        final String SUBKEYNAME = "Software\\OpenOffice.org\\UNO\\InstallPath";
+        final String SUBKEYNAME = "Software\\OpenOffice\\UNO\\InstallPath";
+        final String SUBKEYNAME64 = 
"Software\\Wow6432Node\\OpenOffice\\UNO\\InstallPath";
 
         String path = null;
         
@@ -200,14 +200,28 @@ final class InstallationFinder {
         } catch ( WinRegKeyException e ) {
             try {
                 // read the key's default value from HKEY_LOCAL_MACHINE
-                WinRegKey key = new WinRegKey( "HKEY_LOCAL_MACHINE",
-                                               SUBKEYNAME );
+                WinRegKey key = new WinRegKey( "HKEY_LOCAL_USER",
+                                               SUBKEYNAME64 );
                 path = key.getStringValue( "" ); // default                
-            } catch ( WinRegKeyException we ) {
-                System.err.println( "com.sun.star.lib.loader." +
-                    "InstallationFinder::getPathFromWindowsRegistry: " +
-                    "reading key from Windows Registry failed: " + we );
-            }         
+            } catch ( WinRegKeyException e64 ) {
+                try {
+                    // read the key's default value from HKEY_LOCAL_MACHINE
+                    WinRegKey key = new WinRegKey( "HKEY_LOCAL_MACHINE",
+                                                   SUBKEYNAME );
+                    path = key.getStringValue( "" ); // default                
+                } catch ( WinRegKeyException we ) {
+                    try {
+                        // read the key's default value from HKEY_LOCAL_MACHINE
+                        WinRegKey key = new WinRegKey( "HKEY_LOCAL_MACHINE",
+                                                       SUBKEYNAME64 );
+                        path = key.getStringValue( "" ); // default            
    
+                    } catch ( WinRegKeyException we64 ) {
+                        System.err.println( "com.sun.star.lib.loader." +
+                                            
"InstallationFinder::getPathFromWindowsRegistry: " +
+                                            "reading key from Windows Registry 
failed: " + we64 );
+                    } 
+                } 
+            }
         }
         
         return path;        

Modified: 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/Loader.java
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/Loader.java?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/Loader.java
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/Loader.java
 Wed Jun  4 14:43:45 2014
@@ -19,6 +19,8 @@
  * 
  *************************************************************/
 
+
+
 package com.sun.star.lib.loader;
 
 import java.io.File;
@@ -103,32 +105,30 @@ public final class Loader {
                                 "main: cannot get manifest resources: " + e );
         }
         
-        // if no manifest entry was found, check first the system property
-        // Application-Class and if it is not set get the name of the class
+        // if no manifest entry was found, get the name of the class
         // to be loaded from the argument list
-        String[] args = arguments;            
+        String[] args;            
         if ( className == null ) {
-            className = System.getProperty("Application-Class");
-            
-            if (className == null) {
-                if ( arguments.length > 0 ) {            
-                    className = arguments[0];            
-                    args = new String[arguments.length - 1];
-                    System.arraycopy( arguments, 1, args, 0, args.length );
-                } else {
-                    throw new IllegalArgumentException(
-                        "The name of the class to be loaded must be either " +
-                        "specified in the Main-Class attribute of the " +
-                        "com/sun/star/lib/loader/Loader.class entry " +
-                        "of the manifest file or as a command line argument." 
);
-                }
+            if ( arguments.length > 0 ) {            
+                className = arguments[0];            
+                args = new String[arguments.length - 1];
+                System.arraycopy( arguments, 1, args, 0, args.length );
+            } else {
+                throw new IllegalArgumentException(
+                    "The name of the class to be loaded must be either " +
+                    "specified in the Main-Class attribute of the " +
+                    "com/sun/star/lib/loader/Loader.class entry " +
+                    "of the manifest file or as a command line argument." );
             }
+        } else {
+            args = arguments;            
         }
         
         // load the class with the customized class loader and
         // invoke the main method
         if ( className != null ) {
             ClassLoader cl = getCustomLoader();
+            Thread.currentThread().setContextClassLoader(cl);
             Class c = cl.loadClass( className );
             Method m = c.getMethod( "main", new Class[] { String[].class } );
             m.invoke( null, new Object[] { args } );

Modified: 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKey.java
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKey.java?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKey.java
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKey.java
 Wed Jun  4 14:43:45 2014
@@ -19,6 +19,8 @@
  * 
  *************************************************************/
 
+
+
 package com.sun.star.lib.loader;
 
 import java.io.BufferedInputStream;

Modified: 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKeyException.java
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKeyException.java?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKeyException.java
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/project_templates/UNOClientAppProject/src/com/sun/star/lib/loader/WinRegKeyException.java
 Wed Jun  4 14:43:45 2014
@@ -19,6 +19,8 @@
  * 
  *************************************************************/
 
+
+
 package com.sun.star.lib.loader;
 
 /**

Modified: 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/ConfigurationSettings.java
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/ConfigurationSettings.java?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/ConfigurationSettings.java
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/ConfigurationSettings.java
 Wed Jun  4 14:43:45 2014
@@ -43,7 +43,7 @@ import org.openoffice.extensions.config.
 
 /**
  *
- * @author js93811
+ * @author jsc
  */
 public class ConfigurationSettings {
     
@@ -318,6 +318,8 @@ public class ConfigurationSettings {
         String sdkPath = loc.getSdkPath();
         System.setProperty("office.home.dir", officePath); // NOI18N
         System.setProperty("office.program.dir", 
officePath.concat("/").concat(PlatformInfo.getOfficeProgramDir())); // NOI18N
+        System.setProperty("ure.bin.dir", 
System.getProperty("office.program.dir")); // NOI18N
+        
         System.setProperty("oo.version.number", 
loc.isThreeLayerOffice()?"three":"older"); // NOI18N
         System.setProperty("oo.sdk.dir", sdkPath); // NOI18N
         String[] types = loc.getUnoTypesPath();
@@ -333,13 +335,18 @@ public class ConfigurationSettings {
             System.setProperty("sdk.bin.dir", 
sdkPath.concat(File.separator).concat("bin")); // NOI18N
         }
         else {
-            // String platform = PlatformInfo.getPlatformBinDir();
+            String platform = PlatformInfo.getPlatformBinDir();
+//            System.setProperty("sdk.bin.dir", 
sdkPath.concat(File.separator).concat(platform).concat(File.separator).concat("bin"));
 // NOI18N
             System.setProperty("sdk.bin.dir", 
sdkPath.concat(File.separator).concat("bin")); // NOI18N
         }
-        System.setProperty("ure.bin.dir", loc.getUreBinPath()); // NOI18N
+        //System.setProperty("ure.bin.dir", loc.getUreBinPath()); // NOI18N
         String soPath = loc.getPathVariable();
         if (!PlatformInfo.isWindows()) {
             soPath = soPath.concat(File.pathSeparator).concat("/usr/bin"); // 
NOI18N
+        
+            if (PlatformInfo.isMacOS())
+                soPath = new 
String("/usr/lib").concat(File.pathSeparator).concat(soPath); // NOI18N
+
         }
         System.setProperty("office.tool.path", soPath); // NOI18N
     }

Modified: 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/IxLocator.java
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/IxLocator.java?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/IxLocator.java
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/IxLocator.java
 Wed Jun  4 14:43:45 2014
@@ -34,18 +34,14 @@ public class IxLocator extends PlatformL
 
     private final static String[] STARTING_PATHS = 
             new String[] {"/opt", "/usr/lib", "/usr"};
+    private final static String OPENOFFICE_NAME = "openoffice4";
     private final static String OPENOFFICEORG3_NAME = "openoffice.org3";
-    private final static String STAROFFICE9_NAME = "staroffice9";
     private final static String OPENOFFICEORG_NAME = "openoffice.org";
-    private final static String STAROFFICE_NAME = "staroffice";
-    private final static String STARSUITE_NAME = "starsuite";
     // all names in an array for providing some sort of hierarchy
     private final static String[] OFFICE_NAMES = new String[] {
-         STAROFFICE9_NAME,
+         OPENOFFICE_NAME,
          OPENOFFICEORG3_NAME,
-         STAROFFICE_NAME,
-         OPENOFFICEORG_NAME,
-         STARSUITE_NAME,
+         OPENOFFICEORG_NAME
     };
     
     public IxLocator(String officePath, String sdkPath, boolean 
guessOfficePaths) {

Modified: 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/MacLocator.java
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/MacLocator.java?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/MacLocator.java
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/config/office/MacLocator.java
 Wed Jun  4 14:43:45 2014
@@ -34,12 +34,12 @@ public class MacLocator extends Platform
 
     private final static String[] STARTING_PATHS = 
             new String[] {"/Applications"};
+    private final static String OPENOFFICE_NAME = "OpenOffice";
     private final static String OPENOFFICEORG3_NAME = "OpenOffice.org";
-    private final static String STAROFFICE9_NAME = "StarOffice";
     // all names in an array for providing some sort of hierarchy
     private final static String[] OFFICE_NAMES = new String[] {
-         OPENOFFICEORG3_NAME,
-         STAROFFICE9_NAME,
+         OPENOFFICE_NAME,
+         OPENOFFICEORG3_NAME
     };
     
     public MacLocator(String office, String sdk, boolean guessOfficePaths) {
@@ -55,30 +55,29 @@ public class MacLocator extends Platform
         mOfficePathsSet = false;
         try {
             File startPath = new 
File(mOfficePath.getCanonicalPath().concat("/Contents"));
-            File[] baseLink = startPath.listFiles(new FileFilter() {
+            File[] programPath = startPath.listFiles(new FileFilter() {
 
                 public boolean accept(File pathname) {
                     String path = pathname.getPath();
-                    if (path != null && path.endsWith("basis-link")) {
+                    if (path != null && path.endsWith("program")) {
                         return true;
                     }
                     return false;
                 }
             });
-            if (baseLink != null && baseLink.length > 0) {
+            if (programPath != null && programPath.length > 0) {
                 try {
-                    String path = baseLink[0].getCanonicalPath();
-                    mJutUnoilPath = path.concat("/program/classes");
-                    mJuhJurtRidlPath = path.concat("/ure-link/share/java");
-                    mUnorcPath = path.concat("/ure-link/lib");
-                    mUreBinPath = path.concat("/ure-link/bin");
+                    String path = programPath[0].getCanonicalPath();
+                    mJutUnoilPath = path.concat("/classes");
+                    mJuhJurtRidlPath = path.concat("/classes");
+                    // URE path is equal to .../program/MacOS path
+                    mUnorcPath = path;
+                    mUreBinPath = path;
                     mPathVariable = mOfficePath.getCanonicalPath().concat(
                             "/Contents/MacOS:").concat(
-                            
mSdkPath.getCanonicalPath()).concat("/bin:/usr/lib:").concat(
-                            path).concat("/program:").concat(path).concat(
-                            "/ure-link/lib:").concat(mUreBinPath); // // NOI18N
-                    mTypesPath = new 
String[]{path.concat("/ure-link/share/misc/types.rdb"), 
path.concat("/program/offapi.rdb")};
-                    mThreeLayerOffice = true;
+                            
mSdkPath.getCanonicalPath()).concat("/bin:/usr/lib:").concat(path); // // NOI18N
+                    mTypesPath = new String[]{path.concat("/types.rdb")};
+                    mThreeLayerOffice = false;
                     mOfficePathsSet = true;
                 } catch (IOException ex) {
                     LogWriter.getLogWriter().printStackTrace(ex);
@@ -129,7 +128,7 @@ public class MacLocator extends Platform
         if (mSdkPath == null && mOfficePath != null) {  // office, but no sdk 
yet found...
             try {
                 String path = mOfficePath.getCanonicalPath();
-                String sdkPath = path.concat("/basis-link/sdk"); // NOI18N
+                String sdkPath = path.concat("/sdk"); // NOI18N
                 File f = new File(sdkPath);
                 if (f.exists()) {
                     mSdkPath = f.getCanonicalFile();

Modified: 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/util/listeners/BackgroundIdlCompilation.java
URL: 
http://svn.apache.org/viewvc/openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/util/listeners/BackgroundIdlCompilation.java?rev=1600243&r1=1600242&r2=1600243&view=diff
==============================================================================
--- 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/util/listeners/BackgroundIdlCompilation.java
 (original)
+++ 
openoffice/devtools/netbeansintegration/trunk/src/org/openoffice/extensions/util/listeners/BackgroundIdlCompilation.java
 Wed Jun  4 14:43:45 2014
@@ -91,7 +91,8 @@ public class BackgroundIdlCompilation ex
             // ok, five seconds passed and nothing happened, start compilation.
             ConfigurationSettings settings = 
ConfigurationSettings.getSettings();
             String sdkPath = 
settings.getValue(ConfigurationSettings.KEY_SDK_INSTALLATION);
-            String sdkBinPath = 
sdkPath.concat(File.separator).concat(PlatformInfo.getPlatformBinDir()).concat(File.separator).concat("bin");
 // NOI18N
+            String sdkBinPath = 
sdkPath.concat(File.separator).concat(File.separator).concat("bin"); // NOI18N
+//            String sdkBinPath = 
sdkPath.concat(File.separator).concat(PlatformInfo.getPlatformBinDir()).concat(File.separator).concat("bin");
 // NOI18N
             String soProgram = 
settings.getValue(ConfigurationSettings.KEY_OFFICE_INSTALLATION).concat(File.separator).concat(PlatformInfo.getOfficeProgramDir());
             String outPath = System.getProperty("java.io.tmpdir");
             String buildDir = 
"build".concat(OOoListenerHelper.getProjectName());


Reply via email to