Page 1 of 1

use of on_gui_checked_state_changed ?

Posted: Fri Jul 22, 2016 10:08 am
by binbinhfr
http://lua-api.factorio.com/0.13.9/even ... te_changed

about the new on_gui_checked_state_changed event, I wonder why it has been separated from on_gui_click ?
Did I miss something?

On the other hand, this new on_gui_text_changed is very useful !

Re: use of on_gui_checked_state_changed ?

Posted: Fri Jul 22, 2016 10:10 am
by Klonan
binbinhfr wrote:http://lua-api.factorio.com/0.13.9/even ... te_changed

about the new on_gui_checked_state_changed event, I wonder why it has been separated from on_gui_click ?
Did I miss something?

On the other hand, this new on_gui_text_changed is very useful !

Because you can right-click a checkbox which will register the on_click but not change the state of the checkbox

Re: use of on_gui_checked_state_changed ?

Posted: Fri Jul 22, 2016 11:23 am
by binbinhfr
Klonan wrote:Because you can right-click a checkbox which will register the on_click but not change the state of the checkbox
Oh, ok, that's subtile. I did not know that on_click was reacting to righ-clicks too. (but we cannot make the distinction with the left click, no ?)