Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(928)

Unified Diff: webkit/glue/plugins/webplugin_delegate_impl_mac.mm

Issue 257008: Fix several issues around fullscreen Mac plugins:... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webkit/glue/plugins/webplugin_delegate_impl_mac.mm
===================================================================
--- webkit/glue/plugins/webplugin_delegate_impl_mac.mm (revision 27721)
+++ webkit/glue/plugins/webplugin_delegate_impl_mac.mm (working copy)
@@ -563,6 +563,21 @@
}
void WebPluginDelegateImpl::OnNullEvent() {
+ if (!webkit_glue::IsPluginRunningInRendererProcess()) {
+ // If the plugin is running in a subprocess, drain any pending system
+ // events so that the plugin's event handlers will get called on any
+ // windows it has created. Filter out activate/deactivate events on
+ // the fake browser window, but pass everything else through.
+ EventRecord event;
+ while (GetNextEvent(everyEvent, &event)) {
+ if (event.what == activateEvt && cg_context_.window &&
+ reinterpret_cast<void *>(event.message) != cg_context_.window)
+ continue;
+ instance()->NPP_HandleEvent(&event);
+ }
+ }
+
+ // Send an idle event so that the plugin can do background work
NPEvent np_event = {0};
np_event.what = nullEvent;
np_event.when = TickCount();
« chrome/plugin/plugin_thread.cc ('K') | « webkit/glue/plugins/fake_plugin_window_tracker_mac.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698