videoplayback/videohelix/inc/mpxcalldetector.h
branchRCL_3
changeset 70 375929f879c2
parent 64 3eb824b18d67
child 73 f89a65650939
equal deleted inserted replaced
64:3eb824b18d67 70:375929f879c2
     1 /*
       
     2 * Copyright (c) 2010 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:  Class for call detaction
       
    15 *
       
    16 */
       
    17 
       
    18 // Version : %version: 1 %
       
    19 
       
    20 #ifndef MPXCALLDETECTOR_H
       
    21 #define MPXCALLDETECTOR_H
       
    22 
       
    23 #include <e32base.h>
       
    24 #include <e32property.h>
       
    25 
       
    26 class MMPXCallDetectorObserver
       
    27 {
       
    28     public:
       
    29         virtual void CallDetectedL() = 0;
       
    30 };
       
    31 
       
    32 /**
       
    33  *  Detector for incoming call
       
    34  */
       
    35 NONSHARABLE_CLASS( CMPXCallDetector ) : public CActive
       
    36 {
       
    37     public: // Constructors and destructor
       
    38 
       
    39         /**
       
    40         * Two-phased constructor.
       
    41         */
       
    42         static CMPXCallDetector* NewL( MMPXCallDetectorObserver* aObserver );
       
    43 
       
    44         /**
       
    45         * Destructor.
       
    46         */
       
    47         ~CMPXCallDetector();
       
    48         
       
    49     public: // New functions
       
    50 
       
    51         /**
       
    52         * Request call notifications
       
    53         *
       
    54         */
       
    55         void RequestNotification();
       
    56 
       
    57     private:
       
    58 
       
    59         /**
       
    60         * C++ default constructor.
       
    61         */
       
    62         CMPXCallDetector( MMPXCallDetectorObserver* aObserver );
       
    63 
       
    64         /**
       
    65         * Symbian OS 2nd phase constructor.
       
    66         */
       
    67         void ConstructL();
       
    68     
       
    69         /**
       
    70         * From CActive
       
    71         * @see CActive for more information
       
    72         */
       
    73         void RunL();
       
    74         
       
    75         /**
       
    76         * From CActive
       
    77         * @see CActive for more information
       
    78         */
       
    79         void DoCancel();
       
    80 
       
    81     private:
       
    82 
       
    83         // Call observer
       
    84         MMPXCallDetectorObserver*           iObserver;
       
    85         RProperty                           iTsyProperty;
       
    86 };
       
    87 
       
    88 #endif // CALLDETECTOR_H