Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 78437 Details for
Bug 203365
[dnd]Profile should not be saved as a result of file transfer
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Only do a commit if encoding has changed
patch.txt (text/plain), 2.49 KB, created by
Kevin Doyle
on 2007-09-14 11:05:18 EDT
(
hide
)
Description:
Only do a commit if encoding has changed
Filename:
MIME Type:
Creator:
Kevin Doyle
Created:
2007-09-14 11:05:18 EDT
Size:
2.49 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.rse.core >Index: src/org/eclipse/rse/core/model/Host.java >=================================================================== >RCS file: /cvsroot/dsdp/org.eclipse.tm.rse/plugins/org.eclipse.rse.core/src/org/eclipse/rse/core/model/Host.java,v >retrieving revision 1.12 >diff -u -r1.12 Host.java >--- src/org/eclipse/rse/core/model/Host.java 25 May 2007 13:23:40 -0000 1.12 >+++ src/org/eclipse/rse/core/model/Host.java 14 Sep 2007 14:56:56 -0000 >@@ -20,6 +20,7 @@ > * Martin Oberhuber (Wind River) - [184095] Replace systemTypeName by IRSESystemType > * Martin Oberhuber (Wind River) - [177523] Unify singleton getter methods > * Martin Oberhuber (Wind River) - [186640] Add IRSESystemType.testProperty() >+ * Kevin Doyle (IBM) - [203365] Profile should not be saved as a result of file transfer > ********************************************************************************/ > > package org.eclipse.rse.core.model; >@@ -555,7 +556,7 @@ > * @see org.eclipse.rse.core.model.IHost#setDefaultEncoding(java.lang.String, boolean) > */ > public void setDefaultEncoding(String encoding, boolean fromRemote) { >- >+ boolean commit = false; > IPropertySet encPropertySet = getPropertySet(ENCODING_PROPERTY_SET); > > if (encPropertySet == null) { >@@ -563,27 +564,35 @@ > } > > if (encPropertySet != null) { >+ String savedNonRemoteEncoding = encPropertySet.getPropertyValue(ENCODING_NON_REMOTE_PROPERTY_KEY); >+ String savedRemoteEncoding = encPropertySet.getPropertyValue(ENCODING_REMOTE_PROPERTY_KEY); > > if (encoding != null) { > >- if (!fromRemote) { >+ if (!fromRemote && !encoding.equals(savedNonRemoteEncoding)) { > encPropertySet.addProperty(ENCODING_NON_REMOTE_PROPERTY_KEY, encoding); >+ commit = true; > } >- else { >+ else if (fromRemote && !encoding.equals(savedRemoteEncoding)) { > encPropertySet.addProperty(ENCODING_REMOTE_PROPERTY_KEY, encoding); >+ commit = true; > } > } > else { > >- if (!fromRemote) { >+ if (!fromRemote && savedNonRemoteEncoding != null) { > encPropertySet.removeProperty(ENCODING_NON_REMOTE_PROPERTY_KEY); >+ commit = true; > } >- else { >+ else if (fromRemote && savedRemoteEncoding != null) { > encPropertySet.removeProperty(ENCODING_REMOTE_PROPERTY_KEY); >+ commit = true; > } > } > } >- >- commit(); >+ // Only commit if the encoding has changed >+ if (commit) { >+ commit(); >+ } > } > } >\ No newline at end of file
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
mober.at+eclipse
:
iplog+
Actions:
View
|
Diff
Attachments on
bug 203365
: 78437