Read the statement by Michael Teeuw here.
Magic Touch Display
-
@Manino whatever other module want to control show and hide of modules.
sendNotification is a broadcast to all other modules. if they understand the notification then they can act on it
MMM-ModuleController obviously watches for this notification from some other module and then acts to show or hide modules.
-
@sdetweil Yes, but should I copy paste it into config or what?
I’m on a very low level of the Magic Mirror, have been here for only a month and I can’t understand were to put the line or lines. I have tried at least 50 different places, in files, cofig, and also the css. I can’t do it right.
-
@Manino no. that would go inside another.module where u want to control modules being shown or hidden
consider a module that has an on/off button, a toggle, default on.
when you press it, all the other modules should be hidden. when you press it again the modules should be shown
now, YOU could write and maintain all the code that does the show and hide, OR you could send that notification to some other module that provides that function.
so, in this button action section of this new module you could paste this code to signal hide and show.
it doesn’t go anywhere else
-
@sdetweil And what is another.module?
I have the MMM-ModuleController, MMM-Calculator, MMM-DrawingBoard. Do you mean someone of those or is it something else? I do understand what is supposed to happen, but can’t figure out HOW to do it with those lines.
-
@Manino look at the source for
https://github.com/Jopyth/MMM-Buttons
his doc says that this module can send notifications to two other modules