|
1 /* |
|
2 * Copyright (c) 2007 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 MCSBITMAPBUFFER_H_ |
|
20 #define MCSBITMAPBUFFER_H_ |
|
21 |
|
22 #include <liwvariant.h> |
|
23 #include <liwvariant.h> |
|
24 #include <liwbufferextension.h> |
|
25 |
|
26 |
|
27 /** |
|
28 * |
|
29 */ |
|
30 class CMcsBitmapBuffer : public CLiwBitmapBuffer |
|
31 { |
|
32 public: |
|
33 |
|
34 /** |
|
35 * Two-phased constructor. |
|
36 * |
|
37 * @return CMcsBitmapBuffer* Pointer. |
|
38 */ |
|
39 static CMcsBitmapBuffer* NewL( CFbsBitmap* aBitmapPtr ); |
|
40 |
|
41 /** |
|
42 * Destructor |
|
43 */ |
|
44 virtual ~CMcsBitmapBuffer(); |
|
45 |
|
46 private: |
|
47 |
|
48 /** |
|
49 * Default Constructor. |
|
50 */ |
|
51 CMcsBitmapBuffer( CFbsBitmap* aBitmapPtr); |
|
52 |
|
53 public: |
|
54 |
|
55 /** |
|
56 * Returns the pointer to the underlying buffer. |
|
57 * |
|
58 * @return the pointer to the underlying buffer |
|
59 */ |
|
60 virtual TUint8* Buf() const; |
|
61 |
|
62 /** |
|
63 * Returns the length of the buffer data. |
|
64 * |
|
65 * @return the length of the buffer data |
|
66 */ |
|
67 virtual TInt Len(); |
|
68 |
|
69 /** |
|
70 * Releases the buffer. The service provider implementing concrete |
|
71 * buffer type should provide appropriate implementation. |
|
72 */ |
|
73 virtual void Release(); |
|
74 |
|
75 /** |
|
76 * Returns the appropriate type of buffer. |
|
77 */ |
|
78 virtual TInt TypeID(); |
|
79 |
|
80 /** |
|
81 * This returns the pointer of the type CFbsBitmap. |
|
82 * @return platform specific bitmap representation. By default, |
|
83 * this method returns NULL |
|
84 */ |
|
85 virtual CFbsBitmap* AsBitmap(); |
|
86 |
|
87 public: |
|
88 |
|
89 CFbsBitmap* iBitmapPtr; |
|
90 |
|
91 private: |
|
92 /** |
|
93 * Dummy implementation for == operator not applicable in this case. |
|
94 */ |
|
95 TBool operator==( CLiwBuffer& /*aBuffer*/ ) |
|
96 { |
|
97 return ETrue; |
|
98 } |
|
99 }; |
|
100 |
|
101 #endif /*MCSBITMAPBUFFER_H_*/ |
|
102 |
|
103 // End of file |