|
1 /* |
|
2 * Copyright (c) 2002-2004 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: Implementation for installing branding data |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef CCABRANDINSTALLER_H |
|
21 #define CCABRANDINSTALLER_H |
|
22 |
|
23 // INCLUDES |
|
24 #include "MCABrandInstaller.h" |
|
25 #include <e32base.h> |
|
26 #include <badesca.h> |
|
27 |
|
28 // FORWARD DECLARATIONS |
|
29 class CEikonEnv; |
|
30 class CFileMan; |
|
31 |
|
32 // CLASS DECLARATION |
|
33 |
|
34 /** |
|
35 * Implementation for installing branding data. |
|
36 * |
|
37 * @lib alternator.lib |
|
38 * @since S60 3.0 |
|
39 */ |
|
40 class CCABrandInstallerImp : public MCABrandInstaller, public CBase |
|
41 { |
|
42 public: // Constructors and destructor |
|
43 |
|
44 /** |
|
45 * Two-phased constructor. |
|
46 */ |
|
47 static CCABrandInstallerImp* NewL(); |
|
48 |
|
49 static CCABrandInstallerImp* NewLC(); |
|
50 |
|
51 /** |
|
52 * Destructor. |
|
53 */ |
|
54 virtual ~CCABrandInstallerImp(); |
|
55 |
|
56 public: // New functions |
|
57 |
|
58 /** |
|
59 * Checks if brand already exists |
|
60 * @since Series 60 3.0 |
|
61 * @param aBrandName Name of brand "server" |
|
62 * @return EFalse if not exists else ETrue |
|
63 */ |
|
64 TBool BrandAlreadyExistsL( const TDesC& aBrandName ); |
|
65 |
|
66 /** |
|
67 * Creates import folder if not existing |
|
68 */ |
|
69 void CreateImportFolderL(); |
|
70 |
|
71 /** |
|
72 * Checks if import folder exists |
|
73 * @retun EFalse if not existing |
|
74 */ |
|
75 TBool ImportFolderExistsL(); |
|
76 |
|
77 /** |
|
78 * Lists installed brands |
|
79 * @param aListOfBrands Array that is filled of list of installed brands |
|
80 */ |
|
81 void ListOfInstalledBrandsL( CDesCArray& aListOfBrands ); |
|
82 |
|
83 /** |
|
84 * Lists uninstalled brands from import folder |
|
85 * @param aListOfBrands Array that is filled of list of uninstalled brands |
|
86 */ |
|
87 void ListOfUninstalledBrandsL( CDesCArray& aListOfBrands ); |
|
88 |
|
89 /** |
|
90 * Checks if new brand is available |
|
91 * @return ETrue if available |
|
92 */ |
|
93 TBool IsNewBrandAvailableL(); |
|
94 |
|
95 void InstallNewBrandL(); |
|
96 |
|
97 public: // Functions from base classes |
|
98 |
|
99 /** |
|
100 * From MCABrandInstaller |
|
101 */ |
|
102 TBool FolderExists( const TDesC& aFolderPath ); |
|
103 |
|
104 /** |
|
105 * From MCABrandInstaller |
|
106 */ |
|
107 TInt CreateFolder( const TDesC& aFolderPath ); |
|
108 |
|
109 /** |
|
110 * From MCABrandInstaller |
|
111 */ |
|
112 TInt MoveFolder( const TDesC& aSourcePath, const TDesC& aDestFolder ); |
|
113 |
|
114 /** |
|
115 * From MCABrandInstaller |
|
116 */ |
|
117 TInt RemoveFolder( const TDesC& aFolderPath ); |
|
118 |
|
119 protected: // New functions |
|
120 |
|
121 protected: // Functions from base classes |
|
122 |
|
123 private: |
|
124 |
|
125 /** |
|
126 * C++ default constructor. |
|
127 */ |
|
128 CCABrandInstallerImp(); |
|
129 |
|
130 /** |
|
131 * By default Symbian 2nd phase constructor is private. |
|
132 */ |
|
133 void ConstructL(); |
|
134 |
|
135 private: // Data |
|
136 |
|
137 //Handle to eikon environment |
|
138 CEikonEnv* iEikEnv; |
|
139 // |
|
140 CFileMan* iFileMan; |
|
141 |
|
142 HBufC* iPrivatePath; |
|
143 }; |
|
144 |
|
145 #endif // CCABRANDINSTALLER_H |
|
146 |
|
147 // End of File |