home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 7 / Apprentice-Release7.iso / Source Code / C / Applications / Simple Slideshow / Prototypes.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-08-25  |  1.9 KB  |  78 lines  |  [TEXT/MPCC]

  1. /*************************************************************************************************
  2. *
  3. *
  4. *            MacZapp        -- a standard Mac application template. prototype header file
  5. *
  6. *
  7. *************************************************************************************************/
  8.  
  9. #define        kFileMenu        129
  10.  
  11. enum
  12. {
  13.     kItemChooseSlides = 1,
  14.     kItemOptions,
  15.     kItemGo = 4,
  16.     kItemStop,
  17.     kItemStartOver,
  18.     kItemQuit = 8
  19. };
  20.  
  21.  
  22. void    InitialiseTheApp(void);
  23. void    RunTheApp(void);
  24. void    QuitTheApp(void);
  25. void    CheckCanRun(void);
  26.  
  27. void    HandleTheEvent(EventRecord *theEvent);
  28. void    HandleMouseEvent(EventRecord *theEvent);
  29. void    HandleMenuSelection(long mSelect);
  30. void    HandleKeypress(WindowPtr theWindow,char keyChar);
  31.  
  32. void    OpenNewWindow(short windowResID);
  33. void    ClickTheWindow(WindowPtr theWindow,Point clickLocation);
  34. void    DrawTheWindow(WindowPtr theWindow);
  35.  
  36.  
  37.  
  38. Boolean        ChooseFolder(FSSpec* folderSpec);
  39. void        CopyPString(ConstStr255Param srcString,Str255 destString);
  40. void        ConcatPStrings(Str255 first,ConstStr255Param second);
  41.  
  42. void        StartSlideshow();
  43. void        RunSlideshow();
  44. void        StopSlideshow();
  45. void        ResetSlideshow();
  46. PicHandle    OpenPICT(short refNum);
  47. PicHandle    OpenJPEG(short refNum);
  48. PicHandle    OpenTIFF(short refNum);
  49. PicHandle    OpenGIF(short refNum);
  50. short        FSpCountFiles(FSSpec* aFolderSpec);
  51. void        SetUpNextSlideFile();
  52. void        OpenNextFile();
  53. void        DisplayPicture(PicHandle thePic);
  54. void        DisplayPictureOldWay(PicHandle thePic);
  55.  
  56. void        CentreRects(Rect *rect1,Rect *rect2);
  57. Boolean        DoOptionsDialog();
  58.  
  59. OSErr          ConvertFromJFIF(StringPtr name,short originalFile,PicHandle *thePicture);
  60. OSErr        ConvertTIFFToPICT(FSSpec *theFile,PicHandle *thePicture);
  61. OSErr        ConvertGIFtoPICT(FSSpec *theFile,PicHandle *thePicture);
  62.  
  63. void        RestorePrefs();
  64. void        SavePrefs();
  65.  
  66. void        DoAboutBox();
  67. void        SetSlideWindowSize(WindowPtr theWindow);
  68. void        DoOptions();
  69. void        SetUpRandomList();
  70.  
  71.  
  72.  
  73.  
  74. #define        Min(a,b)    ((a) < (b))? (a) : (b)
  75. #define        Max(a,b)    ((a) > (b))? (a) : (b)
  76.  
  77. #define        ABS(x)        ((x) < 0)? -(x) : (x)
  78.