winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
October 2009
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
3 participants
1207 discussions
Start a n
N
ew thread
Jacek Caban : mshtml: Added IHTMLLocation::put_href implementation.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: 47c27742d046f8a5c3da94613c541a17cbedf257 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=47c27742d046f8a5c3da94613…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sun Oct 11 21:11:35 2009 +0200 mshtml: Added IHTMLLocation::put_href implementation. --- dlls/mshtml/htmllocation.c | 11 +++++++++-- dlls/mshtml/mshtml_private.h | 1 + dlls/mshtml/navigate.c | 25 +++++++++++++++++++++++++ dlls/mshtml/tests/htmldoc.c | 42 ++++++++++++++++++++++++++++++++++++++++-- 4 files changed, 75 insertions(+), 4 deletions(-) diff --git a/dlls/mshtml/htmllocation.c b/dlls/mshtml/htmllocation.c index 45899b4..891e7b8 100644 --- a/dlls/mshtml/htmllocation.c +++ b/dlls/mshtml/htmllocation.c @@ -134,8 +134,15 @@ static HRESULT WINAPI HTMLLocation_Invoke(IHTMLLocation *iface, DISPID dispIdMem static HRESULT WINAPI HTMLLocation_put_href(IHTMLLocation *iface, BSTR v) { HTMLLocation *This = HTMLLOCATION_THIS(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + if(!This->window || !This->window->doc) { + FIXME("No document available\n"); + return E_FAIL; + } + + return navigate_url(This->window->doc, v); } static HRESULT WINAPI HTMLLocation_get_href(IHTMLLocation *iface, BSTR *p) diff --git a/dlls/mshtml/mshtml_private.h b/dlls/mshtml/mshtml_private.h index 4a10fea..44a816e 100644 --- a/dlls/mshtml/mshtml_private.h +++ b/dlls/mshtml/mshtml_private.h @@ -608,6 +608,7 @@ BOOL install_wine_gecko(BOOL); HRESULT nsuri_to_url(LPCWSTR,BOOL,BSTR*); HRESULT hlink_frame_navigate(HTMLDocument*,LPCWSTR,nsIInputStream*,DWORD); +HRESULT navigate_url(HTMLDocumentNode*,OLECHAR*); void call_property_onchanged(ConnectionPoint*,DISPID); HRESULT call_set_active_object(IOleInPlaceUIWindow*,IOleInPlaceActiveObject*); diff --git a/dlls/mshtml/navigate.c b/dlls/mshtml/navigate.c index 7c7376d..92d95fc 100644 --- a/dlls/mshtml/navigate.c +++ b/dlls/mshtml/navigate.c @@ -41,6 +41,8 @@ WINE_DEFAULT_DEBUG_CHANNEL(mshtml); #define CONTENT_LENGTH "Content-Length" #define UTF16_STR "utf-16" +static WCHAR emptyW[] = {0}; + typedef struct { const nsIInputStreamVtbl *lpInputStreamVtbl; @@ -1217,3 +1219,26 @@ HRESULT hlink_frame_navigate(HTMLDocument *doc, LPCWSTR url, IBindStatusCallback_Release(STATUSCLB(callback)); return hres; } + +HRESULT navigate_url(HTMLDocumentNode *doc, OLECHAR *url) +{ + OLECHAR *translated_url = NULL; + HRESULT hres; + + if(!url) + url = emptyW; + + if(doc->basedoc.doc_obj->hostui) { + hres = IDocHostUIHandler_TranslateUrl(doc->basedoc.doc_obj->hostui, 0, url, + &translated_url); + if(hres == S_OK) + url = translated_url; + } + + hres = hlink_frame_navigate(&doc->basedoc, url, NULL, 0); + if(FAILED(hres)) + FIXME("hlink_frame_navigate failed: %08x\n", hres); + + CoTaskMemFree(translated_url); + return hres; +} diff --git a/dlls/mshtml/tests/htmldoc.c b/dlls/mshtml/tests/htmldoc.c index e02951f..79d7786 100644 --- a/dlls/mshtml/tests/htmldoc.c +++ b/dlls/mshtml/tests/htmldoc.c @@ -148,6 +148,7 @@ DEFINE_EXPECT(EnableModeless_FALSE); DEFINE_EXPECT(Frame_EnableModeless_TRUE); DEFINE_EXPECT(Frame_EnableModeless_FALSE); DEFINE_EXPECT(Frame_GetWindow); +DEFINE_EXPECT(TranslateUrl); static IUnknown *doc_unk; static IMoniker *doc_mon; @@ -665,6 +666,7 @@ static HRESULT WINAPI HlinkFrame_Navigate(IHlinkFrame *iface, DWORD grfHLNF, LPB DWORD site_data = 0xdeadbeef; hres = IHlink_GetTargetFrameName(pihlNavigate, &frame_name); + todo_wine ok(hres == S_FALSE, "GetTargetFrameName failed: %08x\n", hres); ok(frame_name == NULL, "frame_name = %p\n", frame_name); @@ -676,6 +678,7 @@ static HRESULT WINAPI HlinkFrame_Navigate(IHlinkFrame *iface, DWORD grfHLNF, LPB hres = IHlink_GetHlinkSite(pihlNavigate, &site, &site_data); ok(hres == S_OK, "GetHlinkSite failed: %08x\n", hres); ok(site == NULL, "site = %p\n, expected NULL\n", site); + todo_wine ok(site_data == 0xdeadbeef, "site_data = %x\n", site_data); } @@ -2107,8 +2110,13 @@ static HRESULT WINAPI DocHostUIHandler_GetExternal(IDocHostUIHandler2 *iface, ID static HRESULT WINAPI DocHostUIHandler_TranslateUrl(IDocHostUIHandler2 *iface, DWORD dwTranslate, OLECHAR *pchURLIn, OLECHAR **ppchURLOut) { - ok(0, "unexpected call\n"); - return E_NOTIMPL; + CHECK_EXPECT(TranslateUrl); + ok(!dwTranslate, "dwTranslate = %x\n", dwTranslate); + ok(!strcmp_wa(pchURLIn, "about:blank"), "pchURLIn = %s\n", wine_dbgstr_w(pchURLIn)); + ok(ppchURLOut != NULL, "ppchURLOut == NULL\n"); + ok(!*ppchURLOut, "*ppchURLOut = %p\n", *ppchURLOut); + + return S_FALSE; } static HRESULT WINAPI DocHostUIHandler_FilterDataObject(IDocHostUIHandler2 *iface, IDataObject *pDO, @@ -2997,6 +3005,34 @@ static void test_Persist(IUnknown *unk, IMoniker *mon) } } +static void test_put_href(IUnknown *unk) +{ + IHTMLLocation *location; + IHTMLDocument2 *doc; + BSTR str; + HRESULT hres; + + hres = IUnknown_QueryInterface(unk, &IID_IHTMLDocument2, (void**)&doc); + ok(hres == S_OK, "Could not get IHTMLDocument2 iface: %08x\n", hres); + + location = NULL; + hres = IHTMLDocument2_get_location(doc, &location); + IHTMLDocument2_Release(doc); + ok(hres == S_OK, "get_location failed: %08x\n", hres); + ok(location != NULL, "location == NULL\n"); + + SET_EXPECT(TranslateUrl); + SET_EXPECT(Navigate); + str = a2bstr("about:blank"); + hres = IHTMLLocation_put_href(location, str); + SysFreeString(str); + ok(hres == S_OK, "put_href failed: %08x\n", hres); + CHECK_CALLED(TranslateUrl); + CHECK_CALLED(Navigate); + + IHTMLLocation_Release(location); +} + static const OLECMDF expect_cmds[OLECMDID_GETPRINTTEMPLATE+1] = { 0, OLECMDF_SUPPORTED, /* OLECMDID_OPEN */ @@ -4118,6 +4154,8 @@ static void test_HTMLDocument_http(void) test_IsDirty(unk, S_FALSE); test_MSHTML_QueryStatus(unk, OLECMDF_SUPPORTED); + test_put_href(unk); + test_InPlaceDeactivate(unk, TRUE); test_Close(unk, FALSE); test_IsDirty(unk, S_FALSE);
1
0
0
0
Jacek Caban : mshtml: Moved QueryService call to hlink_frame_navigate.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: 4aa48041fafaff23751be52edfd0f212ddd18ddb URL:
http://source.winehq.org/git/wine.git/?a=commit;h=4aa48041fafaff23751be52ed…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sun Oct 11 21:11:03 2009 +0200 mshtml: Moved QueryService call to hlink_frame_navigate. --- dlls/mshtml/mshtml_private.h | 2 +- dlls/mshtml/navigate.c | 43 +++++++++++++++++++++++++---------------- dlls/mshtml/nsio.c | 20 +----------------- 3 files changed, 29 insertions(+), 36 deletions(-) diff --git a/dlls/mshtml/mshtml_private.h b/dlls/mshtml/mshtml_private.h index 2f9e1e5..4a10fea 100644 --- a/dlls/mshtml/mshtml_private.h +++ b/dlls/mshtml/mshtml_private.h @@ -607,7 +607,7 @@ BOOL install_wine_gecko(BOOL); HRESULT nsuri_to_url(LPCWSTR,BOOL,BSTR*); -void hlink_frame_navigate(HTMLDocument*,IHlinkFrame*,LPCWSTR,nsIInputStream*,DWORD); +HRESULT hlink_frame_navigate(HTMLDocument*,LPCWSTR,nsIInputStream*,DWORD); void call_property_onchanged(ConnectionPoint*,DISPID); HRESULT call_set_active_object(IOleInPlaceUIWindow*,IOleInPlaceActiveObject*); diff --git a/dlls/mshtml/navigate.c b/dlls/mshtml/navigate.c index 267168f..7c7376d 100644 --- a/dlls/mshtml/navigate.c +++ b/dlls/mshtml/navigate.c @@ -1160,14 +1160,27 @@ void channelbsc_set_channel(nsChannelBSC *This, nsChannel *channel, nsIStreamLis } } -void hlink_frame_navigate(HTMLDocument *doc, IHlinkFrame *hlink_frame, - LPCWSTR uri, nsIInputStream *post_data_stream, DWORD hlnf) +HRESULT hlink_frame_navigate(HTMLDocument *doc, LPCWSTR url, + nsIInputStream *post_data_stream, DWORD hlnf) { + IHlinkFrame *hlink_frame; + IServiceProvider *sp; BSCallback *callback; IBindCtx *bindctx; IMoniker *mon; IHlink *hlink; - HRESULT hr; + HRESULT hres; + + hres = IOleClientSite_QueryInterface(doc->doc_obj->client, &IID_IServiceProvider, + (void**)&sp); + if(FAILED(hres)) + return hres; + + hres = IServiceProvider_QueryService(sp, &IID_IHlinkFrame, &IID_IHlinkFrame, + (void**)&hlink_frame); + IServiceProvider_Release(sp); + if(FAILED(hres)) + return hres; callback = &create_channelbsc(NULL)->bsc; @@ -1178,21 +1191,15 @@ void hlink_frame_navigate(HTMLDocument *doc, IHlinkFrame *hlink_frame, debugstr_an(callback->post_data, callback->post_data_len)); } - hr = CreateAsyncBindCtx(0, STATUSCLB(callback), NULL, &bindctx); - if (FAILED(hr)) { - IBindStatusCallback_Release(STATUSCLB(callback)); - return; - } + hres = CreateAsyncBindCtx(0, STATUSCLB(callback), NULL, &bindctx); + if(SUCCEEDED(hres)) + hres = CoCreateInstance(&CLSID_StdHlink, NULL, CLSCTX_INPROC_SERVER, + &IID_IHlink, (LPVOID*)&hlink); - hr = CoCreateInstance(&CLSID_StdHlink, NULL, CLSCTX_INPROC_SERVER, &IID_IHlink, (LPVOID*)&hlink); - if (FAILED(hr)) { - IBindCtx_Release(bindctx); - IBindStatusCallback_Release(STATUSCLB(callback)); - return; - } + if(SUCCEEDED(hres)) + hres = CreateURLMoniker(NULL, url, &mon); - hr = CreateURLMoniker(NULL, uri, &mon); - if (SUCCEEDED(hr)) { + if(SUCCEEDED(hres)) { IHlink_SetMonikerReference(hlink, 0, mon, NULL); if(hlnf & HLNF_OPENINNEWWINDOW) { @@ -1200,11 +1207,13 @@ void hlink_frame_navigate(HTMLDocument *doc, IHlinkFrame *hlink_frame, IHlink_SetTargetFrameName(hlink, wszBlank); /* FIXME */ } - IHlinkFrame_Navigate(hlink_frame, hlnf, bindctx, STATUSCLB(callback), hlink); + hres = IHlinkFrame_Navigate(hlink_frame, hlnf, bindctx, STATUSCLB(callback), hlink); IMoniker_Release(mon); } + IHlinkFrame_Release(hlink_frame); IBindCtx_Release(bindctx); IBindStatusCallback_Release(STATUSCLB(callback)); + return hres; } diff --git a/dlls/mshtml/nsio.c b/dlls/mshtml/nsio.c index 8ed0108..f10db48 100644 --- a/dlls/mshtml/nsio.c +++ b/dlls/mshtml/nsio.c @@ -128,7 +128,6 @@ static BOOL exec_shldocvw_67(HTMLDocumentObj *doc, LPCWSTR url) static BOOL before_async_open(nsChannel *channel, NSContainer *container) { HTMLDocumentObj *doc = container->doc; - IServiceProvider *service_provider; DWORD hlnf = 0; LPCWSTR uri; HRESULT hres; @@ -154,23 +153,8 @@ static BOOL before_async_open(nsChannel *channel, NSContainer *container) if(!hlnf && !exec_shldocvw_67(doc, uri)) return FALSE; - hres = IOleClientSite_QueryInterface(doc->client, &IID_IServiceProvider, - (void**)&service_provider); - if(SUCCEEDED(hres)) { - IHlinkFrame *hlink_frame; - - hres = IServiceProvider_QueryService(service_provider, &IID_IHlinkFrame, - &IID_IHlinkFrame, (void**)&hlink_frame); - IServiceProvider_Release(service_provider); - if(SUCCEEDED(hres)) { - hlink_frame_navigate(&doc->basedoc, hlink_frame, uri, channel->post_data_stream, hlnf); - IHlinkFrame_Release(hlink_frame); - - return FALSE; - } - } - - return TRUE; + hres = hlink_frame_navigate(&doc->basedoc, uri, channel->post_data_stream, hlnf); + return hres != S_OK; } #define NSCHANNEL_THIS(iface) DEFINE_THIS(nsChannel, HttpChannel, iface)
1
0
0
0
Jacek Caban : mshtml: Improved IHTMLElement2::doScroll stub.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: ae6fed5c4ff376d064655770ddd7ac73a4b171bf URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ae6fed5c4ff376d064655770d…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sun Oct 11 21:10:47 2009 +0200 mshtml: Improved IHTMLElement2::doScroll stub. --- dlls/mshtml/htmlelem2.c | 11 ++++++- dlls/mshtml/mshtml_private.h | 1 + dlls/mshtml/mutation.c | 2 + dlls/mshtml/tests/htmldoc.c | 65 ++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 77 insertions(+), 2 deletions(-) diff --git a/dlls/mshtml/htmlelem2.c b/dlls/mshtml/htmlelem2.c index fd7cb69..d001eaa 100644 --- a/dlls/mshtml/htmlelem2.c +++ b/dlls/mshtml/htmlelem2.c @@ -130,8 +130,15 @@ static HRESULT WINAPI HTMLElement2_componentFromPoint(IHTMLElement2 *iface, static HRESULT WINAPI HTMLElement2_doScroll(IHTMLElement2 *iface, VARIANT component) { HTMLElement *This = HTMLELEM2_THIS(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&component)); + + if(!This->node.doc->content_ready + || !This->node.doc->basedoc.doc_obj->in_place_active) + return E_PENDING; + + WARN("stub\n"); + return S_OK; } static HRESULT WINAPI HTMLElement2_put_onscroll(IHTMLElement2 *iface, VARIANT v) diff --git a/dlls/mshtml/mshtml_private.h b/dlls/mshtml/mshtml_private.h index 18719fe..2f9e1e5 100644 --- a/dlls/mshtml/mshtml_private.h +++ b/dlls/mshtml/mshtml_private.h @@ -472,6 +472,7 @@ struct HTMLDocumentNode { LONG ref; HTMLDOMNode *nodes; + BOOL content_ready; IInternetSecurityManager *secmgr; diff --git a/dlls/mshtml/mutation.c b/dlls/mshtml/mutation.c index dd47522..023c9c4 100644 --- a/dlls/mshtml/mutation.c +++ b/dlls/mshtml/mutation.c @@ -466,6 +466,8 @@ static void NSAPI nsDocumentObserver_EndLoad(nsIDocumentObserver *iface, nsIDocu TRACE("\n"); + This->doc->basedoc.doc_node->content_ready = TRUE; + task = heap_alloc(sizeof(task_t)); task->doc = &This->doc->basedoc; diff --git a/dlls/mshtml/tests/htmldoc.c b/dlls/mshtml/tests/htmldoc.c index 7a4d5ee..e02951f 100644 --- a/dlls/mshtml/tests/htmldoc.c +++ b/dlls/mshtml/tests/htmldoc.c @@ -157,6 +157,7 @@ static BOOL ipsex; static BOOL set_clientsite = FALSE, container_locked = FALSE; static BOOL readystate_set_loading = FALSE, readystate_set_interactive = FALSE, load_from_stream; static BOOL editmode = FALSE, show_failed; +static BOOL inplace_deactivated; static int stream_read, protocol_read; static enum load_state_t { LD_DOLOAD, @@ -211,6 +212,18 @@ static int strcmp_wa(LPCWSTR strw, const char *stra) return lstrcmpA(stra, buf); } +static BSTR a2bstr(const char *str) +{ + BSTR ret; + int len; + + len = MultiByteToWideChar(CP_ACP, 0, str, -1, NULL, 0); + ret = SysAllocStringLen(NULL, len); + MultiByteToWideChar(CP_ACP, 0, str, -1, ret, len); + + return ret; +} + static BOOL is_english(void) { return PRIMARYLANGID(GetSystemDefaultLangID()) == LANG_ENGLISH @@ -1493,6 +1506,7 @@ static HRESULT WINAPI InPlaceSite_CanInPlaceActivate(IOleInPlaceSiteEx *iface) static HRESULT WINAPI InPlaceSite_OnInPlaceActivate(IOleInPlaceSiteEx *iface) { CHECK_EXPECT(OnInPlaceActivate); + inplace_deactivated = FALSE; return S_OK; } @@ -1550,6 +1564,7 @@ static HRESULT WINAPI InPlaceSite_OnUIDeactivate(IOleInPlaceSiteEx *iface, BOOL static HRESULT WINAPI InPlaceSite_OnInPlaceDeactivate(IOleInPlaceSiteEx *iface) { CHECK_EXPECT(OnInPlaceDeactivate); + inplace_deactivated = TRUE; return S_OK; } @@ -2565,6 +2580,53 @@ static LRESULT WINAPI wnd_proc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam return DefWindowProc(hwnd, msg, wParam, lParam); } +static void test_doscroll(IUnknown *unk) +{ + IHTMLDocument3 *doc; + IHTMLElement2 *elem2; + IHTMLElement *elem; + VARIANT v; + HRESULT hres; + + hres = IUnknown_QueryInterface(unk, &IID_IHTMLDocument3, (void**)&doc); + ok(hres == S_OK, "Could not get IHTMLDocument3 iface: %08x\n", hres); + if(FAILED(hres)) + return; + + hres = IHTMLDocument3_get_documentElement(doc, &elem); + IHTMLDocument3_Release(doc); + ok(hres == S_OK, "get_documentElement failed: %08x\n", hres); + switch(load_state) { + case LD_DOLOAD: + case LD_NO: + ok(!elem, "elem != NULL\n"); + default: + break; + case LD_INTERACTIVE: + case LD_COMPLETE: + ok(elem != NULL, "elem == NULL\n"); + } + if(!elem) + return; + + hres = IHTMLElement_QueryInterface(elem, &IID_IHTMLElement2, (void**)&elem2); + IHTMLElement_Release(elem); + ok(hres == S_OK, "Could not get IHTMLElement2 iface: %08x\n", hres); + + V_VT(&v) = VT_BSTR; + V_BSTR(&v) = a2bstr("left"); + hres = IHTMLElement2_doScroll(elem2, v); + SysFreeString(V_BSTR(&v)); + IHTMLElement2_Release(elem2); + + if(inplace_deactivated) + ok(hres == E_PENDING, "doScroll failed: %08x\n", hres); + else if(load_state == LD_COMPLETE) + ok(hres == S_OK, "doScroll failed: %08x\n", hres); + else + ok(hres == E_PENDING || hres == S_OK, "doScroll failed: %08x\n", hres); +} + static void _test_readyState(unsigned line, IUnknown *unk) { IHTMLDocument2 *htmldoc; @@ -2618,6 +2680,8 @@ static void _test_readyState(unsigned line, IUnknown *unk) ok_(__FILE__,line) (V_VT(&out) == VT_I4, "V_VT(out)=%d\n", V_VT(&out)); ok_(__FILE__,line) (V_I4(&out) == load_state%5, "VT_I4(out)=%d, expected %d\n", V_I4(&out), load_state%5); + test_doscroll((IUnknown*)htmldoc); + IHTMLDocument2_Release(htmldoc); } @@ -3868,6 +3932,7 @@ static void init_test(enum load_state_t ls) { stream_read = 0; protocol_read = 0; ipsex = FALSE; + inplace_deactivated = FALSE; } static void test_HTMLDocument(BOOL do_load)
1
0
0
0
Jacek Caban : mshtml: Return NULL documentElement in READYSTATE_UNINITIALIZED state.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: 5763637e9b3dae64f99da51f3541a6f44aa4a837 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5763637e9b3dae64f99da51f3…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sun Oct 11 21:10:07 2009 +0200 mshtml: Return NULL documentElement in READYSTATE_UNINITIALIZED state. --- dlls/mshtml/htmldoc3.c | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/dlls/mshtml/htmldoc3.c b/dlls/mshtml/htmldoc3.c index f4f923f..c5a7a97 100644 --- a/dlls/mshtml/htmldoc3.c +++ b/dlls/mshtml/htmldoc3.c @@ -141,6 +141,11 @@ static HRESULT WINAPI HTMLDocument3_get_documentElement(IHTMLDocument3 *iface, I TRACE("(%p)->(%p)\n", This, p); + if(This->doc_obj->readystate == READYSTATE_UNINITIALIZED) { + *p = NULL; + return S_OK; + } + if(!This->nsdoc) { WARN("NULL nsdoc\n"); return E_UNEXPECTED;
1
0
0
0
Paul Vriens : shell32/tests: Fix test failure on Cyrillic locales.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: 7a0430d0e8bd1e1266e20f655ab03e223b26bb00 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=7a0430d0e8bd1e1266e20f655…
Author: Paul Vriens <Paul.Vriens.Wine(a)gmail.com> Date: Sun Oct 11 10:21:26 2009 +0200 shell32/tests: Fix test failure on Cyrillic locales. --- dlls/shell32/tests/shlfileop.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/shell32/tests/shlfileop.c b/dlls/shell32/tests/shlfileop.c index cbd6025..33d1a94 100644 --- a/dlls/shell32/tests/shlfileop.c +++ b/dlls/shell32/tests/shlfileop.c @@ -48,8 +48,8 @@ "Expected %d, got %d\n", ret, retval) static CHAR CURR_DIR[MAX_PATH]; -static const WCHAR UNICODE_PATH[] = {'c',':','\\',0x00c4,'\0','\0'}; - /* "c:\Ä", or "c:\A" with diaeresis */ +static const WCHAR UNICODE_PATH[] = {'c',':','\\',0x00ae,'\0','\0'}; + /* "c:\®" can be used in all codepages */ /* Double-null termination needed for pFrom field of SHFILEOPSTRUCT */ static HMODULE hshell32;
1
0
0
0
Andrey Turkin : advapi32: Ignore invalid MultipleTrusteeOperation values in SetEntriesInAcl.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: 7de9f842e55bc00f48650e8ba7e262abf3ba701b URL:
http://source.winehq.org/git/wine.git/?a=commit;h=7de9f842e55bc00f48650e8ba…
Author: Andrey Turkin <andrey.turkin(a)gmail.com> Date: Sat Oct 10 17:52:09 2009 +0400 advapi32: Ignore invalid MultipleTrusteeOperation values in SetEntriesInAcl. --- dlls/advapi32/security.c | 2 +- dlls/advapi32/tests/security.c | 14 +++++++++++--- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/dlls/advapi32/security.c b/dlls/advapi32/security.c index bff68a3..24c48c8 100644 --- a/dlls/advapi32/security.c +++ b/dlls/advapi32/security.c @@ -3484,7 +3484,7 @@ DWORD WINAPI SetEntriesInAclW( ULONG count, PEXPLICIT_ACCESSW pEntries, pEntries[i].Trustee.TrusteeForm, pEntries[i].Trustee.TrusteeType, pEntries[i].Trustee.ptstrName); - if (pEntries[i].Trustee.MultipleTrusteeOperation != NO_MULTIPLE_TRUSTEE) + if (pEntries[i].Trustee.MultipleTrusteeOperation == TRUSTEE_IS_IMPERSONATE) { WARN("bad multiple trustee operation %d for trustee %d\n", pEntries[i].Trustee.MultipleTrusteeOperation, i); ret = ERROR_INVALID_PARAMETER; diff --git a/dlls/advapi32/tests/security.c b/dlls/advapi32/tests/security.c index dfcd45b..1a2e39d 100644 --- a/dlls/advapi32/tests/security.c +++ b/dlls/advapi32/tests/security.c @@ -2528,11 +2528,19 @@ static void test_SetEntriesInAcl(void) ExplicitAccess.grfAccessPermissions = KEY_WRITE; ExplicitAccess.grfAccessMode = GRANT_ACCESS; ExplicitAccess.grfInheritance = NO_INHERITANCE; - ExplicitAccess.Trustee.pMultipleTrustee = NULL; - ExplicitAccess.Trustee.MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE; + ExplicitAccess.Trustee.TrusteeType = TRUSTEE_IS_WELL_KNOWN_GROUP; ExplicitAccess.Trustee.TrusteeForm = TRUSTEE_IS_SID; - ExplicitAccess.Trustee.TrusteeType = TRUSTEE_IS_UNKNOWN; ExplicitAccess.Trustee.ptstrName = EveryoneSid; + ExplicitAccess.Trustee.MultipleTrusteeOperation = 0xDEADBEEF; + ExplicitAccess.Trustee.pMultipleTrustee = (PVOID)0xDEADBEEF; + res = pSetEntriesInAclW(1, &ExplicitAccess, OldAcl, &NewAcl); + ok(res == ERROR_SUCCESS, "SetEntriesInAclW failed: %u\n", res); + ok(NewAcl != NULL, "returned acl was NULL\n"); + LocalFree(NewAcl); + + ExplicitAccess.Trustee.TrusteeType = TRUSTEE_IS_UNKNOWN; + ExplicitAccess.Trustee.pMultipleTrustee = NULL; + ExplicitAccess.Trustee.MultipleTrusteeOperation = NO_MULTIPLE_TRUSTEE; res = pSetEntriesInAclW(1, &ExplicitAccess, OldAcl, &NewAcl); ok(res == ERROR_SUCCESS, "SetEntriesInAclW failed: %u\n", res); ok(NewAcl != NULL, "returned acl was NULL\n");
1
0
0
0
Andrey Turkin : ntdll: Run TLS callbacks in zero-sized TLS directories.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: 7aeaa0338c6e1e313463da8dbad7fc2e9b32304c URL:
http://source.winehq.org/git/wine.git/?a=commit;h=7aeaa0338c6e1e313463da8db…
Author: Andrey Turkin <andrey.turkin(a)gmail.com> Date: Sat Oct 10 15:09:02 2009 +0400 ntdll: Run TLS callbacks in zero-sized TLS directories. --- dlls/ntdll/loader.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c index 71d7ecd..42c4225 100644 --- a/dlls/ntdll/loader.c +++ b/dlls/ntdll/loader.c @@ -845,7 +845,7 @@ static NTSTATUS alloc_process_tls(void) IMAGE_DIRECTORY_ENTRY_TLS, &size ))) continue; size = (dir->EndAddressOfRawData - dir->StartAddressOfRawData) + dir->SizeOfZeroFill; - if (!size) continue; + if (!size && !dir->AddressOfCallBacks) continue; tls_total_size += size; tls_module_count++; }
1
0
0
0
Michael Stefaniuc : windowscodecs: Remove redundant NULL check before HeapFree (Smatch).
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: 13ad5d17250e5e5822ab3a99122f9bef4c8ae08a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=13ad5d17250e5e5822ab3a991…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Sat Oct 10 01:05:10 2009 +0200 windowscodecs: Remove redundant NULL check before HeapFree (Smatch). --- dlls/windowscodecs/pngformat.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/dlls/windowscodecs/pngformat.c b/dlls/windowscodecs/pngformat.c index 6aaca6b..3334d76 100644 --- a/dlls/windowscodecs/pngformat.c +++ b/dlls/windowscodecs/pngformat.c @@ -860,7 +860,7 @@ static HRESULT WINAPI PngFrameEncode_WritePixels(IWICBitmapFrameEncode *iface, /* set up setjmp/longjmp error handling */ if (setjmp(png_jmpbuf(This->png_ptr))) { - if (row_pointers) HeapFree(GetProcessHeap(), 0, row_pointers); + HeapFree(GetProcessHeap(), 0, row_pointers); return E_FAIL; }
1
0
0
0
Paul Vriens : ddraw/tests: Don't crash on older ddraw.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: 72fab20ffe0d7f713a78c4cbee8d6ef87ca16c93 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=72fab20ffe0d7f713a78c4cbe…
Author: Paul Vriens <Paul.Vriens.Wine(a)gmail.com> Date: Sat Oct 10 10:06:32 2009 +0200 ddraw/tests: Don't crash on older ddraw. --- dlls/ddraw/tests/ddrawmodes.c | 15 +++++++++++---- 1 files changed, 11 insertions(+), 4 deletions(-) diff --git a/dlls/ddraw/tests/ddrawmodes.c b/dlls/ddraw/tests/ddrawmodes.c index 7ea4d53..bd8bec7 100644 --- a/dlls/ddraw/tests/ddrawmodes.c +++ b/dlls/ddraw/tests/ddrawmodes.c @@ -149,9 +149,14 @@ static void test_DirectDrawEnumerateA(void) ret = pDirectDrawEnumerateA((LPDDENUMCALLBACKA)0xdeadbeef, NULL); ok(ret == DDERR_INVALIDPARAMS, "Expected DDERR_INVALIDPARAMS, got %d\n", ret); - /* Test with callback that crashes. */ - ret = pDirectDrawEnumerateA(crash_callbackA, NULL); - ok(ret == DDERR_INVALIDPARAMS, "Expected DDERR_INVALIDPARAMS, got %d\n", ret); + if (pDirectDrawEnumerateExA) + { + /* Test with callback that crashes. */ + ret = pDirectDrawEnumerateA(crash_callbackA, NULL); + ok(ret == DDERR_INVALIDPARAMS, "Expected DDERR_INVALIDPARAMS, got %d\n", ret); + } + else + win_skip("Test would crash on older ddraw\n"); /* Test with valid callback parameter and NULL context parameter. */ trace("Calling DirectDrawEnumerateA with test_nullcontext_callbackA callback and NULL context.\n"); @@ -185,7 +190,9 @@ static void test_DirectDrawEnumerateW(void) /* Test with NULL callback parameter. */ ret = pDirectDrawEnumerateW(NULL, NULL); - ok(ret == DDERR_INVALIDPARAMS, "Expected DDERR_INVALIDPARAMS, got %d\n", ret); + ok(ret == DDERR_INVALIDPARAMS || + ret == DDERR_UNSUPPORTED, /* Older ddraw */ + "Expected DDERR_INVALIDPARAMS or DDERR_UNSUPPORTED, got %d\n", ret); /* Test with invalid callback parameter. */ ret = pDirectDrawEnumerateW((LPDDENUMCALLBACKW)0xdeadbeef, NULL);
1
0
0
0
Paul Vriens : comctl32/tests: Fix some test failures on older comctl32 versions.
by Alexandre Julliard
12 Oct '09
12 Oct '09
Module: wine Branch: master Commit: bfe67814f9486d45816d8b06bca94880164d9c7c URL:
http://source.winehq.org/git/wine.git/?a=commit;h=bfe67814f9486d45816d8b06b…
Author: Paul Vriens <Paul.Vriens.Wine(a)gmail.com> Date: Fri Oct 9 21:44:58 2009 +0200 comctl32/tests: Fix some test failures on older comctl32 versions. --- dlls/comctl32/tests/datetime.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/dlls/comctl32/tests/datetime.c b/dlls/comctl32/tests/datetime.c index 7cd08a0..1de433c 100644 --- a/dlls/comctl32/tests/datetime.c +++ b/dlls/comctl32/tests/datetime.c @@ -678,7 +678,9 @@ static void test_wm_set_get_text(void) hWnd = create_datetime_control(0); ret = SendMessage(hWnd, WM_SETTEXT, 0, (LPARAM)a_str); - expect(CB_ERR, ret); + ok(CB_ERR == ret || + broken(1 == ret), /* comctl32 <= 4.72 */ + "Expected CB_ERR, got %ld\n", ret); buff[0] = 0; ret = SendMessage(hWnd, WM_GETTEXT, sizeof(buff), (LPARAM)buff);
1
0
0
0
← Newer
1
...
78
79
80
81
82
83
84
...
121
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
Results per page:
10
25
50
100
200