admin管理员组文章数量:1300164
I want to add a menu item/action to the default contextual menu items that are shown when we tap on a selected item using the PenciKit lasso.
I tried overriding the touchesBegan to try to identify the selectionView and maybe override the menu there, but it does not seem to be the right way to do that.
class Canvas: PKCanvasView {
override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) {
super.touchesBegan(touches, with: event)
touches.forEach { touch in
print("touch location \(touch.location(in: self))")
}
}
}
ScreenGrab of Lasso Contextual Menu
本文标签:
版权声明:本文标题:swift - How to change PencilKit contextual menu on PKCanvasView's PKToolPickerLassoItem selection - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741657716a2390855.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论