Ejemplo n.º 1
0
 def savewlist(self):
     """保存白名单"""
     wlist = []
     rows = self.whiteList.rowCount()
     for row in range(rows):
         content = self.whiteList.item(row, 0).text()
         wlist.append(content)
     setxml("./listxml/whitelist.xml", wlist, "maillist", "mail")
     QMessageBox.information(self, "提示", self.tr("已保存至本地!"))
Ejemplo n.º 2
0
 def saveblist(self):
     """保存黑名单"""
     blist = []
     rows = self.blackList.rowCount()
     for row in range(rows):
         content = self.blackList.item(row, 0).text()
         blist.append(content)
     setxml("./listxml/blacklist.xml", blist, "maillist", "mail")
     QMessageBox.information(self, "提示", self.tr("已保存至本地!"))