Fixed WIN32 crash when the file dialog window is cancelled.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8344 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
b42f5ebdbf
commit
caef04e057
@ -88,7 +88,8 @@ void file_cb(const char *n) {
|
||||
|
||||
void button_cb(Fl_Widget *,void *) {
|
||||
fl_file_chooser_callback(file_cb);
|
||||
puts(fl_file_chooser("Image file?","*.{bm,bmp,gif,jpg,pbm,pgm,png,ppm,xbm,xpm}", name));
|
||||
const char *fname = fl_file_chooser("Image file?","*.{bm,bmp,gif,jpg,pbm,pgm,png,ppm,xbm,xpm}", name);
|
||||
puts(fname ? fname : "(null)"); fflush(stdout);
|
||||
fl_file_chooser_callback(0);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user