DESIGN (xvutils) functions
LIBRARY ROUTINE
xvu_save_wait - pop up a save message; wait for response
LIBRARY CALL
int xvu_save_wait(
char *string,
char *filename,
char *save_label,
char *discard_label,
char *cancel_label)
INPUT
- string - Optional string for first line of
label; if non-NULL, will replace
"Save Changes to"
- filename - Name of file to which changes will be
saved (subsequently, by the application).
- save_label - Optional label for button which returns
value of 2; if non-NULL, will replace label
of "Save" on first button
- discard_label - Optional label for button which returns
value of 1; if non-NULL, will replace label
of "Discard" on first button
- cancel_label - Optional label for button which returns
value of 0; if non-NULL, will replace label
of "Cancel" on first button
OUTPUT
none
RETURN VALUE
2 if user selected "Save" (first) button
1 if user selected "Discard" (second)
0 if user selected "Cancel" (third) button
DESCRIPTION
Creates and maps a pop-up save object which looks like:
-----------------------------------
| |
| Save Changes to {file}? |
| |
- - - - - - - - - - - - - - - - - -
| -------- ----------- ---------- |
| | Save | | Discard | | Cancel | |
| -------- ----------- ---------- |
-----------------------------------
This routine will block input to the application until
it is acknowledged by the user. The user must click on
"Save", "Discard" or "Cancel" before control will be
returned to the application program.
Note that this utility does *not* actually save
any changes to the file, or write to the file specified
in any way. It simply prompts the user and returns
a status depending on which button the user clicked.
ADDITIONAL INFORMATION
none
EXAMPLES
none
SIDE EFFECTS
none
RESTRICTIONS
none
MODIFICATION
none
FILES
$DESIGN/objects/library/xvutils/src/save.c
SEE ALSO
xvutils(3)
COPYRIGHT
Copyright (C) 1993 - 1997, Khoral Research, Inc. ("KRI") All rights reserved.