From 7f992db892686fe4c260b0362d13b957af908692 Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Mon, 28 Aug 2017 12:57:24 +0200 Subject: Examples: Use canonical include style and sort #include See also https://wiki.qt.io/Writing_Qt_Examples Change-Id: Ife2300b9f1a074e9dc418d53f8c47138129b0cc7 Reviewed-by: Milian Wolff --- examples/webchannel/chatserver-cpp/chatserver.cpp | 4 ++-- examples/webchannel/chatserver-cpp/main.cpp | 4 ++-- examples/webchannel/shared/websocketclientwrapper.cpp | 2 +- examples/webchannel/shared/websockettransport.cpp | 5 ++--- examples/webchannel/shared/websockettransport.h | 2 +- examples/webchannel/standalone/main.cpp | 17 +++++++---------- 6 files changed, 15 insertions(+), 19 deletions(-) diff --git a/examples/webchannel/chatserver-cpp/chatserver.cpp b/examples/webchannel/chatserver-cpp/chatserver.cpp index beee713..1025c80 100644 --- a/examples/webchannel/chatserver-cpp/chatserver.cpp +++ b/examples/webchannel/chatserver-cpp/chatserver.cpp @@ -50,9 +50,9 @@ #include "chatserver.h" -#include -#include +#include #include +#include ChatServer::ChatServer(QObject *parent) : QObject(parent) diff --git a/examples/webchannel/chatserver-cpp/main.cpp b/examples/webchannel/chatserver-cpp/main.cpp index ea27e87..9e025ac 100644 --- a/examples/webchannel/chatserver-cpp/main.cpp +++ b/examples/webchannel/chatserver-cpp/main.cpp @@ -48,14 +48,14 @@ ** ****************************************************************************/ -#include "qwebchannel.h" #include "chatserver.h" #include "../shared/websocketclientwrapper.h" #include "../shared/websockettransport.h" -#include #include +#include +#include int main(int argc, char** argv) { diff --git a/examples/webchannel/shared/websocketclientwrapper.cpp b/examples/webchannel/shared/websocketclientwrapper.cpp index a69e56a..16be85e 100644 --- a/examples/webchannel/shared/websocketclientwrapper.cpp +++ b/examples/webchannel/shared/websocketclientwrapper.cpp @@ -51,7 +51,7 @@ #include "websocketclientwrapper.h" #include "websockettransport.h" -#include +#include /*! \brief Wraps connected QWebSockets clients in WebSocketTransport objects. diff --git a/examples/webchannel/shared/websockettransport.cpp b/examples/webchannel/shared/websockettransport.cpp index 4dbec39..e4ce50a 100644 --- a/examples/webchannel/shared/websockettransport.cpp +++ b/examples/webchannel/shared/websockettransport.cpp @@ -50,11 +50,10 @@ #include "websockettransport.h" +#include #include #include -#include - -#include +#include /*! \brief QWebChannelAbstractSocket implementation that uses a QWebSocket internally. diff --git a/examples/webchannel/shared/websockettransport.h b/examples/webchannel/shared/websockettransport.h index af645ab..252eaeb 100644 --- a/examples/webchannel/shared/websockettransport.h +++ b/examples/webchannel/shared/websockettransport.h @@ -51,7 +51,7 @@ #ifndef WEBSOCKETTRANSPORT_H #define WEBSOCKETTRANSPORT_H -#include +#include QT_BEGIN_NAMESPACE class QWebSocket; diff --git a/examples/webchannel/standalone/main.cpp b/examples/webchannel/standalone/main.cpp index f468652..736ee52 100644 --- a/examples/webchannel/standalone/main.cpp +++ b/examples/webchannel/standalone/main.cpp @@ -48,21 +48,18 @@ ** ****************************************************************************/ -#include "qwebchannel.h" +#include "ui_dialog.h" +#include "../shared/websocketclientwrapper.h" +#include "../shared/websockettransport.h" #include -#include -#include #include -#include +#include #include #include -#include - -#include "../shared/websocketclientwrapper.h" -#include "../shared/websockettransport.h" - -#include "ui_dialog.h" +#include +#include +#include /*! An instance of this class gets published over the WebChannel and is then accessible to HTML clients. -- cgit v1.2.1