Skip to content

Commit 021c0bb

Browse files
farfromrefugNathanWalker
authored andcommitted
fix(core): delegate should be set on nativeTextViewProtected (NativeScript#8881)
just like textfields. Fixes components extending this one
1 parent 29da0fb commit 021c0bb

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

packages/core/ui/text-view/index.ios.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ class NoScrollAnimationUITextView extends UITextView {
8585
@CSSType('TextView')
8686
export class TextView extends TextViewBaseCommon {
8787
nativeViewProtected: UITextView;
88+
nativeTextViewProtected: UITextView;
8889
private _delegate: UITextViewDelegateImpl;
8990
_isShowingHint: boolean;
9091
public _isEditing: boolean;
@@ -114,11 +115,11 @@ export class TextView extends TextViewBaseCommon {
114115
@profile
115116
public onLoaded() {
116117
super.onLoaded();
117-
this.ios.delegate = this._delegate;
118+
this.nativeTextViewProtected.delegate = this._delegate;
118119
}
119120

120121
public onUnloaded() {
121-
this.ios.delegate = null;
122+
this.nativeTextViewProtected.delegate = null;
122123
super.onUnloaded();
123124
}
124125

0 commit comments

Comments
 (0)