mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
TextBase and Button text-decoration and text-transform fixes
This commit is contained in:
@@ -25,16 +25,20 @@ var textProperty = new dependencyObservable.Property(
|
||||
"text",
|
||||
"Button",
|
||||
new proxy.PropertyMetadata("", dependencyObservable.PropertyMetadataSettings.AffectsLayout)
|
||||
);
|
||||
);
|
||||
|
||||
var formattedTextProperty = new dependencyObservable.Property(
|
||||
"formattedText",
|
||||
"Button",
|
||||
new proxy.PropertyMetadata("", dependencyObservable.PropertyMetadataSettings.AffectsLayout)
|
||||
);
|
||||
);
|
||||
|
||||
function onTextPropertyChanged(data: dependencyObservable.PropertyChangeData) {
|
||||
var button = <Button>data.object;
|
||||
|
||||
button.style._updateTextDecoration();
|
||||
button.style._updateTextTransform();
|
||||
|
||||
button._onTextPropertyChanged(data);
|
||||
}
|
||||
|
||||
@@ -63,6 +67,9 @@ export class Button extends view.View implements definition.Button {
|
||||
if (this.formattedText) {
|
||||
this.formattedText.updateSpansBindingContext(newValue);
|
||||
}
|
||||
|
||||
this.style._updateTextDecoration();
|
||||
this.style._updateTextTransform();
|
||||
}
|
||||
|
||||
get text(): string {
|
||||
|
||||
Reference in New Issue
Block a user