diff --git a/pydm/widgets/rules.py b/pydm/widgets/rules.py index d573a8c67..b2eca6df0 100644 --- a/pydm/widgets/rules.py +++ b/pydm/widgets/rules.py @@ -3,13 +3,11 @@ import functools import weakref -from qtpy.QtCore import QThread, QMutex, Signal, QMutexLocker +from qtpy.QtCore import QThread, QMutex, Signal from qtpy.QtWidgets import QWidget, QApplication - +from ..utilities import is_qt_designer from .channel import PyDMChannel -import pydm.data_plugins - import numpy as np import math @@ -190,7 +188,8 @@ def register(self, widget, rules): value_slot=value_cb, enum_strings_slot=enums_cb) item['channels'].append(c) rules_db.append(item) - if initial_val: + + if initial_val and not is_qt_designer(): self.emit_value(widget_ref, name, prop, initial_val) if rules_db: @@ -219,6 +218,9 @@ def unregister(self, widget_ref): del w_data def run(self): + if is_qt_designer(): + return + while not self.isInterruptionRequested(): w_map = self.widget_map.copy() for widget_ref, rules in w_map.items():