summaryrefslogtreecommitdiff
path: root/src/Fl_Native_File_Chooser_FLTK.cxx
diff options
context:
space:
mode:
authorGreg Ercolano <erco@seriss.com>2010-01-17 17:09:00 +0000
committerGreg Ercolano <erco@seriss.com>2010-01-17 17:09:00 +0000
commit97ac940d919dd35dd32cee2c04b28f65aba4d9ad (patch)
treedda1ca58af2d1a3df91f98fb872a74c385956e09 /src/Fl_Native_File_Chooser_FLTK.cxx
parent7221382917ce840ecf37e9102445e5191dcff08d (diff)
Small indent / whitespace fixups, Manolo's doc modification for
Fl_Native_File_Chooser::options. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7015 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Native_File_Chooser_FLTK.cxx')
-rw-r--r--src/Fl_Native_File_Chooser_FLTK.cxx62
1 files changed, 31 insertions, 31 deletions
diff --git a/src/Fl_Native_File_Chooser_FLTK.cxx b/src/Fl_Native_File_Chooser_FLTK.cxx
index ee75d0ebf..2d5753260 100644
--- a/src/Fl_Native_File_Chooser_FLTK.cxx
+++ b/src/Fl_Native_File_Chooser_FLTK.cxx
@@ -62,7 +62,7 @@ Fl_Native_File_Chooser::Fl_Native_File_Chooser(int val) {
_directory = NULL;
_errmsg = NULL;
_file_chooser = new Fl_File_Chooser(NULL, NULL, 0, NULL);
- type(val); // do this after _file_chooser created
+ type(val); // do this after _file_chooser created
_nfilters = 0;
// Added by MG
@@ -142,7 +142,7 @@ int Fl_Native_File_Chooser::type() const {
-------------- ----------------------------------------------- ------- ------- -------
NEW_FOLDER Shows the 'New Folder' button. Ignored Used Used
PREVIEW Enables the 'Preview' mode by default. Ignored Ignored Used
- SAVEAS_CONFIRM Confirm dialog if BROWSE_SAVE_FILE file exists. Ignored Used Ignored
+ SAVEAS_CONFIRM Confirm dialog if BROWSE_SAVE_FILE file exists. Ignored Used Used
\endcode
*/
void Fl_Native_File_Chooser::options(int val) {
@@ -258,10 +258,10 @@ const char* Fl_Native_File_Chooser::filename() const {
\b Example:
\code
if ( fnfc->show() == 0 ) {
- // Print all filenames user selected
- for (int n=0; n<fnfc->count(); n++ ) {
- printf("%d) '%s'\n", n, fnfc->filename(n));
- }
+ // Print all filenames user selected
+ for (int n=0; n<fnfc->count(); n++ ) {
+ printf("%d) '%s'\n", n, fnfc->filename(n));
+ }
}
\endcode
*/
@@ -352,10 +352,10 @@ int Fl_Native_File_Chooser::filter_value() const {
\b Example:
\code
if ( fnfc->show() == 0 ) {
- // Print all filenames user selected
- for (int n=0; n<fnfc->count(); n++ ) {
- printf("%d) '%s'\n", n, fnfc->filename(n));
- }
+ // Print all filenames user selected
+ for (int n=0; n<fnfc->count(); n++ ) {
+ printf("%d) '%s'\n", n, fnfc->filename(n));
+ }
}
\endcode
*/
@@ -412,33 +412,33 @@ void Fl_Native_File_Chooser::parse_filter() {
switch (*in) {
// FINISHED PARSING NAME?
case '\t':
- if ( mode != 'n' ) goto regchar;
- mode = 'w';
- break;
+ if ( mode != 'n' ) goto regchar;
+ mode = 'w';
+ break;
// ESCAPE NEXT CHAR
case '\\':
- ++in;
- goto regchar;
+ ++in;
+ goto regchar;
// FINISHED PARSING ONE OF POSSIBLY SEVERAL FILTERS?
case '\r':
case '\n':
case '\0':
- // APPEND NEW FILTER TO LIST
- if ( wildcard[0] ) {
- // OUT: "name(wild)\tname(wild)"
- char comp[2048];
- sprintf(comp, "%s%.511s(%.511s)", ((_parsedfilt)?"\t":""),
- name, wildcard);
- _parsedfilt = strapp(_parsedfilt, comp);
- _nfilters++;
- //DEBUG printf("DEBUG: PARSED FILT NOW <%s>\n", _parsedfilt);
- }
- // RESET
- wildcard[0] = name[0] = '\0';
- mode = strchr(in, '\t') ? 'n' : 'w';
- // DONE?
- if ( *in == '\0' ) return; // done
- else continue; // not done yet, more filters
+ // APPEND NEW FILTER TO LIST
+ if ( wildcard[0] ) {
+ // OUT: "name(wild)\tname(wild)"
+ char comp[2048];
+ sprintf(comp, "%s%.511s(%.511s)", ((_parsedfilt)?"\t":""),
+ name, wildcard);
+ _parsedfilt = strapp(_parsedfilt, comp);
+ _nfilters++;
+ //DEBUG printf("DEBUG: PARSED FILT NOW <%s>\n", _parsedfilt);
+ }
+ // RESET
+ wildcard[0] = name[0] = '\0';
+ mode = strchr(in, '\t') ? 'n' : 'w';
+ // DONE?
+ if ( *in == '\0' ) return; // done
+ else continue; // not done yet, more filters
// Parse all other chars
default: // handle all non-special chars