Commit d8f0e36c authored by jhoneycutt@apple.com's avatar jhoneycutt@apple.com

2007-12-17 Jon Honeycutt <jhoneycutt@apple.com>

        Reviewed by Darin.

        <rdar://problem/5651291> REGRESSION: Flash content doesn't display
        (www.adobe.com)

        We were passing NPEvent** instead of NPEvent* to NPP_HandleEvent.

        * plugins/win/PluginViewWin.cpp:
        (WebCore::PluginViewWin::dispatchNPEvent): Changed to take NPEvent&, not
        NPEvent*
        (WebCore::PluginViewWin::paint): Pass NPEvent, not NPEvent*
        (WebCore::PluginViewWin::handleKeyboardEvent): same
        (WebCore::PluginViewWin::handleMouseEvent): same
        * plugins/win/PluginViewWin.h:




git-svn-id: http://svn.webkit.org/repository/webkit/trunk@28816 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 908e410e
2007-12-17 Jon Honeycutt <jhoneycutt@apple.com>
Reviewed by Darin.
<rdar://problem/5651291> REGRESSION: Flash content doesn't display
(www.adobe.com)
We were passing NPEvent** instead of NPEvent* to NPP_HandleEvent.
* plugins/win/PluginViewWin.cpp:
(WebCore::PluginViewWin::dispatchNPEvent): Changed to take NPEvent&, not
NPEvent*
(WebCore::PluginViewWin::paint): Pass NPEvent, not NPEvent*
(WebCore::PluginViewWin::handleKeyboardEvent): same
(WebCore::PluginViewWin::handleMouseEvent): same
* plugins/win/PluginViewWin.h:
2007-12-17 Alexey Proskuryakov <ap@webkit.org>
Reviewed by Darin.
......
......@@ -438,14 +438,14 @@ void PluginViewWin::paintMissingPluginIcon(GraphicsContext* context, const IntRe
context->restore();
}
bool PluginViewWin::dispatchNPEvent(NPEvent* npEvent)
bool PluginViewWin::dispatchNPEvent(NPEvent& npEvent)
{
if (!m_plugin->pluginFuncs()->event)
return true;
bool shouldPop = false;
if (m_plugin->pluginFuncs()->version < NPVERS_HAS_POPUPS_ENABLED_STATE && isWindowsMessageUserGesture(npEvent->event)) {
if (m_plugin->pluginFuncs()->version < NPVERS_HAS_POPUPS_ENABLED_STATE && isWindowsMessageUserGesture(npEvent.event)) {
pushPopupsEnabledState(true);
shouldPop = true;
}
......@@ -502,7 +502,7 @@ void PluginViewWin::paint(GraphicsContext* context, const IntRect& rect)
npEvent.lParam = reinterpret_cast<uint32>(&windowpos);
npEvent.wParam = 0;
dispatchNPEvent(&npEvent);
dispatchNPEvent(npEvent);
setNPWindowRect(frameGeometry());
......@@ -513,7 +513,7 @@ void PluginViewWin::paint(GraphicsContext* context, const IntRect& rect)
// ignores it so we just pass null.
npEvent.lParam = 0;
dispatchNPEvent(&npEvent);
dispatchNPEvent(npEvent);
context->releaseWindowsContext(hdc);
}
......@@ -533,7 +533,7 @@ void PluginViewWin::handleKeyboardEvent(KeyboardEvent* event)
}
KJS::JSLock::DropAllLocks;
if (!dispatchNPEvent(&npEvent))
if (!dispatchNPEvent(npEvent))
event->setDefaultHandled();
}
......@@ -605,7 +605,7 @@ void PluginViewWin::handleMouseEvent(MouseEvent* event)
HCURSOR currentCursor = ::GetCursor();
KJS::JSLock::DropAllLocks;
if (!dispatchNPEvent(&npEvent))
if (!dispatchNPEvent(npEvent))
event->setDefaultHandled();
// Currently, Widget::setCursor is always called after this function in EventHandler.cpp
......
......@@ -172,7 +172,7 @@ namespace WebCore {
void popPopupsStateTimerFired(Timer<PluginViewWin>*);
Timer<PluginViewWin> m_popPopupsStateTimer;
bool dispatchNPEvent(NPEvent*);
bool dispatchNPEvent(NPEvent&);
OwnPtr<PluginMessageThrottlerWin> m_messageThrottler;
void updateWindow() const;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment