home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / yacl-012.zip / ui / stddlg.h < prev    next >
C/C++ Source or Header  |  1995-03-28  |  2KB  |  81 lines

  1.  
  2.  
  3. #ifndef _stddlg_h_ /* Tue Jan  4 14:59:57 1994 */
  4. #define _stddlg_h_
  5.  
  6.  
  7.  
  8.  
  9.  
  10. /*
  11.  *
  12.  *          Copyright (C) 1994, M. A. Sridhar
  13.  *  
  14.  *
  15.  *     This software is Copyright M. A. Sridhar, 1994. You are free
  16.  *     to copy, modify or distribute this software  as you see fit,
  17.  *     and to use  it  for  any  purpose, provided   this copyright
  18.  *     notice and the following   disclaimer are included  with all
  19.  *     copies.
  20.  *
  21.  *                        DISCLAIMER
  22.  *
  23.  *     The author makes no warranties, either expressed or implied,
  24.  *     with respect  to  this  software, its  quality, performance,
  25.  *     merchantability, or fitness for any particular purpose. This
  26.  *     software is distributed  AS IS.  The  user of this  software
  27.  *     assumes all risks  as to its quality  and performance. In no
  28.  *     event shall the author be liable for any direct, indirect or
  29.  *     consequential damages, even if the  author has been  advised
  30.  *     as to the possibility of such damages.
  31.  *
  32.  */
  33.  
  34.  
  35.  
  36.  
  37.  
  38. // This header file defines functions for ``standard'' dialogs  for yes/no
  39. // and informational message boxes and for file selection.
  40.  
  41. #if defined(__GNUC__)
  42. #pragma interface
  43. #endif
  44.  
  45.  
  46. #include "ui/visualob.h"
  47.  
  48.  
  49. // ---------------- Simple question or info dialog -------------------
  50.  
  51.  
  52. // Dialog styles:
  53. enum UI_SimpleDialogStyle {
  54.     UIS_Ok, UIS_OkCancel, UIS_YesNo, UIS_YesNoCancel
  55. };
  56.  
  57.  
  58. // Dialog icon styles:
  59. enum UI_SimpleDialogIconStyle {
  60.     UIS_Information, UIS_Warning, UIS_Error, UIS_Question
  61. };
  62.  
  63. UI_ViewID UI_SimpleDialog (const char* message,
  64.                            const char* box_title = "",
  65.                            UI_VisualObject* parent = NULL,
  66.                            UI_SimpleDialogStyle style = UIS_Ok,
  67.                            UI_SimpleDialogIconStyle icon = UIS_Information);
  68. // Show the specified kind of dialog, and return the id of the button
  69. // clicked on.
  70.  
  71.  
  72. // ---------------------- Open file dialog ----------------------------
  73.  
  74. CL_String UI_FileSelectDialog (UI_VisualObject* parent,
  75.                                const char* box_title = "Open file");
  76. // Show the platform's file-open dialog, and return the chosen file name.
  77. // Return the null string if canceled.
  78.  
  79.  
  80. #endif /* _simpldlg_h_ */
  81.