MCPcopy Index your code
hub / github.com/NativeScript/NativeScript / _hasAncestorView

Function _hasAncestorView

packages/core/ui/core/view/view-common.ts:1257–1267  ·  view source on GitHub ↗
(ancestorView: ViewCommon)

Source from the content-addressed store, hash-verified

1255 }
1256
1257 _hasAncestorView(ancestorView: ViewCommon): boolean {
1258 const matcher = (view: ViewCommon) => view === ancestorView;
1259
1260 for (let parent = this.parent; parent != null; parent = parent.parent) {
1261 if (matcher(<ViewCommon>parent)) {
1262 return true;
1263 }
1264 }
1265
1266 return false;
1267 }
1268
1269 /**
1270 * Shared helper method for applying glass effects to views.

Callers

nothing calls this directly

Calls 1

matcherFunction · 0.85

Tested by

no test coverage detected