equal
deleted
inserted
replaced
|
1 // Copyright (c) 2007-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 "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 #include "swdirectgdidriverimpl.h" |
|
17 #include <graphics/directgdidriverinternal.h> |
|
18 |
|
19 /** |
|
20 Creates an object of the derived class i.e. CDirectGdiDriverImpl |
|
21 |
|
22 @param aInternal A reference to a CDirectGdiDriverInternal pointer. |
|
23 @param aLibrary A handle to the adapter library. Only used on WINS. |
|
24 |
|
25 @pre CDirectGdiDriver object has been initialised from the calling thread. |
|
26 @post Instance of CDirectGdiDriverImpl has been created. |
|
27 |
|
28 @return KErrNone if successful, KErrNoMemory if not enough memory could be allocated. |
|
29 */ |
|
30 EXPORT_C TInt CDirectGdiDriverInternal::New(CDirectGdiDriverInternal*& aInternal, RLibrary aLibrary) |
|
31 { |
|
32 CDirectGdiDriverInternal* internalDriver = new CSwDirectGdiDriverImpl(aLibrary); |
|
33 if(!internalDriver) |
|
34 return KErrNoMemory; |
|
35 |
|
36 aInternal = internalDriver; |
|
37 return KErrNone; |
|
38 } |