b-em icon indicating copy to clipboard operation
b-em copied to clipboard

choosing a new folder for VDFS doesn't start at the existing one on windows.

Open mark-usher opened this issue 1 year ago • 5 comments

On windows... Line 1016 in gui-allegro.c if ((chooser = al_create_native_file_dialog(vdfs_get_root(), "Choose a folder to be the VDFS root - ", "*", ALLEGRO_FILECHOOSER_FOLDER))) { even though the vdfs root is correct and being returned, it isn't being set as the initial path in the allegro created dialog in windows. Allegro 5 bug?

mark-usher avatar Jun 13 '23 03:06 mark-usher

This seems to be a feature of Allegro 5. Looking at the code in https://github.com/liballeg/allegro5/blob/master/addons/native_dialog/win_dialog.c when the flag ALLEGRO_FILECHOOSER_FOLDER is passed in, almost all the work is done by a separate function that ignores the initial path specified and ends up calling a completely different Windows function than the one that browses for files.

The next step is probably to check if Allegro have this logged as a bug.

SteveFosdick avatar Jun 14 '23 22:06 SteveFosdick

I have raised one: https://github.com/liballeg/allegro5/issues/1449

SteveFosdick avatar Jun 14 '23 23:06 SteveFosdick

Thanks Steve :) I thought it was looking to be on the Allegro side as the variables were holding the expected values before it was handed off.

mark-usher avatar Jun 15 '23 01:06 mark-usher

The next Allegro release will fix this issue

joecarl avatar Sep 28 '23 07:09 joecarl