Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/haxeui/haxeui-core
Browse files Browse the repository at this point in the history
  • Loading branch information
ianharrigan committed Nov 27, 2024
2 parents 3e8e50b + 46f0d62 commit 16cc565
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion haxe/ui/containers/properties/PropertyEditor.hx
Original file line number Diff line number Diff line change
Expand Up @@ -99,10 +99,17 @@ class PropertyEditorOptions extends PropertyEditor {

@:bind(buttonBar, UIEvent.CHANGE)
private function onButtonBarChange(_) {
onValueChanged(buttonBar.selectedButton.text);
if (buttonBar.selectedButton != null) {
onValueChanged(buttonBar.selectedButton.text);
} else {
onValueChanged(null);
}
}

public override function applyValue(value:Variant) {
if (value == null) {
buttonBar.selectedIndex = -1;
}
for (button in buttonBar.findComponents(Button)) {
if (button.text == value.toString() || button.id == value.toString()) {
button.selected = true;
Expand Down

0 comments on commit 16cc565

Please sign in to comment.