如何使用 Delphi Firemonkey 在 iPhone 应用程序上使用手势?
我正在尝试使用 Delphi XE2 / FireMonkey 编写一个 iPhone 应用程序,并且已经克服了许多最初的障碍,但现在我陷入了手势处理。
我已经使用 TVertScrollBox 创建了一个测试应用程序,但我无法滚动内容,除非启用滚动条(非常细)并触摸它们。这对 iPhone 不太友好(而且几乎无法使用)。希望您能指出正确的方向。
文档似乎建议使用 UIGestureRecognizer...
...但是这些需要附加到视图,而应用程序使用 FireMonkey 表单。
任何想法将不胜感激。
I am trying to write an iPhone app using Delphi XE2 / FireMonkey and have got past many of the initial hurdles, but am now stuck on gesture handling.
I have created a test app with a TVertScrollBox, but I cannot scroll the contents, unless I enable the scroll bars (which are very thin), and touch those. This is not very iPhone friendly (and almost unusable). Would appreciate a pointer in the right direction.
Documentation seems to suggest using UIGestureRecognizer...
...however these need to be attached to a View, whereas the app is using a FireMonkey form.
Any thoughts would be appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我已经弄清楚如何执行此操作...
TVertScrollBox 控件需要将 MouseTracking 属性设置为 True。
添加到 TVertScrollBox 的所有控件都需要将其 HitTest 属性(如果存在)设置为 False。之后就可以了!
I have worked out how to do this...
The TVertScrollBox control needs to have the MouseTracking property set to True.
All controls added to the TVertScrollBox then need to have their HitTest property (if it exists) set to False. After that it just works!
以Delphi Xe3、Fire Monkey作为支持基本手势(缩放、旋转、平移)
但官方 Xe3 不再支持“IOS”作为目标。
你必须等待 2013 年初才能发布他们的“mobile studio”扩展
With Delphi Xe3, Fire monkey as support for basic gestures (zoom, rotation, pan)
But officially Xe3 doesn't support anymore "IOS" as a target.
You have to wait beginning of 2013 for the release of their "mobile studio" extension
目前 FireMonkey 中没有手势。
Gestures not in FireMonkey at the moment.