mpviewplugins/mpcollectionviewplugin/tsrc/unittest_mpcollectioncontainers/stub/src/mpenginefactory.cpp
equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 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 "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: MpEngineFactory stub for testing mpplaybackview |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #include "stub/inc/mpenginefactory.h" |
|
20 #include "stub/inc/mpplaybackdata.h" |
|
21 #include "stub/inc/mpengine.h" |
|
22 |
|
23 |
|
24 |
|
25 /*! |
|
26 * Stub function |
|
27 */ |
|
28 |
|
29 /*! |
|
30 * Stub function |
|
31 */ |
|
32 MpEngineFactory::MpEngineFactory() |
|
33 : mSharedEngine( 0 ) |
|
34 { |
|
35 } |
|
36 |
|
37 /*! |
|
38 * Stub function |
|
39 */ |
|
40 MpEngineFactory::~MpEngineFactory() |
|
41 { |
|
42 } |
|
43 |
|
44 /*! |
|
45 * Stub function |
|
46 */ |
|
47 MpEngineFactory * MpEngineFactory::instance() |
|
48 { |
|
49 static MpEngineFactory instance; |
|
50 return &instance; |
|
51 } |
|
52 |
|
53 /*! |
|
54 * Stub function |
|
55 */ |
|
56 MpEngine *MpEngineFactory::sharedEngine() |
|
57 { |
|
58 if ( !instance()->mSharedEngine ) { |
|
59 instance()->mSharedEngine = new MpEngine(); |
|
60 } |
|
61 return instance()->mSharedEngine; |
|
62 } |