30
|
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: Implementation of VideoServicePlay
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
44
|
18 |
// Version : %version: da1mmcf#6 %
|
30
|
19 |
|
36
|
20 |
#include "videoservices.h"
|
30
|
21 |
#include "videoserviceplay.h"
|
|
22 |
#include "videoplayerengine.h"
|
36
|
23 |
#include "mpxvideo_debug.h"
|
30
|
24 |
|
|
25 |
|
36
|
26 |
// -------------------------------------------------------------------------------------------------
|
|
27 |
// VideoServicePlay()
|
|
28 |
// -------------------------------------------------------------------------------------------------
|
|
29 |
//
|
38
|
30 |
VideoServicePlay::VideoServicePlay( VideoServices* parent,
|
44
|
31 |
VideoPlayerEngine* engine,
|
38
|
32 |
QLatin1String service )
|
|
33 |
: XQServiceProvider( service, parent )
|
36
|
34 |
, mEngine( engine )
|
|
35 |
, mServiceApp( parent )
|
30
|
36 |
{
|
36
|
37 |
MPX_ENTER_EXIT(_L("VideoServicePlay::VideoServicePlay()"));
|
30
|
38 |
publishAll();
|
|
39 |
}
|
|
40 |
|
36
|
41 |
// -------------------------------------------------------------------------------------------------
|
|
42 |
// ~VideoServicePlay()
|
|
43 |
// -------------------------------------------------------------------------------------------------
|
|
44 |
//
|
30
|
45 |
VideoServicePlay::~VideoServicePlay()
|
|
46 |
{
|
36
|
47 |
MPX_DEBUG(_L("VideoServicePlay::~VideoServicePlay()"));
|
30
|
48 |
}
|
|
49 |
|
36
|
50 |
// -------------------------------------------------------------------------------------------------
|
|
51 |
// setEngine()
|
|
52 |
// -------------------------------------------------------------------------------------------------
|
|
53 |
//
|
44
|
54 |
void VideoServicePlay::setEngine( VideoPlayerEngine* engine )
|
30
|
55 |
{
|
36
|
56 |
MPX_DEBUG(_L("VideoServicePlay::setEngine()"));
|
|
57 |
mEngine = engine;
|
30
|
58 |
}
|
|
59 |
|
36
|
60 |
// -------------------------------------------------------------------------------------------------
|
|
61 |
// playMedia()
|
|
62 |
// -------------------------------------------------------------------------------------------------
|
|
63 |
//
|
30
|
64 |
void VideoServicePlay::playMedia( QString filePath )
|
|
65 |
{
|
36
|
66 |
MPX_ENTER_EXIT(_L("VideoServicePlay::playMedia()"),
|
|
67 |
_L("filePath = %s"), filePath.data() );
|
|
68 |
|
|
69 |
if ( mEngine )
|
30
|
70 |
{
|
36
|
71 |
mServiceApp->setCurrentService( VideoServices::EPlayback );
|
30
|
72 |
mEngine->playMedia( filePath );
|
|
73 |
}
|
|
74 |
}
|
|
75 |
|
36
|
76 |
// -------------------------------------------------------------------------------------------------
|
|
77 |
// playPDLMedia()
|
|
78 |
// -------------------------------------------------------------------------------------------------
|
|
79 |
//
|
30
|
80 |
void VideoServicePlay::playPDLMedia( QString filePath, int downloadID )
|
|
81 |
{
|
36
|
82 |
MPX_DEBUG(_L("VideoServicePlay::playPDLMedia()"));
|
|
83 |
Q_UNUSED( filePath );
|
|
84 |
Q_UNUSED( downloadID );
|
30
|
85 |
}
|
|
86 |
|
36
|
87 |
// -------------------------------------------------------------------------------------------------
|
|
88 |
// closePlayer()
|
|
89 |
// -------------------------------------------------------------------------------------------------
|
|
90 |
//
|
30
|
91 |
void VideoServicePlay::closePlayer()
|
|
92 |
{
|
36
|
93 |
MPX_DEBUG(_L("VideoServicePlay::closePlayer()"));
|
30
|
94 |
}
|
|
95 |
|