|
1 /* |
|
2 * Copyright (c) 2009 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: AknPhysics observer interface |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef M_AKNPHYSICSOBSERVER_H |
|
19 #define M_AKNPHYSICSOBSERVER_H |
|
20 |
|
21 #include <e32base.h> |
|
22 |
|
23 /** |
|
24 * AknPhysics observer. |
|
25 * |
|
26 * @lib aknphysics |
|
27 * @since S60 v5.0 |
|
28 */ |
|
29 class MAknPhysicsObserver |
|
30 { |
|
31 |
|
32 public: |
|
33 |
|
34 /** |
|
35 * Physics emulation has moved the view. |
|
36 * |
|
37 * When this method is called client should update its visual and logical |
|
38 * states to reflect the changes caused by view move. Note that if the |
|
39 * parameter @c aDrawNow is @c EFalse client is not allowed to redraw the |
|
40 * display but should only update its logical state. |
|
41 * Physics engine will ensure that the last frame is always drawn. |
|
42 * |
|
43 * @since S60 v5.0 |
|
44 * |
|
45 * @param aNewPosition The new position of the view. |
|
46 * @param aDrawNow @c ETrue if client should redraw the screen, |
|
47 * otherwise @c EFalse. |
|
48 * @param aFlags Additional flags, not used currently. |
|
49 */ |
|
50 virtual void ViewPositionChanged( const TPoint& aNewPosition, |
|
51 TBool aDrawNow, |
|
52 TUint aFlags ) = 0; |
|
53 |
|
54 /** |
|
55 * Physics emulation has stopped moving the view |
|
56 * |
|
57 * @since S60 v5.0 |
|
58 */ |
|
59 virtual void PhysicEmulationEnded() = 0; |
|
60 |
|
61 /** |
|
62 * Returns the observer's view position. |
|
63 * |
|
64 * @since S60 v5.0 |
|
65 * |
|
66 * @return Physics observer's view position. |
|
67 */ |
|
68 virtual TPoint ViewPosition() const = 0; |
|
69 }; |
|
70 |
|
71 #endif // M_AKNPHYSICSOBSERVER_H |