|
1 /* |
|
2 * Copyright (c) 2007 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 "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: Creates extension's instances. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 // INCLUDE FILES |
|
20 #include "clogsextensionfactory.h" |
|
21 |
|
22 #include "clogsviewextension.h" |
|
23 #include "clogsuicontrolextension.h" |
|
24 #include "simpledebug.h" |
|
25 |
|
26 // ================= MEMBER FUNCTIONS ======================= |
|
27 |
|
28 |
|
29 // --------------------------------------------------------------------------- |
|
30 // Constructor |
|
31 // --------------------------------------------------------------------------- |
|
32 // |
|
33 inline CLogsExtensionFactory::CLogsExtensionFactory() |
|
34 { |
|
35 _LOG("CLogsExtensionFactory::CLogsExtensionFactory()" ) |
|
36 } |
|
37 |
|
38 |
|
39 // --------------------------------------------------------------------------- |
|
40 // NewL |
|
41 // --------------------------------------------------------------------------- |
|
42 // |
|
43 CLogsExtensionFactory* CLogsExtensionFactory::NewL() |
|
44 { |
|
45 |
|
46 _LOG("CLogsExtensionFactory::NewL()" ) |
|
47 |
|
48 return new (ELeave) CLogsExtensionFactory; |
|
49 } |
|
50 |
|
51 |
|
52 // --------------------------------------------------------------------------- |
|
53 // Destructor |
|
54 // --------------------------------------------------------------------------- |
|
55 // |
|
56 CLogsExtensionFactory::~CLogsExtensionFactory() |
|
57 { |
|
58 _LOG("CLogsExtensionFactory::~CLogsExtensionFactory()" ) |
|
59 } |
|
60 |
|
61 |
|
62 // --------------------------------------------------------------------------- |
|
63 // Releases the factory. |
|
64 // --------------------------------------------------------------------------- |
|
65 // |
|
66 void CLogsExtensionFactory::Release() |
|
67 { |
|
68 _LOG("CLogsExtensionFactory::Release() begin" ) |
|
69 delete this; |
|
70 _LOG("CLogsExtensionFactory::Release() end" ) |
|
71 } |
|
72 |
|
73 |
|
74 // --------------------------------------------------------------------------- |
|
75 // Ownership of view is transferred to the caller. |
|
76 // --------------------------------------------------------------------------- |
|
77 // |
|
78 MLogsViewExtension* CLogsExtensionFactory::CreateLogsViewExtensionL |
|
79 (CPbkContactEngine& /*aEngine*/, MLogsExtObserver* /*aObserver*/) |
|
80 { |
|
81 _LOG("CLogsExtensionFactory::CreateLogsViewExtensionL() start" ) |
|
82 |
|
83 iViewExtension = CLogsViewExtension::NewL(); |
|
84 |
|
85 _LOG("CLogsExtensionFactory::CreateLogsViewExtensionL() end" ) |
|
86 return iViewExtension; |
|
87 } |
|
88 |
|
89 |
|
90 // --------------------------------------------------------------------------- |
|
91 // Ownership of extension is transferred to the caller. |
|
92 // --------------------------------------------------------------------------- |
|
93 // |
|
94 MLogsUiControlExtension* CLogsExtensionFactory::CreateLogsUiControlExtensionL() |
|
95 { |
|
96 _LOG("CLogsExtensionFactory::CreateLogsUiControlExtensionL() start" ) |
|
97 |
|
98 iControlExtension = CLogsUiControlExtension::NewL(); |
|
99 |
|
100 _LOG("CLogsExtensionFactory::CreateLogsUiControlExtensionL() end" ) |
|
101 return iControlExtension; |
|
102 } |
|
103 |
|
104 // End of File |