separate tree node expanding bug

Please report only one bug per message!

Moderators: sheep, Hacker, Stefan2, white

Post Reply
mosunovpa
Junior Member
Junior Member
Posts: 2
Joined: 2019-06-17, 11:05 UTC

separate tree node expanding bug

Post by *mosunovpa »

Hello.
Very small bug. When i expand non-focused node of the separate tree by clicking an arrow the new tree item becomes selected. I suppose the tree should not change item selection in that case.
User avatar
DrShark
Power Member
Power Member
Posts: 1625
Joined: 2006-11-03, 22:26 UTC
Location: Kyiv, 68/262

Re: separate tree node expanding bug

Post by *DrShark »

mosunovpa wrote:
2019-06-17, 11:13 UTC
When i expand non-focused node of the separate tree by clicking an arrow the new tree item becomes selected.
What do you mean by "arrow"?

If you meant the [+] item to expand folders in Separate Tree, a click on it with mouse expands the separate tree without changing the current path in active panel, so here it works as expected.

If to set the focus on a separate tree using a command cm_FocusSrcTree, and use up/down arrow keys, they will change focus+selection (it's the same thing for separate tree), and panel's current path will follow focused-selected folder in Separate tree. I don't think it's possible to expand not-focused folders of Separate Tree with arrow keys in a way similar to one possible using mouse and [+] control. As far as I know, described behavior is designed to work this way, I even made a suggestion to enhance it for different workflow, but currently the development of features (and even some bugfixing) related to trees is on hiatus.
Android 4.3.1 no root, kernel 08.09.2016; Win7 Home Premium SP1 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right
User avatar
Horst.Epp
Power Member
Power Member
Posts: 3883
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Re: separate tree node expanding bug

Post by *Horst.Epp »

mosunovpa wrote:
2019-06-17, 11:13 UTC
Hello.
Very small bug. When i expand non-focused node of the separate tree by clicking an arrow the new tree item becomes selected. I suppose the tree should not change item selection in that case.
Not for me.
The tree is expanded and no focus change is made on any of the other two windows.
Windows 10 Home x64 Version 20H2 (OS Build 19042.608)
TC 9.51 x64 / x86, Everything 1.4.1.996 (x64)
User avatar
petermad
Power Member
Power Member
Posts: 9848
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Re: separate tree node expanding bug

Post by *petermad »

2DrShark
If you meant the [+] item to expand folders in Separate Tree
whether you see a [+] or a little triangle depends on these 2 settings in the [Color] section of wincmd.ini:
TreeLineColor=-1 Sets the color of the connecting lines in the tree inside of the file panels, the separate trees, the Alt+F10 tree dialog, and the FTP connect dialog. Values: rgb-value, or -1=default, or -2= invisible
TreeTriangles=-1 Icons to expand/collapse tree:
0: Show [+]
1: Show triangle if supported
-1: Let TC decide
By Default TC shows triangles (in newer OS's), but if TreeLineColor=0 (black) and TreeTriangles=-1 TC decides to show [+]'s

2mosunovpa
The focus is changed in the tree itself when clicking a node, but the file panels are unchanged, so it is not quite the way it is in Windows Explorer.

But both in TC and Explorer It is first when you click on the folder name that the file panel is changed to that folder.
License #524 (1994)
Danish Total Commander Translator
TC 9.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (2004) 64bit, 'Everything' 1.4.1.992 (x64)
TC 3.10 on Android 6.0
Get:
Extended TC Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
DrShark
Power Member
Power Member
Posts: 1625
Joined: 2006-11-03, 22:26 UTC
Location: Kyiv, 68/262

Re: separate tree node expanding bug

Post by *DrShark »

petermad wrote:
2019-11-17, 20:01 UTC
whether you see a [+] or a little triangle depends on these 2 settings in the [Color] section of wincmd.ini:
...
On my OS with clean ini TC decides to use [+] by default.
petermad wrote:
2019-11-17, 20:01 UTC
The focus is changed in the tree itself when clicking a node, but the file panels are unchanged
The topic is about Separate Tree, there focus is not changed to a folder for which we're expanding the node, and this behavior doesn't seem to be configurable.

For regular tree it moves there, and in theory there should be a way to disable this behavior using the AllowSetCursorPos=0 setting:

Code: Select all

[Configuration]
AllowSetCursorPos=0
; Sets behaviour when expanding a large directory in tree view with the mouse, e.g. by clicking on the [+] symbol:
; 1: Mouse cursor is moved so it remains on the expanded directory
; 0: Mouse cursor is not moved
Well, just I tried it on the tree of my C:'\ drive and it is still moved, maybe all the dirs there arn't large enough to make this setting work (but I tried to expand a dir with 65000 subdirs, and cursor moved on it anyway)...
Android 4.3.1 no root, kernel 08.09.2016; Win7 Home Premium SP1 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right
User avatar
petermad
Power Member
Power Member
Posts: 9848
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Re: separate tree node expanding bug

Post by *petermad »

The topic is about Separate Tree, there focus is not changed to a folder for which we're expanding the node, and this behavior doesn't seem to be configurable.
I am talking about the separate tree too. With focus I mean the selection bar in the tree panel - it moves to the folder in the tree of wich I clicked the node to the left of the folder name. And the color of the folder turns red (with clean ini). This applies to 64bit TC

BUT I just discovered that in 32bit TC the selection bar stays where it is - as you experience.

So the behaviour depends on the bitness of TC - I myself would prefer if both versions worked as the 32 bit version

On my OS with clean ini TC decides to use [+] by default.
On my Windows 7, 8.1 and 10 computers it defaults to a triangle. On my Windows XP computer it defaults to [+].

For regular tree it moves there, and in theory there should be a way to disable this behavior using the AllowSetCursorPos=0 setting:
This setting applies to the MOUSE cursor - not the selection cursior bar.
License #524 (1994)
Danish Total Commander Translator
TC 9.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (2004) 64bit, 'Everything' 1.4.1.992 (x64)
TC 3.10 on Android 6.0
Get:
Extended TC Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
DrShark
Power Member
Power Member
Posts: 1625
Joined: 2006-11-03, 22:26 UTC
Location: Kyiv, 68/262

Re: separate tree node expanding bug

Post by *DrShark »

petermad wrote:
2019-11-18, 12:56 UTC
I am talking about the separate tree too. With focus I mean the selection bar in the tree panel - it moves to the folder in the tree of wich I clicked the node to the left of the folder name. And the color of the folder turns red (with clean ini). This applies to 64bit TC

BUT I just discovered that in 32bit TC the selection bar stays where it is - as you experience.
I can confirm this inconsistency in separate trees of Total Commander 9.50 beta 11 x32 and x64 with default TC settings on Windows 10 1903 (18362.535). On x32 clicking the node just expands it, on x64 focus also moves a to a tree folder which node we're clicking.
Android 4.3.1 no root, kernel 08.09.2016; Win7 Home Premium SP1 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right
User avatar
petermad
Power Member
Power Member
Posts: 9848
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Re: separate tree node expanding bug

Post by *petermad »

*Bump* - since this inconsistency also applies to TC 9.5b12
License #524 (1994)
Danish Total Commander Translator
TC 9.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (2004) 64bit, 'Everything' 1.4.1.992 (x64)
TC 3.10 on Android 6.0
Get:
Extended TC Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 39980
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: separate tree node expanding bug

Post by *ghisler(Author) »

So far I couldn't find out why this is happening - seems to be a different implementation of the listbox control in Delphi and Lazarus.
Author of Total Commander
http://www.ghisler.com
User avatar
DrShark
Power Member
Power Member
Posts: 1625
Joined: 2006-11-03, 22:26 UTC
Location: Kyiv, 68/262

Re: separate tree node expanding bug

Post by *DrShark »

HISTORY.TXT wrote:10.01.20 Fixed: Separate tree: Do not focus line when just clicking on expand or collapse icon (64)
Confirmed fixed in TC 9.50 beta 12a 64-bit.
Android 4.3.1 no root, kernel 08.09.2016; Win7 Home Premium SP1 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right
User avatar
petermad
Power Member
Power Member
Posts: 9848
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Re: separate tree node expanding bug

Post by *petermad »

I can confirm the fix in TC 9.5b12a too :-)
License #524 (1994)
Danish Total Commander Translator
TC 9.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (2004) 64bit, 'Everything' 1.4.1.992 (x64)
TC 3.10 on Android 6.0
Get:
Extended TC Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 39980
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: separate tree node expanding bug

Post by *ghisler(Author) »

Thanks - I had to modify the Lazarus library to make it work.
Author of Total Commander
http://www.ghisler.com
Post Reply