|
1 /* |
|
2 * Copyright (c) 2005 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 |
|
19 #ifndef __TrkSWInstUIHandler_H__ |
|
20 #define __TrkSWInstUIHandler_H__ |
|
21 |
|
22 |
|
23 // Epoc Include |
|
24 #include <swi/msisuihandlers.h> |
|
25 |
|
26 //Macros |
|
27 #define KUserNameMaxLength 64 |
|
28 #define KPassword 64 |
|
29 |
|
30 |
|
31 enum KMyErrCode |
|
32 { |
|
33 KErrNothing, |
|
34 KErrLanguage, |
|
35 KErrDrive, |
|
36 KErrOptions, |
|
37 KErrAbortInstall, |
|
38 KErrAbortUnInstall, |
|
39 KErrLeave, |
|
40 KErrCannotOverwriteFile, |
|
41 KErrError |
|
42 }; |
|
43 |
|
44 |
|
45 using namespace Swi; |
|
46 |
|
47 class CTrkSWInstUIHandler : public CBase, public Swi::MUiHandler |
|
48 { |
|
49 public: |
|
50 static CTrkSWInstUIHandler* NewL(); |
|
51 |
|
52 static CTrkSWInstUIHandler* NewL(const TChar); |
|
53 |
|
54 ~CTrkSWInstUIHandler(); |
|
55 |
|
56 TBool DisplayInstallL (const CAppInfo& aAppInfo, |
|
57 const CApaMaskedBitmap* aLogo, |
|
58 const RPointerArray <CCertificateInfo> & aCertificates); |
|
59 |
|
60 TBool DisplayGrantCapabilitiesL(const CAppInfo& aAppInfo, |
|
61 const TCapabilitySet& aCapabilitySet); |
|
62 |
|
63 TInt DisplayLanguageL(const CAppInfo& aAppInfo, |
|
64 const RArray<TLanguage>& aLanguages); |
|
65 |
|
66 TInt DisplayDriveL(const CAppInfo& aAppInfo, |
|
67 TInt64 aSize, |
|
68 const RArray<TChar>& aDriveLetters, |
|
69 const RArray<TInt64>& aDriveSpaces); |
|
70 |
|
71 TBool DisplayUpgradeL(const CAppInfo& aAppInfo, |
|
72 const CAppInfo& aExistingAppInfo); |
|
73 |
|
74 TBool DisplayOptionsL(const CAppInfo& aAppInfo, |
|
75 const RPointerArray<TDesC>& aOptions, |
|
76 RArray<TBool>& aSelections); |
|
77 |
|
78 TBool HandleInstallEventL(const CAppInfo& aAppInfo, |
|
79 TInstallEvent aEvent, |
|
80 TInt aValue=0, |
|
81 const TDesC& aDes=KNullDesC); |
|
82 |
|
83 void HandleCancellableInstallEventL(const CAppInfo& aAppInfo, |
|
84 TInstallCancellableEvent aEvent, |
|
85 MCancelHandler& aCancelHandler, |
|
86 TInt aValue=0, |
|
87 const TDesC& aDes=KNullDesC); |
|
88 |
|
89 TBool DisplaySecurityWarningL(const CAppInfo& aAppInfo, |
|
90 Swi::TSignatureValidationResult aSigValidationResult, |
|
91 RPointerArray<CPKIXValidationResultBase>& aPkixResults, |
|
92 RPointerArray<CCertificateInfo>& aCertificates, |
|
93 TBool aInstallAnyway); |
|
94 |
|
95 TBool DisplayOcspResultL(const CAppInfo& aAppInfo, |
|
96 TRevocationDialogMessage aMessage, |
|
97 RPointerArray<TOCSPOutcome>& aOutcomes, |
|
98 RPointerArray<CCertificateInfo>& aCertificates, |
|
99 TBool aWarningOnly); |
|
100 |
|
101 void DisplayCannotOverwriteFileL(const CAppInfo& aAppInfo, |
|
102 const CAppInfo& aInstalledAppInfo, |
|
103 const TDesC& aFileName); |
|
104 |
|
105 TBool DisplayUninstallL(const CAppInfo& aAppInfo); |
|
106 |
|
107 |
|
108 TBool DisplayTextL(const CAppInfo& aAppInfo, |
|
109 TFileTextOption aOption, |
|
110 const TDesC& aText); |
|
111 |
|
112 void DisplayErrorL(const CAppInfo& aAppInfo, |
|
113 TErrorDialog aType, |
|
114 const TDesC& aParam); |
|
115 |
|
116 TBool DisplayDependencyBreakL(const CAppInfo& aAppInfo, |
|
117 const RPointerArray<TDesC>& aComponents); |
|
118 |
|
119 TBool DisplayApplicationsInUseL(const CAppInfo& aAppInfo, const RPointerArray<TDesC>& aAppNames); |
|
120 |
|
121 TBool DisplayQuestionL(const CAppInfo& aAppInfo, TQuestionDialog aQuestion, const TDesC& aDes=KNullDesC); |
|
122 |
|
123 TBool DisplayMissingDependencyL(const CAppInfo& aAppInfo, |
|
124 const TDesC& aDependencyName, |
|
125 TVersion aWantedVersionFrom, |
|
126 TVersion aWantedVersionTo, |
|
127 TVersion aInstalledVersion); |
|
128 |
|
129 TBool iDispInstall; |
|
130 TBool iDispGrantCapabilities; |
|
131 TBool iDispUnInstall; |
|
132 TInt iDispLanguage; |
|
133 TInt iDispDialect; |
|
134 TChar iDispDrive; |
|
135 TBool iDispUpgrade; |
|
136 TBool iDispDependencyBreak; |
|
137 TBool iDispQuestion; |
|
138 TBool iDispSecurityWarning; |
|
139 TBool iDispRevocationQuery; |
|
140 TBool iDispApplicationInUse; |
|
141 TBool iDispTextDialog; |
|
142 TInt iDispOptions; |
|
143 TInt iAppUID; |
|
144 |
|
145 KMyErrCode iErrCode; |
|
146 |
|
147 private: |
|
148 CTrkSWInstUIHandler(); |
|
149 CTrkSWInstUIHandler(const TChar aInstallDrive); |
|
150 |
|
151 void ConstructL(); |
|
152 }; |
|
153 |
|
154 #endif //__TrkSWInstUIHandler_H__ |
|
155 |