From 82d923a0a39b14363059faf9574a0df68010c91c Mon Sep 17 00:00:00 2001 From: Rossen Hristov Date: Wed, 11 Nov 2015 15:37:42 +0200 Subject: [PATCH] Fixed #1082: Null reference exception in view.android.setOnTouchListener method --- ui/core/view.android.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ui/core/view.android.ts b/ui/core/view.android.ts index 60753f31b..6a600229f 100644 --- a/ui/core/view.android.ts +++ b/ui/core/view.android.ts @@ -139,6 +139,10 @@ export class View extends viewCommon.View { } } + if (!owner._nativeView || !owner._nativeView.onTouchEvent) { + return false; + } + return owner._nativeView.onTouchEvent(motionEvent); } }));