diff options
author | Bea Lam <bea.lam@nokia.com> | 2011-01-18 00:40:26 (GMT) |
---|---|---|
committer | Bea Lam <bea.lam@nokia.com> | 2011-01-19 04:59:00 (GMT) |
commit | 5ddfe819e93462eff396c24d10c0446c4cd9b0ac (patch) | |
tree | e4fca55eebf4772704f32bb7ec1924860753edda /tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp | |
parent | ebd4bc73c46c2962742a682b6a391fb68c482aec (diff) | |
download | Qt-5ddfe819e93462eff396c24d10c0446c4cd9b0ac.zip Qt-5ddfe819e93462eff396c24d10c0446c4cd9b0ac.tar.gz Qt-5ddfe819e93462eff396c24d10c0446c4cd9b0ac.tar.bz2 |
Rename Image::cached to 'cached' (and QDeclarativePixmap::Cached also)
This is to keep consistent property naming consistent. E.g. Image
has 'smooth', 'mirror' properties rather than 'smoothed', 'mirrored'.
For consistency QDeclarativePixmap::Cached was renamed as well.
Reviewed-by: Martin Jones
Diffstat (limited to 'tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp')
-rw-r--r-- | tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp b/tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp index 7bb629e..c277eb7 100644 --- a/tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp +++ b/tests/auto/declarative/qdeclarativeimage/tst_qdeclarativeimage.cpp @@ -126,7 +126,7 @@ void tst_qdeclarativeimage::imageSource_data() QTest::addColumn<double>("height"); QTest::addColumn<bool>("remote"); QTest::addColumn<bool>("async"); - QTest::addColumn<bool>("cached"); + QTest::addColumn<bool>("cache"); QTest::addColumn<QString>("error"); QTest::newRow("local") << QUrl::fromLocalFile(SRCDIR "/data/colors.png").toString() << 120.0 << 120.0 << false << false << true << ""; @@ -151,7 +151,7 @@ void tst_qdeclarativeimage::imageSource() QFETCH(double, height); QFETCH(bool, remote); QFETCH(bool, async); - QFETCH(bool, cached); + QFETCH(bool, cache); QFETCH(QString, error); TestHTTPServer server(SERVER_PORT); @@ -165,8 +165,8 @@ void tst_qdeclarativeimage::imageSource() QTest::ignoreMessage(QtWarningMsg, error.toUtf8()); QString componentStr = "import QtQuick 1.0\nImage { source: \"" + source + "\"; asynchronous: " - + (async ? QLatin1String("true") : QLatin1String("false")) + "; cached: " - + (cached ? QLatin1String("true") : QLatin1String("false")) + " }"; + + (async ? QLatin1String("true") : QLatin1String("false")) + "; cache: " + + (cache ? QLatin1String("true") : QLatin1String("false")) + " }"; QDeclarativeComponent component(&engine); component.setData(componentStr.toLatin1(), QUrl::fromLocalFile("")); QDeclarativeImage *obj = qobject_cast<QDeclarativeImage*>(component.create()); @@ -177,10 +177,10 @@ void tst_qdeclarativeimage::imageSource() else QVERIFY(obj->asynchronous() == false); - if (cached) - QVERIFY(obj->cached() == true); + if (cache) + QVERIFY(obj->cache() == true); else - QVERIFY(obj->cached() == false); + QVERIFY(obj->cache() == false); if (remote || async) QTRY_VERIFY(obj->status() == QDeclarativeImage::Loading); |