diff --git a/resources/strings/strings.xml b/resources/strings/strings.xml index 3dad734..8cd73d8 100644 --- a/resources/strings/strings.xml +++ b/resources/strings/strings.xml @@ -32,6 +32,7 @@ No configuration URL in the application settings. No Internet connection. No JSON returned from HTTP request. + Menu definition error, check the instructions. No Phone connection. No phone connection, no cached menu. No Response, check Internet connection diff --git a/source/HomeAssistantApp.mc b/source/HomeAssistantApp.mc index 4fd0318..87aef09 100644 --- a/source/HomeAssistantApp.mc +++ b/source/HomeAssistantApp.mc @@ -218,6 +218,8 @@ class HomeAssistantApp extends Application.AppBase { } else { if (data == null) { ErrorView.show(WatchUi.loadResource($.Rez.Strings.NoJson) as Lang.String); + } else if (data.size() == 0) { + ErrorView.show(WatchUi.loadResource($.Rez.Strings.NoMenu) as Lang.String); } else { buildMenu(data); WatchUi.switchToView(mHaMenu, new HomeAssistantViewDelegate(false), WatchUi.SLIDE_IMMEDIATE);