KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I have one ImageView in my application which can be situated anywhere on screen On touch I want to move this view at the center of the Screen. I tried this functionality with Translate Animation and its RELATIVE_TO_PARENT functionality as follows TranslateAnimation translateAnimation1 = new TranslateAnimation( TranslateAnimation.RELATIVE_TO_PARENT,0.0f, TranslateAnimation.RELATIVE_TO_PARENT,0.5f, TranslateAnimation.RELATIVE_TO_PARENT,0.0f, TranslateAnimation.RELATIVE_TO_PARENT,0.5f); but ImageView moves 50% (of the screen) down from its current position. Is there any way to move this view to the center of the screen regardless of its current position?
Tags (comma-separated)
Save Edits
Cancel