AddWindow.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:mama 作者: maateen 项目源码 文件源码
def removeall_clicked(self, button, store):
        """
        @description: Same as the past function but remove all lines of the
        treeview
        """
        # if there is still an entry in the model
        old = expanduser('~') + '/.config/mama/mama.xml'
        new = expanduser('~') + '/.config/mama/.mama.bak'
        if os.path.exists(old):
            os.rename(old, new)

        if len(store) != 0:
            # remove all the entries in the model
            self.labelState.set_text('Remove all commands')
            for i in range(len(store)):
                iter = store.get_iter(0)
                store.remove(iter)

            self.saveTree(store)
        print("Empty list")
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号