home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / sys / amiga / programm / 15525 < prev    next >
Encoding:
Text File  |  1992-11-08  |  2.0 KB  |  52 lines

  1. Newsgroups: comp.sys.amiga.programmer
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!cs.utexas.edu!torn!nott!cu23.crl.aecl.ca!wl.aecl.ca!taylorm
  3. From: taylorm@wl.aecl.ca
  4. Subject: RE: Listview slider problem (Code included)
  5. Message-ID: <7NOV92.19133372@wl.aecl.ca>
  6. Sender: news@cu23.crl.aecl.ca (USENET News System)
  7. Nntp-Posting-Host: wc4.wl.aecl.ca
  8. Organization: AECL RESEARCH
  9. References:  <7NOV92.13340477@wl.aecl.ca> <mbs.1a46@adastra.cvl.va.us>
  10. Date: Sun, 8 Nov 1992 01:13:33 GMT
  11. Lines: 39
  12.  
  13.  
  14. I wrote:
  15. >>              (imsg = GT_GetIMsg(calcwin->UserPort)))
  16. >>          {
  17. >>          gad = (struct Gadget *)imsg->IAddress;
  18. >>
  19.  
  20. mbs@adastra.cvl.va.us (Michael B. Smith) writes:
  21. > NO! This isn't your bug, but NEVER EVER do this, unless you know that
  22. > imsg->Class is IDCMP_GADGETUP or IDCMP_GADGETDOWN. It isn't a gadget
  23. > unless the Class is for one of those two.
  24.  
  25. The pointer only gets deferenced if the imsg->Class is a IDCMP_GADGETUP or
  26. IDCMP_GADGETDOWN.  I realize that this my not be the best style, but it
  27. is based on an example in the Amiga Rom Kernal Libraries manual (p409).
  28.  
  29. The 'C' language lets you get away with murder, and the victim is usually
  30. yourself.
  31.  
  32. >>                        WA_DetailPen,     -1,
  33. >>                        WA_BlockPen,      -1,
  34.  
  35. > THIS is your problem. I personally would suggest:
  36. >                        WA_DetailPen,   0,
  37. >                        WA_BlockPen,    1,
  38.  
  39. Correct you are.  Strangely, one of the examples I was studying sets the 
  40. pens to -1 as I did, the difference being that his worked.  
  41.  
  42. Oh well, thank you very much.  My sanity, whatever it is worth, is once
  43. again intact.
  44.  
  45. *****************************************************************************
  46.   In search of the virtual world       *             /\/\ike Taylor
  47.                                        * mataylor@undergrad.math.uwaterloo.ca
  48.     Sometimes real is too real         *          taylorm@wl.aecl.ca
  49. *****************************************************************************
  50.