| 1 |
/* File : Fl_File_Chooser.i */ |
| 2 |
//%module Fl_File_Chooser |
| 3 |
|
| 4 |
%feature("docstring") ::Fl_File_Chooser |
| 5 |
""" |
| 6 |
The Fl_File_Chooser widget displays a standard file selection dialog that |
| 7 |
supports various selection modes. |
| 8 |
|
| 9 |
The Fl_File_Chooser class also exports several static values that may be used |
| 10 |
to localize or customize the appearance of all file chooser dialogs: |
| 11 |
Member Default value |
| 12 |
add_favorites_label 'Add to Favorites' |
| 13 |
all_files_label 'All Files (*)' |
| 14 |
custom_filter_label 'Custom Filter' |
| 15 |
existing_file_label 'Please choose an existing file!' |
| 16 |
favorites_label 'Favorites' |
| 17 |
filename_label 'Filename:' |
| 18 |
filesystems_label 'My Computer' (WIN32) |
| 19 |
'File Systems' (all others) |
| 20 |
manage_favorites_label 'Manage Favorites' |
| 21 |
new_directory_label 'New Directory?' |
| 22 |
new_directory_tooltip 'Create a new directory.' |
| 23 |
preview_label 'Preview' |
| 24 |
save_label 'Save' |
| 25 |
show_label 'Show:' |
| 26 |
sort fl_numericsort |
| 27 |
|
| 28 |
The sort member specifies the sort function that is used when loading the |
| 29 |
contents of a directory. |
| 30 |
""" ; |
| 31 |
|
| 32 |
%{ |
| 33 |
#include "FL/Fl_File_Chooser.H" |
| 34 |
%} |
| 35 |
|
| 36 |
%include "macros.i" |
| 37 |
//CHANGE_OWNERSHIP(Fl_File_Chooser) |
| 38 |
|
| 39 |
%ignore Fl_File_Chooser::sort; |
| 40 |
// this is not declared on all systems! |
| 41 |
%ignore Fl_File_Chooser::rescan_keep_filename; |
| 42 |
|
| 43 |
DEFINE_CALLBACK(Fl_File_Chooser) |
| 44 |
|
| 45 |
%ignore Fl_File_Chooser::user_data(void *); |
| 46 |
%ignore Fl_File_Chooser::user_data() const; |
| 47 |
|
| 48 |
%include "FL/Fl_File_Chooser.H" |
| 49 |
|
| 50 |
ADD_CALLBACK(Fl_File_Chooser) |
| 51 |
ADD_USERDATA(Fl_File_Chooser) |
| 52 |
|
| 53 |
%typemap(in) PyObject *PyFunc { |
| 54 |
if (!PyCallable_Check($input)) { |
| 55 |
PyErr_SetString(PyExc_TypeError, "Need a callable object!"); |
| 56 |
return NULL; |
| 57 |
} |
| 58 |
$1 = $input; |
| 59 |
} |
| 60 |
|