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:
@@ -6,6 +6,7 @@
|
||||
|
||||
#include "include/base/cef_logging.h"
|
||||
#include "include/cef_cookie.h"
|
||||
#include "cefclient/browser/main_message_loop_external_pump.h"
|
||||
#include "cefclient/common/client_switches.h"
|
||||
|
||||
namespace client {
|
||||
@@ -82,4 +83,12 @@ void ClientAppBrowser::OnRenderProcessThreadCreated(
|
||||
(*it)->OnRenderProcessThreadCreated(this, extra_info);
|
||||
}
|
||||
|
||||
void ClientAppBrowser::OnScheduleMessagePumpWork(int64 delay) {
|
||||
// Only used when `--external-message-pump` is passed via the command-line.
|
||||
MainMessageLoopExternalPump* message_pump =
|
||||
MainMessageLoopExternalPump::Get();
|
||||
if (message_pump)
|
||||
message_pump->OnScheduleMessagePumpWork(delay);
|
||||
}
|
||||
|
||||
} // namespace client
|
||||
|
Reference in New Issue
Block a user