Show More
@@ -253,7 +253,7 b' class Widget(LoggingConfigurable):' | |||||
253 | # Support methods |
|
253 | # Support methods | |
254 | #------------------------------------------------------------------------- |
|
254 | #------------------------------------------------------------------------- | |
255 | @contextmanager |
|
255 | @contextmanager | |
256 |
def _property |
|
256 | def _lock_property(self, key, value): | |
257 | """Lock a property-value pair. |
|
257 | """Lock a property-value pair. | |
258 |
|
258 | |||
259 | NOTE: This, in addition to the single lock for all state changes, is |
|
259 | NOTE: This, in addition to the single lock for all state changes, is | |
@@ -299,7 +299,7 b' class Widget(LoggingConfigurable):' | |||||
299 | for name in self.keys: |
|
299 | for name in self.keys: | |
300 | if name in sync_data: |
|
300 | if name in sync_data: | |
301 | value = self._unpack_widgets(sync_data[name]) |
|
301 | value = self._unpack_widgets(sync_data[name]) | |
302 |
with self._property |
|
302 | with self._lock_property(name, value): | |
303 | setattr(self, name, value) |
|
303 | setattr(self, name, value) | |
304 |
|
304 | |||
305 | def _handle_custom_msg(self, content): |
|
305 | def _handle_custom_msg(self, content): |
General Comments 0
You need to be logged in to leave comments.
Login now