Hi Denis, Thanks a lot for looking at this! I will let Glenn answer. Cheers, Doru
On Oct 26, 2016, at 11:02 AM, Denis Kudriashov <dionisiydk@gmail.com> wrote:
Hi.
I look at dev version of Bloc and have questions about events.
There is duplicated hierarchy of OSEvent and BlEvent. For example for OSKeyDownEvent and OSMouseButtonPressEvent there are same events from Block: BlKeyDownEvent and BlMouseDownEvent.
Bloc of course add many new events like BlDragEvent and BlDblClickEvent. But why we not manage all events equally? why we need this distinction?
Also I was so much surprized about keyboard modifiers. In OS there is OSStateModifiers with smart boolean states like leftShiftPressed, leftAltPressed which are decoded from integer bits of raw SDL event.
And in Bloc it is BlKeyModifiers which are created from OSStateModifier. And here is most amazing thing: BlKeyModifiers encode smart boolean flags about keys back into integer bits. So we have:
SDL event int => OSStateModifiers booleans => BlKeyModifiers int
Why it is done like this? And currently BlKeyModifiers lost many states from OSStateModifiers.
-- www.tudorgirba.com www.feenk.com "Yesterday is a fact. Tomorrow is a possibility. Today is a challenge."