X-Git-Url: http://plrg.eecs.uci.edu/git/?p=smartthings-infrastructure.git;a=blobdiff_plain;f=ColorControl%2FColorControls.groovy;h=90223c54bdd233baf3feb1690ed53477676ef9e9;hp=9b003f6189301780896e68525c7b74ecaf455566;hb=e98662a7daa8b953396cc514738ec56a41172d42;hpb=55f57d1619271ede7bbd5c83e6218df6772afc89;ds=inline diff --git a/ColorControl/ColorControls.groovy b/ColorControl/ColorControls.groovy index 9b003f6..90223c5 100644 --- a/ColorControl/ColorControls.groovy +++ b/ColorControl/ColorControls.groovy @@ -205,6 +205,14 @@ public class ColorControls { } } + def setLevel(long level) { + if (level != this.level) { + this.currentLevel = level + this.level = level + colorControls[0].setLevel(level) + } + } + def setColorTemperature(int colorTemperature) { if (colorTemperature != this.colorTemperature) { this.colorTemperature = colorTemperature