KeyListener and the 'return' key


#1

I'm using juce::KeyListener in a component displayed with "juce::CallOutBox::launchAsynchronously" method.

I noticed that return key does not trigger keyPressed event (Windows platform). After examining juce_win32_Windowing.cpp, doKeyDown method on line 2011 I noticed, that VK_RETURN in not listed in switch. And because CallOutBox is modal method there is no parent to process this.

It seems like VK_RETURN is missing from switch statement. Or perhaps call to handleKeyPress is missing from switch default.

 


#2

After wasting a lot of time investigating your phantom tab key "bug" last week, and knowing that I hit the return key in juce apps every day, I find it hard to take this very seriously.


#3

You need to admit, that 'tab' implementation in Juce handleKeyPress is "odd" and that solution is not something trivial. At least not without knowledge how focus traveler works. And even then overriding createFocusTraverser to get keyPressed event is not really intuitive.

 

Regarding this 'return' issue.  I found out that ListBox in intercepting  this key. I can handle this now. Sorry for taking your time.