I'm trying to handle javascript calling C++ functions and sending results back from C++ to javascript.
I've read all the comments in cef_message_router.h and, as far as I can tell, I've implemented it all.
I've looked at the cefclient binding_test stuff, and it works as it should
I've copied the html / javascript from that to my app.
OnQuery does get called in my CefMessageRouterBrowserSide::Handler class, and I call callback->Success and return true from the OnQuery function, but I never get results back to javascript.
In the cefclient example, after calling callback->success, ClientApp::OnProcessMessageReceived is called (which is CefRenderProcessHandler::OnProcessMessageReceived, I believe).
In my app, that does not happen.
Presumably that's why my data isn't making its way back into javascript, but I can't figure out the problem.
In CefRenderProcessHandler I have functions for:
OnProcessMessageReceived
OnContextReleased
OnContextCreated
OnWebKitInitialized
OnWebKitInitialized and OnContextCreated are definitely being called, as I hit breakpoints when I set them there.
What could I be doing wrong that OnProcessMessageReceived is not being called? I feel like I must be missing something obvious but haven't been able to figure it out.
Help?!