|
1 /* |
|
2 * Copyright (c) 2006 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 * |
|
16 */ |
|
17 |
|
18 |
|
19 #include "WidgetUiApp.h" |
|
20 #include "WidgetUiDocument.h" |
|
21 #include "MemoryManager.h" |
|
22 #include "widgetappdefs.rh" |
|
23 #include <eikstart.h> |
|
24 |
|
25 // EXTERNAL DATA STRUCTURES |
|
26 |
|
27 // EXTERNAL FUNCTION PROTOTYPES |
|
28 |
|
29 // CONSTANTS |
|
30 |
|
31 // MACROS |
|
32 |
|
33 // LOCAL CONSTANTS AND MACROS |
|
34 |
|
35 // MODULE DATA STRUCTURES |
|
36 |
|
37 // LOCAL FUNCTION PROTOTYPES |
|
38 |
|
39 // FORWARD DECLARATIONS |
|
40 |
|
41 // ============================= LOCAL FUNCTIONS =============================== |
|
42 |
|
43 |
|
44 // ============================ MEMBER FUNCTIONS =============================== |
|
45 |
|
46 // ----------------------------------------------------------------------------- |
|
47 // CWidgetUiApp::AppDllUid() |
|
48 // Returns application UID |
|
49 // ----------------------------------------------------------------------------- |
|
50 // |
|
51 TUid CWidgetUiApp::AppDllUid() const |
|
52 { |
|
53 return KUidWidgetUi; |
|
54 } |
|
55 |
|
56 // ----------------------------------------------------------------------------- |
|
57 // CWidgetUiApp::OpenIniFileLC() |
|
58 // overrides CAknApplication::OpenIniFileLC to enable INI file support |
|
59 // ----------------------------------------------------------------------------- |
|
60 // |
|
61 CDictionaryStore* CWidgetUiApp::OpenIniFileLC( |
|
62 RFs& aFs ) const |
|
63 { |
|
64 return CEikApplication::OpenIniFileLC( aFs ); |
|
65 } |
|
66 |
|
67 // ----------------------------------------------------------------------------- |
|
68 // CWidgetUiApp::CreateDocumentL() |
|
69 // Creates CWidgetUiDocument object |
|
70 // ----------------------------------------------------------------------------- |
|
71 // |
|
72 CApaDocument* CWidgetUiApp::CreateDocumentL() |
|
73 { |
|
74 return CWidgetUiDocument::NewL( *this ); |
|
75 } |
|
76 |
|
77 // ================= OTHER EXPORTED FUNCTIONS ============== |
|
78 |
|
79 // ----------------------------------------------------------------------------- |
|
80 // NewApplication |
|
81 // |
|
82 // |
|
83 // ----------------------------------------------------------------------------- |
|
84 // |
|
85 LOCAL_C CApaApplication* NewApplication( ) |
|
86 { |
|
87 return new CWidgetUiApp; |
|
88 } |
|
89 |
|
90 // ----------------------------------------------------------------------------- |
|
91 // E32Main |
|
92 // |
|
93 // ----------------------------------------------------------------------------- |
|
94 // |
|
95 GLDEF_C TInt E32Main() |
|
96 { |
|
97 RAllocator* oldAllocator = MemoryManager::SwitchToFastAllocator(); |
|
98 __UHEAP_MARK; |
|
99 TInt result = EikStart::RunApplication( NewApplication ); |
|
100 __UHEAP_MARKEND; |
|
101 MemoryManager::CloseFastAllocator(oldAllocator); |
|
102 return result; |
|
103 } |
|
104 |
|
105 // End of File |