Mercurial > code > home > repos > light9
changeset 1782:e6eb97a87117
fix 'clear all' in live
Ignore-this: cae71ca982f3f136a57f6399480ffcb2
author | Drew Perttula <drewp@bigasterisk.com> |
---|---|
date | Tue, 05 Jun 2018 06:06:51 +0000 |
parents | e46907e9e053 |
children | 717a971132eb |
files | light9/web/live/live.coffee |
diffstat | 1 files changed, 8 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/light9/web/live/live.coffee Tue Jun 05 06:05:58 2018 +0000 +++ b/light9/web/live/live.coffee Tue Jun 05 06:06:51 2018 +0000 @@ -82,6 +82,10 @@ 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 @@ 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)