home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 5 / FreshFish_July-August1994.bin / bbs / util / superdark-2.0a.lha / SuperDark-2.0a / programmer / includes / tom_gadget.h < prev   
Encoding:
C/C++ Source or Header  |  1993-06-18  |  1.3 KB  |  62 lines

  1. #define    MAX_GADGET    50    /* Max number of gadget in a Window */
  2.  
  3. #define GD_ok                                  0
  4. #define GD_test                                1
  5. #define GD_cancel                              2
  6. #define GD_info                                3
  7.  
  8. #define GD_first                               4
  9.  
  10. typedef    enum{
  11.     END_LISTE,    /* This is to signal the end of the dark gadget list*/
  12.     BUTTON,        /* A simple button gadget                */
  13.     SLIDER,
  14.     CHECKBOX,
  15.     MX,
  16.     LISTVIEW,
  17.     OWN_GADGET,
  18.     CYCLE,
  19.     STRING,
  20.     INTEGER,
  21.     SCREEN,            /* A button to choose screen resolution */
  22.     DATA_STRING,        /* Data not show, only for saving    */
  23.     IMAGE,            /* It's to show an image structure     */
  24.     FONT,            /* A button to choose a font        */
  25.     INV_CHECKBOX        /* Like a checkbox, but not show on screen */
  26.  
  27. }type_gadget;
  28.  
  29. #define    HORIZ    1
  30. #define    VERT    2
  31.     
  32. typedef    struct    own_init{
  33.     struct    Gadget    (*own_add)();
  34.     void    (*own_press)();
  35.     void    (*own_end)();
  36. };
  37.  
  38. typedef    struct    tom_gadget{
  39.     char    *GadgetText;
  40.     type_gadget    type_gadg;
  41.     short    int    LeftEdge,TopEdge;
  42.     short    int    Width,Height;
  43.     short    int    value;
  44.     short    int    d1,d2,d3;
  45.     char    *p_data;
  46.     struct    Gadget    *p_gadg;
  47.  
  48. };
  49.  
  50. typedef    struct    contexe{
  51.     struct    tom_gadget    *t_g;
  52.     struct    Window    *Wnd;
  53.     APTR        Visual;
  54.     struct Gadget        *GList;
  55.     int        flg_end;
  56.     int        flg_save;
  57.     char    *p_name;
  58. };
  59.  
  60. int    find_res(USHORT flg_depth,SHORT *p_depth,SHORT *p_tx,SHORT *p_ty,ULONG *p_d_id);
  61.  
  62.