From f3dabbb985bcd57f56f889a965e312fa54ea284a Mon Sep 17 00:00:00 2001 From: DS_Starter Date: Fri, 4 Oct 2019 14:55:49 +0000 Subject: [PATCH] 95_Dashboard: contrib 3.17.0 git-svn-id: https://svn.fhem.de/fhem/trunk@20312 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/contrib/DS_Starter/95_Dashboard.pm | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/fhem/contrib/DS_Starter/95_Dashboard.pm b/fhem/contrib/DS_Starter/95_Dashboard.pm index f5d704646..e39abee00 100644 --- a/fhem/contrib/DS_Starter/95_Dashboard.pm +++ b/fhem/contrib/DS_Starter/95_Dashboard.pm @@ -55,6 +55,7 @@ use vars qw($FW_ss); # is smallscreen, needed by 97_GROUP/95_VIEW # Versions History intern our %Dashboard_vNotesIntern = ( + "3.17.0" => "04.10.2019 Path handling of backgroundimage changed ", "3.16.0" => "04.10.2019 new attribute dashboard_hideGroupHeader, commandref revised ", "3.15.2" => "29.09.2019 fix warnings, Forum: https://forum.fhem.de/index.php/topic,16503.msg978883.html#msg978883 ", "3.15.1" => "25.09.2019 change initial attributes, commandref revised ", @@ -429,6 +430,10 @@ sub Dashboard_SummaryFN ($$$$) { readingsSingleUpdate($hash, "state", "Disabled", 0 ); return ""; } + + # Hintergrundbild bauen + my $bimg = $backgroundimage?"url(/fhem/images/$backgroundimage)":""; + Log3 ($name, 5, "Dashboard $name - Backgroundimage to display: $bimg"); if ($debug == 1) { $debugfield = "edit"; } if ($showtabs eq "tabs-and-buttonbar-at-the-top") { $showbuttonbar = "top"; } @@ -485,7 +490,7 @@ sub Dashboard_SummaryFN ($$$$) { $ret .= "\n"; $ret .= "\n"; $ret .= "\n"; - $ret .= "
\n"; + $ret .= "
\n"; ########################### Dashboard Tab-Liste ############################################## $ret .= "
    \n"; @@ -1245,7 +1250,13 @@ return $a;
  • dashboard_backgroundimage
    Displays a background image for the complete dashboard. The image is not stretched in any way. So the size should - match/extend the dashboard height/width. + match/extend the dashboard height/width. The relative path to "./www/images" has to be used.

    + + Example
    + attr dashboard_backgroundimage dashboard/cam_video.PNG
    + # File ./www/images/dashboard/cam_video.PNG is shown
    + attr dashboard_backgroundimage cam_video.PNG
    + # File ./www/images/cam_video.PNG is shown

  • @@ -1528,7 +1539,13 @@ return $a;
  • dashboard_backgroundimage
    Zeigt ein Hintergrundbild im Dashboard an. Das Bild wird nicht gestreckt, es sollte daher auf die Größe des Dashboards - passen oder diese überschreiten. + passen oder diese überschreiten. Es ist der relative Pfad zum Verzeichnis "./www/images" anzugeben.

    + + Beispiel
    + attr dashboard_backgroundimage dashboard/cam_video.PNG
    + # Bild ./www/images/dashboard/cam_video.PNG wird angezeigt
    + attr dashboard_backgroundimage cam_video.PNG
    + # Bild ./www/images/cam_video.PNG wird angezeigt