tugboat.py 文件源码

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

项目:scl_jamf_tools 作者: univ-of-utah-marriott-library-apple 项目源码 文件源码
def button_state(self):
        """
        sets buttons to the correct state
        """

        #
        # This method is used to enable/disable specific buttons, based on OS, etc.
        #
        # You want to use the Combobox option of state='disabled'.
        #
        # There are three options for state as follows:
        #
        #     state='normal' which is the fully functional Combobox.
        #     state='readonly' which is the Combobox with a value, but can't be changed (directly).
        #     state='disabled' which is where the Combobox cannot be interacted with.
        #
        # self.highlight_button = ttk.Style()
        # self.highlight_button.configure('Highlight.TButton', foreground='red')
        # ttk.Button(self.mainframe, text="Query this system", style='Highlight.TButton', command= lambda: self.query_jamf_me()).grid(column=2, row=20, padx =3, sticky=W)

        self.logger.info("%s: activated" % inspect.stack()[0][3])

        if self.platform == "Mac":
            self.jamf_management_btn.configure(state="normal")

        else:
            self.jamf_management_btn.configure(state="disabled")
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号