|
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: |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef MEMSPYVIEWDRIVEINFO_H |
|
19 #define MEMSPYVIEWDRIVEINFO_H |
|
20 |
|
21 // System includes |
|
22 #include <coecntrl.h> |
|
23 #include <aknlists.h> |
|
24 |
|
25 // Engine includes |
|
26 #include <memspy/engine/memspyenginehelperfilesystem.h> |
|
27 |
|
28 // User includes |
|
29 #include "MemSpyViewBase.h" |
|
30 |
|
31 // Classes referenced |
|
32 |
|
33 |
|
34 |
|
35 |
|
36 class CMemSpyViewDriveInfoBase : public CMemSpyViewBase |
|
37 { |
|
38 public: |
|
39 CMemSpyViewDriveInfoBase( CMemSpyEngine& aEngine, MMemSpyViewObserver& aObserver ); |
|
40 ~CMemSpyViewDriveInfoBase(); |
|
41 void BaseConstructL(); |
|
42 |
|
43 public: // From CMemSpyViewBase |
|
44 TBool HandleCommandL( TInt aCommand ); |
|
45 |
|
46 protected: // Data members |
|
47 CMemSpyEngineDriveList* iList; |
|
48 }; |
|
49 |
|
50 |
|
51 |
|
52 |
|
53 class CMemSpyViewDriveList : public CMemSpyViewDriveInfoBase, public MMemSpyEngineDriveListObserver |
|
54 { |
|
55 public: |
|
56 CMemSpyViewDriveList( CMemSpyEngine& aEngine, MMemSpyViewObserver& aObserver ); |
|
57 CMemSpyViewDriveList( CMemSpyEngine& aEngine, MMemSpyViewObserver& aObserver, TDriveNumber aDriveNumber ); |
|
58 void ConstructL( const TRect& aRect, CCoeControl& aContainer, TAny* aSelectionRune = NULL ); |
|
59 |
|
60 public: // From CMemSpyViewBase |
|
61 TMemSpyViewType ViewType() const; |
|
62 CMemSpyViewBase* PrepareParentViewL(); |
|
63 CMemSpyViewBase* PrepareChildViewL(); |
|
64 |
|
65 private: // From CMemSpyViewBase |
|
66 void RefreshL(); |
|
67 void SetListBoxModelL(); |
|
68 void HandleListBoxItemActionedL( TInt aIndex ); |
|
69 void HandleListBoxItemSelectedL( TInt aIndex ); |
|
70 |
|
71 private: // From MMemSpyEngineDriveListObserver |
|
72 void HandleDriveListChangedL( const CMemSpyEngineDriveList& aList ); |
|
73 |
|
74 private: // Data members |
|
75 TBool iUseDriveNumber; |
|
76 TDriveNumber iDriveNumber; |
|
77 CMemSpyEngineDriveEntry* iCurrentDrive; |
|
78 }; |
|
79 |
|
80 |
|
81 |
|
82 class CMemSpyViewDriveInfo : public CMemSpyViewDriveInfoBase, public MMemSpyEngineDriveEntryObserver |
|
83 { |
|
84 public: |
|
85 CMemSpyViewDriveInfo( CMemSpyEngine& aEngine, MMemSpyViewObserver& aObserver, TDriveNumber aDriveNumber ); |
|
86 void ConstructL( const TRect& aRect, CCoeControl& aContainer, TAny* aSelectionRune = NULL ); |
|
87 |
|
88 public: // From CMemSpyViewBase |
|
89 void RefreshL(); |
|
90 TMemSpyViewType ViewType() const; |
|
91 CMemSpyViewBase* PrepareParentViewL(); |
|
92 |
|
93 private: // From CMemSpyViewBase |
|
94 void SetListBoxModelL(); |
|
95 |
|
96 private: // From MMemSpyEngineDriveEntryObserver |
|
97 void HandleDriveEntryChangedL( const CMemSpyEngineDriveEntry& aEntry ); |
|
98 |
|
99 private: // Data members |
|
100 const TDriveNumber iDriveNumber; |
|
101 CMemSpyEngineDriveEntry* iDriveInfo; |
|
102 }; |
|
103 |
|
104 |
|
105 |
|
106 #endif |