mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 754582 - Fixed unused-result warnings in Windows-specific code r=benjamin
This commit is contained in:
parent
136e182794
commit
d5f0f251b0
@ -1200,8 +1200,7 @@ PluginInstanceParent::NPP_HandleEvent(void* event)
|
||||
}
|
||||
}
|
||||
if (DoublePassRenderingEvent() == npevent->event) {
|
||||
CallPaint(npremoteevent, &handled);
|
||||
return handled;
|
||||
return CallPaint(npremoteevent, &handled) && handled;
|
||||
}
|
||||
|
||||
switch (npevent->event) {
|
||||
@ -1209,7 +1208,9 @@ PluginInstanceParent::NPP_HandleEvent(void* event)
|
||||
{
|
||||
RECT rect;
|
||||
SharedSurfaceBeforePaint(rect, npremoteevent);
|
||||
CallPaint(npremoteevent, &handled);
|
||||
if (!CallPaint(npremoteevent, &handled)) {
|
||||
handled = false;
|
||||
}
|
||||
SharedSurfaceAfterPaint(npevent);
|
||||
return handled;
|
||||
}
|
||||
@ -1237,10 +1238,7 @@ PluginInstanceParent::NPP_HandleEvent(void* event)
|
||||
case WM_WINDOWPOSCHANGED:
|
||||
{
|
||||
// We send this in nsObjectFrame just before painting
|
||||
SendWindowPosChanged(npremoteevent);
|
||||
// nsObjectFrame doesn't care whether we handle this
|
||||
// or not, just returning 1 for good hygiene
|
||||
return 1;
|
||||
return SendWindowPosChanged(npremoteevent);
|
||||
}
|
||||
break;
|
||||
}
|
||||
@ -1792,7 +1790,7 @@ PluginInstanceParent::PluginWindowHookProc(HWND hWnd,
|
||||
switch (message) {
|
||||
case WM_SETFOCUS:
|
||||
// Let the child plugin window know it should take focus.
|
||||
self->CallSetPluginFocus();
|
||||
unused << self->CallSetPluginFocus();
|
||||
break;
|
||||
|
||||
case WM_CLOSE:
|
||||
@ -1821,7 +1819,7 @@ PluginInstanceParent::SubclassPluginWindow(HWND aWnd)
|
||||
mPluginWndProc =
|
||||
(WNDPROC)::SetWindowLongPtrA(mPluginHWND, GWLP_WNDPROC,
|
||||
reinterpret_cast<LONG_PTR>(PluginWindowHookProc));
|
||||
bool bRes = ::SetPropW(mPluginHWND, kPluginInstanceParentProperty, this);
|
||||
DebugOnly<bool> bRes = ::SetPropW(mPluginHWND, kPluginInstanceParentProperty, this);
|
||||
NS_ASSERTION(mPluginWndProc,
|
||||
"PluginInstanceParent::SubclassPluginWindow failed to set subclass!");
|
||||
NS_ASSERTION(bRes,
|
||||
|
@ -792,7 +792,7 @@ PluginModuleParent::NP_Initialize(NPNetscapeFuncs* bFuncs, NPError* error)
|
||||
|
||||
if (NS_SUCCEEDED(mozilla::widget::GetAudioSessionData(id, sessionName,
|
||||
iconPath)))
|
||||
SendSetAudioSessionData(id, sessionName, iconPath);
|
||||
unused << SendSetAudioSessionData(id, sessionName, iconPath);
|
||||
#endif
|
||||
|
||||
return NS_OK;
|
||||
@ -1043,7 +1043,7 @@ void
|
||||
PluginModuleParent::ProcessRemoteNativeEventsInRPCCall()
|
||||
{
|
||||
#if defined(OS_WIN)
|
||||
SendProcessNativeEventsInRPCCall();
|
||||
unused << SendProcessNativeEventsInRPCCall();
|
||||
return;
|
||||
#endif
|
||||
NS_NOTREACHED(
|
||||
|
@ -25,7 +25,7 @@
|
||||
#include "nsThreadUtils.h"
|
||||
|
||||
#ifdef XP_WIN
|
||||
#include "Windows.h"
|
||||
#include <windows.h>
|
||||
#endif
|
||||
|
||||
using namespace mozilla;
|
||||
|
@ -66,6 +66,7 @@ using mozilla::plugins::PluginInstanceParent;
|
||||
#include "nsRenderingContext.h"
|
||||
#include "prmem.h"
|
||||
#include "WinUtils.h"
|
||||
#include "mozilla/unused.h"
|
||||
|
||||
#include "LayerManagerOGL.h"
|
||||
#include "BasicLayers.h"
|
||||
@ -84,6 +85,7 @@ extern "C" {
|
||||
#include "pixman.h"
|
||||
}
|
||||
|
||||
using namespace mozilla;
|
||||
using namespace mozilla::layers;
|
||||
using namespace mozilla::widget;
|
||||
|
||||
@ -252,7 +254,7 @@ bool nsWindow::OnPaint(HDC aDC, PRUint32 aNestingLevel)
|
||||
PluginInstanceParent* instance = reinterpret_cast<PluginInstanceParent*>(
|
||||
::GetPropW(mWnd, L"PluginInstanceParentProperty"));
|
||||
if (instance) {
|
||||
instance->CallUpdateWindow();
|
||||
unused << instance->CallUpdateWindow();
|
||||
} else {
|
||||
// We should never get here since in-process plugins should have
|
||||
// subclassed our HWND and handled WM_PAINT, but in some cases that
|
||||
|
Loading…
Reference in New Issue
Block a user