home *** CD-ROM | disk | FTP | other *** search
/ Frozen Fish 1: Amiga / FrozenFish-Apr94.iso / bbs / alib / d5xx / d541 / gifmachine.lha / GIFMachine / Sources / warncli.c < prev    next >
C/C++ Source or Header  |  1991-09-17  |  2KB  |  57 lines

  1. /* Copyright 1990 by Christopher A. Wichura.
  2.    See file GIFMachine.doc for full description of rights.
  3. */
  4.  
  5. #include <exec/types.h>
  6. #include <intuition/intuition.h>
  7. #include <graphics/text.h>
  8.  
  9. #include <clib/exec_protos.h>
  10. #include <pragmas/exec_lib.h>
  11.  
  12. #include <clib/intuition_protos.h>
  13. extern struct IntuitionBase *IntuitionBase;
  14. #include <pragmas/intuition_lib.h>
  15.  
  16. static struct TextAttr TOPAZ60 = {"topaz.font", TOPAZ_SIXTY,
  17.     FS_NORMAL, FPF_ROMFONT};
  18.  
  19. static struct IntuiText BodyText2 = {-1, -1,    /* pen numbers */
  20.                              0,             /* draw mode */
  21.                              9,14,          /* starting offsets */
  22.                              &TOPAZ60,      /* text attribute pointer */
  23.                              "for CLI use only!",
  24.                              NULL };
  25.  
  26. static struct IntuiText BodyText1 = {-1,-1,      /* pen numbers */
  27.                              0,             /* draw mode */
  28.                              29,4,          /* starting offsets */
  29.                              &TOPAZ60,      /* text attribute pointer */
  30.                              "GIFMachine is",
  31.                              &BodyText2 };
  32.  
  33. static struct IntuiText ContinueText = {-1,-1,  /* pen numbers */
  34.                              0,             /* draw mode */
  35.                              4,4,           /* starting offsets */
  36.                              &TOPAZ60,      /* text attribute pointer */
  37.                              "CONTINUE",
  38.                              NULL };
  39.  
  40. void WarnMustUseCLI(void)
  41. {
  42.     BOOL    OpenedIntui;
  43.  
  44.     if (IntuitionBase)
  45.         OpenedIntui = FALSE;
  46.     else {
  47.         if (!(IntuitionBase = OpenLibrary("intuition.library", 0)))
  48.             return;
  49.         OpenedIntui = TRUE;
  50.     }
  51.  
  52.     AutoRequest(NULL,&BodyText1,NULL,&ContinueText,0,0,220,64);
  53.  
  54.     if (OpenedIntui)
  55.         CloseLibrary(IntuitionBase);
  56. }
  57.