Android: chronometer widget and layout() method could not work well at the same time
Posted
by
Lennard
on Stack Overflow
See other posts from Stack Overflow
or by Lennard
Published on 2011-01-04T02:47:23Z
Indexed on
2011/01/04
2:54 UTC
Read the original article
Hit count: 249
I write a test android app, in which there are only two views, a chronometer and a imageview. Using the layout() method of the imageview to dynamically change the position of it, I wish to implement drag-and-drop effect. It does work.
However, each time the chronometer ticks, the imageview is always reverted to its original position, which seems that the whole screen is reloaded from the layout xml.
So, does anybody know how to prevent the imageview from reverting to the original place, and let chronometer and drag-and-drop effect coexist? Thx
© Stack Overflow or respective owner