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

Method disposeNativeView

packages/core/ui/frame/index.ios.ts:58–94  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

56 }
57
58 public disposeNativeView() {
59 const current = this._currentEntry;
60 const executingEntry = this._executingContext ? this._executingContext.entry : null;
61
62 if (executingEntry) {
63 this._disposeBackstackEntry(executingEntry);
64 }
65
66 this.backStack.forEach((entry) => {
67 if (entry !== executingEntry) {
68 this._disposeBackstackEntry(entry);
69 }
70 });
71
72 if (current) {
73 this._disposeBackstackEntry(current);
74 }
75
76 this._removeFromFrameStack();
77
78 if (this.viewController) {
79 this.viewController.lastExecutingTransition = null;
80 this.viewController = null;
81 }
82
83 // This was the last frame so we can get rid of the controller delegate reference
84 if (this._isFrameStackEmpty()) {
85 navControllerDelegate = null;
86 }
87
88 if (this._ios) {
89 this._ios.controller = null;
90 this._ios = null;
91 }
92
93 super.disposeNativeView();
94 }
95
96 // @ts-ignore
97 public get ios(): iOSFrame {

Callers

nothing calls this directly

Calls 4

forEachMethod · 0.80
_removeFromFrameStackMethod · 0.80
_isFrameStackEmptyMethod · 0.80

Tested by

no test coverage detected