Skip to content

Commit

Permalink
Enable duplicate for folders. #5204
Browse files Browse the repository at this point in the history
  • Loading branch information
dkocher committed Oct 17, 2010
1 parent d454539 commit f687c2e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 17 deletions.
9 changes: 1 addition & 8 deletions source/ch/cyberduck/ui/cocoa/BrowserController.java
Expand Up @@ -3856,14 +3856,7 @@ else if(action.equals(Foundation.selector("createFileButtonClicked:"))) {
return this.isMounted() && this.getSession().isCreateFileSupported(this.workdir());
}
else if(action.equals(Foundation.selector("duplicateFileButtonClicked:"))) {
if(this.isMounted() && this.getSelectionCount() == 1) {
final Path selected = this.getSelectedPath();
if(null == selected) {
return false;
}
return selected.attributes().isFile();
}
return false;
return this.isMounted() && this.getSelectionCount() == 1;
}
else if(action.equals(Foundation.selector("renameFileButtonClicked:"))) {
if(this.isMounted() && this.getSelectionCount() == 1) {
Expand Down
10 changes: 1 addition & 9 deletions source/ch/cyberduck/ui/controller/BrowserController.cs
Expand Up @@ -1630,15 +1630,7 @@ private bool IsEditable(Path selected)

private bool View_ValidateDuplicateFile()
{
if (IsMounted() && SelectedPaths.Count == 1)
{
if (null == SelectedPath)
{
return false;
}
return SelectedPath.attributes().isFile();
}
return false;
return IsMounted() && SelectedPaths.Count == 1;
}

private bool View_ValidateRenameFile()
Expand Down

0 comments on commit f687c2e

Please sign in to comment.