sl@0
|
1 |
// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
|
sl@0
|
2 |
// All rights reserved.
|
sl@0
|
3 |
// This component and the accompanying materials are made available
|
sl@0
|
4 |
// under the terms of "Eclipse Public License v1.0"
|
sl@0
|
5 |
// which accompanies this distribution, and is available
|
sl@0
|
6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
sl@0
|
7 |
//
|
sl@0
|
8 |
// Initial Contributors:
|
sl@0
|
9 |
// Nokia Corporation - initial contribution.
|
sl@0
|
10 |
//
|
sl@0
|
11 |
// Contributors:
|
sl@0
|
12 |
//
|
sl@0
|
13 |
// Description:
|
sl@0
|
14 |
// This class represents the body part of CDirectGdiDriver that defines the HAI.
|
sl@0
|
15 |
//
|
sl@0
|
16 |
//
|
sl@0
|
17 |
|
sl@0
|
18 |
|
sl@0
|
19 |
#ifndef __DIRECTGDIDRIVERINTERNAL_H__
|
sl@0
|
20 |
#define __DIRECTGDIDRIVERINTERNAL_H__
|
sl@0
|
21 |
|
sl@0
|
22 |
/**
|
sl@0
|
23 |
@file
|
sl@0
|
24 |
@publishedPartner
|
sl@0
|
25 |
@prototype
|
sl@0
|
26 |
*/
|
sl@0
|
27 |
|
sl@0
|
28 |
#include <e32base.h>
|
sl@0
|
29 |
|
sl@0
|
30 |
//forward declarations
|
sl@0
|
31 |
class RSgDrawable;
|
sl@0
|
32 |
class RSgImage;
|
sl@0
|
33 |
class MDirectGdiEngine;
|
sl@0
|
34 |
|
sl@0
|
35 |
/**
|
sl@0
|
36 |
This class represents the body part of CDirectGdiDriver that defines the HAI.
|
sl@0
|
37 |
An adaptation must derive from this class and implement all the interfaces to
|
sl@0
|
38 |
provide the functionality required by the generic layer.
|
sl@0
|
39 |
|
sl@0
|
40 |
@publishedPartner
|
sl@0
|
41 |
@prototype
|
sl@0
|
42 |
@deprecated
|
sl@0
|
43 |
*/
|
sl@0
|
44 |
class CDirectGdiDriverInternal : public CBase
|
sl@0
|
45 |
{
|
sl@0
|
46 |
public:
|
sl@0
|
47 |
IMPORT_C static TInt New(CDirectGdiDriverInternal*& aInternal, RLibrary aLibrary);
|
sl@0
|
48 |
inline RLibrary Library() const;
|
sl@0
|
49 |
|
sl@0
|
50 |
/**
|
sl@0
|
51 |
@see CDirectGdiDriver::Flush()
|
sl@0
|
52 |
*/
|
sl@0
|
53 |
virtual void Flush() = 0;
|
sl@0
|
54 |
|
sl@0
|
55 |
/**
|
sl@0
|
56 |
@see CDirectGdiDriver::Finish()
|
sl@0
|
57 |
*/
|
sl@0
|
58 |
virtual void Finish() = 0;
|
sl@0
|
59 |
|
sl@0
|
60 |
/**
|
sl@0
|
61 |
@see CDirectGdiDriver::GetError()
|
sl@0
|
62 |
*/
|
sl@0
|
63 |
virtual TInt GetError() = 0;
|
sl@0
|
64 |
|
sl@0
|
65 |
/**
|
sl@0
|
66 |
@see CDirectGdiDriver::SetError()
|
sl@0
|
67 |
*/
|
sl@0
|
68 |
virtual void SetError(TInt aErr) = 0;
|
sl@0
|
69 |
|
sl@0
|
70 |
/**
|
sl@0
|
71 |
@see CDirectGdiDriver::CreateDrawableSource()
|
sl@0
|
72 |
|
sl@0
|
73 |
@param aHandle Handle of the newly created drawable source.
|
sl@0
|
74 |
@param aRSgDrawable The RSgDrawable object to use when creating the drawable source.
|
sl@0
|
75 |
*/
|
sl@0
|
76 |
virtual TInt CreateDrawableSource(TInt& aHandle, const RSgDrawable& aRSgDrawable) = 0;
|
sl@0
|
77 |
|
sl@0
|
78 |
/**
|
sl@0
|
79 |
@see CDirectGdiDriver::CloseDrawableSource()
|
sl@0
|
80 |
|
sl@0
|
81 |
@param aHandle A handle to a RDirectGdiDrawableSource object to be closed.
|
sl@0
|
82 |
*/
|
sl@0
|
83 |
virtual void CloseDrawableSource(TInt& aHandle) = 0;
|
sl@0
|
84 |
|
sl@0
|
85 |
/**
|
sl@0
|
86 |
@see CDirectGdiDriver::CreateImageTarget()
|
sl@0
|
87 |
|
sl@0
|
88 |
@param aHandle Handle of the newly created image target.
|
sl@0
|
89 |
@param aRSgImage The RSgImage to use when creating the image target.
|
sl@0
|
90 |
*/
|
sl@0
|
91 |
virtual TInt CreateImageTarget(TInt& aHandle, const RSgImage& aRSgImage) = 0;
|
sl@0
|
92 |
|
sl@0
|
93 |
/**
|
sl@0
|
94 |
@see CDirectGdiDriver::CloseImageTarget()
|
sl@0
|
95 |
|
sl@0
|
96 |
@param aHandle A handle to a RDirectGdiImageTarget object to be closed.
|
sl@0
|
97 |
*/
|
sl@0
|
98 |
virtual void CloseImageTarget(TInt& aHandle) = 0;
|
sl@0
|
99 |
|
sl@0
|
100 |
/**
|
sl@0
|
101 |
@see CDirectGdiDriver::CreateEngine()
|
sl@0
|
102 |
*/
|
sl@0
|
103 |
virtual TInt CreateEngine(MDirectGdiEngine*& aEngine) = 0;
|
sl@0
|
104 |
|
sl@0
|
105 |
/**
|
sl@0
|
106 |
@see CDirectGdiDriver::DestroyEngine()
|
sl@0
|
107 |
*/
|
sl@0
|
108 |
virtual void DestroyEngine(MDirectGdiEngine* aEngine) = 0;
|
sl@0
|
109 |
|
sl@0
|
110 |
/**
|
sl@0
|
111 |
@see CDirectGdiDriver::GetInterface()
|
sl@0
|
112 |
*/
|
sl@0
|
113 |
virtual TInt GetInterface(TUid aInterfaceId, TAny*& aInterface) = 0;
|
sl@0
|
114 |
|
sl@0
|
115 |
protected:
|
sl@0
|
116 |
inline CDirectGdiDriverInternal(RLibrary aLibrary);
|
sl@0
|
117 |
private:
|
sl@0
|
118 |
/** Handle to the DirectGDI adapter DLL owned by this thread.*/
|
sl@0
|
119 |
const RLibrary iAdapterLibrary;
|
sl@0
|
120 |
};
|
sl@0
|
121 |
|
sl@0
|
122 |
#include <graphics/directgdidriverinternal.inl>
|
sl@0
|
123 |
|
sl@0
|
124 |
|
sl@0
|
125 |
#endif //__DIRECTGDIDRIVERINTERNAL_H__
|