1 /* |
|
2 * Copyright (c) 2002 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: LandmarksUi Content File - LM application ByLm view's container. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 |
|
24 |
|
25 #ifndef CLMKBYLMCONTAINER_H |
|
26 #define CLMKBYLMCONTAINER_H |
|
27 |
|
28 // INCLUDES |
|
29 #include <EPos_CPosLandmark.h> |
|
30 #include <coecobs.h> |
|
31 #include "CLmkLbWithFilterContainer.h" |
|
32 |
|
33 |
|
34 |
|
35 // FORWARD DECLARATIONS |
|
36 class CAknView; |
|
37 |
|
38 // FORWARD DECLARATIONS |
|
39 class CEikTextListBox; |
|
40 class CLmkAppLmSelectorImpl; |
|
41 |
|
42 // CLASS DECLARATION |
|
43 /** |
|
44 * CLmkByLmContainer container control class. |
|
45 * |
|
46 */ |
|
47 class CLmkByLmContainer : public CLmkLbWithFilterContainer, public MCoeControlObserver |
|
48 { |
|
49 public: // Constructors and destructor |
|
50 /** |
|
51 * Two-phased constructor |
|
52 * @param aKeyProcessor |
|
53 * @param aParent |
|
54 * @param aRect A rectangle for drawing. |
|
55 * @return The newly created object. |
|
56 */ |
|
57 |
|
58 // For Landscape Support |
|
59 |
|
60 static CLmkByLmContainer* NewL(MLmkKeyProcessor& aKeyProcessor, |
|
61 MObjectProvider* aParent, |
|
62 const TRect& aRect , |
|
63 CAknView& aView); |
|
64 |
|
65 /** |
|
66 * Destructor. |
|
67 */ |
|
68 ~CLmkByLmContainer(); |
|
69 |
|
70 public: // from CCoeControl |
|
71 TKeyResponse OfferKeyEventL( const TKeyEvent& aKeyEvent, |
|
72 TEventCode aType ); |
|
73 |
|
74 // For Landscape Support |
|
75 |
|
76 void HandleResourceChange(TInt aType); |
|
77 |
|
78 public: // New functions |
|
79 TInt GetSelectedLandmarksL(RPointerArray<CPosLandmark> &aArray); |
|
80 |
|
81 TBool IsLandmarkDataEmptyL(CPosLandmark* aLandmark); |
|
82 |
|
83 TBool IsEditorOpened(); |
|
84 |
|
85 void SetEditorOpenedBool(TBool aBoolvalue); |
|
86 |
|
87 void SetHandlePointerEventBool( TBool aBoolValue); |
|
88 |
|
89 protected: // From CLmkLbWithFilterContainer |
|
90 void SetupTitlePaneL(); |
|
91 void SetupSelectorAndListL( CPosLandmarkDatabase& aDb, |
|
92 CLmkSender& aSender ); |
|
93 void SetupNaviPaneL(); |
|
94 |
|
95 public: // From MCoeControlObserver |
|
96 |
|
97 /** |
|
98 * HandleControlEventL handles an event from an observed control. |
|
99 * |
|
100 * @param aControl the control that reported the event |
|
101 * @param aEventType contains info about the event |
|
102 */ |
|
103 void HandleControlEventL(CCoeControl* aControl, TCoeEvent aEventType); |
|
104 |
|
105 private: |
|
106 /** |
|
107 * C++ default constructor. |
|
108 * @param aKeyProcessor |
|
109 * @return newly instantiated object |
|
110 */ |
|
111 // Changed for Landscape support |
|
112 CLmkByLmContainer( MLmkKeyProcessor& aKeyProcessor, CAknView& aView ); |
|
113 |
|
114 // from CCoeControl |
|
115 void FocusChanged(TDrawNow aDrawNow); |
|
116 |
|
117 /** |
|
118 * Symbian 2nd phase constructor |
|
119 * @param aRect |
|
120 */ |
|
121 void ConstructL( const TRect& aRect ); |
|
122 |
|
123 private://from MLmkMskObserver |
|
124 void UpdateMskContainerL(); |
|
125 |
|
126 private: //from CLmkBaseContainer |
|
127 CEikMenuBar* MenuBar(); |
|
128 TInt ContextSpecificMenuBar(); |
|
129 |
|
130 #ifdef RD_SCALABLE_UI_V2 |
|
131 public://for touch support |
|
132 void HandlePointerEventL( const TPointerEvent& aPointerEvent ); |
|
133 #endif//RD_SCALABLE_UI_V2 |
|
134 |
|
135 private: // Data |
|
136 CAknView &iView; |
|
137 TBool iIsEditorOpened; |
|
138 TBool iHandlePointerEvent; |
|
139 |
|
140 }; |
|
141 |
|
142 #endif // CLMKBYLMCONTAINER_H |
|
143 |
|
144 // End of File |
|