[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdemultimedia/kaboodle
From: Carsten Pfeiffer <carpdjih () mailbox ! tu-berlin ! de>
Date: 2003-10-14 19:12:14
[Download RAW message or body]
CVS commit by pfeiffer:
- applying patch by Cedric Pasteur <cedric.pasteur@m6net.fr> to play/pause
video in fullscreen mode via the mouse (as most other players do)
- fix deprecation
M +1 -1 kaboodleapp.cpp 1.9
M +1 -1 userinterface.cpp 1.34
M +18 -0 view.cpp 1.19
M +2 -0 view.h 1.11
--- kdemultimedia/kaboodle/kaboodleapp.cpp #1.8:1.9
@@ -38,5 +38,5 @@ Kaboodle::KaboodleApp::KaboodleApp()
{
KURL url = args->url(args->count() - 1);
- if(!url.isMalformed()) openURL = url;
+ if(url.isValid()) openURL = url;
}
--- kdemultimedia/kaboodle/userinterface.cpp #1.33:1.34
@@ -104,5 +104,5 @@ void Kaboodle::UserInterface::fileOpen(v
{
KURL file(KFileDialog::getOpenURL(QString::null, \
KDE::PlayObjectFactory::mimeTypes().join(" "), this, i18n("Select \
File to Play")));
- if(!file.isMalformed())
+ if(file.isValid())
{
part->openURL(file);
--- kdemultimedia/kaboodle/view.cpp #1.18:1.19
@@ -73,4 +73,6 @@ Kaboodle::View::View(QWidget *parent, co
setVideoWidget(video);
connect(video, SIGNAL(adaptSize(int, int)), this, SLOT(calculateSize(int, \
int))); + connect(video, SIGNAL(mouseButtonPressed(int, const QPoint&, int)), \
this, SLOT(slotButtonPressed(int, const QPoint &, int) ) ) ; + connect(video, \
SIGNAL(mouseButtonDoubleClick(const QPoint&)), this, SLOT(slotDblClick(const QPoint \
&) ) ) ;
QWidget *sliderBox = new QWidget(box);
@@ -300,4 +302,20 @@ void Kaboodle::View::updateButtons(int b
}
+}
+
+void Kaboodle::View::slotButtonPressed(int /*type*/, const QPoint &, int /* state \
*/) +{
+ if((KMediaPlayer::Player::State)player->state() == \
KMediaPlayer::Player::Pause ) + player->play();
+ else player->pause();
+}
+
+void Kaboodle::View::slotDblClick( const QPoint &, int /* state */)
+{
+ if ( video->isFullscreen() )
+ video->setWindowed();
+ else video->setFullscreen();
+
+ player->play(); // play() is called because the video is stopped when \
double-clicking ( slotButtonPressed is called ) }
--- kdemultimedia/kaboodle/view.h #1.10:1.11
@@ -79,4 +79,6 @@ signals:
private slots:
void updateLabel(const QString &text);
+ void slotButtonPressed( int, const QPoint &, int state );
+ void slotDblClick( const QPoint &, int state );
void calculateSize(int width, int height);
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic