1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-09-10 03:53:21 +02:00

[309755] SystemRemoteFileOpenWithMenu.getPreferredEditor(), the listed default editor is not always correct

This commit is contained in:
David McKnight 2010-04-29 16:06:26 +00:00
parent 156f809081
commit 66a454623a

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2005, 2009 IBM Corporation and others.
* Copyright (c) 2005, 2010 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
* which accompanies this distribution, and is available at
@ -366,9 +366,13 @@ private boolean isFileCached(ISystemEditableRemoteObject editable, IRemoteFile r
boolean usedBinary = properties.getUsedBinaryTransfer();
boolean isBinary = remoteFile.isBinary();
boolean usedReadOnly = properties.getReadOnly();
boolean isReadOnly = !remoteFile.canWrite();
return (!dirty &&
!remoteNewer &&
usedBinary == isBinary &&
usedReadOnly == isReadOnly &&
!encodingChanged);
}
return false;