mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-16 03:31:45 +08:00
17 lines
629 B
TypeScript
17 lines
629 B
TypeScript
import common = require("./text-base-common");
|
|
import types = require("utils/types");
|
|
import dependencyObservable = require("ui/core/dependency-observable");
|
|
|
|
export class TextBase extends common.TextBase {
|
|
public _onTextPropertyChanged(data: dependencyObservable.PropertyChangeData) {
|
|
if (this.android) {
|
|
var newValue = types.isNullOrUndefined(data.newValue) ? "" : data.newValue + "";
|
|
this.android.setText(newValue);
|
|
}
|
|
}
|
|
public _setFormattedTextPropertyToNative(value) {
|
|
if (this.android) {
|
|
this.android.setText(value._formattedText);
|
|
}
|
|
}
|
|
} |