From 3de7f8f13d2cef164b52a8dc1f5b09b3d4e12278 Mon Sep 17 00:00:00 2001 From: louis Date: Wed, 14 Jan 2015 14:20:22 +0100 Subject: added weather viewelement to metrix main menu --- dtd/displaymenu.dtd | 7 +++- libtemplate/templateview.c | 5 ++- skins/metrixhd/themes/default/globals.xml | 4 ++ skins/metrixhd/xmlfiles/displaymenumain.xml | 47 +++++++++++++++++++--- .../plug-weatherforecast-weatherforecast.xml | 29 ++++++------- ...eatherforecast-weatherforecastdetailcurrent.xml | 28 +++++++------ ...-weatherforecast-weatherforecastdetaildaily.xml | 3 ++ ...weatherforecast-weatherforecastdetailhourly.xml | 3 ++ skinskeleton/xmlfiles/displaymenumain.xml | 21 ++++++++++ views/displaychannelview.c | 5 ++- views/displaymenuview.c | 16 ++++++++ views/displaymenuview.h | 1 + views/viewhelpers.c | 7 ++-- views/viewhelpers.h | 2 +- 14 files changed, 138 insertions(+), 40 deletions(-) diff --git a/dtd/displaymenu.dtd b/dtd/displaymenu.dtd index 5dc80ef..b14c3da 100644 --- a/dtd/displaymenu.dtd +++ b/dtd/displaymenu.dtd @@ -75,6 +75,11 @@ debug CDATA #IMPLIED > + + + + discusage | devices | systemload | temperatures | currentschedule | currentweather | customtokens | menuitems)*> >::iterator it = pluginViews.begin(); it != pluginViews.end(); it++) { - esyslog("skindesigner: translating plugin %s", (it->first).c_str()); map< int, cTemplateView*> plugViews = it->second; for (map< int, cTemplateView*>::iterator it2 = plugViews.begin(); it2 != plugViews.end(); it2++) { - esyslog("skindesigner: translating view %d", (int)it2->first); cTemplateView *pluginView = it2->second; pluginView->Translate(); } @@ -1178,6 +1176,9 @@ string cTemplateViewMenu::GetViewElementName(eViewElement ve) { case veCurrentSchedule: name = "Current Schedule"; break; + case veCurrentWeather: + name = "Current Weather"; + break; case veCustomTokens: name = "Custom Tokens"; break; diff --git a/skins/metrixhd/themes/default/globals.xml b/skins/metrixhd/themes/default/globals.xml index 006eb5a..1eae5f1 100644 --- a/skins/metrixhd/themes/default/globals.xml +++ b/skins/metrixhd/themes/default/globals.xml @@ -270,6 +270,10 @@ max max + + for + für + - + - + + + + + + + + + + + + + + + + + + + - + - + @@ -225,10 +260,10 @@ {load} current system load --> - + - + diff --git a/skins/metrixhd/xmlfiles/plug-weatherforecast-weatherforecast.xml b/skins/metrixhd/xmlfiles/plug-weatherforecast-weatherforecast.xml index 9190266..b77899a 100644 --- a/skins/metrixhd/xmlfiles/plug-weatherforecast-weatherforecast.xml +++ b/skins/metrixhd/xmlfiles/plug-weatherforecast-weatherforecast.xml @@ -45,6 +45,9 @@ {iscurrent} true if item is "Current Weather" {ishourly} true if item is "Next 48 hours" {isdaily} true if item is "Next 7 days" + {city} configured city to display weather for + {latitude} latitude + {longitude} longitude If {iscurrent} is true, the following tokens are set: {timestamp} timestamp in hh:mm dd.mm of current forecast @@ -125,20 +128,18 @@ - - - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/skins/metrixhd/xmlfiles/plug-weatherforecast-weatherforecastdetailcurrent.xml b/skins/metrixhd/xmlfiles/plug-weatherforecast-weatherforecastdetailcurrent.xml index f1b07e2..4932759 100644 --- a/skins/metrixhd/xmlfiles/plug-weatherforecast-weatherforecastdetailcurrent.xml +++ b/skins/metrixhd/xmlfiles/plug-weatherforecast-weatherforecastdetailcurrent.xml @@ -35,6 +35,9 @@ + + +