Check for window_event_result::deleted for ui_get_filename polling loop
This is instead of using window_exists, which could give a false positive if a new window was allocated with the same pointer value as a deleted one.
This commit is contained in:
parent
7f7047063a
commit
1c8ad24da3
|
@ -301,8 +301,7 @@ int ui_get_filename(char (&filename)[PATH_MAX], const char *const filespec, cons
|
|||
|
||||
wind = ui_dialog_get_window(dlg);
|
||||
|
||||
while (window_exists(wind))
|
||||
event_process();
|
||||
while (event_process() != window_event_result::deleted) {}
|
||||
|
||||
//key_flush();
|
||||
|
||||
|
|
Loading…
Reference in a new issue