Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8705183
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T03:17:45+00:00 2026-06-13T03:17:45+00:00

In my android app I have a view which is laid on top of

  • 0

In my android app I have a view which is laid on top of another view. When I click a button this top view is animated and goes out of screen. The problem is that it is like the view is still “there” as it captures all touch events and they do not get passed to the view which is behind.

This is the code that animates the view away:

TranslateAnimation animation = new TranslateAnimation (0, 0, 0, height);
animation.setDuration(1000);
animation.setFillAfter(true);
topView.startAnimation(animation);

What can I do to solve this problem?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T03:17:46+00:00Added an answer on June 13, 2026 at 3:17 am

    Create an animation Listener and remove the view from its parent when the animation is over.

    Animation animation = new AlphaAnimation(0 ,0);
            animation.setAnimationListener(new AnimationListener() {
    
                public void onAnimationStart(Animation animation) {
                    // TODO Auto-generated method stub
    
                }
    
                public void onAnimationRepeat(Animation animation) {
                    // TODO Auto-generated method stub
    
                }
    
                public void onAnimationEnd(Animation animation) {
                    parentView.removeView(topView)
                }
            });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm writing an Android app, in which I have several buttons laid out in
i am making a app which takes photo on button click i have camera.java
I am writing a simple android app which have a edittext and a button.
I have a view which include another one with the include component (see http://android-developers.blogspot.com/2009/02/android-layout-tricks-2-reusing-layouts.html
I Have created an android app, which has view flipper and it has 4
I have a View in my android app which I want to scale &
I have a custom view in my Android App that uses a ScaleGestureDetector.SimpleOnScaleGestureListener to
I have an android app it displays web view.I want know the app idle
I have an Android app with a ListActivity in the main view. The list
I have a very simple dialog defined as: import android.app.AlertDialog; import android.content.Context; import android.view.LayoutInflater;

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.