lambda, 匿名函数, 变量,传参
lambda:
# 无参数函数情况 def delete_one(): pass Button(otherFrame, text="删除", width=4, command=delete_one) # 有参数的函数,且自带参数event doub_event =lambda event: self.item_clicked(event, otherFrame) self.tree.tag_bind('ttk', '<Double-Button-1>', doub_event )