uiservicetab/vimpstui/inc/cvimpstuidoublelistboxarray.h
branchRCL_3
changeset 29 9a48e301e94b
parent 0 5e5d6b214f4f
equal deleted inserted replaced
28:3104fc151679 29:9a48e301e94b
       
     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 "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:  CVIMPSTUiDoubleListboxArray-array decorator
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef _CVIMPSTUIDIUBLELISTBOXARRAY_H
       
    21 #define _CVIMPSTUIDIUBLELISTBOXARRAY_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include    <e32base.h>
       
    25 #include    <bamdesca.h> // MDesCArray
       
    26 #include    <AknIconArray.h>
       
    27 #include    <gulicon.h>
       
    28 
       
    29 // FORWARD DECLARATIONS
       
    30 class CFormattedCellListBoxData;
       
    31 class CColumnListBoxData;
       
    32 class CVIMPSTUiListBoxModel;
       
    33 class CVIMPSTUiDoubleStyleListBox;
       
    34 class MVIMPSTProcessArray;
       
    35 class CFont;
       
    36 class CVIMPSTUiDoubleListBoxTabViewControl;
       
    37 
       
    38 // CLASS DECLARATION
       
    39 
       
    40 /**
       
    41  *  Friends-array decorator.
       
    42  *  Decorates the array for listbox
       
    43  *
       
    44  *  @lib vimpstui.dll
       
    45  *  @since 5.0
       
    46  */
       
    47 class CVIMPSTUiDoubleListboxArray : public CBase, public MDesCArray
       
    48     {
       
    49     public:  // Constructors and destructor
       
    50 
       
    51         /**
       
    52          * Two-phased constructor.		 
       
    53 		 * @param aItemModel that contains the data.
       
    54 		 * @param aListBoxData Listbox data for setting row properties,
       
    55 		 *                   can be NULL.
       
    56 		 * @param aListBox Listbox 
       
    57          */
       
    58         static CVIMPSTUiDoubleListboxArray* NewL(
       
    59             MVIMPSTProcessArray& aItemModel,
       
    60             CFormattedCellListBoxData* aListboxData,
       
    61             CVIMPSTUiDoubleStyleListBox& aListBox,
       
    62             CVIMPSTUiDoubleListBoxTabViewControl& aTabbedviewControl);
       
    63 
       
    64         /**
       
    65          * Destructor.
       
    66          */
       
    67         virtual ~CVIMPSTUiDoubleListboxArray();
       
    68      
       
    69 
       
    70 	public: // Functions from MDesCArray
       
    71 
       
    72         /**
       
    73          * From MDesCArray, Returns the number of descriptor elements in 
       
    74 		 * a descriptor array.
       
    75 		 * @see MDesCArray
       
    76          */
       
    77 		TInt MdcaCount() const;
       
    78 
       
    79         /**
       
    80          * From MDesCArray, Indexes into a descriptor array.
       
    81 		 * @see MDesCArray
       
    82          */
       
    83 		TPtrC16 MdcaPoint( TInt aIndex ) const;
       
    84 		
       
    85 	
       
    86     private: // new functions
       
    87                     
       
    88         void AppendOwnDataL( TPtr& aBuffer,
       
    89                             TInt aIndex ) const;
       
    90         
       
    91                                     
       
    92 
       
    93 	private:
       
    94 	
       
    95         /**
       
    96          * C++ default constructor.
       
    97 		 * @param aItemModel that contains the data.
       
    98          * @param aListBoxData Listbox data for setting row properties, can be NULL.
       
    99          * @param aListBox Listbox 
       
   100          */
       
   101         CVIMPSTUiDoubleListboxArray( MVIMPSTProcessArray& aItemModel,
       
   102                 CFormattedCellListBoxData* aListboxData ,CVIMPSTUiDoubleStyleListBox& aListBox,
       
   103                 CVIMPSTUiDoubleListBoxTabViewControl& aTabbedviewControl);
       
   104 
       
   105         /**
       
   106          * By default Symbian OS constructor is private.
       
   107          */
       
   108         void ConstructL();
       
   109 
       
   110     private:    // Data        
       
   111         
       
   112         // wrapper array on engine side arrays
       
   113         MVIMPSTProcessArray& iItemArray;
       
   114         
       
   115 		// Doesn't own. Pointer to listbox data for setting row properties
       
   116         CFormattedCellListBoxData* iListboxData;
       
   117 		
       
   118 		//Ref. to Contact List Box
       
   119         CVIMPSTUiDoubleStyleListBox& iListBox;
       
   120 		
       
   121 		// Owns. Buffer that hold's information about fetched item
       
   122 		HBufC* iData;
       
   123 	
       
   124 		// maxmimun length of icon strings added to formatted text
       
   125 		TInt iMaxLengthOfIcons;
       
   126 				
       
   127 		// pointers to listbox fonts, contained objects are not owned
       
   128 		RPointerArray<CFont> iFonts;
       
   129         // Not own. Model to check the real location of items.
       
   130         CVIMPSTUiListBoxModel* iContactListBoxModel;
       
   131         CVIMPSTUiDoubleListBoxTabViewControl& iTabbedviewControl;
       
   132         
       
   133         // to hold the value whether presence is supported or not for the service
       
   134         TBool iPresenceSupported;
       
   135          // to hold the value whether im is supported  or not for the service
       
   136         TBool iIMSupported;
       
   137         
       
   138 	};
       
   139 
       
   140 #endif      // _CVIMPSTUIDIUBLELISTBOXARRAY_H
       
   141 
       
   142 // End of File