webengine/webkitutils/rt_gesturehelper/src/pointercapturer.h
changeset 1 7c90e6132015
parent 0 dd21522fd290
child 2 8de7b67c0fb3
child 5 10e98eab6f85
equal deleted inserted replaced
0:dd21522fd290 1:7c90e6132015
     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 the License "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:  Responsible for capturing pointer events
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef _POINTERCAPTURER_H_
       
    20 #define _POINTERCAPTURER_H_
       
    21 
       
    22 // INCLUDES
       
    23 #include <e32std.h>
       
    24 #include <e32base.h>
       
    25 
       
    26 class CAlfControl;
       
    27 class CAlfControlGroup;
       
    28 class CAlfEnv;
       
    29 class CAlfDisplay;
       
    30 
       
    31 // CLASS DECLARATION
       
    32 
       
    33 namespace RT_GestureHelper 
       
    34 {
       
    35 
       
    36 class CGestureHelperImpl;
       
    37 class CPointerCaptureControl;
       
    38 
       
    39 /**
       
    40  * CPointerCaptureControl
       
    41  * Gesture control own a gesture helper, and captures any pointer events that 
       
    42  * no other control captures. After it captures pointer down event, it will 
       
    43  * capture all pointer events until pointer up. It does this by bringing its
       
    44  * control group to the top upon pointer down, and lowering the control group
       
    45  * to the botton upon pointer up.
       
    46  */
       
    47 NONSHARABLE_CLASS( CPointerCapturer ) : public CBase
       
    48     {
       
    49 public: 
       
    50     /** Two-phased constructor */
       
    51     static CPointerCapturer* NewL();
       
    52     /** Destructor */
       
    53     ~CPointerCapturer();
       
    54     
       
    55     void InitForAlfredL( CGestureHelperImpl& aHelper, CAlfEnv& aEnv, 
       
    56         CAlfDisplay& aDisplay, TInt aControlGroupId );
       
    57 
       
    58     void StartL();
       
    59     void Stop();
       
    60     
       
    61 private:    
       
    62     /// 
       
    63     CPointerCaptureControl* iCaptureControl;
       
    64     TInt iControlGroupId;
       
    65     };
       
    66 
       
    67 } // namespace GestureHelper
       
    68     
       
    69 #endif // _POINTERCAPTURER_H_