自定义散点视图的形状
我目前在 Blend 和 VS2008 中使用 Surface SDK 1.0,并且遇到了一个问题:我在整个屏幕上使用了 scatterview。 我的屏幕中间还有一个网格。 中间的面板非常烦人,因为我的 scatterviewitems 很容易在网格后面丢失,并且由于网格被锁定在适当的位置,所以我无法检索它们。
最好在网格周围添加“墙”,以便我的 scatterviewitem 能够从网格上反弹,就像在 scatterview 边缘一样。
我怎么解决这个问题?
I'm currently using the Surface SDK 1.0 in Blend and VS2008, and I've encountered a problem: I use a scatterview over the whole screen. I also have a grid in the middle of the screen. The panel in the middle is quite annoying because my scatterviewitems can easily get lost BEHIND the grid, and since the grid is locked in position, there is no way for me to retrieve them.
It would be desireable to add "walls" around the grid, so that my scatterviewitems would bounce off it, as it does at the edges of the scatterview.
How can I solve this problem?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
只需连接到“ScatterManipulationCompleted”并检查该项目是否在您的网格下。 如果是,启动一个故事板,将 ScatterViewItem 的中心移回网格背景之外。
另请查看 surface 社区论坛,有很多关于 ScatterViewItem 和碰撞检测的帖子。
Just hook up to "ScatterManipulationCompleted" and check if the item is under your grid. If yes start a Storyboard which moves the Center of your ScatterViewItem back out of the grids background.
Also take a look at the surface community forums, there are a lot posts regarding ScatterViewItem and collision detection.