GEMLIB
0.44.0
|
standard file selector More...
Macros | |
#define | fsel_exinput(a, b, c, d) mt_fsel_exinput(a,b,c,d,aes_global) |
#define | fsel_input(a, b, c) mt_fsel_input(a,b,c,aes_global) |
#define | fsel_boxinput(a, b, c, d, e) mt_fsel_exinput(a,b,c,d,e,aes_global) |
Typedefs | |
typedef void __CDECL(* | FSEL_CALLBACK) (short *msg) |
Functions | |
short | mt_fsel_exinput (char *path, char *file, short *exit_button, const char *title, short *global) |
short | mt_fsel_input (char *path, char *file, short *exit_button, short *global) |
short | mt_fsel_boxinput (char *path, char *file, short *exit_button, const char *title, FSEL_CALLBACK callback, short *global) |
standard file selector
The File Selector Library contains two functions for displaying the system file selector (or currently installed alternate file selector) and prompting the user to select a file.
#define fsel_boxinput | ( | a, | |
b, | |||
c, | |||
d, | |||
e | |||
) | mt_fsel_exinput(a,b,c,d,e,aes_global) |
single-thread version of mt_fsel_exinput()
#define fsel_exinput | ( | a, | |
b, | |||
c, | |||
d | |||
) | mt_fsel_exinput(a,b,c,d,aes_global) |
single-thread version of mt_fsel_exinput()
#define fsel_input | ( | a, | |
b, | |||
c | |||
) | mt_fsel_input(a,b,c,aes_global) |
single-thread version of mt_fsel_input()
typedef void __CDECL(* FSEL_CALLBACK) (short *msg) |
callback function used by BoxKite file selector. See mt_fsel_boxinput()
short mt_fsel_boxinput | ( | char * | path, |
char * | file, | ||
short * | exit_button, | ||
const char * | label, | ||
FSEL_CALLBACK | callback, | ||
short * | global_aes | ||
) |
displays the extended file selector and allows the user to select a valid GEMDOS path and file.
path | see mt_fsel_exinput() |
file | see mt_fsel_exinput() |
exit_button | see mt_fsel_exinput() [option CHECK_NULLPTR] exit_button may be NULL |
label | see mt_fsel_exinput() |
callback | is a pointer to a callback function. This callback function will be called by BoxKite when it received an AES message for the main application. It does not only concern the Message WM_REDRAW and WM_MOVED. Other messages are ignored. |
global_aes | global AES array |
short mt_fsel_exinput | ( | char * | path, |
char * | file, | ||
short * | exit_button, | ||
const char * | title, | ||
short * | global_aes | ||
) |
displays the system file selector and offers the user an opportunity to choose a complete GEMDOS path specification.
path | should be a pointer to a character buffer at least 260 bytes long. On input the buffer should contain a complete GEMDOS path specification including a drive specifier, path string, and wildcard mask as follows: 'drive:\path\mask'. The mask can be any valid GEMDOS wildcard (usually *.*). On function exit, path contains final path of the selected file (you will have to strip the mask) |
file | should point to a character buffer 13 bytes long (12 character filename plus NULL), or 260 bytes long if the application runs in MiNT domain (see Pdomain GEMDOS call). On input its contents will be placed on the filename line of the selector (usually this value can simply be a empty string). On function exit, file contains the filename which the user selected. |
exit_button | is a short pointer which upon function exit will contain FSEL_CANCEL (0) if the user selected CANCEL or FSEL_OK (1) if OK. [option CHECK_NULLPTR] exit_button may be NULL |
title | should be a pointer to a character string up to 30 characters long which contains the title to appear in the file selector (usually indicates which action the user is about to take). |
global_aes | global AES array |
The path parameter to this function should be validated to ensure that the path actually exists prior to calling this function to prevent confusing the user.
This call should always be used as opposed to mt_fsel_input() when it is available (ie always with this lib). Otherwise, the user has no reminder as to what function s/he is actually undertaking.
References mt_fsel_input().
short mt_fsel_input | ( | char * | path, |
char * | file, | ||
short * | exit_button, | ||
short * | global_aes | ||
) |
displays the system file selector and allows the user to select a valid GEMDOS path and file.
path | see mt_fsel_exinput() |
file | see mt_fsel_exinput() |
exit_button | see mt_fsel_exinput() [option CHECK_NULLPTR] exit_button may be NULL |
global_aes | global AES array |
Referenced by mt_fsel_exinput().