mirror of
https://github.com/house-of-abbey/GarminHomeAssistant.git
synced 2026-06-26 14:03:28 +00:00
Update HomeAssistantView.mc
Bug fix for numeric picker initialisation when no user defined template is supplied.
This commit is contained in:
@@ -209,11 +209,9 @@ class HomeAssistantView extends WatchUi.Menu2 {
|
|||||||
}
|
}
|
||||||
fullList.addAll(item.getMenuView().getItemsToUpdate());
|
fullList.addAll(item.getMenuView().getItemsToUpdate());
|
||||||
} else if (item instanceof HomeAssistantNumericMenuItem) {
|
} else if (item instanceof HomeAssistantNumericMenuItem) {
|
||||||
// Numeric items can have an optional template to evaluate
|
// Numeric items can have an optional template to evaluate, but they must always be included in order
|
||||||
var nmi = item as HomeAssistantNumericMenuItem;
|
// to initialise the numeric picker's value.
|
||||||
if (nmi.hasTemplate()) {
|
|
||||||
fullList.add(item);
|
fullList.add(item);
|
||||||
}
|
|
||||||
} else if (item instanceof HomeAssistantToggleMenuItem) {
|
} else if (item instanceof HomeAssistantToggleMenuItem) {
|
||||||
fullList.add(item);
|
fullList.add(item);
|
||||||
} else if (item instanceof HomeAssistantTapMenuItem) {
|
} else if (item instanceof HomeAssistantTapMenuItem) {
|
||||||
|
|||||||
Reference in New Issue
Block a user