Convert features.movie to QT_[REQUIRE_]CONFIG
Change-Id: I838c7305d4649f953c5bb972f1aa51dbb078afe2 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>bb10
parent
9ec0280714
commit
3945cf1f9a
|
|
@ -10,7 +10,6 @@ HEADERS += \
|
|||
image/qimageiohandler.h \
|
||||
image/qimagereader.h \
|
||||
image/qimagewriter.h \
|
||||
image/qmovie.h \
|
||||
image/qpaintengine_pic_p.h \
|
||||
image/qpicture.h \
|
||||
image/qpicture_p.h \
|
||||
|
|
@ -41,7 +40,6 @@ SOURCES += \
|
|||
image/qpixmap.cpp \
|
||||
image/qpixmapcache.cpp \
|
||||
image/qplatformpixmap.cpp \
|
||||
image/qmovie.cpp \
|
||||
image/qpixmap_raster.cpp \
|
||||
image/qpixmap_blitter.cpp \
|
||||
image/qimagepixmapcleanuphooks.cpp \
|
||||
|
|
@ -50,6 +48,10 @@ SOURCES += \
|
|||
image/qiconengine.cpp \
|
||||
image/qiconengineplugin.cpp \
|
||||
|
||||
qtConfig(movie) {
|
||||
HEADERS += image/qmovie.h
|
||||
SOURCES += image/qmovie.cpp
|
||||
}
|
||||
|
||||
win32:!winrt: SOURCES += image/qpixmap_win.cpp
|
||||
|
||||
|
|
|
|||
|
|
@ -172,8 +172,6 @@
|
|||
|
||||
#include "qmovie.h"
|
||||
|
||||
#ifndef QT_NO_MOVIE
|
||||
|
||||
#include "qglobal.h"
|
||||
#include "qimage.h"
|
||||
#include "qimagereader.h"
|
||||
|
|
@ -1020,5 +1018,3 @@ void QMovie::setCacheMode(CacheMode cacheMode)
|
|||
QT_END_NAMESPACE
|
||||
|
||||
#include "moc_qmovie.cpp"
|
||||
|
||||
#endif // QT_NO_MOVIE
|
||||
|
|
|
|||
|
|
@ -42,15 +42,14 @@
|
|||
|
||||
#include <QtGui/qtguiglobal.h>
|
||||
|
||||
#ifndef QT_NO_MOVIE
|
||||
|
||||
#include <QtCore/qobject.h>
|
||||
#include <QtCore/qbytearray.h>
|
||||
#include <QtCore/qlist.h>
|
||||
#include <QtGui/qimagereader.h>
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
QT_REQUIRE_CONFIG(movie);
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QByteArray;
|
||||
class QColor;
|
||||
|
|
@ -144,6 +143,4 @@ private:
|
|||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif // QT_NO_MOVIE
|
||||
|
||||
#endif // QMOVIE_H
|
||||
|
|
|
|||
|
|
@ -422,7 +422,7 @@ QAccessible::Role QAccessibleDisplay::role() const
|
|||
if (l->picture())
|
||||
return QAccessible::Graphic;
|
||||
#endif
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
if (l->movie())
|
||||
return QAccessible::Animation;
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ QLabelPrivate::QLabelPrivate()
|
|||
#ifndef QT_NO_PICTURE
|
||||
picture(Q_NULLPTR),
|
||||
#endif
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
movie(),
|
||||
#endif
|
||||
control(Q_NULLPTR),
|
||||
|
|
@ -582,7 +582,7 @@ QSize QLabelPrivate::sizeForWidth(int w) const
|
|||
} else if (picture && !picture->isNull()) {
|
||||
br = picture->boundingRect();
|
||||
#endif
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
} else if (movie && !movie->currentPixmap().isNull()) {
|
||||
br = movie->currentPixmap().rect();
|
||||
br.setSize(br.size() / movie->currentPixmap().devicePixelRatio());
|
||||
|
|
@ -1015,7 +1015,7 @@ void QLabel::paintEvent(QPaintEvent *)
|
|||
int align = QStyle::visualAlignment(d->isTextLabel ? d->textDirection()
|
||||
: layoutDirection(), QFlag(d->align));
|
||||
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
if (d->movie) {
|
||||
if (d->scaledcontents)
|
||||
style->drawItemPixmap(&painter, cr, align, d->movie->currentPixmap().scaled(cr.size()));
|
||||
|
|
@ -1216,7 +1216,7 @@ void QLabelPrivate::updateShortcut()
|
|||
|
||||
#endif // QT_NO_SHORTCUT
|
||||
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
void QLabelPrivate::_q_movieUpdated(const QRect& rect)
|
||||
{
|
||||
Q_Q(QLabel);
|
||||
|
|
@ -1276,7 +1276,7 @@ void QLabel::setMovie(QMovie *movie)
|
|||
d->updateLabel();
|
||||
}
|
||||
|
||||
#endif // QT_NO_MOVIE
|
||||
#endif // QT_CONFIG(movie)
|
||||
|
||||
/*!
|
||||
\internal
|
||||
|
|
@ -1309,7 +1309,7 @@ void QLabelPrivate::clearContents()
|
|||
q->releaseShortcut(shortcutId);
|
||||
shortcutId = 0;
|
||||
#endif
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
if (movie) {
|
||||
QObject::disconnect(movie, SIGNAL(resized(QSize)), q, SLOT(_q_movieResized(QSize)));
|
||||
QObject::disconnect(movie, SIGNAL(updated(QRect)), q, SLOT(_q_movieUpdated(QRect)));
|
||||
|
|
@ -1329,7 +1329,7 @@ void QLabelPrivate::clearContents()
|
|||
}
|
||||
|
||||
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
|
||||
/*!
|
||||
Returns a pointer to the label's movie, or 0 if no movie has been
|
||||
|
|
@ -1344,7 +1344,7 @@ QMovie *QLabel::movie() const
|
|||
return d->movie;
|
||||
}
|
||||
|
||||
#endif // QT_NO_MOVIE
|
||||
#endif // QT_CONFIG(movie)
|
||||
|
||||
/*!
|
||||
\property QLabel::textFormat
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ public:
|
|||
#ifndef QT_NO_PICTURE
|
||||
const QPicture *picture() const;
|
||||
#endif
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
QMovie *movie() const;
|
||||
#endif
|
||||
|
||||
|
|
@ -122,7 +122,7 @@ public Q_SLOTS:
|
|||
#ifndef QT_NO_PICTURE
|
||||
void setPicture(const QPicture &);
|
||||
#endif
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
void setMovie(QMovie *movie);
|
||||
#endif
|
||||
void setNum(int);
|
||||
|
|
@ -152,7 +152,7 @@ protected:
|
|||
private:
|
||||
Q_DISABLE_COPY(QLabel)
|
||||
Q_DECLARE_PRIVATE(QLabel)
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
Q_PRIVATE_SLOT(d_func(), void _q_movieUpdated(const QRect&))
|
||||
Q_PRIVATE_SLOT(d_func(), void _q_movieResized(const QSize&))
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -59,7 +59,9 @@
|
|||
#include "qtextdocumentfragment.h"
|
||||
#include "qframe_p.h"
|
||||
#include "qtextdocument.h"
|
||||
#if QT_CONFIG(movie)
|
||||
#include "qmovie.h"
|
||||
#endif
|
||||
#include "qimage.h"
|
||||
#include "qbitmap.h"
|
||||
#include "qpicture.h"
|
||||
|
|
@ -79,7 +81,7 @@ public:
|
|||
void updateLabel();
|
||||
QSize sizeForWidth(int w) const;
|
||||
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
void _q_movieUpdated(const QRect&);
|
||||
void _q_movieResized(const QSize&);
|
||||
#endif
|
||||
|
|
@ -116,7 +118,7 @@ public:
|
|||
#ifndef QT_NO_PICTURE
|
||||
QPicture *picture;
|
||||
#endif
|
||||
#ifndef QT_NO_MOVIE
|
||||
#if QT_CONFIG(movie)
|
||||
QPointer<QMovie> movie;
|
||||
#endif
|
||||
mutable QWidgetTextControl *control;
|
||||
|
|
|
|||
Loading…
Reference in New Issue