小编Iva*_*van的帖子

SwiftUI 中另一个按钮内的按钮

如何让内部Button执行其操作而不是始终执行外部操作?

struct Foo: View {
    var body: some View {
        Button(action: { print("alloha") }) {
            HStack {
                Button(action: { print("hello") }) {
                    Image(systemName: "circle.fill")
                }
                Text("world")
                Spacer()
            }
        }
    }
}
Run Code Online (Sandbox Code Playgroud)

button ios swift swiftui

12
推荐指数
1
解决办法
5015
查看次数

为什么应用程序因 NSBluetoothPeripheralUsageDescription 键的“Info.plist 文件中缺少目的字符串”而被拒绝?

所以我有 info.plist :

<key>NSBluetoothPeripheralUsageDescription</key> <string>Bluetooth is required bla bla.</string>

我什至已经将它本地化为两种支持的语言。

然后添加 InfoPlist.strings 文件并添加:

"NSBluetoothPeripheralUsageDescription" = "Bluetooth is required bla bla bla";
Run Code Online (Sandbox Code Playgroud)

并将其本地化...

在应用程序目标的功能中,我为后台模式添加了蓝牙。

我只使用标准的 BLE api,没有使用外部库。

为什么我总是收到一封电子邮件:

亲爱的开发者,

我们发现了您的应用程序“bla”最近交付的一个或多个问题。请更正以下问题,然后重新上传。

Info.plist 文件中缺少用途字符串 - 您的应用程序代码引用了一个或多个访问敏感用户数据的 API。应用程序的 Info.plist 文件应该包含一个 NSBluetoothPeripheralUsageDescription 键和一个面向用户的目的字符串,清楚而完整地解释你的应用程序为什么需要数据。

?

xcode bluetooth objective-c app-store ios

8
推荐指数
2
解决办法
7490
查看次数

标签 统计

ios ×2

app-store ×1

bluetooth ×1

button ×1

objective-c ×1

swift ×1

swiftui ×1

xcode ×1