34 #include <hbaction.h> |
33 #include <hbaction.h> |
35 #include <hbiconitem.h> |
34 #include <hbiconitem.h> |
36 #include <hbratingslider.h> |
35 #include <hbratingslider.h> |
37 #include <hbiconanimator.h> |
36 #include <hbiconanimator.h> |
38 #include <hbtransparentwindow.h> |
37 #include <hbtransparentwindow.h> |
|
38 #include <hbiconanimationmanager.h> |
39 |
39 |
40 #include "mpxvideoviewwrapper.h" |
40 #include "mpxvideoviewwrapper.h" |
41 #include "hbvideobaseplaybackview.h" |
41 #include "hbvideobaseplaybackview.h" |
42 #include "mpxvideoplaybackbuttonbar.h" |
42 #include "mpxvideoplaybackcontrolbar.h" |
43 #include "mpxvideoplaybackprogressbar.h" |
|
44 #include "mpxvideoplaybackcontrolpolicy.h" |
43 #include "mpxvideoplaybackcontrolpolicy.h" |
45 #include "mpxvideoplaybackdocumentloader.h" |
44 #include "mpxvideoplaybackdocumentloader.h" |
46 #include "mpxvideoplaybackviewfiledetails.h" |
45 #include "mpxvideoplaybackviewfiledetails.h" |
47 #include "mpxvideoplaybackstatuspanecontrol.h" |
46 #include "mpxvideoplaybackstatuspanecontrol.h" |
48 #include "mpxvideoplaybackfiledetailswidget.h" |
47 #include "mpxvideoplaybackfiledetailswidget.h" |
184 // ------------------------------------------------------------------------------------------------- |
183 // ------------------------------------------------------------------------------------------------- |
185 // |
184 // |
186 void QMPXVideoPlaybackControlsController::addFileDetails( |
185 void QMPXVideoPlaybackControlsController::addFileDetails( |
187 QMPXVideoPlaybackViewFileDetails* details ) |
186 QMPXVideoPlaybackViewFileDetails* details ) |
188 { |
187 { |
|
188 MPX_ENTER_EXIT(_L("QMPXVideoPlaybackControlsController::addFileDetails")); |
|
189 |
189 // |
190 // |
190 // If it is not local, hide the star rating |
191 // If it is not local, hide the star rating |
191 // |
192 // |
192 if ( details->mPlaybackMode != EMPXVideoLocal ) |
193 if ( details->mPlaybackMode != EMPXVideoLocal ) |
193 { |
194 { |
479 case EMPXBufferingAnimation: |
480 case EMPXBufferingAnimation: |
480 { |
481 { |
481 // |
482 // |
482 // Buffering animation icon |
483 // Buffering animation icon |
483 // |
484 // |
|
485 HbIconAnimationManager* manager = HbIconAnimationManager::global(); |
|
486 manager->addDefinitionFile(":/hbvideoplaybackview/animation.axml"); |
|
487 |
484 QGraphicsWidget *widget = mLoader->findWidget( QString( "bufferingIcon" ) ); |
488 QGraphicsWidget *widget = mLoader->findWidget( QString( "bufferingIcon" ) ); |
485 HbLabel *bufferingAnim = qobject_cast<HbLabel*>( widget ); |
489 HbLabel *bufferingAnim = qobject_cast<HbLabel*>( widget ); |
486 HbIconItem *iconItem = new HbIconItem( bufferingAnim->icon() ); |
|
487 iconItem->animator().startAnimation(); |
|
488 |
490 |
489 control = new QMPXVideoPlaybackFullScreenControl( this, |
491 control = new QMPXVideoPlaybackFullScreenControl( this, |
490 controlIndex, |
492 controlIndex, |
491 bufferingAnim, |
493 bufferingAnim, |
492 properties ); |
494 properties ); |
505 properties ); |
507 properties ); |
506 mControls.append( control ); |
508 mControls.append( control ); |
507 |
509 |
508 break; |
510 break; |
509 } |
511 } |
510 case EMPXButtonBar: |
512 case EMPXControlBar: |
511 { |
513 { |
512 // |
514 // |
513 // Button bar |
515 // Button bar |
514 // |
516 // |
515 QGraphicsWidget *widget = mLoader->findWidget( QString( "buttonBarLayout" ) ); |
517 QGraphicsWidget *widget = mLoader->findWidget( QString( "controlBarLayout" ) ); |
516 QMPXVideoPlaybackButtonBar *buttonBar = |
518 QMPXVideoPlaybackControlBar *controlBar = |
517 qobject_cast<QMPXVideoPlaybackButtonBar*>( widget ); |
519 qobject_cast<QMPXVideoPlaybackControlBar*>( widget ); |
518 buttonBar->initialize(); |
520 controlBar->initialize(); |
519 |
521 |
520 control = new QMPXVideoPlaybackFullScreenControl( this, |
522 control = new QMPXVideoPlaybackFullScreenControl( this, |
521 controlIndex, |
523 controlIndex, |
522 buttonBar, |
524 controlBar, |
523 properties ); |
525 properties ); |
524 mControls.append( control ); |
|
525 |
|
526 break; |
|
527 } |
|
528 case EMPXProgressBar: |
|
529 { |
|
530 // |
|
531 // Progress bar |
|
532 // |
|
533 QGraphicsWidget *widget = mLoader->findWidget( QString( "progressBarLayout" ) ); |
|
534 QMPXVideoPlaybackProgressBar *progressBar = |
|
535 qobject_cast<QMPXVideoPlaybackProgressBar*>( widget ); |
|
536 progressBar->initialize(); |
|
537 |
|
538 control = new QMPXVideoPlaybackFullScreenControl( this, |
|
539 controlIndex, |
|
540 progressBar, |
|
541 properties ); |
|
542 |
|
543 mControls.append( control ); |
526 mControls.append( control ); |
544 |
527 |
545 break; |
528 break; |
546 } |
529 } |
547 case EMPXFileDetailsWidget: |
530 case EMPXFileDetailsWidget: |