home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 April: Mac OS SDK / Dev.CD Apr 97 SDK1.toast / Development Kits (Disc 1) / Apple Shared Library Manager / ASLM Examples / Sample INIT / Sources / ShowINITLibrary.c < prev    next >
Encoding:
C/C++ Source or Header  |  1996-11-19  |  961 b   |  35 lines  |  [TEXT/MPS ]

  1. /*
  2.     File:        ShowINITLibrary.c
  3.  
  4.     Contains:    Implementation of ShowINITLibrary.
  5.  
  6.     Copyright:    © 1993 by Apple Computer, Inc., all rights reserved.
  7.  
  8. */
  9.  
  10.  
  11. #include <LibraryManager.h>
  12. #include <LibraryManagerUtilities.h>
  13.  
  14. #include "ShowINITLibrary.h"
  15.  
  16. extern pascal void ShowINIT( short, short );
  17.  
  18. /*————————————————————————————————————————————————————————————————————————————————————
  19.     ShowInit
  20.     
  21.     Calls the famous ShowINIT by Paul Mercer, to display INIT's ICON.
  22. ————————————————————————————————————————————————————————————————————————————————————*/
  23.  
  24. void    ShowInit( short iconID )
  25. {
  26.      GlobalWorld a5world = GetCurrentGlobalWorld();     // save a5 world since ShowINIT trashes it 
  27.     ShowINIT( iconID, -1 );
  28.     SetCurrentGlobalWorld(a5world);        // restore to our previous a5 world
  29.  
  30.     // We do an UnloadLibraries now to offset the LoadLibraries(false,true) that
  31.     // was done because we set the stayLoaded flag. Otherwise the library will
  32.     // never unload.
  33.     UnloadLibraries();    
  34. }
  35.