diff --git a/shared/qrceditor/resourcefile.cpp b/shared/qrceditor/resourcefile.cpp index defd22749ffa4ec49095583967ca524227ef7a83..723d6f745a5b35b99a7b9763d6fa71d657c4cf5e 100644 --- a/shared/qrceditor/resourcefile.cpp +++ b/shared/qrceditor/resourcefile.cpp @@ -30,9 +30,6 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -/* -TRANSLATOR qdesigner_internal::ResourceModel -*/ #include "resourcefile_p.h" @@ -50,6 +47,10 @@ TRANSLATOR qdesigner_internal::ResourceModel QT_BEGIN_NAMESPACE +/* +TRANSLATOR qdesigner_internal::ResourceModel +*/ + namespace qdesigner_internal { /****************************************************************************** @@ -956,7 +957,7 @@ QString ResourceModel::resourcePath(const QString &prefix, const QString &file) return QDir::cleanPath(rc); } -QMimeData *ResourceModel::mimeData(const QModelIndexList & indexes) const +QMimeData *ResourceModel::mimeData(const QModelIndexList &indexes) const { if (indexes.size() != 1) return 0; @@ -977,6 +978,7 @@ QMimeData *ResourceModel::mimeData(const QModelIndexList & indexes) const rc->setText(doc.toString()); return rc; } + } // namespace qdesigner_internal QT_END_NAMESPACE diff --git a/shared/qrceditor/resourcefile_p.h b/shared/qrceditor/resourcefile_p.h index c3de0f65cfdbb2da05639167304204bb203431e2..d474b6c5d017f113f385070b3361447568c70559 100644 --- a/shared/qrceditor/resourcefile_p.h +++ b/shared/qrceditor/resourcefile_p.h @@ -30,8 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -#ifndef RESOURCEFILE_H -#define RESOURCEFILE_H + +#ifndef RESOURCEFILE__P_H +#define RESOURCEFILE__P_H #include "namespace_global.h" @@ -62,8 +63,6 @@ struct Prefix; */ class Node { - File *m_file; - Prefix *m_prefix; protected: Node(File *file, Prefix *prefix) : m_file(file), m_prefix(prefix) { @@ -72,6 +71,9 @@ protected: public: File * file() { return m_file; } Prefix * prefix() { Q_ASSERT(m_prefix != NULL); return m_prefix; } +private: + File *m_file; + Prefix *m_prefix; }; /*! @@ -95,7 +97,8 @@ typedef QList<File *> FileList; Represents a prefix node in a \l ResourceFile tree. */ -struct Prefix : public Node { +struct Prefix : public Node +{ Prefix(const QString &_name = QString(), const QString &_lang = QString(), const FileList &_file_list = FileList()) : Node(NULL, this), name(_name), lang(_lang), file_list(_file_list) {} ~Prefix() @@ -263,4 +266,4 @@ private: QT_END_NAMESPACE -#endif // RESOURCEFILE_H +#endif // RESOURCEFILE_P_H diff --git a/shared/qrceditor/resourceview.cpp b/shared/qrceditor/resourceview.cpp index 891b19aeaead5d9d45c751138e7111d11c9b9138..22e2ff0799a534abc7a43b44eb93281b6e755d54 100644 --- a/shared/qrceditor/resourceview.cpp +++ b/shared/qrceditor/resourceview.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "resourceview.h" #include "undocommands_p.h" @@ -658,4 +659,4 @@ bool ResourceView::resourceDragEnabled() const return m_qrcModel->resourceDragEnabled(); } -} +} // namespace SharedTools diff --git a/shared/qrceditor/resourceview.h b/shared/qrceditor/resourceview.h index 87cd22de368c24596b614eb8aea98ea2a2e9ffe5..82599c9543e949e7da1af56e8641659fd3122b6f 100644 --- a/shared/qrceditor/resourceview.h +++ b/shared/qrceditor/resourceview.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef RESOURCEVIEW_H #define RESOURCEVIEW_H @@ -42,10 +43,12 @@ using namespace qdesigner_internal; -QT_FORWARD_DECLARE_CLASS(QAction) -QT_FORWARD_DECLARE_CLASS(QMenu) -QT_FORWARD_DECLARE_CLASS(QMouseEvent) -QT_FORWARD_DECLARE_CLASS(QUndoStack) +QT_BEGIN_NAMESPACE +class QAction; +class QMenu; +class QMouseEvent; +class QUndoStack; +QT_END_NAMESPACE namespace SharedTools { @@ -178,6 +181,6 @@ private: int m_mergeId; }; -} +} // namespace SharedTools -#endif //RESOURCEVIEW_H +#endif // RESOURCEVIEW_H diff --git a/shared/qrceditor/test/main.cpp b/shared/qrceditor/test/main.cpp index d8891accd80202f86e844312582ce573a34020cf..d0b664ff65d9ca49ca35e1045fb2dc08aed814c6 100644 --- a/shared/qrceditor/test/main.cpp +++ b/shared/qrceditor/test/main.cpp @@ -30,12 +30,13 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "qrceditor.h" #include "mainwindow.h" int main(int argc, char *argv[]) { - QApplication app(argc,argv); + QApplication app(argc, argv); MainWindow mw; mw.show(); return app.exec(); diff --git a/shared/qrceditor/test/mainwindow.cpp b/shared/qrceditor/test/mainwindow.cpp index 2879602d178bd4d538cf672a2396d866753da69f..a316fcc3fc059ba0cf6a235d5bb09cc6a96f445b 100644 --- a/shared/qrceditor/test/mainwindow.cpp +++ b/shared/qrceditor/test/mainwindow.cpp @@ -30,16 +30,16 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "mainwindow.h" #include "qrceditor.h" -#include <QMenuBar> #include <QAction> -#include <QVBoxLayout> +#include <QDebug> #include <QFileDialog> +#include <QMenuBar> #include <QStatusBar> - -#include <qdebug.h> +#include <QVBoxLayout> MainWindow::MainWindow() : m_qrcEditor(new SharedTools::QrcEditor()) @@ -67,9 +67,9 @@ MainWindow::MainWindow() : void MainWindow::slotOpen() { - const QString fileName = QFileDialog::getOpenFileName (this, tr("Choose resource file"), - QString(), - tr("Resource files (*.qrc)")); + const QString fileName = QFileDialog::getOpenFileName(this, tr("Choose resource file"), + QString(), + tr("Resource files (*.qrc)")); if (fileName.isEmpty()) return; @@ -81,13 +81,13 @@ void MainWindow::slotOpen() void MainWindow::slotSave() { - const QString oldFileName = m_qrcEditor->fileName(); + const QString oldFileName = m_qrcEditor->fileName(); QString fileName = oldFileName; if (fileName.isEmpty()) { - fileName = QFileDialog::getSaveFileName (this, tr("Save resource file"), - QString(), - tr("Resource files (*.qrc)")); + fileName = QFileDialog::getSaveFileName(this, tr("Save resource file"), + QString(), + tr("Resource files (*.qrc)")); if (fileName.isEmpty()) return; } diff --git a/shared/qrceditor/test/mainwindow.h b/shared/qrceditor/test/mainwindow.h index f6570a4a12a96a9177d87fa370a93c849671db91..61ea67ec1ba425f583dd76ffaf517ff3e38f09d0 100644 --- a/shared/qrceditor/test/mainwindow.h +++ b/shared/qrceditor/test/mainwindow.h @@ -30,8 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -#ifndef _MAINWINDOW_ -#define _MAINWINDOW_ + +#ifndef MAINWINDOW_H +#define MAINWINDOW_H #include <QMainWindow> @@ -39,7 +40,8 @@ namespace SharedTools { class QrcEditor; } -class MainWindow : public QMainWindow { +class MainWindow : public QMainWindow +{ Q_OBJECT public: @@ -51,6 +53,6 @@ private slots: private: SharedTools::QrcEditor *m_qrcEditor; -}; // MainWindow +}; -#endif +#endif // MAINWINDOW_H diff --git a/shared/qrceditor/undocommands.cpp b/shared/qrceditor/undocommands.cpp index 90007d8c1b6dbc9370237c2f8a0c06513100dd3e..69628c3369c22824a9200b505ef407b28af305db 100644 --- a/shared/qrceditor/undocommands.cpp +++ b/shared/qrceditor/undocommands.cpp @@ -30,18 +30,6 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -/**************************************************************************** -** -** Copyright (C) 2008-$THISYEAR$ $TROLLTECH$. All rights reserved. -** -** This file is part of the $MODULE$ of the Qt Toolkit. -** -** $TROLLTECH_DUAL_LICENSE$ -** -** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE -** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. -** -****************************************************************************/ #include "undocommands_p.h" @@ -104,7 +92,7 @@ bool ModifyPropertyCommand::mergeWith(const QUndoCommand * command) { const ModifyPropertyCommand * const brother = dynamic_cast<const ModifyPropertyCommand *>(command); - if ((command == NULL) || (m_property != brother->m_property)) + if (command == NULL || m_property != brother->m_property) return false; // Choose older command (this) and forgot the other @@ -125,9 +113,8 @@ void ModifyPropertyCommand::undo() void ModifyPropertyCommand::redo() { // Prevent execution from within QUndoStack::push - if (m_after.isNull()) { + if (m_after.isNull()) return; - } // Bring back text before undo Q_ASSERT(m_view != NULL); diff --git a/shared/qrceditor/undocommands_p.h b/shared/qrceditor/undocommands_p.h index 8247f9354766410a6f66459aa51767caf28eec70..3f111d0a15806824a913da8773895f1e8b21d9e8 100644 --- a/shared/qrceditor/undocommands_p.h +++ b/shared/qrceditor/undocommands_p.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef UNDO_COMMANDS_H #define UNDO_COMMANDS_H @@ -38,7 +39,9 @@ #include <QtCore/QString> #include <QtGui/QUndoCommand> -QT_FORWARD_DECLARE_CLASS(QModelIndex); +QT_BEGIN_NAMESPACE +class QModelIndex; +QT_END_NAMESPACE namespace SharedTools { diff --git a/shared/qscripthighlighter/qscripthighlighter.cpp b/shared/qscripthighlighter/qscripthighlighter.cpp index 6d9449e36c1966701f3c1ace480ccdc61f29d30b..885a388be51af91f0583bc393528d157cc4c6744 100644 --- a/shared/qscripthighlighter/qscripthighlighter.cpp +++ b/shared/qscripthighlighter/qscripthighlighter.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "qscripthighlighter.h" #include <QtCore/QSet> @@ -105,7 +106,7 @@ static const QSet<QString> &qscriptKeywords() { } - namespace SharedTools { +namespace SharedTools { QScriptHighlighter::QScriptHighlighter(QTextDocument *parent) : QSyntaxHighlighter(parent) @@ -438,9 +439,8 @@ void QScriptHighlighter::highlightKeyword(int currentPos, const QString &buffer) if (buffer.at(0) == QLatin1Char('Q')) { setFormat(currentPos - buffer.length(), buffer.length(), m_formats[TypeFormat]); } else { - if (qscriptKeywords().contains(buffer)) { + if (qscriptKeywords().contains(buffer)) setFormat(currentPos - buffer.length(), buffer.length(), m_formats[KeywordFormat]); - } } } @@ -466,7 +466,8 @@ void QScriptHighlighter::setFormats(const QVector<QTextCharFormat> &s) qCopy(s.constBegin(), s.constEnd(), m_formats); } -int QScriptHighlighter::onBlockStart() { +int QScriptHighlighter::onBlockStart() +{ int state = 0; int previousState = previousBlockState(); if (previousState != -1) @@ -476,5 +477,6 @@ int QScriptHighlighter::onBlockStart() { void QScriptHighlighter::onOpeningParenthesis(QChar, int) {} void QScriptHighlighter::onClosingParenthesis(QChar, int) {} void QScriptHighlighter::onBlockEnd(int state, int) { return setCurrentBlockState(state); } -} + +} // namespace SharedTools diff --git a/shared/qscripthighlighter/qscripthighlighter.h b/shared/qscripthighlighter/qscripthighlighter.h index 186cb59f5f9906dde7409e6747a4e4e4ee92526f..938aa9cde587862f96f03b3947091a4c9d8c8dfa 100644 --- a/shared/qscripthighlighter/qscripthighlighter.h +++ b/shared/qscripthighlighter/qscripthighlighter.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef QSCRIPTSYNTAXHIGHLIGHTER_H #define QSCRIPTSYNTAXHIGHLIGHTER_H @@ -59,7 +60,8 @@ private: virtual int onBlockStart(); // returns the blocks initial state virtual void onOpeningParenthesis(QChar parenthesis, int pos); virtual void onClosingParenthesis(QChar parenthesis, int pos); - virtual void onBlockEnd(int state, int firstNonSpace); // sets the enriched user state, or simply calls setCurrentBlockState(state); + // sets the enriched user state, or simply calls setCurrentBlockState(state); + virtual void onBlockEnd(int state, int firstNonSpace); void highlightKeyword(int currentPos, const QString &buffer); diff --git a/shared/qscripthighlighter/test/main.cpp b/shared/qscripthighlighter/test/main.cpp index 80095802daf19ab217e938cd07225c6b5718a837..5015ac193665fc08434714fa2c11b0c56f8e6e52 100644 --- a/shared/qscripthighlighter/test/main.cpp +++ b/shared/qscripthighlighter/test/main.cpp @@ -30,7 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "qscripthighlighter.h" + #include <QTextEdit> #include <QMainWindow> #include <QApplication> diff --git a/shared/qtextended_integration.h b/shared/qtextended_integration.h index d76ea28babdc53a1135f2626bc7f45483f86bea3..c05d4b63d9e1ebbca0ba80d70d849c9eddbde8d5 100644 --- a/shared/qtextended_integration.h +++ b/shared/qtextended_integration.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef QTEXTENDED_INTEGRATION #define QTEXTENDED_INTEGRATION diff --git a/shared/qtlockedfile/qtlockedfile.cpp b/shared/qtlockedfile/qtlockedfile.cpp index e4fe1c388d815b89733cb87cf78be47c9d6a4a55..abcb545543b898e25f176d1acec504ee394266ea 100644 --- a/shared/qtlockedfile/qtlockedfile.cpp +++ b/shared/qtlockedfile/qtlockedfile.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "qtlockedfile.h" namespace SharedTools { @@ -158,4 +159,4 @@ QtLockedFile::LockMode QtLockedFile::lockMode() const Destroys the \e QtLockedFile object. If any locks were held, they are released. */ -} +} // namespace SharedTools diff --git a/shared/qtlockedfile/qtlockedfile.h b/shared/qtlockedfile/qtlockedfile.h index b8357d491b151a9e6f3ff29f0b923c5eed2e0f8a..347e96f7328e46b723fead07a9e4dbfd1488f3d6 100644 --- a/shared/qtlockedfile/qtlockedfile.h +++ b/shared/qtlockedfile/qtlockedfile.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef QTLOCKEDFILE_H #define QTLOCKEDFILE_H @@ -75,6 +76,6 @@ private: LockMode m_lock_mode; }; -} +} // namespace SharedTools -#endif +#endif // QTLOCKEDFILE_H diff --git a/shared/qtlockedfile/qtlockedfile_unix.cpp b/shared/qtlockedfile/qtlockedfile_unix.cpp index 0a9ba5ab4789057f2179b26b445b7536b621d6aa..9eb932411e9f148468c3752af24e8fe79478480c 100644 --- a/shared/qtlockedfile/qtlockedfile_unix.cpp +++ b/shared/qtlockedfile/qtlockedfile_unix.cpp @@ -30,13 +30,14 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + +#include "qtlockedfile.h" + #include <string.h> #include <errno.h> #include <unistd.h> #include <fcntl.h> -#include "qtlockedfile.h" - namespace SharedTools { bool QtLockedFile::lock(LockMode mode, bool block) @@ -107,4 +108,4 @@ QtLockedFile::~QtLockedFile() unlock(); } -} +} // namespace SharedTools diff --git a/shared/qtlockedfile/qtlockedfile_win.cpp b/shared/qtlockedfile/qtlockedfile_win.cpp index 01e3f76e7545f0a81997883ee000183eaa3837e6..9a85a82420897006d455819c816cd343894c2af4 100644 --- a/shared/qtlockedfile/qtlockedfile_win.cpp +++ b/shared/qtlockedfile/qtlockedfile_win.cpp @@ -30,7 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "qtlockedfile.h" + #include <qt_windows.h> #include <QtCore/QFileInfo> @@ -202,4 +204,4 @@ QtLockedFile::~QtLockedFile() } } -} +} // namespace SharedTools diff --git a/shared/qtsingleapplication/qtlocalpeer.cpp b/shared/qtsingleapplication/qtlocalpeer.cpp index 30a195f90860eee9b0f17dfcb6b71e1a6823972c..bfd98a4d45527727d9b07e0a27c0482b40f7e8bf 100644 --- a/shared/qtsingleapplication/qtlocalpeer.cpp +++ b/shared/qtsingleapplication/qtlocalpeer.cpp @@ -32,6 +32,7 @@ ***************************************************************************/ #include "qtlocalpeer.h" + #include <QtCore/QCoreApplication> #include <QtCore/QTime> @@ -176,4 +177,4 @@ void QtLocalPeer::receiveConnection() emit messageReceived(message); // ##(might take a long time to return) } -} +} // namespace SharedTools diff --git a/shared/qtsingleapplication/qtlocalpeer.h b/shared/qtsingleapplication/qtlocalpeer.h index bac571bd2821025e6f6472c559f91bf78783682e..c760c5b49789f906c567ce1371b5eded99e5d2d6 100644 --- a/shared/qtsingleapplication/qtlocalpeer.h +++ b/shared/qtsingleapplication/qtlocalpeer.h @@ -31,11 +31,11 @@ ** ***************************************************************************/ +#include "qtlockedfile.h" #include <QtNetwork/QLocalServer> #include <QtNetwork/QLocalSocket> #include <QtCore/QDir> -#include <qtlockedfile.h> namespace SharedTools { @@ -66,4 +66,4 @@ private: static const char* ack; }; -} // SharedTools +} // namespace SharedTools diff --git a/shared/qtsingleapplication/qtsingleapplication.cpp b/shared/qtsingleapplication/qtsingleapplication.cpp index ff437e039e34f2ca1d804fc491692fbb3e52089e..b28c3606ef3fc8e87b5a8f3acd286d057a68f370 100644 --- a/shared/qtsingleapplication/qtsingleapplication.cpp +++ b/shared/qtsingleapplication/qtsingleapplication.cpp @@ -33,6 +33,7 @@ #include "qtsingleapplication.h" #include "qtlocalpeer.h" + #include <QtGui/QWidget> #include <QtGui/QFileOpenEvent> @@ -80,7 +81,8 @@ QtSingleApplication::QtSingleApplication(Display *dpy, int &argc, char **argv, Q sysInit(); } -QtSingleApplication::QtSingleApplication(Display* dpy, const QString &appId, int argc, char **argv, Qt::HANDLE visual, Qt::HANDLE colormap) +QtSingleApplication::QtSingleApplication(Display* dpy, const QString &appId, + int argc, char **argv, Qt::HANDLE visual, Qt::HANDLE colormap) : QApplication(dpy, argc, argv, visual, colormap) { sysInit(appId); @@ -115,13 +117,13 @@ QString QtSingleApplication::id() const } -void QtSingleApplication::setActivationWindow(QWidget* aw, bool activateOnMessage) +void QtSingleApplication::setActivationWindow(QWidget *aw, bool activateOnMessage) { actWin = aw; if (activateOnMessage) - connect(peer, SIGNAL(messageReceived(const QString&)), this, SLOT(activateWindow())); + connect(peer, SIGNAL(messageReceived(QString)), this, SLOT(activateWindow())); else - disconnect(peer, SIGNAL(messageReceived(const QString&)), this, SLOT(activateWindow())); + disconnect(peer, SIGNAL(messageReceived(QString)), this, SLOT(activateWindow())); } @@ -140,4 +142,4 @@ void QtSingleApplication::activateWindow() } } -} +} // namespace SharedTools diff --git a/shared/qtsingleapplication/qtsingleapplication.h b/shared/qtsingleapplication/qtsingleapplication.h index f56e3f1c354c3edb77c1eedf5031d029f9875c1b..d3b16c6a7bb45413bdd2898adf5a28f61db5a6da 100644 --- a/shared/qtsingleapplication/qtsingleapplication.h +++ b/shared/qtsingleapplication/qtsingleapplication.h @@ -82,4 +82,4 @@ private: QWidget *actWin; }; -} +} // namespace SharedTools diff --git a/shared/qtsingleapplication/qtsinglecoreapplication.cpp b/shared/qtsingleapplication/qtsinglecoreapplication.cpp index d3c636641da4d3b5b3514db5600fa45e6d09c109..8048fc23a3b0de5e2fa7495d0f8b05bddb304ca1 100644 --- a/shared/qtsingleapplication/qtsinglecoreapplication.cpp +++ b/shared/qtsingleapplication/qtsinglecoreapplication.cpp @@ -40,7 +40,7 @@ QtSingleCoreApplication::QtSingleCoreApplication(int &argc, char **argv) : QCoreApplication(argc, argv) { peer = new QtLocalPeer(this); - connect(peer, SIGNAL(messageReceived(const QString&)), SIGNAL(messageReceived(const QString&))); + connect(peer, SIGNAL(messageReceived(QString)), SIGNAL(messageReceived(QString))); } @@ -48,7 +48,7 @@ QtSingleCoreApplication::QtSingleCoreApplication(const QString &appId, int &argc : QCoreApplication(argc, argv) { peer = new QtLocalPeer(this, appId); - connect(peer, SIGNAL(messageReceived(const QString&)), SIGNAL(messageReceived(const QString&))); + connect(peer, SIGNAL(messageReceived(QString)), SIGNAL(messageReceived(QString))); } @@ -69,4 +69,4 @@ QString QtSingleCoreApplication::id() const return peer->applicationId(); } -} +} // namespace SharedTools diff --git a/shared/qtsingleapplication/qtsinglecoreapplication.h b/shared/qtsingleapplication/qtsinglecoreapplication.h index 185a82a0b34625e6127809cfcc3f3214cac348bc..31640270984c5080879dc31770191196788ee191 100644 --- a/shared/qtsingleapplication/qtsinglecoreapplication.h +++ b/shared/qtsingleapplication/qtsinglecoreapplication.h @@ -60,4 +60,4 @@ private: QtLocalPeer* peer; }; -} +} // namespace SharedTools diff --git a/shared/scriptwrapper/interface_wrap_helpers.h b/shared/scriptwrapper/interface_wrap_helpers.h index eb1f4b37acbcf4a1d789e890d7b41aa76f4f63fc..6c8fbb871f7cfd34e2519053b5e93e22d03b633e 100644 --- a/shared/scriptwrapper/interface_wrap_helpers.h +++ b/shared/scriptwrapper/interface_wrap_helpers.h @@ -30,13 +30,14 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef INTERFACE_WRAP_HELPERS_H #define INTERFACE_WRAP_HELPERS_H #include <extensionsystem/ExtensionSystemInterfaces> #include <QtScript/QScriptEngine> - namespace SharedTools { +namespace SharedTools { // Convert a QObjectInterface to Scriptvalue // To be registered as a magic creation function with qScriptRegisterMetaType(). @@ -87,6 +88,6 @@ static void registerQObjectInterface(QScriptEngine &engine) Q_UNUSED(metaTypeId); } -} +} // namespace SharedTools -#endif +#endif // INTERFACE_WRAP_HELPERS_H diff --git a/shared/scriptwrapper/wrap_helpers.h b/shared/scriptwrapper/wrap_helpers.h index cb7f68dddbd621aa25c9a157a343be07ce36ef7c..c310c6f36ad91ade9e77c858bfae3dc4310f4483 100644 --- a/shared/scriptwrapper/wrap_helpers.h +++ b/shared/scriptwrapper/wrap_helpers.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef WRAP_HELPERS_H #define WRAP_HELPERS_H @@ -329,6 +330,6 @@ static void registerQObject(QScriptEngine &engine) scriptValueToQObject<SomeQObject>); } -} +} // namespace SharedTools -#endif +#endif // WRAP_HELPERS_H diff --git a/src/app/main.cpp b/src/app/main.cpp index 0247b1dde358568595826da4b072fd0df9644371..df4b368c7d9aaa5923202990730283a89c818bc8 100644 --- a/src/app/main.cpp +++ b/src/app/main.cpp @@ -51,7 +51,7 @@ # include <sys/resource.h> #endif -enum { OptionIndent =4, DescriptionIndent = 24 }; +enum { OptionIndent = 4, DescriptionIndent = 24 }; static const char *appNameC = "Qt Creator"; static const char *corePluginNameC = "Core"; diff --git a/src/libs/aggregation/aggregate.cpp b/src/libs/aggregation/aggregate.cpp index bfd9e0f4dce3b2cc6a0607e039ff5105637b2284..5ca8cc535560894f982cb2f5392c0c64dec186f9 100644 --- a/src/libs/aggregation/aggregate.cpp +++ b/src/libs/aggregation/aggregate.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "aggregate.h" #include <QtCore/QWriteLocker> @@ -262,4 +263,3 @@ void Aggregate::remove(QObject *component) m_components.removeAll(component); disconnect(component, SIGNAL(destroyed(QObject*)), this, SLOT(deleteSelf(QObject*))); } - diff --git a/src/libs/aggregation/aggregate.h b/src/libs/aggregation/aggregate.h index 5040aec8b2ee79d27444d19580d20dc2b7d0d809..20c9bfbca69c1ab89ed0a4301220c0ec6328b5ec 100644 --- a/src/libs/aggregation/aggregate.h +++ b/src/libs/aggregation/aggregate.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef QAGGREGATION_H #define QAGGREGATION_H @@ -131,4 +132,4 @@ template <typename T> QList<T *> query_all(QObject *obj) } // namespace Aggregation -#endif // header guard +#endif // QAGGREGATION_H diff --git a/src/libs/aggregation/aggregation_global.h b/src/libs/aggregation/aggregation_global.h index cae0917d651c12dc8d718dd0c01e555765f19914..0080813711cc890f75166753caae62c76f1f01d3 100644 --- a/src/libs/aggregation/aggregation_global.h +++ b/src/libs/aggregation/aggregation_global.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef AGGREGATION_GLOBAL_H #define AGGREGATION_GLOBAL_H @@ -41,4 +42,4 @@ # define AGGREGATION_EXPORT Q_DECL_IMPORT #endif -#endif // header +#endif // AGGREGATION_GLOBAL_H diff --git a/src/libs/aggregation/examples/text/main.cpp b/src/libs/aggregation/examples/text/main.cpp index 1a0ecac8167e54b640cd082749b57079aae034d4..8de68c0ffb7646c39e7b557e8c785607f53e3be7 100644 --- a/src/libs/aggregation/examples/text/main.cpp +++ b/src/libs/aggregation/examples/text/main.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "main.h" #include <QtGui/QApplication> @@ -107,4 +108,3 @@ int main(int argc, char *argv[]) w.show(); return app.exec(); } - diff --git a/src/libs/aggregation/examples/text/main.h b/src/libs/aggregation/examples/text/main.h index 3a458923b426b1d03d2538dec9cfc6031d3038b0..dba72569465913b416a41ca11e37e4ce5e9a7e26 100644 --- a/src/libs/aggregation/examples/text/main.h +++ b/src/libs/aggregation/examples/text/main.h @@ -30,15 +30,16 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MAIN_H #define MAIN_H #include "myinterfaces.h" +#include "ui_main.h" #include <aggregate.h> #include <QtGui/QWidget> -#include "ui_main.h" class MyMain : public QWidget { diff --git a/src/libs/aggregation/examples/text/myinterfaces.h b/src/libs/aggregation/examples/text/myinterfaces.h index 62dad429e2a1b392b25cc5c305f092622b2fdc89..150f60603bcda5e39848669106ebb2576a830fe2 100644 --- a/src/libs/aggregation/examples/text/myinterfaces.h +++ b/src/libs/aggregation/examples/text/myinterfaces.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MYINTERFACES_H #define MYINTERFACES_H @@ -45,6 +46,7 @@ public: IComboEntry(QString title) : m_title(title) {} virtual ~IComboEntry() {} QString title() const { return m_title; } + private: QString m_title; }; @@ -57,6 +59,7 @@ public: IText1(QString text) : m_text(text) {} virtual ~IText1() {} QString text() const { return m_text; } + private: QString m_text; }; @@ -68,6 +71,7 @@ class IText2 : public QObject public: IText2(QString text) : m_text(text) {} QString text() const { return m_text; } + private: QString m_text; }; @@ -80,6 +84,7 @@ public: IText3(QString text) : m_text(text) {} virtual ~IText3() {} QString text() const { return m_text; } + private: QString m_text; }; diff --git a/src/libs/aggregation/test/tst_aggregate.cpp b/src/libs/aggregation/test/tst_aggregate.cpp index 098cc723af9b3cfa262c67630ce9a414bfb251a9..38447eaaf1fe33bc5eec11dbb5e4a4e6fd6327d9 100644 --- a/src/libs/aggregation/test/tst_aggregate.cpp +++ b/src/libs/aggregation/test/tst_aggregate.cpp @@ -30,10 +30,11 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -#include <QtTest/QtTest> #include <aggregate.h> +#include <QtTest/QtTest> + class tst_Aggregate : public QObject { Q_OBJECT @@ -195,4 +196,5 @@ void tst_Aggregate::parentAggregate() } QTEST_MAIN(tst_Aggregate) + #include "tst_aggregate.moc" diff --git a/src/libs/cplusplus/CppDocument.cpp b/src/libs/cplusplus/CppDocument.cpp index b2e0ca4be14a45aadd2c48c823e8ae83483a8010..f422cbefc46f2eddea2255e89d1e51d85078030e 100644 --- a/src/libs/cplusplus/CppDocument.cpp +++ b/src/libs/cplusplus/CppDocument.cpp @@ -40,6 +40,7 @@ #include <Symbols.h> #include <AST.h> #include <Scope.h> + #include <QByteArray> #include <QFile> #include <QtDebug> @@ -47,50 +48,52 @@ using namespace CPlusPlus; namespace { - class DocumentDiagnosticClient: public DiagnosticClient - { - enum { MAX_MESSAGE_COUNT = 10 }; - public: - DocumentDiagnosticClient(Document *doc, QList<Document::DiagnosticMessage> *messages) - : doc(doc), - messages(messages) - { } +class DocumentDiagnosticClient : public DiagnosticClient +{ + enum { MAX_MESSAGE_COUNT = 10 }; + +public: + DocumentDiagnosticClient(Document *doc, QList<Document::DiagnosticMessage> *messages) + : doc(doc), + messages(messages) + { } + + virtual void report(int level, + StringLiteral *fileId, + unsigned line, unsigned column, + const char *format, va_list ap) + { + if (messages->count() == MAX_MESSAGE_COUNT) + return; - virtual void report(int level, - StringLiteral *fileId, - unsigned line, unsigned column, - const char *format, va_list ap) - { - if (messages->count() == MAX_MESSAGE_COUNT) - return; + const QString fileName = QString::fromUtf8(fileId->chars(), fileId->size()); - const QString fileName = QString::fromUtf8(fileId->chars(), fileId->size()); + if (fileName != doc->fileName()) + return; - if (fileName != doc->fileName()) - return; + QString message; + message.vsprintf(format, ap); - QString message; - message.vsprintf(format, ap); + Document::DiagnosticMessage m(convertLevel(level), doc->fileName(), + line, column, message); + messages->append(m); + } - Document::DiagnosticMessage m(convertLevel(level), doc->fileName(), - line, column, message); - messages->append(m); + static int convertLevel(int level) { + switch (level) { + case Warning: return Document::DiagnosticMessage::Warning; + case Error: return Document::DiagnosticMessage::Error; + case Fatal: return Document::DiagnosticMessage::Fatal; + default: return Document::DiagnosticMessage::Error; } + } - static int convertLevel(int level) { - switch (level) { - case Warning: return Document::DiagnosticMessage::Warning; - case Error: return Document::DiagnosticMessage::Error; - case Fatal: return Document::DiagnosticMessage::Fatal; - default: return Document::DiagnosticMessage::Error; - } - } + Document *doc; + QList<Document::DiagnosticMessage> *messages; +}; - Document *doc; - QList<Document::DiagnosticMessage> *messages; - }; -} // end of anonymous namespace +} // anonymous namespace Document::Document(const QString &fileName) : _fileName(fileName), @@ -116,19 +119,29 @@ Document::~Document() } Control *Document::control() const -{ return _control; } +{ + return _control; +} QString Document::fileName() const -{ return _fileName; } +{ + return _fileName; +} QStringList Document::includedFiles() const -{ return _includedFiles; } +{ + return _includedFiles; +} void Document::addIncludeFile(const QString &fileName) -{ _includedFiles.append(fileName); } +{ + _includedFiles.append(fileName); +} QByteArray Document::definedMacros() const -{ return _definedMacros; } +{ + return _definedMacros; +} void Document::appendMacro(const QByteArray ¯oName, const QByteArray &text) { @@ -141,13 +154,19 @@ void Document::appendMacro(const QByteArray ¯oName, const QByteArray &text) } TranslationUnit *Document::translationUnit() const -{ return _translationUnit; } +{ + return _translationUnit; +} bool Document::skipFunctionBody() const -{ return _translationUnit->skipFunctionBody(); } +{ + return _translationUnit->skipFunctionBody(); +} void Document::setSkipFunctionBody(bool skipFunctionBody) -{ _translationUnit->setSkipFunctionBody(skipFunctionBody); } +{ + _translationUnit->setSkipFunctionBody(skipFunctionBody); +} unsigned Document::globalSymbolCount() const { @@ -158,7 +177,9 @@ unsigned Document::globalSymbolCount() const } Symbol *Document::globalSymbolAt(unsigned index) const -{ return _globalNamespace->memberAt(index); } +{ + return _globalNamespace->memberAt(index); +} Scope *Document::globalSymbols() const { @@ -169,10 +190,14 @@ Scope *Document::globalSymbols() const } Namespace *Document::globalNamespace() const -{ return _globalNamespace; } +{ + return _globalNamespace; +} Symbol *Document::findSymbolAt(unsigned line, unsigned column) const -{ return findSymbolAt(line, column, globalSymbols()); } +{ + return findSymbolAt(line, column, globalSymbols()); +} Symbol *Document::findSymbolAt(unsigned line, unsigned column, Scope *scope) const { @@ -203,10 +228,14 @@ Document::Ptr Document::create(const QString &fileName) } void Document::setSource(const QByteArray &source) -{ _translationUnit->setSource(source.constBegin(), source.size()); } +{ + _translationUnit->setSource(source.constBegin(), source.size()); +} void Document::startSkippingBlocks(unsigned start) -{ _skippedBlocks.append(Block(start, 0)); } +{ + _skippedBlocks.append(Block(start, 0)); +} void Document::stopSkippingBlocks(unsigned stop) { @@ -218,10 +247,14 @@ void Document::stopSkippingBlocks(unsigned stop) } QSet<QByteArray> Document::macroNames() const -{ return _macroNames; } +{ + return _macroNames; +} void Document::parse() -{ _translationUnit->parse(); } +{ + _translationUnit->parse(); +} void Document::check() { @@ -239,4 +272,6 @@ void Document::check() } void Document::releaseTranslationUnit() -{ _translationUnit->release(); } +{ + _translationUnit->release(); +} diff --git a/src/libs/cplusplus/CppDocument.h b/src/libs/cplusplus/CppDocument.h index 47f2366ddd00718da69689021a0076b03bb918b3..274ec4ba6a3a903e807db038c77306ef2cf397f7 100644 --- a/src/libs/cplusplus/CppDocument.h +++ b/src/libs/cplusplus/CppDocument.h @@ -30,16 +30,18 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CPPDOCUMENT_H #define CPPDOCUMENT_H #include <CPlusPlusForwardDeclarations.h> + #include <QByteArray> +#include <QList> +#include <QSet> #include <QSharedPointer> #include <QString> #include <QStringList> -#include <QList> -#include <QSet> namespace CPlusPlus { diff --git a/src/libs/cplusplus/ExpressionUnderCursor.h b/src/libs/cplusplus/ExpressionUnderCursor.h index e3fa442326e42f2587b2b698667cbc1c87db7c92..d1e307e6fcc0fb4b9d8cdb7ef8456eba47dea6c3 100644 --- a/src/libs/cplusplus/ExpressionUnderCursor.h +++ b/src/libs/cplusplus/ExpressionUnderCursor.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef EXPRESSIONUNDERCURSOR_H #define EXPRESSIONUNDERCURSOR_H diff --git a/src/libs/cplusplus/Icons.h b/src/libs/cplusplus/Icons.h index c549c1c4296d8edf3dfc964c636e3b6ce419ee86..2ecec8f228b8eb16bc8ef04eb8a658c4896d36c5 100644 --- a/src/libs/cplusplus/Icons.h +++ b/src/libs/cplusplus/Icons.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CPLUSPLUS_ICONS_H #define CPLUSPLUS_ICONS_H diff --git a/src/libs/cplusplus/LookupContext.cpp b/src/libs/cplusplus/LookupContext.cpp index 027cfb577d6f434b517b2da5ecfa219f91d8d441..157e15ad44c03e421d8ff1b104c18d537680ab54 100644 --- a/src/libs/cplusplus/LookupContext.cpp +++ b/src/libs/cplusplus/LookupContext.cpp @@ -39,6 +39,7 @@ #include <Scope.h> #include <Control.h> #include <cplusplus/Overview.h> + #include <QFile> #include <QtDebug> diff --git a/src/libs/cplusplus/LookupContext.h b/src/libs/cplusplus/LookupContext.h index d2fe8b7beff438b5c55a511048e5767384e11de9..d234dfaef6b05d313d3cb12b176b88ea692999a0 100644 --- a/src/libs/cplusplus/LookupContext.h +++ b/src/libs/cplusplus/LookupContext.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CPLUSPLUS_LOOKUPCONTEXT_H #define CPLUSPLUS_LOOKUPCONTEXT_H @@ -45,8 +46,7 @@ namespace CPlusPlus { class CPLUSPLUS_EXPORT LookupUtils { public: - static bool isNameCompatibleWithIdentifier(Name *name, - Identifier *id); + static bool isNameCompatibleWithIdentifier(Name *name, Identifier *id); }; class CPLUSPLUS_EXPORT LookupContext: LookupUtils diff --git a/src/libs/cplusplus/NameOfExpression.cpp b/src/libs/cplusplus/NameOfExpression.cpp index d54e7f5521641ed544a72e610bf04facccc41362..1d527d88ae2c79867d1059631906fb04428a510d 100644 --- a/src/libs/cplusplus/NameOfExpression.cpp +++ b/src/libs/cplusplus/NameOfExpression.cpp @@ -44,6 +44,7 @@ #include <CoreTypes.h> #include <TypeVisitor.h> #include <NameVisitor.h> + #include <QList> #include <QtDebug> diff --git a/src/libs/cplusplus/NameOfExpression.h b/src/libs/cplusplus/NameOfExpression.h index f68795cea0d482d6fea7fc04405fca79a82526d1..3f2b15e56e52a58f97877dc018679631e43e83ee 100644 --- a/src/libs/cplusplus/NameOfExpression.h +++ b/src/libs/cplusplus/NameOfExpression.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CPLUSPLUS_NAMEOFEXPRESSION_H #define CPLUSPLUS_NAMEOFEXPRESSION_H diff --git a/src/libs/cplusplus/NamePrettyPrinter.cpp b/src/libs/cplusplus/NamePrettyPrinter.cpp index 5d6fddfb63aadcb6b2445f65e5dc4037ec7af071..0795e6f0e65cf121ef34186b0e2f46ce997b307a 100644 --- a/src/libs/cplusplus/NamePrettyPrinter.cpp +++ b/src/libs/cplusplus/NamePrettyPrinter.cpp @@ -30,7 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "NamePrettyPrinter.h" + #include <Names.h> #include <Overview.h> #include <NameVisitor.h> @@ -46,7 +48,9 @@ NamePrettyPrinter::~NamePrettyPrinter() { } const Overview *NamePrettyPrinter::overview() const -{ return _overview; } +{ + return _overview; +} QString NamePrettyPrinter::operator()(Name *name) { diff --git a/src/libs/cplusplus/NamePrettyPrinter.h b/src/libs/cplusplus/NamePrettyPrinter.h index 38684326507bca88b16747f0ce94dc933d61032e..8e8210fd3d2ccb291f55079a97f2ce0af0ae280f 100644 --- a/src/libs/cplusplus/NamePrettyPrinter.h +++ b/src/libs/cplusplus/NamePrettyPrinter.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CPLUSPLUS_NAMEPRETTYPRINTER_H #define CPLUSPLUS_NAMEPRETTYPRINTER_H diff --git a/src/libs/cplusplus/Overview.cpp b/src/libs/cplusplus/Overview.cpp index ec40f75b515308f187553da4824aa4b0005d9f7c..9d561eae757688ae656b5c27d11ed874e16f3d04 100644 --- a/src/libs/cplusplus/Overview.cpp +++ b/src/libs/cplusplus/Overview.cpp @@ -49,25 +49,39 @@ Overview::~Overview() { } bool Overview::showArgumentNames() const -{ return _showArgumentNames; } +{ + return _showArgumentNames; +} void Overview::setShowArgumentNames(bool showArgumentNames) -{ _showArgumentNames = showArgumentNames; } +{ + _showArgumentNames = showArgumentNames; +} void Overview::setShowReturnTypes(bool showReturnTypes) -{ _showReturnTypes = showReturnTypes; } +{ + _showReturnTypes = showReturnTypes; +} bool Overview::showReturnTypes() const -{ return _showReturnTypes; } +{ + return _showReturnTypes; +} void Overview::setMarkArgument(unsigned position) -{ _markArgument = position; } +{ + _markArgument = position; +} bool Overview::showFunctionSignatures() const -{ return _showFunctionSignatures; } +{ + return _showFunctionSignatures; +} void Overview::setShowFunctionSignatures(bool showFunctionSignatures) -{ _showFunctionSignatures = showFunctionSignatures; } +{ + _showFunctionSignatures = showFunctionSignatures; +} QString Overview::prettyName(Name *name) const { @@ -75,9 +89,10 @@ QString Overview::prettyName(Name *name) const return pp(name); } -QString Overview::prettyType(const FullySpecifiedType &ty, - Name *name) const -{ return prettyType(ty, prettyName(name)); } +QString Overview::prettyType(const FullySpecifiedType &ty, Name *name) const +{ + return prettyType(ty, prettyName(name)); +} QString Overview::prettyType(const FullySpecifiedType &ty, const QString &name) const diff --git a/src/libs/cplusplus/Overview.h b/src/libs/cplusplus/Overview.h index 6b84a4b53f214f7819d1802686a6d364692e50f0..c9c0a6222a04e970dba36a4d0ea7e2862a2b1c9a 100644 --- a/src/libs/cplusplus/Overview.h +++ b/src/libs/cplusplus/Overview.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef OVERVIEW_H #define OVERVIEW_H diff --git a/src/libs/cplusplus/OverviewModel.cpp b/src/libs/cplusplus/OverviewModel.cpp index 028811e6ae3ee21f69c6197349342d67e2bfcefc..d56ab91e2f68b27fe0f7d421fd0cd37ff92fdae6 100644 --- a/src/libs/cplusplus/OverviewModel.cpp +++ b/src/libs/cplusplus/OverviewModel.cpp @@ -33,10 +33,12 @@ #include "OverviewModel.h" #include "Overview.h" + #include <Scope.h> #include <Semantic.h> #include <Literals.h> #include <Symbols.h> + #include <QFile> #include <QtDebug> @@ -50,10 +52,14 @@ OverviewModel::~OverviewModel() { } bool OverviewModel::hasDocument() const -{ return _cppDocument; } +{ + return _cppDocument; +} Document::Ptr OverviewModel::document() const -{ return _cppDocument; } +{ + return _cppDocument; +} unsigned OverviewModel::globalSymbolCount() const { @@ -124,7 +130,9 @@ int OverviewModel::rowCount(const QModelIndex &parent) const } int OverviewModel::columnCount(const QModelIndex &) const -{ return 1; } +{ + return 1; +} QVariant OverviewModel::data(const QModelIndex &index, int role) const { @@ -174,7 +182,9 @@ QVariant OverviewModel::data(const QModelIndex &index, int role) const } Symbol *OverviewModel::symbolFromIndex(const QModelIndex &index) const -{ return static_cast<Symbol *>(index.internalPointer()); } +{ + return static_cast<Symbol *>(index.internalPointer()); +} void OverviewModel::rebuild(Document::Ptr doc) { diff --git a/src/libs/cplusplus/OverviewModel.h b/src/libs/cplusplus/OverviewModel.h index 9ff920487ba0055956684c9eef0bed46cba1d152..8bb2bee8f54b7a00940a7503e53c04ca3381fe6b 100644 --- a/src/libs/cplusplus/OverviewModel.h +++ b/src/libs/cplusplus/OverviewModel.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CPLUSPLUS_OVERVIEWMODEL_H #define CPLUSPLUS_OVERVIEWMODEL_H @@ -42,7 +43,7 @@ namespace CPlusPlus { -class CPLUSPLUS_EXPORT OverviewModel: public QAbstractItemModel +class CPLUSPLUS_EXPORT OverviewModel : public QAbstractItemModel { Q_OBJECT diff --git a/src/libs/cplusplus/ResolveExpression.cpp b/src/libs/cplusplus/ResolveExpression.cpp index 6071f235c437d85027a03e1442c347ff88e36757..43320d466455dbd92a797e3f329a80ed71cc0553 100644 --- a/src/libs/cplusplus/ResolveExpression.cpp +++ b/src/libs/cplusplus/ResolveExpression.cpp @@ -44,6 +44,7 @@ #include <CoreTypes.h> #include <TypeVisitor.h> #include <NameVisitor.h> + #include <QList> #include <QtDebug> diff --git a/src/libs/cplusplus/ResolveExpression.h b/src/libs/cplusplus/ResolveExpression.h index 75963bb2fee2d63e768a13fe0b1d73a0a61db659..c68dba64d25c31206cc2403ec118e2d325a8b4ea 100644 --- a/src/libs/cplusplus/ResolveExpression.h +++ b/src/libs/cplusplus/ResolveExpression.h @@ -30,10 +30,12 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CPLUSPLUS_RESOLVEEXPRESSION_H #define CPLUSPLUS_RESOLVEEXPRESSION_H #include "LookupContext.h" + #include <ASTVisitor.h> #include <Semantic.h> #include <FullySpecifiedType.h> diff --git a/src/libs/cplusplus/SimpleLexer.cpp b/src/libs/cplusplus/SimpleLexer.cpp index f047d540c944441896fba6c1c0267d0ce59b1649..70a8e19efae514fcca7bef6b8583d681d6ee97d7 100644 --- a/src/libs/cplusplus/SimpleLexer.cpp +++ b/src/libs/cplusplus/SimpleLexer.cpp @@ -32,6 +32,7 @@ ***************************************************************************/ #include "SimpleLexer.h" + #include <Lexer.h> #include <Token.h> #include <QtDebug> @@ -39,13 +40,19 @@ using namespace CPlusPlus; bool SimpleToken::isLiteral() const -{ return _kind >= T_FIRST_LITERAL && _kind <= T_LAST_LITERAL; } +{ + return _kind >= T_FIRST_LITERAL && _kind <= T_LAST_LITERAL; +} bool SimpleToken::isOperator() const -{ return _kind >= T_FIRST_OPERATOR && _kind <= T_LAST_OPERATOR; } +{ + return _kind >= T_FIRST_OPERATOR && _kind <= T_LAST_OPERATOR; +} bool SimpleToken::isKeyword() const -{ return _kind >= T_FIRST_KEYWORD && _kind < T_FIRST_QT_KEYWORD; } +{ + return _kind >= T_FIRST_KEYWORD && _kind < T_FIRST_QT_KEYWORD; +} SimpleLexer::SimpleLexer() : _lastState(0), @@ -57,16 +64,24 @@ SimpleLexer::~SimpleLexer() { } bool SimpleLexer::qtMocRunEnabled() const -{ return _qtMocRunEnabled; } +{ + return _qtMocRunEnabled; +} void SimpleLexer::setQtMocRunEnabled(bool enabled) -{ _qtMocRunEnabled = enabled; } +{ + _qtMocRunEnabled = enabled; +} bool SimpleLexer::skipComments() const -{ return _skipComments; } +{ + return _skipComments; +} void SimpleLexer::setSkipComments(bool skipComments) -{ _skipComments = skipComments; } +{ + _skipComments = skipComments; +} QList<SimpleToken> SimpleLexer::operator()(const QString &text, int state) { diff --git a/src/libs/cplusplus/SimpleLexer.h b/src/libs/cplusplus/SimpleLexer.h index 9bbba4195023cffc07847ef50501c825ae30a9e8..82236fc565af60aa1624c1ac3a5feb3db918f604 100644 --- a/src/libs/cplusplus/SimpleLexer.h +++ b/src/libs/cplusplus/SimpleLexer.h @@ -34,6 +34,7 @@ #define SIMPLELEXER_H #include <CPlusPlusForwardDeclarations.h> + #include <QString> #include <QList> diff --git a/src/libs/extensionsystem/extensionsystem_global.h b/src/libs/extensionsystem/extensionsystem_global.h index ebd1f34da252795ead255f51df2890f82bfa22ad..fdadf50e63f9e8b184a356b52283efcb37ccdeac 100644 --- a/src/libs/extensionsystem/extensionsystem_global.h +++ b/src/libs/extensionsystem/extensionsystem_global.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef EXTENSIONSYSTEM_GLOBAL_H #define EXTENSIONSYSTEM_GLOBAL_H @@ -41,4 +42,4 @@ # define EXTENSIONSYSTEM_EXPORT Q_DECL_IMPORT #endif -#endif // header +#endif // EXTENSIONSYSTEM_GLOBAL_H diff --git a/src/libs/extensionsystem/iplugin.cpp b/src/libs/extensionsystem/iplugin.cpp index 47cb702e16b3cecec95f3e419edf4e317c869d3a..d35ba9d4a2599fd148670b16e9bae5a701e5decd 100644 --- a/src/libs/extensionsystem/iplugin.cpp +++ b/src/libs/extensionsystem/iplugin.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "iplugin.h" #include "iplugin_p.h" #include "pluginmanager.h" diff --git a/src/libs/extensionsystem/iplugin.h b/src/libs/extensionsystem/iplugin.h index b263e7b0d295b815de78924e7207210cbd30a866..e2b31130265d6e543acf1c3696130cb710e543dc 100644 --- a/src/libs/extensionsystem/iplugin.h +++ b/src/libs/extensionsystem/iplugin.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IPLUGIN_H #define IPLUGIN_H diff --git a/src/libs/extensionsystem/iplugin_p.h b/src/libs/extensionsystem/iplugin_p.h index 461a903a3989b19c810027d4bd6ba331c0d191dc..cb10c06b0b89e3da6c585a5b396b79658cdad11a 100644 --- a/src/libs/extensionsystem/iplugin_p.h +++ b/src/libs/extensionsystem/iplugin_p.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IPLUGIN_P_H #define IPLUGIN_P_H @@ -55,4 +56,4 @@ public: } // namespace Internal } // namespace ExtensionSystem -#endif // header guard +#endif // IPLUGIN_P_H diff --git a/src/libs/extensionsystem/optionsparser.cpp b/src/libs/extensionsystem/optionsparser.cpp index 77b6ed869e47e80a6e236296083e079722abbf03..9b6bdcb65839b009890e5be4a5b96338cffe2db7 100644 --- a/src/libs/extensionsystem/optionsparser.cpp +++ b/src/libs/extensionsystem/optionsparser.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "optionsparser.h" #include <QtCore/QCoreApplication> diff --git a/src/libs/extensionsystem/optionsparser.h b/src/libs/extensionsystem/optionsparser.h index 65ea70c9ba20adfe08e8ccb27ae56d683ba2a6dc..4702a953fa45f795662a20d8b62028432f1492ba 100644 --- a/src/libs/extensionsystem/optionsparser.h +++ b/src/libs/extensionsystem/optionsparser.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef OPTIONSPARSER_H #define OPTIONSPARSER_H diff --git a/src/libs/extensionsystem/plugindetailsview.cpp b/src/libs/extensionsystem/plugindetailsview.cpp index 349cc48a12a0df33ffa1c0cb3415e0bb7071263a..47de68db2f49001a37839b90a48da1bafc708430 100644 --- a/src/libs/extensionsystem/plugindetailsview.cpp +++ b/src/libs/extensionsystem/plugindetailsview.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugindetailsview.h" #include "ui_plugindetailsview.h" diff --git a/src/libs/extensionsystem/plugindetailsview.h b/src/libs/extensionsystem/plugindetailsview.h index 99386f29d0fc2e76ce639ff506ce68ba08d248d4..2e641117314a12c99fd28bbc1508134fc8224b85 100644 --- a/src/libs/extensionsystem/plugindetailsview.h +++ b/src/libs/extensionsystem/plugindetailsview.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGINDETAILSVIEW_H_ #define PLUGINDETAILSVIEW_H_ @@ -38,8 +39,7 @@ #include <QtGui/QWidget> -namespace ExtensionSystem -{ +namespace ExtensionSystem { namespace Internal { namespace Ui { diff --git a/src/libs/extensionsystem/pluginerrorview.cpp b/src/libs/extensionsystem/pluginerrorview.cpp index c1572d88299b42a22e9063ce1947b71e47e9ce4a..820d4b7cfc932d3661117369dd5ea0285f9ffecb 100644 --- a/src/libs/extensionsystem/pluginerrorview.cpp +++ b/src/libs/extensionsystem/pluginerrorview.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "pluginerrorview.h" #include "ui_pluginerrorview.h" diff --git a/src/libs/extensionsystem/pluginerrorview.h b/src/libs/extensionsystem/pluginerrorview.h index 87b4097d033f09101c5739df7ba752db7576c626..f8e3beca9c7fe92feea9e9cd5c3025f10c5f4894 100644 --- a/src/libs/extensionsystem/pluginerrorview.h +++ b/src/libs/extensionsystem/pluginerrorview.h @@ -30,16 +30,16 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -#ifndef PLUGINERRORVIEW_H_ -#define PLUGINERRORVIEW_H_ + +#ifndef PLUGINERRORVIEW_H +#define PLUGINERRORVIEW_H #include "extensionsystem_global.h" #include "pluginspec.h" #include <QtGui/QWidget> -namespace ExtensionSystem -{ +namespace ExtensionSystem { namespace Internal { namespace Ui { @@ -63,4 +63,4 @@ private: } // namespace ExtensionSystem -#endif /*PLUGINERRORVIEW_H_*/ +#endif // PLUGINERRORVIEW_H diff --git a/src/libs/extensionsystem/pluginmanager.cpp b/src/libs/extensionsystem/pluginmanager.cpp index daf4169a80a5fb2a14be467b18825d94ae0e4d81..802c56b6936a6ab8434a5f996faae36d5e7354e4 100644 --- a/src/libs/extensionsystem/pluginmanager.cpp +++ b/src/libs/extensionsystem/pluginmanager.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "pluginmanager.h" #include "pluginmanager_p.h" #include "pluginspec.h" diff --git a/src/libs/extensionsystem/pluginmanager.h b/src/libs/extensionsystem/pluginmanager.h index 7f003b4f89985a47a1f03fb8aaa2010e42a3211d..85ac5e69dd0d5c9ddd8b7c66a90c7f36d7ab7d54 100644 --- a/src/libs/extensionsystem/pluginmanager.h +++ b/src/libs/extensionsystem/pluginmanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef EXTENSIONSYSTEM_PLUGINMANAGER_H #define EXTENSIONSYSTEM_PLUGINMANAGER_H @@ -133,6 +134,6 @@ private: friend class Internal::PluginManagerPrivate; }; -} //namespace +} // namespace ExtensionSystem -#endif // PLUGINMANAGER_H +#endif // EXTENSIONSYSTEM_PLUGINMANAGER_H diff --git a/src/libs/extensionsystem/pluginmanager_p.h b/src/libs/extensionsystem/pluginmanager_p.h index 6b8df8d2bee5a4932ec4b761b1b19dfaa0038d97..28ba1ee85801170b305f7dff52f5a0da28d39cfa 100644 --- a/src/libs/extensionsystem/pluginmanager_p.h +++ b/src/libs/extensionsystem/pluginmanager_p.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGINMANAGER_P_H #define PLUGINMANAGER_P_H diff --git a/src/libs/extensionsystem/pluginspec.cpp b/src/libs/extensionsystem/pluginspec.cpp index dfa7bdbe7c0a764b1d0103cc98b49df1660e73b3..91f10d6c1daba9d4991e3dc7cb1a865334275c9f 100644 --- a/src/libs/extensionsystem/pluginspec.cpp +++ b/src/libs/extensionsystem/pluginspec.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "pluginspec.h" #include "pluginspec.h" #include "pluginspec_p.h" diff --git a/src/libs/extensionsystem/pluginspec.h b/src/libs/extensionsystem/pluginspec.h index 06a219fe2d4418cd604a04180ea53225030784e5..53f08cef49d779f90c4539a64a5bf9a93de9d175 100644 --- a/src/libs/extensionsystem/pluginspec.h +++ b/src/libs/extensionsystem/pluginspec.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGINSPEC_H #define PLUGINSPEC_H diff --git a/src/libs/extensionsystem/pluginspec_p.h b/src/libs/extensionsystem/pluginspec_p.h index a11167e85e277e64a586fa8e6edf595ca5de3c3d..1ecd70bb95ec9947ca8ecba6a6169e0742cbbd78 100644 --- a/src/libs/extensionsystem/pluginspec_p.h +++ b/src/libs/extensionsystem/pluginspec_p.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGINSPEC_P_H #define PLUGINSPEC_P_H @@ -103,4 +104,4 @@ private: } // namespace Internal } // namespace ExtensionSystem -#endif // header guard +#endif // PLUGINSPEC_P_H diff --git a/src/libs/extensionsystem/pluginview.cpp b/src/libs/extensionsystem/pluginview.cpp index d75911ea37dbc7a2794db89d248f3da0d42f6707..f1b3a97a7f23ddd8aed4ac788798afa5dc2de11f 100644 --- a/src/libs/extensionsystem/pluginview.cpp +++ b/src/libs/extensionsystem/pluginview.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "pluginview.h" #include "pluginview_p.h" #include "pluginmanager.h" diff --git a/src/libs/extensionsystem/pluginview.h b/src/libs/extensionsystem/pluginview.h index eacf38edaa513cb2402928dd8431a1e8a7ee5c07..77245c2ad4e23609cba25f42a62d7105274fb511 100644 --- a/src/libs/extensionsystem/pluginview.h +++ b/src/libs/extensionsystem/pluginview.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGINVIEW_H #define PLUGINVIEW_H @@ -79,4 +80,4 @@ private: } // namespae ExtensionSystem -#endif +#endif // PLUGIN_VIEW_H diff --git a/src/libs/extensionsystem/pluginview_p.h b/src/libs/extensionsystem/pluginview_p.h index 48d63ba35937a06335f669ee2fcafa7226a01a73..adca251d3bfe49c9269302467d13013a0fadc1b8 100644 --- a/src/libs/extensionsystem/pluginview_p.h +++ b/src/libs/extensionsystem/pluginview_p.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGINVIEW_P_H #define PLUGINVIEW_P_H @@ -45,7 +46,7 @@ public: PluginManager *manager; }; -} // namespace -} // namespace +} // namespace Internal +} // namespace ExtensionSystem -#endif +#endif PLUGINVIEW_P_H diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin1/plugin1.cpp b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin1/plugin1.cpp index 69b9821b3b1457c39d9515e6d2f995009b65271a..7c93c49b6ffc8a2aa274b0b5b4922c2cc0e10d9a 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin1/plugin1.cpp +++ b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin1/plugin1.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugin1.h" #include <QtCore/qplugin.h> @@ -40,8 +41,10 @@ MyPlugin1::MyPlugin1() { } -bool MyPlugin1::initialize(const QStringList & /*arguments*/, QString *errorString) +bool MyPlugin1::initialize(const QStringList &arguments, QString *errorString) { + Q_UNUSED(arguments); + Q_UNUSED(errorString); return true; } diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin1/plugin1.h b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin1/plugin1.h index d3c493aebaa41531fa7fbc1746c6aa995f083bd4..27f63a72b19a3397e38f5ec3c731d8f6c15694d7 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin1/plugin1.h +++ b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin1/plugin1.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGIN1_H #define PLUGIN1_H @@ -50,6 +51,6 @@ public: void extensionsInitialized(); }; -} // namespace +} // namespace Plugin1 -#endif // header guard +#endif // PLUGIN1_H diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin2/plugin2.cpp b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin2/plugin2.cpp index c5af5f39a35f9fe2f45ff34738eb881c0baccf80..7c230d4ab0d1a861c868abc396f1c4a4bd3235e3 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin2/plugin2.cpp +++ b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin2/plugin2.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugin2.h" #include <QtCore/qplugin.h> diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin2/plugin2.h b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin2/plugin2.h index b1cd95c7627d6e13908247a40dc463561c72f6e9..e95cf049e08e87662e68a4437b8aa457c23da9aa 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin2/plugin2.h +++ b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin2/plugin2.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGIN2_H #define PLUGIN2_H @@ -50,6 +51,6 @@ public: void extensionsInitialized(); }; -} // namespace +} // Plugin2 -#endif // header guard +#endif // PLUGIN2_H diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin3/plugin3.h b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin3/plugin3.h index 7514d63bd71751bfa7a6c94cbd7a05dbcdff5ab9..06d81410d6302c80bd0fb94b4cccf404ce142159 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin3/plugin3.h +++ b/src/libs/extensionsystem/test/auto/pluginmanager/circularplugins/plugin3/plugin3.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGIN3_H #define PLUGIN3_H @@ -50,6 +51,6 @@ public: void extensionsInitialized(); }; -} // namespace +} // namespace Plugin3 -#endif // header guard +#endif // PLUGIN3_H diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin1/plugin1.cpp b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin1/plugin1.cpp index 8149d046d21498d3234bb2a549fb1b29f1b8752a..2747a051e06d634ad9b41989e065eae920cd5f3d 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin1/plugin1.cpp +++ b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin1/plugin1.cpp @@ -28,8 +28,9 @@ ** In addition, as a special exception, Nokia gives you certain additional ** rights. These rights are described in the Nokia Qt GPL Exception version ** 1.2, included in the file GPL_EXCEPTION.txt in this package. -** +** ***************************************************************************/ + #include "plugin1.h" #include <extensionsystem/pluginmanager.h> diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin1/plugin1.h b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin1/plugin1.h index 4be9f9bbf7fcc948e7987bd47b4b7eca2011594a..72baefe0bbc4353d813542fd965775450810f28c 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin1/plugin1.h +++ b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin1/plugin1.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGIN1_H #define PLUGIN1_H @@ -53,6 +54,6 @@ private: bool initializeCalled; }; -} // namespace +} // namespace Plugin1 -#endif // header guard +#endif // PLUGIN1_H diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin2/plugin2.cpp b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin2/plugin2.cpp index 99f192766a4de243ab3de278d67272cc52f37a40..2cbf925f99a1593d2f0f7fff57a12410c4d6d3e9 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin2/plugin2.cpp +++ b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin2/plugin2.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugin2.h" #include <extensionsystem/pluginmanager.h> diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin2/plugin2.h b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin2/plugin2.h index 08d77a38c704bdde74ae9bd6295c3b2a41ada3c4..029e38fb350e1bb60499a72f161b3ce46c6811fc 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin2/plugin2.h +++ b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin2/plugin2.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGIN2_H #define PLUGIN2_H @@ -53,6 +54,6 @@ private: bool initializeCalled; }; -} // namespace +} // namespace Plugin2 -#endif // header guard +#endif // PLUGIN2_H diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin3/plugin3.cpp b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin3/plugin3.cpp index 4410c34511349774d3f042870500a57ac22d4f54..c3c49fd62b3a64e49a7c581898dc73c21dccfabd 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin3/plugin3.cpp +++ b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin3/plugin3.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugin3.h" #include <extensionsystem/pluginmanager.h> @@ -74,4 +75,3 @@ void MyPlugin3::extensionsInitialized() } Q_EXPORT_PLUGIN(MyPlugin3) - diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin3/plugin3.h b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin3/plugin3.h index 0991b7a152657ffda1ae10e1395058f62447e88b..dbd43db2614afae264c2df3e9be048f965f14579 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin3/plugin3.h +++ b/src/libs/extensionsystem/test/auto/pluginmanager/correctplugins1/plugin3/plugin3.h @@ -53,6 +53,6 @@ private: bool initializeCalled; }; -} // namespace +} // namespace Plugin3 -#endif // header guard +#endif // PLUGIN3_H diff --git a/src/libs/extensionsystem/test/auto/pluginmanager/tst_pluginmanager.cpp b/src/libs/extensionsystem/test/auto/pluginmanager/tst_pluginmanager.cpp index f54b978e9af77a5b3ca3a31ac2e77ab28a16d92f..e693749430b9bd8b6719b384fc7ac1648fc8231f 100644 --- a/src/libs/extensionsystem/test/auto/pluginmanager/tst_pluginmanager.cpp +++ b/src/libs/extensionsystem/test/auto/pluginmanager/tst_pluginmanager.cpp @@ -30,14 +30,15 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -#include <QtTest/QtTest> - -#include <QtCore/QObject> #include <extensionsystem/pluginmanager.h> #include <extensionsystem/pluginspec.h> #include <extensionsystem/iplugin.h> +#include <QtTest/QtTest> + +#include <QtCore/QObject> + using namespace ExtensionSystem; class SignalReceiver; @@ -263,5 +264,6 @@ void tst_PluginManager::correctPlugins1() } QTEST_MAIN(tst_PluginManager) + #include "tst_pluginmanager.moc" diff --git a/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin.cpp b/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin.cpp index 8c3db6c189557517555bf9c8da2832270e52d378..639bd33b61cfc5bd02730ce7d29099167a931029 100644 --- a/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin.cpp +++ b/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "testplugin.h" #include <QtCore/qplugin.h> diff --git a/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin.h b/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin.h index 10fc0acf508d2120ed93bffe5539c4555c45e886..1029e211096702d47c5f57e39a271e856cc1c360 100644 --- a/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin.h +++ b/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef TESTPLUGIN_H #define TESTPLUGIN_H @@ -59,4 +60,4 @@ private: } // namespace -#endif // header guard +#endif // TESTPLUGIN_H diff --git a/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin_global.h b/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin_global.h index ae40ac8ea8bd7e15a4cd76afe81e0fd7c8469888..be5ae3bc458bc92f053113b2fae08d084ce7a0c0 100644 --- a/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin_global.h +++ b/src/libs/extensionsystem/test/auto/pluginspec/testplugin/testplugin_global.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef TESTPLUGIN_GLOBAL_H #define TESTPLUGIN_GLOBAL_H @@ -41,4 +42,4 @@ # define MYPLUGIN_EXPORT Q_DECL_IMPORT #endif -#endif // header +#endif // TESTPLUGIN_GLOBAL_H diff --git a/src/libs/extensionsystem/test/auto/pluginspec/tst_pluginspec.cpp b/src/libs/extensionsystem/test/auto/pluginspec/tst_pluginspec.cpp index f3471edcaac2ec70b2d9e8a57183f743e1c750c5..1e59535d57ad97ec81a11c4af7b9191a026efca2 100644 --- a/src/libs/extensionsystem/test/auto/pluginspec/tst_pluginspec.cpp +++ b/src/libs/extensionsystem/test/auto/pluginspec/tst_pluginspec.cpp @@ -30,7 +30,6 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -#include <QtTest/QtTest> #include "testplugin/testplugin.h" @@ -40,6 +39,7 @@ #include <extensionsystem/pluginmanager.h> #include <QtCore/QObject> +#include <QtTest/QtTest> using namespace ExtensionSystem; @@ -275,4 +275,5 @@ void tst_PluginSpec::initializeExtensions() } QTEST_MAIN(tst_PluginSpec) + #include "tst_pluginspec.moc" diff --git a/src/libs/extensionsystem/test/manual/pluginview/plugindialog.cpp b/src/libs/extensionsystem/test/manual/pluginview/plugindialog.cpp index 3282d9862e7b689ffe52399a65a5c0fa6abba6a5..bced61f40ce039d345a69e2ae4d5386fbecbe5db 100644 --- a/src/libs/extensionsystem/test/manual/pluginview/plugindialog.cpp +++ b/src/libs/extensionsystem/test/manual/pluginview/plugindialog.cpp @@ -30,7 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugindialog.h" + #include <extensionsystem/plugindetailsview.h> #include <extensionsystem/pluginerrorview.h> #include <extensionsystem/pluginspec.h> @@ -139,4 +141,3 @@ int main(int argc, char *argv[]) dialog.show(); app.exec(); } - diff --git a/src/libs/extensionsystem/test/manual/pluginview/plugindialog.h b/src/libs/extensionsystem/test/manual/pluginview/plugindialog.h index 8987230681a9f4dd345187de034ade39958bc9cc..89ab9fcc7a7db2a3879c94b4f173a87dfb4c4e57 100644 --- a/src/libs/extensionsystem/test/manual/pluginview/plugindialog.h +++ b/src/libs/extensionsystem/test/manual/pluginview/plugindialog.h @@ -30,11 +30,13 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGINDIALOG_H #define PLUGINDIALOG_H #include <extensionsystem/pluginview.h> #include <extensionsystem/pluginmanager.h> + #include <QtGui/QWidget> #include <QtGui/QPushButton> @@ -58,4 +60,4 @@ private: QPushButton *m_errorDetailsButton; }; -#endif +#endif // PLUGINDIALOG_H diff --git a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin1/plugin1.cpp b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin1/plugin1.cpp index 32d3bdf07013a4d68d1b6eda81f53b5816c3bcc7..88704e9bc04f67b58cae87cb13f1d6f9d274c1cc 100644 --- a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin1/plugin1.cpp +++ b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin1/plugin1.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugin1.h" #include <extensionsystem/pluginmanager.h> @@ -83,4 +84,3 @@ void MyPlugin1::extensionsInitialized() } Q_EXPORT_PLUGIN(MyPlugin1) - diff --git a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin1/plugin1.h b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin1/plugin1.h index f993b25c9f2c76d3e5902be5be38a39cceca7340..28440c27335ec5336e8242fde7c9a7edfe847625 100644 --- a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin1/plugin1.h +++ b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin1/plugin1.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGIN1_H #define PLUGIN1_H @@ -54,6 +55,6 @@ private: bool initializeCalled; }; -} // namespace +} // namespace Plugin1 -#endif // header guard +#endif // PLUGIN1_H diff --git a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin2/plugin2.cpp b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin2/plugin2.cpp index 3ce6f258fa8bd3a2768300b5afe21c575a6bc205..d48f717e1db071844e2b686da49dff9afabb5739 100644 --- a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin2/plugin2.cpp +++ b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin2/plugin2.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugin2.h" #include <extensionsystem/pluginmanager.h> @@ -66,4 +67,3 @@ void MyPlugin2::extensionsInitialized() } Q_EXPORT_PLUGIN(MyPlugin2) - diff --git a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin2/plugin2.h b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin2/plugin2.h index 51200387546522af483efa913bd84eefb9090f77..d65d7f69998a2581e26b9fb5b336b2e378f8c7d8 100644 --- a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin2/plugin2.h +++ b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin2/plugin2.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGIN2_H #define PLUGIN2_H @@ -54,6 +55,6 @@ private: bool initializeCalled; }; -} // namespace +} // namespace Plugin2 -#endif // header guard +#endif // PLUGIN2_H diff --git a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin3/plugin3.cpp b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin3/plugin3.cpp index ff37d06096ddd71e0e7188938d95be8325227036..9f1da813b570babf64a196be93c8cdc759676d7f 100644 --- a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin3/plugin3.cpp +++ b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin3/plugin3.cpp @@ -28,8 +28,9 @@ ** In addition, as a special exception, Nokia gives you certain additional ** rights. These rights are described in the Nokia Qt GPL Exception version ** 1.2, included in the file GPL_EXCEPTION.txt in this package. -** +** ***************************************************************************/ + #include "plugin3.h" #include <extensionsystem/pluginmanager.h> @@ -74,4 +75,3 @@ void MyPlugin3::extensionsInitialized() } Q_EXPORT_PLUGIN(MyPlugin3) - diff --git a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin3/plugin3.h b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin3/plugin3.h index 00bd6429125ec20f3d92dd29a93d2cb68f8a12c1..19666f89a72d9e2624d4fea5ab29a4972e9b7d25 100644 --- a/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin3/plugin3.h +++ b/src/libs/extensionsystem/test/manual/pluginview/plugins/plugin3/plugin3.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGIN3_H #define PLUGIN3_H @@ -54,6 +55,6 @@ private: bool initializeCalled; }; -} // namespace +} // namespace Plugin3 -#endif // header guard +#endif // PLUGIN3_H diff --git a/src/libs/qtconcurrent/multitask.h b/src/libs/qtconcurrent/multitask.h index fc66de1715e5ab3416f6bbbccbe9a5fd202e6879..889753533b91f95eed13a36d32d68b1fbb73df98 100644 --- a/src/libs/qtconcurrent/multitask.h +++ b/src/libs/qtconcurrent/multitask.h @@ -30,11 +30,13 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MULTITASK_H #define MULTITASK_H #include "qtconcurrent_global.h" #include "runextensions.h" + #include <QtCore/QObject> #include <QtCore/QList> #include <QtCore/QEventLoop> @@ -184,14 +186,15 @@ private: }; template <typename Class, typename T> -QFuture<T> run(void (Class::*fn)(QFutureInterface<T> &), const QList<Class *> &objects, int priority = 0) { +QFuture<T> run(void (Class::*fn)(QFutureInterface<T> &), const QList<Class *> &objects, int priority = 0) +{ MultiTask<Class, T> *task = new MultiTask<Class, T>(fn, objects); QFuture<T> future = task->future(); QThreadPool::globalInstance()->start(task, priority); return future; } -} //namespace +} // namespace QtConcurrent QT_END_NAMESPACE diff --git a/src/libs/qtconcurrent/qtconcurrent_global.h b/src/libs/qtconcurrent/qtconcurrent_global.h index 15d47af5f3a8706cab3a7ff35140662fe7f8f9b8..0a5a109d4ec5732094b6c93cd59d8cb2bdab65fc 100644 --- a/src/libs/qtconcurrent/qtconcurrent_global.h +++ b/src/libs/qtconcurrent/qtconcurrent_global.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef QTCONCURRENT_GLOBAL_H #define QTCONCURRENT_GLOBAL_H diff --git a/src/libs/qtconcurrent/runextensions.h b/src/libs/qtconcurrent/runextensions.h index 43707c14d5d18adce026629c0483cc5efd51820d..c17153131b7a7ea114eae934abc391c5d6433bf5 100644 --- a/src/libs/qtconcurrent/runextensions.h +++ b/src/libs/qtconcurrent/runextensions.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef QTCONCURRENT_RUNEX_H #define QTCONCURRENT_RUNEX_H @@ -390,8 +391,8 @@ QFuture<T> run(void (Class::*fn)(QFutureInterface<T> &), Class *object) return (new StoredInterfaceMemberFunctionCall0<T, void (Class::*)(QFutureInterface<T> &), Class>(fn, object))->start(); } -} //namespace QtConcurrent +} // namespace QtConcurrent QT_END_NAMESPACE -#endif +#endif // QTCONCURRENT_RUNEX_H diff --git a/src/libs/utils/basevalidatinglineedit.cpp b/src/libs/utils/basevalidatinglineedit.cpp index cb936e3c2d2b0cb125fb5f4b6e2119cbbfd977c4..fb09d95745a3f786712cb8c9b610a865b48aaf81 100644 --- a/src/libs/utils/basevalidatinglineedit.cpp +++ b/src/libs/utils/basevalidatinglineedit.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "basevalidatinglineedit.h" #include <QtCore/QDebug> @@ -153,5 +154,5 @@ void BaseValidatingLineEdit::slotReturnPressed() emit validReturnPressed(); } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/basevalidatinglineedit.h b/src/libs/utils/basevalidatinglineedit.h index 348268701126b609ee4850c187286d5ee8a70753..40b5503819223a189a761201c64b5d8217b08c51 100644 --- a/src/libs/utils/basevalidatinglineedit.h +++ b/src/libs/utils/basevalidatinglineedit.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BASEVALIDATINGLINEEDIT_H #define BASEVALIDATINGLINEEDIT_H @@ -95,6 +96,6 @@ private: BaseValidatingLineEditPrivate *m_bd; }; -} -} +} // namespace Utils +} // namespace Core #endif // BASEVALIDATINGLINEEDIT_H diff --git a/src/libs/utils/classnamevalidatinglineedit.cpp b/src/libs/utils/classnamevalidatinglineedit.cpp index b52758eda5fdb5bd157c5d4701ca2e2a0b8fa9f0..9e36203b0e2221f89073a874300952bd41166e32 100644 --- a/src/libs/utils/classnamevalidatinglineedit.cpp +++ b/src/libs/utils/classnamevalidatinglineedit.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "classnamevalidatinglineedit.h" #include <QtCore/QDebug> @@ -133,5 +134,5 @@ QString ClassNameValidatingLineEdit::createClassName(const QString &name) return className; } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/classnamevalidatinglineedit.h b/src/libs/utils/classnamevalidatinglineedit.h index c0a209d0d71cfc58030d04f536e3e4e19015006e..2271a9cd313ce586a80a9fab5620e03aa5b93eec 100644 --- a/src/libs/utils/classnamevalidatinglineedit.h +++ b/src/libs/utils/classnamevalidatinglineedit.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CLASSNAMEVALIDATINGLINEEDIT_H #define CLASSNAMEVALIDATINGLINEEDIT_H @@ -44,8 +45,9 @@ struct ClassNameValidatingLineEditPrivate; /* A Line edit that validates a C++ class name and emits a signal * to derive suggested file names from it. */ -class QWORKBENCH_UTILS_EXPORT ClassNameValidatingLineEdit : - public Core::Utils::BaseValidatingLineEdit { +class QWORKBENCH_UTILS_EXPORT ClassNameValidatingLineEdit + : public Core::Utils::BaseValidatingLineEdit +{ Q_DISABLE_COPY(ClassNameValidatingLineEdit) Q_PROPERTY(bool namespacesEnabled READ namespacesEnabled WRITE setNamespacesEnabled DESIGNABLE true) Q_OBJECT @@ -73,7 +75,7 @@ private: ClassNameValidatingLineEditPrivate *m_d; }; -} -} +} // namespace Utils +} // namespace Core #endif // CLASSNAMEVALIDATINGLINEEDIT_H diff --git a/src/libs/utils/codegeneration.cpp b/src/libs/utils/codegeneration.cpp index 3af484935a7ec39533e9c076b02dd2a69b1e011f..8956396accf6a57ed6fdb00ec7efa4fcb7685dd2 100644 --- a/src/libs/utils/codegeneration.cpp +++ b/src/libs/utils/codegeneration.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "codegeneration.h" #include <QtCore/QTextStream> diff --git a/src/libs/utils/codegeneration.h b/src/libs/utils/codegeneration.h index 1a20c76d083e83bcae915b2dece75d80b8b6354c..c804365bcea1c4ac105c62d1132c75f87bb4d4ee 100644 --- a/src/libs/utils/codegeneration.h +++ b/src/libs/utils/codegeneration.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CODEGENERATION_H #define CODEGENERATION_H diff --git a/src/libs/utils/fancylineedit.cpp b/src/libs/utils/fancylineedit.cpp index e7e930c544e919d37ee94fae40f83c2151aea4e5..8adb3a5bb4d4165cb904ddaf0284bb11f21dbcf2 100644 --- a/src/libs/utils/fancylineedit.cpp +++ b/src/libs/utils/fancylineedit.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "fancylineedit.h" #include <QtCore/QEvent> diff --git a/src/libs/utils/fancylineedit.h b/src/libs/utils/fancylineedit.h index 24a109eada349f066e2759d441c1a3223cc9b2d7..634eefa8c0d4e8d23737ffe2653ab25f5174969e 100644 --- a/src/libs/utils/fancylineedit.h +++ b/src/libs/utils/fancylineedit.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FANCYLINEEDIT_H #define FANCYLINEEDIT_H @@ -77,11 +78,11 @@ public: bool useLayoutDirection() const; void setUseLayoutDirection(bool v); - /* Set whether tabbing in will trigger the menu. */ + // Set whether tabbing in will trigger the menu. bool hasMenuTabFocusTrigger() const; void setMenuTabFocusTrigger(bool v); - /* Hint text that is displayed when no focus is set */ + // Hint text that is displayed when no focus is set. QString hintText() const; bool isShowingHintText() const; diff --git a/src/libs/utils/filenamevalidatinglineedit.cpp b/src/libs/utils/filenamevalidatinglineedit.cpp index 1beed717efd828a05feb1b174830afada54afc09..388d271795547ee12ce9682e266474de5078854f 100644 --- a/src/libs/utils/filenamevalidatinglineedit.cpp +++ b/src/libs/utils/filenamevalidatinglineedit.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "filenamevalidatinglineedit.h" namespace Core { @@ -93,5 +94,5 @@ bool FileNameValidatingLineEdit::validate(const QString &value, QString *errorM return validateFileName(value, errorMessage); } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/filenamevalidatinglineedit.h b/src/libs/utils/filenamevalidatinglineedit.h index 7535fc196de38aaef5fd675853513bfe47aabe58..c263a94d6cce1e0e457ad3da9489d442ba2b657d 100644 --- a/src/libs/utils/filenamevalidatinglineedit.h +++ b/src/libs/utils/filenamevalidatinglineedit.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FILENAMEVALIDATINGLINEEDIT_H #define FILENAMEVALIDATINGLINEEDIT_H @@ -38,7 +39,8 @@ namespace Core { namespace Utils { -class QWORKBENCH_UTILS_EXPORT FileNameValidatingLineEdit : public BaseValidatingLineEdit { +class QWORKBENCH_UTILS_EXPORT FileNameValidatingLineEdit : public BaseValidatingLineEdit +{ Q_OBJECT Q_DISABLE_COPY(FileNameValidatingLineEdit) @@ -51,6 +53,7 @@ protected: virtual bool validate(const QString &value, QString *errorMessage) const; }; -} -} +} // namespace Utils +} // namespace Core + #endif // FILENAMEVALIDATINGLINEEDIT_H diff --git a/src/libs/utils/filesearch.cpp b/src/libs/utils/filesearch.cpp index 9756984b4b0935e917ed4f2762ec0165b9cc506e..6bcbf26671f08714e28c6059e44f74cf87d97591 100644 --- a/src/libs/utils/filesearch.cpp +++ b/src/libs/utils/filesearch.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "filesearch.h" #include <QtCore/QFile> @@ -44,162 +45,164 @@ using namespace Core::Utils; namespace { - void runFileSearch(QFutureInterface<FileSearchResult> &future, - QString searchTerm, - QStringList files, - QTextDocument::FindFlags flags) - { - future.setProgressRange(0, files.size()); - int numFilesSearched = 0; - int numMatches = 0; - - bool caseInsensitive = !(flags & QTextDocument::FindCaseSensitively); - bool wholeWord = (flags & QTextDocument::FindWholeWords); - - QByteArray sa = searchTerm.toUtf8(); - int scMaxIndex = sa.length()-1; - const char *sc = sa.constData(); - - QByteArray sal = searchTerm.toLower().toUtf8(); - const char *scl = sal.constData(); - - QByteArray sau = searchTerm.toUpper().toUtf8(); - const char *scu = sau.constData(); - - int chunkSize = qMax(100000, sa.length()); - - foreach (QString s, files) { - if (future.isPaused()) - future.waitForResume(); - if (future.isCanceled()) { - future.setProgressValueAndText(numFilesSearched, - qApp->translate("FileSearch", "%1: canceled. %2 occurrences found in %3 files."). - arg(searchTerm).arg(numMatches).arg(numFilesSearched)); - break; - } - QFile file(s); - if (!file.open(QIODevice::ReadOnly)) - continue; - int lineNr = 1; - const char *startOfLastLine = NULL; - - bool firstChunk = true; - while (!file.atEnd()) { - if (!firstChunk) - file.seek(file.pos()-sa.length()+1); - - const QByteArray chunk = file.read(chunkSize); - const char *chunkPtr = chunk.constData(); - startOfLastLine = chunkPtr; - for (const char *regionPtr = chunkPtr; regionPtr < chunkPtr + chunk.length()-scMaxIndex; ++regionPtr) { - const char *regionEnd = regionPtr + scMaxIndex; - - if (*regionPtr == '\n') { - startOfLastLine = regionPtr + 1; - ++lineNr; + +void runFileSearch(QFutureInterface<FileSearchResult> &future, + QString searchTerm, + QStringList files, + QTextDocument::FindFlags flags) +{ + future.setProgressRange(0, files.size()); + int numFilesSearched = 0; + int numMatches = 0; + + bool caseInsensitive = !(flags & QTextDocument::FindCaseSensitively); + bool wholeWord = (flags & QTextDocument::FindWholeWords); + + QByteArray sa = searchTerm.toUtf8(); + int scMaxIndex = sa.length()-1; + const char *sc = sa.constData(); + + QByteArray sal = searchTerm.toLower().toUtf8(); + const char *scl = sal.constData(); + + QByteArray sau = searchTerm.toUpper().toUtf8(); + const char *scu = sau.constData(); + + int chunkSize = qMax(100000, sa.length()); + + foreach (QString s, files) { + if (future.isPaused()) + future.waitForResume(); + if (future.isCanceled()) { + future.setProgressValueAndText(numFilesSearched, + qApp->translate("FileSearch", "%1: canceled. %2 occurrences found in %3 files."). + arg(searchTerm).arg(numMatches).arg(numFilesSearched)); + break; + } + QFile file(s); + if (!file.open(QIODevice::ReadOnly)) + continue; + int lineNr = 1; + const char *startOfLastLine = NULL; + + bool firstChunk = true; + while (!file.atEnd()) { + if (!firstChunk) + file.seek(file.pos()-sa.length()+1); + + const QByteArray chunk = file.read(chunkSize); + const char *chunkPtr = chunk.constData(); + startOfLastLine = chunkPtr; + for (const char *regionPtr = chunkPtr; regionPtr < chunkPtr + chunk.length()-scMaxIndex; ++regionPtr) { + const char *regionEnd = regionPtr + scMaxIndex; + + if (*regionPtr == '\n') { + startOfLastLine = regionPtr + 1; + ++lineNr; + } + else if ( + // case sensitive + (!caseInsensitive && *regionPtr == sc[0] && *regionEnd == sc[scMaxIndex]) + || + // case insensitive + (caseInsensitive && (*regionPtr == scl[0] || *regionPtr == scu[0]) + && (*regionEnd == scl[scMaxIndex] || *regionEnd == scu[scMaxIndex])) + ) { + const char *afterRegion = regionEnd + 1; + const char *beforeRegion = regionPtr - 1; + bool equal = true; + if (wholeWord && + ( ((*beforeRegion >= '0' && *beforeRegion <= '9') || *beforeRegion >= 'A') + || ((*afterRegion >= '0' && *afterRegion <= '9') || *afterRegion >= 'A'))) + { + equal = false; } - else if ( - // case sensitive - (!caseInsensitive && *regionPtr == sc[0] && *regionEnd == sc[scMaxIndex]) - || - // case insensitive - (caseInsensitive && (*regionPtr == scl[0] || *regionPtr == scu[0]) - && (*regionEnd == scl[scMaxIndex] || *regionEnd == scu[scMaxIndex])) - ) { - const char *afterRegion = regionEnd + 1; - const char *beforeRegion = regionPtr - 1; - bool equal = true; - if (wholeWord && - ( ((*beforeRegion >= '0' && *beforeRegion <= '9') || *beforeRegion >= 'A') - || ((*afterRegion >= '0' && *afterRegion <= '9') || *afterRegion >= 'A'))) - { - equal = false; - } - int regionIndex = 1; - for (const char *regionCursor = regionPtr + 1; regionCursor < regionEnd; ++regionCursor, ++regionIndex) { - if ( // case sensitive - (!caseInsensitive && equal && *regionCursor != sc[regionIndex]) - || - // case insensitive - (caseInsensitive && equal && *regionCursor != sc[regionIndex] && *regionCursor != scl[regionIndex] && *regionCursor != scu[regionIndex]) - ) { - equal = false; - } + int regionIndex = 1; + for (const char *regionCursor = regionPtr + 1; regionCursor < regionEnd; ++regionCursor, ++regionIndex) { + if ( // case sensitive + (!caseInsensitive && equal && *regionCursor != sc[regionIndex]) + || + // case insensitive + (caseInsensitive && equal && *regionCursor != sc[regionIndex] && *regionCursor != scl[regionIndex] && *regionCursor != scu[regionIndex]) + ) { + equal = false; } - if (equal) { - int textLength = chunk.length() - (startOfLastLine - chunkPtr); - if (textLength > 0) { - QByteArray res; - res.reserve(256); - int i = 0; - int n = 0; - while (startOfLastLine[i] != '\n' && startOfLastLine[i] != '\r' && i < textLength && n++ < 256) - res.append(startOfLastLine[i++]); - future.reportResult(FileSearchResult(QDir::toNativeSeparators(s), lineNr, QString(res), - regionPtr - startOfLastLine, sa.length())); - ++numMatches; - } + } + if (equal) { + int textLength = chunk.length() - (startOfLastLine - chunkPtr); + if (textLength > 0) { + QByteArray res; + res.reserve(256); + int i = 0; + int n = 0; + while (startOfLastLine[i] != '\n' && startOfLastLine[i] != '\r' && i < textLength && n++ < 256) + res.append(startOfLastLine[i++]); + future.reportResult(FileSearchResult(QDir::toNativeSeparators(s), lineNr, QString(res), + regionPtr - startOfLastLine, sa.length())); + ++numMatches; } } } - firstChunk = false; } - ++numFilesSearched; - future.setProgressValueAndText(numFilesSearched, qApp->translate("FileSearch", "%1: %2 occurrences found in %3 of %4 files."). - arg(searchTerm).arg(numMatches).arg(numFilesSearched).arg(files.size())); + firstChunk = false; } - if (!future.isCanceled()) - future.setProgressValueAndText(numFilesSearched, qApp->translate("FileSearch", "%1: %2 occurrences found in %3 files."). - arg(searchTerm).arg(numMatches).arg(numFilesSearched)); + ++numFilesSearched; + future.setProgressValueAndText(numFilesSearched, qApp->translate("FileSearch", "%1: %2 occurrences found in %3 of %4 files."). + arg(searchTerm).arg(numMatches).arg(numFilesSearched).arg(files.size())); } + if (!future.isCanceled()) + future.setProgressValueAndText(numFilesSearched, qApp->translate("FileSearch", "%1: %2 occurrences found in %3 files."). + arg(searchTerm).arg(numMatches).arg(numFilesSearched)); +} - void runFileSearchRegExp(QFutureInterface<FileSearchResult> &future, - QString searchTerm, - QStringList files, - QTextDocument::FindFlags flags) - { - future.setProgressRange(0, files.size()); - int numFilesSearched = 0; - int numMatches = 0; - if (flags & QTextDocument::FindWholeWords) - searchTerm = QString("\b%1\b").arg(searchTerm); - Qt::CaseSensitivity caseSensitivity = (flags & QTextDocument::FindCaseSensitively) ? Qt::CaseSensitive : Qt::CaseInsensitive; - QRegExp expression(searchTerm, caseSensitivity); - - foreach (QString s, files) { - if (future.isPaused()) - future.waitForResume(); - if (future.isCanceled()) { - future.setProgressValueAndText(numFilesSearched, - qApp->translate("FileSearch", "%1: canceled. %2 occurrences found in %3 files."). - arg(searchTerm).arg(numMatches).arg(numFilesSearched)); - break; - } - QFile file(s); - if (!file.open(QIODevice::ReadOnly)) - continue; - QTextStream stream(&file); - int lineNr = 1; - QString line; - while (!stream.atEnd()) { - line = stream.readLine(); - int pos = 0; - while ((pos = expression.indexIn(line, pos)) != -1) { - future.reportResult(FileSearchResult(QDir::toNativeSeparators(s), lineNr, line, - pos, expression.matchedLength())); - pos += expression.matchedLength(); - } - ++lineNr; +void runFileSearchRegExp(QFutureInterface<FileSearchResult> &future, + QString searchTerm, + QStringList files, + QTextDocument::FindFlags flags) +{ + future.setProgressRange(0, files.size()); + int numFilesSearched = 0; + int numMatches = 0; + if (flags & QTextDocument::FindWholeWords) + searchTerm = QString("\b%1\b").arg(searchTerm); + Qt::CaseSensitivity caseSensitivity = (flags & QTextDocument::FindCaseSensitively) ? Qt::CaseSensitive : Qt::CaseInsensitive; + QRegExp expression(searchTerm, caseSensitivity); + + foreach (QString s, files) { + if (future.isPaused()) + future.waitForResume(); + if (future.isCanceled()) { + future.setProgressValueAndText(numFilesSearched, + qApp->translate("FileSearch", "%1: canceled. %2 occurrences found in %3 files."). + arg(searchTerm).arg(numMatches).arg(numFilesSearched)); + break; + } + QFile file(s); + if (!file.open(QIODevice::ReadOnly)) + continue; + QTextStream stream(&file); + int lineNr = 1; + QString line; + while (!stream.atEnd()) { + line = stream.readLine(); + int pos = 0; + while ((pos = expression.indexIn(line, pos)) != -1) { + future.reportResult(FileSearchResult(QDir::toNativeSeparators(s), lineNr, line, + pos, expression.matchedLength())); + pos += expression.matchedLength(); } - ++numFilesSearched; - future.setProgressValueAndText(numFilesSearched, qApp->translate("FileSearch", "%1: %2 occurrences found in %3 of %4 files."). - arg(searchTerm).arg(numMatches).arg(numFilesSearched).arg(files.size())); + ++lineNr; } - if (!future.isCanceled()) - future.setProgressValueAndText(numFilesSearched, qApp->translate("FileSearch", "%1: %2 occurrences found in %3 files."). - arg(searchTerm).arg(numMatches).arg(numFilesSearched)); + ++numFilesSearched; + future.setProgressValueAndText(numFilesSearched, qApp->translate("FileSearch", "%1: %2 occurrences found in %3 of %4 files."). + arg(searchTerm).arg(numMatches).arg(numFilesSearched).arg(files.size())); } + if (!future.isCanceled()) + future.setProgressValueAndText(numFilesSearched, qApp->translate("FileSearch", "%1: %2 occurrences found in %3 files."). + arg(searchTerm).arg(numMatches).arg(numFilesSearched)); +} + } // namespace diff --git a/src/libs/utils/filesearch.h b/src/libs/utils/filesearch.h index 3b747fb54897cea75a3e4c01d1c1264685b9478e..4f6d260286b235b67f2a92833a5563797f580ded 100644 --- a/src/libs/utils/filesearch.h +++ b/src/libs/utils/filesearch.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FILESEARCH_H #define FILESEARCH_H @@ -63,7 +64,7 @@ QWORKBENCH_UTILS_EXPORT QFuture<FileSearchResult> findInFiles(const QString &sea QWORKBENCH_UTILS_EXPORT QFuture<FileSearchResult> findInFilesRegExp(const QString &searchTerm, const QStringList &files, QTextDocument::FindFlags flags); -} //Utils -} //Core +} // namespace Utils +} // namespace Core -#endif +#endif // FILESEARCH_H diff --git a/src/libs/utils/filewizarddialog.cpp b/src/libs/utils/filewizarddialog.cpp index 2843a304e5b5267a94e1cd8f27f2b3e39bffc56f..d9454c52a129e3e111baf3c102232280dff1914f 100644 --- a/src/libs/utils/filewizarddialog.cpp +++ b/src/libs/utils/filewizarddialog.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "filewizarddialog.h" #include "filewizardpage.h" diff --git a/src/libs/utils/filewizarddialog.h b/src/libs/utils/filewizarddialog.h index 6a4a7d9ba6f536cda9cb5dc4cab4e24b8c3d0286..20dd98e350a5c95c326fa1fa93b1c67f4d6d9f09 100644 --- a/src/libs/utils/filewizarddialog.h +++ b/src/libs/utils/filewizarddialog.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FILEWIZARDDIALOG_H #define FILEWIZARDDIALOG_H @@ -64,6 +65,7 @@ private: FileWizardPage *m_filePage; }; -} -} +} // namespace Utils +} // namespace Core + #endif // FILEWIZARDDIALOG_H diff --git a/src/libs/utils/filewizardpage.cpp b/src/libs/utils/filewizardpage.cpp index a448ebe7395f203f0f1bd68ecc7651edf42168e4..a796f7bafde26c777bbecc7f5d26cbfbed372dca 100644 --- a/src/libs/utils/filewizardpage.cpp +++ b/src/libs/utils/filewizardpage.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "filewizardpage.h" #include "ui_filewizardpage.h" diff --git a/src/libs/utils/filewizardpage.h b/src/libs/utils/filewizardpage.h index b2ae28a9d0d5efe3809ee1c30b43a2363262beb3..984b10b5da2acceecaa607167c0fdfdb22727dbd 100644 --- a/src/libs/utils/filewizardpage.h +++ b/src/libs/utils/filewizardpage.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FILEWIZARDPAGE_H #define FILEWIZARDPAGE_H @@ -81,6 +82,7 @@ private: FileWizardPagePrivate *m_d; }; -} -} +} // namespace Utils +} // namespace Core + #endif // FILEWIZARDPAGE_H diff --git a/src/libs/utils/linecolumnlabel.cpp b/src/libs/utils/linecolumnlabel.cpp index c6028ab13ff46817a7e8e82d31210fa75e546ba7..3a25c36f9628b07008245a63952dea8b23f3dd67 100644 --- a/src/libs/utils/linecolumnlabel.cpp +++ b/src/libs/utils/linecolumnlabel.cpp @@ -30,14 +30,14 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "linecolumnlabel.h" namespace Core { namespace Utils { -LineColumnLabel::LineColumnLabel(QWidget *parent) : - QLabel(parent), - m_unused(0) +LineColumnLabel::LineColumnLabel(QWidget *parent) + : QLabel(parent), m_unused(0) { } @@ -65,5 +65,5 @@ void LineColumnLabel::setMaxText(const QString &maxText) m_maxText = maxText; } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/linecolumnlabel.h b/src/libs/utils/linecolumnlabel.h index d5dea084cc2700b75d1cb0da12ebd1fcaca911b8..ba7f9e4078ac7bde89d340c2c1765bcfbc4afd94 100644 --- a/src/libs/utils/linecolumnlabel.h +++ b/src/libs/utils/linecolumnlabel.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef LINECOLUMNLABEL_H #define LINECOLUMNLABEL_H @@ -42,7 +43,8 @@ namespace Utils { /* A label suitable for displaying cursor positions, etc. with a fixed * with derived from a sample text. */ -class QWORKBENCH_UTILS_EXPORT LineColumnLabel : public QLabel { +class QWORKBENCH_UTILS_EXPORT LineColumnLabel : public QLabel +{ Q_DISABLE_COPY(LineColumnLabel) Q_OBJECT Q_PROPERTY(QString maxText READ maxText WRITE setMaxText DESIGNABLE true) @@ -62,7 +64,7 @@ private: void *m_unused; }; -} -} +} // namespace Utils +} // namespace Core #endif // LINECOLUMNLABEL_H diff --git a/src/libs/utils/listutils.h b/src/libs/utils/listutils.h index 3b688f336dfc33194f981d3cc5454cadec225a3a..cbd307937ded90abb0b9ff7290bb5a15d64165b0 100644 --- a/src/libs/utils/listutils.h +++ b/src/libs/utils/listutils.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef LISTUTILS_H #define LISTUTILS_H @@ -48,7 +49,7 @@ QList<T1> qwConvertList(const QList<T2> &list) return convertedList; } -} // Utils -} // Core +} // namespace Utils +} // namespace Core #endif // LISTUTILS_H diff --git a/src/libs/utils/newclasswidget.cpp b/src/libs/utils/newclasswidget.cpp index 67cd1f8691d9d03f25a973ce428ef890f800edd2..1224ba32701f6c768bd6781ef23dda8571419b7e 100644 --- a/src/libs/utils/newclasswidget.cpp +++ b/src/libs/utils/newclasswidget.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "newclasswidget.h" #include "ui_newclasswidget.h" @@ -457,6 +458,5 @@ QStringList NewClassWidget::files() const return rc; } - } // namespace Utils } // namespace Core diff --git a/src/libs/utils/newclasswidget.h b/src/libs/utils/newclasswidget.h index e534189d7756b8d948e71a31cef94d065bdfc290..138f7bc9af8550ba6c89f035a8db7650677c6bd2 100644 --- a/src/libs/utils/newclasswidget.h +++ b/src/libs/utils/newclasswidget.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef NEWCLASSWIDGET_H #define NEWCLASSWIDGET_H diff --git a/src/libs/utils/pathchooser.cpp b/src/libs/utils/pathchooser.cpp index 188aa3b126ba1f6e0155e09631280a71ce96e659..16d26b0f5625aeca3648a40c9c669b9db2a46c52 100644 --- a/src/libs/utils/pathchooser.cpp +++ b/src/libs/utils/pathchooser.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "pathchooser.h" #include "basevalidatinglineedit.h" @@ -181,5 +182,5 @@ QString PathChooser::homePath() #endif } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/pathchooser.h b/src/libs/utils/pathchooser.h index e09040c4c06b8405f6c6f4bdd0c044ada9ab3449..d8b33077badeab4ee8a5f6e2f25a5012f21b590c 100644 --- a/src/libs/utils/pathchooser.h +++ b/src/libs/utils/pathchooser.h @@ -84,7 +84,7 @@ private: PathChooserPrivate *m_d; }; -} -} +} // namespace Utils +} // namespace Core #endif // PATHCHOOSER_H diff --git a/src/libs/utils/projectintropage.cpp b/src/libs/utils/projectintropage.cpp index bc17333fb97712e16bc02eb36c5c89ff87f17e63..4e9dd365a80a13f135e3035b00321aeced16cd2d 100644 --- a/src/libs/utils/projectintropage.cpp +++ b/src/libs/utils/projectintropage.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "projectintropage.h" #include "filewizardpage.h" #include "ui_projectintropage.h" @@ -211,5 +212,5 @@ void ProjectIntroPage::hideStatusLabel() displayStatusMessage(Hint, QString()); } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/projectintropage.h b/src/libs/utils/projectintropage.h index 56dcc2532725837d29292a3cf6ffe06f3f3bf77f..a145590dfd146b78465fd8f697323fc79ab8ecd6 100644 --- a/src/libs/utils/projectintropage.h +++ b/src/libs/utils/projectintropage.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PROJECTINTROPAGE_H #define PROJECTINTROPAGE_H @@ -55,7 +56,8 @@ struct ProjectIntroPagePrivate; * layout, otherwise, QWizard will squeeze it due to its strange expanding * hacks. */ -class QWORKBENCH_UTILS_EXPORT ProjectIntroPage : public QWizardPage { +class QWORKBENCH_UTILS_EXPORT ProjectIntroPage : public QWizardPage +{ Q_OBJECT Q_DISABLE_COPY(ProjectIntroPage) Q_PROPERTY(QString description READ description WRITE setPath DESIGNABLE true) @@ -102,6 +104,7 @@ private: ProjectIntroPagePrivate *m_d; }; -} -} +} // namespace Utils +} // namespace Core + #endif // PROJECTINTROPAGE_H diff --git a/src/libs/utils/projectnamevalidatinglineedit.cpp b/src/libs/utils/projectnamevalidatinglineedit.cpp index fb979d39345155a6865e71dd539e4eae6b39cb70..b6c1ccd505a3419ec6713266d5b30730b33a36b5 100644 --- a/src/libs/utils/projectnamevalidatinglineedit.cpp +++ b/src/libs/utils/projectnamevalidatinglineedit.cpp @@ -30,14 +30,15 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "projectnamevalidatinglineedit.h" #include "filenamevalidatinglineedit.h" namespace Core { namespace Utils { -ProjectNameValidatingLineEdit::ProjectNameValidatingLineEdit(QWidget *parent) : - BaseValidatingLineEdit(parent) +ProjectNameValidatingLineEdit::ProjectNameValidatingLineEdit(QWidget *parent) + : BaseValidatingLineEdit(parent) { } @@ -62,5 +63,5 @@ bool ProjectNameValidatingLineEdit::validate(const QString &value, QString *erro return validateProjectName(value, errorMessage); } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/projectnamevalidatinglineedit.h b/src/libs/utils/projectnamevalidatinglineedit.h index c677cea141477a6e0f8c6945edd6be6af1beb637..c42b8e4a359b8a66a8a61976db305ab7736e8716 100644 --- a/src/libs/utils/projectnamevalidatinglineedit.h +++ b/src/libs/utils/projectnamevalidatinglineedit.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PROJECTNAMEVALIDATINGLINEEDIT_H #define PROJECTNAMEVALIDATINGLINEEDIT_H @@ -38,7 +39,8 @@ namespace Core { namespace Utils { -class QWORKBENCH_UTILS_EXPORT ProjectNameValidatingLineEdit : public BaseValidatingLineEdit { +class QWORKBENCH_UTILS_EXPORT ProjectNameValidatingLineEdit : public BaseValidatingLineEdit +{ Q_OBJECT Q_DISABLE_COPY(ProjectNameValidatingLineEdit) @@ -51,6 +53,7 @@ protected: virtual bool validate(const QString &value, QString *errorMessage) const; }; -} -} +} // namespace Utils +} // namespace Core + #endif // PROJECTNAMEVALIDATINGLINEEDIT_H diff --git a/src/libs/utils/qtcolorbutton.cpp b/src/libs/utils/qtcolorbutton.cpp index 8b54bdda1d436d44a3a6d55fbfe97610073052f0..8f67fc097563b821213acf9b126bbf96f70d5f2a 100644 --- a/src/libs/utils/qtcolorbutton.cpp +++ b/src/libs/utils/qtcolorbutton.cpp @@ -30,12 +30,14 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "qtcolorbutton.h" -#include <QtGui/QColorDialog> -#include <QtGui/QPainter> + #include <QtCore/QMimeData> -#include <QtGui/QDragEnterEvent> #include <QtGui/QApplication> +#include <QtGui/QColorDialog> +#include <QtGui/QDragEnterEvent> +#include <QtGui/QPainter> namespace Core { namespace Utils { diff --git a/src/libs/utils/qtcolorbutton.h b/src/libs/utils/qtcolorbutton.h index 07355c883ec9c6bbe138728181b6fe720b8c12b6..930aef1579dd8f331c175bd0c7608d35713517f0 100644 --- a/src/libs/utils/qtcolorbutton.h +++ b/src/libs/utils/qtcolorbutton.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef QTCOLORBUTTON_H #define QTCOLORBUTTON_H diff --git a/src/libs/utils/reloadpromptutils.cpp b/src/libs/utils/reloadpromptutils.cpp index ca1d9e23dedb0c172c085b4970f05747ac7e74d9..9c4111a7db7b56158e9956bbe941585df75c9a14 100644 --- a/src/libs/utils/reloadpromptutils.cpp +++ b/src/libs/utils/reloadpromptutils.cpp @@ -30,7 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "reloadpromptutils.h" + #include <QtGui/QMessageBox> using namespace Core; @@ -47,7 +49,8 @@ QWORKBENCH_UTILS_EXPORT Core::Utils::ReloadPromptAnswer QWORKBENCH_UTILS_EXPORT Core::Utils::ReloadPromptAnswer Core::Utils::reloadPrompt(const QString &title, const QString &prompt, QWidget *parent) { - switch (QMessageBox::question(parent, title, prompt, QMessageBox::Yes|QMessageBox::YesToAll|QMessageBox::No|QMessageBox::NoToAll, + switch (QMessageBox::question(parent, title, prompt, + QMessageBox::Yes|QMessageBox::YesToAll|QMessageBox::No|QMessageBox::NoToAll, QMessageBox::YesToAll)) { case QMessageBox::Yes: return ReloadCurrent; diff --git a/src/libs/utils/reloadpromptutils.h b/src/libs/utils/reloadpromptutils.h index deaf4b920a662a39d6d8bbaff4eab486023da4f4..5d6fc87002551719bbd1f0ad9ad79473f1be614f 100644 --- a/src/libs/utils/reloadpromptutils.h +++ b/src/libs/utils/reloadpromptutils.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef RELOADPROMPTUTILS_H #define RELOADPROMPTUTILS_H diff --git a/src/libs/utils/settingsutils.cpp b/src/libs/utils/settingsutils.cpp index ca8de01828e0db61236f04575e2e6438c9bf175b..0f77b397ccacc713bdf974e5240d36cc20e3e442 100644 --- a/src/libs/utils/settingsutils.cpp +++ b/src/libs/utils/settingsutils.cpp @@ -30,7 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "settingsutils.h" + #include <QtCore/QString> namespace Core { @@ -41,13 +43,13 @@ QWORKBENCH_UTILS_EXPORT QString settingsKey(const QString &category) QString rc(category); const QChar underscore = QLatin1Char('_'); const int size = rc.size(); - for (int i = 0; i < size;i++) { + for (int i = 0; i < size; i++) { const QChar c = rc.at(i); - if (!c.isLetterOrNumber() && c != underscore) + if (!c.isLetterOrNumber() && c != underscore) rc[i] = underscore; } return rc; } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/settingsutils.h b/src/libs/utils/settingsutils.h index 734a2f02f9d4ee3f983a3778c63b39a83e7f26d6..abce76ee2f68bc5d9a26302470e4d3fd662ae85f 100644 --- a/src/libs/utils/settingsutils.h +++ b/src/libs/utils/settingsutils.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef SETTINGSTUTILS_H #define SETTINGSTUTILS_H diff --git a/src/libs/utils/submiteditorwidget.cpp b/src/libs/utils/submiteditorwidget.cpp index aeafcd828d558e051663bd5e583bec18d3d86e30..b2c7995686315dddf3d67162ac6012fceceffbdd 100644 --- a/src/libs/utils/submiteditorwidget.cpp +++ b/src/libs/utils/submiteditorwidget.cpp @@ -30,18 +30,20 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "submiteditorwidget.h" #include "ui_submiteditorwidget.h" #include <QtCore/QDebug> #include <QtCore/QPointer> -enum { debug= 0 }; +enum { debug = 0 }; namespace Core { namespace Utils { -struct SubmitEditorWidgetPrivate { +struct SubmitEditorWidgetPrivate +{ SubmitEditorWidgetPrivate(); Ui::SubmitEditorWidget m_ui; diff --git a/src/libs/utils/submiteditorwidget.h b/src/libs/utils/submiteditorwidget.h index 3c40ccecba72e02ec41e91d6e8c7b448a3948828..b034b549e4f6956e2ddd4a92ea7ebb648c1030e2 100644 --- a/src/libs/utils/submiteditorwidget.h +++ b/src/libs/utils/submiteditorwidget.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef SUBMITEDITORWIDGET_H #define SUBMITEDITORWIDGET_H @@ -65,7 +66,8 @@ struct SubmitEditorWidgetPrivate; * Care should be taken to ensure the widget is deleted properly when the * editor closes. */ -class QWORKBENCH_UTILS_EXPORT SubmitEditorWidget : public QWidget { +class QWORKBENCH_UTILS_EXPORT SubmitEditorWidget : public QWidget +{ Q_OBJECT Q_DISABLE_COPY(SubmitEditorWidget) Q_PROPERTY(QString descriptionText READ descriptionText WRITE setDescriptionText DESIGNABLE true) @@ -117,6 +119,7 @@ private: SubmitEditorWidgetPrivate *m_d; }; -} -} +} // namespace Utils +} // namespace Core + #endif // SUBMITEDITORWIDGET_H diff --git a/src/libs/utils/synchronousprocess.cpp b/src/libs/utils/synchronousprocess.cpp index 71bcdffb6cca6967f4507ca66b300e391821be52..049fd0f574a6d3343f59f60e7e958f11cca01ef6 100644 --- a/src/libs/utils/synchronousprocess.cpp +++ b/src/libs/utils/synchronousprocess.cpp @@ -352,5 +352,5 @@ void SynchronousProcess::processStdErr(bool emitSignals) } } -} -} +} // namespace Utils +} // namespace Core diff --git a/src/libs/utils/synchronousprocess.h b/src/libs/utils/synchronousprocess.h index 9458655d6bfa8053c3306d5cb777886d89aa6808..356dec2643f07cfbe0bd5f2de52faf0737a1cacd 100644 --- a/src/libs/utils/synchronousprocess.h +++ b/src/libs/utils/synchronousprocess.h @@ -30,15 +30,16 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef SYNCHRONOUSPROCESS_H #define SYNCHRONOUSPROCESS_H +#include "utils_global.h" + #include <QtCore/QObject> #include <QtCore/QProcess> #include <QtCore/QStringList> -#include "utils_global.h" - QT_BEGIN_NAMESPACE class QTextCodec; class QDebug; @@ -51,7 +52,8 @@ namespace Utils { struct SynchronousProcessPrivate; /* Result of SynchronousProcess execution */ -struct QWORKBENCH_UTILS_EXPORT SynchronousProcessResponse { +struct QWORKBENCH_UTILS_EXPORT SynchronousProcessResponse +{ enum Result { // Finished with return code 0 Finished, @@ -87,7 +89,8 @@ QWORKBENCH_UTILS_EXPORT QDebug operator<<(QDebug str, const SynchronousProcessRe * stdOutBufferedSignalsEnabled()/setStdErrBufferedSignalsEnabled(). * They would typically be used for log windows. */ -class QWORKBENCH_UTILS_EXPORT SynchronousProcess : public QObject { +class QWORKBENCH_UTILS_EXPORT SynchronousProcess : public QObject +{ Q_OBJECT public: SynchronousProcess(); @@ -134,6 +137,7 @@ private: SynchronousProcessPrivate *m_d; }; -} -} +} // namespace Utils +} // namespace Core + #endif diff --git a/src/libs/utils/utils_global.h b/src/libs/utils/utils_global.h index 3a91f77a2b9f94b18fc3b8bf8bfea61b217a4844..fa967e639722e01679dd9cd571259264c54fd21f 100644 --- a/src/libs/utils/utils_global.h +++ b/src/libs/utils/utils_global.h @@ -30,18 +30,6 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -/**************************************************************************** -** -** Copyright (C) 1992-$THISYEAR$ Trolltech AS. All rights reserved. -** -** This file is part of the $MODULE$ of the Qt Toolkit. -** -** $LICENSE$ -** -** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE -** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. -** -****************************************************************************/ #ifndef UTILS_GLOBAL_H #define UTILS_GLOBAL_H diff --git a/src/plugins/bineditor/bineditor.cpp b/src/plugins/bineditor/bineditor.cpp index 4ca6e18707cf757c5f42f4e510396c03d11ba0ed..4f2f45fc44da3de383585c73c13a14170d5d856d 100644 --- a/src/plugins/bineditor/bineditor.cpp +++ b/src/plugins/bineditor/bineditor.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "bineditor.h" #include <texteditor/fontsettings.h> diff --git a/src/plugins/bineditor/bineditor.h b/src/plugins/bineditor/bineditor.h index 2eae59af1a764dabcd9bae4fff1b833644a66b4c..ad6b9064ac434680df726075647022d0ee9235cd 100644 --- a/src/plugins/bineditor/bineditor.h +++ b/src/plugins/bineditor/bineditor.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BINEDITOR_H #define BINEDITOR_H diff --git a/src/plugins/bineditor/bineditorconstants.h b/src/plugins/bineditor/bineditorconstants.h index f67d6c522d7f27c02ca9b1f009df71b3c4e5e58b..a0f18d36fd94d9a68276d4f82c40d3d275074b44 100644 --- a/src/plugins/bineditor/bineditorconstants.h +++ b/src/plugins/bineditor/bineditorconstants.h @@ -30,14 +30,17 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BINEDITORCONSTANTS_H #define BINEDITORCONSTANTS_H namespace BINEditor { - namespace Constants { - const char * const C_BINEDITOR = "Binary Editor"; - const char * const C_BINEDITOR_MIMETYPE = "application/octet-stream"; - } -} +namespace Constants { + +const char * const C_BINEDITOR = "Binary Editor"; +const char * const C_BINEDITOR_MIMETYPE = "application/octet-stream"; + +} // namespace Constants +} // namespace BINEditor #endif // BINEDITORCONSTANTS_H diff --git a/src/plugins/bineditor/bineditorplugin.cpp b/src/plugins/bineditor/bineditorplugin.cpp index ee223f3deae3a85130f7ffa9c4ee63a4737900c7..cf1d21429b374d3de6d6d930ecb32b923edd1ae4 100644 --- a/src/plugins/bineditor/bineditorplugin.cpp +++ b/src/plugins/bineditor/bineditorplugin.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "bineditorplugin.h" #include "bineditor.h" #include "bineditorconstants.h" diff --git a/src/plugins/bineditor/bineditorplugin.h b/src/plugins/bineditor/bineditorplugin.h index 6bd0da64b30d007029b6c3e85c629d040c5a29b8..53ea5d6232c00686112b0f98e855a9fccd44cd94 100644 --- a/src/plugins/bineditor/bineditorplugin.h +++ b/src/plugins/bineditor/bineditorplugin.h @@ -30,17 +30,18 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BINEDITORPLUGIN_H #define BINEDITORPLUGIN_H +#include <extensionsystem/iplugin.h> +#include <coreplugin/editormanager/ieditorfactory.h> + #include <QtCore/qplugin.h> #include <QtCore/QPointer> #include <QtCore/QStringList> #include <QtGui/QAction> -#include <extensionsystem/iplugin.h> -#include <coreplugin/editormanager/ieditorfactory.h> - namespace Core { class ICore; class IWizard; diff --git a/src/plugins/bookmarks/bookmark.cpp b/src/plugins/bookmarks/bookmark.cpp index 41f4659cb7001a96e86327fb984cbd05cff5fefc..c41aa5323afae1daced6e66a904edca1f33accc2 100644 --- a/src/plugins/bookmarks/bookmark.cpp +++ b/src/plugins/bookmarks/bookmark.cpp @@ -30,8 +30,10 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "bookmark.h" #include "bookmarkmanager.h" + #include <QtCore/QDebug> #include <QtGui/QTextBlock> diff --git a/src/plugins/bookmarks/bookmark.h b/src/plugins/bookmarks/bookmark.h index d54d6af3e5610caa11d5a26387d57c2955bb5848..97a83f9247138b6b18658397df2ace66ea7032bc 100644 --- a/src/plugins/bookmarks/bookmark.h +++ b/src/plugins/bookmarks/bookmark.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BOOKMARK_H #define BOOKMARK_H diff --git a/src/plugins/bookmarks/bookmarkmanager.cpp b/src/plugins/bookmarks/bookmarkmanager.cpp index bb26bfbd4ffa7f565d4721f9dc90db861c7d1f9e..402054860d69e0f7b534655db56ac401df0085e1 100644 --- a/src/plugins/bookmarks/bookmarkmanager.cpp +++ b/src/plugins/bookmarks/bookmarkmanager.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "bookmarkmanager.h" #include "bookmark.h" #include "bookmarksplugin.h" diff --git a/src/plugins/bookmarks/bookmarkmanager.h b/src/plugins/bookmarks/bookmarkmanager.h index 45e4bf3b7b1e081f09ccd5284907658167427be9..b6fba5934a82d63647c580f26c388fc0c45b9f9f 100644 --- a/src/plugins/bookmarks/bookmarkmanager.h +++ b/src/plugins/bookmarks/bookmarkmanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BOOKMARKMANAGER_H #define BOOKMARKMANAGER_H @@ -131,7 +132,8 @@ private: QItemSelectionModel *m_selectionModel; }; -class BookmarkView : public QListView { +class BookmarkView : public QListView +{ Q_OBJECT public: BookmarkView(QWidget *parent = 0); diff --git a/src/plugins/bookmarks/bookmarks_global.h b/src/plugins/bookmarks/bookmarks_global.h index e29f4e5865012352dfc2aa46a9b62c4171098a21..f91575032f502e7ac45f6847fb8c1416d99230cf 100644 --- a/src/plugins/bookmarks/bookmarks_global.h +++ b/src/plugins/bookmarks/bookmarks_global.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BOOKMARKS_GLOBAL_H #define BOOKMARKS_GLOBAL_H @@ -49,8 +50,8 @@ const char * const BOOKMARKS_NEXTDOC_ACTION = "Bookmarks.Next.Document"; const char * const BOOKMARKS_MENU = "Bookmarks.Menu"; const char * const BOOKMARKS_CONTEXT = "Bookmarks"; -} //namespace Constants -} //namespace Bookmarks +} // namespace Constants +} // namespace Bookmarks -#endif //BOOKMARKS_GLOBAL_H +#endif // BOOKMARKS_GLOBAL_H diff --git a/src/plugins/bookmarks/bookmarksplugin.cpp b/src/plugins/bookmarks/bookmarksplugin.cpp index 76df8e57774d224f0424505e1e601e22c0d55e31..2fdf3d528a044ff4a37519740778552014ec18f2 100644 --- a/src/plugins/bookmarks/bookmarksplugin.cpp +++ b/src/plugins/bookmarks/bookmarksplugin.cpp @@ -30,28 +30,28 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "bookmarksplugin.h" #include "bookmarkmanager.h" #include "bookmarks_global.h" -#include <QtCore/qplugin.h> -#include <QtGui/QMenu> -#include <QDebug> - #include <texteditor/texteditorconstants.h> #include <coreplugin/icore.h> #include <coreplugin/coreconstants.h> #include <coreplugin/uniqueidmanager.h> #include <coreplugin/actionmanager/actionmanagerinterface.h> +#include <QtCore/qplugin.h> +#include <QtGui/QMenu> +#include <QDebug> + using namespace Bookmarks::Constants; using namespace Bookmarks::Internal; BookmarksPlugin *BookmarksPlugin::m_instance = 0; -BookmarksPlugin::BookmarksPlugin(): - m_bookmarkManager(0), - m_core(0) +BookmarksPlugin::BookmarksPlugin() + : m_bookmarkManager(0), m_core(0) { m_instance = this; } diff --git a/src/plugins/bookmarks/bookmarksplugin.h b/src/plugins/bookmarks/bookmarksplugin.h index 7da45ef5ee75f1fbe25d9cf0f6062c9000d85dad..255f209086cc68ce40fc279a5d0a4351d3bc529e 100644 --- a/src/plugins/bookmarks/bookmarksplugin.h +++ b/src/plugins/bookmarks/bookmarksplugin.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BOOKMARKS_H #define BOOKMARKS_H diff --git a/src/plugins/cmakeprojectmanager/cmakeproject.cpp b/src/plugins/cmakeprojectmanager/cmakeproject.cpp index 2c98124bb908f0c4ce1c54a29eb31a9252f896e8..dd4aa4290e08d43d95b4fd3524cb39db8f3e3c16 100644 --- a/src/plugins/cmakeprojectmanager/cmakeproject.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeproject.cpp @@ -30,11 +30,14 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "cmakeproject.h" #include "cmakeprojectconstants.h" #include "cmakeprojectnodes.h" + #include <extensionsystem/pluginmanager.h> #include <cpptools/cppmodelmanagerinterface.h> + #include <QtCore/QDebug> using namespace CMakeProjectManager; diff --git a/src/plugins/cmakeprojectmanager/cmakeproject.h b/src/plugins/cmakeprojectmanager/cmakeproject.h index b5a8d0b6b4a491ac7ae51e9cad5c5a3c3f69e835..a67b7b666bf86d4d472a4165afe1eb99a62ff636 100644 --- a/src/plugins/cmakeprojectmanager/cmakeproject.h +++ b/src/plugins/cmakeprojectmanager/cmakeproject.h @@ -1,4 +1,4 @@ -/*************************************************************************** + /*************************************************************************** ** ** This file is part of Qt Creator ** @@ -30,17 +30,19 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CMAKEPROJECT_H #define CMAKEPROJECT_H +#include "cmakeprojectmanager.h" +#include "cmakeprojectnodes.h" + #include <projectexplorer/project.h> #include <projectexplorer/projectnodes.h> #include <projectexplorer/buildstep.h> #include <coreplugin/ifile.h> -#include <QtCore/QXmlStreamReader> -#include "cmakeprojectmanager.h" -#include "cmakeprojectnodes.h" +#include <QtCore/QXmlStreamReader> namespace CMakeProjectManager { namespace Internal{ @@ -152,7 +154,7 @@ public: virtual void init(const QString &buildConfiguration); }; -} -} +} // namespace Internal +} // namespace CMakeProjectManager #endif // CMAKEPROJECT_H diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectconstants.h b/src/plugins/cmakeprojectmanager/cmakeprojectconstants.h index 02c76f6682d86a9eb45477c401118897341be9ec..2e9bad248adc0415ded6698108c56493080746f9 100644 --- a/src/plugins/cmakeprojectmanager/cmakeprojectconstants.h +++ b/src/plugins/cmakeprojectmanager/cmakeprojectconstants.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CMAKEPROJECTCONSTANTS_H #define CMAKEPROJECTCONSTANTS_H @@ -39,7 +40,7 @@ namespace Constants { const char * const PROJECTCONTEXT = "CMakeProject.ProjectContext"; const char * const CMAKEMIMETYPE = "text/x-cmake"; // TOOD check that this is correct -} -} +} // namespace Constants +} // namespace CMakeProjectManager #endif // CMAKEPROJECTCONSTANTS_H diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp b/src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp index 4a179967ccb1d89a4da24f5a28eaa414efdea91f..0f2fb804da2af6a39fe60d2a974a48da8bdbd5ab 100644 --- a/src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "cmakeprojectmanager.h" #include "cmakeprojectconstants.h" #include "cmakeproject.h" @@ -40,7 +41,6 @@ #include <coreplugin/uniqueidmanager.h> #include <projectexplorer/projectexplorerconstants.h> - using namespace CMakeProjectManager::Internal; CMakeManager::CMakeManager() diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectmanager.h b/src/plugins/cmakeprojectmanager/cmakeprojectmanager.h index 3808b72efba557d21e28f1991a96591b4d476e03..fba00db869fa243744c8760ef6f534250b37d290 100644 --- a/src/plugins/cmakeprojectmanager/cmakeprojectmanager.h +++ b/src/plugins/cmakeprojectmanager/cmakeprojectmanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CMAKEPROJECTMANAGER_H #define CMAKEPROJECTMANAGER_H @@ -55,6 +56,8 @@ private: int m_projectContext; int m_projectLanguage; }; -} -} + +} // namespace Internal +} // namespace CMakeProjectManager + #endif // CMAKEPROJECTMANAGER_H diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectnodes.cpp b/src/plugins/cmakeprojectmanager/cmakeprojectnodes.cpp index 338750158f740dc4357d941dde471bd329361bcf..c78e15830c36ec78359ceeb26278e5fae06ac474 100644 --- a/src/plugins/cmakeprojectmanager/cmakeprojectnodes.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeprojectnodes.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "cmakeprojectnodes.h" using namespace CMakeProjectManager; diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectnodes.h b/src/plugins/cmakeprojectmanager/cmakeprojectnodes.h index a0a9453a47d7b068b4e7cdcae300854a2dcce89a..b8f0284fa3760b7e1a1542022e733f651f964efb 100644 --- a/src/plugins/cmakeprojectmanager/cmakeprojectnodes.h +++ b/src/plugins/cmakeprojectmanager/cmakeprojectnodes.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CMAKEPROJECTNODE_H #define CMAKEPROJECTNODE_H @@ -60,7 +61,8 @@ public: using ProjectNode::addFileNodes; using ProjectNode::addFolderNodes; }; -} -} + +} // namespace Internal +} // namespace CMakeProjectManager #endif // CMAKEPROJECTNODE_H diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectplugin.cpp b/src/plugins/cmakeprojectmanager/cmakeprojectplugin.cpp index 9a9190568f11d86ee9b691b34ae61a4d0c356cc5..1eabecb3b6eb9854c82ceec1def4733f449f6f56 100644 --- a/src/plugins/cmakeprojectmanager/cmakeprojectplugin.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeprojectplugin.cpp @@ -30,13 +30,16 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "cmakeprojectplugin.h" +#include "cmakeprojectmanager.h" + #include <coreplugin/icore.h> #include <coreplugin/mimedatabase.h> + #include <QtCore/qplugin.h> #include <QtCore/QDebug> -#include "cmakeprojectmanager.h" using namespace CMakeProjectManager::Internal; @@ -59,7 +62,6 @@ bool CMakeProjectPlugin::initialize(const QStringList & /*arguments*/, QString * void CMakeProjectPlugin::extensionsInitialized() { - } Q_EXPORT_PLUGIN(CMakeProjectPlugin) diff --git a/src/plugins/cmakeprojectmanager/cmakeprojectplugin.h b/src/plugins/cmakeprojectmanager/cmakeprojectplugin.h index 0620220667ae8d3256f1ac260c830b50e780ff84..6bc2748e4f139873a83c63eb6e6ad436c30cb8b8 100644 --- a/src/plugins/cmakeprojectmanager/cmakeprojectplugin.h +++ b/src/plugins/cmakeprojectmanager/cmakeprojectplugin.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CMAKEPROJECTPLUGIN_H #define CMAKEPROJECTPLUGIN_H @@ -52,9 +53,6 @@ public: bool initialize(const QStringList &arguments, QString *error_message); void extensionsInitialized(); - - -private: }; } // namespace Internal diff --git a/src/plugins/coreplugin/actionmanager/actioncontainer.cpp b/src/plugins/coreplugin/actionmanager/actioncontainer.cpp index ab30677a628972dc3325028372a8e4fb1827c407..68709dcd13c4b67c2325c91bdca5bd5fb9aaddb4 100644 --- a/src/plugins/coreplugin/actionmanager/actioncontainer.cpp +++ b/src/plugins/coreplugin/actionmanager/actioncontainer.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "actioncontainer.h" #include "command.h" #include "coreimpl.h" diff --git a/src/plugins/coreplugin/actionmanager/actioncontainer.h b/src/plugins/coreplugin/actionmanager/actioncontainer.h index 8f629410a42e1c22c7c51a7c9f3715374a83a165..51b0437d4f2d4adbc9a43611621ecfbf2cb3f3e2 100644 --- a/src/plugins/coreplugin/actionmanager/actioncontainer.h +++ b/src/plugins/coreplugin/actionmanager/actioncontainer.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef ACTIONCONTAINER_H #define ACTIONCONTAINER_H @@ -152,6 +153,4 @@ private: } // namespace Internal } // namespace Core -#endif //ACTIONCONTAINER_H - - +#endif // ACTIONCONTAINER_H diff --git a/src/plugins/coreplugin/actionmanager/actionmanager.cpp b/src/plugins/coreplugin/actionmanager/actionmanager.cpp index f218a84c732a9ee5958269875bd75d6c2e032bdf..488dcddfa415f40e141688ed62d81b86b40a143a 100644 --- a/src/plugins/coreplugin/actionmanager/actionmanager.cpp +++ b/src/plugins/coreplugin/actionmanager/actionmanager.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "actionmanager.h" #include "mainwindow.h" #include "actioncontainer.h" @@ -510,6 +511,7 @@ IActionContainer *ActionManager::actionContainer(int uid) const } return it.value(); } + static const char *settingsGroup = "KeyBindings"; static const char *idKey = "ID"; static const char *sequenceKey = "Keysequence"; diff --git a/src/plugins/coreplugin/actionmanager/actionmanager.h b/src/plugins/coreplugin/actionmanager/actionmanager.h index c0279e3b69b9d41dc0ab821d68acc0b1d4acfbb1..43c5ecdc91f183f6460e2564d90c194caa8df584 100644 --- a/src/plugins/coreplugin/actionmanager/actionmanager.h +++ b/src/plugins/coreplugin/actionmanager/actionmanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef ACTIONMANAGER_H #define ACTIONMANAGER_H @@ -43,7 +44,8 @@ QT_BEGIN_NAMESPACE class QSettings; QT_END_NAMESPACE -struct CommandLocation { +struct CommandLocation +{ int m_container; int m_position; }; @@ -125,5 +127,4 @@ private: } // namespace Internal } // namespace Core - -#endif //ACTIONMANAGER_H +#endif // ACTIONMANAGER_H diff --git a/src/plugins/coreplugin/actionmanager/actionmanagerinterface.h b/src/plugins/coreplugin/actionmanager/actionmanagerinterface.h index 9a3760ed76422bd23025566d57636911e3c5fef6..2d7ead17a72a869afd4dea66e2599266d1827972 100644 --- a/src/plugins/coreplugin/actionmanager/actionmanagerinterface.h +++ b/src/plugins/coreplugin/actionmanager/actionmanagerinterface.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef ACTIONMANAGERINTERFACE_H #define ACTIONMANAGERINTERFACE_H diff --git a/src/plugins/coreplugin/actionmanager/command.cpp b/src/plugins/coreplugin/actionmanager/command.cpp index d5e0b17b367744dfac58f3f86a7bc9731db82481..4c8a15ae7405d3149953d7b92573476963776804 100644 --- a/src/plugins/coreplugin/actionmanager/command.cpp +++ b/src/plugins/coreplugin/actionmanager/command.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include <QtCore/QDebug> #include <QtGui/QAction> #include <QtGui/QShortcut> diff --git a/src/plugins/coreplugin/actionmanager/command.h b/src/plugins/coreplugin/actionmanager/command.h index 2d227d6542442ff2f2738b156bbeff9da96bfbf3..32a85762a2a1fff1f07ecc921b01d35aa93f3bfe 100644 --- a/src/plugins/coreplugin/actionmanager/command.h +++ b/src/plugins/coreplugin/actionmanager/command.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef COMMAND_H #define COMMAND_H @@ -175,4 +176,4 @@ private: } // namespace Internal } // namespace Core -#endif //COMMAND_H +#endif // COMMAND_H diff --git a/src/plugins/coreplugin/actionmanager/commandsfile.cpp b/src/plugins/coreplugin/actionmanager/commandsfile.cpp index 6849dd97711a7db14463dba39190ec21e5488a8b..897af6baeb4bf5dc844b28ff18ee236c69b527d3 100644 --- a/src/plugins/coreplugin/actionmanager/commandsfile.cpp +++ b/src/plugins/coreplugin/actionmanager/commandsfile.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "coreimpl.h" #include "commandsfile.h" #include "shortcutsettings.h" diff --git a/src/plugins/coreplugin/actionmanager/commandsfile.h b/src/plugins/coreplugin/actionmanager/commandsfile.h index 890c2384f512db222fc9c0c2f2afcbe53f13ed34..491cb0b2008ecf94dc1111ecb4d9a04a5daa78db 100644 --- a/src/plugins/coreplugin/actionmanager/commandsfile.h +++ b/src/plugins/coreplugin/actionmanager/commandsfile.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef COMMANDSFILE_H #define COMMANDSFILE_H @@ -44,7 +45,8 @@ namespace Internal { struct ShortcutItem; -class CommandsFile : public QObject { +class CommandsFile : public QObject +{ Q_OBJECT public: diff --git a/src/plugins/coreplugin/actionmanager/iactioncontainer.h b/src/plugins/coreplugin/actionmanager/iactioncontainer.h index a9adb471b12aa91d7a6318081893149d23339a1b..0b2efdda88608431dec39d238f81faaa4e0d242d 100644 --- a/src/plugins/coreplugin/actionmanager/iactioncontainer.h +++ b/src/plugins/coreplugin/actionmanager/iactioncontainer.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IACTIONCONTAINER_H #define IACTIONCONTAINER_H @@ -42,6 +43,7 @@ namespace Core { class ICommand; + class IActionContainer : public QObject { public: diff --git a/src/plugins/coreplugin/actionmanager/icommand.h b/src/plugins/coreplugin/actionmanager/icommand.h index c1a03a2f14803934b0b2649f018473086877ee51..fb7a7ab4d4a7bf946b929fd51e6102a965ebb0c7 100644 --- a/src/plugins/coreplugin/actionmanager/icommand.h +++ b/src/plugins/coreplugin/actionmanager/icommand.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef ICOMMAND_H #define ICOMMAND_H diff --git a/src/plugins/coreplugin/basefilewizard.cpp b/src/plugins/coreplugin/basefilewizard.cpp index b54b43af8d37b75f1f29959e0952189352f96525..eb5dfff87f4a3adfece7dd26d770af9112c7a5df 100644 --- a/src/plugins/coreplugin/basefilewizard.cpp +++ b/src/plugins/coreplugin/basefilewizard.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "basefilewizard.h" #include "mimedatabase.h" @@ -56,7 +57,8 @@ enum { debugWizard = 0 }; namespace Core { -class GeneratedFilePrivate : public QSharedData { +class GeneratedFilePrivate : public QSharedData +{ public: GeneratedFilePrivate() {} explicit GeneratedFilePrivate(const QString &p); @@ -150,8 +152,11 @@ bool GeneratedFile::write(QString *errorMessage) const file.close(); return true; } + + // ------------ BaseFileWizardParameterData -class BaseFileWizardParameterData : public QSharedData { +class BaseFileWizardParameterData : public QSharedData +{ public: explicit BaseFileWizardParameterData(IWizard::Kind kind = IWizard::FileWizard); @@ -338,7 +343,8 @@ void WizardEventLoop::rejected() } // ---------------- BaseFileWizardPrivate -struct BaseFileWizardPrivate { +struct BaseFileWizardPrivate +{ explicit BaseFileWizardPrivate(const Core::BaseFileWizardParameters ¶meters, Core::ICore *core); @@ -666,6 +672,6 @@ GeneratedFiles StandardFileWizard::generateFiles(const QWizard *w, errorMessage); } - } // namespace Core + #include "basefilewizard.moc" diff --git a/src/plugins/coreplugin/basefilewizard.h b/src/plugins/coreplugin/basefilewizard.h index dcf965ecce40fb8b52ce285a25f737fd8c6a7bf1..0c392430b7f49203639217aea3b191215b0272a6 100644 --- a/src/plugins/coreplugin/basefilewizard.h +++ b/src/plugins/coreplugin/basefilewizard.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BASEFILEWIZARD_H #define BASEFILEWIZARD_H @@ -62,7 +63,8 @@ class GeneratedFilePrivate; * each file whether it already exists and will report any errors that may * occur during creation of the files. */ -class CORE_EXPORT GeneratedFile { +class CORE_EXPORT GeneratedFile +{ public: GeneratedFile(); explicit GeneratedFile(const QString &path); @@ -93,7 +95,8 @@ typedef QList<GeneratedFile> GeneratedFiles; /* Parameter class for passing parameters to instances of class Wizard * containing name, icon and such. */ -class CORE_EXPORT BaseFileWizardParameters { +class CORE_EXPORT BaseFileWizardParameters +{ public: explicit BaseFileWizardParameters(IWizard::Kind kind = IWizard::FileWizard); BaseFileWizardParameters(const BaseFileWizardParameters &); @@ -204,7 +207,8 @@ private: // Core::Utils::FileWizardDialog and introduces a new virtual to generate the // files from path and name. -class CORE_EXPORT StandardFileWizard : public BaseFileWizard { +class CORE_EXPORT StandardFileWizard : public BaseFileWizard +{ Q_DISABLE_COPY(StandardFileWizard) Q_OBJECT diff --git a/src/plugins/coreplugin/basemode.cpp b/src/plugins/coreplugin/basemode.cpp index 5573f733f8cba2866095232467abe1e06d32b34a..40e6d911f9e3acb50db09b65351386199175b56d 100644 --- a/src/plugins/coreplugin/basemode.cpp +++ b/src/plugins/coreplugin/basemode.cpp @@ -30,12 +30,13 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -#include "basemode.h" -#include <QtGui/QWidget> +#include "basemode.h" #include <extensionsystem/pluginmanager.h> +#include <QtGui/QWidget> + using namespace Core; /*! diff --git a/src/plugins/coreplugin/basemode.h b/src/plugins/coreplugin/basemode.h index 65bd5bb3784ac32d8de73cdb5e3f6cc2c8afddf5..952a7c4b6d397277c50044d773db4d09edb2ae4a 100644 --- a/src/plugins/coreplugin/basemode.h +++ b/src/plugins/coreplugin/basemode.h @@ -30,11 +30,11 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BASEMODE_H #define BASEMODE_H #include "core_global.h" - #include "imode.h" #include <QtCore/QObject> diff --git a/src/plugins/coreplugin/baseview.cpp b/src/plugins/coreplugin/baseview.cpp index ef0ab5754cd4311178bcda827456d149e98dc94c..661bbe7bfb3d409e81c7508a7a133a0796380010 100644 --- a/src/plugins/coreplugin/baseview.cpp +++ b/src/plugins/coreplugin/baseview.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "baseview.h" #include <extensionsystem/ExtensionSystemInterfaces> diff --git a/src/plugins/coreplugin/baseview.h b/src/plugins/coreplugin/baseview.h index dd3bb0503a5b34881ad9fa9e5556f934be01025d..996a69ce6238dd3d5a82cdf266549867f40f9877 100644 --- a/src/plugins/coreplugin/baseview.h +++ b/src/plugins/coreplugin/baseview.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef BASEVIEW_H #define BASEVIEW_H diff --git a/src/plugins/coreplugin/core_global.h b/src/plugins/coreplugin/core_global.h index 71737b31b73e0796dbf6aa76d3dbc39ba391ba5d..7fda209da9d63f72357097139eaca04213aacf34 100644 --- a/src/plugins/coreplugin/core_global.h +++ b/src/plugins/coreplugin/core_global.h @@ -30,18 +30,6 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -/**************************************************************************** -** -** Copyright (C) 1992-$THISYEAR$ Trolltech AS. All rights reserved. -** -** This file is part of the $MODULE$ of the Qt Toolkit. -** -** $LICENSE$ -** -** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE -** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. -** -****************************************************************************/ #ifndef CORE_GLOBAL_H #define CORE_GLOBAL_H diff --git a/src/plugins/coreplugin/coreconstants.h b/src/plugins/coreplugin/coreconstants.h index 6f0292041ef96bde4de2cd28b9dbe2c2319044f5..f05e224919718ff6ffd76bdd07ba6686a1890213 100644 --- a/src/plugins/coreplugin/coreconstants.h +++ b/src/plugins/coreplugin/coreconstants.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef CORECONSTANTS_H #define CORECONSTANTS_H diff --git a/src/plugins/coreplugin/coreimpl.cpp b/src/plugins/coreplugin/coreimpl.cpp index 258aa0331bb9b01ecaa33108c0d361e6f58efc7d..3b1452a35d7238c4f68588232a5c9a2cdb7a007a 100644 --- a/src/plugins/coreplugin/coreimpl.cpp +++ b/src/plugins/coreplugin/coreimpl.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "coreimpl.h" #include <QtCore/QDir> diff --git a/src/plugins/coreplugin/coreimpl.h b/src/plugins/coreplugin/coreimpl.h index b7eaf185a4d2515125bc271bcefa84a1aad4f73f..f6aca168b14b0ec01c71e2793b0bfcb81034cf1e 100644 --- a/src/plugins/coreplugin/coreimpl.h +++ b/src/plugins/coreplugin/coreimpl.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef COREIMPL_H #define COREIMPL_H diff --git a/src/plugins/coreplugin/coreplugin.cpp b/src/plugins/coreplugin/coreplugin.cpp index 070edd9a6a7aa54055447ba3c2ded35ce1a08f96..dbc96ce4cc147d5713a441af81451e0bc4edf88e 100644 --- a/src/plugins/coreplugin/coreplugin.cpp +++ b/src/plugins/coreplugin/coreplugin.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "coreplugin.h" #include "welcomemode.h" #include "editmode.h" diff --git a/src/plugins/coreplugin/coreplugin.h b/src/plugins/coreplugin/coreplugin.h index 6afd9c7f248a9aea15008f58329bb87a03f04b7c..43ae3bbb274e2aef86ed535e8d97f4757228827e 100644 --- a/src/plugins/coreplugin/coreplugin.h +++ b/src/plugins/coreplugin/coreplugin.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef QWORKBENCHPLUGIN_H #define QWORKBENCHPLUGIN_H diff --git a/src/plugins/coreplugin/dialogs/ioptionspage.h b/src/plugins/coreplugin/dialogs/ioptionspage.h index 4aa385438518037616256caec356cb5f45abb027..e6f9298284d704f794988ed6eccf2b32091518dd 100644 --- a/src/plugins/coreplugin/dialogs/ioptionspage.h +++ b/src/plugins/coreplugin/dialogs/ioptionspage.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IOPTIONSPAGE_H #define IOPTIONSPAGE_H diff --git a/src/plugins/coreplugin/dialogs/iwizard.h b/src/plugins/coreplugin/dialogs/iwizard.h index 37457ba39b977403fe6f02610150478840f03b21..68b3f2529d47ecff2012500f49b64891ca6bc8e2 100644 --- a/src/plugins/coreplugin/dialogs/iwizard.h +++ b/src/plugins/coreplugin/dialogs/iwizard.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IWIZARD_H #define IWIZARD_H @@ -65,6 +66,7 @@ public: virtual QStringList runWizard(const QString &path, QWidget *parent) = 0; }; + } // namespace Core #endif // IWIZARD_H diff --git a/src/plugins/coreplugin/dialogs/newdialog.cpp b/src/plugins/coreplugin/dialogs/newdialog.cpp index e344dc34a0519a32d797b7945bcf787383b5381e..fcb43ddf12b3700b192e3a5f5287f139d8c90e57 100644 --- a/src/plugins/coreplugin/dialogs/newdialog.cpp +++ b/src/plugins/coreplugin/dialogs/newdialog.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "newdialog.h" #include "ui_newdialog.h" #include "basefilewizard.h" @@ -37,7 +38,6 @@ #include <coreplugin/coreconstants.h> #include <coreplugin/dialogs/iwizard.h> - #include <QtGui/QHeaderView> #include <QtGui/QPushButton> @@ -143,7 +143,6 @@ void NewDialog::okButtonClicked() accept(); } - void NewDialog::updateOkButton() { m_okButton->setEnabled(currentWizard() != 0); diff --git a/src/plugins/coreplugin/dialogs/newdialog.h b/src/plugins/coreplugin/dialogs/newdialog.h index 84059b71a17954ec2c706af23cbdc45612171300..17275069f8c271d6da51f63592409f1b0d84e652 100644 --- a/src/plugins/coreplugin/dialogs/newdialog.h +++ b/src/plugins/coreplugin/dialogs/newdialog.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef NEWDIALOG_H #define NEWDIALOG_H @@ -79,4 +80,4 @@ private: } // namespace Internal } // namespace Core -#endif //NEWDIALOG_H +#endif // NEWDIALOG_H diff --git a/src/plugins/coreplugin/dialogs/openwithdialog.cpp b/src/plugins/coreplugin/dialogs/openwithdialog.cpp index b3882184744bfa9720af104c0c0d29b6d202006f..25954c9cecc7978763aaee8e7badad28335f93ca 100644 --- a/src/plugins/coreplugin/dialogs/openwithdialog.cpp +++ b/src/plugins/coreplugin/dialogs/openwithdialog.cpp @@ -28,8 +28,9 @@ ** In addition, as a special exception, Nokia gives you certain additional ** rights. These rights are described in the Nokia Qt GPL Exception version ** 1.2, included in the file GPL_EXCEPTION.txt in this package. -** +** ***************************************************************************/ + #include "openwithdialog.h" #include <QtGui/QListWidget> @@ -39,8 +40,8 @@ using namespace Core; using namespace Core::Internal; -OpenWithDialog::OpenWithDialog(const QString &fileName, QWidget *parent) : - QDialog(parent) +OpenWithDialog::OpenWithDialog(const QString &fileName, QWidget *parent) + : QDialog(parent) { setupUi(this); label->setText(tr("Open file '%1' with:").arg(QFileInfo(fileName).fileName())); diff --git a/src/plugins/coreplugin/dialogs/openwithdialog.h b/src/plugins/coreplugin/dialogs/openwithdialog.h index 569f5eac7d743b5a639e049ed9abd6cadd3c2a57..63eb5880e788b0f113e114f31e8852ee99d82ec4 100644 --- a/src/plugins/coreplugin/dialogs/openwithdialog.h +++ b/src/plugins/coreplugin/dialogs/openwithdialog.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef OPENWITHDIALOG_H #define OPENWITHDIALOG_H @@ -66,4 +67,4 @@ private: } // namespace Internal } // namespace Core -#endif +#endif // OPENWITHDIALOG_H diff --git a/src/plugins/coreplugin/dialogs/saveitemsdialog.cpp b/src/plugins/coreplugin/dialogs/saveitemsdialog.cpp index 7c06c786fd5e3d151f147051c536b12302d3cc24..244f178b140ef8fdd2c469ec33835103dd528e30 100644 --- a/src/plugins/coreplugin/dialogs/saveitemsdialog.cpp +++ b/src/plugins/coreplugin/dialogs/saveitemsdialog.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "saveitemsdialog.h" #include "mainwindow.h" #include "vcsmanager.h" diff --git a/src/plugins/coreplugin/dialogs/saveitemsdialog.h b/src/plugins/coreplugin/dialogs/saveitemsdialog.h index 52e43aab0a641603b15b0a5d127f60501ae28277..3b02160c0a6fac66efe647684ef02d8614273747 100644 --- a/src/plugins/coreplugin/dialogs/saveitemsdialog.h +++ b/src/plugins/coreplugin/dialogs/saveitemsdialog.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef SAVEITEMSDIALOG_H #define SAVEITEMSDIALOG_H diff --git a/src/plugins/coreplugin/dialogs/settingsdialog.cpp b/src/plugins/coreplugin/dialogs/settingsdialog.cpp index 78d839bf1aaf084d765e26b4ceff99e1960502c9..b0bb2da6486ef1961ce6abbc02db06460ab766d9 100644 --- a/src/plugins/coreplugin/dialogs/settingsdialog.cpp +++ b/src/plugins/coreplugin/dialogs/settingsdialog.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "settingsdialog.h" #include "coreimpl.h" @@ -111,7 +112,6 @@ SettingsDialog::SettingsDialog(QWidget *parent, const QString &initialCategory, SettingsDialog::~SettingsDialog() { - } void SettingsDialog::pageSelected(QTreeWidgetItem *) @@ -123,16 +123,14 @@ void SettingsDialog::pageSelected(QTreeWidgetItem *) void SettingsDialog::accept() { - foreach(IOptionsPage *page, m_pages) { + foreach(IOptionsPage *page, m_pages) page->finished(true); - } done(QDialog::Accepted); } void SettingsDialog::reject() { - foreach(IOptionsPage *page, m_pages) { + foreach(IOptionsPage *page, m_pages) page->finished(false); - } done(QDialog::Rejected); } diff --git a/src/plugins/coreplugin/dialogs/settingsdialog.h b/src/plugins/coreplugin/dialogs/settingsdialog.h index 2d80aa643c26967e3de27312ddba7c215836c087..c56093e138247aabbdd839ada83d53a7d0b4ea36 100644 --- a/src/plugins/coreplugin/dialogs/settingsdialog.h +++ b/src/plugins/coreplugin/dialogs/settingsdialog.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef SETTINGSDIALOG_H #define SETTINGSDIALOG_H diff --git a/src/plugins/coreplugin/dialogs/shortcutsettings.cpp b/src/plugins/coreplugin/dialogs/shortcutsettings.cpp index aeefebdf24cc0450d02eb54888205ab148068d0b..87e504dd025a6b21b84d92ec56c001c43201b6cc 100644 --- a/src/plugins/coreplugin/dialogs/shortcutsettings.cpp +++ b/src/plugins/coreplugin/dialogs/shortcutsettings.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "shortcutsettings.h" #include "ui_shortcutsettings.h" #include "actionmanager.h" diff --git a/src/plugins/coreplugin/dialogs/shortcutsettings.h b/src/plugins/coreplugin/dialogs/shortcutsettings.h index 38dfb88894878d6ae6c4027d802d9ea13a2202a6..e6d753664e571d4c3f362cdf2187c70ebddb20bc 100644 --- a/src/plugins/coreplugin/dialogs/shortcutsettings.h +++ b/src/plugins/coreplugin/dialogs/shortcutsettings.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef SHORTCUTSETTINGS_H #define SHORTCUTSETTINGS_H @@ -54,7 +55,8 @@ class ActionManager; class Command; class MainWindow; -struct ShortcutItem { +struct ShortcutItem +{ ICommand *m_cmd; QKeySequence m_key; QTreeWidgetItem *m_item; diff --git a/src/plugins/coreplugin/editmode.cpp b/src/plugins/coreplugin/editmode.cpp index 088cd69f37db7b06a7d2d647ab3e7f004be5af96..516f484caf4ae65c78fb8099bf81c31abeed0a34 100644 --- a/src/plugins/coreplugin/editmode.cpp +++ b/src/plugins/coreplugin/editmode.cpp @@ -51,7 +51,7 @@ using namespace Core; using namespace Core::Internal; -EditMode::EditMode(EditorManager *editorManager): +EditMode::EditMode(EditorManager *editorManager) : m_editorManager(editorManager), m_splitter(new MiniSplitter), m_rightSplitWidgetLayout(new QVBoxLayout) diff --git a/src/plugins/coreplugin/editmode.h b/src/plugins/coreplugin/editmode.h index 234c4aab9e976b6830ba3a9b7d7144d2a63d2fad..95275dd9b18f36dd90254e297faf729f3b5f2d4d 100644 --- a/src/plugins/coreplugin/editmode.h +++ b/src/plugins/coreplugin/editmode.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef EDITMODE_H #define EDITMODE_H diff --git a/src/plugins/coreplugin/editormanager/editorgroup.cpp b/src/plugins/coreplugin/editormanager/editorgroup.cpp index 53b61c74fde2fb5552c4060680f1024b9e518487..5a6fe6156b3ad69ae1f0e3943b7b42ad755795f6 100644 --- a/src/plugins/coreplugin/editormanager/editorgroup.cpp +++ b/src/plugins/coreplugin/editormanager/editorgroup.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "editorgroup.h" #include "editormanager.h" diff --git a/src/plugins/coreplugin/editormanager/editorgroup.h b/src/plugins/coreplugin/editormanager/editorgroup.h index eca333c4df7b19195c70205e91e71fdbb4c7389b..69be7ba6e052cd66138f57b457b2c0cd84d5f985 100644 --- a/src/plugins/coreplugin/editormanager/editorgroup.h +++ b/src/plugins/coreplugin/editormanager/editorgroup.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef EDITORGROUP_H #define EDITORGROUP_H @@ -135,19 +136,24 @@ public: QModelIndex index(int row, int column = 0, const QModelIndex &parent = QModelIndex()) const; void addEditor(IEditor *editor) { insertEditor(rowCount(), editor); } - void insertEditor(int index, IEditor *editor) { + + void insertEditor(int index, IEditor *editor) + { beginInsertRows(QModelIndex(), index, index); m_editors.insert(index, editor); endInsertRows(); } - void removeEditor(IEditor *editor) { + + void removeEditor(IEditor *editor) + { int index = m_editors.indexOf(editor); beginRemoveRows(QModelIndex(), index, index); m_editors.removeAt(index); endRemoveRows(); } - void emitDataChanged(IEditor *editor) { + void emitDataChanged(IEditor *editor) + { int idx = m_editors.indexOf(editor); QModelIndex mindex = index(idx, 0); emit dataChanged(mindex, mindex); diff --git a/src/plugins/coreplugin/editormanager/editormanager.cpp b/src/plugins/coreplugin/editormanager/editormanager.cpp index 7b2e0b2362796e6722b2604e74e410480b6460e1..3cb8e16cf515c1426a364d5b500a6586de097c7c 100644 --- a/src/plugins/coreplugin/editormanager/editormanager.cpp +++ b/src/plugins/coreplugin/editormanager/editormanager.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "editormanager.h" #include "editorsplitter.h" #include "openeditorswindow.h" diff --git a/src/plugins/coreplugin/editormanager/editormanager.h b/src/plugins/coreplugin/editormanager/editormanager.h index 750e35b0cb03d1586c21c701d2be52f26be25a4d..8a9e88ac2291cd591e3c994b00c031f8ee140d9d 100644 --- a/src/plugins/coreplugin/editormanager/editormanager.h +++ b/src/plugins/coreplugin/editormanager/editormanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef EDITORMANAGER_H #define EDITORMANAGER_H diff --git a/src/plugins/coreplugin/editormanager/editorsplitter.cpp b/src/plugins/coreplugin/editormanager/editorsplitter.cpp index 82710e7e930c47fc36cf850ade5ccb1d95bc9340..fe86bf2b0b83e9ca7744fb6e9ade4c9917bc2afe 100644 --- a/src/plugins/coreplugin/editormanager/editorsplitter.cpp +++ b/src/plugins/coreplugin/editormanager/editorsplitter.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "editorsplitter.h" #include "editormanager.h" #include "openeditorswindow.h" diff --git a/src/plugins/coreplugin/editormanager/editorsplitter.h b/src/plugins/coreplugin/editormanager/editorsplitter.h index 12faab68da1db1eae10575db29eae9b1321bcf0e..d3b2696e00ddffa74652738127a760778d22e57e 100644 --- a/src/plugins/coreplugin/editormanager/editorsplitter.h +++ b/src/plugins/coreplugin/editormanager/editorsplitter.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef EDITORSPLITTER_H #define EDITORSPLITTER_H diff --git a/src/plugins/coreplugin/editormanager/ieditor.h b/src/plugins/coreplugin/editormanager/ieditor.h index 66a9fdca14f324210a6a82b80af11e1959ee3c15..4c057fd14e268d642fa6c994d493a86c39227237 100644 --- a/src/plugins/coreplugin/editormanager/ieditor.h +++ b/src/plugins/coreplugin/editormanager/ieditor.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IEDITOR_H #define IEDITOR_H diff --git a/src/plugins/coreplugin/editormanager/ieditorfactory.h b/src/plugins/coreplugin/editormanager/ieditorfactory.h index 2b70ef95b99671ed9b25b7f00cb107a592a43625..60e633db20e3a250c77b662ea98f80236f60852b 100644 --- a/src/plugins/coreplugin/editormanager/ieditorfactory.h +++ b/src/plugins/coreplugin/editormanager/ieditorfactory.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IEDITORFACTORY_H #define IEDITORFACTORY_H diff --git a/src/plugins/coreplugin/editormanager/openeditorsview.cpp b/src/plugins/coreplugin/editormanager/openeditorsview.cpp index b2400853ec51a2cea35bad7bd4ef9c6e9217d960..c6a886ed3044e7da157017a563b7ed52d6868f60 100644 --- a/src/plugins/coreplugin/editormanager/openeditorsview.cpp +++ b/src/plugins/coreplugin/editormanager/openeditorsview.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "openeditorsview.h" #include "editorgroup.h" #include "editormanager.h" @@ -301,10 +302,8 @@ QKeySequence OpenEditorsViewFactory::activationSequence() OpenEditorsViewFactory::OpenEditorsViewFactory() { - } OpenEditorsViewFactory::~OpenEditorsViewFactory() { - } diff --git a/src/plugins/coreplugin/editormanager/openeditorsview.h b/src/plugins/coreplugin/editormanager/openeditorsview.h index d4c20a4a24e149b6eb9a95663f4395bb8adce2ea..e9c8fcd56e3a786deb1c1d5a7d491c645a1dbb34 100644 --- a/src/plugins/coreplugin/editormanager/openeditorsview.h +++ b/src/plugins/coreplugin/editormanager/openeditorsview.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef OPENEDITORSVIEW_H #define OPENEDITORSVIEW_H @@ -88,4 +89,4 @@ public: } // namespace Internal } // namespace Core -#endif +#endif // OPENEDITORSVIEW_H diff --git a/src/plugins/coreplugin/editormanager/openeditorswindow.cpp b/src/plugins/coreplugin/editormanager/openeditorswindow.cpp index 2e97d444f78f813b4099e28c04e8da4fc48c0345..30d6c6b8d488b884139c28c9e35bc062555a95ed 100644 --- a/src/plugins/coreplugin/editormanager/openeditorswindow.cpp +++ b/src/plugins/coreplugin/editormanager/openeditorswindow.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "openeditorswindow.h" #include "editorgroup.h" #include "editormanager.h" diff --git a/src/plugins/coreplugin/editormanager/openeditorswindow.h b/src/plugins/coreplugin/editormanager/openeditorswindow.h index fcefe42eff90d77c0abda777ec3d45ee9c4e32f0..b9613c85ab032d535ff5b61a28587f1eea2b6652 100644 --- a/src/plugins/coreplugin/editormanager/openeditorswindow.h +++ b/src/plugins/coreplugin/editormanager/openeditorswindow.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef OPENEDITORSWINDOW_H #define OPENEDITORSWINDOW_H diff --git a/src/plugins/coreplugin/editormanager/stackededitorgroup.cpp b/src/plugins/coreplugin/editormanager/stackededitorgroup.cpp index ffb0b14743202f1361a179d9062d3a6184f95bf0..e5e4b3e89ad37e67d96fe564d1244cf7a2d2cc8c 100644 --- a/src/plugins/coreplugin/editormanager/stackededitorgroup.cpp +++ b/src/plugins/coreplugin/editormanager/stackededitorgroup.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "stackededitorgroup.h" #include "editormanager.h" #include "coreimpl.h" diff --git a/src/plugins/coreplugin/editormanager/stackededitorgroup.h b/src/plugins/coreplugin/editormanager/stackededitorgroup.h index 5b7cfd5298a26295fce7605a69822ed0d7ffe465..56ecbc9a3a35f0a291f35586d264f31b105b60b2 100644 --- a/src/plugins/coreplugin/editormanager/stackededitorgroup.h +++ b/src/plugins/coreplugin/editormanager/stackededitorgroup.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef STACKEDEDITORGROUP_H #define STACKEDEDITORGROUP_H diff --git a/src/plugins/coreplugin/fancyactionbar.cpp b/src/plugins/coreplugin/fancyactionbar.cpp index 08ad842eed2df43dcbad64340299531e34a1ffca..8893c37dbc8a59ae2bea24848eb0fb4d2dae951e 100644 --- a/src/plugins/coreplugin/fancyactionbar.cpp +++ b/src/plugins/coreplugin/fancyactionbar.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "fancyactionbar.h" #include <QtGui/QHBoxLayout> diff --git a/src/plugins/coreplugin/fancyactionbar.h b/src/plugins/coreplugin/fancyactionbar.h index 701e834ad6080a1e09a66198be496b7e65d126fa..ba71cfb428ea504586df5e9b1c7f317bd41b1857 100644 --- a/src/plugins/coreplugin/fancyactionbar.h +++ b/src/plugins/coreplugin/fancyactionbar.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FANCYACTIONBAR_H #define FANCYACTIONBAR_H diff --git a/src/plugins/coreplugin/fancytabwidget.cpp b/src/plugins/coreplugin/fancytabwidget.cpp index ed57c27b92149472b23fc86b34285c883e1c2fec..fb5ab80469ac84480cbd42b7c36737022e0db614 100644 --- a/src/plugins/coreplugin/fancytabwidget.cpp +++ b/src/plugins/coreplugin/fancytabwidget.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "fancytabwidget.h" #include "stylehelper.h" diff --git a/src/plugins/coreplugin/fancytabwidget.h b/src/plugins/coreplugin/fancytabwidget.h index 19fd1731102131e0fa18fd308d50904c0aa1cfeb..395482cad6c01bb3ef13bdb030e7aad4cde0c93b 100644 --- a/src/plugins/coreplugin/fancytabwidget.h +++ b/src/plugins/coreplugin/fancytabwidget.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FANCYTABWIDGET_H #define FANCYTABWIDGET_H @@ -115,4 +116,4 @@ private: } // namespace Internal } // namespace Core -#endif +#endif // FANCYTABWIDGET_H diff --git a/src/plugins/coreplugin/fileiconprovider.cpp b/src/plugins/coreplugin/fileiconprovider.cpp index 8e01ecbb8d75cc428e1c5767cf3a1bba4d19876e..022807e443e6edcba733507bf88c17545f12810b 100644 --- a/src/plugins/coreplugin/fileiconprovider.cpp +++ b/src/plugins/coreplugin/fileiconprovider.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "fileiconprovider.h" using namespace Core; @@ -46,8 +47,8 @@ using namespace Core; FileIconProvider *FileIconProvider::m_instance = 0; -FileIconProvider::FileIconProvider(): - m_unknownFileIcon(QLatin1String(":/qworkbench/images/unknownfile.png")) +FileIconProvider::FileIconProvider() + : m_unknownFileIcon(QLatin1String(":/qworkbench/images/unknownfile.png")) { } diff --git a/src/plugins/coreplugin/fileiconprovider.h b/src/plugins/coreplugin/fileiconprovider.h index 4124eeb43d49bd1d77b277aff9076c041e120c69..6c7deea35aa466b406160eea32b3c34d801578f9 100644 --- a/src/plugins/coreplugin/fileiconprovider.h +++ b/src/plugins/coreplugin/fileiconprovider.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FILEICONPROVIDER_H #define FILEICONPROVIDER_H diff --git a/src/plugins/coreplugin/filemanager.cpp b/src/plugins/coreplugin/filemanager.cpp index 299bba4ff9082c05f547c9ade2b72e874477fb7f..3f622bf97398e9303cc74228bbb69c7b63c0bdb4 100644 --- a/src/plugins/coreplugin/filemanager.cpp +++ b/src/plugins/coreplugin/filemanager.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "filemanager.h" #include "ifile.h" #include "mainwindow.h" diff --git a/src/plugins/coreplugin/filemanager.h b/src/plugins/coreplugin/filemanager.h index c6759d5b45e865318ed95ea54c5bd7e7e5780751..fbea2af6d1c9871bf6391b1b36b0c1fdf4833f27 100644 --- a/src/plugins/coreplugin/filemanager.h +++ b/src/plugins/coreplugin/filemanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FILEMANAGER_H #define FILEMANAGER_H @@ -60,7 +61,8 @@ class CORE_EXPORT FileManager : public QObject { Q_OBJECT - struct FileInfo { + struct FileInfo + { QString fileName; QDateTime modified; QFile::Permissions permissions; diff --git a/src/plugins/coreplugin/findplaceholder.cpp b/src/plugins/coreplugin/findplaceholder.cpp index ec80b530b5d30ebf7205fbcf7a19f8e0e4ada89a..72a305e63b41ba6fa1f98063c93bee565b70529f 100644 --- a/src/plugins/coreplugin/findplaceholder.cpp +++ b/src/plugins/coreplugin/findplaceholder.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "findplaceholder.h" #include "modemanager.h" @@ -41,7 +42,7 @@ using namespace Core; FindToolBarPlaceHolder *FindToolBarPlaceHolder::m_current = 0; FindToolBarPlaceHolder::FindToolBarPlaceHolder(Core::IMode *mode, QWidget *parent) - :QWidget(parent), m_mode(mode) + : QWidget(parent), m_mode(mode) { setLayout(new QVBoxLayout); setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Maximum); @@ -52,7 +53,6 @@ FindToolBarPlaceHolder::FindToolBarPlaceHolder(Core::IMode *mode, QWidget *paren FindToolBarPlaceHolder::~FindToolBarPlaceHolder() { - } void FindToolBarPlaceHolder::currentModeChanged(Core::IMode *mode) diff --git a/src/plugins/coreplugin/findplaceholder.h b/src/plugins/coreplugin/findplaceholder.h index 89850d812ea07f0b38ad0175a2e03afb40d8f52e..41cfaa6665e2dfec75bf46b8cc9ff96e8c75e386 100644 --- a/src/plugins/coreplugin/findplaceholder.h +++ b/src/plugins/coreplugin/findplaceholder.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FINDPLACEHOLDER_H #define FINDPLACEHOLDER_H diff --git a/src/plugins/coreplugin/flowlayout.cpp b/src/plugins/coreplugin/flowlayout.cpp index 1c43dead53cda0bd62a5e0c104ecf26637402046..da638ea1986ff2d19a6bb1cde95af52338fb0aee 100644 --- a/src/plugins/coreplugin/flowlayout.cpp +++ b/src/plugins/coreplugin/flowlayout.cpp @@ -30,27 +30,13 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -/**************************************************************************** -** -** Copyright (C) 2004-$THISYEAR$ Trolltech AS. All rights reserved. -** -** This file is part of the $MODULE$ of the Qt Toolkit. -** -** $LICENSE$ -** -** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE -** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. -** -****************************************************************************/ - -#include <QtGui> #include "flowlayout.h" using namespace Core::Internal; FlowLayout::FlowLayout(QWidget *parent, int margin, int spacing) - : QLayout(parent) + : QLayout(parent) { setMargin(margin); setSpacing(spacing); @@ -121,11 +107,10 @@ QSize FlowLayout::sizeHint() const QSize FlowLayout::minimumSize() const { QSize size; - QLayoutItem *item; - foreach (item, itemList) + foreach (QLayoutItem *item, itemList) size = size.expandedTo(item->minimumSize()); - size += QSize(2*margin(), 2*margin()); + size += QSize(2 * margin(), 2 * margin()); return size; } @@ -135,8 +120,7 @@ int FlowLayout::doLayout(const QRect &rect, bool testOnly) const int y = rect.y(); int lineHeight = 0; - QLayoutItem *item; - foreach (item, itemList) { + foreach (QLayoutItem *item, itemList) { int nextX = x + item->sizeHint().width() + spacing(); if (nextX - spacing() > rect.right() && lineHeight > 0) { x = rect.x(); diff --git a/src/plugins/coreplugin/flowlayout.h b/src/plugins/coreplugin/flowlayout.h index f0a7d4235b9293146d7114c21c416b02f1fd91de..b8fae2446b4271d65a483e4f4bf35185b5143774 100644 --- a/src/plugins/coreplugin/flowlayout.h +++ b/src/plugins/coreplugin/flowlayout.h @@ -30,18 +30,6 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -/**************************************************************************** -** -** Copyright (C) 2004-$THISYEAR$ Trolltech AS. All rights reserved. -** -** This file is part of the $MODULE$ of the Qt Toolkit. -** -** $LICENSE$ -** -** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE -** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. -** -****************************************************************************/ #ifndef FLOWLAYOUT_H #define FLOWLAYOUT_H @@ -80,4 +68,4 @@ private: } // namespace Internal } // namespace Core -#endif +#endif // FLOWLAYOUT_H diff --git a/src/plugins/coreplugin/generalsettings.cpp b/src/plugins/coreplugin/generalsettings.cpp index 8595eb03ee4d5fa91839b194db135706680e59da..eea09bfaf36177d431a47f23ef2e57ba75e91519 100644 --- a/src/plugins/coreplugin/generalsettings.cpp +++ b/src/plugins/coreplugin/generalsettings.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "generalsettings.h" #include "stylehelper.h" diff --git a/src/plugins/coreplugin/generalsettings.h b/src/plugins/coreplugin/generalsettings.h index 0cffc9caaf9463b067c2d79e6c1f537bfce29fc6..3a0c18fdd0557556029ac577ad789ee4a014682a 100644 --- a/src/plugins/coreplugin/generalsettings.h +++ b/src/plugins/coreplugin/generalsettings.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef GENERALSETTINGS_H #define GENERALSETTINGS_H diff --git a/src/plugins/coreplugin/icontext.h b/src/plugins/coreplugin/icontext.h index a873afb4c5bdba72c8fb166c58e5ab6039573a22..87cc54944086719fc14a6f02136d955ef508dfcb 100644 --- a/src/plugins/coreplugin/icontext.h +++ b/src/plugins/coreplugin/icontext.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef ICONTEXT_H #define ICONTEXT_H diff --git a/src/plugins/coreplugin/icore.h b/src/plugins/coreplugin/icore.h index ad85e4be18850f893ed07345c80c0c45f7e1aac4..c06c7c6a4ddc454e6dfb08f08328aff4a49929bf 100644 --- a/src/plugins/coreplugin/icore.h +++ b/src/plugins/coreplugin/icore.h @@ -72,7 +72,6 @@ class CORE_EXPORT ICore : public QObject Q_OBJECT public: - ICore() {} virtual ~ICore() {} @@ -131,4 +130,4 @@ signals: } // namespace Core -#endif //ICORE_H +#endif // ICORE_H diff --git a/src/plugins/coreplugin/icorelistener.h b/src/plugins/coreplugin/icorelistener.h index 3ff0a859a1f97ca8a8dc0a694668086ba15e8990..a957a97b00dfcc9c60184dcd8b177c01360fd023 100644 --- a/src/plugins/coreplugin/icorelistener.h +++ b/src/plugins/coreplugin/icorelistener.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef ICORELISTENER_H #define ICORELISTENER_H diff --git a/src/plugins/coreplugin/ifile.h b/src/plugins/coreplugin/ifile.h index 40a03b484e0bb6d55b6ed64d2b8c4fff6bdf66c9..764fe2c68a4bfbc297d10831dcdffafe308de262 100644 --- a/src/plugins/coreplugin/ifile.h +++ b/src/plugins/coreplugin/ifile.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IFILE_H #define IFILE_H @@ -67,6 +68,6 @@ signals: void changed(); }; -} //namespace +} // namespace Core -#endif //IFILE_H +#endif // IFILE_H diff --git a/src/plugins/coreplugin/ifilefactory.h b/src/plugins/coreplugin/ifilefactory.h index e8dcf155e18799e2bee1aaa8fd221aa004cc9d50..af05517afc625076e38e61d0b292dbd2070ff6a3 100644 --- a/src/plugins/coreplugin/ifilefactory.h +++ b/src/plugins/coreplugin/ifilefactory.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IFILEFACTORY_H #define IFILEFACTORY_H diff --git a/src/plugins/coreplugin/ifilewizardextension.h b/src/plugins/coreplugin/ifilewizardextension.h index 238d628a78b67f6bb5a5f01e49e3a94c39565bec..31aa8714d0b0a492495b925d50da1bfbfa11f210 100644 --- a/src/plugins/coreplugin/ifilewizardextension.h +++ b/src/plugins/coreplugin/ifilewizardextension.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IFILEWIZARDEXTENSION_H #define IFILEWIZARDEXTENSION_H diff --git a/src/plugins/coreplugin/imode.h b/src/plugins/coreplugin/imode.h index 080b5d9be0f9a39b904f285a268bf527cbd5de50..fa93092f889eaab55bf913b8663c7d5fd917f527 100644 --- a/src/plugins/coreplugin/imode.h +++ b/src/plugins/coreplugin/imode.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IMODE_H #define IMODE_H diff --git a/src/plugins/coreplugin/inavigationwidgetfactory.cpp b/src/plugins/coreplugin/inavigationwidgetfactory.cpp index 74772c4cc910c180d8731e4ed4f502cfa46a9484..0e559c62e390b1d2dcd16b5e0400212028ab482c 100644 --- a/src/plugins/coreplugin/inavigationwidgetfactory.cpp +++ b/src/plugins/coreplugin/inavigationwidgetfactory.cpp @@ -30,18 +30,17 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "inavigationwidgetfactory.h" using namespace Core; INavigationWidgetFactory::INavigationWidgetFactory() { - } INavigationWidgetFactory::~INavigationWidgetFactory() { - } QKeySequence INavigationWidgetFactory::activationSequence() diff --git a/src/plugins/coreplugin/inavigationwidgetfactory.h b/src/plugins/coreplugin/inavigationwidgetfactory.h index f182f3accaa42b48a17b4c6879103ed3f390ad26..064492532c752487bfb3a40e5714e05de47021fe 100644 --- a/src/plugins/coreplugin/inavigationwidgetfactory.h +++ b/src/plugins/coreplugin/inavigationwidgetfactory.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef INAVIGATIONWIDGET_H #define INAVIGATIONWIDGET_H @@ -65,6 +66,7 @@ public: // Similar to how IView virtual NavigationView createWidget() = 0; }; -} + +} // namespace Core #endif // INAVIGATIONWIDGET_H diff --git a/src/plugins/coreplugin/ioutputpane.h b/src/plugins/coreplugin/ioutputpane.h index 9847c1a1b2515ba91ab108151b027f266c24a014..ecb0f392788204ca31ec6a06b2ef967a79c160f3 100644 --- a/src/plugins/coreplugin/ioutputpane.h +++ b/src/plugins/coreplugin/ioutputpane.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IOUTPUTPANE_H #define IOUTPUTPANE_H diff --git a/src/plugins/coreplugin/iversioncontrol.h b/src/plugins/coreplugin/iversioncontrol.h index e2d3de1ec3807227c66f5d179f9ccbd9695b5191..45b07faa8e999663187d1f888b72d621b47510d5 100644 --- a/src/plugins/coreplugin/iversioncontrol.h +++ b/src/plugins/coreplugin/iversioncontrol.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IVERSIONCONTROL_H #define IVERSIONCONTROL_H diff --git a/src/plugins/coreplugin/iview.h b/src/plugins/coreplugin/iview.h index dd0a222b59ca78ad5df37209dbf1b09a81c043ba..cd242ee8f603d26c0152c760200bb0028722bc3b 100644 --- a/src/plugins/coreplugin/iview.h +++ b/src/plugins/coreplugin/iview.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef IVIEW_H #define IVIEW_H diff --git a/src/plugins/coreplugin/mainwindow.cpp b/src/plugins/coreplugin/mainwindow.cpp index a90f1ff14e90b97c8bd003b63c96044f2ed199e1..6e11f42abef202cca2022d19d506ae7babcd5d24 100644 --- a/src/plugins/coreplugin/mainwindow.cpp +++ b/src/plugins/coreplugin/mainwindow.cpp @@ -53,6 +53,7 @@ #include "progressview.h" #include "shortcutsettings.h" #include "vcsmanager.h" + #include "scriptmanager.h" #include "settingsdialog.h" #include "stylehelper.h" diff --git a/src/plugins/coreplugin/mainwindow.h b/src/plugins/coreplugin/mainwindow.h index 00721a1662eea9229e9b1754198db5a11c22d660..e465cc27fbff03f40b74b535429048aa06eebd81 100644 --- a/src/plugins/coreplugin/mainwindow.h +++ b/src/plugins/coreplugin/mainwindow.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MAINWINDOW_H #define MAINWINDOW_H @@ -56,34 +57,34 @@ namespace Core { class ActionManagerInterface; class BaseMode; +class BaseView; class EditorManager; class FileManager; class IContext; class MessageManager; -class ModeManager; class MimeDatabase; +class ModeManager; class ProgressManagerInterface; -class VCSManager; +class RightPaneWidget; class ScriptManagerInterface; class UniqueIDManager; class VariableManager; +class VCSManager; class ViewManagerInterface; -class BaseView; -class RightPaneWidget; namespace Internal { -class CoreImpl; class ActionManager; -class ProgressManager; -class OutputPane; -class ViewManager; -class GeneralSettings; -class ShortcutSettings; +class CoreImpl; class FancyTabWidget; +class GeneralSettings; class NavigationWidget; +class OutputPane; +class ProgressManager; +class ShortcutSettings; +class ViewManager; -class CORE_EXPORT MainWindow : public QMainWindow +class CORE_EXPORT MainWindow : public QMainWindow { Q_OBJECT @@ -129,7 +130,6 @@ public: QMenu *createPopupMenu(); - void setSuppressNavigationWidget(bool suppress); signals: diff --git a/src/plugins/coreplugin/manhattanstyle.cpp b/src/plugins/coreplugin/manhattanstyle.cpp index d82059f00df287543d3c13147f4672d4222a8911..1fe95c8f425fd9138762158ce3aa87bf56297e5d 100644 --- a/src/plugins/coreplugin/manhattanstyle.cpp +++ b/src/plugins/coreplugin/manhattanstyle.cpp @@ -30,20 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -/**************************************************************************** -** -** Copyright (C) 2007-$THISYEAR$ $TROLLTECH$. All rights reserved. -** -** This file is part of the Manhattan Style project -** -** $TROLLTECH_GPL_LICENSE$ -** -** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE -** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. -** -****************************************************************************/ #include "manhattanstyle.h" + #include <QStyleOption> #include <QPainter> #include <QScrollArea> diff --git a/src/plugins/coreplugin/manhattanstyle.h b/src/plugins/coreplugin/manhattanstyle.h index 685a35da663eb684a8a1f2bad90c00919f9e1327..6210df6bf850386c8e4fa853becff8147af5a140 100644 --- a/src/plugins/coreplugin/manhattanstyle.h +++ b/src/plugins/coreplugin/manhattanstyle.h @@ -30,18 +30,6 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ -/**************************************************************************** -** -** Copyright (C) 2007-$THISYEAR$ $TROLLTECH$. All rights reserved. -** -** This file is part of the ManhattanStyle project on Trolltech Labs. -** -** $TROLLTECH_GPL_LICENSE$ -** -** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE -** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. -** -****************************************************************************/ #ifndef MANHATTANSTYLE_H #define MANHATTANSTYLE_H diff --git a/src/plugins/coreplugin/messagemanager.cpp b/src/plugins/coreplugin/messagemanager.cpp index a6268fbd2503ad0a7a4297a3eba44e8cc47ecf8f..4b72673bce360c58ab43d7a669c4845c11b7660b 100644 --- a/src/plugins/coreplugin/messagemanager.cpp +++ b/src/plugins/coreplugin/messagemanager.cpp @@ -30,21 +30,21 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "messagemanager.h" #include "messageoutputwindow.h" +#include <extensionsystem/pluginmanager.h> + #include <QtGui/QStatusBar> #include <QtGui/QApplication> -#include <extensionsystem/pluginmanager.h> - using namespace Core; MessageManager *MessageManager::m_instance = 0; -MessageManager::MessageManager(): - m_pm(0), - m_messageOutputWindow(0) +MessageManager::MessageManager() + : m_pm(0), m_messageOutputWindow(0) { m_instance = this; } diff --git a/src/plugins/coreplugin/messagemanager.h b/src/plugins/coreplugin/messagemanager.h index f2854108d69f1b00ef5deba0e305ae19c4a4193e..a92263a056689cba61bb80f5dfb4bd28434d64a6 100644 --- a/src/plugins/coreplugin/messagemanager.h +++ b/src/plugins/coreplugin/messagemanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MESSAGEMANAGER_H #define MESSAGEMANAGER_H diff --git a/src/plugins/coreplugin/messageoutputwindow.cpp b/src/plugins/coreplugin/messageoutputwindow.cpp index 2ffe82e9df68a8d99e16282c3159f1c68d608773..b7afcca98812eccab0c3e28467edd92c16de6c03 100644 --- a/src/plugins/coreplugin/messageoutputwindow.cpp +++ b/src/plugins/coreplugin/messageoutputwindow.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "messageoutputwindow.h" #include <QtGui/QTextEdit> diff --git a/src/plugins/coreplugin/messageoutputwindow.h b/src/plugins/coreplugin/messageoutputwindow.h index 1373ea363d4c110cce06970d79cffc5740c71a75..06d9d892cf28ae875ab0c137a6493486ad56ec84 100644 --- a/src/plugins/coreplugin/messageoutputwindow.h +++ b/src/plugins/coreplugin/messageoutputwindow.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MESSAGEOUTPUTWINDOW_H #define MESSAGEOUTPUTWINDOW_H diff --git a/src/plugins/coreplugin/mimedatabase.cpp b/src/plugins/coreplugin/mimedatabase.cpp index d49d4728e6b5646e1c809c3706fe7c4b360bb883..7ee16e07763ec9ae43f014b0b11dd0a95b1965fe 100644 --- a/src/plugins/coreplugin/mimedatabase.cpp +++ b/src/plugins/coreplugin/mimedatabase.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "mimedatabase.h" #include <QtCore/QStringList> @@ -93,7 +94,6 @@ enum { BinaryMatchPriority = 1, TextMatchPriority = 2}; */ namespace Core { - namespace Internal { // FileMatchContext: Passed on to the mimetypes from the database @@ -786,7 +786,8 @@ bool BaseMimeTypeParser::parse(QIODevice *dev, const QString &fileName, QString enum { Dangling = 32767 }; -struct MimeMapEntry { +struct MimeMapEntry +{ explicit MimeMapEntry(const MimeType &t = MimeType(), int aLevel = Dangling); MimeType type; int level; // hierachy level @@ -821,7 +822,8 @@ MimeMapEntry::MimeMapEntry(const MimeType &t, int aLevel) : * to check the most specific types first). Starting a recursion from the * leaves is not suitable since it will hit parent nodes several times. */ -class MimeDatabasePrivate { +class MimeDatabasePrivate +{ Q_DISABLE_COPY(MimeDatabasePrivate) public: MimeDatabasePrivate(); diff --git a/src/plugins/coreplugin/mimedatabase.h b/src/plugins/coreplugin/mimedatabase.h index d4f96cf8d9047132b4d28d299ca88b4b4d75aac9..3a58bff0cb05b572a80242a668b3a08b1713f47b 100644 --- a/src/plugins/coreplugin/mimedatabase.h +++ b/src/plugins/coreplugin/mimedatabase.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MIMEDATABASE_H #define MIMEDATABASE_H @@ -57,7 +58,8 @@ namespace Internal { } /* Magic (file contents) matcher interface. */ -class CORE_EXPORT IMagicMatcher { +class CORE_EXPORT IMagicMatcher +{ Q_DISABLE_COPY(IMagicMatcher) protected: IMagicMatcher() {} @@ -72,7 +74,8 @@ public: /* Utility class: A standard Magic match rule based on contents. Provides * static factory methods for creation (currently only for "string". This can * be extended to handle "little16"/"big16", etc.). */ -class CORE_EXPORT MagicRule { +class CORE_EXPORT MagicRule +{ Q_DISABLE_COPY(MagicRule) public: explicit MagicRule(const QByteArray &pattern, int startPos, int endPos); @@ -89,7 +92,8 @@ private: /* Utility class: A Magic matcher that checks a number of rules based on * operator "or". It is used for rules parsed from XML files. */ -class CORE_EXPORT MagicRuleMatcher : public IMagicMatcher { +class CORE_EXPORT MagicRuleMatcher : public IMagicMatcher +{ Q_DISABLE_COPY(MagicRuleMatcher) public: typedef QSharedPointer<MagicRule> MagicRuleSharedPointer; diff --git a/src/plugins/coreplugin/minisplitter.cpp b/src/plugins/coreplugin/minisplitter.cpp index dfdad9fb5376582f2e64c30822cb83bbbb49794f..7d0e6edff6db42768bd1a848524070b955a7e17f 100644 --- a/src/plugins/coreplugin/minisplitter.cpp +++ b/src/plugins/coreplugin/minisplitter.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "minisplitter.h" #include "stylehelper.h" diff --git a/src/plugins/coreplugin/minisplitter.h b/src/plugins/coreplugin/minisplitter.h index aedb2b757c72382d4d7178dd6e667d82eee067bc..d5ca2e7196de791c30532391dc1e86a2539538b8 100644 --- a/src/plugins/coreplugin/minisplitter.h +++ b/src/plugins/coreplugin/minisplitter.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MINISPLITTER_H #define MINISPLITTER_H diff --git a/src/plugins/coreplugin/modemanager.cpp b/src/plugins/coreplugin/modemanager.cpp index 74027ab391a19a67aa10d16168655ec0e111bb92..58a02bd4c2e0d718cb9e8b3bedca813acacc45fa 100644 --- a/src/plugins/coreplugin/modemanager.cpp +++ b/src/plugins/coreplugin/modemanager.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "modemanager.h" #include "fancytabwidget.h" #include "fancyactionbar.h" @@ -55,7 +56,7 @@ using namespace Core::Internal; ModeManager *ModeManager::m_instance = 0; -ModeManager::ModeManager(Internal::MainWindow *mainWindow, FancyTabWidget *modeStack): +ModeManager::ModeManager(Internal::MainWindow *mainWindow, FancyTabWidget *modeStack) : m_mainWindow(mainWindow), m_modeStack(modeStack), m_signalMapper(new QSignalMapper(this)) diff --git a/src/plugins/coreplugin/modemanager.h b/src/plugins/coreplugin/modemanager.h index 775c8d4a611e4c9e3907faf4943041ba407fa7e0..96e873f46c6a91ae760d9e128594c7b8a6870af1 100644 --- a/src/plugins/coreplugin/modemanager.h +++ b/src/plugins/coreplugin/modemanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef MODEMANAGER_H #define MODEMANAGER_H diff --git a/src/plugins/coreplugin/navigationwidget.cpp b/src/plugins/coreplugin/navigationwidget.cpp index 0a29c24d7c310992e8b2f8de66569b223eb6480b..eda1123c02d4b9eccb01ccb5daca3705ef93be6a 100644 --- a/src/plugins/coreplugin/navigationwidget.cpp +++ b/src/plugins/coreplugin/navigationwidget.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "navigationwidget.h" #include <coreplugin/icore.h> @@ -134,10 +135,10 @@ void NavigationWidgetPlaceHolder::currentModeAboutToChange(Core::IMode *mode) NavigationWidget *NavigationWidget::m_instance = 0; NavigationWidget::NavigationWidget(QAction *toggleSideBarAction) - : m_shown(true) - , m_suppressed(false) - , m_width(0) - , m_toggleSideBarAction(toggleSideBarAction) + : m_shown(true), + m_suppressed(false), + m_width(0), + m_toggleSideBarAction(toggleSideBarAction) { connect(ExtensionSystem::PluginManager::instance(), SIGNAL(objectAdded(QObject*)), this, SLOT(objectAdded(QObject*))); diff --git a/src/plugins/coreplugin/navigationwidget.h b/src/plugins/coreplugin/navigationwidget.h index d8244f88682eb9636e243e702e52d4792a71869f..01d9f2893e2e581328580b405f407917f0558b53 100644 --- a/src/plugins/coreplugin/navigationwidget.h +++ b/src/plugins/coreplugin/navigationwidget.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef NAVIGATIONWIDGET_H #define NAVIGATIONWIDGET_H diff --git a/src/plugins/coreplugin/outputpane.cpp b/src/plugins/coreplugin/outputpane.cpp index 92378d72e96fea956c4bbca29a7e2c6716b4808d..b92d9270223db7ae891f891c88109bcd82122284 100644 --- a/src/plugins/coreplugin/outputpane.cpp +++ b/src/plugins/coreplugin/outputpane.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "outputpane.h" #include "coreconstants.h" #include "ioutputpane.h" diff --git a/src/plugins/coreplugin/outputpane.h b/src/plugins/coreplugin/outputpane.h index fcc54745b00c947265c139d9956a306e40774834..489ff87bac0d70b7b72c5360f4b2e72ea15e1bc1 100644 --- a/src/plugins/coreplugin/outputpane.h +++ b/src/plugins/coreplugin/outputpane.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef OUTPUTPANE_H #define OUTPUTPANE_H diff --git a/src/plugins/coreplugin/plugindialog.cpp b/src/plugins/coreplugin/plugindialog.cpp index dcf8c9b826801fe43faa825255f1a0082831ed55..a22df97f5f213902434a4fe32bf5cebd4ac7eeab 100644 --- a/src/plugins/coreplugin/plugindialog.cpp +++ b/src/plugins/coreplugin/plugindialog.cpp @@ -30,7 +30,9 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "plugindialog.h" + #include <extensionsystem/pluginmanager.h> #include <extensionsystem/pluginview.h> #include <extensionsystem/plugindetailsview.h> @@ -47,8 +49,8 @@ using namespace Core::Internal; PluginDialog::PluginDialog(ExtensionSystem::PluginManager *manager, QWidget *parent) - : QDialog(parent) - , m_view(new ExtensionSystem::PluginView(manager, this)) + : QDialog(parent), + m_view(new ExtensionSystem::PluginView(manager, this)) { QVBoxLayout *vl = new QVBoxLayout(this); vl->addWidget(m_view); diff --git a/src/plugins/coreplugin/plugindialog.h b/src/plugins/coreplugin/plugindialog.h index d3c0d312a6b119933af882bd2bc2a4080240475e..08cfee7ae705283b022a079f3e405e780c2fb0d0 100644 --- a/src/plugins/coreplugin/plugindialog.h +++ b/src/plugins/coreplugin/plugindialog.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PLUGINDIALOG_H #define PLUGINDIALOG_H @@ -72,4 +73,4 @@ private: } // namespace Internal } // namespace Core -#endif +#endif // PLUGINDIALOG_H diff --git a/src/plugins/coreplugin/progressmanager/futureprogress.cpp b/src/plugins/coreplugin/progressmanager/futureprogress.cpp index 2aeb817bc2fc7633721a1feb3e8165ff6cb232d1..9e662585d2925e92f7e1cecb121dd91160132b48 100644 --- a/src/plugins/coreplugin/progressmanager/futureprogress.cpp +++ b/src/plugins/coreplugin/progressmanager/futureprogress.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "futureprogress.h" #include "progresspie.h" diff --git a/src/plugins/coreplugin/progressmanager/futureprogress.h b/src/plugins/coreplugin/progressmanager/futureprogress.h index 4f46a4a1fb2a96d4924e246ce39cef30c91030ea..bd1d7e7bddf9c244bfc7a6798ea72026ac91887f 100644 --- a/src/plugins/coreplugin/progressmanager/futureprogress.h +++ b/src/plugins/coreplugin/progressmanager/futureprogress.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef FUTUREPROGRESS_H #define FUTUREPROGRESS_H @@ -91,4 +92,5 @@ private: }; } // namespace Core + #endif // FUTUREPROGRESS_H diff --git a/src/plugins/coreplugin/progressmanager/progressmanager.cpp b/src/plugins/coreplugin/progressmanager/progressmanager.cpp index 6e4e15644e9b8553d57c3ad7a5cac9e58306d76d..ce8474346044d55330e60821ae4247293ea2f142 100644 --- a/src/plugins/coreplugin/progressmanager/progressmanager.cpp +++ b/src/plugins/coreplugin/progressmanager/progressmanager.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "progressmanager.h" #include "progressview.h" #include "coreimpl.h" @@ -56,7 +57,6 @@ ProgressManager::~ProgressManager() void ProgressManager::init() { - } void ProgressManager::cancelTasks(const QString &type) diff --git a/src/plugins/coreplugin/progressmanager/progressmanager.h b/src/plugins/coreplugin/progressmanager/progressmanager.h index 0c40dcc0faaa9b4f9a5a78be9dc2630be5bbd025..8413a252ebd2c9eaf5a7cfc5d05c085d6c7e0938 100644 --- a/src/plugins/coreplugin/progressmanager/progressmanager.h +++ b/src/plugins/coreplugin/progressmanager/progressmanager.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PROGRESSMANAGER_H #define PROGRESSMANAGER_H @@ -40,7 +41,6 @@ #include <QtCore/QFutureWatcher> namespace Core { - namespace Internal { class ProgressView; @@ -71,4 +71,4 @@ private: } // namespace Internal } // namespace Core -#endif //PROGRESSMANAGER_H +#endif // PROGRESSMANAGER_H diff --git a/src/plugins/coreplugin/progressmanager/progressmanagerinterface.h b/src/plugins/coreplugin/progressmanager/progressmanagerinterface.h index 6a89293467fd539ddbaa6d09efb7223e6eca91e4..e491eaaa2987ee28a28ce2f962e30ac850064df9 100644 --- a/src/plugins/coreplugin/progressmanager/progressmanagerinterface.h +++ b/src/plugins/coreplugin/progressmanager/progressmanagerinterface.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PROGRESSMANAGERINTERFACE_H #define PROGRESSMANAGERINTERFACE_H @@ -57,6 +58,6 @@ public slots: virtual void cancelTasks(const QString &type) = 0; }; -} //namespace +} // namespace Core #endif //PROGRESSMANAGERINTERFACE_H diff --git a/src/plugins/coreplugin/progressmanager/progresspie.cpp b/src/plugins/coreplugin/progressmanager/progresspie.cpp index 7a237fe5d9f2d0748cddc4e594374326ff912753..aaf090a0fd687f921bc066d8f26c744cc8136921 100644 --- a/src/plugins/coreplugin/progressmanager/progresspie.cpp +++ b/src/plugins/coreplugin/progressmanager/progresspie.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "progresspie.h" #include "stylehelper.h" @@ -47,7 +48,6 @@ ProgressBar::ProgressBar(QWidget *parent) ProgressBar::~ProgressBar() { - } QString ProgressBar::title() const @@ -60,7 +60,6 @@ bool ProgressBar::hasError() const return m_error; } - void ProgressBar::setTitle(const QString &title) { m_title = title; diff --git a/src/plugins/coreplugin/progressmanager/progresspie.h b/src/plugins/coreplugin/progressmanager/progresspie.h index dfeb33e5581fefa685ebc2e1968c3889728cb20e..23992025edab95e1a900017ce0b854f7dcf3b71f 100644 --- a/src/plugins/coreplugin/progressmanager/progresspie.h +++ b/src/plugins/coreplugin/progressmanager/progresspie.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PROGRESSPIE_H #define PROGRESSPIE_H diff --git a/src/plugins/coreplugin/progressmanager/progressview.cpp b/src/plugins/coreplugin/progressmanager/progressview.cpp index bb0008056bdf241ac55dfbfa3c0431a2715e633b..96b3158266075e0f80c6ddf85dbb3069690546ec 100644 --- a/src/plugins/coreplugin/progressmanager/progressview.cpp +++ b/src/plugins/coreplugin/progressmanager/progressview.cpp @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #include "progressview.h" #include "futureprogress.h" @@ -39,7 +40,7 @@ using namespace Core; using namespace Core::Internal; ProgressView::ProgressView(QWidget *parent) -: QWidget(parent) + : QWidget(parent) { m_layout = new QVBoxLayout; setLayout(m_layout); diff --git a/src/plugins/coreplugin/progressmanager/progressview.h b/src/plugins/coreplugin/progressmanager/progressview.h index 7e832f92f24c99cfd304a5979e0f0b7399ccd7a0..3d164a7ccbce776e47754eb4f03dd08470f92fbe 100644 --- a/src/plugins/coreplugin/progressmanager/progressview.h +++ b/src/plugins/coreplugin/progressmanager/progressview.h @@ -30,6 +30,7 @@ ** 1.2, included in the file GPL_EXCEPTION.txt in this package. ** ***************************************************************************/ + #ifndef PROGRESSVIEW_H #define PROGRESSVIEW_H @@ -78,4 +79,4 @@ private: } // namespace Internal } // namespace Core -#endif //PROGRESSVIEW_H +#endif // PROGRESSVIEW_H