def __init__(self, box, comar, link_name): QListBoxItem.__init__(self, box) self.comar = comar self.link_name = link_name self.link_type = "net" self.remote_name = "" comar.call_package("Net.Link.linkInfo", link_name) tmp = comar.read_cmd() if tmp[0] != comar.RESULT: return self.link_type, self.name, self.remote_name = tmp[2].split("\n") self.f1 = QFont() self.f1.setBold(True)
def __init__(self, box, comar, name, link_name): QListBoxItem.__init__(self, box) self.comar = comar self.name = name self.online = "down" self.link_name = link_name self.device = "" self.device_name = "" self.address = "" self.f1 = QFont() self.f2 = QFont() self.f1.setBold(True) self.f1.setPointSize(self.f1.pointSize() + 4) comar.call_package("Net.Link.connectionInfo", link_name, [ "name", name ], id=2) comar.call_package("Net.Link.getAddress", link_name, [ "name", name ], id=3) comar.call_package("Net.Link.getState", link_name, [ "name", name ], id=4)
def __init__(self, box, comar, name, link_name): QListBoxItem.__init__(self, box) self.comar = comar self.online = False self.name = name self.link_name = link_name self.device = "" self.device_name = "" self.address = "" self.f1 = QFont() self.f2 = QFont() self.f1.setBold(True) self.f1.setPointSize(self.f1.pointSize() + 4) self.up_pix = QPixmap(locate("data", "net_kga/net-up.png")) self.down_pix = QPixmap(locate("data", "net_kga/net-down.png")) comar.call_package("Net.Link.connectionInfo", link_name, [ "name", name ], id=2) comar.call_package("Net.Link.getAddress", link_name, [ "name", name ], id=3) comar.call_package("Net.Link.getState", link_name, [ "name", name ], id=4)