Fix all krazy #include warnings

- "include own header first line"
- "put config.h in angle brackets line"
- "do not include QtModule/QtClass line"

`QElapsedTimer` was implicitly included by
kfileitemmodelsortalgorithm.h, now we need to explicitly include it in
kfileitemmodel.cpp.

We also need to explicitly link to `Qt5::Concurrent`, otherwise we
cannot `#include <QtConcurrentRun>`.
This commit is contained in:
Elvis Angelaccio 2018-02-04 11:38:50 +01:00
parent 219e40cff8
commit ecbab34510
9 changed files with 20 additions and 18 deletions

View file

@ -137,6 +137,7 @@ generate_export_header(dolphinprivate BASE_NAME dolphin)
target_link_libraries(
dolphinprivate PUBLIC
dolphinvcs
Qt5::Concurrent
Qt5::Gui
KF5::Crash
KF5::I18n

View file

@ -17,15 +17,14 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#include <QApplication>
#include <QIcon>
#include "global.h"
#include "dolphindebug.h"
#include "dolphin_generalsettings.h"
#include <KRun>
#include "global.h"
#include "dolphindebug.h"
#include "dolphin_generalsettings.h"
#include <QApplication>
#include <QIcon>
QList<QUrl> Dolphin::validateUris(const QStringList& uriList)
{

View file

@ -31,6 +31,7 @@
#include "private/kfileitemmodelsortalgorithm.h"
#include "private/kfileitemmodeldirlister.h"
#include <QElapsedTimer>
#include <QMimeData>
#include <QTimer>
#include <QWidget>

View file

@ -24,10 +24,10 @@
#include "dolphin_export.h"
#include <QtCore/qpointer.h>
#include <qaccessible.h>
#include <qaccessibleobject.h>
#include <QtWidgets/qaccessiblewidget.h>
#include <QAccessible>
#include <QAccessibleObject>
#include <QAccessibleWidget>
#include <QPointer>
class KItemListView;
class KItemListContainer;

View file

@ -22,7 +22,7 @@
#ifndef KFILEITEMMODELSORTALGORITHM_H
#define KFILEITEMMODELSORTALGORITHM_H
#include <QtConcurrent/QtConcurrent>
#include <QtConcurrentRun>
#include <algorithm>

View file

@ -22,7 +22,7 @@
#include <QDialog>
#include <KFileItem>
#include "config-baloo.h"
#include <config-baloo.h>
#ifndef HAVE_BALOO
class KFileMetaDataConfigurationWidget;

View file

@ -20,10 +20,11 @@
#ifndef INFORMATIONPANELCONTENT_H
#define INFORMATIONPANELCONTENT_H
#include "config-baloo.h"
#include <KFileItem>
#include <QUrl>
#include <config-baloo.h>
#include <KFileItem>
#include <QUrl>
#include <QPointer>
#include <QWidget>

View file

@ -17,11 +17,11 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
***************************************************************************/
#include <KIO/FileSystemFreeSpaceJob>
#include "mountpointobserver.h"
#include "mountpointobservercache.h"
#include <KIO/FileSystemFreeSpaceJob>
MountPointObserver::MountPointObserver(const QUrl& url, QObject* parent) :
QObject(parent),
m_url(url),

View file

@ -23,7 +23,7 @@
#define DOLPHINFILEMETADATAWIDGET_H
#include <QWidget>
#include "config-baloo.h"
#include <config-baloo.h>
class KFileItemList;
class QLabel;