From 7daa07f52f86671a25c4df52a4044c74f6e7a04f Mon Sep 17 00:00:00 2001 From: poaudet Date: Sat, 28 Feb 2026 14:15:09 -0500 Subject: [PATCH] first commit --- source/HomeAssistantNumericPicker.mc | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/source/HomeAssistantNumericPicker.mc b/source/HomeAssistantNumericPicker.mc index 4b49196..ce0b733 100644 --- a/source/HomeAssistantNumericPicker.mc +++ b/source/HomeAssistantNumericPicker.mc @@ -43,15 +43,17 @@ class HomeAssistantNumericPicker extends WatchUi.Picker { step = 1.0; } - WatchUi.Picker.initialize({ - :title => new WatchUi.Text({ + WatchUi.Picker.initialize( + new WatchUi.Text({ :text => haItem.getLabel(), :locX => WatchUi.LAYOUT_HALIGN_CENTER, :locY => WatchUi.LAYOUT_VALIGN_BOTTOM }), - :pattern => [factory], - :defaults => [((val - min) / step).toNumber()] - }); + [factory], + { + :defaults => [((val - min) / step).toNumber()] + } + ); } //! Called when the user has completed picking.