breathing_phrase_list_wt.py 文件源码

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

项目:mindfulness-at-the-computer 作者: SunyataZero 项目源码 文件源码
def add_new_phrase_button_clicked(self):
        text_sg = self.add_to_list_qle.text().strip()  # strip is needed to remove a newline at the end (why?)
        if not (text_sg and text_sg.strip()):
            return
        mc.model.PhrasesM.add(
            text_sg,
            BREATHING_IN_DEFAULT_PHRASE,
            BREATHING_OUT_DEFAULT_PHRASE,
            "", ""
        )
        self.add_to_list_qle.clear()

        self.update_gui()
        self.list_widget.setCurrentRow(self.list_widget.count() - 1)
        # self.in_breath_phrase_qle.setFocus()

        # if dialog_result == QtWidgets.QDialog.Accepted:
        EditDialog.launch_edit_dialog()
        self.phrase_changed_signal.emit(True)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号