|
1 // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of the License "Symbian Foundation License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.symbianfoundation.org/legal/sfl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 #ifndef __APAPRIV_H__ |
|
17 #define __APAPRIV_H__ |
|
18 |
|
19 #if !defined(__E32STD_H__) |
|
20 #include <e32std.h> |
|
21 #endif |
|
22 #if !defined(__S32MEM_H__) |
|
23 #include <s32mem.h> |
|
24 #endif |
|
25 #if !defined(__GDI_H__) |
|
26 #include <gdi.h> |
|
27 #endif |
|
28 #include <apaid.h> |
|
29 |
|
30 // classes referenced: |
|
31 class CApaMaskedBitmap; |
|
32 // |
|
33 |
|
34 class HBufBuf : public TBufBuf |
|
35 { |
|
36 public: |
|
37 static HBufBuf* NewL(CBufBase& aBuf,TInt aPos,TInt aMode=ERead|EWrite); |
|
38 private: |
|
39 void DoRelease(); |
|
40 }; |
|
41 |
|
42 |
|
43 class CApaIconPicture : public CPicture |
|
44 { |
|
45 public: |
|
46 static CApaIconPicture* NewL(const TSize& aIconSizeInTwips, const TUid aAppUid); |
|
47 // |
|
48 void Draw(CGraphicsContext& aGc,const TPoint& aTopLeft,const TRect& aClipRect,MGraphicsDeviceMap* aMap)const; |
|
49 TPictureCapability Capability() const; |
|
50 TInt ScaleFactorWidth() const; |
|
51 TInt ScaleFactorHeight() const; |
|
52 void SetScaleFactor(TInt aScaleFactorWidth,TInt aScaleFactorHeight); |
|
53 void GetOriginalSizeInTwips(TSize& aOriginalSize) const; |
|
54 // |
|
55 void InternalizeL(RReadStream& aStream); |
|
56 void ExternalizeL(RWriteStream& aStream)const; |
|
57 ~CApaIconPicture(); |
|
58 private: |
|
59 CApaIconPicture(const TSize& aIconSizeInTwips, const TUid aAppUid); |
|
60 void ConstructL(); |
|
61 void CreateIconL(); |
|
62 private: |
|
63 CApaMaskedBitmap* iIcon; // null unless the current format is EIcon |
|
64 TUid iAppUid; |
|
65 TSize iOriginalSizeInTwips; |
|
66 TInt iScaleFactorWidth; // Stored as percent * 10 |
|
67 TInt iScaleFactorHeight; // Stored as percent * 10 |
|
68 TSize iDisplaySizeInPixels; |
|
69 TSize iDisplaySizeInTwips; |
|
70 }; |
|
71 |
|
72 class CApaAppServiceInfoArrayWrapper : public CApaAppServiceInfoArray |
|
73 { |
|
74 public: |
|
75 static CApaAppServiceInfoArrayWrapper* NewL(CArrayFix<TApaAppServiceInfo>* aServiceInfoArray); |
|
76 ~CApaAppServiceInfoArrayWrapper(); |
|
77 TArray<TApaAppServiceInfo> Array(); |
|
78 private: |
|
79 CApaAppServiceInfoArrayWrapper(CArrayFix<TApaAppServiceInfo>* aServiceInfoArray); |
|
80 private: |
|
81 CArrayFix<TApaAppServiceInfo>* iServiceInfoArray; |
|
82 }; |
|
83 |
|
84 |
|
85 |
|
86 |
|
87 #endif |