00001 /* ============================================================================ 00002 * Name : AknListQueryControl.h 00003 * Part of : Avkon 00004 * Implementation notes: 00005 * Declaration of Avkon list query control. 00006 * Copyright © 2002 Nokia Corporation. 00007 * This material, including documentation and any related 00008 * computer programs, is protected by copyright controlled by 00009 * Nokia Corporation. All rights are reserved. Copying, 00010 * including reproducing, storing, adapting or translating, any 00011 * or all of this material requires the prior written consent of 00012 * Nokia Corporation. This material also contains confidential 00013 * information which may not be disclosed to others without the 00014 * prior written consent of Nokia Corporation. 00015 */ 00016 00017 00018 #ifndef __AKN_LIST_QUERY_CONTROL_H 00019 #define __AKN_LIST_QUERY_CONTROL_H 00020 00021 #include <AknControl.h> 00022 00023 #include <aknpopupheadingpane.h> 00024 #start_since SINCE_3_1_SDK 00025 #include <aknmessagequerycontrol.h> 00026 #end_since SINCE_3_1_SDK 00027 00028 class CEikFormattedCellListBox; 00029 struct TAknPopupWindowLayoutDef; 00030 00034 class CAknListQueryControl : public CAknControl 00035 { 00036 public: 00040 IMPORT_C CAknListQueryControl(); 00041 00045 IMPORT_C void ConstructFromResourceL(TResourceReader& aRes); 00046 00050 IMPORT_C virtual ~CAknListQueryControl(); 00051 00057 IMPORT_C TSize MinimumSize(); 00058 00064 IMPORT_C TInt CountComponentControls() const; 00065 00072 IMPORT_C CCoeControl* ComponentControl(TInt anIndex) const; 00073 00082 IMPORT_C TKeyResponse OfferKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType); 00083 00089 IMPORT_C void Draw(const TRect& aRect) const; 00090 00095 IMPORT_C void SetLayout(TAknPopupWindowLayoutDef* aLayout); 00096 00097 IMPORT_C void FocusChanged(TDrawNow aDrawNow); 00098 00103 inline CEikFormattedCellListBox* Listbox() const; 00104 00109 inline CAknPopupHeadingPane* Heading() const; 00110 00115 inline TInt Listtype() const; 00116 00121 IMPORT_C void HandlePointerEventL(const TPointerEvent& aPointerEvent); 00122 00123 #start_since SINCE_3_1_SDK 00124 00129 CAknMessageQueryControl* MessageBox() const; 00130 #end_since SINCE_3_1_SDK 00131 private: 00135 IMPORT_C void* ExtensionInterface( TUid aInterface ); 00136 00137 private: 00138 CEikFormattedCellListBox* iListBox; 00139 CAknPopupHeadingPane* iHeading; 00140 TInt iListType; 00141 TAknPopupWindowLayoutDef* iLayout; 00142 CAknMessageQueryControl* iMessageBox; 00143 00144 TInt iSpare[1]; 00145 00146 public: 00147 00151 inline CEikFormattedCellListBox* listbox() const; 00152 }; 00153 00154 inline CEikFormattedCellListBox *CAknListQueryControl::Listbox() const 00155 { 00156 return iListBox; 00157 } 00158 00159 inline CAknPopupHeadingPane *CAknListQueryControl::Heading() const 00160 { 00161 if ( iHeading && iHeading->Prompt() ) 00162 return iHeading; 00163 return 0; 00164 } 00165 00166 inline TInt CAknListQueryControl::Listtype() const 00167 { 00168 return iListType; 00169 } 00170 00174 inline CEikFormattedCellListBox* CAknListQueryControl::listbox() const 00175 { 00176 return Listbox(); 00177 } 00178 00179 #endif