ALLEGRO_FILECHOOSER *al_create_native_file_dialog(
   char const *initial_path,
   char const *title,
   char const *patterns,
   int mode)
Introduced in 5.0.0

Creates a new native file dialog. You should only have one such dialog opened at a time.


Possible flags for the 'flags' parameter are:

If supported by the native dialog, it will not allow entering new names, but just allow existing files to be selected. Else it is ignored.
If the native dialog system has a different dialog for saving (for example one which allows creating new directories), it is used. Else ignored.
If there is support for a separate dialog to select a folder instead of a file, it will be used.
If a different dialog is available for selecting pictures, it is used. Else ignored.
If the platform supports it, also hidden files will be shown.
If supported, allow selecting multiple files.


A handle to the dialog which you can pass to al_show_native_file_dialog to display it, and from which you then can query the results. When you are done, call al_destroy_native_file_dialog on it.

If a dialog window could not be created then this function returns NULL.

Examples: ex_native_filechooser

Most helpful discussions:

Other recent discussions: