summaryrefslogtreecommitdiffstats
path: root/examples/multimedia/videowidget
diff options
context:
space:
mode:
authorAndrew den Exter <andrew.den-exter@nokia.com>2009-11-04 07:53:51 (GMT)
committerAndrew den Exter <andrew.den-exter@nokia.com>2009-11-04 07:59:06 (GMT)
commit14238b8f58b2f7496cde8b829870a6180286ea14 (patch)
tree6707eb820fb3c72ebba137f93cfe08948136a04b /examples/multimedia/videowidget
parent1400ce5b85fbe7c67899f5f62bfd276eecb21ae0 (diff)
downloadQt-14238b8f58b2f7496cde8b829870a6180286ea14.zip
Qt-14238b8f58b2f7496cde8b829870a6180286ea14.tar.gz
Qt-14238b8f58b2f7496cde8b829870a6180286ea14.tar.bz2
QAbstractVideoSurface API review changes.
Rename isStarted() and startedChanged() to is active() and activeChanged(). Remove the the similar format argument from isFormatSupported() and add a new nearestFormat() function which provides the same functionality. Reviewed-by: Justin McPherson
Diffstat (limited to 'examples/multimedia/videowidget')
-rw-r--r--examples/multimedia/videowidget/videoplayer.cpp3
-rw-r--r--examples/multimedia/videowidget/videowidget.cpp2
2 files changed, 2 insertions, 3 deletions
diff --git a/examples/multimedia/videowidget/videoplayer.cpp b/examples/multimedia/videowidget/videoplayer.cpp
index ed24714..cd146e8 100644
--- a/examples/multimedia/videowidget/videoplayer.cpp
+++ b/examples/multimedia/videowidget/videoplayer.cpp
@@ -100,8 +100,7 @@ void VideoPlayer::openFile()
QString fileName = QFileDialog::getOpenFileName(this, tr("Open Movie"));
if (!fileName.isEmpty()) {
- if (surface->isStarted())
- surface->stop();
+ surface->stop();
movie.setFileName(fileName);
diff --git a/examples/multimedia/videowidget/videowidget.cpp b/examples/multimedia/videowidget/videowidget.cpp
index 80688e1..f73a52f 100644
--- a/examples/multimedia/videowidget/videowidget.cpp
+++ b/examples/multimedia/videowidget/videowidget.cpp
@@ -84,7 +84,7 @@ void VideoWidget::paintEvent(QPaintEvent *event)
{
QPainter painter(this);
- if (surface->isStarted()) {
+ if (surface->isActive()) {
const QRect videoRect = surface->videoRect();
if (!videoRect.contains(event->rect())) {