604 views
in GUI Development by

Hello.

I've run into an interesting behavior of KeyPressHandler class.

For example my OnPress handler decides to bypass the incoming key event and sets KeyPressHandler.Continue variable to true. If this happens KeyPressHandler doesn't reset its internal variable pressCounter to zero, and next time the same key event arrives the KeyPressHandler processes it as OnHold event. 

Is it intended operation and user should manually reset pressCounter to zero?

Best regards,
Maxim.

1 Answer

0 votes
by

Hi Maxim,

thank you very much for this information. In fact this is an error in the actual implementation of the KeyPressHandler. Of course the handler should always start counting with 0. As workaround you can set the variable pressCounter to 0 when you decide to bypass the event to another handler. We will fix the problem in the next release.

Best regards

Paul Banach

Ask Embedded Wizard - Archive

Welcome to the Ask Embedded Wizard archive. This community forum served us well for many years, but we've evolved our support approach!

Your resources:

The Embedded Wizard Online Documentation provides comprehensive documentation, tutorials, examples and ready-to-use software packages.

For dedicated assistance, explore our Embedded Wizard Product Support.

You can still browse the valuable discussions from our community history here.

Embedded Wizard Website | Privacy Policy | Imprint

...