[TC 8.0b17 x64] Losing focus when closing Choose Command

The behaviour described in the bug report is either by design, or would be far too complex/time-consuming to be changed

Moderators: Hacker, petermad, Stefan2, white

Post Reply
ayww
Junior Member
Junior Member
Posts: 16
Joined: 2003-06-25, 15:50 UTC

[TC 8.0b17 x64] Losing focus when closing Choose Command

Post by *ayww »

Closing the "Choose Command" window (e.g. after opening Configuration -> Buttonbar -> click on magnifier) via the window close button (X at top right) causes TC to lose focus and switch to other programs running.

Clicking Cancel in "Choose Command" window always works fine.

I have tested on Windows XP 32Bit and Windows XP x64:

It only happens on WinXP x64 with TC 64Bit.

WinXP 32Bit and TC 32Bit is ok.
WinXP x64 and TC 32Bit is ok.


I think this might be the same as here:
http://ghisler.ch/board/viewtopic.php?t=33388
umbra
Power Member
Power Member
Posts: 876
Joined: 2012-01-14, 20:41 UTC

Re: [TC 8.0b17 x64] Losing focus when closing Choose Command

Post by *umbra »

ayww wrote:I think this might be the same as here:
http://ghisler.ch/board/viewtopic.php?t=33388
Probably, except in this case, there is no flickering, when I press Cancel.
Windows 10 Pro x64, Windows 11 Pro x64
User avatar
petermad
Power Member
Power Member
Posts: 16115
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

I can confirm this.

It does NOT happen if I open the dialog by using cm_CommandBrowser.

But it happens if I open the dialog using the magnifying button in:
1. Change button bar
2. Change start menu
3. Change directory menu
4. Configuration -> Misc. -> Redifine hotkeys
License #524 (1994)
Danish Total Commander Translator
TC 11.55rc4 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1393a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50861
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Yes, it's the same problem. It's a bug in Lazarus (certain inherited methods of a common form ancestor are not called). Calling the functions manually seems to do the trick, but I have to change that in all dialogs (I already did it in some of them).
Author of Total Commander
https://www.ghisler.com
umbra
Power Member
Power Member
Posts: 876
Joined: 2012-01-14, 20:41 UTC

Post by *umbra »

Partially fixed in beta 18. There is still a difference:
1. Open "Choose Command" dialog.
2. Focus to another application.
3. Refocus to "Choose Command" dialog.

Now when you close it with Cancel, the focus stays in TC. But if you close it with X, the other app becomes focused.
Windows 10 Pro x64, Windows 11 Pro x64
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50861
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Sorry, this cannot be prevented.
Author of Total Commander
https://www.ghisler.com
Post Reply