Jacek Caban : mshtml: Added get_type implementation.

Alexandre Julliard julliard at wine.codeweavers.com
Thu Jul 6 06:09:04 CDT 2006


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

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Wed Jul  5 22:38:04 2006 +0200

mshtml: Added get_type implementation.

---

 dlls/mshtml/selection.c |   14 ++++++++++++--
 1 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/dlls/mshtml/selection.c b/dlls/mshtml/selection.c
index cce8a71..24ef88e 100644
--- a/dlls/mshtml/selection.c
+++ b/dlls/mshtml/selection.c
@@ -160,8 +160,18 @@ static HRESULT WINAPI HTMLSelectionObjec
 static HRESULT WINAPI HTMLSelectionObject_get_type(IHTMLSelectionObject *iface, BSTR *p)
 {
     HTMLSelectionObject *This = HTMLSELOBJ_THIS(iface);
-    FIXME("(%p)->(%p)\n", This, p);
-    return E_NOTIMPL;
+    PRInt32 range_cnt = 0;
+
+    static const WCHAR wszNone[] = {'N','o','n','e',0};
+    static const WCHAR wszText[] = {'T','e','x','t',0};
+
+    TRACE("(%p)->(%p)\n", This, p);
+
+    if(This->nsselection)
+        nsISelection_GetRangeCount(This->nsselection, &range_cnt);
+
+    *p = SysAllocString(range_cnt ? wszText : wszNone); /* FIXME: control */
+    return S_OK;
 }
 
 #undef HTMLSELOBJ_THIS




More information about the wine-cvs mailing list