1 /* |
|
2 * Copyright (c) 2006 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: Memory card info popup |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef C_FILEMANAGERMMCINFOPOPUP_H |
|
21 #define C_FILEMANAGERMMCINFOPOPUP_H |
|
22 |
|
23 |
|
24 // INCLUDES |
|
25 #include <coecntrl.h> |
|
26 #include <badesca.h> |
|
27 |
|
28 |
|
29 // FORWARD DECLARATIONS |
|
30 class CAknSingleHeadingPopupMenuStyleListBox; |
|
31 class CAknPopupList; |
|
32 class TFileManagerDriveInfo; |
|
33 class CMSPUtil; |
|
34 |
|
35 |
|
36 // CLASS DECLARATION |
|
37 /** |
|
38 * This class displays memory card info |
|
39 * |
|
40 * @lib FileManagerView.lib |
|
41 * @since S60 3.1 |
|
42 */ |
|
43 NONSHARABLE_CLASS(CFileManagerMMCInfoPopup) : public CCoeControl |
|
44 { |
|
45 |
|
46 public: // Constructors and destructor |
|
47 /** |
|
48 * Two-phased constructor. |
|
49 * @param aProperties Properties of the item that will be shown |
|
50 * @return Newly created popup. |
|
51 */ |
|
52 static CFileManagerMMCInfoPopup* NewL( |
|
53 const TFileManagerDriveInfo& aInfo ); |
|
54 |
|
55 /** |
|
56 * Executes the dialog. |
|
57 * @return ETrue if dialog was dismissed using OK, |
|
58 * EFalse otherwise. |
|
59 */ |
|
60 TBool ExecuteLD(); |
|
61 |
|
62 protected: |
|
63 /** |
|
64 * Destructor. |
|
65 */ |
|
66 ~CFileManagerMMCInfoPopup(); |
|
67 |
|
68 private: // New functions |
|
69 /** |
|
70 * C++ default constructor. |
|
71 */ |
|
72 CFileManagerMMCInfoPopup(); |
|
73 |
|
74 /** |
|
75 * By default Symbian 2nd phase constructor is private. |
|
76 */ |
|
77 void ConstructL( const TFileManagerDriveInfo& aInfo ); |
|
78 |
|
79 /** |
|
80 * Constructs data array |
|
81 * @param aProperties Properties of the item that will be shown |
|
82 * @return Data array |
|
83 */ |
|
84 MDesCArray* ConstructDataArrayL( |
|
85 const TFileManagerDriveInfo& aInfo ); |
|
86 |
|
87 /** |
|
88 * Creates name entry |
|
89 * @param aProperties Properties of the item that will be shown |
|
90 * @return Name entry |
|
91 */ |
|
92 HBufC* NameEntryLC( |
|
93 const TFileManagerDriveInfo& aInfo ); |
|
94 |
|
95 /** |
|
96 * Creates size entry with text and size |
|
97 * @param aTextId Text to display |
|
98 * @param aSize Size to display |
|
99 * @return Size entry |
|
100 */ |
|
101 HBufC* SizeEntryLC( TInt aTextId, TInt64 aSize ); |
|
102 |
|
103 private: // Data |
|
104 /** |
|
105 * Popup list that is the actual dialog that is shown |
|
106 * Own. |
|
107 */ |
|
108 CAknPopupList* iPopupList; |
|
109 |
|
110 /** |
|
111 * Listbox that is given to CAknPopupList constructor |
|
112 * Own. |
|
113 */ |
|
114 CAknSingleHeadingPopupMenuStyleListBox* iListBox; |
|
115 |
|
116 /** |
|
117 * Keeps track if destructor is already called |
|
118 * Not own. |
|
119 */ |
|
120 TBool* iIsDestroyed; |
|
121 |
|
122 /** |
|
123 * Memory State Popup utilities |
|
124 * Own. |
|
125 */ |
|
126 CMSPUtil* iUtil; |
|
127 |
|
128 }; |
|
129 |
|
130 #endif // C_FILEMANAGERMMCINFOPOPUP_H |
|
131 |
|
132 // End of File |
|