Error Summary-player (vitamio) Volume entity key and touch gesture control, volume adjustment conflict, vitamio gesture

Source: Internet
Author: User

Error Summary-player (vitamio) Volume entity key and touch gesture control, volume adjustment conflict, vitamio gesture

This is an exclusive experience. After a few days of online data query failure, we met in the group. Then let him help me look at it and finally solved the conflict. In this case, I would like to thank the colleague for his enthusiastic help;

Let's talk about this problem:

Currently, I am working on a film and television project. In this project, video playback must be used. Video Playback references the vitamio class library and SurfaceView controls are used on the playback page. These requirements are then imposed during video playback: The gesture slides to adjust the volume. When I had a hard time dealing with it, I did not think of it but encountered a conflict when I pressed the volume entity key to play the page exit. How can this problem be solved? A few lines of code.

Modify the review key listening here:

@ Overridepublic boolean onKeyDown (int keyCode, KeyEvent event) {// TODO Auto-generated method stubif (keyCode = KeyEvent. KEYCODE_BACK & event. getRepeatCount () = 0) {// if (event. getAction () = KeyEvent. ACTION_DOWN ){............ return true ;}}

I am not very clear about the reason. I guess: At this time, the volume key should be used as the return key function, and the above is to eliminate this conflict.





Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.