Bug 1445444: Properly initialize plugin window drawing type on Windows r=jimm
authorDavid Parks <dparks@mozilla.com>
Mon, 25 Jun 2018 13:16:44 -0700
changeset 426829 59221b30f49baa42ee9f8d12a087e093398165ce
parent 426828 d2bdf1f738384b8253d30478fc5bcf9c31673c24
child 426830 eb542860b989d4f6ea1ffcb29ff843b857d78482
child 426905 547144f5596c1a146b208d68d93950a6313080ca
push id105337
push userbtara@mozilla.com
push dateTue, 17 Jul 2018 03:49:53 +0000
treeherdermozilla-inbound@59221b30f49b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjimm
bugs1445444
milestone63.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1445444: Properly initialize plugin window drawing type on Windows r=jimm Sets the default plugin window type to windowed on Windows. Most of the time, plugins use async drawing so this will be overwritten but it should be properly initialized for cases where we do not switch to async.
dom/plugins/base/nsPluginNativeWindowWin.cpp
--- a/dom/plugins/base/nsPluginNativeWindowWin.cpp
+++ b/dom/plugins/base/nsPluginNativeWindowWin.cpp
@@ -470,16 +470,17 @@ HookSetWindowLongPtr()
 nsPluginNativeWindowWin::nsPluginNativeWindowWin() : nsPluginNativeWindow()
 {
   // initialize the struct fields
   window = nullptr;
   x = 0;
   y = 0;
   width = 0;
   height = 0;
+  type = NPWindowTypeWindow;
 
   mPrevWinProc = nullptr;
   mPluginWinProc = nullptr;
   mPluginType = nsPluginHost::eSpecialType_None;
 
   mParentWnd = nullptr;
   mParentProc = 0;