Commit c04ca1fa authored by Yuri Chornoivan's avatar Yuri Chornoivan

Fix minor EBN issues

parent 81ac73fc
......@@ -182,7 +182,7 @@ void AddRemoveAnnotationTest::testRemoveAnnotations()
QString annot1Name = annot1->uniqueName();
annot1->setDisposeDataFunction( TestingUtils::AnnotationDisposeWatcher::disposeAnnotation );
TestingUtils::AnnotationDisposeWatcher::resetDisposedAnnotationName();
QVERIFY( TestingUtils::AnnotationDisposeWatcher::disposedAnnotationName() == QString() );
QVERIFY( TestingUtils::AnnotationDisposeWatcher::disposedAnnotationName().isEmpty() );
m_document->closeDocument();
QVERIFY( TestingUtils::AnnotationDisposeWatcher::disposedAnnotationName() == annot1Name );
}
......
......@@ -7,7 +7,7 @@
* (at your option) any later version. *
***************************************************************************/
#include <QtTest/QTest>
#include <QTest>
#include <QDirIterator>
#include <QDebug>
#include <QStringList>
......
......@@ -36,7 +36,7 @@ namespace TestingUtils
return !it1.hasNext() && !it2.hasNext();
}
QString AnnotationDisposeWatcher::m_disposedAnnotationName = QString();
QString AnnotationDisposeWatcher::m_disposedAnnotationName = QString(); //krazy:exclude=nullstrassign
QString AnnotationDisposeWatcher::disposedAnnotationName() {
return m_disposedAnnotationName;
......
......@@ -15,8 +15,8 @@
#include <QListWidgetItem>
#include <QPushButton>
#include <QStackedWidget>
#include <QtXml/QDomDocument>
#include <QtXml/QDomElement>
#include <QDomDocument>
#include <QDomElement>
#include <KConfigGroup>
#include <QDialogButtonBox>
......
......@@ -18,8 +18,8 @@
#include <QHBoxLayout>
#include <QListWidget>
#include <QListWidgetItem>
#include <QtXml/QDomDocument>
#include <QtXml/QDomElement>
#include <QDomDocument>
#include <QDomElement>
#include <KConfigGroup>
#include <QDialogButtonBox>
#include <QPushButton>
......
......@@ -12,11 +12,11 @@
#include "editdrawingtooldialog.h"
#include <KLocalizedString>
#include <KMessageBox>
#include <QDebug>
#include <QDomElement>
#include <QListWidgetItem>
#include <QMessageBox>
#include <QPainter>
// Used to store tools' XML description in m_list's items
......@@ -145,7 +145,7 @@ void WidgetDrawingTools::slotAdd()
{
QListWidgetItem * listEntry = m_list->item( i );
if (itemText == listEntry->text()) {
QMessageBox::information( this, i18n("Duplicated Name"), i18n("There's already a tool with that name. Using a default one") );
KMessageBox::information( this, i18n("There's already a tool with that name. Using a default one"), i18n("Duplicated Name") );
itemText = defaultName();
break;
}
......@@ -189,7 +189,7 @@ void WidgetDrawingTools::slotEdit()
{
QListWidgetItem * auxListEntry = m_list->item( i );
if (itemText == auxListEntry->text() && auxListEntry != listEntry) {
QMessageBox::information( this, i18n("Duplicated Name"), i18n("There's already a tool with that name. Using a default one") );
KMessageBox::information( this, i18n("There's already a tool with that name. Using a default one"), i18n("Duplicated Name") );
itemText = defaultName();
break;
}
......
......@@ -13,8 +13,8 @@
#include "global.h"
#include "okularcore_export.h"
#include <QtCore/QString>
#include <QtCore/QVariant>
#include <QString>
#include <QVariant>
namespace Okular {
......
......@@ -11,8 +11,8 @@
#include "annotations_p.h"
// qt/kde includes
#include <QtWidgets/QApplication>
#include <QtGui/QColor>
#include <QApplication>
#include <QColor>
// DBL_MAX
#include <float.h>
......
......@@ -10,13 +10,13 @@
#ifndef _OKULAR_ANNOTATIONS_H_
#define _OKULAR_ANNOTATIONS_H_
#include <QtCore/QString>
#include <QtCore/QDateTime>
#include <QtCore/QLinkedList>
#include <QtCore/QRect>
#include <QtGui/QFont>
#include <QtXml/QDomDocument>
#include <QtXml/QDomElement>
#include <QString>
#include <QDateTime>
#include <QLinkedList>
#include <QRect>
#include <QFont>
#include <QDomDocument>
#include <QDomElement>
#include "okularcore_export.h"
#include "area.h"
......
......@@ -14,10 +14,10 @@
#include "annotations.h"
// qt/kde includes
#include <QtCore/QDateTime>
#include <QtCore/QString>
#include <QtCore/QVariant>
#include <QtGui/QColor>
#include <QDateTime>
#include <QString>
#include <QVariant>
#include <QColor>
class QTransform;
......
......@@ -9,9 +9,9 @@
#include "area.h"
#include <QtCore/QRect>
#include <QtGui/QPolygonF>
#include <QtCore/QDebug>
#include <QRect>
#include <QPolygonF>
#include <QDebug>
#include <math.h>
......
......@@ -12,11 +12,11 @@
#include <math.h>
#include <QtCore/QList>
#include <QtGui/QColor>
#include <QtGui/QPainterPath>
#include <QtGui/QTransform>
#include <QtCore/QDebug>
#include <QList>
#include <QColor>
#include <QPainterPath>
#include <QTransform>
#include <QDebug>
#include "global.h"
#include "okularcore_export.h"
......
......@@ -13,7 +13,7 @@
// qt/kde includes
#include <qbuffer.h>
#include <qdir.h>
#include <QtCore/QDebug>
#include <QDebug>
#include <krandom.h>
#include <phonon/path.h>
#include <phonon/audiooutput.h>
......
......@@ -12,7 +12,7 @@
#include "okularcore_export.h"
#include <QtCore/QObject>
#include <QObject>
namespace Okular {
......
......@@ -9,8 +9,8 @@
#include "chooseenginedialog_p.h"
#include <QtWidgets/QComboBox>
#include <QtWidgets/QLabel>
#include <QComboBox>
#include <QLabel>
#include <KLocalizedString>
#include <QDialogButtonBox>
......
......@@ -10,7 +10,7 @@
#ifndef _CHOOSEENGINEDIALOG_H
#define _CHOOSEENGINEDIALOG_H
#include <QtCore/QStringList>
#include <QStringList>
#include <QDialog>
#include <QMimeType>
......
......@@ -11,7 +11,7 @@
#ifndef OKULAR_DEBUG_P_H
#define OKULAR_DEBUG_P_H
#include <QtCore/qloggingcategory.h>
#include <qloggingcategory.h>
Q_DECLARE_LOGGING_CATEGORY(OkularCoreDebug)
......
......@@ -27,18 +27,18 @@
#endif
// qt/kde/system includes
#include <QtCore/QtAlgorithms>
#include <QtCore/QDir>
#include <QtCore/QFile>
#include <QtCore/QFileInfo>
#include <QtCore/QMap>
#include <QtCore/qtemporaryfile.h>
#include <QtCore/QTextStream>
#include <QtCore/QTimer>
#include <QtWidgets/QApplication>
#include <QtWidgets/QLabel>
#include <QtPrintSupport/QPrinter>
#include <QtPrintSupport/QPrintDialog>
#include <QtAlgorithms>
#include <QDir>
#include <QFile>
#include <QFileInfo>
#include <QMap>
#include <qtemporaryfile.h>
#include <QTextStream>
#include <QTimer>
#include <QApplication>
#include <QLabel>
#include <QPrinter>
#include <QPrintDialog>
#include <QStack>
#include <QUndoCommand>
#include <QMimeDatabase>
......@@ -94,8 +94,6 @@
#include "form.h"
#include "utils.h"
#include <memory>
#include <config-okular.h>
#if HAVE_MALLOC_TRIM
......
......@@ -19,11 +19,11 @@
#include "global.h"
#include "pagesize.h"
#include <QtCore/QObject>
#include <QtCore/QStringList>
#include <QtCore/QVector>
#include <QtPrintSupport/QPrinter>
#include <QtXml/QDomDocument>
#include <QObject>
#include <QStringList>
#include <QVector>
#include <QPrinter>
#include <QDomDocument>
#include <QMimeType>
#include <QUrl>
......
......@@ -16,11 +16,11 @@
#include "synctex/synctex_parser.h"
// qt/kde/system includes
#include <QtCore/QHash>
#include <QtCore/QLinkedList>
#include <QtCore/QMap>
#include <QtCore/QMutex>
#include <QtCore/QPointer>
#include <QHash>
#include <QLinkedList>
#include <QMap>
#include <QMutex>
#include <QPointer>
#include <QUrl>
#include <KPluginMetaData>
......
......@@ -13,7 +13,7 @@
#ifndef _OKULAR_DOCUMENT_COMMANDS_P_H_
#define _OKULAR_DOCUMENT_COMMANDS_P_H_
#include <QtWidgets/QUndoCommand>
#include <QUndoCommand>
#include <QDomNode>
#include "area.h"
......
......@@ -12,19 +12,19 @@
#include "fileprinter.h"
#include <QtPrintSupport/QPrinter>
#include <QPrinter>
#include <QPrintEngine>
#include <QStringList>
#include <QSize>
#include <QtCore/QFile>
#include <QtCore/QFileInfo>
#include <QtWidgets/QLabel>
#include <QtGui/QShowEvent>
#include <QtNetwork/QTcpSocket>
#include <QFile>
#include <QFileInfo>
#include <QLabel>
#include <QShowEvent>
#include <QTcpSocket>
#include <KProcess>
#include <KShell>
#include <QtCore/QDebug>
#include <QDebug>
#include <QStandardPaths>
#include "debug_p.h"
......
......@@ -14,9 +14,9 @@
#ifndef FILEPRINTER_H
#define FILEPRINTER_H
#include <QtCore/QList>
#include <QtCore/QString>
#include <QtPrintSupport/QPrinter>
#include <QList>
#include <QString>
#include <QPrinter>
#include "okularcore_export.h"
#include "generator.h"
......
......@@ -10,10 +10,10 @@
#ifndef _OKULAR_FONTINFO_H_
#define _OKULAR_FONTINFO_H_
#include <QtCore/QList>
#include <QtCore/QMetaType>
#include <QtCore/QSharedDataPointer>
#include <QtCore/QString>
#include <QList>
#include <QMetaType>
#include <QSharedDataPointer>
#include <QString>
#include "okularcore_export.h"
......
......@@ -11,7 +11,7 @@
#include "form_p.h"
// qt includes
#include <QtCore/QVariant>
#include <QVariant>
#include "action.h"
......
......@@ -14,7 +14,7 @@
#include "area.h"
#include "annotations.h"
#include <QtCore/QStringList>
#include <QStringList>
namespace Okular {
......
......@@ -12,7 +12,7 @@
#include "form.h"
#include <QtCore/QString>
#include <QString>
namespace Okular {
......
......@@ -17,9 +17,9 @@
#include <QApplication>
#include <qeventloop.h>
#include <QtPrintSupport/QPrinter>
#include <QPrinter>
#include <QtCore/QDebug>
#include <QDebug>
#include <QIcon>
#include <QMimeDatabase>
#include <QTimer>
......
......@@ -21,13 +21,13 @@
#include "global.h"
#include "pagesize.h"
#include <QtCore/QList>
#include <QtCore/QObject>
#include <QtCore/QSharedDataPointer>
#include <QtCore/QSizeF>
#include <QtCore/QString>
#include <QtCore/QVariant>
#include <QtCore/QVector>
#include <QList>
#include <QObject>
#include <QSharedDataPointer>
#include <QSizeF>
#include <QString>
#include <QVariant>
#include <QVector>
#include <QMimeType>
#include <kpluginfactory.h>
......
......@@ -9,7 +9,7 @@
#include "generator_p.h"
#include <QtCore/QDebug>
#include <QDebug>
#include "fontinfo.h"
#include "generator.h"
......
......@@ -15,9 +15,9 @@
#include "area.h"
#include <QtCore/QSet>
#include <QtCore/QThread>
#include <QtGui/QImage>
#include <QSet>
#include <QThread>
#include <QImage>
class QEventLoop;
class QMutex;
......
......@@ -10,7 +10,7 @@
#ifndef OKULAR_GLOBAL_H
#define OKULAR_GLOBAL_H
#include <QtCore/QGlobalStatic>
#include <QGlobalStatic>
namespace Okular {
......
......@@ -9,7 +9,7 @@
#include "core/misc.h"
#include <QtCore/QDebug>
#include <QDebug>
#include "debug_p.h"
......
......@@ -16,7 +16,7 @@
#include <qstring.h>
#include <qtemporaryfile.h>
#include <QtCore/QDebug>
#include <QDebug>
#include "debug_p.h"
......
......@@ -14,7 +14,7 @@
#include "global.h"
#include "okularcore_export.h"
#include <QtCore/QSize>
#include <QSize>
class QImage;
......
......@@ -14,7 +14,7 @@
#ifndef _OKULAR_DOCUMENTOBSERVER_H_
#define _OKULAR_DOCUMENTOBSERVER_H_
#include <QtCore/QVector>
#include <QVector>
#include "okularcore_export.h"
......
......@@ -14,16 +14,16 @@
#include "page_p.h"
// qt/kde includes
#include <QtCore/QHash>
#include <QtCore/QSet>
#include <QtCore/QString>
#include <QtCore/QVariant>
#include <QtCore/QUuid>
#include <QtGui/QPixmap>
#include <QtXml/QDomDocument>
#include <QtXml/QDomElement>
#include <QHash>
#include <QSet>
#include <QString>
#include <QVariant>
#include <QUuid>
#include <QPixmap>
#include <QDomDocument>
#include <QDomElement>
#include <QtCore/QDebug>
#include <QDebug>
// local includes
#include "action.h"
......@@ -49,7 +49,7 @@
#include <limits>
#ifdef PAGE_PROFILE
#include <QtCore/QTime>
#include <QTime>
#endif
using namespace Okular;
......
......@@ -13,7 +13,7 @@
#ifndef _OKULAR_PAGE_H_
#define _OKULAR_PAGE_H_
#include <QtCore/QLinkedList>
#include <QLinkedList>
#include "okularcore_export.h"
#include "area.h"
......
......@@ -10,7 +10,7 @@
#ifndef _OKULAR_PAGECONTROLLER_P_H_
#define _OKULAR_PAGECONTROLLER_P_H_
#include <QtCore/QObject>
#include <QObject>
#include <threadweaver/queue.h>
......
......@@ -10,9 +10,9 @@
#ifndef _OKULAR_PAGESIZE_H_
#define _OKULAR_PAGESIZE_H_
#include <QtCore/QList>
#include <QtCore/QSharedDataPointer>
#include <QtCore/QString>
#include <QList>
#include <QSharedDataPointer>
#include <QString>
#include "okularcore_export.h"
......
......@@ -9,7 +9,7 @@
#include "rotationjob_p.h"
#include <QtGui/QTransform>
#include <QTransform>
using namespace Okular;
......
......@@ -10,8 +10,8 @@
#ifndef _OKULAR_ROTATIONJOB_P_H_
#define _OKULAR_ROTATIONJOB_P_H_
#include <QtGui/QImage>
#include <QtGui/QTransform>
#include <QImage>
#include <QTransform>
#include <threadweaver/qobjectdecorator.h>
#include <threadweaver/job.h>
......
......@@ -15,7 +15,7 @@
#include <kjs/kjsprototype.h>
#include <kjs/kjsarguments.h>
#include <QtCore/QDebug>
#include <QDebug>
#include "../debug_p.h"
#include "../document_p.h"
......
......@@ -14,7 +14,7 @@
#include <kjs/kjsprototype.h>
#include <kjs/kjsarguments.h>
#include <QtCore/QDebug>
#include <QDebug>
#include "../debug_p.h"
......
......@@ -16,7 +16,7 @@
#include <kjs/kjsprototype.h>
#include <kjs/kjsarguments.h>
#include <QtCore/QDebug>
#include <QDebug>
#include <assert.h>
#include "../document_p.h"
......
......@@ -16,7 +16,7 @@
#include <qhash.h>
#include <QtCore/QDebug>
#include <QDebug>
#include "../debug_p.h"
#include "../document_p.h"
......
......@@ -13,7 +13,7 @@
#include <kjs/kjsobject.h>
#include <kjs/kjsprototype.h>
#include <QtCore/QString>
#include <QString>
using namespace Okular;
......
......@@ -9,7 +9,7 @@
#include "scripter.h"
#include <QtCore/QDebug>
#include <QDebug>
#include <QFile>
#include "debug_p.h"
......
......@@ -9,7 +9,7 @@
#include "sound.h"
#include <QtCore/QVariant>
#include <QVariant>
using namespace Okular;
......
......@@ -12,8 +12,8 @@
#include "okularcore_export.h"
#include <QtCore/QByteArray>
#include <QtCore/QString>
#include <QByteArray>
#include <QString>
namespace Okular {
......
......@@ -10,8 +10,8 @@
#include "sourcereference.h"
#include "sourcereference_p.h"
#include <QtCore/QString>
#include <QtCore/QUrl>
#include <QString>
#include <QUrl>
#include <KLocalizedString>
using namespace Okular;
......
......@@ -10,16 +10,16 @@
#include "textdocumentgenerator.h"
#include "textdocumentgenerator_p.h"
#include <QtCore/QFile>
#include <QtCore/QMutex>
#include <QtCore/QStack>
#include <QtCore/QTextStream>
#include <QtCore/QVector>
#include <QtGui/QFontDatabase>
#include <QtGui/QImage>
#include <QtGui/QPainter>
#include <QtPrintSupport/QPrinter>
#include <QtGui/QTextDocumentWriter>
#include <QFile>
#include <QMutex>
#include <QStack>
#include <QTextStream>
#include <QVector>
#include <QFontDatabase>
#include <QImage>
#include <QPainter>
#include <QPrinter>
#include <QTextDocumentWriter>
#include "action.h"
#include "annotations.h"
......