From 7f210bb7b25e89e2f06ee0460dd86a93cf966e68 Mon Sep 17 00:00:00 2001 From: hjk Date: Mon, 18 Feb 2019 11:27:50 +0100 Subject: [PATCH] WinRT: Split WinRtQtVersion hierarchy To match the general pattern. Part of the code duplication can go later. Change-Id: I42f936bea88b4fc06f839045ba7988745f951ab7 Reviewed-by: Oliver Wolff --- src/plugins/winrt/winrtphoneqtversion.cpp | 14 ++++++++++++++ src/plugins/winrt/winrtphoneqtversion.h | 5 ++++- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/src/plugins/winrt/winrtphoneqtversion.cpp b/src/plugins/winrt/winrtphoneqtversion.cpp index aec898b965b..bf0446c61ce 100644 --- a/src/plugins/winrt/winrtphoneqtversion.cpp +++ b/src/plugins/winrt/winrtphoneqtversion.cpp @@ -55,6 +55,20 @@ QSet WinRtPhoneQtVersion::targetDeviceTypes() const return {Constants::WINRT_DEVICE_TYPE_PHONE, Constants::WINRT_DEVICE_TYPE_EMULATOR}; } +QSet WinRtPhoneQtVersion::availableFeatures() const +{ + QSet features = QtSupport::BaseQtVersion::availableFeatures(); + features.insert(QtSupport::Constants::FEATURE_MOBILE); + features.remove(QtSupport::Constants::FEATURE_QT_CONSOLE); + features.remove(Core::Id::versionedId(QtSupport::Constants::FEATURE_QT_QUICK_CONTROLS_PREFIX, 1)); + features.remove(QtSupport::Constants::FEATURE_QT_WEBKIT); + return features; +} + +QList WinRtPhoneQtVersion::detectQtAbis() const +{ + return qtAbisFromLibrary(qtCorePaths()); +} // Factory diff --git a/src/plugins/winrt/winrtphoneqtversion.h b/src/plugins/winrt/winrtphoneqtversion.h index 95dddce37f7..1a643d9f19f 100644 --- a/src/plugins/winrt/winrtphoneqtversion.h +++ b/src/plugins/winrt/winrtphoneqtversion.h @@ -30,12 +30,15 @@ namespace WinRt { namespace Internal { -class WinRtPhoneQtVersion : public WinRtQtVersion +class WinRtPhoneQtVersion : public QtSupport::BaseQtVersion { Q_DECLARE_TR_FUNCTIONS(WinRt::Internal::WinRtQtVersion) public: WinRtPhoneQtVersion() = default; + QSet availableFeatures() const override; + QList detectQtAbis() const override; + QString description() const override; BaseQtVersion *clone() const override; QString type() const override;