Page 1 of 1

Eventreceiver + windows form

Posted: Fri May 04, 2007 8:01 am
by Dave
Hello, I'm experiencing a problem with the event receiver. Currently I have it running within a Windows MFC form. The Irrlicht device is created with the HWND of a CButton, which is located in the middle of the form.

Now the problem is that for some reason, I don't get any feedback from the eventreceiver. No mouse or keyboard, nothing. I placed a breakpoint right at the beginning, but it didn't break there.

When I don't embed the Irrlicht window in my form, everything works. I'm able to selected items and move them using the keyboard. And the only thing I changed is wether or not the viewport should be embedded. The rest of the code remains exactly the same.

Does anyone have an idea what the solution might be?

Posted: Fri May 04, 2007 8:49 am
by Sylence
If you use a different window to draw with irrlicht in, you have to write your own input handling code.
In this case use the input handling that MFC provides and send them to your event receiver

Posted: Fri May 04, 2007 9:09 am
by Dave
Thanks, I didn't think of that. It works now :)