home *** CD-ROM | disk | FTP | other *** search
/ PSION CD 2 / PsionCDVol2.iso / Programs / 720 / PDF090B4-SorceCode / pdf / activepage.h < prev    next >
Encoding:
C/C++ Source or Header  |  2000-09-30  |  1.4 KB  |  73 lines

  1. // ActivePage.h
  2. //
  3. // Copyright (c) 2000 Sander van der Wal. All rights reserved.
  4. //
  5. // $Id: activepage.h 1.1 2000-09-17 13:39:38+02 svdwal Exp svdwal $
  6.  
  7. #ifndef ACTIVEPAGE_H_
  8. #define ACTIVEPAGE_H_
  9.  
  10. // Parent
  11. #ifndef __E32BASE_H__
  12. #include <e32base.h>
  13. #endif
  14.  
  15. // --o PDF
  16. class PDFDoc;
  17. class OutputDev;
  18. class Gfx;
  19. #include "Object.h"
  20.  
  21.  
  22. //////////////////////////////////////////////////////////////////////////////
  23. //
  24. // MActivePageObserver
  25. //
  26. //////////////////////////////////////////////////////////////////////////////
  27. class MActivePageObserver
  28. {
  29. public:
  30.   virtual void NotifyPageFinishedL(TInt aError) = 0;
  31. };
  32.  
  33.  
  34. //////////////////////////////////////////////////////////////////////////////
  35. //
  36. // CActivePage
  37. //
  38. //////////////////////////////////////////////////////////////////////////////
  39. class CActivePage: public CActive
  40. {
  41. private:
  42.   CActivePage(TInt aPriority, MActivePageObserver* aObserver);
  43.   void ConstructL();
  44.  
  45. public:
  46.   static CActivePage* NewL(TInt aPriority, MActivePageObserver* aObserver);
  47.   ~CActivePage();
  48.  
  49. // --o CActive
  50. private:
  51.   void RunL();
  52.   void DoCancel();
  53.  
  54. // --o CActivePage
  55. public:
  56.   // Display a page asynchronously
  57.   void StartRenderingL(OutputDev *aOut, PDFDoc* aDoc, TInt aPage, int aDpi, int aRotate);
  58.  
  59. private:
  60.   void StopRendering();
  61.  
  62. private:
  63.   MActivePageObserver* iObserver;
  64.   
  65.   // global display state
  66.   Gfx*   iGfx;
  67.   Object iObj;
  68.   TInt   iNumCmds;
  69. };
  70.  
  71. #endif
  72.  
  73.