LightBlog

lundi 21 août 2017

Google is Making Pen Input Behave Like Touch in Chrome OS

Tablets and even laptops specifically aren’t selling as much as they used to. Sure, there are a number of people still using them every day, but sales numbers have stagnated and even declined over the last few years. We are seeing growth in a new segment though, the 2-in-1 devices, where a laptop has the capability to be used as a tablet. There’s a Chrome OS device that comes with a stylus, the Samsung Chromebook Pro, but it looks as if Google is working to improve stylus support in the platform.

We have discovered three different commits for Chrome OS that show this work is being done right now. The first linked below was updated on August 18th, and it explains how things will be handled in a future update to the platform. They want the stylus to behave like a touch input all over Chrome OS as it is an easier method and one that is more intuitive to the end user. The developer says it is too difficult to teach views in Chrome about PointerEvents everywhere.

So to simplify things, they laid out their plan for how things a stylus will work with Chrome OS. For example, if the tip of a stylus is hovering over the screen then Chrome OS will treat it like MouseEvents. Then it will look for two different things when the tip of stylus first touches a digitizer. If a button is being held down (excluding the tip of the stylus), then it will dispatch MouseEvents until the tip of the stylus is removed from the screen.

However, if there aren’t any buttons being held down, then Chrome OS will dispatch TouchEvents so that the platform treats it as if you were tapping/touching the UI element on the screen. So you’ll be able to do things like scrolling through a webpage with a stylus like you normally would when you’re using your finger.


Commit #1 Commit #2 Commit #3



from xda-developers http://ift.tt/2vXdi5V
via IFTTT

.

Aucun commentaire:

Enregistrer un commentaire