Hin-Tak Leung : hhctrl.ocx: Look up in chm if url doesn't contain "://".

Alexandre Julliard julliard at winehq.org
Thu Apr 17 07:38:43 CDT 2008


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

Author: Hin-Tak Leung <hintak_leung at yahoo.co.uk>
Date:   Mon Apr 14 20:17:27 2008 +0000

hhctrl.ocx: Look up in chm if url doesn't contain "://".

---

 dlls/hhctrl.ocx/help.c |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/dlls/hhctrl.ocx/help.c b/dlls/hhctrl.ocx/help.c
index 900cfd9..a2081ce 100644
--- a/dlls/hhctrl.ocx/help.c
+++ b/dlls/hhctrl.ocx/help.c
@@ -89,9 +89,15 @@ BOOL NavigateToUrl(HHInfo *info, LPCWSTR surl)
     BOOL ret;
     HRESULT hres;
 
-    hres = navigate_url(info, surl);
-    if(SUCCEEDED(hres))
-        return TRUE;
+    static const WCHAR url_indicator[] = {':', '/', '/'};
+
+    TRACE("%s\n", debugstr_w(surl));
+
+    if (strstrW(surl, url_indicator)) {
+        hres = navigate_url(info, surl);
+        if(SUCCEEDED(hres))
+            return TRUE;
+    } /* look up in chm if it doesn't look like a full url */
 
     SetChmPath(&chm_path, info->pCHMInfo->szFile, surl);
     ret = NavigateToChm(info, chm_path.chm_file, chm_path.chm_index);




More information about the wine-cvs mailing list