summaryrefslogtreecommitdiffstats
path: root/tests/auto/symbian
diff options
context:
space:
mode:
authorJanne Anttila <janne.anttila@digia.com>2009-08-04 11:02:56 (GMT)
committerJanne Anttila <janne.anttila@digia.com>2009-08-04 11:30:41 (GMT)
commitcd10d1a8dbb3b77c2d4e9c389e134b1f3cc3c2cf (patch)
tree39fa997e3391ffdcc24cdf96ea0c0b5b62391a99 /tests/auto/symbian
parent4b07c9d95087cc69956bfe309cd9b4eec26235ec (diff)
downloadQt-cd10d1a8dbb3b77c2d4e9c389e134b1f3cc3c2cf.zip
Qt-cd10d1a8dbb3b77c2d4e9c389e134b1f3cc3c2cf.tar.gz
Qt-cd10d1a8dbb3b77c2d4e9c389e134b1f3cc3c2cf.tar.bz2
Trailing whitespace and tab/space fixes for auto tests
Diffstat (limited to 'tests/auto/symbian')
-rw-r--r--tests/auto/symbian/orientationchange/orientationchange.pro4
-rw-r--r--tests/auto/symbian/orientationchange/tst_orientationchange.cpp36
-rw-r--r--tests/auto/symbian/qmainexceptions/qmainexceptions.pro4
-rw-r--r--tests/auto/symbian/qmainexceptions/tst_qmainexceptions.cpp8
4 files changed, 25 insertions, 27 deletions
diff --git a/tests/auto/symbian/orientationchange/orientationchange.pro b/tests/auto/symbian/orientationchange/orientationchange.pro
index d240fa1..08b34f9 100644
--- a/tests/auto/symbian/orientationchange/orientationchange.pro
+++ b/tests/auto/symbian/orientationchange/orientationchange.pro
@@ -1,7 +1,7 @@
load(qttest_p4)
-HEADERS +=
+HEADERS +=
SOURCES += tst_orientationchange.cpp
-symbian {
+symbian {
INCLUDEPATH += $$MW_LAYER_SYSTEMINCLUDE
}
diff --git a/tests/auto/symbian/orientationchange/tst_orientationchange.cpp b/tests/auto/symbian/orientationchange/tst_orientationchange.cpp
index 9d57ae1..ff371fa 100644
--- a/tests/auto/symbian/orientationchange/tst_orientationchange.cpp
+++ b/tests/auto/symbian/orientationchange/tst_orientationchange.cpp
@@ -61,11 +61,11 @@ class TestWidget : public QWidget
{
public:
TestWidget(QWidget *parent = 0);
-
+
void reset();
public:
void resizeEvent(QResizeEvent *event);
-
+
public:
QSize resizeEventSize;
int resizeEventCount;
@@ -86,58 +86,58 @@ void TestWidget::reset()
void TestWidget::resizeEvent(QResizeEvent *event)
{
QWidget::resizeEvent(event);
-
+
// Size delivered in first resize event is stored.
- if (!resizeEventCount)
+ if (!resizeEventCount)
resizeEventSize = event->size();
- resizeEventCount++;
+ resizeEventCount++;
}
void tst_orientationchange::resizeEventOnOrientationChange()
{
// This will test that when orientation 'changes', then
// at most one resize event is generated.
-
+
TestWidget *normalWidget = new TestWidget();
TestWidget *fullScreenWidget = new TestWidget();
TestWidget *maximizedWidget = new TestWidget();
-
+
fullScreenWidget->showFullScreen();
maximizedWidget->showMaximized();
normalWidget->show();
-
+
QCoreApplication::sendPostedEvents();
QCoreApplication::sendPostedEvents();
-
+
QCOMPARE(fullScreenWidget->resizeEventCount, 1);
QCOMPARE(fullScreenWidget->size(), fullScreenWidget->resizeEventSize);
QCOMPARE(maximizedWidget->resizeEventCount, 1);
QCOMPARE(maximizedWidget->size(), maximizedWidget->resizeEventSize);
QCOMPARE(normalWidget->resizeEventCount, 1);
QCOMPARE(normalWidget->size(), normalWidget->resizeEventSize);
-
+
fullScreenWidget->reset();
maximizedWidget->reset();
normalWidget->reset();
-
+
// Assumes that Qt application is AVKON application.
CAknAppUi *appUi = static_cast<CAknAppUi*>(CEikonEnv::Static()->EikAppUi());
-
+
// Determine 'opposite' orientation to the current orientation.
-
+
CAknAppUi::TAppUiOrientation orientation = CAknAppUi::EAppUiOrientationLandscape;
if (fullScreenWidget->size().width() > fullScreenWidget->size().height()) {
orientation = CAknAppUi::EAppUiOrientationPortrait;
}
-
+
TRAPD(err, appUi->SetOrientationL(orientation));
QCoreApplication::sendPostedEvents();
QCoreApplication::sendPostedEvents();
- // setOrientationL is not guaranteed to change orientation
- // (if emulator configured to support just portrait or landscape, then
+ // setOrientationL is not guaranteed to change orientation
+ // (if emulator configured to support just portrait or landscape, then
// setOrientationL call shouldn't do anything).
// So let's ensure that we do not get resize event twice.
@@ -150,9 +150,9 @@ void tst_orientationchange::resizeEventOnOrientationChange()
QCOMPARE(maximizedWidget->size(), maximizedWidget->resizeEventSize);
}
QCOMPARE(normalWidget->resizeEventCount, 0);
-
+
TRAP(err, appUi->SetOrientationL(CAknAppUi::EAppUiOrientationUnspecified));
-
+
delete normalWidget;
delete fullScreenWidget;
delete maximizedWidget;
diff --git a/tests/auto/symbian/qmainexceptions/qmainexceptions.pro b/tests/auto/symbian/qmainexceptions/qmainexceptions.pro
index 7533dd4..16111c1 100644
--- a/tests/auto/symbian/qmainexceptions/qmainexceptions.pro
+++ b/tests/auto/symbian/qmainexceptions/qmainexceptions.pro
@@ -1,5 +1,3 @@
load(qttest_p4)
-HEADERS +=
+HEADERS +=
SOURCES += tst_qmainexceptions.cpp
-
-
diff --git a/tests/auto/symbian/qmainexceptions/tst_qmainexceptions.cpp b/tests/auto/symbian/qmainexceptions/tst_qmainexceptions.cpp
index 1601b7e..bfe092b 100644
--- a/tests/auto/symbian/qmainexceptions/tst_qmainexceptions.cpp
+++ b/tests/auto/symbian/qmainexceptions/tst_qmainexceptions.cpp
@@ -423,7 +423,7 @@ void HybridFuncLX(THybridAction aAction)
void tst_qmainexceptions::testHybrid()
{
- TRAPD(error,
+ TRAPD(error,
QT_TRYCATCH_LEAVING(
HybridFuncLX(EHybridLeave);
) );
@@ -432,8 +432,8 @@ void tst_qmainexceptions::testHybrid()
QCOMPARE(int(sizeof(expected1)/sizeof(int)), int(recDtor - dtorFired));
for (int i=0; i<sizeof(expected1)/sizeof(int); i++)
QCOMPARE(expected1[i], dtorFired[i]);
-
- TRAP(error,
+
+ TRAP(error,
QT_TRYCATCH_LEAVING(
HybridFuncLX(EHybridThrow);
) );
@@ -443,7 +443,7 @@ void tst_qmainexceptions::testHybrid()
for (int i=0; i<sizeof(expected2)/sizeof(int); i++)
QCOMPARE(expected2[i], dtorFired[i]);
- TRAP(error,
+ TRAP(error,
QT_TRYCATCH_LEAVING(
HybridFuncLX(EHybridPass);
) );