Skip to content

Commit

Permalink
Add fire_and_forget member to Property. (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Stegeman authored Feb 5, 2018
1 parent 67a1a37 commit d4e6731
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions gateway_addon/addon_manager_proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,8 @@ def set_prop_fn(proxy):
prop = dev.find_property(msg['data']['propertyName'])
if prop:
prop.set_value(msg['data']['propertyValue'])
if prop.fire_and_forget:
self.send_property_changed_notification(prop)

self.make_thread(set_prop_fn, args=(self,))
continue
Expand Down
1 change: 1 addition & 0 deletions gateway_addon/property.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def __init__(self, device, name, description):
self.value = None
self.description = {}
self.visible = True
self.fire_and_forget = False

if 'visible' in description:
self.visible = description['visible']
Expand Down

0 comments on commit d4e6731

Please sign in to comment.