fmradio/fmradioengine/inc/fmradiocontroleventobserver.h
branchRCL_3
changeset 19 cce62ebc198e
parent 18 1a6714c53019
child 20 93c594350b9a
equal deleted inserted replaced
18:1a6714c53019 19:cce62ebc198e
     1 /*
       
     2 * Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Declaration for the control event observer interface
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef MFMRADIOCONTROLEVENTOBSERVER_H
       
    19 #define MFMRADIOCONTROLEVENTOBSERVER_H
       
    20 
       
    21 #include "fmradioaudioutils.hrh"
       
    22 #include "fmradiosystemutils.h"
       
    23 
       
    24 /**
       
    25  *  MFMRadioControlEventObserver
       
    26  *
       
    27  *  MFMRadioControlEventObserver defines observer interface for FM Radio control events.
       
    28  */
       
    29 class MFMRadioControlEventObserver
       
    30     {
       
    31     
       
    32 public:
       
    33         
       
    34     /**
       
    35      * Called when "step to channel" request occurs.
       
    36      *
       
    37      * @param aDirection EFMRadioUp for stepping up, EFMRadioDown for stepping down
       
    38      */
       
    39     virtual void StepToChannelL( TFMRadioTuneDirection aDirection ) = 0;
       
    40     
       
    41     /**
       
    42      * Called when "set channel" request occurs.
       
    43      *
       
    44      * @param aChannelId Channel id to set
       
    45      */
       
    46     virtual void SetChannelL( TInt aChannelId ) = 0;
       
    47     
       
    48     /**
       
    49      * Called when "seek" request occurs.
       
    50      *
       
    51      * @param aDirection If EFMRadioUp seeks up, otherwise seeks down
       
    52      */
       
    53     virtual void SeekL( TFMRadioTuneDirection aDirection ) = 0;
       
    54 
       
    55     /**
       
    56      * Called when "step to frequency up" request occurs.
       
    57      *
       
    58      * @param aDirection EFMRadioUp for stepping up, EFMRadioDown for stepping down
       
    59      */
       
    60     virtual void StepToFrequencyL( TFMRadioTuneDirection aDirection ) = 0;
       
    61     
       
    62     /**
       
    63      * Called when "set frequency" request occurs.
       
    64      *
       
    65      * @param aFreq Frequency to set
       
    66      */
       
    67     virtual void SetFrequencyL( TUint32 aFreq ) = 0;
       
    68     
       
    69     /**
       
    70      * Called when "adjust volume" request occurs.
       
    71      *
       
    72      * @param aDirection If EFMRadioDecVolume decreases, otherwise increases 
       
    73      * volume
       
    74      */
       
    75     virtual void AdjustVolumeL( TFMRadioVolumeSetDirection aDirection ) = 0;
       
    76     
       
    77     /**
       
    78      * Called when "mute" request occurs.
       
    79      * 
       
    80      * @param aMute if ETrue mutes, else unmutes radio
       
    81      */
       
    82     virtual void MuteL( TBool aMute ) = 0;
       
    83 
       
    84     /**
       
    85     * Called when "play" request occurs.
       
    86     *
       
    87     * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
    88     */
       
    89     virtual void PlayL( TBool aDownPressed ) = 0;
       
    90 
       
    91     /**
       
    92      * Called when "pause" request occurs.
       
    93      *
       
    94      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
    95      */
       
    96     virtual void PauseL(TBool aDownPressed ) = 0;
       
    97 
       
    98     /**
       
    99      * Called when "play", "pause" or "pauseplay" request occurs.
       
   100      *
       
   101      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   102      */
       
   103     virtual void PausePlayL( TBool aDownPressed ) = 0;
       
   104     
       
   105     /**
       
   106      * Called when "stop" request occurs.
       
   107      *
       
   108      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   109      */
       
   110     virtual void StopL( TBool aDownPressed ) = 0;
       
   111     
       
   112     /**
       
   113      * Called when "forward" request occurs.
       
   114      *
       
   115      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   116      */
       
   117     virtual void ForwardL( TBool aDownPressed ) = 0;
       
   118     
       
   119     /**
       
   120      * Called when "fast forward" request occurs.
       
   121      *
       
   122      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   123      */
       
   124     virtual void FastForwardL( TBool aDownPressed ) = 0;
       
   125     
       
   126     /**
       
   127      * Called when "backward" request occurs.
       
   128      *
       
   129      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   130      */
       
   131     virtual void BackwardL( TBool aDownPressed ) = 0;
       
   132     
       
   133     /**
       
   134      * Called when "rewind" request occurs.
       
   135      *
       
   136      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   137      */
       
   138     virtual void RewindL( TBool aDownPressed ) = 0;
       
   139     
       
   140     /**
       
   141      * Called when "channel up" request occurs.
       
   142      *
       
   143      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   144      */
       
   145     virtual void ChannelUpL( TBool aDownPressed ) = 0;
       
   146     
       
   147     /**
       
   148      * Called when "channel down" request occurs.
       
   149      *
       
   150      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   151      */
       
   152     virtual void ChannelDownL( TBool aDownPressed ) = 0;
       
   153     
       
   154     /**
       
   155      * Called when "volume up" request occurs.
       
   156      *
       
   157      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   158      */
       
   159     virtual void VolumeUpL( TBool aDownPressed ) = 0;
       
   160     
       
   161     /**
       
   162      * Called when "volume down" request occurs.
       
   163      *
       
   164      * @param aDownPressed If ETrue, button is down. If EFalse, button is up.
       
   165      */
       
   166     virtual void VolumeDownL( TBool aDownPressed ) = 0;
       
   167     
       
   168     /**
       
   169      * Called when "change view" request occurs
       
   170      *
       
   171      * @param aViewId the id of activated view
       
   172      * @param aForceChange if ETrue, view changing is forced and state 
       
   173      * of FM Radio is not checked
       
   174      */
       
   175     virtual void ChangeViewL(TUid aViewId, TBool aForceChange) = 0;
       
   176     
       
   177     /**
       
   178      * Called when output source is changed
       
   179      * @param aDestination the current output source
       
   180      */
       
   181     virtual void SetAudioOutputDestinationL(TFMRadioOutputDestination aDestination) = 0;
       
   182     
       
   183     /**
       
   184      * Called when headset button answer/end call is pressed
       
   185      */
       
   186     virtual void AnswerEndCallL() = 0;
       
   187     };
       
   188 
       
   189 #endif      // MFMRADIOCONTROLEVENTOBSERVER_H   
       
   190             
       
   191