MCPcopy Create free account
hub / github.com/NativeScript/NativeScript / _onSizeChanged

Method _onSizeChanged

packages/core/ui/core/view/index.ios.ts:405–417  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

403 }
404
405 _onSizeChanged(): void {
406 const nativeView = this.nativeViewProtected;
407 if (!nativeView) {
408 return;
409 }
410
411 const background = this.style.backgroundInternal;
412 const backgroundDependsOnSize = (background.image && background.image !== 'none') || background.clipPath || !background.hasUniformBorder() || background.hasBorderRadius() || background.hasBoxShadows();
413
414 if (this._nativeBackgroundState === 'invalid' || (this._nativeBackgroundState === 'drawn' && backgroundDependsOnSize)) {
415 this._redrawNativeBackground(background);
416 }
417 }
418
419 public updateNativeTransform() {
420 const scaleX = this.scaleX || 1e-6;

Callers 1

updateBackgroundMethod · 0.95

Calls 4

hasBorderRadiusMethod · 0.80
hasBoxShadowsMethod · 0.80
hasUniformBorderMethod · 0.45

Tested by

no test coverage detected