Add getHeader functionlity..

This commit is contained in:
Michael Teeuw
2016-09-20 17:22:24 +02:00
parent c916472b22
commit b2a7d3584b
4 changed files with 66 additions and 14 deletions

View File

@@ -84,6 +84,17 @@ var Module = Class.extend({
return div;
},
/* getHeader()
* This method generates the header string which needs to be displayed if a user has a header configured for this module.
* This method is called by the Magic Mirror core, but only if the user has configured a default header for the module.
* This method needs to be subclassed if the module wants to display modified headers on the mirror.
*
* return string - The header to display above the header.
*/
getHeader: function() {
return this.data.header;
},
/* notificationReceived(notification, payload, sender)
* This method is called when a notification arrives.
* This method is called by the Magic Mirror core.