Exemplo n.º 1
0
    def __init__(self, parent=None):
        super(Creator_Widget, self).__init__(parent)

        # 界面语言
        self.lan = language.lan()
        self.current_lan = self.lan.get_language()

        self.__init_ui()
        self.__init_connect()
Exemplo n.º 2
0
    def __init__(self, parent=None):
        super(Main_Widget, self).__init__(parent)
        self.main_widget_settings = QtCore.QSettings("dezerlin_soft", "submitter")

        # 界面语言
        self.lan = language.lan()
        self.current_lan = self.lan.get_language()

        self.__init_ui()
        self.__init_connect()
Exemplo n.º 3
0
    def __init__(self, parent=None):
        super(Dialog, self).__init__(parent)
        self.ok = "OK"
        self.cancel = "Cancel"

        # 界面语言
        self.lan = language.lan()
        self.current_lan = self.lan.get_language()

        self.__init_ui()
        self.__init_connect()
Exemplo n.º 4
0
    def __init__(self, parent=None):
        super(Task_List_Widget, self).__init__(parent)

        # 界面语言
        self.lan = language.lan()
        self.current_lan = self.lan.get_language()

        # 添加搜索框
        self.search_line = QtWidgets.QLineEdit(self)
        self.search_line.setPlaceholderText(self.current_lan.search)
        main_layout = QtWidgets.QVBoxLayout(self)
        main_layout.setContentsMargins(0, 0, 10, 0)
        main_layout.addStretch()
        main_layout.addWidget(self.search_line)
        # 设置滑块宽度
        self.verticalScrollBar().setStyleSheet("QScrollBar{width:10px;}")
        # 连接搜索
        self.search_line.textChanged.connect(self.filter_item)
Exemplo n.º 5
0
    def __init__(self):
        super(Main, self).__init__()
        # 实例化自定义信号
        self.signal_wrapper = Signal_Wrapper()
        # 实例化设置保存
        self.settings = Submitter_Setting()
        # 获取资源路径
        self.res_path = os.path.join(os.path.dirname(os.path.realpath(sys.argv[0])).replace('\\', '/'), "res")
        self.login_dialog_icon =base64_pic.get_res("login.ico")
        self.main_widget_icon = base64_pic.get_res("task.ico")

        # 实例化启动画面
        self.welcome_screen = QtWidgets.QSplashScreen()
        self.welcome_screen.setPixmap(QtGui.QPixmap(base64_pic.get_res("welcome.jpg")))

        # 获取当前语言
        self.lan = language.lan()
        self.current_lan = self.lan.get_language()

        # 实例化登录框
        self.login_dialog = login_dialog.Dialog()
        # 初始化语言选项
        self.login_dialog.set_language_box(self.lan.language_list, self.lan.get_language_name())
        self.login_dialog.set_title(self.current_lan.login_title, self.login_dialog_icon)

        # 实例化主窗口
        self.main_widget = main_ui.Main_Widget()
        # 设置 "显示最近" 的最大最小值
        self.main_widget.set_last_show_range(1, 100, self.settings.get_slider_position())
        # 设置图标和名称
        self.main_widget.set_title("DZL Task Hub", self.main_widget_icon)

        # 初始化信号和槽的连接
        self.__init_connect()

        # 当前版本文件文件名
        self.version_name = None