Fixed NullPointerException

This commit is contained in:
ExoMemphiz
2018-07-04 13:37:57 +02:00
parent b30823183e
commit 5a5fff8b2a
2 changed files with 4 additions and 4 deletions
@@ -302,10 +302,10 @@ abstract public class RenderableShadowNode extends VirtualNode {
int x = Math.round(dst[0]);
int y = Math.round(dst[1]);
if (mRegion == null) {
if (mRegion == null && mPath != null) {
mRegion = getRegion(mPath);
}
if (!mRegion.contains(x, y)) {
if (mRegion == null || !mRegion.contains(x, y)) {
return -1;
}
@@ -962,10 +962,10 @@ class TSpanShadowNode extends TextShadowNode {
int x = Math.round(dst[0]);
int y = Math.round(dst[1]);
if (mRegion == null) {
if (mRegion == null && mPath != null) {
mRegion = getRegion(mPath);
}
if (!mRegion.contains(x, y)) {
if (mRegion == null || !mRegion.contains(x, y)) {
return -1;
}