From 03b112773d646fec27265fb21ee9feea671b6fef Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Fri, 3 Aug 2001 18:46:57 +0000 Subject: File chooser cleanup (use fl_ok and fl_cancel for translated label strings) Remove fl_file_chooser_cb() function, which is not needed with the new Fl_FileChooser dialog and related widgets. List directories first, in boldface. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1548 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- test/file_chooser.cxx | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) (limited to 'test') diff --git a/test/file_chooser.cxx b/test/file_chooser.cxx index 2da1d1f56..cafb2e8d7 100644 --- a/test/file_chooser.cxx +++ b/test/file_chooser.cxx @@ -1,5 +1,5 @@ // -// "$Id: file_chooser.cxx,v 1.4.2.3 2001/01/22 15:13:41 easysw Exp $" +// "$Id: file_chooser.cxx,v 1.4.2.3.2.1 2001/08/03 18:46:57 easysw Exp $" // // File chooser test program for the Fast Light Tool Kit (FLTK). // @@ -28,6 +28,7 @@ #include #include #include +#include #include #include #include @@ -41,23 +42,19 @@ void pickfile(Fl_Widget *) { if (p) current->value(p); } -void thecb(const char *name) { - printf("Callback '%s'\n",name); -} - int main(int argc, char **argv) { - Fl_Window window(400,200); - pattern = new Fl_Input(100,50,280,30,"Pattern:"); + Fl_FileIcon::load_system_icons(); + Fl_Window window(310,110); + pattern = new Fl_Input(100,10,200,25,"Pattern:"); pattern->static_value("*"); - current = new Fl_Input(100,90,280,30,"Current:"); - Fl_Button button(100,120,100,30,"&Choose file"); + current = new Fl_Input(100,40,200,25,"Current:"); + Fl_Button button(200,75,100,25,"&Choose file"); button.callback(pickfile); window.end(); window.show(argc, argv); - fl_file_chooser_callback(thecb); return Fl::run(); } // -// End of "$Id: file_chooser.cxx,v 1.4.2.3 2001/01/22 15:13:41 easysw Exp $". +// End of "$Id: file_chooser.cxx,v 1.4.2.3.2.1 2001/08/03 18:46:57 easysw Exp $". // -- cgit v1.2.3