summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimur Pocheptsov <timur.pocheptsov@qt.io>2021-09-07 17:57:44 +0200
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-09-09 11:15:41 +0000
commitd3c6fc147bdc84ab43fb6fca07c459f018db1a23 (patch)
tree6f0ba1b03e8cc2903d53caa92492a9d3d1873ed1
parentc97424d1b5ffd64dca34eb3a9da60becfcf4928d (diff)
downloadqtconnectivity-d3c6fc147bdc84ab43fb6fca07c459f018db1a23.tar.gz
CoreBluetooth: provide a description (in Info.plist) of BT usage
Our lowenergyscanner example can be built and deployed on iOS device. As such, it has to provide an explanation, why it needs an access to BT adapter, otherwise, it would crash with the most recent versions of iOS. Change-Id: Iebcdf8af931002532aada0c452263effd342300e Reviewed-by: Alex Blasche <alexander.blasche@qt.io> (cherry picked from commit 42e1fdacd51c48dd6892e32f8c0d7a2882a3ad7e) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r--examples/bluetooth/lowenergyscanner/Info.plist39
-rw-r--r--examples/bluetooth/lowenergyscanner/lowenergyscanner.pro2
2 files changed, 41 insertions, 0 deletions
diff --git a/examples/bluetooth/lowenergyscanner/Info.plist b/examples/bluetooth/lowenergyscanner/Info.plist
new file mode 100644
index 00000000..7f056858
--- /dev/null
+++ b/examples/bluetooth/lowenergyscanner/Info.plist
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>CFBundleDisplayName</key>
+ <string>${PRODUCT_NAME}</string>
+ <key>CFBundleExecutable</key>
+ <string>${EXECUTABLE_NAME}</string>
+ <key>CFBundleIconFile</key>
+ <string>${ASSETCATALOG_COMPILER_APPICON_NAME}</string>
+ <key>CFBundleIdentifier</key>
+ <string>${PRODUCT_BUNDLE_IDENTIFIER}</string>
+ <key>CFBundleName</key>
+ <string>${PRODUCT_NAME}</string>
+ <key>CFBundlePackageType</key>
+ <string>APPL</string>
+ <key>CFBundleShortVersionString</key>
+ <string>${QMAKE_SHORT_VERSION}</string>
+ <key>CFBundleSignature</key>
+ <string>${QMAKE_PKGINFO_TYPEINFO}</string>
+ <key>CFBundleVersion</key>
+ <string>${QMAKE_FULL_VERSION}</string>
+ <key>LSRequiresIPhoneOS</key>
+ <true/>
+ <key>MinimumOSVersion</key>
+ <string>${IPHONEOS_DEPLOYMENT_TARGET}</string>
+ <key>NSBluetoothAlwaysUsageDescription</key>
+ <string>Qt LE scanner wants to access your Bluetooth adapter</string>
+ <key>UILaunchStoryboardName</key>
+ <string>LaunchScreen</string>
+ <key>UISupportedInterfaceOrientations</key>
+ <array>
+ <string>UIInterfaceOrientationPortrait</string>
+ <string>UIInterfaceOrientationPortraitUpsideDown</string>
+ <string>UIInterfaceOrientationLandscapeLeft</string>
+ <string>UIInterfaceOrientationLandscapeRight</string>
+ </array>
+</dict>
+</plist>
diff --git a/examples/bluetooth/lowenergyscanner/lowenergyscanner.pro b/examples/bluetooth/lowenergyscanner/lowenergyscanner.pro
index f3378b4c..934f6cfa 100644
--- a/examples/bluetooth/lowenergyscanner/lowenergyscanner.pro
+++ b/examples/bluetooth/lowenergyscanner/lowenergyscanner.pro
@@ -10,6 +10,8 @@ SOURCES += main.cpp \
serviceinfo.cpp \
characteristicinfo.cpp
+ios: QMAKE_INFO_PLIST = Info.plist
+
OTHER_FILES += assets/*.qml
HEADERS += \