summaryrefslogtreecommitdiffstats
path: root/tests/manual
diff options
context:
space:
mode:
authorAxel Waggershauser <awagger@gmail.com>2013-03-15 00:42:15 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-03-16 20:22:50 +0100
commitb11317a64339f5a4bcffc8234ecaf15c7fb416f2 (patch)
treef81e40ee49f5109b4100048d131d5bb922b448aa /tests/manual
parent72367a94a750355eb748793ce8c365373a332c9c (diff)
Whitespace cleanup: remove trailing whitespace
Remove all trailing whitespace from the following list of files: *.cpp *.h *.conf *.qdoc *.pro *.pri *.mm *.rc *.pl *.qps *.xpm *.txt *README excluding 3rdparty, test-data and auto generated code. Note A): the only non 3rdparty c++-files that still have trailing whitespace after this change are: * src/corelib/codecs/cp949codetbl_p.h * src/corelib/codecs/qjpunicode.cpp * src/corelib/codecs/qbig5codec.cpp * src/corelib/xml/qxmlstream_p.h * src/tools/qdoc/qmlparser/qqmljsgrammar.cpp * src/tools/uic/ui4.cpp * tests/auto/other/qtokenautomaton/tokenizers/* * tests/benchmarks/corelib/tools/qstring/data.cpp * util/lexgen/tokenizer.cpp Note B): in about 30 files some overlapping 'leading tab' and 'TAB character in non-leading whitespace' issues have been fixed to make the sanity bot happy. Plus some general ws-fixes here and there as asked for during review. Change-Id: Ia713113c34d82442d6ce4d93d8b1cf545075d11d Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Diffstat (limited to 'tests/manual')
-rw-r--r--tests/manual/bearerex/bearerex.cpp42
-rw-r--r--tests/manual/bearerex/bearerex.h8
-rw-r--r--tests/manual/bearerex/xqlistwidget.cpp4
-rw-r--r--tests/manual/bearerex/xqlistwidget.h4
-rw-r--r--tests/manual/inputmethodhints/inputmethodhints.h2
-rw-r--r--tests/manual/qcursor/grab_override/mainwindow.h4
-rw-r--r--tests/manual/qtouchevent/touchwidget.cpp2
-rw-r--r--tests/manual/repaint/mainwindow/main.cpp10
-rw-r--r--tests/manual/repaint/scrollarea/main.cpp4
-rw-r--r--tests/manual/repaint/splitter/main.cpp2
-rw-r--r--tests/manual/repaint/tableview/main.cpp5
-rw-r--r--tests/manual/repaint/task141091/main.cpp11
-rw-r--r--tests/manual/repaint/widget/main.cpp8
13 files changed, 52 insertions, 54 deletions
diff --git a/tests/manual/bearerex/bearerex.cpp b/tests/manual/bearerex/bearerex.cpp
index 4417253930..185dbe123e 100644
--- a/tests/manual/bearerex/bearerex.cpp
+++ b/tests/manual/bearerex/bearerex.cpp
@@ -49,9 +49,9 @@ BearerEx::BearerEx(QWidget* parent)
: QMainWindow(parent)
{
setupUi(this);
-
+
createMenus();
-
+
connect(&m_NetworkConfigurationManager, SIGNAL(updateCompleted()), this, SLOT(configurationsUpdateCompleted()));
connect(&m_NetworkConfigurationManager, SIGNAL(configurationAdded(QNetworkConfiguration)),
this, SLOT(configurationAdded(QNetworkConfiguration)));
@@ -79,19 +79,19 @@ void BearerEx::showConfigurations()
{
listWidget->clear();
QListWidgetItem* listItem;
-
+
QNetworkConfiguration defaultConfig = m_NetworkConfigurationManager.defaultConfiguration();
if (defaultConfig.type() == QNetworkConfiguration::UserChoice) {
listItem = new QListWidgetItem();
QFont font = listItem->font();
font.setBold(true);
font.setUnderline(true);
- listItem->setFont(font);
+ listItem->setFont(font);
listItem->setText(" UserChoice");
listItem->setData(Qt::UserRole, QVariant::fromValue(defaultConfig));
listWidget->addItem(listItem);
}
-
+
QList<QNetworkConfiguration> configurations = m_NetworkConfigurationManager.allConfigurations();
for (int i=0; i<configurations.count(); i++)
{
@@ -102,7 +102,7 @@ void BearerEx::showConfigurations()
} else if (configurations[i].type() == QNetworkConfiguration::ServiceNetwork) {
text.append("(SNAP,");
}
-
+
if ((configurations[i].state() & QNetworkConfiguration::Active) == QNetworkConfiguration::Active) {
text.append("Act) ");
} else if ((configurations[i].state() & QNetworkConfiguration::Discovered) == QNetworkConfiguration::Discovered) {
@@ -111,12 +111,12 @@ void BearerEx::showConfigurations()
text.append("Def) ");
}
text.append(configurations[i].name());
-
+
if (defaultConfig.isValid() && defaultConfig == configurations[i]) {
QFont font = listItem->font();
font.setBold(true);
font.setUnderline(true);
- listItem->setFont(font);
+ listItem->setFont(font);
}
listItem->setText(text);
listItem->setData(Qt::UserRole, QVariant::fromValue(configurations[i]));
@@ -151,7 +151,7 @@ void BearerEx::on_createSessionButton_clicked()
QListWidgetItem* item = listWidget->currentItem();
if (!item) {
return;
- }
+ }
QNetworkConfiguration networkConfiguration = qvariant_cast<QNetworkConfiguration>(item->data(Qt::UserRole));
int newTabIndex = mainTabWidget->count();
SessionTab* newTab = new SessionTab(&networkConfiguration,&m_NetworkConfigurationManager,eventListWidget,newTabIndex-1);
@@ -184,7 +184,7 @@ void BearerEx::onlineStateChanged(bool isOnline)
QListWidgetItem* listItem = new QListWidgetItem();
QFont font = listItem->font();
font.setBold(true);
- listItem->setFont(font);
+ listItem->setFont(font);
if (isOnline) {
listItem->setText(QString("> Online"));
} else {
@@ -231,7 +231,7 @@ DetailedInfoDialog::DetailedInfoDialog(QNetworkConfiguration* apNetworkConfigura
tableWidget->setColumnCount(2);
int rowCount = 2;
-
+
if (apNetworkConfiguration->type() == QNetworkConfiguration::ServiceNetwork) {
rowCount = rowCount + apNetworkConfiguration->children().count();
}
@@ -274,7 +274,7 @@ SessionTab::SessionTab(QNetworkConfiguration* apNetworkConfiguration,
connect(m_NetworkSession, SIGNAL(opened()), this, SLOT(opened()));
connect(m_NetworkSession, SIGNAL(closed()), this, SLOT(closed()));
connect(m_NetworkSession, SIGNAL(error(QNetworkSession::SessionError)), this, SLOT(error(QNetworkSession::SessionError)));
-
+
if (apNetworkConfiguration->type() == QNetworkConfiguration::InternetAccessPoint) {
snapLabel->hide();
snapLineEdit->hide();
@@ -342,7 +342,7 @@ void SessionTab::on_openSessionButton_clicked()
{
m_NetworkSession->open();
if (m_NetworkSession->isOpen()) {
- newState(m_NetworkSession->state());
+ newState(m_NetworkSession->state());
}
}
@@ -350,7 +350,7 @@ void SessionTab::on_closeSessionButton_clicked()
{
m_NetworkSession->close();
if (!m_NetworkSession->isOpen()) {
- newState(m_NetworkSession->state());
+ newState(m_NetworkSession->state());
}
}
@@ -414,10 +414,10 @@ void SessionTab::opened()
QListWidgetItem* listItem = new QListWidgetItem();
QFont font = listItem->font();
font.setBold(true);
- listItem->setFont(font);
+ listItem->setFont(font);
listItem->setText(QString("S")+QString::number(m_index)+QString(" - ")+QString("Opened"));
m_eventListWidget->addItem(listItem);
-
+
QVariant identifier = m_NetworkSession->sessionProperty("ActiveConfiguration");
if (!identifier.isNull()) {
QString configId = identifier.toString();
@@ -445,7 +445,7 @@ void SessionTab::closed()
QListWidgetItem* listItem = new QListWidgetItem();
QFont font = listItem->font();
font.setBold(true);
- listItem->setFont(font);
+ listItem->setFont(font);
listItem->setText(QString("S")+QString::number(m_index)+QString(" - ")+QString("Closed"));
m_eventListWidget->addItem(listItem);
}
@@ -492,10 +492,10 @@ void SessionTab::on_dataObjectChanged(const QString &newObjectType)
}
-void SessionTab::stateChanged(QNetworkSession::State state)
+void SessionTab::stateChanged(QNetworkSession::State state)
{
newState(state);
-
+
QListWidgetItem* listItem = new QListWidgetItem();
listItem->setText(QString("S")+QString::number(m_index)+QString(" - ")+stateString(state));
m_eventListWidget->addItem(listItem);
@@ -527,7 +527,7 @@ void SessionTab::error(QNetworkSession::SessionError error)
QListWidgetItem* listItem = new QListWidgetItem();
QMessageBox msgBox;
msgBox.setStandardButtons(QMessageBox::Close);
-
+
QString errorString;
switch (error)
{
@@ -549,7 +549,7 @@ void SessionTab::error(QNetworkSession::SessionError error)
}
listItem->setText(QString("S")+QString::number(m_index)+QString(" - ")+errorString);
m_eventListWidget->addItem(listItem);
-
+
msgBox.setText(errorString);
msgBox.exec();
}
diff --git a/tests/manual/bearerex/bearerex.h b/tests/manual/bearerex/bearerex.h
index 5ec2e17060..8de2b1d41d 100644
--- a/tests/manual/bearerex/bearerex.h
+++ b/tests/manual/bearerex/bearerex.h
@@ -88,7 +88,7 @@ private Q_SLOTS:
void configurationAdded(const QNetworkConfiguration& config);
void configurationRemoved(const QNetworkConfiguration& config);
void onlineStateChanged(bool isOnline);
- void configurationChanged(const QNetworkConfiguration & config);
+ void configurationChanged(const QNetworkConfiguration & config);
private:
QNetworkConfigurationManager m_NetworkConfigurationManager;
@@ -112,8 +112,8 @@ public:
SessionTab(QNetworkConfiguration* apNetworkConfiguration = 0, QNetworkConfigurationManager* configManager = 0,
QListWidget* eventListWidget = 0, int index = 0, BearerEx* parent = 0);
~SessionTab();
-
- QString stateString(QNetworkSession::State state);
+
+ QString stateString(QNetworkSession::State state);
private Q_SLOTS:
void on_createQNetworkAccessManagerButton_clicked();
@@ -125,7 +125,7 @@ private Q_SLOTS:
void on_dataObjectChanged(const QString& newObjectType);
void on_alrButton_clicked();
void finished(quint32 errorCode, qint64 dataReceived, QString errorType);
-
+
void newConfigurationActivated();
void preferredConfigurationChanged(const QNetworkConfiguration& config, bool isSeamless);
void stateChanged(QNetworkSession::State state);
diff --git a/tests/manual/bearerex/xqlistwidget.cpp b/tests/manual/bearerex/xqlistwidget.cpp
index 556d9e400f..cb03f6e9bf 100644
--- a/tests/manual/bearerex/xqlistwidget.cpp
+++ b/tests/manual/bearerex/xqlistwidget.cpp
@@ -42,7 +42,7 @@
#include "xqlistwidget.h"
XQListWidget::XQListWidget(QWidget* parent) : QListWidget(parent)
-{
+{
}
void XQListWidget::keyPressEvent(QKeyEvent* event)
@@ -59,7 +59,7 @@ void XQListWidget::keyPressEvent(QKeyEvent* event)
focusNextChild();
break;
}
- default:
+ default:
{
QListWidget::keyPressEvent(event);
}
diff --git a/tests/manual/bearerex/xqlistwidget.h b/tests/manual/bearerex/xqlistwidget.h
index b23dfb5735..80aecceb0b 100644
--- a/tests/manual/bearerex/xqlistwidget.h
+++ b/tests/manual/bearerex/xqlistwidget.h
@@ -48,8 +48,8 @@
class XQListWidget: public QListWidget
{
public:
- XQListWidget(QWidget* parent = 0);
-
+ XQListWidget(QWidget* parent = 0);
+
protected:
void keyPressEvent(QKeyEvent* event);
};
diff --git a/tests/manual/inputmethodhints/inputmethodhints.h b/tests/manual/inputmethodhints/inputmethodhints.h
index 09c6ca41f5..ce1724280f 100644
--- a/tests/manual/inputmethodhints/inputmethodhints.h
+++ b/tests/manual/inputmethodhints/inputmethodhints.h
@@ -52,7 +52,7 @@ class inputmethodhints : public QMainWindow
public:
inputmethodhints(QWidget *parent = 0);
~inputmethodhints();
-
+
public slots:
void checkboxChanged(int);
diff --git a/tests/manual/qcursor/grab_override/mainwindow.h b/tests/manual/qcursor/grab_override/mainwindow.h
index c105e22850..eaf4b95615 100644
--- a/tests/manual/qcursor/grab_override/mainwindow.h
+++ b/tests/manual/qcursor/grab_override/mainwindow.h
@@ -64,11 +64,11 @@ private slots:
private:
void keyPressEvent(QKeyEvent* event);
-
+
Ui::MainWindow *ui;
QTimer *timer;
int override;
-
+
QCursor ccurs;
QCursor bcurs;
};
diff --git a/tests/manual/qtouchevent/touchwidget.cpp b/tests/manual/qtouchevent/touchwidget.cpp
index 68206aad22..e2834203f7 100644
--- a/tests/manual/qtouchevent/touchwidget.cpp
+++ b/tests/manual/qtouchevent/touchwidget.cpp
@@ -122,7 +122,7 @@ bool TouchWidget::event(QEvent *event)
case QEvent::MouseButtonRelease:
seenMouseRelease = true;
if (closeWindowOnMouseRelease)
- window()->close();
+ window()->close();
if (acceptMouseRelease) {
event->accept();
return true;
diff --git a/tests/manual/repaint/mainwindow/main.cpp b/tests/manual/repaint/mainwindow/main.cpp
index 173f81de06..eb3096a59c 100644
--- a/tests/manual/repaint/mainwindow/main.cpp
+++ b/tests/manual/repaint/mainwindow/main.cpp
@@ -47,16 +47,16 @@ int main(int argc, char **argv)
QApplication app(argc, argv);
QMainWindow mainWindow;
-
+
mainWindow.setCentralWidget(new StaticWidget());
mainWindow.setStatusBar(new QStatusBar());
-
+
QDockWidget *dockWidget = new QDockWidget();
dockWidget->setWidget(new StaticWidget());
mainWindow.addDockWidget(Qt::LeftDockWidgetArea, dockWidget);
-
+
QToolBar *toolBar = new QToolBar();
-
+
toolBar->addWidget(new StaticWidget())->setVisible(true);;
toolBar->addWidget(new QSpinBox())->setVisible(true);;
@@ -64,6 +64,6 @@ int main(int argc, char **argv)
mainWindow.resize(600, 400);
mainWindow.show();
-
+
return app.exec();
}
diff --git a/tests/manual/repaint/scrollarea/main.cpp b/tests/manual/repaint/scrollarea/main.cpp
index 44b43c30f7..6102ab8ee8 100644
--- a/tests/manual/repaint/scrollarea/main.cpp
+++ b/tests/manual/repaint/scrollarea/main.cpp
@@ -42,7 +42,6 @@
#include <QtWidgets>
#include "../shared/shared.h"
-
int main(int argc, char **argv)
{
QApplication app(argc, argv);
@@ -57,8 +56,7 @@ int main(int argc, char **argv)
scrollView.resize(600, 400);
scrollView.show();
-
-
+
return app.exec();
}
diff --git a/tests/manual/repaint/splitter/main.cpp b/tests/manual/repaint/splitter/main.cpp
index 5ee1e19402..2c01053ae1 100644
--- a/tests/manual/repaint/splitter/main.cpp
+++ b/tests/manual/repaint/splitter/main.cpp
@@ -53,6 +53,6 @@ int main(int argc, char **argv)
splitter.resize(600, 400);
splitter.show();
-
+
return app.exec();
}
diff --git a/tests/manual/repaint/tableview/main.cpp b/tests/manual/repaint/tableview/main.cpp
index 442b1668e0..71f8209d6d 100644
--- a/tests/manual/repaint/tableview/main.cpp
+++ b/tests/manual/repaint/tableview/main.cpp
@@ -45,7 +45,7 @@
class CellWidget : public QWidget
{
public:
- CellWidget (QWidget *parent = 0) : QWidget(parent) { }
+ CellWidget(QWidget *parent = 0) : QWidget(parent) {}
void paintEvent(QPaintEvent * event)
{
static int value = 200;
@@ -69,8 +69,7 @@ int main(int argc, char **argv)
tableWidget.setCellWidget(row, col, new CellWidget());
tableWidget.resize(400, 600);
tableWidget.show();
-
-
+
return app.exec();
}
diff --git a/tests/manual/repaint/task141091/main.cpp b/tests/manual/repaint/task141091/main.cpp
index d2b0f76606..b5b6ae92d7 100644
--- a/tests/manual/repaint/task141091/main.cpp
+++ b/tests/manual/repaint/task141091/main.cpp
@@ -45,11 +45,12 @@
class MyWidget : public QWidget
{
public:
- MyWidget() : QWidget() {
-
-
+ MyWidget() : QWidget()
+ {
setAttribute(Qt::WA_OpaquePaintEvent);
- setAttribute(Qt::WA_StaticContents); }
+ setAttribute(Qt::WA_StaticContents);
+ }
+
protected:
void paintEvent(QPaintEvent *e) { qDebug() << e->rect(); }
};
@@ -60,4 +61,4 @@ int main(int argc, char **argv)
MyWidget w;
w.show();
return a.exec();
-} \ No newline at end of file
+}
diff --git a/tests/manual/repaint/widget/main.cpp b/tests/manual/repaint/widget/main.cpp
index 520b3e22f5..22011a160c 100644
--- a/tests/manual/repaint/widget/main.cpp
+++ b/tests/manual/repaint/widget/main.cpp
@@ -108,24 +108,24 @@ protected:
QPushButton * resizeButton;
QPushButton * movebutton;
QPushButton * moveResizebutton;
- QPushButton * scrollbutton;
+ QPushButton * scrollbutton;
};
int main(int argc, char **argv)
{
QApplication app(argc, argv);
-
+
TopLevel bc;
bc.resize(500, 500);
c = new Child(&bc);
c->move(100, 100);
c->resize(100, 100);
-
+
QWidget *gc = new StaticWidget(c);
gc->move(20, 20);
gc->resize(50,50);
-
+
bc.show();
return app.exec();