def __init__(self, xmlobj): self._attrs = [] if xmlobj is not None: self.__name__ = xmlobj.tag for child in xmlobj: if child.tag == "property": key, text = qt3ui.loadProperty(child) else: text = aqtt(child.text) key = child.tag if isinstance(text, basestring): text = text.strip() setattr(self, key, text) self._attrs.append(key)
def __init__(self, xmlobj=None): self._attrs = [] if xmlobj is not None: self.__name__ = xmlobj.tag for child in xmlobj: if child.tag == "property": # Se importa aquí para evitar error de importación cíclica. from pineboolib.qt3ui import loadProperty key, text = loadProperty(child) else: text = aqtt(child.text) key = child.tag if isinstance(text, str): text = text.strip() setattr(self, key, text) self._attrs.append(key)