if (iid.Equals(NS_GET_IID(nsIServiceManager))) { *ptr = (void*) (nsIServiceManager*)this;
if (iid.Equals(NS_GET_IID(nsIPluginInstancePeer))) { *ptr = (void*) this;
CPluginManager::QueryInterface(const nsIID& iid, void** ptr) {                                                                            if (NULL == ptr) {                                                    return NS_ERROR_NULL_POINTER;                                            }                                                                            if (iid.Equals(NS_GET_IID(nsIServiceManager))) {                                                                  *ptr = (void*) (nsIServiceManager*)this;                                                AddRef();                                                                    return NS_OK;                                                            }    if (iid.Equals(NS_GET_IID(nsIAllocator))) {                                                                  *ptr = (void*) (nsIAllocator*)this;                                                AddRef();                                                                    return NS_OK;                                                            }    if (iid.Equals(NS_GET_IID(nsIPluginManager)) || iid.Equals(NS_GET_IID(nsISupports))) {        *ptr = (void*) ((nsIPluginManager*)this);                                AddRef();                                                                    return NS_OK;                                                            }                                                                          return NS_NOINTERFACE;                                                 }