|
1 /* |
|
2 * Copyright (c) 2000-2009 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 the License "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 * HelloWorld |
|
16 * The example is a simple application containing a single view with |
|
17 * the text "Hello World !" drawn on it. |
|
18 * The example includes code for displaying a very simple menu. |
|
19 * This source file contains the single exported function required by |
|
20 * all UI applications and the E32Dll function which is also required |
|
21 * but is not used here. |
|
22 * |
|
23 */ |
|
24 |
|
25 |
|
26 |
|
27 #include "HelloWorld.h" |
|
28 |
|
29 |
|
30 // The entry point for the application code. It creates |
|
31 // an instance of the CApaApplication derived |
|
32 // class, CExampleApplication. |
|
33 // |
|
34 |
|
35 #if defined(EKA2) |
|
36 |
|
37 #include <eikstart.h> |
|
38 LOCAL_C CApaApplication* NewApplication() |
|
39 { |
|
40 return new CExampleApplication; |
|
41 } |
|
42 |
|
43 GLDEF_C TInt E32Main() |
|
44 { |
|
45 return EikStart::RunApplication(NewApplication); |
|
46 } |
|
47 |
|
48 #endif |
|
49 |
|
50 #if defined(__WINS__) && !defined(EKA2) |
|
51 // This function is required by all Symbian OS DLLs. In this |
|
52 // example, it does nothing. |
|
53 |
|
54 EXPORT_C CApaApplication* NewApplication() |
|
55 { |
|
56 return new CExampleApplication; |
|
57 } |
|
58 |
|
59 GLDEF_C TInt E32Dll(TDllReason) |
|
60 { |
|
61 return KErrNone; |
|
62 } |
|
63 |
|
64 EXPORT_C TInt WinsMain(TDesC* aCmdLine) |
|
65 { |
|
66 return EikStart::RunApplication(NewApplication, aCmdLine); |
|
67 } |
|
68 |
|
69 #endif |