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
December 2019
----- 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
1 participants
635 discussions
Start a n
N
ew thread
Alistair Leslie-Hughes : msado15: Add _Command stub interface.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: 2839e7b5e7c2df7fccba4fb65aa0f7bd8a2d82dd URL:
https://source.winehq.org/git/wine.git/?a=commit;h=2839e7b5e7c2df7fccba4fb6…
Author: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Date: Thu Dec 12 16:42:06 2019 +0100 msado15: Add _Command stub interface. Signed-off-by: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/msado15/Makefile.in | 1 + dlls/msado15/command.c | 313 +++++++++++++++++++++++++++++++++++++++ dlls/msado15/main.c | 5 + dlls/msado15/msado15_classes.idl | 8 + dlls/msado15/msado15_private.h | 1 + dlls/msado15/tests/msado15.c | 27 ++++ 6 files changed, 355 insertions(+) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=2839e7b5e7c2df7fccba…
1
0
0
0
Andrey Gusev : ieframe/tests: Fix a typo in ok() message.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: 375c91e31dda8fd4750eb2fa92b113dffeaf5386 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=375c91e31dda8fd4750eb2fa…
Author: Andrey Gusev <andrey.goosev(a)gmail.com> Date: Thu Dec 12 18:10:11 2019 +0200 ieframe/tests: Fix a typo in ok() message. Signed-off-by: Andrey Gusev <andrey.goosev(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ieframe/tests/webbrowser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/ieframe/tests/webbrowser.c b/dlls/ieframe/tests/webbrowser.c index 9ec54a7077..0195851bda 100644 --- a/dlls/ieframe/tests/webbrowser.c +++ b/dlls/ieframe/tests/webbrowser.c @@ -2665,7 +2665,7 @@ static void test_Extent(IWebBrowser2 *unk) trace("dpi: %d / %d\n", dpi_y, dpi_y); hres = IWebBrowser2_QueryInterface(unk, &IID_IOleObject, (void**)&oleobj); - ok(hres == S_OK, "Could not get IOleObkect: %08x\n", hres); + ok(hres == S_OK, "Could not get IOleObject: %08x\n", hres); if(FAILED(hres)) return;
1
0
0
0
Alistair Leslie-Hughes : msado15: Add ISupportErrorInfo support to _Connection.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: 23b50cac89b2826244f26b7c5a608b628a1a1c1d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=23b50cac89b2826244f26b7c…
Author: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Date: Thu Dec 12 16:42:05 2019 +0100 msado15: Add ISupportErrorInfo support to _Connection. Signed-off-by: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/msado15/connection.c | 56 +++++++++++++++++++++++++++++++++++++++----- dlls/msado15/tests/msado15.c | 5 ++-- 2 files changed, 52 insertions(+), 9 deletions(-) diff --git a/dlls/msado15/connection.c b/dlls/msado15/connection.c index 037ab52199..73b225628c 100644 --- a/dlls/msado15/connection.c +++ b/dlls/msado15/connection.c @@ -32,11 +32,11 @@ WINE_DEFAULT_DEBUG_CHANNEL(msado15); struct connection { - _Connection Connection_iface; - LONG refs; - - ObjectStateEnum state; - LONG timeout; + _Connection Connection_iface; + ISupportErrorInfo ISupportErrorInfo_iface; + LONG refs; + ObjectStateEnum state; + LONG timeout; }; static inline struct connection *impl_from_Connection( _Connection *iface ) @@ -44,6 +44,11 @@ static inline struct connection *impl_from_Connection( _Connection *iface ) return CONTAINING_RECORD( iface, struct connection, Connection_iface ); } +static inline struct connection *impl_from_ISupportErrorInfo( ISupportErrorInfo *iface ) +{ + return CONTAINING_RECORD( iface, struct connection, ISupportErrorInfo_iface ); +} + static ULONG WINAPI connection_AddRef( _Connection *iface ) { struct connection *connection = impl_from_Connection( iface ); @@ -64,13 +69,18 @@ static ULONG WINAPI connection_Release( _Connection *iface ) static HRESULT WINAPI connection_QueryInterface( _Connection *iface, REFIID riid, void **obj ) { - TRACE( "%p, %s, %p\n", iface, debugstr_guid(riid), obj ); + struct connection *connection = impl_from_Connection( iface ); + TRACE( "%p, %s, %p\n", connection, debugstr_guid(riid), obj ); if (IsEqualGUID( riid, &IID__Connection ) || IsEqualGUID( riid, &IID_IDispatch ) || IsEqualGUID( riid, &IID_IUnknown )) { *obj = iface; } + else if(IsEqualGUID( riid, &IID_ISupportErrorInfo )) + { + *obj = &connection->ISupportErrorInfo_iface; + } else { FIXME( "interface %s not implemented\n", debugstr_guid(riid) ); @@ -339,12 +349,46 @@ static const struct _ConnectionVtbl connection_vtbl = connection_Cancel }; +static HRESULT WINAPI supporterror_QueryInterface( ISupportErrorInfo *iface, REFIID riid, void **obj ) +{ + struct connection *connection = impl_from_ISupportErrorInfo( iface ); + return connection_QueryInterface( &connection->Connection_iface, riid, obj ); +} + +static ULONG WINAPI supporterror_AddRef( ISupportErrorInfo *iface ) +{ + struct connection *connection = impl_from_ISupportErrorInfo( iface ); + return connection_AddRef( &connection->Connection_iface ); +} + +static ULONG WINAPI supporterror_Release( ISupportErrorInfo *iface ) +{ + struct connection *connection = impl_from_ISupportErrorInfo( iface ); + return connection_Release( &connection->Connection_iface ); +} + +static HRESULT WINAPI supporterror_InterfaceSupportsErrorInfo( ISupportErrorInfo *iface, REFIID riid ) +{ + struct connection *connection = impl_from_ISupportErrorInfo( iface ); + FIXME( "%p, %s\n", connection, debugstr_guid(riid) ); + return S_FALSE; +} + +static const struct ISupportErrorInfoVtbl support_error_vtbl = +{ + supporterror_QueryInterface, + supporterror_AddRef, + supporterror_Release, + supporterror_InterfaceSupportsErrorInfo +}; + HRESULT Connection_create( void **obj ) { struct connection *connection; if (!(connection = heap_alloc( sizeof(*connection) ))) return E_OUTOFMEMORY; connection->Connection_iface.lpVtbl = &connection_vtbl; + connection->ISupportErrorInfo_iface.lpVtbl = &support_error_vtbl; connection->refs = 1; connection->state = adStateClosed; connection->timeout = 30; diff --git a/dlls/msado15/tests/msado15.c b/dlls/msado15/tests/msado15.c index 4ef4762ac6..5a1813694b 100644 --- a/dlls/msado15/tests/msado15.c +++ b/dlls/msado15/tests/msado15.c @@ -414,9 +414,8 @@ static void test_Connection(void) ok(hr == E_NOINTERFACE, "Unexpected IRunnableObject interface\n"); hr = _Connection_QueryInterface(connection, &IID_ISupportErrorInfo, (void**)&errorinfo); - todo_wine ok(hr == S_OK, "Failed to get ISupportErrorInfo interface\n"); - if (hr == S_OK) - ISupportErrorInfo_Release(errorinfo); + ok(hr == S_OK, "Failed to get ISupportErrorInfo interface\n"); + ISupportErrorInfo_Release(errorinfo); if (0) /* Crashes on windows */ {
1
0
0
0
Gabriel Ivăncescu : jscript/tests: Add initial tests for the script TypeInfo.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: cf7a432df5194546d5a9b5e9840c2e6b3c0635fd URL:
https://source.winehq.org/git/wine.git/?a=commit;h=cf7a432df5194546d5a9b5e9…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Thu Dec 12 14:54:03 2019 +0200 jscript/tests: Add initial tests for the script TypeInfo. Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/jscript/tests/jscript.c | 362 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 362 insertions(+) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=cf7a432df5194546d5a9…
1
0
0
0
Gabriel Ivăncescu : jscript: Implement ScriptTypeComp_BindType.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: 2e3ebd64e78c83c443fe7f54651c5ae684a96690 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=2e3ebd64e78c83c443fe7f54…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Thu Dec 12 14:54:02 2019 +0200 jscript: Implement ScriptTypeComp_BindType. Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/jscript/dispex.c | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index 657660567d..6cc6df58e1 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -1069,10 +1069,25 @@ static HRESULT WINAPI ScriptTypeComp_BindType(ITypeComp *iface, LPOLESTR szName, ITypeInfo **ppTInfo, ITypeComp **ppTComp) { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeComp(iface); + ITypeInfo *disp_typeinfo; + ITypeComp *disp_typecomp; + HRESULT hr; - FIXME("(%p)->(%s %08x %p %p)\n", This, debugstr_w(szName), lHashVal, ppTInfo, ppTComp); + TRACE("(%p)->(%s %08x %p %p)\n", This, debugstr_w(szName), lHashVal, ppTInfo, ppTComp); - return E_NOTIMPL; + if (!szName || !ppTInfo || !ppTComp) + return E_INVALIDARG; + + /* Look into the inherited IDispatch */ + hr = get_dispatch_typeinfo(&disp_typeinfo); + if (FAILED(hr)) return hr; + + hr = ITypeInfo_GetTypeComp(disp_typeinfo, &disp_typecomp); + if (FAILED(hr)) return hr; + + hr = ITypeComp_BindType(disp_typecomp, szName, lHashVal, ppTInfo, ppTComp); + ITypeComp_Release(disp_typecomp); + return hr; } static const ITypeCompVtbl ScriptTypeCompVtbl = {
1
0
0
0
Gabriel Ivăncescu : jscript: Implement ScriptTypeComp_Bind.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: 245dabd8138cf7f47f7abf10a49e3b4b0fba3715 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=245dabd8138cf7f47f7abf10…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Thu Dec 12 14:54:01 2019 +0200 jscript: Implement ScriptTypeComp_Bind. Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/jscript/dispex.c | 49 +++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 47 insertions(+), 2 deletions(-) diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index fb636b4577..657660567d 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -1013,11 +1013,56 @@ static HRESULT WINAPI ScriptTypeComp_Bind(ITypeComp *iface, LPOLESTR szName, ULO ITypeInfo **ppTInfo, DESCKIND *pDescKind, BINDPTR *pBindPtr) { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeComp(iface); + UINT flags = wFlags ? wFlags : ~0; + ITypeInfo *disp_typeinfo; + ITypeComp *disp_typecomp; + HRESULT hr; + UINT i; - FIXME("(%p)->(%s %08x %d %p %p %p)\n", This, debugstr_w(szName), lHashVal, + TRACE("(%p)->(%s %08x %d %p %p %p)\n", This, debugstr_w(szName), lHashVal, wFlags, ppTInfo, pDescKind, pBindPtr); - return E_NOTIMPL; + if (!szName || !ppTInfo || !pDescKind || !pBindPtr) + return E_INVALIDARG; + + for (i = 0; i < This->num_funcs; i++) + { + if (wcsicmp(szName, This->funcs[i].prop->name)) continue; + if (!(flags & INVOKE_FUNC)) return TYPE_E_TYPEMISMATCH; + + hr = ITypeInfo_GetFuncDesc(&This->ITypeInfo_iface, i, &pBindPtr->lpfuncdesc); + if (FAILED(hr)) return hr; + + *pDescKind = DESCKIND_FUNCDESC; + *ppTInfo = &This->ITypeInfo_iface; + ITypeInfo_AddRef(*ppTInfo); + return S_OK; + } + + for (i = 0; i < This->num_vars; i++) + { + if (wcsicmp(szName, This->vars[i]->name)) continue; + if (!(flags & INVOKE_PROPERTYGET)) return TYPE_E_TYPEMISMATCH; + + hr = ITypeInfo_GetVarDesc(&This->ITypeInfo_iface, i, &pBindPtr->lpvardesc); + if (FAILED(hr)) return hr; + + *pDescKind = DESCKIND_VARDESC; + *ppTInfo = &This->ITypeInfo_iface; + ITypeInfo_AddRef(*ppTInfo); + return S_OK; + } + + /* Look into the inherited IDispatch */ + hr = get_dispatch_typeinfo(&disp_typeinfo); + if (FAILED(hr)) return hr; + + hr = ITypeInfo_GetTypeComp(disp_typeinfo, &disp_typecomp); + if (FAILED(hr)) return hr; + + hr = ITypeComp_Bind(disp_typecomp, szName, lHashVal, wFlags, ppTInfo, pDescKind, pBindPtr); + ITypeComp_Release(disp_typecomp); + return hr; } static HRESULT WINAPI ScriptTypeComp_BindType(ITypeComp *iface, LPOLESTR szName, ULONG lHashVal,
1
0
0
0
Gabriel Ivăncescu : jscript: Implement ScriptTypeInfo_GetTypeComp.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: 6872cf1cfc3d87b26029e42f3da63559f33b9c95 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6872cf1cfc3d87b26029e42f…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Thu Dec 12 14:54:00 2019 +0200 jscript: Implement ScriptTypeInfo_GetTypeComp. Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/jscript/dispex.c | 64 +++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 62 insertions(+), 2 deletions(-) diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index 1ac747b491..fb636b4577 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -614,6 +614,7 @@ struct typeinfo_func { typedef struct { ITypeInfo ITypeInfo_iface; + ITypeComp ITypeComp_iface; LONG ref; UINT num_funcs; @@ -629,12 +630,19 @@ static inline ScriptTypeInfo *ScriptTypeInfo_from_ITypeInfo(ITypeInfo *iface) return CONTAINING_RECORD(iface, ScriptTypeInfo, ITypeInfo_iface); } +static inline ScriptTypeInfo *ScriptTypeInfo_from_ITypeComp(ITypeComp *iface) +{ + return CONTAINING_RECORD(iface, ScriptTypeInfo, ITypeComp_iface); +} + static HRESULT WINAPI ScriptTypeInfo_QueryInterface(ITypeInfo *iface, REFIID riid, void **ppv) { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeInfo(iface); if (IsEqualGUID(&IID_IUnknown, riid) || IsEqualGUID(&IID_ITypeInfo, riid)) *ppv = &This->ITypeInfo_iface; + else if (IsEqualGUID(&IID_ITypeComp, riid)) + *ppv = &This->ITypeComp_iface; else { WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); @@ -712,9 +720,13 @@ static HRESULT WINAPI ScriptTypeInfo_GetTypeComp(ITypeInfo *iface, ITypeComp **p { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeInfo(iface); - FIXME("(%p)->(%p)\n", This, ppTComp); + TRACE("(%p)->(%p)\n", This, ppTComp); - return E_NOTIMPL; + if (!ppTComp) return E_INVALIDARG; + + *ppTComp = &This->ITypeComp_iface; + ITypeInfo_AddRef(iface); + return S_OK; } static HRESULT WINAPI ScriptTypeInfo_GetFuncDesc(ITypeInfo *iface, UINT index, FUNCDESC **ppFuncDesc) @@ -979,6 +991,53 @@ static const ITypeInfoVtbl ScriptTypeInfoVtbl = { ScriptTypeInfo_ReleaseVarDesc }; +static HRESULT WINAPI ScriptTypeComp_QueryInterface(ITypeComp *iface, REFIID riid, void **ppv) +{ + ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeComp(iface); + return ITypeInfo_QueryInterface(&This->ITypeInfo_iface, riid, ppv); +} + +static ULONG WINAPI ScriptTypeComp_AddRef(ITypeComp *iface) +{ + ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeComp(iface); + return ITypeInfo_AddRef(&This->ITypeInfo_iface); +} + +static ULONG WINAPI ScriptTypeComp_Release(ITypeComp *iface) +{ + ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeComp(iface); + return ITypeInfo_Release(&This->ITypeInfo_iface); +} + +static HRESULT WINAPI ScriptTypeComp_Bind(ITypeComp *iface, LPOLESTR szName, ULONG lHashVal, WORD wFlags, + ITypeInfo **ppTInfo, DESCKIND *pDescKind, BINDPTR *pBindPtr) +{ + ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeComp(iface); + + FIXME("(%p)->(%s %08x %d %p %p %p)\n", This, debugstr_w(szName), lHashVal, + wFlags, ppTInfo, pDescKind, pBindPtr); + + return E_NOTIMPL; +} + +static HRESULT WINAPI ScriptTypeComp_BindType(ITypeComp *iface, LPOLESTR szName, ULONG lHashVal, + ITypeInfo **ppTInfo, ITypeComp **ppTComp) +{ + ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeComp(iface); + + FIXME("(%p)->(%s %08x %p %p)\n", This, debugstr_w(szName), lHashVal, ppTInfo, ppTComp); + + return E_NOTIMPL; +} + +static const ITypeCompVtbl ScriptTypeCompVtbl = { + ScriptTypeComp_QueryInterface, + ScriptTypeComp_AddRef, + ScriptTypeComp_Release, + ScriptTypeComp_Bind, + ScriptTypeComp_BindType +}; + static inline jsdisp_t *impl_from_IDispatchEx(IDispatchEx *iface) { return CONTAINING_RECORD(iface, jsdisp_t, IDispatchEx_iface); @@ -1081,6 +1140,7 @@ static HRESULT WINAPI DispatchEx_GetTypeInfo(IDispatchEx *iface, UINT iTInfo, LC return E_OUTOFMEMORY; typeinfo->ITypeInfo_iface.lpVtbl = &ScriptTypeInfoVtbl; + typeinfo->ITypeComp_iface.lpVtbl = &ScriptTypeCompVtbl; typeinfo->ref = 1; typeinfo->num_vars = num_vars; typeinfo->num_funcs = num_funcs;
1
0
0
0
Gabriel Ivăncescu : jscript: Implement ScriptTypeInfo_GetIDsOfNames.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: a6ac60dcc30815bb73571ea504519a32d3a3e3da URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a6ac60dcc30815bb73571ea5…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Thu Dec 12 14:53:59 2019 +0200 jscript: Implement ScriptTypeInfo_GetIDsOfNames. Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/jscript/dispex.c | 47 +++++++++++++++++++++++++++++++++++++++++++-- dlls/jscript/jscript.h | 1 + dlls/jscript/jscript_main.c | 25 ++++++++++++++++++++++++ 3 files changed, 71 insertions(+), 2 deletions(-) diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index df87aedcac..1ac747b491 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -802,10 +802,53 @@ static HRESULT WINAPI ScriptTypeInfo_GetIDsOfNames(ITypeInfo *iface, LPOLESTR *r MEMBERID *pMemId) { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeInfo(iface); + ITypeInfo *disp_typeinfo; + const WCHAR *name; + HRESULT hr = S_OK; + int i, j, arg; - FIXME("(%p)->(%p %u %p)\n", This, rgszNames, cNames, pMemId); + TRACE("(%p)->(%p %u %p)\n", This, rgszNames, cNames, pMemId); - return E_NOTIMPL; + if (!rgszNames || !cNames || !pMemId) return E_INVALIDARG; + + for (i = 0; i < cNames; i++) pMemId[i] = MEMBERID_NIL; + name = rgszNames[0]; + + for (i = 0; i < This->num_funcs; i++) + { + struct typeinfo_func *func = &This->funcs[i]; + + if (wcsicmp(name, func->prop->name)) continue; + pMemId[0] = prop_to_id(This->jsdisp, func->prop); + + for (j = 1; j < cNames; j++) + { + name = rgszNames[j]; + for (arg = func->code->param_cnt; --arg >= 0;) + if (!wcsicmp(name, func->code->params[arg])) + break; + if (arg >= 0) + pMemId[j] = arg; + else + hr = DISP_E_UNKNOWNNAME; + } + return hr; + } + + for (i = 0; i < This->num_vars; i++) + { + dispex_prop_t *var = This->vars[i]; + + if (wcsicmp(name, var->name)) continue; + pMemId[0] = prop_to_id(This->jsdisp, var); + return S_OK; + } + + /* Look into the inherited IDispatch */ + hr = get_dispatch_typeinfo(&disp_typeinfo); + if (FAILED(hr)) return hr; + + return ITypeInfo_GetIDsOfNames(disp_typeinfo, rgszNames, cNames, pMemId); } static HRESULT WINAPI ScriptTypeInfo_Invoke(ITypeInfo *iface, PVOID pvInstance, MEMBERID memid, WORD wFlags, diff --git a/dlls/jscript/jscript.h b/dlls/jscript/jscript.h index 7174db8e0c..4ec5004df0 100644 --- a/dlls/jscript/jscript.h +++ b/dlls/jscript/jscript.h @@ -87,6 +87,7 @@ static inline LPWSTR heap_strdupW(LPCWSTR str) typedef struct jsdisp_t jsdisp_t; extern HINSTANCE jscript_hinstance DECLSPEC_HIDDEN; +HRESULT get_dispatch_typeinfo(ITypeInfo**) DECLSPEC_HIDDEN; #define PROPF_ARGMASK 0x00ff #define PROPF_METHOD 0x0100 diff --git a/dlls/jscript/jscript_main.c b/dlls/jscript/jscript_main.c index 9f9f4121f7..532cdf96d9 100644 --- a/dlls/jscript/jscript_main.c +++ b/dlls/jscript/jscript_main.c @@ -37,6 +37,30 @@ LONG module_ref = 0; DEFINE_GUID(GUID_NULL,0,0,0,0,0,0,0,0,0,0,0); HINSTANCE jscript_hinstance; +static ITypeInfo *dispatch_typeinfo; + +HRESULT get_dispatch_typeinfo(ITypeInfo **out) +{ + ITypeInfo *typeinfo; + ITypeLib *typelib; + HRESULT hr; + + if (!dispatch_typeinfo) + { + hr = LoadRegTypeLib(&IID_StdOle, STDOLE_MAJORVERNUM, STDOLE_MINORVERNUM, STDOLE_LCID, &typelib); + if (FAILED(hr)) return hr; + + hr = ITypeLib_GetTypeInfoOfGuid(typelib, &IID_IDispatch, &typeinfo); + ITypeLib_Release(typelib); + if (FAILED(hr)) return hr; + + if (InterlockedCompareExchangePointer((void**)&dispatch_typeinfo, typeinfo, NULL)) + ITypeInfo_Release(typeinfo); + } + + *out = dispatch_typeinfo; + return S_OK; +} static HRESULT WINAPI ClassFactory_QueryInterface(IClassFactory *iface, REFIID riid, void **ppv) { @@ -145,6 +169,7 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpv) break; case DLL_PROCESS_DETACH: if (lpv) break; + if (dispatch_typeinfo) ITypeInfo_Release(dispatch_typeinfo); free_strings(); }
1
0
0
0
Gabriel Ivăncescu : jscript: Implement ScriptTypeInfo_GetVarDesc.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: 93cc9e557d35703b6248ed5f361f3e935fe13044 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=93cc9e557d35703b6248ed5f…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Thu Dec 12 14:53:58 2019 +0200 jscript: Implement ScriptTypeInfo_GetVarDesc. Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/jscript/dispex.c | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index 1f062fe22e..df87aedcac 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -752,10 +752,22 @@ static HRESULT WINAPI ScriptTypeInfo_GetFuncDesc(ITypeInfo *iface, UINT index, F static HRESULT WINAPI ScriptTypeInfo_GetVarDesc(ITypeInfo *iface, UINT index, VARDESC **ppVarDesc) { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeInfo(iface); + VARDESC *desc; - FIXME("(%p)->(%u %p)\n", This, index, ppVarDesc); + TRACE("(%p)->(%u %p)\n", This, index, ppVarDesc); - return E_NOTIMPL; + if (!ppVarDesc) return E_INVALIDARG; + if (index >= This->num_vars) return TYPE_E_ELEMENTNOTFOUND; + + desc = heap_alloc_zero(sizeof(*desc)); + if (!desc) return E_OUTOFMEMORY; + + desc->memid = prop_to_id(This->jsdisp, This->vars[index]); + desc->varkind = VAR_DISPATCH; + desc->elemdescVar.tdesc.vt = VT_VARIANT; + + *ppVarDesc = desc; + return S_OK; } static HRESULT WINAPI ScriptTypeInfo_GetNames(ITypeInfo *iface, MEMBERID memid, BSTR *rgBstrNames, @@ -894,7 +906,9 @@ static void WINAPI ScriptTypeInfo_ReleaseVarDesc(ITypeInfo *iface, VARDESC *pVar { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeInfo(iface); - FIXME("(%p)->(%p)\n", This, pVarDesc); + TRACE("(%p)->(%p)\n", This, pVarDesc); + + heap_free(pVarDesc); } static const ITypeInfoVtbl ScriptTypeInfoVtbl = {
1
0
0
0
Gabriel Ivăncescu : jscript: Implement ScriptTypeInfo_GetFuncDesc.
by Alexandre Julliard
12 Dec '19
12 Dec '19
Module: wine Branch: master Commit: a7b850341772da86c9a5adfe13148bd09e6155c5 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a7b850341772da86c9a5adfe…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Thu Dec 12 14:53:57 2019 +0200 jscript: Implement ScriptTypeInfo_GetFuncDesc. Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/jscript/dispex.c | 31 ++++++++++++++++++++++++++++--- 1 file changed, 28 insertions(+), 3 deletions(-) diff --git a/dlls/jscript/dispex.c b/dlls/jscript/dispex.c index ef002e4c7e..1f062fe22e 100644 --- a/dlls/jscript/dispex.c +++ b/dlls/jscript/dispex.c @@ -720,10 +720,33 @@ static HRESULT WINAPI ScriptTypeInfo_GetTypeComp(ITypeInfo *iface, ITypeComp **p static HRESULT WINAPI ScriptTypeInfo_GetFuncDesc(ITypeInfo *iface, UINT index, FUNCDESC **ppFuncDesc) { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeInfo(iface); + struct typeinfo_func *func; + FUNCDESC *desc; + unsigned i; - FIXME("(%p)->(%u %p)\n", This, index, ppFuncDesc); + TRACE("(%p)->(%u %p)\n", This, index, ppFuncDesc); - return E_NOTIMPL; + if (!ppFuncDesc) return E_INVALIDARG; + if (index >= This->num_funcs) return TYPE_E_ELEMENTNOTFOUND; + func = &This->funcs[index]; + + /* Store the parameter array after the FUNCDESC structure */ + desc = heap_alloc_zero(sizeof(*desc) + sizeof(ELEMDESC) * func->code->param_cnt); + if (!desc) return E_OUTOFMEMORY; + + desc->memid = prop_to_id(This->jsdisp, func->prop); + desc->funckind = FUNC_DISPATCH; + desc->invkind = INVOKE_FUNC; + desc->callconv = CC_STDCALL; + desc->cParams = func->code->param_cnt; + desc->elemdescFunc.tdesc.vt = VT_VARIANT; + + if (func->code->param_cnt) desc->lprgelemdescParam = (ELEMDESC*)(desc + 1); + for (i = 0; i < func->code->param_cnt; i++) + desc->lprgelemdescParam[i].tdesc.vt = VT_VARIANT; + + *ppFuncDesc = desc; + return S_OK; } static HRESULT WINAPI ScriptTypeInfo_GetVarDesc(ITypeInfo *iface, UINT index, VARDESC **ppVarDesc) @@ -862,7 +885,9 @@ static void WINAPI ScriptTypeInfo_ReleaseFuncDesc(ITypeInfo *iface, FUNCDESC *pF { ScriptTypeInfo *This = ScriptTypeInfo_from_ITypeInfo(iface); - FIXME("(%p)->(%p)\n", This, pFuncDesc); + TRACE("(%p)->(%p)\n", This, pFuncDesc); + + heap_free(pFuncDesc); } static void WINAPI ScriptTypeInfo_ReleaseVarDesc(ITypeInfo *iface, VARDESC *pVarDesc)
1
0
0
0
← Newer
1
...
19
20
21
22
23
24
25
...
64
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
Results per page:
10
25
50
100
200