Public Methods |
struct cDialog* | cDialog_ctor (struct cDialog *ptr_dialog, char *caption, char *text, long style, int edit_size, struct cWinApp *ptr_win_app) |
void | cDialog_dtor (struct cDialog *ptr_dialog, int memory_flag) |
void | cDialog_GetEditText (struct cDialog *ptr_dialog, char *ptr_buffer) |
void | cDialog_SetEditText (struct cDialog *ptr_dialog, char *text) |
void | cDialog_PlaySound (long number) |
bool | cDialog_proc (struct cDialog *ptr_dialog, struct Message *ptr_message) |
int | cDialog_ShowModal (struct cDialog *ptr_dialog) |
void | cDialog_Disconnect (struct cDialog *ptr_dialog) |
bool | cDialog_Select (struct cDialog *ptr_dialog) |
void | cDialog_update (struct cDialog *ptr_dialog) |
struct cClip* | cDialog_GetParent (struct cDialog *ptr_dialog) |
void | cDialog_Hide (struct cDialog *ptr_dialog) |
void | cDialog_Show (struct cDialog *ptr_dialog) |
void | cDialog_Disable (struct cDialog *ptr_dialog) |
void | cDialog_Enable (struct cDialog *ptr_dialog) |
void | cDialog_AddObj (struct cDialog *ptr_dialog, struct cObject *ptr_object, int x, int y) |
void | cDialog_InsObj (struct cDialog *ptr_dialog, struct cObject *ptr_object, int x, int y, int index) |
void | cDialog_RemObj (struct cClip *ptr_dialog, struct cObject *ptr_object) |
bool | cDialog_SelectFirst (struct cDialog *ptr_dialog) |
bool | cDialog_SelectPrev (struct cDialog *ptr_dialog, bool round) |
bool | cDialog_SelectNext (struct cDialog *ptr_dialog, bool round) |
void | cDialog_Scroll (struct cDialog *ptr_dialog, struct rect_t *rectangle) |
void | cDialog_Scroll_Ex (struct cDialog *ptr_dialog, int x, int y) |
void | cDialog_SendScroll (struct cDialog *ptr_dialog) |
int | cDialog_GetShifty (struct cDialog *ptr_dialog) |
int | cDialog_GetShiftx (struct cDialog *ptr_dialog) |
int | cDialog_GetCount (struct cDialog *ptr_dialog) |
struct cObject* | cDialog_get_by_index (struct cDialog *ptr_dialog, int index) |
int | cDialog_FindObj (struct cDialog *ptr_dialog, struct cObject *ptr_object) |
struct cObject* | cDialog_GetSelectedObject (struct cDialog *ptr_dialog) |
This is a common dialog structure. You can create a various types of dialog windows using the third parameter of the cDialog_ctor function.
Dialog styles are defined by combinations of constants of the "tDialogStyle" enumeration (see the "Enumerations" page). For example, you can create a combination like this: "mbOk | mbCancel | mbEdit". This dialog box contains "Ok" and "Cancel" buttons, plus editing field that has been defined by the "mbEdit" parameter. In this case, both the cButton_GetEditText and cButton_SetEditText functions are enabled.
After creating a dialog box, you can show it (see cDialog_ShowModal), and then when a message comes in, you can process it by calling the cDialog_proc function.
You must call the cDialog_ctor function before use and the cDialog_dtor function after use.