Focus相关的Picker控件方法
Picker control methods related to Focus
我有一个带有 UIPicker
的 iOS + Watch 应用程序,我不断收到与其相关的日志,但我无法弄清楚与 Watch 应用程序相关的日志:
[default] -[SPRemoteInterface handlePlistDictionary:fromIdentifier:]:2977: ComF:->Plugin method .pickerFocus is not implemented by the controller (null)
[default] -[SPRemoteInterface handlePlistDictionary:fromIdentifier:]:2977: ComF:->Plugin method .pickerClearFocus is not implemented by the controller (null)
我查看了文档,我能找到的最接近的东西只是 pickerDidFocus()
方法,它似乎在谈论我遇到的一般问题领域,但 没有明确的实施思路特别是 .pickerClearFocus
和 .pickerFocus
.
我确实为我的案例找到了解决方案 (WKInterfaceButton)。 button reference outlet和button sent action outlet必须在同一个class。 The message is shown when selector outlet references to the view and the action references the view controller.
单元格:
class aCellView: NSObject {
var delegate: WKInterfaceController? = nil
// The action outlet
@IBAction func doSomeThing() {
self.delegate!.doSomeThing()
}
}
控制器:
class HomeInterfaceController: WKInterfaceController {
// ... where you implement your cell
cell.delegate = self
// ... where you implement your cell
}
与“.pickerSettle”相同...
"I'm having the same problem. Looks like a bug of the iOS or XCode, because the public API does not incude a method ".pickerSettle",现有方法 "pickerDidSettle" 实际上调用得很好。一切似乎都按预期工作。"
来自:
我有一个带有 UIPicker
的 iOS + Watch 应用程序,我不断收到与其相关的日志,但我无法弄清楚与 Watch 应用程序相关的日志:
[default] -[SPRemoteInterface handlePlistDictionary:fromIdentifier:]:2977: ComF:->Plugin method .pickerFocus is not implemented by the controller (null)
[default] -[SPRemoteInterface handlePlistDictionary:fromIdentifier:]:2977: ComF:->Plugin method .pickerClearFocus is not implemented by the controller (null)
我查看了文档,我能找到的最接近的东西只是 pickerDidFocus()
方法,它似乎在谈论我遇到的一般问题领域,但 没有明确的实施思路特别是 .pickerClearFocus
和 .pickerFocus
.
我确实为我的案例找到了解决方案 (WKInterfaceButton)。 button reference outlet和button sent action outlet必须在同一个class。 The message is shown when selector outlet references to the view and the action references the view controller.
单元格:
class aCellView: NSObject {
var delegate: WKInterfaceController? = nil
// The action outlet
@IBAction func doSomeThing() {
self.delegate!.doSomeThing()
}
}
控制器:
class HomeInterfaceController: WKInterfaceController {
// ... where you implement your cell
cell.delegate = self
// ... where you implement your cell
}
与“.pickerSettle”相同...
"I'm having the same problem. Looks like a bug of the iOS or XCode, because the public API does not incude a method ".pickerSettle",现有方法 "pickerDidSettle" 实际上调用得很好。一切似乎都按预期工作。"
来自: