heribertolugo / FileList

List all files in a given directory, and provide the option to copy or move selected files.
1 stars 0 forks source link

ZipFilePreviewer Loses Cancellation Token #101

Open heribertolugo opened 1 year ago

heribertolugo commented 1 year ago

in ZipBrowserControlclass. method FileBrowserPreview_MouseDoubleClick a new thread is started but the cancellation token passed in is a new token created - meaning if user attempted to cancel, this token would never know. Attempt should be made to pass current token in use before creating the new thread.

currently line 123:


            this.thread.IsBackground = true;
            this.cancellation = new CancellationTokenSource();

            this.thread.Start(new ThreadArgs((ZipFile.ZipFileItem)item.Tag, this.cancellation.Token, this.listView1, this.currentDirectoryTextBox));