如何动态移动ImageButton? [英] How to move a ImageButton dynamically?

查看:108
本文介绍了如何动态移动ImageButton?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是Android的新手

I'm new to Android

我需要动态移动ImageButton,就像当我单击按钮时一样,需要将其重新放置到新位置.我正在使用AbsoluteLayout.

I need to move the ImageButton dynamically, Like when i click the button it needs to be relocated into a new position. Im using AbsoluteLayout.

推荐答案

从不使用AbsoluteLayouts.请改用动画. imageView.startAnimation(ANIMATION);您可以从Google 此处找到示例此处

Never ever use AbsoluteLayouts. Use animations instead. imageView.startAnimation(ANIMATION); You can find examples from google here and here

这篇关于如何动态移动ImageButton?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆