epoc32/include/hwrmhapticsobserver.h
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:33:34 +0100
branchSymbian3
changeset 4 837f303aceeb
parent 2 2fe1408b6811
permissions -rw-r--r--
Current Symbian^3 public API header files (from PDK 3.0.h)
This is the epoc32/include tree with the "platform" subtrees removed, and
all but a selected few mbg and rsg files removed.
     1 /*
     2 * Copyright (c) 2008 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:  This file contains the header of the 
    15 *                MHWRMHapticsObserver class.
    16 *
    17 */
    18 
    19 
    20 #ifndef M_HWRMHAPTICSOBSERVER_H
    21 #define M_HWRMHAPTICSOBSERVER_H
    22 
    23 #include <e32base.h>
    24 
    25 /**
    26 * MHWRMHapticsObserver observer class.
    27 *
    28 * A client should derive from this abstract class to receive haptics 
    29 * status notifications and notification of effect completion. 
    30 *
    31 * @since S60 5.1
    32 */
    33 class MHWRMHapticsObserver
    34     {
    35 public:
    36     
    37     /**
    38     * Haptics status.
    39     */
    40     enum THWRMHapticsStatus 
    41         {
    42         /**
    43          * Haptics is available for the observing client.
    44          */
    45         EHWRMHapticsStatusAvailable = 0,
    46 
    47         /**
    48          * Haptics is reserved for another client. The client making 
    49          * the active reservation does not receive this notification, but
    50          * a success code for the reservation command.
    51          */
    52         EHWRMHapticsStatusReserved,
    53 
    54         /**
    55          * Haptics has been suspended for this client. This occurs, when
    56          * another client with higher priority makes reservation for 
    57          * haptics, or when this client is making reservation and haptics 
    58          * has already been reserved for a client with higher priority.
    59          *
    60          * In suspended state, haptics effects are not played for the
    61          * suspended client, but other commands are executed as normal.
    62          */
    63         EHWRMHapticsStatusSuspended
    64         };
    65         
    66     /** 
    67     * Called when the device's haptics feature state changes
    68     *
    69     * @param aStatus Indicates haptics status.
    70     *
    71     * @since S60 5.1
    72     *
    73     * @see CHWRMHaptics::THWRMHapticsStatus
    74     */
    75     virtual void HapticsStatusChangedL( THWRMHapticsStatus aStatus ) = 0;
    76         
    77     /** 
    78     * Called when effect has completed playing. 
    79     * 
    80     * Method reserved for future use.
    81     *
    82     * @param aError Reason of completion.
    83     * @param aEffectHandle The associated effectHandle to the effect.
    84     *
    85     * @since S60 5.1
    86     */
    87     virtual void EffectCompletedL( TInt aError, TInt aEffectHandle ) = 0;
    88     };
    89 
    90 #endif // M_HWRMHAPTICSOBSERVER_H