Android: Handling Touch Events in Viewgroup

Handling Touch Events in Viewgroup(Android).

          Android market is saturated with so many applications. Looking at the top android applications in the Google play store, its understandable that UI plays a key role in popularity of an application. Performance is another factor that affects it. For an application to be successful, first the sole purpose of the application must be perfectly designed, also the UI of that application must be designed in such a way that it should be impressive and it should be different from others.
         Users are not aware how the back-end stuff of an application works, and they don't care. They just want the application fulfill their needs. But , they are cared of how UI works. User will trash the application if the UI is poorly designed, even if it does the work well. Its the UI which makes an  impression about an application. So while developing an application,the developer has to really care about designing the UI perfectly. Extra care need to given to developing an UI.
        Android UI are designed for touch screens. Touch in UI has to be perfectly handled. This post is about how to handle Touch events while developing an custom layout in Android.

Comments

  1. Great post, thanks for this! I was really struggling to understand exactly how touch events work in a ViewGroup, and this is the best explanation I found.

    ReplyDelete
  2. Good post. Would you please give an example?

    ReplyDelete
  3. nice post. Do u have any suggestion to pass touch event control back to child view from parent view.

    ReplyDelete
    Replies
    1. Actually its not possible. As a hack, what we can do is dispatch a CANCEL event, followed by down event,which will start another touch cycle such that child can take control. But its buggy in some cases.

      Delete
  4. Given so much info in it, These type of articles keeps the users interest in the website, and keep on sharing more ... good luck.
    Android Training in chennai | Android Training

    ReplyDelete

  5. Iam so thrilled because of finding your alluring website here.Actually i was searching for Android.Your blog is so astounding and informative too..Iam very happy to find such a creative blog. Iam also find another one by mistake while am searching the same topicIOS Development.Thank you soo much..

    ReplyDelete

Post a Comment