mirror of
https://github.com/house-of-abbey/GarminHomeAssistant.git
synced 2025-05-02 13:42:32 +00:00
Update HomeAssistantApp.mc
Found a bug when our Dynamic DNS went down. Can't update no menu items.
This commit is contained in:
@ -441,9 +441,18 @@ class HomeAssistantApp extends Application.AppBase {
|
||||
// This function is called by a timer every Globals.menuItemUpdateInterval ms.
|
||||
function updateNextMenuItem() as Void {
|
||||
var itu = mItemsToUpdate as Lang.Array<HomeAssistantToggleMenuItem>;
|
||||
if (itu == null) {
|
||||
if (Globals.scDebug) {
|
||||
System.println("HomeAssistantApp updateNextMenuItem(): No menu items to update");
|
||||
}
|
||||
if (!mIsGlance) {
|
||||
ErrorView.show(WatchUi.loadResource($.Rez.Strings.ConfigUrlNotFound));
|
||||
}
|
||||
} else {
|
||||
itu[mNextItemToUpdate].getState();
|
||||
mNextItemToUpdate = (mNextItemToUpdate + 1) % itu.size();
|
||||
}
|
||||
}
|
||||
|
||||
function getQuitTimer() as QuitTimer {
|
||||
return mQuitTimer;
|
||||
|
Reference in New Issue
Block a user