ontouch - Switching positions of two views(images) in Android

Posted by idish on Stack Overflow See other posts from Stack Overflow or by idish
Published on 2012-06-30T15:10:51Z Indexed on 2012/06/30 15:15 UTC
Read the original article Hit count: 152

Filed under:
|

I've been looking for that 2 days long and haven't found anything related to it.

I'll give an example for my goal. Let's say I have 2 images positioned side by side horizontally. I want the user to be able to switch their positions onlongtouch listener. so let's say that the first image was on the left and the second was on the right side, after switching positions between them, the first image would be in the right and the second would be on the left side.

Basically, it is just like in the launcher where you can switch apps positions.

Please, if anything is not clear for you, I would like to know, and I'll try to explain it better, thank you.

© Stack Overflow or respective owner

Related posts about java

Related posts about android