mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Improve support for a host owned message pump (issue #1805)
- Add new CefSettings.external_message_pump option and CefBrowserProcessHandler::OnScheduleMessagePumpWork() callback. - Improve documentation related to CefDoMessageLoopWork(). - Pass `--external-message-pump` command-line flag to cefclient or cef_unittests to test the new mode.
This commit is contained in:
@ -87,6 +87,22 @@ class CefBrowserProcessHandler : public virtual CefBase {
|
||||
virtual CefRefPtr<CefPrintHandler> GetPrintHandler() {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
///
|
||||
// Called from any thread when work has been scheduled for the browser process
|
||||
// main (UI) thread. This callback is used in combination with CefSettings.
|
||||
// external_message_pump and CefDoMessageLoopWork() in cases where the CEF
|
||||
// message loop must be integrated into an existing application message loop
|
||||
// (see additional comments and warnings on CefDoMessageLoopWork). This
|
||||
// callback should schedule a CefDoMessageLoopWork() call to happen on the
|
||||
// main (UI) thread. |delay_ms| is the requested delay in milliseconds. If
|
||||
// |delay_ms| is <= 0 then the call should happen reasonably soon. If
|
||||
// |delay_ms| is > 0 then the call should be scheduled to happen after the
|
||||
// specified delay and any currently pending scheduled call should be
|
||||
// cancelled.
|
||||
///
|
||||
/*--cef()--*/
|
||||
virtual void OnScheduleMessagePumpWork(int64 delay_ms) {}
|
||||
};
|
||||
|
||||
#endif // CEF_INCLUDE_CEF_BROWSER_PROCESS_HANDLER_H_
|
||||
|
Reference in New Issue
Block a user