CelestialSphereAppUi.h 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. /*
  2. ============================================================================
  3. Name : CelestialSphereAppUi.h
  4. Author : Den Grigorenko
  5. Copyright : Copyright (c) 2008 Den123
  6. Description : Declares UI class for application.
  7. ============================================================================
  8. */
  9. #ifndef __CELESTIALSPHEREAPPUI_h__
  10. #define __CELESTIALSPHEREAPPUI_h__
  11. // INCLUDES
  12. #include <aknappui.h>
  13. #include "PosReader.h"
  14. #include "SimpleTimer.h"
  15. // FORWARD DECLARATIONS
  16. class CCelestialSphereAppView;
  17. // CLASS DECLARATION
  18. /**
  19. * CCelestialSphereAppUi application UI class.
  20. * Interacts with the user through the UI and request message processing
  21. * from the handler class
  22. */
  23. class CCelestialSphereAppUi : public CAknAppUi,
  24. public MPositionReaderObserver,
  25. public MSimpleTimerNotify
  26. {
  27. public:
  28. // Constructors and destructor
  29. /**
  30. * ConstructL.
  31. * 2nd phase constructor.
  32. */
  33. void ConstructL();
  34. /**
  35. * CCelestialSphereAppUi.
  36. * C++ default constructor. This needs to be public due to
  37. * the way the framework constructs the AppUi
  38. */
  39. CCelestialSphereAppUi();
  40. /**
  41. * ~CCelestialSphereAppUi.
  42. * Virtual Destructor.
  43. */
  44. virtual ~CCelestialSphereAppUi();
  45. public: // from MPositionReaderObserver
  46. void ReadingComplete( TPositionInfoBase& aPosInfo );
  47. void ReadingError( TInt aErrorNo );
  48. public: // MSimpleTimerNotify
  49. void TimerExpired( TAny* aTimer,TInt aError );
  50. private:
  51. // Functions from base classes
  52. /**
  53. * From CEikAppUi, HandleCommandL.
  54. * Takes care of command handling.
  55. * @param aCommand Command to be handled.
  56. */
  57. void HandleCommandL(TInt aCommand);
  58. /**
  59. * HandleStatusPaneSizeChange.
  60. * Called by the framework when the application status pane
  61. * size is changed.
  62. */
  63. void HandleStatusPaneSizeChange();
  64. void HandleResourceChangeL(TInt aType);
  65. void HandleForegroundEventL( TBool aForeground );
  66. private:
  67. // Data
  68. /**
  69. * The application view
  70. * Owned by CCelestialSphereAppUi
  71. */
  72. CCelestialSphereAppView* iAppView;
  73. private:
  74. TBool iInBackground;
  75. CPositionReader* iReader;
  76. CSimpleTimer* iTimer;
  77. };
  78. #endif // __CELESTIALSPHEREAPPUI_h__
  79. // End of File