diff --git a/light9/web/live/live.coffee b/light9/web/live/live.coffee --- a/light9/web/live/live.coffee +++ b/light9/web/live/live.coffee @@ -82,6 +82,10 @@ coffeeElementSetup(class Light9LiveDevic daRow.max = 1 @push('deviceAttrs', daRow) + clear: -> + for lc in @shadowRoot.querySelectorAll("light9-live-control") + lc.clear() + ) coffeeElementSetup(class Light9LiveControls extends Polymer.Element @@ -180,12 +184,14 @@ coffeeElementSetup(class Light9LiveContr onGraph: -> @graph.runHandler(@update.bind(@), 'controls') + resendAll: -> for llc in @getElementsByTagName("light9-live-control") llc.resend() + clearAll: -> - for llc in @getElementsByTagName("light9-live-control") - llc.clear() + for dc in @shadowRoot.querySelectorAll("light9-live-device-control") + dc.clear() update: -> U = (x) => @graph.Uri(x)