summaryrefslogtreecommitdiffstats
path: root/src/plugins/mediaservices/qt7/mediaplayer
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-04-23 11:11:44 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-04-23 11:11:44 (GMT)
commit00721d83b20a5e1e66c46cefe98311ee2882b198 (patch)
treefce9a3f1652eb25dade776d438af0d16a06d6647 /src/plugins/mediaservices/qt7/mediaplayer
parent15088d236924bccee787953e04214f87392e8e55 (diff)
parent6a56b0222c15116150dd78883204f65708a927ca (diff)
downloadQt-00721d83b20a5e1e66c46cefe98311ee2882b198.zip
Qt-00721d83b20a5e1e66c46cefe98311ee2882b198.tar.gz
Qt-00721d83b20a5e1e66c46cefe98311ee2882b198.tar.bz2
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-multimedia-staging into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/qt-multimedia-staging: (27 commits) Remove trace code from directshowaudioendpointcontrol.h. New configure.exe binary Add support for MSBuild, which is the project format for MSVC 2010 Only add qvideowidget test once. Multimedia causes build failure when Qt is configured with -embedded Player demo: load not only local files but playlists and urls passed as Gstreamer media backend: preserve playback rate after seeks and media QT7 mediaservice; fix leaking strings. Fixed Qt build with mediaservices disabled. Multimedia tests; fix for missing dependency Disabled QMediaPlayer states debug output. Fixed typo in QMediaPlayer::play() error reporting Fixed QVideoWidget test, waiting for video surface painted. Tests; Fix media tests, make sure they are using mediaservies. Fix warning about illegal empty declaration. Three fixes from Shane after QtMultimedia was split into two dlls. Fix compile errors in Direct Show media service. Add EXPORT defines for QtMediaServices library. Fixed configure check for gstreamer. WebKit; build with change to mediaservices. ...
Diffstat (limited to 'src/plugins/mediaservices/qt7/mediaplayer')
-rw-r--r--src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.h4
-rw-r--r--src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.mm2
-rw-r--r--src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.h10
-rw-r--r--src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.mm20
-rw-r--r--src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.h2
-rw-r--r--src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.mm4
-rw-r--r--src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.h4
-rw-r--r--src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.mm17
8 files changed, 31 insertions, 32 deletions
diff --git a/src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.h b/src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.h
index 907d13d..5ac97b1 100644
--- a/src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.h
+++ b/src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.h
@@ -45,8 +45,8 @@
#include <QtCore/qobject.h>
#include <QtGui/qmacdefines_mac.h>
-#include <QtMultimedia/qmediaplayercontrol.h>
-#include <QtMultimedia/qmediaplayer.h>
+#include <QtMediaServices/qmediaplayercontrol.h>
+#include <QtMediaServices/qmediaplayer.h>
QT_BEGIN_HEADER
diff --git a/src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.mm b/src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.mm
index 0f4ac41..ba22552 100644
--- a/src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.mm
+++ b/src/plugins/mediaservices/qt7/mediaplayer/qt7playercontrol.mm
@@ -42,7 +42,7 @@
#include "qt7playercontrol.h"
#include "qt7playersession.h"
-#include <QtMultimedia/qmediaplaylistnavigator.h>
+#include <QtMediaServices/qmediaplaylistnavigator.h>
#include <QtCore/qurl.h>
#include <QtCore/qdebug.h>
diff --git a/src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.h b/src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.h
index f16807a..8cbc29a 100644
--- a/src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.h
+++ b/src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.h
@@ -42,7 +42,7 @@
#ifndef QT7PLAYERMETADATACONTROL_H
#define QT7PLAYERMETADATACONTROL_H
-#include <QtMultimedia/qmetadatacontrol.h>
+#include <QtMediaServices/qmetadatacontrol.h>
QT_BEGIN_HEADER
@@ -61,9 +61,9 @@ public:
bool isMetaDataAvailable() const;
bool isWritable() const;
- QVariant metaData(QtMultimedia::MetaData key) const;
- void setMetaData(QtMultimedia::MetaData key, const QVariant &value);
- QList<QtMultimedia::MetaData> availableMetaData() const;
+ QVariant metaData(QtMediaServices::MetaData key) const;
+ void setMetaData(QtMediaServices::MetaData key, const QVariant &value);
+ QList<QtMediaServices::MetaData> availableMetaData() const;
QVariant extendedMetaData(const QString &key) const ;
void setExtendedMetaData(const QString &key, const QVariant &value);
@@ -74,7 +74,7 @@ private slots:
private:
QT7PlayerSession *m_session;
- QMap<QtMultimedia::MetaData, QVariant> m_tags;
+ QMap<QtMediaServices::MetaData, QVariant> m_tags;
};
QT_END_NAMESPACE
diff --git a/src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.mm b/src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.mm
index 59d01a2..2ea778d 100644
--- a/src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.mm
+++ b/src/plugins/mediaservices/qt7/mediaplayer/qt7playermetadata.mm
@@ -72,18 +72,18 @@ bool QT7PlayerMetaDataControl::isWritable() const
return false;
}
-QVariant QT7PlayerMetaDataControl::metaData(QtMultimedia::MetaData key) const
+QVariant QT7PlayerMetaDataControl::metaData(QtMediaServices::MetaData key) const
{
return m_tags.value(key);
}
-void QT7PlayerMetaDataControl::setMetaData(QtMultimedia::MetaData key, QVariant const &value)
+void QT7PlayerMetaDataControl::setMetaData(QtMediaServices::MetaData key, QVariant const &value)
{
Q_UNUSED(key);
Q_UNUSED(value);
}
-QList<QtMultimedia::MetaData> QT7PlayerMetaDataControl::availableMetaData() const
+QList<QtMediaServices::MetaData> QT7PlayerMetaDataControl::availableMetaData() const
{
return m_tags.keys();
}
@@ -256,13 +256,13 @@ void QT7PlayerMetaDataControl::updateTags()
metaMap.insert(QLatin1String("nam"), QString::fromUtf8([name UTF8String]));
#endif // QUICKTIME_C_API_AVAILABLE
- m_tags.insert(QtMultimedia::AlbumArtist, metaMap.value(QLatin1String("ART")));
- m_tags.insert(QtMultimedia::AlbumTitle, metaMap.value(QLatin1String("alb")));
- m_tags.insert(QtMultimedia::Title, metaMap.value(QLatin1String("nam")));
- m_tags.insert(QtMultimedia::Date, metaMap.value(QLatin1String("day")));
- m_tags.insert(QtMultimedia::Genre, metaMap.value(QLatin1String("gnre")));
- m_tags.insert(QtMultimedia::TrackNumber, metaMap.value(QLatin1String("trk")));
- m_tags.insert(QtMultimedia::Description, metaMap.value(QLatin1String("des")));
+ m_tags.insert(QtMediaServices::AlbumArtist, metaMap.value(QLatin1String("ART")));
+ m_tags.insert(QtMediaServices::AlbumTitle, metaMap.value(QLatin1String("alb")));
+ m_tags.insert(QtMediaServices::Title, metaMap.value(QLatin1String("nam")));
+ m_tags.insert(QtMediaServices::Date, metaMap.value(QLatin1String("day")));
+ m_tags.insert(QtMediaServices::Genre, metaMap.value(QLatin1String("gnre")));
+ m_tags.insert(QtMediaServices::TrackNumber, metaMap.value(QLatin1String("trk")));
+ m_tags.insert(QtMediaServices::Description, metaMap.value(QLatin1String("des")));
}
if (!wasEmpty || !m_tags.isEmpty())
diff --git a/src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.h b/src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.h
index d4b30b8..9a22c31 100644
--- a/src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.h
+++ b/src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.h
@@ -43,7 +43,7 @@
#define QT7PLAYERSERVICE_H
#include <QtCore/qobject.h>
-#include <QtMultimedia/qmediaservice.h>
+#include <QtMediaServices/qmediaservice.h>
QT_BEGIN_HEADER
diff --git a/src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.mm b/src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.mm
index 205e862..cf79622 100644
--- a/src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.mm
+++ b/src/plugins/mediaservices/qt7/mediaplayer/qt7playerservice.mm
@@ -54,8 +54,8 @@
#include "qt7movievideowidget.h"
#include "qt7playermetadata.h"
-#include <QtMultimedia/qmediaplaylistnavigator.h>
-#include <QtMultimedia/qmediaplaylist.h>
+#include <QtMediaServices/qmediaplaylistnavigator.h>
+#include <QtMediaServices/qmediaplaylist.h>
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.h b/src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.h
index 0ba3041..2450cf8 100644
--- a/src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.h
+++ b/src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.h
@@ -45,8 +45,8 @@
#include <QtCore/qobject.h>
#include <QtGui/qmacdefines_mac.h>
-#include <QtMultimedia/qmediaplayercontrol.h>
-#include <QtMultimedia/qmediaplayer.h>
+#include <QtMediaServices/qmediaplayercontrol.h>
+#include <QtMediaServices/qmediaplayer.h>
QT_BEGIN_HEADER
diff --git a/src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.mm b/src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.mm
index 65c9f7d..0405bbd 100644
--- a/src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.mm
+++ b/src/plugins/mediaservices/qt7/mediaplayer/qt7playersession.mm
@@ -49,7 +49,7 @@
#include "qt7videooutputcontrol.h"
#include <QtNetwork/qnetworkcookie.h>
-#include <QtMultimedia/qmediaplaylistnavigator.h>
+#include <QtMediaServices/qmediaplaylistnavigator.h>
#include <CoreFoundation/CoreFoundation.h>
#include <Foundation/Foundation.h>
@@ -153,10 +153,9 @@
QT_BEGIN_NAMESPACE
-static CFStringRef qString2CFStringRef(const QString &string)
+static inline NSString *qString2CFStringRef(const QString &string)
{
- return CFStringCreateWithCharacters(0, reinterpret_cast<const UniChar *>(string.unicode()),
- string.length());
+ return [NSString stringWithCharacters:reinterpret_cast<const UniChar *>(string.unicode()) length:string.length()];
}
QT7PlayerSession::QT7PlayerSession(QObject *parent)
@@ -391,10 +390,10 @@ void QT7PlayerSession::setMedia(const QMediaContent &content, QIODevice *stream)
foreach (const QNetworkCookie &requestCookie, cookieList) {
NSMutableDictionary *p = [NSMutableDictionary dictionaryWithObjectsAndKeys:
- (NSString*)qString2CFStringRef(requestCookie.name()), NSHTTPCookieName,
- (NSString*)qString2CFStringRef(requestCookie.value()), NSHTTPCookieValue,
- (NSString*)qString2CFStringRef(requestCookie.domain()), NSHTTPCookieDomain,
- (NSString*)qString2CFStringRef(requestCookie.path()), NSHTTPCookiePath,
+ qString2CFStringRef(requestCookie.name()), NSHTTPCookieName,
+ qString2CFStringRef(requestCookie.value()), NSHTTPCookieValue,
+ qString2CFStringRef(requestCookie.domain()), NSHTTPCookieDomain,
+ qString2CFStringRef(requestCookie.path()), NSHTTPCookiePath,
nil
];
if (requestCookie.isSessionCookie())
@@ -407,7 +406,7 @@ void QT7PlayerSession::setMedia(const QMediaContent &content, QIODevice *stream)
}
NSError *err = 0;
- NSString *urlString = (NSString *)qString2CFStringRef(request.url().toString());
+ NSString *urlString = qString2CFStringRef(request.url().toString());
NSDictionary *attr = [NSDictionary dictionaryWithObjectsAndKeys:
[NSURL URLWithString:urlString], QTMovieURLAttribute,