home *** CD-ROM | disk | FTP | other *** search
/ MACD 4 / MACD4.iso / Emulatory / AROS / intuition / modifyprop.c < prev    next >
Encoding:
C/C++ Source or Header  |  1978-03-06  |  2.6 KB  |  103 lines

  1. /*
  2.     (C) 1995-96 AROS - The Amiga Replacement OS
  3.     $Id: modifyprop.c,v 1.3 1996/11/08 11:28:03 aros Exp $
  4.     $Log: modifyprop.c,v $
  5.     Revision 1.3  1996/11/08 11:28:03  aros
  6.     All OS function use now Amiga types
  7.  
  8.     Moved intuition-driver protos to intuition_intern.h
  9.  
  10.     Revision 1.2  1996/10/24 15:51:22  aros
  11.     Use the official AROS macros over the __AROS versions.
  12.  
  13.     Revision 1.1  1996/08/28 17:55:35  digulla
  14.     Proportional gadgets
  15.     BOOPSI
  16.  
  17.  
  18.     Desc:
  19.     Lang: english
  20. */
  21. #include "intuition_intern.h"
  22.  
  23. /*****************************************************************************
  24.  
  25.     NAME */
  26.     #include <intuition/intuition.h>
  27.     #include <clib/intuition_protos.h>
  28.  
  29.     AROS_LH8(void, ModifyProp,
  30.  
  31. /*  SYNOPSIS */
  32.     AROS_LHA(struct Gadget    *, gadget, A0),
  33.     AROS_LHA(struct Window    *, window, A1),
  34.     AROS_LHA(struct Requester *, requester, A2),
  35.     AROS_LHA(ULONG             , flags, D0),
  36.     AROS_LHA(ULONG             , horizPot, D1),
  37.     AROS_LHA(ULONG             , vertPot, D2),
  38.     AROS_LHA(ULONG             , horizBody, D3),
  39.     AROS_LHA(ULONG             , vertBody, D4),
  40.  
  41. /*  LOCATION */
  42.     struct IntuitionBase *, IntuitionBase, 26, Intuition)
  43.  
  44. /*  FUNCTION
  45.     Changes the values in the PropInfo-structure of a proportional
  46.     gadget and refreshes the display.
  47.  
  48.     INPUTS
  49.     gadget - Must be a PROPGADGET
  50.     window - The window which contains the gadget
  51.     requester - If the gadget has GTYP_REQGADGET set, this must be
  52.         non-NULL.
  53.     flags - New flags
  54.     horizPot - New value for the HorizPot field of the PropInfo
  55.     vertPot - New value for the VertPot field of the PropInfo
  56.     horizBody - New value for the HorizBody field of the PropInfo
  57.     vertBody - New value for the VertBody field of the PropInfo
  58.  
  59.     RESULT
  60.     None.
  61.  
  62.     NOTES
  63.     This function causes all gadgets from this gadget to the end of
  64.     the gadget list to be refreshed. If you want a better behaviour,
  65.     use NewModifProp().
  66.  
  67.     EXAMPLE
  68.  
  69.     BUGS
  70.  
  71.     SEE ALSO
  72.     NewModifyProp()
  73.  
  74.     INTERNALS
  75.  
  76.     HISTORY
  77.     29-10-95    digulla automatically created from
  78.                 intuition_lib.fd and clib/intuition_protos.h
  79.  
  80. *****************************************************************************/
  81. {
  82.     AROS_LIBFUNC_INIT
  83.     AROS_LIBBASE_EXT_DECL(struct IntuitionBase *,IntuitionBase)
  84.     struct PropInfo * pi;
  85.  
  86.     if ((gadget->GadgetType & GTYP_GTYPEMASK) != GTYP_PROPGADGET
  87.     || !gadget->SpecialInfo
  88.     )
  89.     return;
  90.  
  91.     pi = gadget->SpecialInfo;
  92.  
  93.     pi->Flags = flags;
  94.     pi->HorizPot = horizPot;
  95.     pi->VertPot = vertPot;
  96.     pi->HorizBody = horizBody;
  97.     pi->VertBody = vertBody;
  98.  
  99.     RefreshGadgets (gadget, window, requester);
  100.  
  101.     AROS_LIBFUNC_EXIT
  102. } /* ModifyProp */
  103.