Make it possible to have <object>'s scriptableObject as a v8 object instead of NPObject.

It is well-known that Chromium is gradually deprecating NPAPI
with the goal of removing it completely by the end of 2014.
This is said to include NPObject class as well.

However, currently, for blink::WebPlugin implementators
(for <object> tag), it is only possible to return the corresponding
scriptable object (to back properties of the <object> tag
as visible from JavaScript) as an NPObject*.

This CL introduces the possibility to provide the plain v8 object,
instead. This lets the embedder to provide scripting facilities
for plugins (or whatever else provides <object> tags)
using v8 api or modern means like gin.

On top of it, the compatibility with current NPObject-based
features like nsplugins is kept
which simply can be removed once NPAPI is fully deprecated.


BUG=351636

Review URL: https://codereview.chromium.org/230813002

git-svn-id: svn://svn.chromium.org/blink/trunk@179794 bbb929c8-8fbe-4397-9dbb-9b2b20218538
9 files changed