* Set the nativeView field performing extra checks and updates to the native properties on the new view. * Use in cases where the createNativeView is not suitable. * As an example use in item controls where the native parent view will create the native views for child items.
(value: any)
| 1240 | * As an example use in item controls where the native parent view will create the native views for child items. |
| 1241 | */ |
| 1242 | setNativeView(value: any): void { |
| 1243 | if (this.__nativeView === value) { |
| 1244 | return; |
| 1245 | } |
| 1246 | |
| 1247 | if (this.__nativeView) { |
| 1248 | this._suspendNativeUpdates(SuspendType.NativeView); |
| 1249 | // We may do a `this.resetNativeView()` here? |
| 1250 | } |
| 1251 | |
| 1252 | this.__nativeView = this.nativeViewProtected = value; |
| 1253 | if (this.__nativeView) { |
| 1254 | this._suspendedUpdates = undefined; |
| 1255 | this.initNativeView(); |
| 1256 | this._resumeNativeUpdates(SuspendType.NativeView); |
| 1257 | } |
| 1258 | } |
| 1259 | |
| 1260 | /** |
| 1261 | * Tears down the UI of a reusable node by making it no longer reusable. |
nothing calls this directly
no test coverage detected