diff options
| author | Avi Levkovich <avi@twine-s.com> | 2020-04-21 14:21:19 +0300 |
|---|---|---|
| committer | Avi Levkovich <avi@twine-s.com> | 2020-04-21 14:21:19 +0300 |
| commit | cd728bf3a7d1db76747cb18bcfe396c83d690e86 (patch) | |
| tree | 99347262eef3f175a7ff1441b6c5a031be74d26f /Software/Visual_Studio/Tango.FileSystem/FileExplorerControl.cs | |
| parent | 7fe23e68512e2462de107e76ae3a92ddd381ac77 (diff) | |
| parent | 97a784b6ce43960bdb92465b08f26d3562a4f202 (diff) | |
| download | Tango-cd728bf3a7d1db76747cb18bcfe396c83d690e86.tar.gz Tango-cd728bf3a7d1db76747cb18bcfe396c83d690e86.zip | |
Merge branch 'master' of https://twinetfs.visualstudio.com/_git/Tango
Diffstat (limited to 'Software/Visual_Studio/Tango.FileSystem/FileExplorerControl.cs')
| -rw-r--r-- | Software/Visual_Studio/Tango.FileSystem/FileExplorerControl.cs | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/Software/Visual_Studio/Tango.FileSystem/FileExplorerControl.cs b/Software/Visual_Studio/Tango.FileSystem/FileExplorerControl.cs index 0a7fe8ddc..58d0772f5 100644 --- a/Software/Visual_Studio/Tango.FileSystem/FileExplorerControl.cs +++ b/Software/Visual_Studio/Tango.FileSystem/FileExplorerControl.cs @@ -305,6 +305,14 @@ namespace Tango.FileSystem public static readonly DependencyProperty SelectionModeProperty = DependencyProperty.Register("SelectionMode", typeof(SelectionMode), typeof(FileExplorerControl), new PropertyMetadata(SelectionMode.Extended)); + public bool AllowFolderDownload + { + get { return (bool)GetValue(AllowFolderDownloadProperty); } + set { SetValue(AllowFolderDownloadProperty, value); } + } + public static readonly DependencyProperty AllowFolderDownloadProperty = + DependencyProperty.Register("AllowFolderDownload", typeof(bool), typeof(FileExplorerControl), new PropertyMetadata(true)); + static FileExplorerControl() { DefaultStyleKeyProperty.OverrideMetadata(typeof(FileExplorerControl), new FrameworkPropertyMetadata(typeof(FileExplorerControl))); @@ -369,7 +377,7 @@ namespace Tango.FileSystem DownloadCommand?.Execute(SelectedItems.ToList()); - }, () => SelectedItems != null && SelectedItems.Count > 0 && SelectedItems.All(x => x.Type != FileSystemItemType.Drive)); + }, () => SelectedItems != null && SelectedItems.Count > 0 && SelectedItems.All(x => x.Type != FileSystemItemType.Drive && (AllowFolderDownload || x.Type == FileSystemItemType.File))); OpenCommand = new RelayCommand(() => { |
