Scroll up/down html page in touch screen not working in jcef

Having problems with building or using the JCEF Java binding? Ask your questions here.

Scroll up/down html page in touch screen not working in jcef

Postby Noman » Thu Apr 21, 2016 5:30 am

Hi,

I am using jcef in my application which is running on linux tablets(Lenovo Tab3, OS=Ubuntu 14.04). I have added a feature in my application to browse html pages on internet. Currently I am getting a problem when loaded page have scrolling and if i want to scroll page up/down using touch then it is not working in that case. However scroll page up/down in is working in installed chrome browser in this tablet.
Can someone suggest me how i can scroll webpages using touch in jcef?
Noman
Newbie
 
Posts: 7
Joined: Wed Feb 11, 2015 9:52 am

Re: Scroll up/down html page in touch screen not working in

Postby magreenblatt » Thu Apr 21, 2016 8:10 am

JCEF uses off-screen rendering on Linux. So you need to handle the Java touch events and then convert them to calls into the CEF API. See https://bitbucket.org/chromiumembedded/ ... ew-default and related code.
magreenblatt
Site Admin
 
Posts: 12407
Joined: Fri May 29, 2009 6:57 pm

Re: Scroll up/down html page in touch screen not working in

Postby Noman » Fri Apr 22, 2016 5:50 am

Thanks for sharing I am looking into that.
I need another information hope you can help on this, Is it possible to inject a custom css on every loaded url in jcef browser. What i need to inject a css to remove selection of picture,text etc on html pages which i am loading into a browser so i need to add a css style: html, body {-webkit-touch-callout: none; -webkit-user-select: none;} into html page. I have checked there is no handler which can give a loaded page source/DOM so how i will do this?
Noman
Newbie
 
Posts: 7
Joined: Wed Feb 11, 2015 9:52 am


Return to JCEF Forum

Who is online

Users browsing this forum: No registered users and 19 guests