Commit 1472bdb0 authored by hjk's avatar hjk
Browse files

some file cosmetics (mostly #include order and whitespace)

parent e2fb40c7
......@@ -30,9 +30,11 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#include <QtGui/QApplication>
#include "textfinder.h"
#include <QtGui/QApplication>
int main(int argc, char *argv[])
{
Q_INIT_RESOURCE(textfinder);
......
......@@ -30,10 +30,12 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#include <QtGui/QMessageBox>
#include "textfinder.h"
#include <QtCore/QFile>
#include <QtCore/QTextStream>
#include "textfinder.h"
#include <QtGui/QMessageBox>
TextFinder::TextFinder(QWidget *parent, Qt::WFlags flags)
: QWidget(parent, flags)
......
......@@ -30,12 +30,14 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#ifndef TEXTFINDER_H
#define TEXTFINDER_H
#include <QtGui/QWidget>
#include "ui_textfinder.h"
#include <QtGui/QWidget>
class QPushButton;
class QTextEdit;
class QLineEdit;
......
......@@ -30,13 +30,14 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#include "cgi.h"
#include <QByteArray>
// -------------------------------------------------------------------------------------------------
const char *cgi_chars = "0123456789abcdef"; // RFC 1738 suggests lower-case to be optimal
QString CGI::encodeURL(const QString &rawText)
{
QByteArray utf = rawText.toUtf8();
......@@ -424,5 +425,3 @@ QString CGI::encodeHTML(const QString &rawText, int conversionFlags)
return enc;
}
// -------------------------------------------------------------------------------------------------
......@@ -30,8 +30,10 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#ifndef _CGI_H_
#define _CGI_H_
#ifndef CGI_H
#define CGI_H
#include <QString>
class CGI
......@@ -54,5 +56,4 @@ private:
inline QChar hexToChar(const QString &hx);
};
#endif // _CGI_H_
#endif // CGI_H
......@@ -30,6 +30,7 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#include "fetcher.h"
#include "cgi.h"
......@@ -44,7 +45,7 @@ Fetcher::Fetcher(const QString &host)
m_status = 0;
m_hadError = false;
connect(this, SIGNAL(requestFinished(int,bool)), SLOT(gotRequestFinished(int,bool)));
connect(this, SIGNAL(readyRead(const QHttpResponseHeader &)), SLOT(gotReadyRead(const QHttpResponseHeader &)));
connect(this, SIGNAL(readyRead(QHttpResponseHeader)), SLOT(gotReadyRead(QHttpResponseHeader)));
}
int Fetcher::fetch(const QString &url)
......
......@@ -30,12 +30,12 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#ifndef FETCHER_H
#define FETCHER_H
#include <QHttp>
#include <QHttpResponseHeader>
#include <QString>
class Fetcher : public QHttp
......
......@@ -30,6 +30,7 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#include "poster.h"
#include "cgi.h"
......@@ -43,7 +44,7 @@ Poster::Poster(const QString &host)
m_status = 0;
m_hadError = false;
connect(this, SIGNAL(requestFinished(int,bool)), SLOT(gotRequestFinished(int,bool)));
connect(this, SIGNAL(responseHeaderReceived(const QHttpResponseHeader &)), SLOT(gotResponseHeaderReceived(const QHttpResponseHeader &)));
connect(this, SIGNAL(responseHeaderReceived(QHttpResponseHeader)), SLOT(gotResponseHeaderReceived(QHttpResponseHeader)));
}
void Poster::post(const QString &description, const QString &comment,
......
......@@ -30,12 +30,12 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#ifndef POSTER_H
#define POSTER_H
#include <QHttp>
#include <QHttpResponseHeader>
#include <QString>
class Poster : public QHttp
......
......@@ -30,7 +30,9 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#include "splitter.h"
#include <QRegExp>
FileDataList splitDiffToFiles(const QByteArray &data)
......
......@@ -30,12 +30,13 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#ifndef SPLITTER_H
#define SPLITTER_H
#include <QString>
#include <QByteArray>
#include <QList>
#include <QString>
struct FileData
{
......
......@@ -30,6 +30,7 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#include "view.h"
#include <QFontMetrics>
......@@ -38,7 +39,6 @@
#include <QPushButton>
#include <QSettings>
// -------------------------------------------------------------------------------------------------
class ColumnIndicatorTextEdit : public QTextEdit
{
public:
......
......@@ -30,6 +30,7 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#ifndef VIEW_H
#define VIEW_H
......@@ -63,4 +64,3 @@ private:
};
#endif // VIEW_H
......@@ -30,24 +30,5 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
// Copyright (c) 2008 Roberto Raggi <roberto.raggi@gmail.com>
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
#include "Array.h"
......@@ -30,24 +30,5 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
// Copyright (c) 2008 Roberto Raggi <roberto.raggi@gmail.com>
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
#include "LiteralTable.h"
......@@ -30,6 +30,7 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#include "widgethost.h"
#include "formresizer.h"
#include "widgethostconstants.h"
......
......@@ -30,6 +30,7 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#ifndef WIDGETHOST_H
#define WIDGETHOST_H
......@@ -80,4 +81,3 @@ private:
} // namespace SharedTools
#endif // WIDGETHOST_H
......@@ -30,6 +30,7 @@
** 1.2, included in the file GPL_EXCEPTION.txt in this package.
**
***************************************************************************/
#ifndef WIDGETHOST_CONSTANTS_H
#define WIDGETHOST_CONSTANTS_H
......@@ -40,5 +41,5 @@ namespace SharedTools {
}
}
#endif //WIDGETHOST_CONSTANTS_H
#endif // WIDGETHOST_CONSTANTS_H
......@@ -108,7 +108,7 @@ void ContentWindow::keyPressEvent(QKeyEvent *e)
emit escapePressed();
}
bool ContentWindow::eventFilter(QObject* o, QEvent *e)
bool ContentWindow::eventFilter(QObject *o, QEvent *e)
{
if (m_contentWidget && o == m_contentWidget->viewport() && e->type()
== QEvent::MouseButtonRelease) {
......
......@@ -66,7 +66,7 @@ private slots:
private:
void focusInEvent(QFocusEvent *e);
void keyPressEvent(QKeyEvent *e);
bool eventFilter(QObject* o, QEvent *e);
bool eventFilter(QObject *o, QEvent *e);
QHelpEngine *m_helpEngine;
QHelpContentWidget *m_contentWidget;
......@@ -75,4 +75,4 @@ private:
QT_END_NAMESPACE
#endif
#endif // CONTENTWINDOW_H
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment