Commit 74d90110 authored by Laurent Montel's avatar Laurent Montel 😁

GIT_SILENT: we depend against qt5.7 now. Clean up

parent 94311653
......@@ -35,7 +35,7 @@ ecm_setup_version(PROJECT VARIABLE_PREFIX AKONADICONTACT
SOVERSION 5
)
set(QT_REQUIRED_VERSION "5.6.0")
set(QT_REQUIRED_VERSION "5.7.0")
find_package(Qt5 ${QT_REQUIRED_VERSION} CONFIG REQUIRED Widgets Test WebEngine WebEngineWidgets)
########### Find packages ###########
find_package(KF5KIO ${KF5_VERSION} CONFIG REQUIRED)
......
......@@ -24,7 +24,7 @@
#include "job/contactgroupexpandjob.h"
#include "standardcontactgroupformatter.h"
#include "textbrowser_p.h"
#include "helper_p.h"
#include <collectionfetchjob.h>
#include <entitydisplayattribute.h>
......
......@@ -26,7 +26,7 @@
#include "customfieldmanager_p.h"
#include "standardcontactformatter.h"
#include "textbrowser_p.h"
#include "helper_p.h"
#include "editor/im/improtocols.h"
#include <KIOCore/kio/transferjob.h>
#include <collection.h>
......
......@@ -38,13 +38,11 @@ AddressesLocationEnginePage::AddressesLocationEnginePage(QObject *parent)
settings()->setAttribute(QWebEngineSettings::ErrorPageEnabled, false);
settings()->setAttribute(QWebEngineSettings::LocalContentCanAccessRemoteUrls, false);
settings()->setAttribute(QWebEngineSettings::LocalContentCanAccessFileUrls, false);
#if QT_VERSION >= QT_VERSION_CHECK(5, 7, 0)
settings()->setAttribute(QWebEngineSettings::ScreenCaptureEnabled, false);
settings()->setAttribute(QWebEngineSettings::WebGLEnabled, false);
settings()->setAttribute(QWebEngineSettings::AutoLoadIconsForPage, false);
settings()->setAttribute(QWebEngineSettings::Accelerated2dCanvasEnabled, false);
settings()->setAttribute(QWebEngineSettings::WebGLEnabled, false);
#endif
#if QT_VERSION >= QT_VERSION_CHECK(5, 8, 0)
settings()->setAttribute(QWebEngineSettings::FocusOnNavigationEnabled, false);
......
......@@ -25,7 +25,7 @@
#include "personaleditor/personaleditorwidget.h"
#include "contacteditorpageplugin.h"
#include "contactmetadata_p.h"
#include "helper_p.h"
#include <kconfig.h>
#include <kconfiggroup.h>
......
......@@ -22,7 +22,7 @@
#include "customfieldslistwidget.h"
#include "../utils/utils.h"
#include "helper_p.h"
#include "customfieldmanager_p.h"
#include "customfieldslistdelegate.h"
#include <QSortFilterProxyModel>
......
......@@ -20,7 +20,7 @@
*/
#include "displaynameeditwidget.h"
#include "helper_p.h"
#include <QtCore/QEvent>
#include <QAbstractItemView>
......
......@@ -25,7 +25,7 @@
#include "../../im/imaddress.h"
#include "../../im/improtocols.h"
#include "../../utils/utils.h"
#include "helper_p.h"
#include <KContacts/Addressee>
using namespace Akonadi;
......
......@@ -31,7 +31,7 @@
*/
#include "kwidgetlister_p.h"
#include "helper_p.h"
#include <QHBoxLayout>
#include <QPushButton>
......
/*
Copyright (c) 2017 Laurent Montel <montel@kde.org>
This library is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published by
the Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
License for more details.
You should have received a copy of the GNU Library General Public License
along with this library; see the file COPYING.LIB. If not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.
*/
#ifndef _HELPER_H
#define _HELPER_H
#include <qglobal.h>
#if QT_VERSION < QT_VERSION_CHECK(5,7,0)
namespace QtPrivate
{
template <typename T> struct QAddConst {
typedef const T Type;
};
}
// this adds const to non-const objects (like std::as_const)
template <typename T>
Q_DECL_CONSTEXPR typename QtPrivate::QAddConst<T>::Type &qAsConst(T &t) Q_DECL_NOTHROW { return t; }
// prevent rvalue arguments:
template <typename T>
void qAsConst(const T &&) Q_DECL_EQ_DELETE;
#endif
#endif
Markdown is supported
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