Search code examples
google-chromepluginscomnpapi

Get IDispatch from NPObject


Is there a way to get IDispatch interface from NPObject in Google Chrome NPAPI browser extension?


Solution

  • AFAIK - no, since the two are unrelated. However you can make use of:

    1. NPP_Invoke
    2. NPP_InvokeDefault
    3. NPP_HasProperty
    4. NPP_HasMethod

    Which are loosely analogous to IDispatch's GetTypeInfo, GetTypeInfoCount and Invoke.