dom/plugins/ipc/COMMessageFilter.h

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/dom/plugins/ipc/COMMessageFilter.h	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,50 @@
     1.4 +/* This Source Code Form is subject to the terms of the Mozilla Public
     1.5 + * License, v. 2.0. If a copy of the MPL was not distributed with this
     1.6 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     1.7 +
     1.8 +#ifndef mozilla_plugins_COMMessageFilter_h
     1.9 +#define mozilla_plugins_COMMessageFilter_h
    1.10 +
    1.11 +#include <objidl.h>
    1.12 +#include "nsISupportsImpl.h"
    1.13 +#include "nsAutoPtr.h"
    1.14 +
    1.15 +namespace mozilla {
    1.16 +namespace plugins {
    1.17 +
    1.18 +class PluginModuleChild;
    1.19 +
    1.20 +class COMMessageFilter MOZ_FINAL : public IMessageFilter
    1.21 +{
    1.22 +public:
    1.23 +  static void Initialize(PluginModuleChild* plugin);
    1.24 +
    1.25 +  COMMessageFilter(PluginModuleChild* plugin)
    1.26 +    : mPlugin(plugin)
    1.27 +  { }
    1.28 +
    1.29 +  HRESULT WINAPI QueryInterface(REFIID riid, void** ppv);
    1.30 +  DWORD WINAPI AddRef();
    1.31 +  DWORD WINAPI Release();
    1.32 +
    1.33 +  DWORD WINAPI HandleInComingCall(DWORD dwCallType,
    1.34 +                                  HTASK htaskCaller,
    1.35 +                                  DWORD dwTickCount,
    1.36 +                                  LPINTERFACEINFO lpInterfaceInfo);
    1.37 +  DWORD WINAPI RetryRejectedCall(HTASK htaskCallee,
    1.38 +                                 DWORD dwTickCount,
    1.39 +                                 DWORD dwRejectType);
    1.40 +  DWORD WINAPI MessagePending(HTASK htaskCallee,
    1.41 +                              DWORD dwTickCount,
    1.42 +                              DWORD dwPendingType);
    1.43 +
    1.44 +private:
    1.45 +  nsAutoRefCnt mRefCnt;
    1.46 +  PluginModuleChild* mPlugin;
    1.47 +  nsRefPtr<IMessageFilter> mPreviousFilter;
    1.48 +};
    1.49 +
    1.50 +} // namespace plugins
    1.51 +} // namespace mozilla
    1.52 +
    1.53 +#endif // COMMessageFilter_h

mercurial