Jacek Caban : mshtml: Added nsIChannel::[Get|Set]Owner implementation.

Alexandre Julliard julliard at winehq.org
Thu Dec 18 08:08:58 CST 2008


Module: wine
Branch: master
Commit: bbd4a63491bae50eecb4f735fe67584d41b9fced
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=bbd4a63491bae50eecb4f735fe67584d41b9fced

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Thu Dec 18 14:08:31 2008 +0100

mshtml: Added nsIChannel::[Get|Set]Owner implementation.

---

 dlls/mshtml/mshtml_private.h |    1 +
 dlls/mshtml/nsio.c           |   16 ++++++++++++----
 2 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/dlls/mshtml/mshtml_private.h b/dlls/mshtml/mshtml_private.h
index 0d02f26..6cb41bd 100644
--- a/dlls/mshtml/mshtml_private.h
+++ b/dlls/mshtml/mshtml_private.h
@@ -348,6 +348,7 @@ typedef struct {
     nsIInputStream *post_data_stream;
     nsILoadGroup *load_group;
     nsIInterfaceRequestor *notif_callback;
+    nsISupports *owner;
     nsLoadFlags load_flags;
     nsIURI *original_uri;
     char *content_type;
diff --git a/dlls/mshtml/nsio.c b/dlls/mshtml/nsio.c
index 0669463..1dca2a4 100644
--- a/dlls/mshtml/nsio.c
+++ b/dlls/mshtml/nsio.c
@@ -417,8 +417,11 @@ static nsresult NSAPI nsChannel_GetOwner(nsIHttpChannel *iface, nsISupports **aO
     if(This->channel)
         return nsIChannel_GetOwner(This->channel, aOwner);
 
-    FIXME("default action not implemented\n");
-    return NS_ERROR_NOT_IMPLEMENTED;
+    if(This->owner)
+        nsISupports_AddRef(This->owner);
+    *aOwner = This->owner;
+
+    return NS_OK;
 }
 
 static nsresult NSAPI nsChannel_SetOwner(nsIHttpChannel *iface, nsISupports *aOwner)
@@ -430,8 +433,13 @@ static nsresult NSAPI nsChannel_SetOwner(nsIHttpChannel *iface, nsISupports *aOw
     if(This->channel)
         return nsIChannel_SetOwner(This->channel, aOwner);
 
-    FIXME("default action not implemented\n");
-    return NS_ERROR_NOT_IMPLEMENTED;
+    if(aOwner)
+        nsISupports_AddRef(aOwner);
+    if(This->owner)
+        nsISupports_Release(This->owner);
+    This->owner = aOwner;
+
+    return NS_OK;
 }
 
 static nsresult NSAPI nsChannel_GetNotificationCallbacks(nsIHttpChannel *iface,




More information about the wine-cvs mailing list