b/3302354 Always pass multi-touch events into WebKit, then handle them in...
b/3302354 Always pass multi-touch events into WebKit, then handle them in WebView if preventDefault is not set. WebViewCore.java: add a MotionEvent field into TouchEventData for multi-touch so the extra data such as pressure, size can be preserved. WebView.java: 1. Extracted the common code for multi-touch and single touch to a new private function: handleTouchEventCommon() 2. Extracted the multi-touch code, including zooming and panning, to a new private function: handleMultiTouchInWebView() 3. In onTouchEvent(), single touch events keep the code path, but multi-touch events are always passed to Webkit first. 4. In Privatehandler.handleMessage(), if WebKit didn't consume the multi-touch event, the private handler calls the handleMultiTouchInWebView() to zoom and pan. Change-Id: I3eba8812bd7cf6a298ff12e0b66223dae6725060
Loading
Please register or sign in to comment