camerauis/cameraapp/generic/inc/CamAppController.h
branchRCL_3
changeset 31 8f559c47d7fd
parent 27 53c8aa5d97a3
child 35 e32fcfe0045f
equal deleted inserted replaced
27:53c8aa5d97a3 31:8f559c47d7fd
    56 #include "camcamerarequests.h"
    56 #include "camcamerarequests.h"
    57 #include "camfolderutility.h"
    57 #include "camfolderutility.h"
    58 #include "camcameracontroller.h"
    58 #include "camcameracontroller.h"
    59 #include "CamDriveChangeNotifier.h"
    59 #include "CamDriveChangeNotifier.h"
    60 #include "CamSyncRotatorAo.h"
    60 #include "CamSyncRotatorAo.h"
    61 
    61 #include "camtvaccessorymonitor.h"
    62 
    62 
    63 // ===========================================================================
    63 // ===========================================================================
    64 // CONSTANTS
    64 // CONSTANTS
    65 
    65 
    66 // !Do not change the order of these without careful consideration!
    66 // !Do not change the order of these without careful consideration!
    85   EBusySequence = 1<<1,
    85   EBusySequence = 1<<1,
    86   EBusySetting  = 1<<2,
    86   EBusySetting  = 1<<2,
    87   EBusyLast // Marker
    87   EBusyLast // Marker
    88   };
    88   };
    89 
    89 
       
    90 enum TCamHdmiEvent
       
    91     {
       
    92     ECamHdmiNoEvent,
       
    93     ECamHdmiCableConnectedBeforeRecording,
       
    94     ECamHdmiCableConnectedDuringRecording
       
    95     };
    90 
    96 
    91 // ===========================================================================
    97 // ===========================================================================
    92 // FORWARD DECLARATIONS
    98 // FORWARD DECLARATIONS
    93 class CRepository;
    99 class CRepository;
    94 //class CCamSettingsModelBase;
   100 //class CCamSettingsModelBase;
   163                           public MCamPlayerObserver,
   169                           public MCamPlayerObserver,
   164                           public MCamObserver,
   170                           public MCamObserver,
   165                           public MCamBurstModeObserver,
   171                           public MCamBurstModeObserver,
   166                           public MCFListener
   172                           public MCFListener
   167                           ,public MCamDriveChangeNotifierObserver
   173                           ,public MCamDriveChangeNotifierObserver
   168                           ,public MBitmapRotationObserver 
   174                           ,public MBitmapRotationObserver,
       
   175                           public MCamTvAccessoryObserver
   169                           
   176                           
   170     {
   177     {
   171     public:  // Constructors and destructor
   178     public:  // Constructors and destructor
   172         
   179         
   173         /**
   180         /**
   466     * From MBitmapRotationObserver
   473     * From MBitmapRotationObserver
   467     * Notification of bitmap rotation complete events
   474     * Notification of bitmap rotation complete events
   468     * @param aErr KErrNone if successful
   475     * @param aErr KErrNone if successful
   469     */
   476     */
   470     void RotationCompleteL( TInt aErr );
   477     void RotationCompleteL( TInt aErr );
   471 
   478     
       
   479     /**
       
   480     * From MCamTvaccessoryObserver
       
   481     * Handles TV Out/HDMI Cable connect Events
       
   482     */
       
   483     void HandleTvAccessoryConnectedL();
       
   484     
       
   485     /**
       
   486     * From MCamTvaccessoryObserver
       
   487     * Handles TV Out/HDMI Cable disconnect Events
       
   488     */
       
   489     void HandleTvAccessoryDisconnectedL();
       
   490     
       
   491     
       
   492     /**
       
   493      * Returns Etrue if HDMI Cable is connected
       
   494      */
       
   495     TBool IsHdmiCableConnected();
       
   496     
       
   497 
       
   498     /**
       
   499     * Called when exiting in secondary camera mode
       
   500     */
       
   501     void HandleSecondaryCameraExitL();
       
   502 	
   472 private:
   503 private:
   473     void ReadVariantFlagsL();
   504     void ReadVariantFlagsL();
   474 
   505 
   475 
   506 
   476     void SetMode( const TCamCameraMode& aNewMode );
   507     void SetMode( const TCamCameraMode& aNewMode );
  1529     * @param aError error code associated with new state (if any)
  1560     * @param aError error code associated with new state (if any)
  1530     */
  1561     */
  1531     void ChangeOperation( TCamCaptureOperation aNewOperation, 
  1562     void ChangeOperation( TCamCaptureOperation aNewOperation, 
  1532                           TInt          aError = KErrNone );
  1563                           TInt          aError = KErrNone );
  1533 
  1564 
       
  1565   public:
  1534     /**
  1566     /**
  1535     * Notify controller observers of an event.
  1567     * Notify controller observers of an event.
  1536     * @since 2.8
  1568     * @since 2.8
  1537     * @param aEvent event code
  1569     * @param aEvent event code
  1538     * @param aError error code
  1570     * @param aError error code
  1539     */
  1571     */
  1540     void NotifyControllerObservers( TCamControllerEvent aEvent,
  1572     void NotifyControllerObservers( TCamControllerEvent aEvent,
  1541                                     TInt                aError = KErrNone ) const;
  1573                                     TInt                aError = KErrNone ) const;
       
  1574   private:
  1542 
  1575 
  1543     /**
  1576     /**
  1544     * Starts the viewfinder if the engine has been prepared for the 
  1577     * Starts the viewfinder if the engine has been prepared for the 
  1545     * current mode.  
  1578     * current mode.  
  1546     * @since 2.8
  1579     * @since 2.8
  2220         /**
  2253         /**
  2221          * Called by the snapshotrotator to indicate when snapshot
  2254          * Called by the snapshotrotator to indicate when snapshot
  2222          * is rotated and ready for drawing
  2255          * is rotated and ready for drawing
  2223          */
  2256          */
  2224         void SnapshotRotationComplete();
  2257         void SnapshotRotationComplete();
       
  2258         
       
  2259         /**
       
  2260          * Method to retrieve Remaining Recording time from CCaeEngine
       
  2261          */
       
  2262         TTimeIntervalMicroSeconds RemainingVideoRecordingTime();
       
  2263         
       
  2264         
       
  2265         /**
       
  2266          * Handles hdmi connect event during recording after video stop
       
  2267          */
       
  2268         void HandlePostHdmiConnectDuringRecordingEventL();
       
  2269         
       
  2270 		/**
       
  2271 		* Sets a Pending Hdmi Event
       
  2272 		*/
       
  2273         void SetPendingHdmiEvent( TCamHdmiEvent aPendingHdmiEvent );
       
  2274         
       
  2275 		/**
       
  2276 		* Handles the current pending Hdmi EVent
       
  2277 		*/
       
  2278         void HandlePendingHdmiEvent();
       
  2279 		
       
  2280     /**
       
  2281 	* Returns ETrue when scene mode is forced to 
       
  2282     * "Automatic" by secondary camera
       
  2283 	*/
       
  2284     TBool SceneModeForcedBySecondaryCamera();
  2225 
  2285 
  2226   private:
  2286   private:
  2227 
  2287 
  2228     // -----------------------------------------------------
  2288     // -----------------------------------------------------
  2229     // Construction parts
  2289     // Construction parts
  2502     
  2562     
  2503     // Property watcher to report changes in the slide state
  2563     // Property watcher to report changes in the slide state
  2504     CCamPropertyWatcher* iSlideStateWatcher;
  2564     CCamPropertyWatcher* iSlideStateWatcher;
  2505     // Property watcher to report changes in the keylock state
  2565     // Property watcher to report changes in the keylock state
  2506     CCamPropertyWatcher* iKeyLockStatusWatcher;
  2566     CCamPropertyWatcher* iKeyLockStatusWatcher;
       
  2567     // Property watcher to report changes in the profile state
       
  2568     CCamPropertyWatcher* iProfileStatusWatcher;
  2507     // Set to ETrue if shutter sound always played
  2569     // Set to ETrue if shutter sound always played
  2508     // otherwise playing shutter sound depends on
  2570     // otherwise playing shutter sound depends on
  2509     // current profile
  2571     // current profile
  2510     TBool iShutterSndAlwaysOn;
  2572     TBool iShutterSndAlwaysOn;
  2511     // Active object to listen to the call state.
  2573     // Active object to listen to the call state.
  2606     CCamSnapShotRotator* iSnapShotRotator;
  2668     CCamSnapShotRotator* iSnapShotRotator;
  2607     // orientation at capture time
  2669     // orientation at capture time
  2608     TCamImageOrientation  iCaptureOrientation;
  2670     TCamImageOrientation  iCaptureOrientation;
  2609     
  2671     
  2610     TBool iIssueModeChangeSequenceSucceeded;
  2672     TBool iIssueModeChangeSequenceSucceeded;
       
  2673     
       
  2674     CCamTvAccessoryMonitor* iTvAccessoryMonitor;
       
  2675     
       
  2676     TBool iHdmiCableConnectedDuringRecording;
       
  2677     
  2611     TBool iSnapshotRedrawNeeded;
  2678     TBool iSnapshotRedrawNeeded;
  2612     
  2679     
       
  2680     TCamHdmiEvent iPendingHdmiEvent;
       
  2681 	
       
  2682     TBool iSceneModeForcedBySecondaryCamera;
       
  2683 	
  2613     };
  2684     };
  2614 
  2685 
  2615 #endif      // CAMAPPCONTROLLER_H
  2686 #endif      // CAMAPPCONTROLLER_H
  2616             
  2687             
  2617 // End of File
  2688 // End of File