diff --git a/CMake/common b/CMake/common index e1a5560..28f4d72 160000 --- a/CMake/common +++ b/CMake/common @@ -1 +1 @@ -Subproject commit e1a5560e7d1dee3156f4bf988a40ffa025ddacbc +Subproject commit 28f4d72999dddac3404a1b040f8c5ed649d3accd diff --git a/deflect/qt/CMakeLists.txt b/deflect/qt/CMakeLists.txt index 7fecaab..c4f097f 100644 --- a/deflect/qt/CMakeLists.txt +++ b/deflect/qt/CMakeLists.txt @@ -5,7 +5,6 @@ set(DEFLECTQT_HEADERS EventReceiver.h - helpers.h QmlGestures.h QmlStreamerImpl.h ) diff --git a/deflect/qt/QmlStreamerImpl.cpp b/deflect/qt/QmlStreamerImpl.cpp index 7c09d02..6cdb16c 100644 --- a/deflect/qt/QmlStreamerImpl.cpp +++ b/deflect/qt/QmlStreamerImpl.cpp @@ -43,7 +43,6 @@ #include "EventReceiver.h" #include "QmlGestures.h" #include "TouchInjector.h" -#include "helpers.h" #include #include @@ -70,7 +69,7 @@ namespace qt { QmlStreamer::Impl::Impl(const QString& qmlFile, const std::string& streamHost, const std::string& streamId) - : _quickView{new OffscreenQuickView{make_unique(), + : _quickView{new OffscreenQuickView{std::make_unique(), renderMode}} , _qmlGestures{new QmlGestures} , _touchInjector{TouchInjector::create(*_quickView)} diff --git a/deflect/qt/TouchInjector.cpp b/deflect/qt/TouchInjector.cpp index 3ee5751..aa8b0d0 100644 --- a/deflect/qt/TouchInjector.cpp +++ b/deflect/qt/TouchInjector.cpp @@ -39,8 +39,6 @@ #include "TouchInjector.h" -#include "helpers.h" - #include #include @@ -61,7 +59,7 @@ std::unique_ptr TouchInjector::create(QWindow& window) return QPointF{normPos.x() * window.width(), normPos.y() * window.height()}; }; - return make_unique(window, mapFunc); + return std::make_unique(window, mapFunc); } void TouchInjector::addTouchPoint(const int id, const QPointF position) diff --git a/deflect/qt/helpers.h b/deflect/qt/helpers.h deleted file mode 100644 index 1991242..0000000 --- a/deflect/qt/helpers.h +++ /dev/null @@ -1,60 +0,0 @@ -/*********************************************************************/ -/* Copyright (c) 2016-2017, EPFL/Blue Brain Project */ -/* Raphael Dumusc */ -/* All rights reserved. */ -/* */ -/* Redistribution and use in source and binary forms, with or */ -/* without modification, are permitted provided that the following */ -/* conditions are met: */ -/* */ -/* 1. Redistributions of source code must retain the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer. */ -/* */ -/* 2. Redistributions in binary form must reproduce the above */ -/* copyright notice, this list of conditions and the following */ -/* disclaimer in the documentation and/or other materials */ -/* provided with the distribution. */ -/* */ -/* THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, */ -/* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */ -/* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE */ -/* DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF TEXAS AT */ -/* AUSTIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, */ -/* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */ -/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ -/* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR */ -/* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF */ -/* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */ -/* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT */ -/* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE */ -/* POSSIBILITY OF SUCH DAMAGE. */ -/* */ -/* The views and conclusions contained in the software and */ -/* documentation are those of the authors and should not be */ -/* interpreted as representing official policies, either expressed */ -/* or implied, of Ecole polytechnique federale de Lausanne. */ -/*********************************************************************/ - -#ifndef DELFECT_QT_HELPERS_H -#define DELFECT_QT_HELPERS_H - -#include -#include - -namespace deflect -{ -namespace qt -{ -// missing make_unique() implementation in C++11 standard -// source: http://herbsutter.com/gotw/_102/ -template -std::unique_ptr make_unique(Args&&... args) -{ - return std::unique_ptr(new T(std::forward(args)...)); -} -} -} - -#endif