Skip to content
Snippets Groups Projects
Commit 5aa9d263 authored by jkerdreu's avatar jkerdreu
Browse files

- Get rid of type conversion, switched to type check only

git-svn-id: https://redmine.imt-atlantique.fr/svn/xaal/code/Go/trunk/xaal-lib/apps@3163 b32b6428-25c9-4566-ad07-03861ab6144f
parent 72723377
No related branches found
No related tags found
No related merge requests found
......@@ -75,7 +75,7 @@ func (l *Lamp) setBrightness(args xaal.MessageBody) *xaal.MessageBody {
if value > 100 {
value = 100
}
l.dev.GetAttribute("brightness").SetValue(value)
l.dev.GetAttribute("brightness").SetValue(int(value))
}
return nil
}
......
......@@ -41,7 +41,7 @@ func main() {
if value > 100 {
value = 100
}
brightness.SetValue(value)
brightness.SetValue(int(value))
if value == 0 {
turn_off(nil)
} else {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment