author | llornkcor <llornkcor> | 2002-08-14 00:04:55 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-08-14 00:04:55 (UTC) |
commit | 29ffa9119abaf753b165c5c241b22938eeaef301 (patch) (unidiff) | |
tree | 89ae13f40e3939dcccb711bbb0a225b857db0a30 | |
parent | 05a272a0dc03c37f143546aa5cde228bd3ba79bb (diff) | |
download | opie-29ffa9119abaf753b165c5c241b22938eeaef301.zip opie-29ffa9119abaf753b165c5c241b22938eeaef301.tar.gz opie-29ffa9119abaf753b165c5c241b22938eeaef301.tar.bz2 |
fullscreen working
-rw-r--r-- | noncore/multimedia/opieplayer2/videowidget.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/noncore/multimedia/opieplayer2/videowidget.cpp b/noncore/multimedia/opieplayer2/videowidget.cpp index 33153d4..b4e69b5 100644 --- a/noncore/multimedia/opieplayer2/videowidget.cpp +++ b/noncore/multimedia/opieplayer2/videowidget.cpp | |||
@@ -136,25 +136,25 @@ QWidget( parent, name, f ), scaledWidth( 0 ), scaledHeight( 0 ) { | |||
136 | connect( mediaPlayerState, SIGNAL( lengthChanged(long) ), this, SLOT( setLength(long) ) ); | 136 | connect( mediaPlayerState, SIGNAL( lengthChanged(long) ), this, SLOT( setLength(long) ) ); |
137 | connect( mediaPlayerState, SIGNAL( positionChanged(long) ),this, SLOT( setPosition(long) ) ); | 137 | connect( mediaPlayerState, SIGNAL( positionChanged(long) ),this, SLOT( setPosition(long) ) ); |
138 | connect( mediaPlayerState, SIGNAL( positionUpdated(long) ),this, SLOT( setPosition(long) ) ); | 138 | connect( mediaPlayerState, SIGNAL( positionUpdated(long) ),this, SLOT( setPosition(long) ) ); |
139 | connect( mediaPlayerState, SIGNAL( viewChanged(char) ), this, SLOT( setView(char) ) ); | 139 | connect( mediaPlayerState, SIGNAL( viewChanged(char) ), this, SLOT( setView(char) ) ); |
140 | 140 | ||
141 | connect( mediaPlayerState, SIGNAL( pausedToggled(bool) ), this, SLOT( setPaused(bool) ) ); | 141 | connect( mediaPlayerState, SIGNAL( pausedToggled(bool) ), this, SLOT( setPaused(bool) ) ); |
142 | connect( mediaPlayerState, SIGNAL( playingToggled(bool) ), this, SLOT( setPlaying(bool) ) ); | 142 | connect( mediaPlayerState, SIGNAL( playingToggled(bool) ), this, SLOT( setPlaying(bool) ) ); |
143 | 143 | ||
144 | setLength( mediaPlayerState->length() ); | 144 | setLength( mediaPlayerState->length() ); |
145 | setPosition( mediaPlayerState->position() ); | 145 | setPosition( mediaPlayerState->position() ); |
146 | 146 | ||
147 | ////////////////////////// FIXME | 147 | ////////////////////////// FIXME |
148 | // setFullscreen( mediaPlayerState->fullscreen() ); | 148 | setFullscreen( mediaPlayerState->fullscreen() ); |
149 | setPaused( mediaPlayerState->paused() ); | 149 | setPaused( mediaPlayerState->paused() ); |
150 | setPlaying( mediaPlayerState->playing() ); | 150 | setPlaying( mediaPlayerState->playing() ); |
151 | qDebug("finished videowidget"); | 151 | qDebug("finished videowidget"); |
152 | } | 152 | } |
153 | 153 | ||
154 | 154 | ||
155 | VideoWidget::~VideoWidget() { | 155 | VideoWidget::~VideoWidget() { |
156 | mediaPlayerState->setPlaying( FALSE ); | 156 | mediaPlayerState->setPlaying( FALSE ); |
157 | for ( int i = 0; i < 7; i++ ) { | 157 | for ( int i = 0; i < 7; i++ ) { |
158 | delete buttonPixUp[i]; | 158 | delete buttonPixUp[i]; |
159 | delete buttonPixDown[i]; | 159 | delete buttonPixDown[i]; |
160 | } | 160 | } |
@@ -387,24 +387,25 @@ void VideoWidget::mouseReleaseEvent( QMouseEvent *event ) { | |||
387 | void VideoWidget::makeVisible() { | 387 | void VideoWidget::makeVisible() { |
388 | if ( mediaPlayerState->fullscreen() ) { | 388 | if ( mediaPlayerState->fullscreen() ) { |
389 | setBackgroundMode( QWidget::NoBackground ); | 389 | setBackgroundMode( QWidget::NoBackground ); |
390 | showFullScreen(); | 390 | showFullScreen(); |
391 | resize( qApp->desktop()->size() ); | 391 | resize( qApp->desktop()->size() ); |
392 | slider->hide(); | 392 | slider->hide(); |
393 | videoFrame-> setGeometry ( 0, 0, width ( ), height ( )); | 393 | videoFrame-> setGeometry ( 0, 0, width ( ), height ( )); |
394 | } else { | 394 | } else { |
395 | showNormal(); | 395 | showNormal(); |
396 | showMaximized(); | 396 | showMaximized(); |
397 | slider->show(); | 397 | slider->show(); |
398 | videoFrame->setGeometry( QRect( 10, 20, 220, 160 ) ); | 398 | videoFrame->setGeometry( QRect( 10, 20, 220, 160 ) ); |
399 | qApp->processEvents(); | ||
399 | } | 400 | } |
400 | } | 401 | } |
401 | 402 | ||
402 | 403 | ||
403 | void VideoWidget::paintEvent( QPaintEvent * pe) { | 404 | void VideoWidget::paintEvent( QPaintEvent * pe) { |
404 | QPainter p( this ); | 405 | QPainter p( this ); |
405 | 406 | ||
406 | if ( mediaPlayerState->fullscreen() ) { | 407 | if ( mediaPlayerState->fullscreen() ) { |
407 | // Clear the background | 408 | // Clear the background |
408 | p.setBrush( QBrush( Qt::black ) ); | 409 | p.setBrush( QBrush( Qt::black ) ); |
409 | // videoFrame->setGeometry( QRect( 0, 0 , 240 ,320 ) ); | 410 | // videoFrame->setGeometry( QRect( 0, 0 , 240 ,320 ) ); |
410 | 411 | ||