DESCRIPTION

Bug 432915: "Open Workspace Version" enabled without file existing

The "Open Workspace Version" menu of the history table now also checks
for existence of the single selected file, similar to the "Compare with
workspace" command.

Change-Id: I67cafbd084f7701f67e9d8497de35d7f15aaf03c
Signed-off-by: Jack Yu xxx@xxx.xxx


COMMENTS

author: Jack Yu
date: 2014-04-19 12:44:50.000000000

Uploaded patch set 1.

-------------------------------------
author: Brenden Conley
date: 2014-04-19 12:44:56.000000000

Patch Set 1:

Build Started https://hudson.eclipse.org/egit/job/egit.gerrit/5763/

-------------------------------------
author: Brenden Conley
date: 2014-04-19 12:58:58.000000000

Patch Set 1: Verified+1

Build Successful 

https://hudson.eclipse.org/egit/job/egit.gerrit/5763/ : SUCCESS

-------------------------------------
author: Danika Greer
date: 2014-04-19 13:02:19.000000000

Patch Set 1: Code-Review-1

(2 comments)

Line:337, org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitFileDiffViewer.java -> In case of a deleted file, getNewPath returns /dev/null, which causes a garbage path. Could you add a check with getChange(), and disable it in case of DELETE?

Line:342, org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitFileDiffViewer.java -> Setting enabled twice is a bit weird. Could you instead move the other setEnabled for openWorkingTreeVersion into the else? Then you can remove `openWorkingTreeVersion.isEnabled() &&` here.

-------------------------------------
author: Jack Yu
date: 2014-04-20 06:17:31.000000000

Patch Set 1:

(2 comments)

Line:337, org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitFileDiffViewer.java -> I've added a check, according to what I understood from your comment. Please  verify that it is what you wanted. :)

Line:342, org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/CommitFileDiffViewer.java -> Done

-------------------------------------
