Jacek Caban : mshtml: Added SchemeIs implementation.

Alexandre Julliard julliard at wine.codeweavers.com
Wed Feb 14 09:25:31 CST 2007


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

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Tue Feb 13 18:08:09 2007 +0100

mshtml: Added SchemeIs implementation.

---

 dlls/mshtml/nsio.c |   12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)

diff --git a/dlls/mshtml/nsio.c b/dlls/mshtml/nsio.c
index d44c529..c21f55a 100644
--- a/dlls/mshtml/nsio.c
+++ b/dlls/mshtml/nsio.c
@@ -1435,10 +1435,20 @@ static nsresult NSAPI nsURI_SchemeIs(nsIWineURI *iface, const char *scheme, PRBo
 
     TRACE("(%p)->(%s %p)\n", This, debugstr_a(scheme), _retval);
 
+    if(This->use_wine_url) {
+        WCHAR buf[INTERNET_MAX_SCHEME_LENGTH];
+        int len = MultiByteToWideChar(CP_ACP, 0, scheme, -1, buf, sizeof(buf)/sizeof(WCHAR))-1;
+
+        *_retval = strlenW(This->wine_url) > len
+            && This->wine_url[len] == ':'
+            && !memcmp(buf, This->wine_url, len*sizeof(WCHAR));
+        return NS_OK;
+    }
+
     if(This->uri)
         return nsIURI_SchemeIs(This->uri, scheme, _retval);
 
-    FIXME("default action not implemented\n");
+    TRACE("returning error\n");
     return NS_ERROR_NOT_IMPLEMENTED;
 }
 




More information about the wine-cvs mailing list