def add(self): block= self.le.text() dict={'name':str(block),'apps':[],'files':[], 'directories':[]} self.conf['blocks'].append(dict) self.parent.conf=self.conf Config.create_from_info(self.conf) self.parent.updateBlocks() self.parent.update_settings() self.update() self.close()
def update_settings(self): #update current config Config.create_from_info(self.conf) QtGui.QApplication.processEvents() self.parent.update_all()