[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[List Home]
|
[tm-cvs-commit] dmcknight org.eclipse.tm.rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources SystemEditableRemoteFile.java
|
- From: Eclipse CVS Genie <genie@xxxxxxxxxxx>
- Date: Mon, 16 Jan 2012 15:59:57 +0000
- Delivered-to: tm-cvs-commit@eclipse.org
Update of /cvsroot/tools/org.eclipse.tm.rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources
In directory dev1:/tmp/cvs-serv8039/src/org/eclipse/rse/files/ui/resources
Modified Files:
Tag: R3_2_maintenance
SystemEditableRemoteFile.java
Log Message:
[249031] Last used editor should be set to SystemEditableRemoteFile
Index: SystemEditableRemoteFile.java
===================================================================
RCS file: /cvsroot/tools/org.eclipse.tm.rse/plugins/org.eclipse.rse.files.ui/src/org/eclipse/rse/files/ui/resources/SystemEditableRemoteFile.java,v
retrieving revision 1.70.2.3
retrieving revision 1.70.2.4
diff -C2 -d -r1.70.2.3 -r1.70.2.4
*** SystemEditableRemoteFile.java 4 Oct 2011 15:41:17 -0000 1.70.2.3
--- SystemEditableRemoteFile.java 16 Jan 2012 15:59:55 -0000 1.70.2.4
***************
*** 1,4 ****
/*******************************************************************************
! * Copyright (c) 2002, 2011 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
--- 1,4 ----
/*******************************************************************************
! * Copyright (c) 2002, 2012 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
***************
*** 43,46 ****
--- 43,47 ----
* David McKnight (IBM) - [334839] File Content Conflict is not handled properly
* David McKnight (IBM) - [359704] SystemEditableRemoteFile does not release reference to editor
+ * David McKnight (IBM) - [249031] Last used editor should be set to SystemEditableRemoteFile
*******************************************************************************/
***************
*** 269,286 ****
this.localPath = getDownloadPath();
! // dkm - use registered
! String fileName = remoteFile.getName();
!
! IEditorRegistry registry = getEditorRegistry();
!
! if (registry != null){
! IEditorDescriptor descriptor = registry.getDefaultEditor(fileName);
! if (descriptor == null)
! {
! descriptor = getDefaultTextEditor();
! }
!
! this._editorDescriptor = descriptor;
}
}
--- 270,287 ----
this.localPath = getDownloadPath();
! IFile localResource = getLocalResource();
!
! // first look for editor corresponding to this particular file
! IEditorDescriptor descriptor = null;
! try {
! descriptor = IDE.getEditorDescriptor(localResource);
! } catch (PartInitException e) {
! }
!
! if (descriptor == null){
! descriptor = getDefaultTextEditor();
}
+
+ this._editorDescriptor = descriptor;
}