TMS
Guest
|
Posted:
Sun Oct 17, 2004 1:25 am Post subject:
Keypress handling in fullscreen for MFC? |
|
|
How should you handle a keypress in fullscreen mode when the control is
embedded in a dialog using MFC?
I've created a simple dialog-based application using the wizard for VC++6.0
(as described in the SDK help on "Embedding the Windows Media Player Control
in an MFC Project"). I then use the context menu to zoom the window to
fullscreen, but then when I press any key, the visualization stops, the
player continues playing, and I don't get back to the dialog box. At that
point, the only thing that works is 'Ctrl-Alt-Del' and terminating the
process.
Experimentation has shown that I can create a handler for the mousedown
event for the player that simply has "m_player.SetFullScreen(FALSE)" that
works to exit fullscreen mode. The same approach does not work in a handler
for the keydown event for the player, however. Though I've verified that I do
get into the keydown handler, once I exit that handler, I don't seem to get
into any others. e.g. keyup.
What's the approach to handling keypresses in fullscreen when embedding the
control?
Thanks in advance,
--- TMS
|
|