Android:GridView Zoom(Android : GridView Zoom)

编程入门 行业动态 更新时间:2024-10-27 00:22:59
Android:GridView Zoom(Android : GridView Zoom)

我有两个网格视图,它们包含我的自定义视图作为他们的孩子。 我已经实现了拖放功能,可以将视图从一个网格拖到另一个网格。 我现在想要实现的是当我将视图放在主GameBoard网格上时,我希望网格自动缩放。 我还希望实现Pinch缩放,以便用户也可以自己放大/缩小网格。 有没有办法实现这个目标?

我试图动态地增加gridview列的高度和宽度,但它没有用,请建议我这样做的方法。

谢谢。

I have two gridviews, they contains my custom views as their children. I have implemented a drag and drop functionality to drag a view from one grid to another. What I want to achieve now is when I drop my view on the main GameBoard grid, I want the Grid to Zoom automatically. I also want to implement Pinch zoom so that user can zoom in/out the grid by himself also. Is there any way to achieve this?

I have tried to increase the gridview column height and width dynamically, but it is not working out, please suggest me a way to do this.

Thanks.

最满意答案

解决了这个问题后,我已经挖了很多东西,但最终我陷入了黑洞。 修改整个游戏以删除GridView并使用基本Canvas来实现所有功能。 希望这有助于某人。

谢谢

I have dig out a lot after solving this, but I end up in a black hole. Revised entire game to remove the GridView and use basic Canvas to achieve all the functionality. Hope this helps someone.

Thanks

更多推荐

本文发布于:2023-08-05 04:13:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1427289.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:Android   GridView   Zoom

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!