public void SetAccess(DirectoryInfo folder, string account, FileSystemRights fsRights) { //hide our main window and throw up a quick dialog to tell user what is going on this.Visibility = Visibility.Hidden; waitWin = new PermissionDialog(); waitWin.Show(); Async.Queue("Set Directory Permissions", () => SetDirectoryAccess(folder, account, fsRights, AccessControlType.Allow), () => this.Dispatcher.Invoke(new DoneProcess(PermissionsDone))); }
public void SetAccess(DirectoryInfo folder, string account, FileSystemRights fsRights) { //hide our main window and throw up a quick dialog to tell user what is going on this.Visibility = Visibility.Hidden; waitWin = new PermissionDialog(); waitWin.Show(); Async.Queue(Async.ThreadPoolName.SetDirectoryPermissions, () => SetDirectoryAccess(folder, account, fsRights, AccessControlType.Allow), () => this.Dispatcher.Invoke(new DoneProcess(PermissionsDone))); }