Пример #1
0
        private async Task DeleteAsync()
        {
            var result = await ShowRemoveConfirmationDialogAsync();

            if (result)
            {
                await _trashCanService.MoveToTrashAsync(Files);
            }
        }
Пример #2
0
        public async Task DeleteAsync(string filePath)
        {
            var files  = CreateFilesList(filePath);
            var result = await ShowRemoveConfirmationDialogAsync(files);

            if (result)
            {
                await _trashCanService.MoveToTrashAsync(files);
            }
        }
Пример #3
0
        private async Task MoveToTrashAsync()
        {
            var nodesToRemove = GetSelectedNodes();

            if (!nodesToRemove.Any())
            {
                return;
            }

            var navigationParameter = new NodesRemovingNavigationParameter(nodesToRemove);
            var result = await ShowRemoveConfirmationDialogAsync(navigationParameter);

            if (result)
            {
                Execute(() => _trashCanService.MoveToTrashAsync(nodesToRemove));
            }
        }
Пример #4
0
        private async Task RemoveToTrashAsync()
        {
            var filesToRemove = GetSelectedFiles();

            if (!filesToRemove.Any())
            {
                return;
            }

            var navigationParameter = new NodesRemovingNavigationParameter(filesToRemove, true);
            var isConfirmed         = await ShowRemoveConfirmationDialogAsync(navigationParameter);

            if (isConfirmed)
            {
                _trashCanService.MoveToTrashAsync(filesToRemove).Forget();
            }
        }