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 |
//
|
sl@0
|
15 |
|
sl@0
|
16 |
#ifndef DIRECTGDIDRAWABLESOURCE_H
|
sl@0
|
17 |
#define DIRECTGDIDRAWABLESOURCE_H
|
sl@0
|
18 |
|
sl@0
|
19 |
/**
|
sl@0
|
20 |
@file
|
sl@0
|
21 |
@publishedPartner
|
sl@0
|
22 |
@prototype
|
sl@0
|
23 |
*/
|
sl@0
|
24 |
|
sl@0
|
25 |
#include <e32def.h>
|
sl@0
|
26 |
|
sl@0
|
27 |
// Forward declarations.
|
sl@0
|
28 |
//
|
sl@0
|
29 |
class RSgDrawable;
|
sl@0
|
30 |
class CDirectGdiDriver;
|
sl@0
|
31 |
|
sl@0
|
32 |
/**
|
sl@0
|
33 |
This class is a handle to a DirectGDI adaptation-specific resource that is bound
|
sl@0
|
34 |
to a non-image resource (RSgDrawable). The intention of creating this class is to allow
|
sl@0
|
35 |
a non-image resource (global and sharable between processes) to be used as a source from
|
sl@0
|
36 |
the DirectGDI rendering API. This class and its DirectGDI adaptation-specific resource are
|
sl@0
|
37 |
non-sharable and will be local to the calling thread.
|
sl@0
|
38 |
|
sl@0
|
39 |
This class is part of generic code and will forward creation and deletion requests
|
sl@0
|
40 |
to the CDirectGdiDriver singleton object for the calling thread.
|
sl@0
|
41 |
|
sl@0
|
42 |
@publishedPartner
|
sl@0
|
43 |
@prototype
|
sl@0
|
44 |
@deprecated
|
sl@0
|
45 |
*/
|
sl@0
|
46 |
NONSHARABLE_CLASS(RDirectGdiDrawableSource)
|
sl@0
|
47 |
{
|
sl@0
|
48 |
friend class CDirectGdiDriver;
|
sl@0
|
49 |
|
sl@0
|
50 |
public:
|
sl@0
|
51 |
IMPORT_C RDirectGdiDrawableSource();
|
sl@0
|
52 |
IMPORT_C RDirectGdiDrawableSource(CDirectGdiDriver& aDriver);
|
sl@0
|
53 |
IMPORT_C TInt Create(const RSgDrawable& aDrawable);
|
sl@0
|
54 |
IMPORT_C void Close();
|
sl@0
|
55 |
inline TInt Handle() const;
|
sl@0
|
56 |
|
sl@0
|
57 |
private:
|
sl@0
|
58 |
CDirectGdiDriver* iDriver;
|
sl@0
|
59 |
TInt iHandle;
|
sl@0
|
60 |
};
|
sl@0
|
61 |
|
sl@0
|
62 |
#include <graphics/directgdidrawablesource.inl>
|
sl@0
|
63 |
|
sl@0
|
64 |
#endif // DIRECTGDIDRAWABLESOURCE_H
|