home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 4 / Apprentice-Release4.iso / Source Code / C / Snippets / DialogControls 1.1.1 / MovableModal.c < prev    next >
Encoding:
Text File  |  1995-05-09  |  4.6 KB  |  33 lines  |  [TEXT/CWIE]

  1.  theWindow );
  2.     
  3.     theList = (*(WindowPeek)theWindow).controlList;
  4.     
  5.     while( theList != nil )
  6.     {
  7.         HiliteControl( theList, 255 );
  8.         theList = (**theList).nextControl;
  9.     }
  10.     
  11.     SetPort( thePort );
  12. }
  13.  
  14. /** When a window is activated, it should reactivate all of it's controls.
  15.     This function does that. **/
  16. void    DoMyActivate( WindowPtr theWindow )
  17. {
  18.     ControlHandle    theList;
  19.     GrafPtr            thePort;
  20.     
  21.     GetPort( &thePort );
  22.     SetPort( theWindow );
  23.     
  24.     theList = (*(WindowPeek)theWindow).controlList;
  25.     
  26.     while( theList != nil )
  27.     {
  28.         HiliteControl( theList, 0 );
  29.         theList = (**theList).nextControl;
  30.     }
  31.     
  32.     SetPort( thePort );
  33. }