When a user has the cursor on a file on the panel plugin and presses CTRL+LEFT ARROW or CTRL+RIGHT ARROW, TC shows the child of all the current item on the oposite pannel.
But what if the user has pressed this key combination on a file? What should the plugin return to TC in FsFindFirst in this case?
In my current implementation i am returning INVALID_HANDLE_VALUE which causes TC to show the "C:\". I don't like this behavior. Is there anything i can do to modify this behavior?
What to return in FsFindFirst in this case?
Moderators: Hacker, petermad, Stefan2, white
What to return in FsFindFirst in this case?
______________________
David Jorge
Personal License #117854
David Jorge
Personal License #117854
Can someone explain me why when i press CTRL+LEFT/RIGHT in a file FSFindFirst(Path,....) is called with the file appended in the Path variable?
Suppose i have in my filesystem \\DIR_A\File1. In that case Path="\DIR_A\File1".
In the fssampleplugin, when i press CTRL+LEFT/RIGHT FSFindFirst is called with Path="\DIR_A" without the file name appended.
How TC takes he decision to call FSFindFirst with the file appended in the Path variable?
I am already returning the handle to the first file in the current dir as suggested, but with this behavior the other pannel thinks that is in \DIR_A\File1 which is a problem. It show the contents of \DIR_A, but TC thinks it is in \DIR_A\File_1 and if i try to go back a dir, FSFindFirst is called with Path="\DIR_A" instead of Path="\".
Suppose i have in my filesystem \\DIR_A\File1. In that case Path="\DIR_A\File1".
In the fssampleplugin, when i press CTRL+LEFT/RIGHT FSFindFirst is called with Path="\DIR_A" without the file name appended.
How TC takes he decision to call FSFindFirst with the file appended in the Path variable?
I am already returning the handle to the first file in the current dir as suggested, but with this behavior the other pannel thinks that is in \DIR_A\File1 which is a problem. It show the contents of \DIR_A, but TC thinks it is in \DIR_A\File_1 and if i try to go back a dir, FSFindFirst is called with Path="\DIR_A" instead of Path="\".

______________________
David Jorge
Personal License #117854
David Jorge
Personal License #117854
I figured out how to solve the problem. If the file has size 0 TC somehow thinks it is a Directory and calls FSFindFist with the file appended in path variable. If the size is greater than 0, FSFindFirst is called without the file appended in the Path.
IMHO this is not how TC should handle this. Why TC doesn't check if it is a Directory or an Archive? Anyway, problem solved
.
BTW, now there is no need to return an handle to the first file in the current dir...
IMHO this is not how TC should handle this. Why TC doesn't check if it is a Directory or an Archive? Anyway, problem solved

BTW, now there is no need to return an handle to the first file in the current dir...
______________________
David Jorge
Personal License #117854
David Jorge
Personal License #117854
- ghisler(Author)
- Site Admin
- Posts: 50421
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Ah, thanks for the info - I will check where the problem is.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com