fixed run for project that is open from remote file system make-project-no-ant-193253
authorVladimir Kvashin <vkvashin@netbeans.org>
Thu, 28 Apr 2011 16:28:23 +0400
branchmake-project-no-ant-193253
changeset 19730628430c6c6eef
parent 197305 5ad182bdf87a
child 197307 37b5136b6a1c
fixed run for project that is open from remote file system
cnd.makeproject/src/org/netbeans/modules/cnd/makeproject/api/configurations/MakeConfiguration.java
     1.1 --- a/cnd.makeproject/src/org/netbeans/modules/cnd/makeproject/api/configurations/MakeConfiguration.java	Thu Apr 28 16:10:06 2011 +0400
     1.2 +++ b/cnd.makeproject/src/org/netbeans/modules/cnd/makeproject/api/configurations/MakeConfiguration.java	Thu Apr 28 16:28:23 2011 +0400
     1.3 @@ -695,8 +695,17 @@
     1.4                  return result;
     1.5              }
     1.6          }
     1.7 +        //if (CndFileUtils.isLocalFileSystem(getBaseFSPath().getFileSystem())) {
     1.8          ExecutionEnvironment execEnv = getDevelopmentHost().getExecutionEnvironment();
     1.9 -        return (execEnv.isLocal()) ? null : ServerList.get(execEnv).getSyncFactory(); // FIXUP: temporary solution
    1.10 +        if (execEnv.isLocal()) {            
    1.11 +            return null;
    1.12 +        } else {
    1.13 +            ExecutionEnvironment fsEnv = FileSystemProvider.getExecutionEnvironment(getBaseFSPath().getFileSystem());
    1.14 +            if (execEnv.equals(fsEnv)) {
    1.15 +                return RemoteSyncFactory.fromID(RemoteProject.FULL_REMOTE_SYNC_ID);
    1.16 +            }
    1.17 +            return ServerList.get(execEnv).getSyncFactory();
    1.18 +        }
    1.19      }
    1.20  
    1.21      public RemoteSyncFactory getFixedRemoteSyncFactory() {