44
|
1 |
/*
|
|
2 |
* Copyright (c) 2010 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 VideoPlaybackFullScreenControl
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
63
|
18 |
// Version : %version: 6 %
|
44
|
19 |
|
|
20 |
|
|
21 |
|
|
22 |
#include <w32std.h>
|
|
23 |
|
|
24 |
#include "mpxvideo_debug.h"
|
|
25 |
#include "videoplaybackfullscreencontrol.h"
|
|
26 |
#include "videoplaybackfiledetailswidget.h"
|
|
27 |
#include "videoplaybackcontrolscontroller.h"
|
|
28 |
#include "videoplaybackdetailsplaybackwindow.h"
|
|
29 |
|
|
30 |
|
|
31 |
// -------------------------------------------------------------------------------------------------
|
|
32 |
// VideoPlaybackFullScreenControl::VideoPlaybackFullScreenControl()
|
|
33 |
// -------------------------------------------------------------------------------------------------
|
|
34 |
//
|
58
|
35 |
VideoPlaybackFullScreenControl::VideoPlaybackFullScreenControl(
|
|
36 |
VideoPlaybackControlsController* controller,
|
|
37 |
TVideoPlaybackControls index,
|
|
38 |
HbWidget* widget,
|
44
|
39 |
TUint controlproperties )
|
|
40 |
: mController( controller )
|
|
41 |
, mControl( widget )
|
|
42 |
, mControlIndex( index )
|
|
43 |
, mProperties( controlproperties )
|
58
|
44 |
, mControlReset( false )
|
44
|
45 |
{
|
|
46 |
MPX_ENTER_EXIT(_L("VideoPlaybackFullScreenControl::VideoPlaybackFullScreenControl()"));
|
|
47 |
|
|
48 |
setParent( mController );
|
|
49 |
}
|
|
50 |
|
|
51 |
// -------------------------------------------------------------------------------------------------
|
|
52 |
// VideoPlaybackFullScreenControl::~VideoPlaybackFullScreenControl()
|
|
53 |
// -------------------------------------------------------------------------------------------------
|
|
54 |
//
|
|
55 |
VideoPlaybackFullScreenControl::~VideoPlaybackFullScreenControl()
|
|
56 |
{
|
|
57 |
MPX_DEBUG(_L("VideoPlaybackControlsController::~VideoPlaybackFullScreenControl"));
|
|
58 |
}
|
|
59 |
|
|
60 |
// -------------------------------------------------------------------------------------------------
|
|
61 |
// VideoPlaybackFullScreenControl::setVisible()
|
|
62 |
// -------------------------------------------------------------------------------------------------
|
|
63 |
//
|
|
64 |
void VideoPlaybackFullScreenControl::setVisible( bool visible )
|
|
65 |
{
|
|
66 |
mVisible = visible;
|
|
67 |
}
|
|
68 |
|
|
69 |
// -------------------------------------------------------------------------------------------------
|
|
70 |
// VideoPlaybackFullScreenControl::isVisible()
|
|
71 |
// -------------------------------------------------------------------------------------------------
|
|
72 |
//
|
|
73 |
bool VideoPlaybackFullScreenControl::isVisible()
|
|
74 |
{
|
|
75 |
return mVisible;
|
|
76 |
}
|
|
77 |
|
|
78 |
// -------------------------------------------------------------------------------------------------
|
|
79 |
// VideoPlaybackFullScreenControl::setVisibility()
|
|
80 |
// -------------------------------------------------------------------------------------------------
|
|
81 |
//
|
|
82 |
void VideoPlaybackFullScreenControl::setVisibility( TMPXPlaybackState state )
|
|
83 |
{
|
|
84 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::setVisibility(%d)"), state);
|
58
|
85 |
|
44
|
86 |
mVisibilityState = state;
|
63
|
87 |
setVisible( true );
|
44
|
88 |
}
|
|
89 |
|
|
90 |
// -------------------------------------------------------------------------------------------------
|
|
91 |
// VideoPlaybackFullScreenControl::controlIndex()
|
|
92 |
// -------------------------------------------------------------------------------------------------
|
|
93 |
//
|
|
94 |
TVideoPlaybackControls VideoPlaybackFullScreenControl::controlIndex()
|
|
95 |
{
|
|
96 |
return mControlIndex;
|
|
97 |
}
|
|
98 |
|
|
99 |
// -------------------------------------------------------------------------------------------------
|
|
100 |
// VideoPlaybackFullScreenControl::volumeChanged()
|
|
101 |
// -------------------------------------------------------------------------------------------------
|
|
102 |
//
|
|
103 |
bool VideoPlaybackFullScreenControl::volumeChanged( int volume )
|
|
104 |
{
|
|
105 |
mVolume = volume;
|
|
106 |
return true;
|
|
107 |
}
|
|
108 |
|
|
109 |
// -------------------------------------------------------------------------------------------------
|
|
110 |
// VideoPlaybackFullScreenControl::durationChanged()
|
|
111 |
// -------------------------------------------------------------------------------------------------
|
|
112 |
//
|
|
113 |
bool VideoPlaybackFullScreenControl::durationChanged( int duration )
|
|
114 |
{
|
|
115 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::durationChanged() [%d]"), duration );
|
58
|
116 |
mDuration = duration;
|
44
|
117 |
return true;
|
|
118 |
}
|
|
119 |
|
|
120 |
// -------------------------------------------------------------------------------------------------
|
|
121 |
// VideoPlaybackFullScreenControl::positionChanged()
|
|
122 |
// -------------------------------------------------------------------------------------------------
|
|
123 |
//
|
|
124 |
bool VideoPlaybackFullScreenControl::positionChanged( int position )
|
58
|
125 |
{
|
44
|
126 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::positionChanged() [%d]"), position );
|
58
|
127 |
mPosition = position;
|
44
|
128 |
return true;
|
|
129 |
}
|
|
130 |
|
|
131 |
// -------------------------------------------------------------------------------------------------
|
|
132 |
// VideoPlaybackFullScreenControl::aspectRatioChanged()
|
|
133 |
// -------------------------------------------------------------------------------------------------
|
|
134 |
//
|
|
135 |
bool VideoPlaybackFullScreenControl::aspectRatioChanged( int aspectRatio )
|
|
136 |
{
|
|
137 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::aspectRatioChanged() [%d]"), aspectRatio );
|
|
138 |
mAspectRatio = aspectRatio;
|
58
|
139 |
return true;
|
44
|
140 |
}
|
|
141 |
|
|
142 |
// -------------------------------------------------------------------------------------------------
|
|
143 |
// VideoPlaybackFullScreenControl::setDownloadSize()
|
|
144 |
// -------------------------------------------------------------------------------------------------
|
|
145 |
//
|
|
146 |
bool VideoPlaybackFullScreenControl::setDownloadSize( int size )
|
|
147 |
{
|
|
148 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::setDownloadSize() [%d]"), size );
|
|
149 |
mDownloadSize = size;
|
|
150 |
return true;
|
|
151 |
}
|
|
152 |
|
|
153 |
// -------------------------------------------------------------------------------------------------
|
|
154 |
// VideoPlaybackFullScreenControl::updateDownloadPosition()
|
|
155 |
// -------------------------------------------------------------------------------------------------
|
|
156 |
//
|
|
157 |
bool VideoPlaybackFullScreenControl::updateDownloadPosition( int size )
|
|
158 |
{
|
|
159 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::updateDownloadPosition() [%d]"), size );
|
|
160 |
mDownloadPosition = size;
|
|
161 |
return true;
|
|
162 |
}
|
|
163 |
|
|
164 |
// -------------------------------------------------------------------------------------------------
|
|
165 |
// VideoPlaybackFullScreenControl::updateState()
|
|
166 |
// -------------------------------------------------------------------------------------------------
|
|
167 |
//
|
|
168 |
void VideoPlaybackFullScreenControl::updateState( TMPXPlaybackState state )
|
|
169 |
{
|
|
170 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::updateState() [%d]"), state );
|
58
|
171 |
mState = state;
|
44
|
172 |
}
|
|
173 |
|
|
174 |
// -------------------------------------------------------------------------------------------------
|
|
175 |
// VideoPlaybackFullScreenControl::updateControlsWithFileDetails()
|
|
176 |
// -------------------------------------------------------------------------------------------------
|
|
177 |
//
|
|
178 |
void VideoPlaybackFullScreenControl::updateControlsWithFileDetails(
|
|
179 |
VideoPlaybackViewFileDetails* details )
|
|
180 |
{
|
|
181 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::updateControlsWithFileDetails()") );
|
|
182 |
Q_UNUSED( details );
|
|
183 |
}
|
|
184 |
|
|
185 |
// -------------------------------------------------------------------------------------------------
|
|
186 |
// VideoPlaybackFullScreenControl::updateControlProperties()
|
|
187 |
// -------------------------------------------------------------------------------------------------
|
|
188 |
//
|
|
189 |
void VideoPlaybackFullScreenControl::updateControlProperties( TUint properties )
|
|
190 |
{
|
|
191 |
MPX_DEBUG(_L("VideoPlaybackFullScreenControl::updateControlProperties()") );
|
|
192 |
mProperties = properties;
|
|
193 |
}
|
|
194 |
|
58
|
195 |
// -------------------------------------------------------------------------------------------------
|
|
196 |
// VideoPlaybackFullScreenControl::resetControl()
|
|
197 |
// -------------------------------------------------------------------------------------------------
|
|
198 |
//
|
|
199 |
void VideoPlaybackFullScreenControl::resetControl()
|
|
200 |
{
|
|
201 |
mControlReset = true;
|
|
202 |
}
|
|
203 |
|
44
|
204 |
// End of file
|