tsrc/musenginestub/inc/musengsession.h
branchRCL_3
changeset 33 bc78a40cd63c
parent 32 73a1feb507fb
--- a/tsrc/musenginestub/inc/musengsession.h	Tue Aug 31 15:12:07 2010 +0300
+++ b/tsrc/musenginestub/inc/musengsession.h	Wed Sep 01 12:31:01 2010 +0100
@@ -16,14 +16,17 @@
 */
 
 
-#ifndef MUSENGSESSION_H
-#define MUSENGSESSION_H
+#ifndef MUSHENGSESSION_H
+#define MUSHENGSESSION_H
 
+// USER INCLUDES
 
 //SYSTEM INCLUDES
 #include <e32base.h>
 
 
+// FORWARD DECLARATIONS
+class MMusEngSessionObserver;
 
 // CLASS DECLARATION
 
@@ -35,38 +38,162 @@
 * resources.
 *
 * @lib musengine.lib
+* @since S60 v3.2
 */
 class CMusEngSession : public CBase
     {
-   
+
     public:
 
         /**
         * Desctructor, finalize session
         *
+        * @since S60 v3.2
         */
         ~CMusEngSession();
 
 
+    public:  // API FUNCTIONS
+
+        /**
+        * Returns currently assigned drawing area
+        *
+        * @since S60 v3.2
+        * @return TRect This session drawing area recttangle
+        */
+        IMPORT_C TRect Rect() const;
+
+        /**
+        * Sets new drawing area
+        *
+        * @since S60 v3.2
+        * @param TRect This session new drawing area rectangle
+        */
+        IMPORT_C void SetRectL( const TRect& aRect );
+
+        /**
+        * Activates/deactivates loadspeaker
+        *
+        * @since S60 v3.2
+        * @param TBool Enable or disable loudspeaker
+        * @param TBool Show activation dialog
+        */
+        IMPORT_C void EnableLoudspeakerL( TBool aEnable, TBool aShowDialog );
+
+        /**
+        * Checks is loudspeaker enabled or disabled.
+        *
+        * @since S60 v3.2
+        * @return TBool true if enabled
+        */
+        IMPORT_C TBool IsLoudSpeakerEnabled() const;
+
+        /**
+        * Returns current volume level
+        *
+        * @since S60 v3.2
+        */
+        IMPORT_C TInt VolumeL() const;
+
+
+    public:  // VIRTUAL API FUNCTIONS
+
+        /**
+        * Increases volume level by one.
+        *
+        * @since S60 v3.2
+        */
+        IMPORT_C virtual void VolumeUpL();
+
+        /**
+        * Decreases volume level by one
+        *
+        * @since S60 v3.2
+        */
+        IMPORT_C virtual void VolumeDownL();
+
+        /**
+        * Enables or disables display. Call to this function is considered
+        * as a permission or denial to draw to the display.
+        *
+        * @since S60 v3.2
+        */
+        IMPORT_C virtual void EnableDisplayL( TBool aEnable ) = 0;
+
+        /**
+        * Mutes current audio stream meaning that any audio is not played or
+        * sent to network.
+        *
+        * @since S60 v3.2
+        */
+        IMPORT_C virtual void MuteL() = 0;
+
+        /**
+        * Unmute current audio stream meaning that all the audio is played
+        * and if needed also sent to network.
+        *
+        * @since S60 v3.2
+        */
+        IMPORT_C virtual void UnmuteL() = 0;
+
+
+    protected: // INTERNAL
+
+        virtual void RectChangedL() = 0;
+
 
     protected:
 
         /**
         * Constructor, private cannot be instantiate
         *
-        * @param aRect reserved drawing area for this session
+        *
+        * @since S60 v3.2
+        * @param TRect reserved drawing area for this session
         */
-        CMusEngSession();
+        CMusEngSession( const TRect& aRect );
 
 
     protected:
 
         /**
-        * second-phase constructor, called by those session specific 
+        * second-phase constructor, called by those session specific
         * constructors
+        *
+        * @since S60 v3.2
         */
         void ConstructL();
 
+
+    protected: // MEMBERS
+
+        /**
+        * Callback pointer to interface, not own
+        *
+        * @since S60 v3.2
+        */
+        MMusEngSessionObserver* iSessionObserver;
+
+
+    public: // MEMBERS
+
+        /**
+        * Drawing area rect
+        *
+        * @since S60 v3.2
+        */
+        TRect iRect;
+
+        /**
+        * Telephone utilities
+        *
+        * @since S60 v3.2
+        */
+        //CMusEngTelephoneUtils* iTelephoneUtils;
+
+        TInt iErrorCode;
+
+
     };
 
-#endif //MUSENGSESSION_H
+#endif //MUSHENGSESSION_H
\ No newline at end of file