summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/gui')
-rw-r--r--tests/auto/gui/image/qicoimageformat/qicoimageformat.pro11
-rw-r--r--tests/auto/gui/image/qicoimageformat/tst_qicoimageformat.cpp6
-rw-r--r--tests/auto/gui/image/qicon/qicon.pro10
-rw-r--r--tests/auto/gui/image/qicon/tst_qicon.cpp4
-rw-r--r--tests/auto/gui/image/qimage/qimage.pro10
-rw-r--r--tests/auto/gui/image/qimage/tst_qimage.cpp9
-rw-r--r--tests/auto/gui/image/qimagereader/qimagereader.pro16
-rw-r--r--tests/auto/gui/image/qimagereader/tst_qimagereader.cpp9
-rw-r--r--tests/auto/gui/image/qimagewriter/qimagewriter.pro9
-rw-r--r--tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp13
-rw-r--r--tests/auto/gui/image/qmovie/qmovie.pro11
-rw-r--r--tests/auto/gui/image/qpixmap/qpixmap.pro8
-rw-r--r--tests/auto/gui/image/qpixmap/tst_qpixmap.cpp305
-rw-r--r--tests/auto/gui/image/qvolatileimage/qvolatileimage.pro5
-rw-r--r--tests/auto/gui/image/qvolatileimage/tst_qvolatileimage.cpp190
-rw-r--r--tests/auto/gui/kernel/kernel.pro3
-rw-r--r--tests/auto/gui/kernel/qclipboard/test/test.pro16
-rw-r--r--tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp84
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro6
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/test/test.pro3
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/test/tst_qfileopenevent.cpp135
-rw-r--r--tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp4
-rw-r--r--tests/auto/gui/painting/qpainter/qpainter.pro8
-rw-r--r--tests/auto/gui/painting/qpainter/tst_qpainter.cpp12
-rw-r--r--tests/auto/gui/painting/qpathclipper/qpathclipper.pro2
-rw-r--r--tests/auto/gui/painting/qpolygon/qpolygon.pro2
-rw-r--r--tests/auto/gui/painting/qtransform/qtransform.pro2
-rw-r--r--tests/auto/gui/painting/qwmatrix/qwmatrix.pro3
-rw-r--r--tests/auto/gui/text/qcssparser/qcssparser.pro6
-rw-r--r--tests/auto/gui/text/qcssparser/tst_qcssparser.cpp2
-rw-r--r--tests/auto/gui/text/qfontdatabase/qfontdatabase.pro4
-rw-r--r--tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp6
-rw-r--r--tests/auto/gui/text/qglyphrun/qglyphrun.pro2
-rw-r--r--tests/auto/gui/text/qrawfont/qrawfont.pro2
-rw-r--r--tests/auto/gui/text/qtextlayout/qtextlayout.pro5
-rw-r--r--tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro3
-rw-r--r--tests/auto/gui/text/qtextodfwriter/tst_qtextodfwriter.cpp5
-rw-r--r--tests/auto/gui/text/qzip/qzip.pro4
-rw-r--r--tests/auto/gui/text/qzip/tst_qzip.cpp4
-rw-r--r--tests/auto/gui/util/qdesktopservices/qdesktopservices.pro24
-rw-r--r--tests/auto/gui/util/qdesktopservices/tst_qdesktopservices.cpp225
41 files changed, 41 insertions, 1147 deletions
diff --git a/tests/auto/gui/image/qicoimageformat/qicoimageformat.pro b/tests/auto/gui/image/qicoimageformat/qicoimageformat.pro
index c150c9af9f..aae89db52f 100644
--- a/tests/auto/gui/image/qicoimageformat/qicoimageformat.pro
+++ b/tests/auto/gui/image/qicoimageformat/qicoimageformat.pro
@@ -12,17 +12,6 @@ wince*: {
}
addPlugins.path = imageformats
DEPLOYMENT += addFiles addPlugins
-} else:symbian {
- addFiles.files = icons
- addFiles.path = .
- DEPLOYMENT += addFiles
- qt_not_deployed {
- addPlugins.files = qico.dll
- addPlugins.path = imageformats
- DEPLOYMENT += addPlugins
- }
- TARGET.UID3 = 0xE0340004
- DEFINES += SYMBIAN_SRCDIR_UID=$$lower($$replace(TARGET.UID3,"0x",""))
} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
}
diff --git a/tests/auto/gui/image/qicoimageformat/tst_qicoimageformat.cpp b/tests/auto/gui/image/qicoimageformat/tst_qicoimageformat.cpp
index 3aace12fdb..a6fc7a8212 100644
--- a/tests/auto/gui/image/qicoimageformat/tst_qicoimageformat.cpp
+++ b/tests/auto/gui/image/qicoimageformat/tst_qicoimageformat.cpp
@@ -42,12 +42,6 @@
#include <QtGui>
#include <QtCore>
-#if defined(Q_OS_SYMBIAN)
-# define STRINGIFY(x) #x
-# define TOSTRING(x) STRINGIFY(x)
-# define SRCDIR "C:/Private/" TOSTRING(SYMBIAN_SRCDIR_UID) "/"
-#endif
-
class tst_QIcoImageFormat : public QObject
{
Q_OBJECT
diff --git a/tests/auto/gui/image/qicon/qicon.pro b/tests/auto/gui/image/qicon/qicon.pro
index cc87fae539..336a63d02f 100644
--- a/tests/auto/gui/image/qicon/qicon.pro
+++ b/tests/auto/gui/image/qicon/qicon.pro
@@ -15,16 +15,6 @@ wince* {
DEPLOYMENT_PLUGIN += qsvg
DEFINES += SRCDIR=\\\".\\\"
-} else:symbian {
- QT += xml svg
- addFiles.files = *.png tst_qicon.cpp *.svg *.svgz
- addFiles.path = .
- DEPLOYMENT += addFiles
- qt_not_deployed {
- plugins.files = qsvgicon.dll
- plugins.path = iconengines
- DEPLOYMENT += plugins
- }
} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
}
diff --git a/tests/auto/gui/image/qicon/tst_qicon.cpp b/tests/auto/gui/image/qicon/tst_qicon.cpp
index 4c430f9435..35be4ae04f 100644
--- a/tests/auto/gui/image/qicon/tst_qicon.cpp
+++ b/tests/auto/gui/image/qicon/tst_qicon.cpp
@@ -43,10 +43,6 @@
#include <QtTest/QtTest>
#include <QImageReader>
#include <qicon.h>
-
-#if defined(Q_OS_SYMBIAN)
-#define SRCDIR "."
-#endif
#include <qiconengine.h>
Q_DECLARE_METATYPE(QSize)
diff --git a/tests/auto/gui/image/qimage/qimage.pro b/tests/auto/gui/image/qimage/qimage.pro
index b517bc1237..87828b9c3e 100644
--- a/tests/auto/gui/image/qimage/qimage.pro
+++ b/tests/auto/gui/image/qimage/qimage.pro
@@ -8,16 +8,6 @@ wince*: {
addImages.path = images
DEPLOYMENT += addImages
DEFINES += SRCDIR=\\\".\\\"
-} else:symbian {
- TARGET.EPOCHEAPSIZE = 0x200000 0x800000
- addImages.files = images/*
- addImages.path = images
- DEPLOYMENT += addImages
- qt_not_deployed {
- imagePlugins.files = qjpeg.dll qgif.dll qmng.dll qtiff.dll qico.dll
- imagePlugins.path = imageformats
- DEPLOYMENT += imagePlugins
- }
} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
}
diff --git a/tests/auto/gui/image/qimage/tst_qimage.cpp b/tests/auto/gui/image/qimage/tst_qimage.cpp
index dce2957ae4..a144fdb3fc 100644
--- a/tests/auto/gui/image/qimage/tst_qimage.cpp
+++ b/tests/auto/gui/image/qimage/tst_qimage.cpp
@@ -54,9 +54,6 @@
//TESTED_CLASS=
//TESTED_FILES=
-#if defined(Q_OS_SYMBIAN)
-# define SRCDIR ""
-#endif
Q_DECLARE_METATYPE(QImage::Format)
Q_DECLARE_METATYPE(Qt::GlobalColor)
@@ -268,11 +265,7 @@ void tst_QImage::formatHandlersInput_data()
{
QTest::addColumn<QString>("testFormat");
QTest::addColumn<QString>("testFile");
- #ifdef Q_OS_SYMBIAN
- const QString prefix = QLatin1String(SRCDIR) + "images/";
- #else
const QString prefix = QLatin1String(SRCDIR) + "/images/";
- #endif
// add a new line here when a file is added
QTest::newRow("ICO") << "ICO" << prefix + "image.ico";
@@ -1499,8 +1492,6 @@ void tst_QImage::smoothScaleBig()
{
#if defined(Q_OS_WINCE)
int bigValue = 2000;
-#elif defined(Q_OS_SYMBIAN)
- int bigValue = 2000;
#else
int bigValue = 200000;
#endif
diff --git a/tests/auto/gui/image/qimagereader/qimagereader.pro b/tests/auto/gui/image/qimagereader/qimagereader.pro
index 43d587ea48..e706f24814 100644
--- a/tests/auto/gui/image/qimagereader/qimagereader.pro
+++ b/tests/auto/gui/image/qimagereader/qimagereader.pro
@@ -3,7 +3,7 @@ SOURCES += tst_qimagereader.cpp
MOC_DIR=tmp
QT += widgets widgets-private core-private gui-private network
RESOURCES += qimagereader.qrc
-!symbian:DEFINES += SRCDIR=\\\"$$PWD\\\"
+DEFINES += SRCDIR=\\\"$$PWD\\\"
win32-msvc:QMAKE_CXXFLAGS -= -Zm200
win32-msvc:QMAKE_CXXFLAGS += -Zm800
@@ -20,17 +20,3 @@ wince*: {
DEPLOYMENT += images imagePlugins
DEFINES += SRCDIR=\\\".\\\"
}
-
-symbian: {
- images.files = images
- images.path = .
-
- DEPLOYMENT += images
-
- qt_not_deployed {
- imagePlugins.files = qjpeg.dll qgif.dll qmng.dll
- imagePlugins.path = imageformats
-
- DEPLOYMENT += imagePlugins
- }
-}
diff --git a/tests/auto/gui/image/qimagereader/tst_qimagereader.cpp b/tests/auto/gui/image/qimagereader/tst_qimagereader.cpp
index ffedc69a7f..d36a7bba39 100644
--- a/tests/auto/gui/image/qimagereader/tst_qimagereader.cpp
+++ b/tests/auto/gui/image/qimagereader/tst_qimagereader.cpp
@@ -57,10 +57,6 @@
#include "../../../platformquirks.h"
-#if defined(Q_OS_SYMBIAN)
-# define SRCDIR "."
-#endif
-
typedef QMap<QString, QString> QStringMap;
typedef QList<int> QIntList;
Q_DECLARE_METATYPE(QImage)
@@ -1089,11 +1085,6 @@ void tst_QImageReader::readFromDevice()
QCOMPARE(image1, expectedImage);
}
-#if defined (Q_OS_SYMBIAN) && defined (__WINS__)
- //the emulator hangs in socket write (this is a test bug, it assumes the TCP stack can accept a whole image to its buffers)
- if(imageData.size() > 16384)
- QSKIP("image larger than socket buffer (test needs to be rewritten)", SkipSingle);
-#endif
Server server(imageData);
QEventLoop loop;
connect(&server, SIGNAL(ready()), &loop, SLOT(quit()));
diff --git a/tests/auto/gui/image/qimagewriter/qimagewriter.pro b/tests/auto/gui/image/qimagewriter/qimagewriter.pro
index 0fc40d0f0a..ebd5efd49a 100644
--- a/tests/auto/gui/image/qimagewriter/qimagewriter.pro
+++ b/tests/auto/gui/image/qimagewriter/qimagewriter.pro
@@ -11,15 +11,6 @@ wince*: {
addFiles.path = images
DEPLOYMENT += addFiles
DEFINES += SRCDIR=\\\".\\\"
-} else:symbian {
- addFiles.files = images\\*.*
- addFiles.path = images
- DEPLOYMENT += addFiles
- qt_not_deployed {
- imagePlugins.files = qjpeg.dll qtiff.dll
- imagePlugins.path = imageformats
- DEPLOYMENT += imagePlugins
- }
} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
}
diff --git a/tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp b/tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp
index b119763723..e21e671938 100644
--- a/tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp
+++ b/tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp
@@ -52,9 +52,6 @@
#include <QPainter>
#include <QSet>
-#if defined(Q_OS_SYMBIAN)
-# define SRCDIR ""
-#endif
typedef QMap<QString, QString> QStringMap;
typedef QList<int> QIntList;
Q_DECLARE_METATYPE(QImage)
@@ -106,11 +103,9 @@ private slots:
void saveToTemporaryFile();
};
-#ifdef Q_OS_SYMBIAN
-static const QLatin1String prefix(SRCDIR "images/");
-#else
+
static const QLatin1String prefix(SRCDIR "/images/");
-#endif
+
static void initializePadding(QImage *image)
{
int effectiveBytesPerLine = (image->width() * image->depth() + 7) / 8;
@@ -278,7 +273,7 @@ void tst_QImageWriter::writeImage2_data()
#if defined QTEST_HAVE_TIFF
void tst_QImageWriter::largeTiff()
{
-#if !defined(Q_OS_WINCE) && !defined(Q_OS_SYMBIAN)
+#if !defined(Q_OS_WINCE)
QImage img(4096, 2048, QImage::Format_ARGB32);
QPainter p(&img);
@@ -305,7 +300,7 @@ void tst_QImageWriter::largeTiff()
QCOMPARE(img, img2);
#else
- QWARN("not tested on Symbian/WinCE");
+ QWARN("not tested on WinCE");
#endif
}
#endif
diff --git a/tests/auto/gui/image/qmovie/qmovie.pro b/tests/auto/gui/image/qmovie/qmovie.pro
index 3e085ceeaf..54cd7a2548 100644
--- a/tests/auto/gui/image/qmovie/qmovie.pro
+++ b/tests/auto/gui/image/qmovie/qmovie.pro
@@ -15,14 +15,3 @@ wince*: {
RESOURCES += resources.qrc
-symbian: {
- addFiles.files = animations\\*
- addFiles.path = animations
- DEPLOYMENT += addFiles
-
- qt_not_deployed {
- imagePlugins.files = qjpeg.dll qgif.dll qmng.dll
- imagePlugins.path = imageformats
- DEPLOYMENT += imagePlugins
- }
-}
diff --git a/tests/auto/gui/image/qpixmap/qpixmap.pro b/tests/auto/gui/image/qpixmap/qpixmap.pro
index fe156d547c..d6d260da00 100644
--- a/tests/auto/gui/image/qpixmap/qpixmap.pro
+++ b/tests/auto/gui/image/qpixmap/qpixmap.pro
@@ -3,8 +3,7 @@ load(qttest_p4)
QT += core-private gui-private widgets widgets-private
SOURCES += tst_qpixmap.cpp
-wince*|symbian: {
-
+wince* {
task31722_0.files = convertFromImage/task31722_0/*.png
task31722_0.path = convertFromImage/task31722_0
@@ -18,13 +17,8 @@ wince*|symbian: {
loadFromData.path = loadFromData
DEPLOYMENT += task31722_0 task31722_1 icons loadFromData
-}
-
-wince*: {
DEFINES += SRCDIR=\\\".\\\"
DEPLOYMENT_PLUGIN += qico
-} else:symbian {
- LIBS += -lfbscli.dll -lbitgdi.dll -lgdi.dll
} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
win32:LIBS += -lgdi32 -luser32
diff --git a/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp b/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp
index 38858e5503..996bd6c017 100644
--- a/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp
+++ b/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp
@@ -64,26 +64,13 @@
#include <qscreen_qws.h>
#endif
-#ifdef Q_OS_SYMBIAN
-#include <e32std.h>
-#include <fbs.h>
-#include <gdi.h>
-#include <bitdev.h>
-#if !defined(QT_NO_OPENVG)
-#include <QtOpenVG/qvg.h>
-#include <QtOpenVG/private/qpixmapdata_vg_p.h>
-#endif
-#endif
-
#ifdef Q_WS_X11
#include <QX11Info>
#endif
//TESTED_CLASS=
//TESTED_FILES=
-#if defined(Q_OS_SYMBIAN)
-# define SRCDIR ""
-#endif
+
Q_DECLARE_METATYPE(QImage::Format)
class tst_QPixmap : public QObject
@@ -148,13 +135,6 @@ private slots:
void fromWinHICON();
#endif
-#if defined(Q_OS_SYMBIAN)
- void fromSymbianCFbsBitmap_data();
- void fromSymbianCFbsBitmap();
- void toSymbianCFbsBitmap_data();
- void toSymbianCFbsBitmap();
-#endif
-
void onlyNullPixmapsOutsideGuiThread();
void refUnref();
@@ -185,9 +165,6 @@ private slots:
void loadAsBitmapOrPixmap();
-#if defined(Q_OS_SYMBIAN) && !defined(QT_NO_OPENVG)
- void vgImageReadBack();
-#endif
void scaled_QTBUG19157();
};
@@ -337,11 +314,8 @@ void tst_QPixmap::convertFromImage_data()
{
QTest::addColumn<QImage>("img1");
QTest::addColumn<QImage>("img2");
-#ifdef Q_OS_SYMBIAN
- const QString prefix = QLatin1String(SRCDIR) + "convertFromImage";
-#else
const QString prefix = QLatin1String(SRCDIR) + "/convertFromImage";
-#endif
+
{
QImage img1;
QImage img2;
@@ -1107,157 +1081,6 @@ void tst_QPixmap::fromWinHICON()
#endif // Q_WS_WIN
-#if defined(Q_OS_SYMBIAN)
-Q_DECLARE_METATYPE(TDisplayMode)
-
-void tst_QPixmap::fromSymbianCFbsBitmap_data()
-{
- QTest::addColumn<TDisplayMode>("format");
- QTest::addColumn<int>("width");
- QTest::addColumn<int>("height");
- QTest::addColumn<QColor>("color");
-
- const int smallWidth = 20;
- const int smallHeight = 20;
- const int largeWidth = 240;
- const int largeHeight = 320;
- const int notAlignedWidth = 250;
- const int notAlignedHeight = 250;
-
- // Indexed Color Formats - Disabled since images seem to be blank -> no palette?
-// QTest::newRow("EGray2 small") << EGray2 << smallWidth << smallHeight << QColor(Qt::black);
-// QTest::newRow("EGray2 big") << EGray2 << largeWidth << largeHeight << QColor(Qt::black);
-// QTest::newRow("EGray256 small") << EGray256 << smallWidth << smallHeight << QColor(Qt::blue);
-// QTest::newRow("EGray256 big") << EGray256 << largeWidth << largeHeight << QColor(Qt::blue);
-// QTest::newRow("EColor256 small") << EColor256 << smallWidth << smallHeight << QColor(Qt::red);
-// QTest::newRow("EColor256 big") << EColor256 << largeWidth << largeHeight << QColor(Qt::red);
-
- // Direct Color Formats
- QTest::newRow("EColor4K small") << EColor4K << smallWidth << smallHeight << QColor(Qt::red);
- QTest::newRow("EColor4K big") << EColor4K << largeWidth << largeHeight << QColor(Qt::red);
- QTest::newRow("EColor4K not aligned") << EColor4K << notAlignedWidth << notAlignedHeight << QColor(Qt::red);
- QTest::newRow("EColor64K small") << EColor64K << smallWidth << smallHeight << QColor(Qt::green);
- QTest::newRow("EColor64K big") << EColor64K << largeWidth << largeHeight << QColor(Qt::green);
- QTest::newRow("EColor64K not aligned") << EColor64K << notAlignedWidth << notAlignedHeight << QColor(Qt::green);
- QTest::newRow("EColor16M small") << EColor16M << smallWidth << smallHeight << QColor(Qt::yellow);
- QTest::newRow("EColor16M big") << EColor16M << largeWidth << largeHeight << QColor(Qt::yellow);
- QTest::newRow("EColor16M not aligned") << EColor16M << notAlignedWidth << notAlignedHeight << QColor(Qt::yellow);
- QTest::newRow("EColor16MU small") << EColor16MU << smallWidth << smallHeight << QColor(Qt::red);
- QTest::newRow("EColor16MU big") << EColor16MU << largeWidth << largeHeight << QColor(Qt::red);
- QTest::newRow("EColor16MU not aligned") << EColor16MU << notAlignedWidth << notAlignedHeight << QColor(Qt::red);
- QTest::newRow("EColor16MA small opaque") << EColor16MA << smallWidth << smallHeight << QColor(255, 255, 0);
- QTest::newRow("EColor16MA big opaque") << EColor16MA << largeWidth << largeHeight << QColor(255, 255, 0);
- QTest::newRow("EColor16MA not aligned opaque") << EColor16MA << notAlignedWidth << notAlignedHeight << QColor(255, 255, 0);
-
- // Semi-transparent Colors - Disabled for now, since the QCOMPARE fails, but visually confirmed to work
-// QTest::newRow("EColor16MA small semi") << EColor16MA << smallWidth << smallHeight << QColor(255, 255, 0, 127);
-// QTest::newRow("EColor16MA big semi") << EColor16MA << largeWidth << largeHeight << QColor(255, 255, 0, 127);
-// QTest::newRow("EColor16MA small trans") << EColor16MA << smallWidth << smallHeight << QColor(255, 255, 0, 0);
-// QTest::newRow("EColor16MA big trans") << EColor16MA << largeWidth << largeHeight << QColor(255, 255, 0, 0);
-
-#if !defined(__SERIES60_31__)
- QTest::newRow("EColor16MAP small") << EColor16MAP << smallWidth << smallHeight << QColor(Qt::red);
- QTest::newRow("EColor16MAP big") << EColor16MAP << largeWidth << largeHeight << QColor(Qt::red);
-#endif
-}
-
-void tst_QPixmap::fromSymbianCFbsBitmap()
-{
- QFETCH(TDisplayMode, format);
- QFETCH(int, width);
- QFETCH(int, height);
- QFETCH(QColor, color);
- int expectedDepth = TDisplayModeUtils::NumDisplayModeBitsPerPixel(format);
-
- CFbsBitmap *nativeBitmap = 0;
- CFbsBitmapDevice *bitmapDevice = 0;
- CBitmapContext *bitmapContext = 0;
-
- nativeBitmap = new (ELeave) CFbsBitmap();
- TInt err = nativeBitmap->Create(TSize(width, height), format);
- CleanupStack::PushL(nativeBitmap);
- QVERIFY(err == KErrNone);
- bitmapDevice = CFbsBitmapDevice::NewL(nativeBitmap);
- CleanupStack::PushL(bitmapDevice);
-
- err = bitmapDevice->CreateBitmapContext(bitmapContext);
- CleanupStack::PushL(bitmapContext);
- QVERIFY(err == KErrNone);
- TRgb symbianColor = TRgb(color.red(), color.green(), color.blue(), color.alpha());
- bitmapContext->SetBrushColor(symbianColor);
- bitmapContext->Clear();
-
- __UHEAP_MARK;
- { // Test the null case
- CFbsBitmap *bitmap = 0;
- QPixmap pixmap = QPixmap::fromSymbianCFbsBitmap(bitmap);
- QVERIFY(pixmap.isNull());
- }
- __UHEAP_MARKEND;
-
- __UHEAP_MARK;
- { // Test the normal case
- QPixmap pixmap = QPixmap::fromSymbianCFbsBitmap(nativeBitmap);
-// QCOMPARE(pixmap.depth(), expectedDepth); // Depth is not preserved now
- QCOMPARE(pixmap.width(), width);
- QCOMPARE(pixmap.height(), height);
- QImage image = pixmap.toImage();
-
- QColor actualColor(image.pixel(1, 1));
- QCOMPARE(actualColor, color);
-
- QImage shouldBe(pixmap.width(), pixmap.height(), image.format());
- if (image.format() == QImage::Format_RGB16)
- shouldBe.fill(qrgb565(color.rgba()).rawValue());
- else
- shouldBe.fill(color.rgba());
- QCOMPARE(image, shouldBe);
- }
- __UHEAP_MARKEND;
-
- CleanupStack::PopAndDestroy(3);
-}
-
-void tst_QPixmap::toSymbianCFbsBitmap_data()
-{
- QTest::addColumn<int>("red");
- QTest::addColumn<int>("green");
- QTest::addColumn<int>("blue");
-
- QTest::newRow("red") << 255 << 0 << 0;
- QTest::newRow("green") << 0 << 255 << 0;
- QTest::newRow("blue") << 0 << 0 << 255;
-}
-
-void tst_QPixmap::toSymbianCFbsBitmap()
-{
- QFETCH(int, red);
- QFETCH(int, green);
- QFETCH(int, blue);
-
- QPixmap pm(100, 100);
- pm.fill(QColor(red, green, blue));
-
- CFbsBitmap *bitmap = pm.toSymbianCFbsBitmap();
-
- QVERIFY(bitmap != 0);
-
- // Verify size
- QCOMPARE(100, (int) bitmap->SizeInPixels().iWidth);
- QCOMPARE(100, (int) bitmap->SizeInPixels().iHeight);
-
- // Verify pixel color
- TRgb pixel;
- bitmap->GetPixel(pixel, TPoint(0,0));
- QCOMPARE((int)pixel.Red(), red);
- QCOMPARE((int)pixel.Green(), green);
- QCOMPARE((int)pixel.Blue(), blue);
-
- // Clean up
- delete bitmap;
-}
-#endif
-
void tst_QPixmap::onlyNullPixmapsOutsideGuiThread()
{
#ifdef Q_WS_QPA
@@ -1286,16 +1109,8 @@ void tst_QPixmap::onlyNullPixmapsOutsideGuiThread()
}
};
Thread thread;
-#if defined(Q_OS_SYMBIAN)
- thread.setStackSize(0x10000);
-#endif
thread.start();
-#if defined(Q_OS_SYMBIAN)
- QVERIFY(thread.wait(10000));
-#else
thread.wait();
-#endif
-
#endif // !defined(Q_WS_WIN) && !defined(Q_WS_MAC)
}
@@ -1489,11 +1304,9 @@ void tst_QPixmap::loadFromDataNullValues()
void tst_QPixmap::loadFromDataImage_data()
{
QTest::addColumn<QString>("imagePath");
-#ifdef Q_OS_SYMBIAN
- const QString prefix = QLatin1String(SRCDIR) + "loadFromData";
-#else
+
const QString prefix = QLatin1String(SRCDIR) + "/loadFromData";
-#endif
+
QTest::newRow("designer_argb32.png") << prefix + "/designer_argb32.png";
// When no extension is provided we try all extensions that has been registered by image providers
QTest::newRow("designer_argb32") << prefix + "/designer_argb32.png";
@@ -1525,11 +1338,9 @@ void tst_QPixmap::loadFromDataImage()
void tst_QPixmap::fromImageReader_data()
{
QTest::addColumn<QString>("imagePath");
-#ifdef Q_OS_SYMBIAN
- const QString prefix = QLatin1String(SRCDIR) + "loadFromData";
-#else
+
const QString prefix = QLatin1String(SRCDIR) + "/loadFromData";
-#endif
+
QTest::newRow("designer_argb32.png") << prefix + "/designer_argb32.png";
QTest::newRow("designer_indexed8_no_alpha.png") << prefix + "/designer_indexed8_no_alpha.png";
QTest::newRow("designer_indexed8_with_alpha.png") << prefix + "/designer_indexed8_with_alpha.png";
@@ -1565,11 +1376,8 @@ void tst_QPixmap::fromImageReaderAnimatedGif_data()
void tst_QPixmap::fromImageReaderAnimatedGif()
{
QFETCH(QString, imagePath);
-#ifdef Q_OS_SYMBIAN
- const QString prefix = QLatin1String(SRCDIR) + "loadFromData";
-#else
+
const QString prefix = QLatin1String(SRCDIR) + "/loadFromData";
-#endif
const QString path = prefix + imagePath;
QImageReader referenceReader(path);
@@ -1677,105 +1485,6 @@ void tst_QPixmap::toImageDeepCopy()
QVERIFY(first != second);
}
-#if defined(Q_OS_SYMBIAN) && !defined(QT_NO_OPENVG)
-Q_OPENVG_EXPORT VGImage qPixmapToVGImage(const QPixmap& pixmap);
-class FriendlyVGPlatformPixmap : public QVGPlatformPixmap
-{
-public:
- FriendlyVGPlatformPixmap(PixelType type) : QVGPlatformPixmap(type) { }
- bool sourceIsNull() { return source.isNull(); }
- friend QPixmap pixmapFromVGImage(VGImage image);
-};
-QPixmap pixmapFromVGImage(VGImage image)
-{
- if (image != VG_INVALID_HANDLE) {
- int w = vgGetParameteri(image, VG_IMAGE_WIDTH);
- int h = vgGetParameteri(image, VG_IMAGE_HEIGHT);
- FriendlyVGPlatformPixmap *pd = new FriendlyVGPlatformPixmap(QPlatformPixmap::PixmapType);
- pd->resize(w, h);
- pd->vgImage = image;
- pd->recreate = false;
- pd->prevSize = QSize(pd->w, pd->h);
- return QPixmap(pd);
- }
- return QPixmap();
-}
-class Content : public QWidget
-{
-public:
- void paintEvent(QPaintEvent *) {
- QPainter painter(this);
- QColor testPixel(qRgb(200, 150, 100));
- if (pm.isNull()) { // first phase: create a VGImage
- painter.beginNativePainting();
- vgimage = vgCreateImage(VG_sARGB_8888_PRE, w, h, VG_IMAGE_QUALITY_FASTER);
- QImage img(20, 10, QImage::Format_ARGB32_Premultiplied);
- img.fill(qRgb(0, 0, 0));
- QPainter p(&img);
- p.fillRect(0, 0, img.width(), img.height(), testPixel);
- p.end();
- vgImageSubData(vgimage, img.bits(), img.bytesPerLine(), VG_sARGB_8888_PRE, 0, 0, img.width(), img.height());
- // Now the area 0,0 20x10 (in OpenVG coords) is filled with some color.
- painter.endNativePainting();
- } else { // second phase: check if readback works
- painter.drawPixmap(0, 0, pm);
- // Drawing should not cause readback, this is important for performance;
- noreadback_ok = static_cast<FriendlyVGPlatformPixmap *>(pm.handle())->sourceIsNull();
- // However toImage() requires readback.
- QImage img = pm.toImage();
- readback_ok = img.width() == pm.width();
- readback_ok &= img.height() == pm.height();
- readback_ok &= !static_cast<FriendlyVGPlatformPixmap *>(pm.handle())->sourceIsNull();
- uint pix = img.pixel(1, 1);
- content_ok = qRed(pix) == testPixel.red();
- content_ok &= qGreen(pix) == testPixel.green();
- content_ok &= qBlue(pix) == testPixel.blue();
- pix = img.pixel(img.width() - 1, img.height() - 1);
- content_ok &= qRed(pix) == 0;
- content_ok &= qGreen(pix) == 0;
- content_ok &= qBlue(pix) == 0;
- }
- }
- int w;
- int h;
- VGImage vgimage;
- QPixmap pm;
- bool noreadback_ok;
- bool readback_ok;
- bool content_ok;
-};
-void tst_QPixmap::vgImageReadBack()
-{
- QPixmap tmp(10, 20);
- if (tmp.handle()->classId() == QPlatformPixmap::OpenVGClass) {
- Content c;
- c.w = 50;
- c.h = 60;
- c.vgimage = VG_INVALID_HANDLE;
- c.noreadback_ok = c.readback_ok = c.content_ok = false;
- c.showFullScreen();
- QTest::qWaitForWindowShown(&c);
- QVERIFY(c.vgimage != VG_INVALID_HANDLE);
- QPixmap pm = pixmapFromVGImage(c.vgimage);
- QVERIFY(!pm.isNull());
- QCOMPARE(pm.width(), c.w);
- QCOMPARE(pm.height(), c.h);
- QVERIFY(qPixmapToVGImage(pm) == c.vgimage);
- QVERIFY(static_cast<FriendlyVGPlatformPixmap *>(pm.handle())->sourceIsNull());
- c.pm = pm;
- // Make sure the second phase in paintEvent is executed too.
- c.hide();
- c.showFullScreen();
- QTest::qWaitForWindowShown(&c);
- QVERIFY(c.noreadback_ok);
- QVERIFY(c.readback_ok);
- QVERIFY(c.content_ok);
- } else {
- QSKIP("Not using openvg graphicssystem", SkipSingle);
- }
-}
-#endif // Symbian & OpenVG
-
void tst_QPixmap::scaled_QTBUG19157()
{
QPixmap foo(5000, 1);
diff --git a/tests/auto/gui/image/qvolatileimage/qvolatileimage.pro b/tests/auto/gui/image/qvolatileimage/qvolatileimage.pro
index 45d80b85f2..d97eb1ee13 100644
--- a/tests/auto/gui/image/qvolatileimage/qvolatileimage.pro
+++ b/tests/auto/gui/image/qvolatileimage/qvolatileimage.pro
@@ -3,8 +3,3 @@ load(qttest_p4)
QT += gui-private widgets
SOURCES += tst_qvolatileimage.cpp
-
-symbian {
- TARGET.EPOCHEAPSIZE = 0x200000 0x800000
- LIBS += -lfbscli
-}
diff --git a/tests/auto/gui/image/qvolatileimage/tst_qvolatileimage.cpp b/tests/auto/gui/image/qvolatileimage/tst_qvolatileimage.cpp
index bacca66dcd..87389ff355 100644
--- a/tests/auto/gui/image/qvolatileimage/tst_qvolatileimage.cpp
+++ b/tests/auto/gui/image/qvolatileimage/tst_qvolatileimage.cpp
@@ -44,9 +44,6 @@
#include <QtGui/qpainter.h>
#include <QtGui/qpaintengine.h>
#include <QtGui/private/qvolatileimage_p.h>
-#ifdef Q_OS_SYMBIAN
-#include <fbs.h>
-#endif
class tst_QVolatileImage : public QObject
{
@@ -60,10 +57,8 @@ private slots:
void ensureFormat();
void dataAccess();
void sharing();
- void paint();
void fill();
void copy();
- void bitmap();
};
void tst_QVolatileImage::create()
@@ -93,21 +88,6 @@ void tst_QVolatileImage::create()
QCOMPARE(img.hasAlphaChannel(), img.imageRef().hasAlphaChannel());
QCOMPARE(img.hasAlphaChannel(), img.toImage().hasAlphaChannel());
QCOMPARE(img.depth(), 32);
-
-#ifdef Q_OS_SYMBIAN
- CFbsBitmap *bmp = new CFbsBitmap;
- QVERIFY(bmp->Create(TSize(100, 50), EColor16MAP) == KErrNone);
- QVolatileImage bmpimg(bmp);
- QVERIFY(!bmpimg.isNull());
- QCOMPARE(bmpimg.width(), 100);
- QCOMPARE(bmpimg.height(), 50);
- // Verify that we only did handle duplication, not pixel data copying.
- QCOMPARE(bmpimg.constBits(), (const uchar *) bmp->DataAddress());
- delete bmp;
- // Check if content is still valid.
- QImage copyimg = bmpimg.toImage();
- QCOMPARE(copyimg.format(), QImage::Format_ARGB32_Premultiplied);
-#endif
}
void tst_QVolatileImage::ensureFormat()
@@ -127,30 +107,6 @@ void tst_QVolatileImage::ensureFormat()
QVERIFY(img.imageRef() != source);
QVERIFY(img.toImage() != source);
QVERIFY(img.format() == QImage::Format_RGB32);
-
-#ifdef Q_OS_SYMBIAN
- CFbsBitmap *bmp = new CFbsBitmap;
- QVERIFY(bmp->Create(TSize(100, 50), EColor16MAP) == KErrNone);
- QVolatileImage bmpimg(bmp);
- QVERIFY(bmpimg.ensureFormat(QImage::Format_ARGB32_Premultiplied)); // no-op
- QCOMPARE(bmpimg.constBits(), (const uchar *) bmp->DataAddress());
-
- // A different format should cause data copying.
- QVERIFY(bmpimg.ensureFormat(QImage::Format_RGB32));
- QVERIFY(bmpimg.constBits() != (const uchar *) bmp->DataAddress());
- const uchar *prevBits = bmpimg.constBits();
-
- QVERIFY(bmpimg.ensureFormat(QImage::Format_RGB16));
- QVERIFY(bmpimg.constBits() != (const uchar *) bmp->DataAddress());
- QVERIFY(bmpimg.constBits() != prevBits);
- prevBits = bmpimg.constBits();
-
- QVERIFY(bmpimg.ensureFormat(QImage::Format_MonoLSB));
- QVERIFY(bmpimg.constBits() != (const uchar *) bmp->DataAddress());
- QVERIFY(bmpimg.constBits() != prevBits);
-
- delete bmp;
-#endif
}
void tst_QVolatileImage::dataAccess()
@@ -190,21 +146,6 @@ void tst_QVolatileImage::sharing()
// toImage() should return a copy of the internal QImage.
// imageRef() is a reference to the internal QImage.
QVERIFY(img1.imageRef().constBits() != img1.toImage().constBits());
-
-#ifdef Q_OS_SYMBIAN
- CFbsBitmap *bmp = new CFbsBitmap;
- QVERIFY(bmp->Create(TSize(100, 50), EColor16MAP) == KErrNone);
- QVolatileImage bmpimg(bmp);
- QVolatileImage bmpimg2;
- bmpimg2 = bmpimg;
- QCOMPARE(bmpimg.constBits(), (const uchar *) bmp->DataAddress());
- QCOMPARE(bmpimg2.constBits(), (const uchar *) bmp->DataAddress());
- // Now force a detach, which should copy the pixel data under-the-hood.
- bmpimg.imageRef();
- QVERIFY(bmpimg.constBits() != (const uchar *) bmp->DataAddress());
- QCOMPARE(bmpimg2.constBits(), (const uchar *) bmp->DataAddress());
- delete bmp;
-#endif
}
bool fuzzyCompareImages(const QImage &image1, const QImage &image2, int tolerance)
@@ -227,52 +168,6 @@ bool fuzzyCompareImages(const QImage &image1, const QImage &image2, int toleranc
return true;
}
-void tst_QVolatileImage::paint()
-{
-#ifdef Q_OS_SYMBIAN
- QVolatileImage img(100, 100, QImage::Format_ARGB32);
- img.beginDataAccess();
- img.imageRef().fill(QColor(Qt::green).rgba());
- QPainter p(&img.imageRef());
- p.drawRect(10, 10, 50, 50);
- p.end();
- img.endDataAccess();
- QImage imgA = img.toImage();
-
- // The following assumes that on openvg the pixmapdata is backed by QVolatileImage)
- // (and that openvg is in use)
- // It should pass with any engine nonetheless.
- // See if painting into the underlying QImage succeeds.
- QPixmap pm(100, 100);
- if (pm.paintEngine()->type() == QPaintEngine::Raster) {
- pm.fill(Qt::green);
- QPainter pmp(&pm);
- pmp.drawRect(10, 10, 50, 50);
- pmp.end();
- QImage imgB = pm.toImage();
- QVERIFY(fuzzyCompareImages(imgA, imgB, 0));
- // Exercise the accelerated QVolatileImagePaintEngine::drawPixmap() a bit.
- QPixmap targetPm(pm.size());
- targetPm.fill(Qt::black);
- pmp.begin(&targetPm);
- pmp.drawPixmap(QPointF(0, 0), pm);
- pmp.end();
- imgB = targetPm.toImage();
- QVERIFY(fuzzyCompareImages(imgA, imgB, 0));
- // Now the overload taking rects.
- targetPm.fill(Qt::black);
- pmp.begin(&targetPm);
- QRectF rect(QPointF(0, 0), pm.size());
- pmp.drawPixmap(rect, pm, rect);
- pmp.end();
- imgB = targetPm.toImage();
- QVERIFY(fuzzyCompareImages(imgA, imgB, 0));
- } else {
- QSKIP("Pixmaps not painted via raster, skipping paint test", SkipSingle);
- }
-#endif
-}
-
void tst_QVolatileImage::fill()
{
QVolatileImage img(100, 100, QImage::Format_ARGB32_Premultiplied);
@@ -280,17 +175,6 @@ void tst_QVolatileImage::fill()
img.fill(col.rgba());
QVERIFY(img.imageRef().pixel(1, 1) == col.rgba());
QVERIFY(img.toImage().pixel(1, 1) == col.rgba());
-
-#ifdef Q_OS_SYMBIAN
- CFbsBitmap *bmp = static_cast<CFbsBitmap *>(img.duplicateNativeImage());
- QVERIFY(bmp);
- TRgb pix;
- bmp->GetPixel(pix, TPoint(1, 1));
- QCOMPARE(pix.Red(), col.red());
- QCOMPARE(pix.Green(), col.green());
- QCOMPARE(pix.Blue(), col.blue());
- delete bmp;
-#endif
}
void tst_QVolatileImage::copy()
@@ -318,80 +202,6 @@ void tst_QVolatileImage::copy()
QVERIFY(fuzzyCompareImages(imgA, imgB, 0));
}
-void tst_QVolatileImage::bitmap()
-{
-#ifdef Q_OS_SYMBIAN
- CFbsBitmap *bmp = new CFbsBitmap;
- QVERIFY(bmp->Create(TSize(100, 50), EColor64K) == KErrNone);
- QVolatileImage bmpimg(bmp);
- CFbsBitmap *dupbmp = static_cast<CFbsBitmap *>(bmpimg.duplicateNativeImage());
- QVERIFY(dupbmp);
- QVERIFY(dupbmp != bmp);
- QCOMPARE(dupbmp->DataAddress(), bmp->DataAddress());
- delete dupbmp;
- delete bmp;
- bmpimg.beginDataAccess();
- qMemSet(bmpimg.bits(), 0, bmpimg.byteCount());
- qMemSet(bmpimg.bits(), 1, bmpimg.bytesPerLine() * bmpimg.height());
- bmpimg.endDataAccess();
-
- // Test bgr->rgb conversion in case of EColor16M.
- bmp = new CFbsBitmap;
- QVERIFY(bmp->Create(TSize(101, 89), EColor16M) == KErrNone);
- bmp->BeginDataAccess();
- TUint32 *addr = bmp->DataAddress();
- uint rgb = QColor(10, 20, 30).rgb();
- qMemCopy(bmp->DataAddress(), &rgb, 3);
- bmp->EndDataAccess();
- TRgb symrgb;
- bmp->GetPixel(symrgb, TPoint(0, 0));
- QVERIFY(symrgb.Red() == 10 && symrgb.Green() == 20 && symrgb.Blue() == 30);
- bmpimg = QVolatileImage(bmp);
- QVERIFY(bmpimg.toImage().pixel(0, 0) == rgb);
- // check if there really was a conversion
- bmp->BeginDataAccess();
- bmpimg.beginDataAccess();
- qMemCopy(&rgb, bmpimg.constBits(), 3);
- uint rgb2 = rgb;
- qMemCopy(&rgb2, bmp->DataAddress(), 3);
- QVERIFY(rgb != rgb2);
- bmpimg.endDataAccess(true);
- bmp->EndDataAccess(true);
- delete bmp;
-
- bmp = new CFbsBitmap;
- QVERIFY(bmp->Create(TSize(101, 89), EGray2) == KErrNone);
- bmpimg = QVolatileImage(bmp); // inverts pixels, but should do it in place
- QCOMPARE(bmpimg.constBits(), (const uchar *) bmp->DataAddress());
- QCOMPARE(bmpimg.format(), QImage::Format_MonoLSB);
- bmpimg.ensureFormat(QImage::Format_ARGB32_Premultiplied);
- QVERIFY(bmpimg.constBits() != (const uchar *) bmp->DataAddress());
- QCOMPARE(bmpimg.format(), QImage::Format_ARGB32_Premultiplied);
- delete bmp;
-
- // The following two formats must be optimal always.
- bmp = new CFbsBitmap;
- QVERIFY(bmp->Create(TSize(101, 89), EColor16MAP) == KErrNone);
- bmpimg = QVolatileImage(bmp);
- QCOMPARE(bmpimg.format(), QImage::Format_ARGB32_Premultiplied);
- QCOMPARE(bmpimg.constBits(), (const uchar *) bmp->DataAddress());
- bmpimg.ensureFormat(QImage::Format_ARGB32_Premultiplied);
- QCOMPARE(bmpimg.constBits(), (const uchar *) bmp->DataAddress());
- delete bmp;
- bmp = new CFbsBitmap;
- QVERIFY(bmp->Create(TSize(101, 89), EColor16MU) == KErrNone);
- bmpimg = QVolatileImage(bmp);
- QCOMPARE(bmpimg.format(), QImage::Format_RGB32);
- QCOMPARE(bmpimg.constBits(), (const uchar *) bmp->DataAddress());
- bmpimg.ensureFormat(QImage::Format_RGB32);
- QCOMPARE(bmpimg.constBits(), (const uchar *) bmp->DataAddress());
- delete bmp;
-
-#else
- QSKIP("CFbsBitmap is only available on Symbian, skipping bitmap test", SkipSingle);
-#endif
-}
-
int main(int argc, char *argv[])
{
QApplication::setGraphicsSystem("openvg");
diff --git a/tests/auto/gui/kernel/kernel.pro b/tests/auto/gui/kernel/kernel.pro
index 58cb247573..c77ea2be2e 100644
--- a/tests/auto/gui/kernel/kernel.pro
+++ b/tests/auto/gui/kernel/kernel.pro
@@ -13,6 +13,3 @@ SUBDIRS=\
qshortcut \
qtouchevent \
-symbian {
- SUBDIRS += qsoftkeymanager
-}
diff --git a/tests/auto/gui/kernel/qclipboard/test/test.pro b/tests/auto/gui/kernel/qclipboard/test/test.pro
index 12c6b6ce4f..38552273c3 100644
--- a/tests/auto/gui/kernel/qclipboard/test/test.pro
+++ b/tests/auto/gui/kernel/qclipboard/test/test.pro
@@ -10,23 +10,11 @@ win32 {
}
}
-wince*|symbian: {
+wince* {
copier.files = ../copier/copier.exe
copier.path = copier
paster.files = ../paster/paster.exe
paster.path = paster
- symbian: {
- LIBS += -lbafl -lestor -letext
-
- load(data_caging_paths)
- rsc.files = $${EPOCROOT}$$HW_ZDIR$$APP_RESOURCE_DIR/copier.rsc
- rsc.files += $${EPOCROOT}$$HW_ZDIR$$APP_RESOURCE_DIR/paster.rsc
- rsc.path = $$APP_RESOURCE_DIR
- reg_resource.files = $${EPOCROOT}$$HW_ZDIR$$REG_RESOURCE_IMPORT_DIR/copier_reg.rsc
- reg_resource.files += $${EPOCROOT}$$HW_ZDIR$$REG_RESOURCE_IMPORT_DIR/paster_reg.rsc
- reg_resource.path = $$REG_RESOURCE_IMPORT_DIR
- }
-
DEPLOYMENT += copier paster rsc reg_resource
-} \ No newline at end of file
+}
diff --git a/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp b/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
index 4d3bb29e13..34bc581396 100644
--- a/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
+++ b/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
@@ -47,14 +47,6 @@
#ifdef Q_WS_MAC
#include <Carbon/Carbon.h>
#endif
-#ifdef Q_OS_SYMBIAN
-#include "private/qcore_symbian_p.h"
-#include "txtetext.h"
-#include <baclipb.h>
-#endif
-#ifdef SYMBIAN_ENABLE_SPLIT_HEADERS
-#include "txtclipboard.h"
-#endif
//TESTED_CLASS=
//TESTED_FILES=
@@ -70,10 +62,6 @@ private slots:
void testSignals();
void setMimeData();
void clearBeforeSetText();
-#ifdef Q_OS_SYMBIAN
- void pasteCopySymbian();
- void copyPasteSymbian();
-#endif
private:
bool nativeClipboardWorking();
@@ -208,8 +196,6 @@ void tst_QClipboard::copy_exit_paste()
#if defined Q_WS_X11 || defined Q_WS_QWS || defined (Q_WS_QPA)
QSKIP("This test does not make sense on X11 and embedded, copied data disappears from the clipboard when the application exits ", SkipAll);
// ### It's still possible to test copy/paste - just keep the apps running
-#elif defined (Q_OS_SYMBIAN) && defined (Q_CC_NOKIAX86)
- QSKIP("emulator cannot launch multiple processes",SkipAll);
#endif
if (!nativeClipboardWorking())
QSKIP("Native clipboard not working in this setup", SkipAll);
@@ -347,76 +333,6 @@ void tst_QClipboard::clearBeforeSetText()
QCOMPARE(QApplication::clipboard()->text(), text);
}
-/*
- Test that text copied from qt application
- can be pasted with symbian clipboard
-*/
-#ifdef Q_OS_SYMBIAN
-// ### This test case only makes sense in symbian
-void tst_QClipboard::pasteCopySymbian()
-{
- if (!nativeClipboardWorking())
- QSKIP("Native clipboard not working in this setup", SkipAll);
- const QString string("Test string symbian.");
- QApplication::clipboard()->setText(string);
-
- const TInt KPlainTextBegin = 0;
- RFs fs = qt_s60GetRFs();
- CClipboard* cb = CClipboard::NewForReadingLC(fs);
-
- CPlainText* text = CPlainText::NewL();
- CleanupStack::PushL(text);
- TInt dataLength = text->PasteFromStoreL(cb->Store(), cb->StreamDictionary(),
- KPlainTextBegin);
- if (dataLength == 0) {
- User::Leave(KErrNotFound);
- }
- HBufC* hBuf = HBufC::NewL(dataLength);
- TPtr buf = hBuf->Des();
- text->Extract(buf, KPlainTextBegin, dataLength);
-
- QString storeString = qt_TDesC2QString(buf);
- CleanupStack::PopAndDestroy(text);
- CleanupStack::PopAndDestroy(cb);
-
- QCOMPARE(string, storeString);
-}
-#endif
-
-/*
- Test that text copied to symbian clipboard
- can be pasted to qt clipboard
-*/
-#ifdef Q_OS_SYMBIAN
-// ### This test case only makes sense in symbian
-void tst_QClipboard::copyPasteSymbian()
-{
- if (!nativeClipboardWorking())
- QSKIP("Native clipboard not working in this setup", SkipAll);
- const QString string("Test string symbian.");
- const TInt KPlainTextBegin = 0;
-
- RFs fs = qt_s60GetRFs();
- CClipboard* cb = CClipboard::NewForWritingLC(fs);
- CStreamStore& store = cb->Store();
- CStreamDictionary& dict = cb->StreamDictionary();
- RStoreWriteStream symbianStream;
- TStreamId symbianStId = symbianStream.CreateLC(cb->Store());
-
- CPlainText* text = CPlainText::NewL();
- CleanupStack::PushL(text);
- TPtrC textPtr(qt_QString2TPtrC(string));
- text->InsertL(KPlainTextBegin, textPtr);
- text->CopyToStoreL(store, dict, KPlainTextBegin, textPtr.Length());
- CleanupStack::PopAndDestroy(text);
- (cb->StreamDictionary()).AssignL(KClipboardUidTypePlainText, symbianStId);
- cb->CommitL();
- CleanupStack::PopAndDestroy(2, cb);
-
- QCOMPARE(QApplication::clipboard()->text(), string);
-}
-#endif
-
QTEST_MAIN(tst_QClipboard)
#include "tst_qclipboard.moc"
diff --git a/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro b/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro
index cb61b82e38..7de7b2ec57 100644
--- a/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro
+++ b/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro
@@ -2,9 +2,3 @@ TEMPLATE = app
TARGET = qfileopeneventexternal
QT += core gui widgets
SOURCES += qfileopeneventexternal.cpp
-symbian: {
- RSS_RULES += "embeddability=KAppEmbeddable;"
- RSS_RULES.datatype_list += "priority = EDataTypePriorityHigh; type = \"application/x-tst_qfileopenevent\";"
- LIBS += -lapparc \
- -leikcore -lefsrv -lcone
-}
diff --git a/tests/auto/gui/kernel/qfileopenevent/test/test.pro b/tests/auto/gui/kernel/qfileopenevent/test/test.pro
index 3f16dcf6ee..1a813bca20 100644
--- a/tests/auto/gui/kernel/qfileopenevent/test/test.pro
+++ b/tests/auto/gui/kernel/qfileopenevent/test/test.pro
@@ -2,6 +2,3 @@ load(qttest_p4)
TARGET = tst_qfileopenevent
HEADERS +=
SOURCES += tst_qfileopenevent.cpp
-symbian {
- LIBS+=-lefsrv -lapgrfx -lapmime
-}
diff --git a/tests/auto/gui/kernel/qfileopenevent/test/tst_qfileopenevent.cpp b/tests/auto/gui/kernel/qfileopenevent/test/tst_qfileopenevent.cpp
index 3916f420a6..00008a80f0 100644
--- a/tests/auto/gui/kernel/qfileopenevent/test/tst_qfileopenevent.cpp
+++ b/tests/auto/gui/kernel/qfileopenevent/test/tst_qfileopenevent.cpp
@@ -42,11 +42,6 @@
#include <QtTest/QtTest>
#include <QtGui/qevent.h>
-#ifdef Q_OS_SYMBIAN
-#include <apgcli.h>
-#include "private/qcore_symbian_p.h"
-#endif
-
class tst_qfileopenevent : public QObject
{
Q_OBJECT
@@ -63,39 +58,15 @@ private slots:
void handleLifetime();
void multiOpen();
void sendAndReceive();
- void external_data();
- void external();
private:
-#ifdef Q_OS_SYMBIAN
- RFile createRFile(const TDesC& filename, const TDesC8& content);
-#else
void createFile(const QString &filename, const QByteArray &content);
-#endif
QFileOpenEvent * createFileAndEvent(const QString &filename, const QByteArray &content);
void checkReadAndWrite(QFileOpenEvent& event, const QByteArray& readContent, const QByteArray& writeContent, bool writeOk);
QByteArray readFileContent(QFileOpenEvent& event);
bool appendFileContent(QFileOpenEvent& event, const QByteArray& writeContent);
bool event(QEvent *);
-
-private:
-#ifdef Q_OS_SYMBIAN
- struct AutoRFs : public RFs
- {
- AutoRFs()
- {
- qt_symbian_throwIfError(Connect());
- qt_symbian_throwIfError(ShareProtected());
- }
-
- ~AutoRFs()
- {
- Close();
- }
- };
- AutoRFs fsSession;
-#endif
};
tst_qfileopenevent::~tst_qfileopenevent()
@@ -106,15 +77,6 @@ void tst_qfileopenevent::initTestCase()
{
}
-#ifdef Q_OS_SYMBIAN
-RFile tst_qfileopenevent::createRFile(const TDesC& filename, const TDesC8& content)
-{
- RFile file;
- qt_symbian_throwIfError(file.Replace(fsSession, filename, EFileWrite));
- qt_symbian_throwIfError(file.Write(content));
- return file;
-}
-#else
void tst_qfileopenevent::createFile(const QString &filename, const QByteArray &content)
{
QFile file(filename);
@@ -122,18 +84,11 @@ void tst_qfileopenevent::createFile(const QString &filename, const QByteArray &c
file.write(content);
file.close();
}
-#endif
QFileOpenEvent * tst_qfileopenevent::createFileAndEvent(const QString &filename, const QByteArray &content)
{
-#ifdef Q_OS_SYMBIAN
- RFile rFile = createRFile(qt_QString2TPtrC(filename), TPtrC8((TText8*)content.constData(), content.size()));
- QScopedPointer<RFile, QScopedPointerRCloser<RFile> > closeRFile(&rFile);
- return new QFileOpenEvent(rFile);
-#else
createFile(filename, content);
return new QFileOpenEvent(filename);
-#endif
}
void tst_qfileopenevent::constructor()
@@ -145,16 +100,6 @@ void tst_qfileopenevent::constructor()
// check that url get/set works
QFileOpenEvent urlTest(QUrl(QLatin1String("file:///urlNameTest")));
QCOMPARE(urlTest.url().toString(), QLatin1String("file:///urlNameTest"));
-
-#ifdef Q_OS_SYMBIAN
- // check that RFile construction works
- RFile rFile = createRFile(_L("testRFile"), _L8("test content"));
- QFileOpenEvent rFileTest(rFile);
- QString targetName(QLatin1String("testRFile"));
- QCOMPARE(rFileTest.file().right(targetName.size()), targetName);
- QCOMPARE(rFileTest.url().toString().right(targetName.size()), targetName);
- rFile.Close();
-#endif
}
QByteArray tst_qfileopenevent::readFileContent(QFileOpenEvent& event)
@@ -184,26 +129,7 @@ void tst_qfileopenevent::checkReadAndWrite(QFileOpenEvent& event, const QByteArr
void tst_qfileopenevent::fileOpen()
{
-#ifdef Q_OS_SYMBIAN
- // create writeable file
- {
- RFile rFile = createRFile(_L("testFileOpen"), _L8("test content"));
- QFileOpenEvent rFileTest(rFile);
- checkReadAndWrite(rFileTest, QByteArray("test content"), QByteArray("+RFileWrite"), true);
- rFile.Close();
- }
-
- // open read-only RFile
- {
- RFile rFile;
- int err = rFile.Open(fsSession, _L("testFileOpen"), EFileRead);
- QFileOpenEvent rFileTest(rFile);
- checkReadAndWrite(rFileTest, QByteArray("test content+RFileWrite"), QByteArray("+RFileRead"), false);
- rFile.Close();
- }
-#else
createFile(QLatin1String("testFileOpen"), QByteArray("test content+RFileWrite"));
-#endif
// filename event
QUrl fileUrl; // need to get the URL during the file test, for use in the URL test
@@ -297,66 +223,5 @@ void tst_qfileopenevent::sendAndReceive()
QFile::remove(QLatin1String("testSendAndReceive"));
}
-void tst_qfileopenevent::external_data()
-{
- QTest::addColumn<QString>("filename");
- QTest::addColumn<QByteArray>("targetContent");
- QTest::addColumn<bool>("sendHandle");
-
- QString privateName(QLatin1String("tst_qfileopenevent_external"));
- QString publicName(QLatin1String("C:\\Data\\tst_qfileopenevent_external"));
- QByteArray writeSuccess("original+external");
- QByteArray writeFail("original");
- QTest::newRow("public name") << publicName << writeSuccess << false;
- QTest::newRow("data caged name") << privateName << writeFail << false;
- QTest::newRow("public handle") << publicName << writeSuccess << true;
- QTest::newRow("data caged handle") << privateName << writeSuccess << true;
-}
-
-void tst_qfileopenevent::external()
-{
-#ifndef Q_OS_SYMBIAN
- QSKIP("external app file open test only valid in Symbian", SkipAll);
-#else
-
- QFETCH(QString, filename);
- QFETCH(QByteArray, targetContent);
- QFETCH(bool, sendHandle);
-
- RFile rFile = createRFile(qt_QString2TPtrC(filename), _L8("original"));
-
- // launch app with the file
- RApaLsSession apa;
- QCOMPARE(apa.Connect(), KErrNone);
- TThreadId threadId;
- TDataType type(_L8("application/x-tst_qfileopenevent"));
- if (sendHandle) {
- QCOMPARE(apa.StartDocument(rFile, type, threadId), KErrNone);
- rFile.Close();
- } else {
- TFileName fullName;
- rFile.FullName(fullName);
- rFile.Close();
- QCOMPARE(apa.StartDocument(fullName, type, threadId), KErrNone);
- }
-
- // wait for app exit
- RThread appThread;
- if (appThread.Open(threadId) == KErrNone) {
- TRequestStatus status;
- appThread.Logon(status);
- User::WaitForRequest(status);
- }
-
- // check the contents
- QFile check(filename);
- QCOMPARE(check.open(QFile::ReadOnly), true);
- QCOMPARE(check.readAll(), targetContent);
- bool ok = check.remove();
-
- QFile::remove(filename);
-#endif
-}
-
QTEST_MAIN(tst_qfileopenevent)
#include "tst_qfileopenevent.moc"
diff --git a/tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp b/tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp
index 5753fb8df4..4c9fc149e5 100644
--- a/tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp
+++ b/tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp
@@ -567,8 +567,8 @@ void tst_QKeySequence::translated()
QFETCH(QString, compKey);
#ifdef Q_WS_MAC
QSKIP("No need to translate modifiers on Mac OS X", SkipAll);
-#elif defined(Q_OS_WINCE) || defined(Q_OS_SYMBIAN)
- QSKIP("No need to translate modifiers on WinCE or Symbian", SkipAll);
+#elif defined(Q_OS_WINCE)
+ QSKIP("No need to translate modifiers on WinCE", SkipAll);
#endif
qApp->installTranslator(ourTranslator);
diff --git a/tests/auto/gui/painting/qpainter/qpainter.pro b/tests/auto/gui/painting/qpainter/qpainter.pro
index 3660da3e39..23cb5db16e 100644
--- a/tests/auto/gui/painting/qpainter/qpainter.pro
+++ b/tests/auto/gui/painting/qpainter/qpainter.pro
@@ -3,17 +3,13 @@ load(qttest_p4)
QT += widgets widgets-private printsupport
SOURCES += tst_qpainter.cpp
-wince*|symbian: {
+wince* {
addFiles.files = drawEllipse drawLine_rop_bitmap drawPixmap_rop drawPixmap_rop_bitmap task217400.png
addFiles.path = .
DEPLOYMENT += addFiles
-}
-
-wince* {
DEFINES += SRCDIR=\\\".\\\"
-} else:!symbian {
+} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
}
-
mac*:CONFIG+=insignificant_test
diff --git a/tests/auto/gui/painting/qpainter/tst_qpainter.cpp b/tests/auto/gui/painting/qpainter/tst_qpainter.cpp
index 2bb99f6a5f..c2606a6c6a 100644
--- a/tests/auto/gui/painting/qpainter/tst_qpainter.cpp
+++ b/tests/auto/gui/painting/qpainter/tst_qpainter.cpp
@@ -52,7 +52,7 @@
#include <qimage.h>
#include <qthread.h>
#include <limits.h>
-#if !defined(Q_OS_WINCE) && !defined(Q_OS_SYMBIAN)
+#if !defined(Q_OS_WINCE)
#include <qprinter.h>
#include <math.h>
#endif
@@ -72,10 +72,6 @@
#include <qlayout.h>
#include <qfontdatabase.h>
-#if defined(Q_OS_SYMBIAN)
-# define SRCDIR "."
-#endif
-
Q_DECLARE_METATYPE(QGradientStops)
Q_DECLARE_METATYPE(QLine)
Q_DECLARE_METATYPE(QRect)
@@ -565,7 +561,7 @@ void tst_QPainter::qt_format_text_boundingRect()
QCOMPARE(pbr, br);
}
#endif
-#if !defined(QT_NO_PRINTER) && !defined(Q_OS_WINCE) && !defined(Q_OS_SYMBIAN)
+#if !defined(QT_NO_PRINTER) && !defined(Q_OS_WINCE)
{
QPrinter printer(QPrinter::HighResolution);
if (printer.printerName().isEmpty()) {
@@ -1498,7 +1494,7 @@ void tst_QPainter::drawPath2()
void tst_QPainter::drawPath3()
{
-#if !defined(Q_OS_WINCE) && !defined(Q_OS_SYMBIAN)
+#if !defined(Q_OS_WINCE)
QImage imgA(400, 400, QImage::Format_RGB32);
#else
QImage imgA(100, 100, QImage::Format_RGB32);
@@ -2970,7 +2966,7 @@ void tst_QPainter::monoImages()
}
}
-#if !defined(Q_OS_IRIX) && !defined(Q_OS_AIX) && !defined(Q_CC_MSVC) && !defined(Q_OS_SOLARIS) && !defined(Q_OS_SYMBIAN)
+#if !defined(Q_OS_IRIX) && !defined(Q_OS_AIX) && !defined(Q_CC_MSVC) && !defined(Q_OS_SOLARIS)
#include <fenv.h>
static const QString fpeExceptionString(int exception)
diff --git a/tests/auto/gui/painting/qpathclipper/qpathclipper.pro b/tests/auto/gui/painting/qpathclipper/qpathclipper.pro
index aead7007f0..319dcb3981 100644
--- a/tests/auto/gui/painting/qpathclipper/qpathclipper.pro
+++ b/tests/auto/gui/painting/qpathclipper/qpathclipper.pro
@@ -6,4 +6,4 @@ QT += gui-private
requires(contains(QT_CONFIG,private_tests))
-unix:!mac:!symbian:LIBS+=-lm
+unix:!mac:LIBS+=-lm
diff --git a/tests/auto/gui/painting/qpolygon/qpolygon.pro b/tests/auto/gui/painting/qpolygon/qpolygon.pro
index 186b704d17..1d5702821c 100644
--- a/tests/auto/gui/painting/qpolygon/qpolygon.pro
+++ b/tests/auto/gui/painting/qpolygon/qpolygon.pro
@@ -2,6 +2,6 @@ load(qttest_p4)
QT += widgets
SOURCES += tst_qpolygon.cpp
-unix:!mac:!symbian:LIBS+=-lm
+unix:!mac:LIBS+=-lm
diff --git a/tests/auto/gui/painting/qtransform/qtransform.pro b/tests/auto/gui/painting/qtransform/qtransform.pro
index 92bef8ce38..7cba3dbb52 100644
--- a/tests/auto/gui/painting/qtransform/qtransform.pro
+++ b/tests/auto/gui/painting/qtransform/qtransform.pro
@@ -2,6 +2,6 @@ load(qttest_p4)
HEADERS +=
SOURCES += tst_qtransform.cpp
-unix:!mac:!symbian:LIBS+=-lm
+unix:!mac:LIBS+=-lm
diff --git a/tests/auto/gui/painting/qwmatrix/qwmatrix.pro b/tests/auto/gui/painting/qwmatrix/qwmatrix.pro
index bab298bc93..8c6a96794c 100644
--- a/tests/auto/gui/painting/qwmatrix/qwmatrix.pro
+++ b/tests/auto/gui/painting/qwmatrix/qwmatrix.pro
@@ -1,6 +1,5 @@
load(qttest_p4)
SOURCES += tst_qwmatrix.cpp
-unix:!mac:!symbian:LIBS+=-lm
-
+unix:!mac:LIBS+=-lm
diff --git a/tests/auto/gui/text/qcssparser/qcssparser.pro b/tests/auto/gui/text/qcssparser/qcssparser.pro
index 16fa265231..14070a5215 100644
--- a/tests/auto/gui/text/qcssparser/qcssparser.pro
+++ b/tests/auto/gui/text/qcssparser/qcssparser.pro
@@ -3,11 +3,9 @@ SOURCES += tst_qcssparser.cpp
QT += xml gui-private
requires(contains(QT_CONFIG,private_tests))
-!symbian: {
- DEFINES += SRCDIR=\\\"$$PWD\\\"
-}
+DEFINES += SRCDIR=\\\"$$PWD\\\"
-wince*|symbian: {
+wince* {
addFiles.files = testdata
addFiles.path = .
timesFont.files = C:/Windows/Fonts/times.ttf
diff --git a/tests/auto/gui/text/qcssparser/tst_qcssparser.cpp b/tests/auto/gui/text/qcssparser/tst_qcssparser.cpp
index f2ff30f591..4e8085811d 100644
--- a/tests/auto/gui/text/qcssparser/tst_qcssparser.cpp
+++ b/tests/auto/gui/text/qcssparser/tst_qcssparser.cpp
@@ -133,7 +133,7 @@ void tst_QCssParser::scanner_data()
QTest::addColumn<QString>("input");
QTest::addColumn<QString>("output");
-#if !defined(Q_OS_IRIX) && !defined(Q_OS_WINCE) && !defined(Q_OS_SYMBIAN)
+#if !defined(Q_OS_IRIX) && !defined(Q_OS_WINCE)
QDir d(SRCDIR);
#else
QDir d(QDir::current());
diff --git a/tests/auto/gui/text/qfontdatabase/qfontdatabase.pro b/tests/auto/gui/text/qfontdatabase/qfontdatabase.pro
index e7dfc3c73d..4abff18412 100644
--- a/tests/auto/gui/text/qfontdatabase/qfontdatabase.pro
+++ b/tests/auto/gui/text/qfontdatabase/qfontdatabase.pro
@@ -1,8 +1,8 @@
load(qttest_p4)
SOURCES += tst_qfontdatabase.cpp
-!symbian:DEFINES += SRCDIR=\\\"$$PWD\\\"
+DEFINES += SRCDIR=\\\"$$PWD\\\"
-wince*|symbian {
+wince* {
additionalFiles.files = FreeMono.ttf
additionalFiles.path = .
DEPLOYMENT += additionalFiles
diff --git a/tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp b/tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp
index 7914ecb00c..052b4d4bd0 100644
--- a/tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp
+++ b/tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp
@@ -39,18 +39,12 @@
**
****************************************************************************/
-
#include <QtTest/QtTest>
-
#include <qfontdatabase.h>
#include <qfontinfo.h>
#include <qfontmetrics.h>
-#ifdef Q_OS_SYMBIAN
-#define SRCDIR "."
-#endif
-
//TESTED_CLASS=
//TESTED_FILES=
diff --git a/tests/auto/gui/text/qglyphrun/qglyphrun.pro b/tests/auto/gui/text/qglyphrun/qglyphrun.pro
index 480ad5b9a4..9d3c6253e0 100644
--- a/tests/auto/gui/text/qglyphrun/qglyphrun.pro
+++ b/tests/auto/gui/text/qglyphrun/qglyphrun.pro
@@ -4,7 +4,7 @@ QT = core gui
SOURCES += \
tst_qglyphrun.cpp
-wince*|symbian*: {
+wince* {
DEFINES += SRCDIR=\\\"\\\"
} else {
DEFINES += SRCDIR=\\\"$$PWD/\\\"
diff --git a/tests/auto/gui/text/qrawfont/qrawfont.pro b/tests/auto/gui/text/qrawfont/qrawfont.pro
index 1c08299699..3bb3dcee40 100644
--- a/tests/auto/gui/text/qrawfont/qrawfont.pro
+++ b/tests/auto/gui/text/qrawfont/qrawfont.pro
@@ -7,7 +7,7 @@ SOURCES += \
INCLUDEPATH += $$QT_SOURCE_TREE/src/3rdparty/harfbuzz/src
-wince*|symbian*: {
+wince* {
DEFINES += SRCDIR=\\\"\\\"
} else {
DEFINES += SRCDIR=\\\"$$PWD/\\\"
diff --git a/tests/auto/gui/text/qtextlayout/qtextlayout.pro b/tests/auto/gui/text/qtextlayout/qtextlayout.pro
index 222e69b804..4498ec02a1 100644
--- a/tests/auto/gui/text/qtextlayout/qtextlayout.pro
+++ b/tests/auto/gui/text/qtextlayout/qtextlayout.pro
@@ -4,8 +4,3 @@ HEADERS +=
SOURCES += tst_qtextlayout.cpp
DEFINES += QT_COMPILES_IN_HARFBUZZ
INCLUDEPATH += $$QT_SOURCE_TREE/src/3rdparty/harfbuzz/src
-
-symbian {
- TARGET.EPOCHEAPSIZE = 100000 20000000
-}
-
diff --git a/tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro b/tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro
index 25bb5a5ed0..32913a9c17 100644
--- a/tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro
+++ b/tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro
@@ -2,5 +2,4 @@ load(qttest_p4)
QT += core-private gui-private
SOURCES += tst_qtextodfwriter.cpp
-!symbian:DEFINES += SRCDIR=\\\"$$PWD\\\"
-symbian:INCLUDEPATH+=$$[QT_INSTALL_PREFIX]/include/QtGui/private
+DEFINES += SRCDIR=\\\"$$PWD\\\"
diff --git a/tests/auto/gui/text/qtextodfwriter/tst_qtextodfwriter.cpp b/tests/auto/gui/text/qtextodfwriter/tst_qtextodfwriter.cpp
index 765afce66e..01abf636c9 100644
--- a/tests/auto/gui/text/qtextodfwriter/tst_qtextodfwriter.cpp
+++ b/tests/auto/gui/text/qtextodfwriter/tst_qtextodfwriter.cpp
@@ -38,6 +38,7 @@
** $QT_END_LICENSE$
**
****************************************************************************/
+
#include <QtTest/QtTest>
#include <QTextDocument>
#include <QTextCursor>
@@ -47,10 +48,6 @@
#include <QBuffer>
#include <QDebug>
-#ifdef Q_OS_SYMBIAN
-#define SRCDIR "."
-#endif
-
#include <private/qtextodfwriter_p.h>
class tst_QTextOdfWriter : public QObject
diff --git a/tests/auto/gui/text/qzip/qzip.pro b/tests/auto/gui/text/qzip/qzip.pro
index 7631a3e93a..221971c560 100644
--- a/tests/auto/gui/text/qzip/qzip.pro
+++ b/tests/auto/gui/text/qzip/qzip.pro
@@ -2,11 +2,11 @@ load(qttest_p4)
QT += gui-private
SOURCES += tst_qzip.cpp
-wince*|symbian: {
+wince* {
addFiles.files = testdata
addFiles.path = .
DEPLOYMENT += addFiles
- !symbian:DEFINES += SRCDIR=\\\".\\\"
+ DEFINES += SRCDIR=\\\".\\\"
} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
}
diff --git a/tests/auto/gui/text/qzip/tst_qzip.cpp b/tests/auto/gui/text/qzip/tst_qzip.cpp
index 0955ac069f..7d7f412648 100644
--- a/tests/auto/gui/text/qzip/tst_qzip.cpp
+++ b/tests/auto/gui/text/qzip/tst_qzip.cpp
@@ -44,10 +44,6 @@
#include <private/qzipwriter_p.h>
#include <private/qzipreader_p.h>
-#ifdef Q_OS_SYMBIAN
-#define SRCDIR "."
-#endif
-
class tst_QZip : public QObject
{
Q_OBJECT
diff --git a/tests/auto/gui/util/qdesktopservices/qdesktopservices.pro b/tests/auto/gui/util/qdesktopservices/qdesktopservices.pro
index 0e51ed0459..3014298239 100644
--- a/tests/auto/gui/util/qdesktopservices/qdesktopservices.pro
+++ b/tests/auto/gui/util/qdesktopservices/qdesktopservices.pro
@@ -3,28 +3,4 @@ QT += widgets
SOURCES += tst_qdesktopservices.cpp
TARGET = tst_qdesktopservices
-symbian: {
- dummy.files = text\\testfile.txt
- dummy.path = .
-
- text.files = text\\*
- text.path = \\data\\others
-
- image.files = image\\*
- image.path = \\data\\images
-
- audio.files = audio\\*
- audio.path = \\data\\sounds
-
- video.files = video\\*
- video.path = \\data\\videos
-
- install.files = install\\*
- install.path = \\data\\installs
-
- DEPLOYMENT += image audio video install
-
- # These are only needed for manual tests
- #DEPLOYMENT += dummy text
- }
diff --git a/tests/auto/gui/util/qdesktopservices/tst_qdesktopservices.cpp b/tests/auto/gui/util/qdesktopservices/tst_qdesktopservices.cpp
index 8bea0a245b..270674d31f 100644
--- a/tests/auto/gui/util/qdesktopservices/tst_qdesktopservices.cpp
+++ b/tests/auto/gui/util/qdesktopservices/tst_qdesktopservices.cpp
@@ -45,12 +45,12 @@
#include <qdebug.h>
#include <qdesktopservices.h>
-//#define RUN_MANUAL_TESTS
//TESTED_CLASS=
//TESTED_FILES=
-class tst_qdesktopservices : public QObject {
- Q_OBJECT
+class tst_qdesktopservices : public QObject
+{
+ Q_OBJECT
public:
tst_qdesktopservices();
@@ -60,26 +60,12 @@ private slots:
void init();
void cleanup();
void openUrl();
-#ifdef Q_OS_SYMBIAN
- // These test are manual ones, you need to check from device that
- // correct system application is started with correct content
- // When you want to run these test, uncomment //#define RUN_MANUAL_TESTS
- void openHttpUrl_data();
- void openHttpUrl();
- void openMailtoUrl_data();
- void openMailtoUrl();
- void openFileUrl_data();
- void openFileUrl();
- void openMultipleFileUrls();
-#endif
void handlers();
void storageLocation_data();
void storageLocation();
void storageLocationDoesNotEndWithSlash_data();
void storageLocationDoesNotEndWithSlash();
-
-protected:
};
tst_qdesktopservices::tst_qdesktopservices()
@@ -110,154 +96,6 @@ void tst_qdesktopservices::openUrl()
#endif
}
-#ifdef Q_OS_SYMBIAN
-void tst_qdesktopservices::openHttpUrl_data()
-{
- QTest::addColumn<QUrl>("url");
- QTest::addColumn<bool>("result");
- QTest::newRow("BasicWithHttp") << QUrl("http://www.google.fi") << true;
- QTest::newRow("BasicWithoutHttp") << QUrl("www.nokia.fi") << true;
- QTest::newRow("BasicWithUserAndPw") << QUrl("http://s60prereleases:oslofjord@pepper.troll.no/s60prereleases/patches/") << true;
- QTest::newRow("URL with space") << QUrl("http://www.manataka.org/Contents Page.html") << true;
-
-}
-
-void tst_qdesktopservices::openHttpUrl()
-{
-#ifndef RUN_MANUAL_TESTS
- QSKIP("Test disabled -- only for manual purposes", SkipAll);
-#endif
-
- QFETCH(QUrl, url);
- QFETCH(bool, result);
- QCOMPARE(QDesktopServices::openUrl(url), result);
- QTest::qWait(30000);
-}
-
-void tst_qdesktopservices::openMailtoUrl_data()
-{
- QTest::addColumn<QUrl>("url");
- QTest::addColumn<bool>("result");
-
- // http://en.wikipedia.org/wiki/E-mail_address
- // RFC Valid e-mail addresses
- QTest::newRow("Wiki valid email 1") << QUrl("mailto:abc@example.com") << true;
- QTest::newRow("Wiki valid email 2") << QUrl("mailto:Abc@example.com") << true;
- QTest::newRow("Wiki valid email 3") << QUrl("mailto:aBC@example.com") << true;
- QTest::newRow("Wiki valid email 4") << QUrl("mailto:abc.123@example.com") << true;
- QTest::newRow("Wiki valid email 5") << QUrl("mailto:1234567890@example.com") << true;
- QTest::newRow("Wiki valid email 6") << QUrl("mailto:_______@example.com") << true;
- QTest::newRow("Wiki valid email 7") << QUrl("mailto:abc+mailbox/department=shipping@example.com") << true;
- // S60 email client considers the next URL invalid, even ity should be valid
- QTest::newRow("Wiki valid email 8") << QUrl("mailto:!#$%&'*+-/=?^_`.{|}~@example.com") << true; // all of these characters are allowed
- QTest::newRow("Wiki valid email 9") << QUrl("mailto:\"abc@def\"@example.com") << true; // anything goes inside quotation marks
- QTest::newRow("Wiki valid email 10") << QUrl("mailto:\"Fred \\\"quota\\\" Bloggs\"@example.com") << true; // however, quotes need escaping
-
- // RFC invalid e-mail addresses
- // These return true even though they are invalid, but check that user is notified about invalid URL in mail application
- QTest::newRow("Wiki invalid email 1") << QUrl("mailto:Abc.example.com") << true; // character @ is missing
- QTest::newRow("Wiki invalid email 2") << QUrl("mailto:Abc.@example.com") << true; // character dot(.) is last in local part
- QTest::newRow("Wiki invalid email 3") << QUrl("mailto:Abc..123@example.com") << true; // character dot(.) is double
- QTest::newRow("Wiki invalid email 4") << QUrl("mailto:A@b@c@example.com") << true; // only one @ is allowed outside quotations marks
- QTest::newRow("Wiki invalid email 5") << QUrl("mailto:()[]\\;:,<>@example.com") << true; // none of the characters before the @ is allowed outside quotation marks
-
- QTest::newRow("Basic") << QUrl("mailto:test@nokia.com") << true;
- QTest::newRow("BasicSeveralAddr") << QUrl("mailto:test@nokia.com,test2@nokia.com,test3@nokia.com") << true;
- QTest::newRow("BasicAndSubject") << QUrl("mailto:test@nokia.com?subject=hello nokia") << true;
- QTest::newRow("BasicAndTo") << QUrl("mailto:test@nokia.com?to=test2@nokia.com") << true;
-
- QTest::newRow("BasicAndCc") << QUrl("mailto:test@nokia.com?cc=mycc@address.com") << true;
- QTest::newRow("BasicAndBcc") << QUrl("mailto:test@nokia.com?bcc=mybcc@address.com") << true;
- QTest::newRow("BasicAndBody") << QUrl("mailto:test@nokia.com?body=Test email message body") << true;
-
- // RFC examples, these are actually invalid because there is not host defined
- // Check that user is notified about invalid URL in mail application
- QTest::newRow("RFC2368 Example 1") << QUrl::fromEncoded("mailto:addr1%2C%20addr2") << true;
- QTest::newRow("RFC2368 Example 2") << QUrl::fromEncoded("mailto:?to=addr1%2C%20addr2") << true;
- QTest::newRow("RFC2368 Example 3") << QUrl("mailto:addr1?to=addr2") << true;
-
- QTest::newRow("RFC2368 Example 4") << QUrl("mailto:joe@example.com?cc=bob@example.com&body=hello") << true;
- QTest::newRow("RFC2368 Example 5") << QUrl("mailto:?to=joe@example.com&cc=bob@example.com&body=hello") << true;
- QTest::newRow("RFC2368 Example 6") << QUrl("mailto:foobar@example.com?In-Reply-To=%3c3469A91.D10AF4C@example.com") << true; // OpaqueData
- QTest::newRow("RFC2368 Example 7") << QUrl::fromEncoded("mailto:infobot@example.com?body=send%20current-issue%0D%0Asend%20index") << true;
- QTest::newRow("RFC2368 Example 8") << QUrl::fromEncoded("mailto:infobot@example.com?body=send%20current-issue") << true;
- QTest::newRow("RFC2368 Example 9") << QUrl("mailto:infobot@example.com?subject=current-issue") << true;
- QTest::newRow("RFC2368 Example 10") << QUrl("mailto:chris@example.com") << true;
-
- //QTest::newRow("RFC2368 Example 11 - illegal chars") << QUrl("mailto:joe@example.com?cc=bob@example.com?body=hello") << false;
- QTest::newRow("RFC2368 Example 12") << QUrl::fromEncoded("mailto:gorby%25kremvax@example.com") << true; // encoded reserved chars '%'
- QTest::newRow("RFC2368 Example 13") << QUrl::fromEncoded("mailto:unlikely%3Faddress@example.com?blat=foop") << true; // encoded reserved chars `?'
-}
-
-void tst_qdesktopservices::openMailtoUrl()
-{
-#ifndef RUN_MANUAL_TESTS
- QSKIP("Test disabled -- only for manual purposes", SkipAll);
-#endif
-
- QFETCH(QUrl, url);
- QFETCH(bool, result);
- QCOMPARE(QDesktopServices::openUrl(url), result);
- QTest::qWait(5000);
-}
-
-void tst_qdesktopservices::openFileUrl_data()
-{
- QTest::addColumn<QUrl>("url");
- QTest::addColumn<bool>("result");
-
- // Text files
- QTest::newRow("DOS text file") << QUrl("file:///c:/data/others/dosfile.txt") << true;
- QTest::newRow("No EOF text file") << QUrl("file:///c:/data/others/noendofline.txt") << true;
- QTest::newRow("text file") << QUrl("file:///c:/data/others/testfile.txt") << true;
- QTest::newRow("text file with space") << QUrl("file:///c:/data/others/test file.txt") << true;
-
- // Images
- QTest::newRow("BMP image") << QUrl("file:///c:/data/images/image.bmp") << true;
- QTest::newRow("GIF image") << QUrl("file:///c:/data/images/image.gif") << true;
- QTest::newRow("JPG image") << QUrl("file:///c:/data/images/image.jpg") << true;
- QTest::newRow("PNG image") << QUrl("file:///c:/data/images/image.png") << true;
-
- // Audio
- QTest::newRow("MP4 audio") << QUrl("file:///c:/data/sounds/aac-only.mp4") << true;
- QTest::newRow("3GP audio") << QUrl("file:///c:/data/sounds/audio_3gpp.3gp") << true;
-
- // Video
- QTest::newRow("MP4 video") << QUrl("file:///c:/data/videos/vid-mpeg4-22k.mp4") << true;
-
- // Installs
- QTest::newRow("SISX") << QUrl("file:///c:/data/installs/ErrRd.sisx") << true;
-
- // Errors
- QTest::newRow("File does not exist") << QUrl("file:///c:/thisfileneverexists.txt") << false;
-}
-
-void tst_qdesktopservices::openFileUrl()
-{
-#ifndef RUN_MANUAL_TESTS
- QSKIP("Test disabled -- only for manual purposes", SkipAll);
-#endif
-
- QFETCH(QUrl, url);
- QFETCH(bool, result);
- QCOMPARE(QDesktopServices::openUrl(url), result);
- QTest::qWait(5000);
-}
-
-void tst_qdesktopservices::openMultipleFileUrls()
-{
-#ifndef RUN_MANUAL_TESTS
- QSKIP("Test disabled -- only for manual purposes", SkipAll);
-#endif
-
- QCOMPARE(QDesktopServices::openUrl(QUrl("file:///c:/data/images/image.bmp")), true);
- QCOMPARE(QDesktopServices::openUrl(QUrl("file:///c:/data/images/image.png")), true);
- QCOMPARE(QDesktopServices::openUrl(QUrl("file:///c:/data/others/noendofline.txt")), true);
- QCOMPARE(QDesktopServices::openUrl(QUrl("file:///c:/data/installs/ErrRd.sisx")), true);
-}
-#endif
-
-
class MyUrlHandler : public QObject
{
Q_OBJECT
@@ -307,67 +145,10 @@ void tst_qdesktopservices::storageLocation_data()
void tst_qdesktopservices::storageLocation()
{
QFETCH(QDesktopServices::StandardLocation, location);
-#ifdef Q_OS_SYMBIAN
- QString storageLocation = QDesktopServices::storageLocation(location);
- QString displayName = QDesktopServices::displayName(location);
- //qDebug( "displayName: %s", displayName );
-
- storageLocation = storageLocation.toLower();
- displayName = displayName.toLower();
-
- QString drive = QDir::currentPath().left(2).toLower();
- if( drive == "z:" )
- drive = "c:";
-
- switch(location) {
- case QDesktopServices::DesktopLocation:
- QCOMPARE( storageLocation, drive + QString("/data") );
- break;
- case QDesktopServices::DocumentsLocation:
- QCOMPARE( storageLocation, drive + QString("/data") );
- break;
- case QDesktopServices::FontsLocation:
- // Currently point always to ROM
- QCOMPARE( storageLocation, QString("z:/resource/fonts") );
- break;
- case QDesktopServices::ApplicationsLocation:
-#ifdef Q_CC_NOKIAX86
- QCOMPARE( storageLocation, QString("z:/sys/bin") );
-#else
- QCOMPARE( storageLocation, drive + QString("/sys/bin") );
-#endif
- break;
- case QDesktopServices::MusicLocation:
- QCOMPARE( storageLocation, drive + QString("/data/sounds") );
- break;
- case QDesktopServices::MoviesLocation:
- QCOMPARE( storageLocation, drive + QString("/data/videos") );
- break;
- case QDesktopServices::PicturesLocation:
- QCOMPARE( storageLocation, drive + QString("/data/images") );
- break;
- case QDesktopServices::TempLocation:
- QCOMPARE( storageLocation, QDir::tempPath().toLower());
- break;
- case QDesktopServices::HomeLocation:
- QCOMPARE( storageLocation, QDir::homePath().toLower());
- break;
- case QDesktopServices::DataLocation:
- // Just check the folder not the drive
- QCOMPARE( storageLocation.mid(2), QDir::currentPath().mid(2).toLower());
- break;
- default:
- QCOMPARE( storageLocation, QString() );
- break;
- }
-
-#else
QDesktopServices::storageLocation(location);
QDesktopServices::displayName(location);
-#endif
}
-
void tst_qdesktopservices::storageLocationDoesNotEndWithSlash_data()
{
storageLocation_data();