+Copy:copyflags missing in BTM if adv options pinned down

Bug reports will be moved here when the described bug has been fixed

Moderators: Hacker, petermad, Stefan2, white

User avatar
white
Power Member
Power Member
Posts: 5815
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

+Copy:copyflags missing in BTM if adv options pinned down

Post by *white »

TC8.50b1-5

* Start TC with a new wincmd.ini file
* Go to Configuration/Options/Misc and remove check mark before Overwriting files
* Select menu options Command/Background Transfer Manager
* Click the Pause button
* Go back to the TC window, select a file and press F5 (Copy)
* Click the Options button to show advanced options
* Click the pin to pin down the advanced options
* Press F2
* Look at the Background Transfer Manager, the copyflags are set before and after the copy operation
* Again, go back to the TC window, select a file and press F5 (Copy)
* Press F2
* Look at the Background Transfer Manager, the copyflags are not set.
* Again, go back to the TC window, select a file and press F5 (Copy)
* Enable the option Skip all which cannot be opened for reading
* Press F2
* Look at the Background Transfer Manager, the first copyflags line is wrong. The value ought to be 128+4=132
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Currently this scenario isn't supported, sorry. You need to re-open the background dialog after changing the main settings. Currently it's not planned to change that, sorry.
Author of Total Commander
https://www.ghisler.com
User avatar
white
Power Member
Power Member
Posts: 5815
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Post by *white »

ghisler(Author) wrote:Currently this scenario isn't supported, sorry. You need to re-open the background dialog after changing the main settings. Currently it's not planned to change that, sorry.
It tested this very thorough. It has nothing to do with re-opening the background dialog. It has to do with the setting "Overwrite all" and it has to do with the pinned down status. The problem is introduced in beta 1, probably because of this change:
HISTORY.TXT wrote:09.04.13 Fixed: F5 Copy dialog: If lower part is pinned, the option to overwrite read only/hidden/system files wasn't checked when these options were set in Configuration - Options - Misc. (32/64)
Not only the option to overwrite read only/hidden/system files wasn't checked, but also the option Overwrite all was not selected when this option was set in Configuration. Both were fixed in beta 1. The option to overwrite read only/hidden/system files works correct. The option Overwrite all does not work correct. This makes that if you enable another option, the Overwrite all option gets disabled by the copyflags (as shown at the end in the example above).
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

The main problem is that when you used the pinned dialog, it's not clear whether TC should reset the overwrite options to those in the dialog, or use the last settings of the BTM. It's clear when the user clicks on "Options" himself.
Author of Total Commander
https://www.ghisler.com
User avatar
white
Power Member
Power Member
Posts: 5815
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Post by *white »

ghisler(Author) wrote:The main problem is that when you used the pinned dialog, it's not clear whether TC should reset the overwrite options to those in the dialog, or use the last settings of the BTM. It's clear when the user clicks on "Options" himself.
1) When the user has set the default to overwrite without warning, the option in the copy dialog shows the same, he would not expect the option to be disabled! This is exactly what happens if the user selects another option. This is a bug and must be fixed!

2) People of course expect to see the copy operation carried out as specified in the copy dialog. Previously pinned down or not, that does not matter.

3) The behavior is implemented for this option only. It is totally inconsistent.

4) I think most people don't understand the copyflags and don't understand why it is sometimes added and sometimes not. To simply things I suggest to:
  • Always add a copyflags line for each operation. Use the options that are set as default at that moment, override these with the options that are visible in the copy dialog.
  • Don't set the copyflags back after the operation. No longer necessary in combination with above suggestion.
  • Give the user an option to hide/show the copyflags lines.
  • Give the user the option to review and change the copyflags. For example, when the user double clicks a line. A dialog can pop up, with the options and allowing the user to change them.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I will try to re-work this. But since it's quite complex, it will probably need multiple beta versions, so please keep testing it.
Author of Total Commander
https://www.ghisler.com
User avatar
white
Power Member
Power Member
Posts: 5815
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Post by *white »

ghisler(Author) wrote:I will try to re-work this. But since it's quite complex, it will probably need multiple beta versions, so please keep testing it.
Thanks. Yes, I will be testing it.
User avatar
white
Power Member
Power Member
Posts: 5815
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Post by *white »

Tested TC 8.50b6 32bit.
The test case described in first post now works OK.
HISTORY.TXT wrote:06.10.13 Fixed: Changed behaviour of Copy/Move dialog when options pinned open: When adding to BTM, the state of the 1..8 combobox is now always used, except when set to 1 (ask), so when the user chooses a method in the BTM, it stays enabled (32/64)
I'm against "except when set to 1 (ask), so when the user chooses a method in the BTM, it stays enabled". If the copy dialog says no files will be overwritten without asking the user first, it should not happen that important data of the user is overwritten without asking the user.

The status of the copy options of the background transfer window is unknown when a copy task is added. The status could be that files are overwritten without warning. The status could have been changed by changing default options in configuration, adding some tasks, and changing default options again. The status could have been changed by the user deleting lines in the BTM window. The background transfer window could be opened beforehand and then stays open after jobs finish. The user could have chosen Overwrite all for a certain job hours ago. Then if the copy dialog says no files will be overwritten without asking the user first, it should not happen that important data of the user is overwritten without asking the user!

Actually in the current final version of Total Commander it is also dangerous to open the BTM beforehand and leave it open all the time. People may not realize their choices for previous jobs hours ago still apply to new copy operations. Important data could be overwritten without warning when they didn't expected that.
Last edited by white on 2013-11-08, 20:53 UTC, edited 1 time in total.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Sorry but I will not change that. When the user chooses one of the overwrite methods in the BTM, I do not want to reset it each time he adds a file. This would be really annoying.
Author of Total Commander
https://www.ghisler.com
gdpr deleted 6
Power Member
Power Member
Posts: 872
Joined: 2013-09-04, 14:07 UTC

Post by *gdpr deleted 6 »

ghisler(Author) wrote:Sorry but I will not change that. When the user chooses one of the overwrite methods in the BTM, I do not want to reset it each time he adds a file. This would be really annoying.
@Ghisler, you NEED to do something about it.
Just a couple of hours after @white wrote his post, i wrote my report about exactly the same dangerous issue (link)
(At that time i wasn't aware that @white did already post the issue here in this thread.)
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

No, it is fully intentional, it has ALWAYS been like this! It's only for the scenario where "Confirm overwrite" is the default, and the user adds files to an already open BTM. In this case, the state of the BTM will not be changed, e.g. when the user was confirming each file separately, it will remain this way. If, however, the user chose "Overwrite all" in the BTM itself, this will remain active. If the user chose "Confirm overwrite" manually in the F5 copy dialog, then this will of course be sent to the BTM too!
Author of Total Commander
https://www.ghisler.com
User avatar
white
Power Member
Power Member
Posts: 5815
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Post by *white »

HISTORY.TXT wrote:29.10.13 Fixed: Default of CopyOverwriteDefault is now again 1 and not 0 as in beta 6+7: When adding files to background transfer manager, the overwrite flags will be taken from the expanded copy dialog (32/64)
Tested OK using TC 8.50b8 32bit.
TOTALCMD.CHM wrote:BackgroundCopyFlags=1 Controls the overwrite behaviour of the background transfer manager:
0: When the user chooses one of the overwrite options, e.g. "Overwrite all", the option remains active also when adding more files to the transfer manager later (behaviour of TC 8.01 or older)
1: Reset the overwrite options when the transfer manager list reaches the end
2: Reset the overwrite options each time the user adds more files to the transfer manager (always confirm again)
See also: CopyOverwriteDefault. If not set (or set to 1), the flags will be taken from the expanded copy dialog box every time files are added. If set to 0, the flags are not reset.
Addition of last line confirmed.
TOTALCMD.CHM wrote:CopyOverwriteDefault=1 1..8: Set default option chosen when clicking on "Options" button in F5 copy dialog (only used when extended copy dialog opened!). The numbers correspond to the options in the dialog.
0: Like 1, but do not reset overwrite confirmation options when adding files to background copy dialog
Addition of last line confirmed.
New in 8.50: If in section [Confirmation] the option confirmation for OverwriteFiles is set to 0 then the overwrite default will be 2 (Overwrite all)
Question: Shouldn't it only override CopyOverwriteDefault=0 or 1?
TOTALCMD.CHM wrote:[Confirmation] Confirmations
OverwriteFiles=1 Ask before overwriting files
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

New in 8.50: If in section [Confirmation] the option confirmation for OverwriteFiles is set to 0 then the overwrite default will be 2 (Overwrite all)
Question: Shouldn't it only override CopyOverwriteDefault=0 or 1?
OverwriteFiles=0 turns off all overwrite confirmations - this is the switch you can set in Configuration - Options - Misc. I think that this should take precedence over something which can only be set in the wincmd.ini. But it seems that TC 8.01 and older didn't handle it this way - OverwriteFiles doesn't seem to have any effect there when CopyOverwriteDefault is set. It's a difficult decision...
Author of Total Commander
https://www.ghisler.com
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

OK, I have made again some changes in beta 10:
- The OverwriteFiles option is used when the dialog box is not expanded
- CopyOverwriteDefault is used when the dialog box is not expanded, and OverwriteFiles=0, or CopyOverwriteDefault>1
Author of Total Commander
https://www.ghisler.com
User avatar
white
Power Member
Power Member
Posts: 5815
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Post by *white »

ghisler(Author) wrote:OK, I have made again some changes in beta 10:
- The OverwriteFiles option is used when the dialog box is not expanded
- CopyOverwriteDefault is used when the dialog box is not expanded, and OverwriteFiles=0, or CopyOverwriteDefault>1
Do you mean the following?
- CopyOverwriteDefault is used when the dialog box is expanded, and OverwriteFiles=1 (means ask confirmation before overwriting files), or CopyOverwriteDefault>1
Then tested OK using TC 8.50b10 32bit.
Post Reply