Skip to content

Commit

Permalink
Update 事件和信号.md
Browse files Browse the repository at this point in the history
  • Loading branch information
maicss committed Dec 1, 2018
1 parent a66f08f commit ed7cae5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion 事件和信号.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
- 事件
- 事件目标

事件源就是发生了状态改变的对象。事件是这个对象状态的改变撞他改变的内容。事件目标是事件想作用的目标。事件源绑定事件处理函数,然后作用于事件目标身上。
事件源就是发生了状态改变的对象。事件是这个对象状态改变的内容。事件目标是事件想作用的目标。事件源绑定事件处理函数,然后作用于事件目标身上。

PyQt5处理事件方面有个signal and slot机制。Signals and slots用于对象间的通讯。事件触发的时候,发生一个signal,slot是用来被Python调用的(相当于一个句柄?这个词也好恶心,就是相当于事件的绑定函数)slot只有在事件触发的时候才能调用。

Expand Down

0 comments on commit ed7cae5

Please sign in to comment.