2001-08-02 20:17:04 +04:00
|
|
|
// generated by Fast Light User Interface Designer (fluid) version 1.0100
|
2001-08-02 01:24:49 +04:00
|
|
|
|
2001-09-29 18:38:59 +04:00
|
|
|
#ifndef Fl_File_Chooser_H
|
|
|
|
#define Fl_File_Chooser_H
|
2001-08-02 01:24:49 +04:00
|
|
|
#include <FL/Fl.H>
|
|
|
|
#include <FL/Fl_Window.H>
|
|
|
|
#include <stdio.h>
|
|
|
|
#include <stdlib.h>
|
|
|
|
#include <string.h>
|
2001-09-29 18:38:59 +04:00
|
|
|
#include <FL/Fl_File_Browser.H>
|
2001-08-02 20:17:04 +04:00
|
|
|
#include <FL/Fl_Button.H>
|
2001-08-02 01:24:49 +04:00
|
|
|
#include <FL/Fl_Return_Button.H>
|
2001-08-03 22:46:57 +04:00
|
|
|
#include <FL/fl_ask.H>
|
2001-08-02 20:17:04 +04:00
|
|
|
#include <FL/Fl_Input.H>
|
|
|
|
#include <FL/Fl_Choice.H>
|
2001-08-02 01:24:49 +04:00
|
|
|
|
2001-09-29 18:38:59 +04:00
|
|
|
class Fl_File_Chooser {
|
2001-08-02 01:24:49 +04:00
|
|
|
public:
|
2001-09-29 18:38:59 +04:00
|
|
|
enum { SINGLE = 0, MULTI = 1, CREATE = 2, DIRECTORY = 4 };
|
|
|
|
Fl_File_Chooser(const char *d, const char *p, int t, const char *title);
|
2001-08-02 01:24:49 +04:00
|
|
|
private:
|
2001-08-02 20:17:04 +04:00
|
|
|
Fl_Window *window;
|
2001-08-02 01:24:49 +04:00
|
|
|
inline void cb_window_i(Fl_Window*, void*);
|
|
|
|
static void cb_window(Fl_Window*, void*);
|
2001-09-29 18:38:59 +04:00
|
|
|
Fl_File_Browser *fileList;
|
|
|
|
inline void cb_fileList_i(Fl_File_Browser*, void*);
|
|
|
|
static void cb_fileList(Fl_File_Browser*, void*);
|
2001-08-02 20:17:04 +04:00
|
|
|
inline void cb_Cancel_i(Fl_Button*, void*);
|
|
|
|
static void cb_Cancel(Fl_Button*, void*);
|
2001-08-02 01:24:49 +04:00
|
|
|
Fl_Return_Button *okButton;
|
|
|
|
inline void cb_okButton_i(Fl_Return_Button*, void*);
|
|
|
|
static void cb_okButton(Fl_Return_Button*, void*);
|
2001-08-02 20:17:04 +04:00
|
|
|
Fl_Input *fileName;
|
|
|
|
inline void cb_fileName_i(Fl_Input*, void*);
|
|
|
|
static void cb_fileName(Fl_Input*, void*);
|
|
|
|
Fl_Button *upButton;
|
|
|
|
inline void cb_upButton_i(Fl_Button*, void*);
|
|
|
|
static void cb_upButton(Fl_Button*, void*);
|
|
|
|
Fl_Button *newButton;
|
|
|
|
inline void cb_newButton_i(Fl_Button*, void*);
|
|
|
|
static void cb_newButton(Fl_Button*, void*);
|
|
|
|
Fl_Choice *dirMenu;
|
|
|
|
inline void cb_dirMenu_i(Fl_Choice*, void*);
|
|
|
|
static void cb_dirMenu(Fl_Choice*, void*);
|
2001-09-29 10:40:06 +04:00
|
|
|
inline void cb__i(Fl_Button*, void*);
|
|
|
|
static void cb_(Fl_Button*, void*);
|
2001-09-29 18:38:59 +04:00
|
|
|
void (*callback_)(Fl_File_Chooser*, void *);
|
2001-08-04 16:21:34 +04:00
|
|
|
void *data_;
|
2001-08-02 01:24:49 +04:00
|
|
|
char directory_[1024];
|
|
|
|
int type_;
|
|
|
|
void fileListCB();
|
|
|
|
void fileNameCB();
|
|
|
|
void newdir();
|
|
|
|
void up();
|
|
|
|
public:
|
2001-09-29 18:38:59 +04:00
|
|
|
void callback(void (*cb)(Fl_File_Chooser *, void *), void *d);
|
2001-08-02 01:24:49 +04:00
|
|
|
void color(Fl_Color c);
|
|
|
|
Fl_Color color();
|
|
|
|
int count();
|
|
|
|
void directory(const char *d);
|
|
|
|
char * directory();
|
|
|
|
void filter(const char *p);
|
|
|
|
const char * filter();
|
|
|
|
void hide();
|
|
|
|
void iconsize(uchar s);
|
|
|
|
uchar iconsize();
|
|
|
|
void label(const char *l);
|
|
|
|
const char * label();
|
|
|
|
void rescan();
|
2001-08-02 20:17:04 +04:00
|
|
|
void show();
|
2001-08-02 01:24:49 +04:00
|
|
|
void textcolor(Fl_Color c);
|
|
|
|
Fl_Color textcolor();
|
2001-08-02 20:17:04 +04:00
|
|
|
void textfont(uchar f);
|
|
|
|
uchar textfont();
|
2001-08-02 01:24:49 +04:00
|
|
|
void textsize(uchar s);
|
|
|
|
uchar textsize();
|
|
|
|
void type(int t);
|
|
|
|
int type();
|
|
|
|
const char *value(int f = 1);
|
|
|
|
void value(const char *filename);
|
|
|
|
int visible();
|
|
|
|
};
|
2001-09-30 21:37:06 +04:00
|
|
|
extern FL_EXPORT char *fl_dir_chooser(const char *message,const char *fname);
|
|
|
|
extern FL_EXPORT char *fl_file_chooser(const char *message,const char *pat,const char *fname);
|
|
|
|
extern FL_EXPORT void fl_file_chooser_callback(void (*cb)(const char*));
|
2001-08-02 01:24:49 +04:00
|
|
|
#endif
|