Plugin to WebBrowserComponent interaction, and visa-versa

Bumping will not help here on the forum (especially bumping after your original post is not even a day old).

You should look at the source code (jucer_LicenseThread.h and jucer_LicenseWebview.h) of the Projucer which needs to solve a similar situation: there the main window content is a WebBrowserComponent but the top header is a JUCE component.

To send data to the WebBrowserComponent you simply pass some URL parameters and call WebBrowserComponent::goToURL(). You’re webpage will need to decode the url parameters and do something with them (such as change the label on the button etc.).

Getting data/callbacks from the WebBrowserComponent to the app is a bit more involved. When you are ready to send data to JUCE, your webpage needs to re-direct your html page to a url with a custom scheme (for example, the projucer uses projucer://here-comes-all-my-data). As you’re JUCE webview gets a WebBrowserComponent::pageAboutToLoad callback everytime the page tries to load a new page, you can catch any redirect to the projucer URL scheme. You can then use the rest of the url as data and do something with it (such as change the label of a JUCE button). If you return false from pageAboutToLoad then the WebBrowserComponent won’t actually navigate to that url.

I hope this helps.