Auto-Center and/or Auto-Remember Browse For Folder dialog?

Would it be possible to add into Listary the auto-centering on-screen, the Browse For Folder dialog? And/or remembering where the user positioned the dialog the last time, and always re-position that dialog as Listary attaches itself to it?


Whenever some app opens that dialog, it’s defaulted to way down low on the screen, and also, when Listary attaches itself to the bottom (where I do like it), Listary overlaps the buttons on that dialog. I always have to manually move the BFF dialog higher up in order to see (and use) everything.

screenshot example (left shot is original position, right shot is after moving it higher up):

If Listary could just do some auto-centering (including it’s own height of the toolbar) or record the Top/Left coords of the BFF dialog whenever it’s moved around, then reposition it to those coords when it attaches itself to the BFF dialog, life would be that much greater. :stuck_out_tongue:

Windows 10 itself can remember the positions of most file dialogs. There are some dialogs that it doesn’t handle well (like the one shown in your screenshot), and unfortunately these dialogs are also very hard for Listary to deal with :frowning:

I whipped up a small program, took me about an hour, that’ll do it. It just polls for the Dialog, when it’s found, checks for any saved X/Y coords, and if found, places it at the stored coords. Usually there are no saved coords on the first time the dialog is seen; after that it saves the coords itself, so the next time the dialog is seen there will always be saved coords to move it to. (You can test it with 7-Zip, when selecting a folder to extract a .zip to).

It would probably be even easier for Listary to do since it already attaches itself to these dialogs, it would just need to save the X/Y coords on it’s (the dialog’s) close (the width and height properties do get saved properly, so no need to save/restore those) and then as soon as it attaches just restore them. :slight_smile:

it would also be nicer if Listary did this rather than my separate app running, using unnecessary memory/resources, and having it’s timer constantly on the hunt for the windows.

I noticed you wrote Listary in C++, so I used Windows APIs to do it. (GetWindowRect, and SetWindowPos).

Thank you for sharing the script. I’ll test if it’s possible to integrate it into Listary.

1 Like