/*
*
* Copyright (c) <2010> Comarch S.A. and/or its subsidiary(-ies).
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of the License "Eclipse Public License v1.0"
* which accompanies this distribution, and is available
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
*
* Original Contributors:
* Comarch S.A. - original contribution.
*
* Contributors:
*
* Description:
*
*/
#ifndef HSPSETTINGS_H_
#define HSPSETTINGS_H_
#include <e32base.h>
/**
* @brief Singleton class representing profile's settings
*/
class CHsHSPSettings : public CBase
{
public:
/**
* Returns pointer to singleton class
*
* @return class instance
*/
static CHsHSPSettings* InstanceL();
/**
* Decrements reference counter. Deletes singleton if there are no references.
*/
void Release();
private:
/**
* Constructor for performing 1st stage construction
*/
CHsHSPSettings();
/**
* Destructor
*/
~CHsHSPSettings();
/**
* Constructor for performing 2nd stage construction
*/
void ConstructL();
public:
/**
* Sets speaker volume level
*
* @param aLevel new level
*/
void SetSpeakerVolumeLevel( const TInt aLevel );
/**
* Sets speaker volume level
*
* @param aLevel new level
*/
void SetMicGainLevel( const TInt aLevel );
/**
* Updates call status
*
* @param aIsCallOngoing denotes if audio call is ongoing
*/
void UpdateCallStatus( const TBool aIsCallOngoing );
/**
* Getter for 'CallOngoing' status
*
* @return ETrue if audio call is ongoing, otherwise EFalse
*/
TBool CallOngoing() const;
private:
/** Speaker volume level */
TInt iSpeakerVolumeLevel;
/** Microphone gain level */
TInt iMicGainLevel;
/** Denotes if voice call is ongoing */
TBool iCallOngoing;
/** Reference counter */
TInt iReferenceCounter;
};
#endif /* HSPSETTINGS_H_ */