Skip to content

Commit

Permalink
Disable symlink/hardlink option when not relevant (Cocoa)
Browse files Browse the repository at this point in the history
Fixes #247.
  • Loading branch information
Virgil Dupras committed Dec 6, 2013
1 parent cb8bb5a commit d14d076
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cocoa/base/DeletionOptions.m
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,9 @@ - (BOOL)show
[[self window] close];
return r == NSOKButton;
}

- (void)setHardlinkOptionEnabled:(BOOL)enabled
{
[linkTypeRadio setEnabled:enabled];
}
@end
4 changes: 4 additions & 0 deletions cocoa/inter/deletion_options.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
class DeletionOptionsView(GUIObjectView):
def updateMsg_(self, msg: str): pass
def show(self) -> bool: pass
def setHardlinkOptionEnabled_(self, enabled: bool): pass

class PyDeletionOptions(PyGUIObject):
def setLinkDeleted_(self, link_deleted: bool):
Expand All @@ -31,3 +32,6 @@ def update_msg(self, msg):
def show(self):
return self.callback.show()

@dontwrap
def set_hardlink_option_enabled(self, enabled):
self.callback.setHardlinkOptionEnabled_(enabled)

0 comments on commit d14d076

Please sign in to comment.