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

Unified Diff: plugins/update/npapi/npfunction_host.h

Issue 624713003: Keep only base/extractor.[cc|h]. (Closed) Base URL: https://chromium.googlesource.com/external/omaha.git@master
Patch Set: Created 6 years, 2 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
« no previous file with comments | « plugins/update/npapi/np_update.cc ('k') | plugins/update/npapi/npfunction_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: plugins/update/npapi/npfunction_host.h
diff --git a/plugins/update/npapi/npfunction_host.h b/plugins/update/npapi/npfunction_host.h
deleted file mode 100644
index 11587d4c2ac54d8c6ae6bf619e56444c43d86473..0000000000000000000000000000000000000000
--- a/plugins/update/npapi/npfunction_host.h
+++ /dev/null
@@ -1,86 +0,0 @@
-// Copyright 2010 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// ========================================================================
-//
-// NpFunctionHost hosts an NPObject inside an IDispatch interface to allow
-// invoking NPAPI functions from a COM environment. Types are automatically
-// marshalled between NPVariant and VARIANT using the functions in
-// variant_utils.h. (For the reverse -- providing an NPObject interface to
-// a COM object implementing IDispatch -- see DispatchHost.)
-//
-// Note that this currently only supports functions; this does not currently
-// support objects. NPN_Enumerate() only provides method/property names,
-// not return types or argument counts/types, which makes it impossible to
-// properly implement IDispatch::GetTypeInfo(). (However, we can implement
-// GetIDsOfNames() if we need it in the future.)
-
-#ifndef OMAHA_PLUGINS_UPDATE_NPAPI_NPFUNCTION_HOST_H_
-#define OMAHA_PLUGINS_UPDATE_NPAPI_NPFUNCTION_HOST_H_
-
-#include <atlbase.h>
-#include <atlcom.h>
-
-#include "base/basictypes.h"
-#include "third_party/npapi/bindings/nphostapi.h"
-
-namespace omaha {
-
-class NpFunctionHostTest;
-
-class ATL_NO_VTABLE NpFunctionHost
- : public CComObjectRootEx<CComObjectThreadModel>,
- public IDispatch {
- public:
- static HRESULT Create(NPP npp, NPObject* npobj, IDispatch** host);
-
- BEGIN_COM_MAP(NpFunctionHost)
- COM_INTERFACE_ENTRY(IDispatch)
- END_COM_MAP()
-
- // IDispatch methods.
- STDMETHOD(GetTypeInfoCount)(UINT* pctinfo);
- STDMETHOD(GetTypeInfo)(UINT iTInfo,
- LCID lcid,
- ITypeInfo** ppTInfo);
- STDMETHOD(GetIDsOfNames)(REFIID riid,
- LPOLESTR* rgszNames,
- UINT cNames,
- LCID lcid,
- DISPID* rgDispId);
- STDMETHOD(Invoke)(DISPID dispIdMember,
- REFIID riid,
- LCID lcid,
- WORD wFlags,
- DISPPARAMS* pDispParams,
- VARIANT* pVarResult,
- EXCEPINFO* pExcepInfo,
- UINT* puArgErr);
-
- // CComObjectRootEx overrides.
- void FinalRelease();
-
- protected:
- NpFunctionHost();
- virtual ~NpFunctionHost() {}
-
- private:
- NPP npp_;
- NPObject* obj_;
-
- DISALLOW_COPY_AND_ASSIGN(NpFunctionHost);
-};
-
-} // namespace omaha
-
-#endif // OMAHA_PLUGINS_UPDATE_NPAPI_NPFUNCTION_HOST_H_
« no previous file with comments | « plugins/update/npapi/np_update.cc ('k') | plugins/update/npapi/npfunction_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698