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
July 2006
----- 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
5 participants
857 discussions
Start a n
N
ew thread
Jeff Latimer : usp10: Add functionality for ScriptXtoCP and ScriptCPtoX calls.
by Alexandre Julliard
21 Jul '06
21 Jul '06
Module: wine Branch: refs/heads/master Commit: 8d139c8b960249e9513492b7ca16d9311b4ef1de URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=8d139c8b960249e9513492b…
Author: Jeff Latimer <lats(a)yless4u.com.au> Date: Thu Jul 20 22:16:50 2006 +1000 usp10: Add functionality for ScriptXtoCP and ScriptCPtoX calls. --- dlls/usp10/tests/usp10.c | 91 ++++++++++++++++++++++++++++++++++++++++++++++ dlls/usp10/usp10.c | 49 ++++++++++++++++++++++--- 2 files changed, 134 insertions(+), 6 deletions(-) diff --git a/dlls/usp10/tests/usp10.c b/dlls/usp10/tests/usp10.c index cbaf44a..2a3d9c4 100644 --- a/dlls/usp10/tests/usp10.c +++ b/dlls/usp10/tests/usp10.c @@ -487,6 +487,96 @@ void test_ScriptTextOut(void) DestroyWindow(hwnd); } +static void test_ScriptXtoX(void) +/**************************************************************************************** + * This routine tests the ScriptXtoCP and ScriptCPtoX functions using static variables * + ****************************************************************************************/ +{ + int iX, iCP; + int cChars; + int cGlyphs; + WORD pwLogClust[10] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0}; + SCRIPT_VISATTR psva[10]; + int piAdvance[10] = {200, 190, 210, 180, 170, 204, 189, 195, 212, 203}; + SCRIPT_ANALYSIS psa; + int piCP, piX; + int piTrailing; + BOOL fTrailing; + HRESULT hr; + + iX = -1; + cChars = 10; + cGlyphs = 10; + hr = ScriptXtoCP(iX, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piCP, &piTrailing); + ok(hr == S_OK, "ScriptXtoCP should return S_OK not %d\n", (unsigned int) hr); + ok(piCP == -1, "Negative iX should return piCP=-1 not %d\n", piCP); + ok(piTrailing == TRUE, "Negative iX should return piTrailing=TRUE not %d", piTrailing); + iX = 1954; + cChars = 10; + cGlyphs = 10; + hr = ScriptXtoCP(iX, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piCP, &piTrailing); + ok(hr == S_OK, "ScriptXtoCP should return S_OK not %d\n", (unsigned int) hr); + ok(piCP == 10, "Excessive iX should return piCP=10 not %d\n", piCP); + ok(piTrailing == FALSE, "Excessive iX should return piTrailing=FALSE not %d\n", piTrailing); + iX = 779; + cChars = 10; + cGlyphs = 10; + hr = ScriptXtoCP(iX, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piCP, &piTrailing); + ok(hr == S_OK, "ScriptXtoCP should return S_OK not %d\n", (unsigned int) hr); + ok(piCP == 3, "iX=%d should return piCP=3 not %d\n", iX, piCP); + ok(piTrailing == 1, "iX=%d should return piTrailing=1 not %d\n", iX, piTrailing); + iX = 780; + cChars = 10; + cGlyphs = 10; + hr = ScriptXtoCP(iX, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piCP, &piTrailing); + ok(hr == S_OK, "ScriptXtoCP should return S_OK not %d\n", (unsigned int) hr); + ok(piCP == 3, "iX=%d should return piCP=3 not %d\n", iX, piCP); + ok(piTrailing == 1, "iX=%d should return piTrailing=1 not %d\n", iX, piTrailing); + iX = 868; + cChars = 10; + cGlyphs = 10; + hr = ScriptXtoCP(iX, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piCP, &piTrailing); + ok(hr == S_OK, "ScriptXtoCP should return S_OK not %d\n", (unsigned int) hr); + ok(piCP == 4, "iX=%d should return piCP=4 not %d\n", iX, piCP); + + iCP=5; + fTrailing = FALSE; + cChars = 10; + cGlyphs = 10; + hr = ScriptCPtoX(iCP, fTrailing, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piX); + ok(hr == S_OK, "ScriptCPtoX should return S_OK not %d\n", (unsigned int) hr); + ok(piX == 976, "iCP=%d should return piX=976 not %d\n", iCP, piX); + iCP=5; + fTrailing = TRUE; + cChars = 10; + cGlyphs = 10; + hr = ScriptCPtoX(iCP, fTrailing, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piX); + ok(hr == S_OK, "ScriptCPtoX should return S_OK not %d\n", (unsigned int) hr); + ok(piX == 1171, "iCP=%d should return piX=1171 not %d\n", iCP, piX); + iCP=6; + fTrailing = FALSE; + cChars = 10; + cGlyphs = 10; + hr = ScriptCPtoX(iCP, fTrailing, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piX); + ok(hr == S_OK, "ScriptCPtoX should return S_OK not %d\n", (unsigned int) hr); + ok(piX == 1171, "iCP=%d should return piX=1171 not %d\n", iCP, piX); + iCP=11; + fTrailing = FALSE; + cChars = 10; + cGlyphs = 10; + hr = ScriptCPtoX(iCP, fTrailing, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piX); + ok(hr == S_OK, "ScriptCPtoX should return S_OK not %d\n", (unsigned int) hr); + ok(piX == 1953, "iCP=%d should return piX=1953 not %d\n", iCP, piX); + iCP=11; + fTrailing = TRUE; + cChars = 10; + cGlyphs = 10; + hr = ScriptCPtoX(iCP, fTrailing, cChars, cGlyphs, pwLogClust, psva, piAdvance, &psa, &piX); + ok(hr == S_OK, "ScriptCPtoX should return S_OK not %d\n", (unsigned int) hr); + ok(piX == 1953, "iCP=%d should return piX=1953 not %d\n", iCP, piX); + +} + static void test_ScriptString(void) { HRESULT hr; @@ -569,5 +659,6 @@ START_TEST(usp10) test_ScriptGetCMap(pwOutGlyphs); test_ScriptGetFontProperties(); test_ScriptTextOut(); + test_ScriptXtoX(); test_ScriptString(); } diff --git a/dlls/usp10/usp10.c b/dlls/usp10/usp10.c index aa39449..9e02007 100644 --- a/dlls/usp10/usp10.c +++ b/dlls/usp10/usp10.c @@ -362,11 +362,20 @@ HRESULT WINAPI ScriptCPtoX(int iCP, const SCRIPT_ANALYSIS *psa, int *piX) { - FIXME("(%d,%d,%d,%d,%p,%p,%p,%p,%p): stub\n", + int item; + int iPosX; + float fMaxPosX = 0; + TRACE("(%d,%d,%d,%d,%p,%p,%p,%p,%p)\n", iCP, fTrailing, cChars, cGlyphs, pwLogClust, psva, piAdvance, psa, piX); - - *piX = 1; /* Return something in range */ + for (item=0; item < cGlyphs; item++) /* total piAdvance */ + fMaxPosX += piAdvance[item]; + iPosX = (fMaxPosX/cGlyphs)*(iCP+fTrailing); + if (iPosX > fMaxPosX) + iPosX = fMaxPosX; + *piX = iPosX; /* Return something in range */ + + TRACE("*piX=%d\n", *piX); return S_OK; } @@ -384,12 +393,40 @@ HRESULT WINAPI ScriptXtoCP(int iX, int *piCP, int *piTrailing) { - FIXME("(%d,%d,%d,%p,%p,%p,%p,%p,%p): stub\n", + int item; + int iPosX = 1; + float fMaxPosX = 1; + float fAvePosX; + TRACE("(%d,%d,%d,%p,%p,%p,%p,%p,%p)\n", iX, cChars, cGlyphs, pwLogClust, psva, piAdvance, psa, piCP, piTrailing); + if (iX < 0) /* iX is before start of run */ + { + *piCP = -1; + *piTrailing = TRUE; + return S_OK; + } - *piCP = 1; /* Return something in range */ - *piTrailing = 0; + for (item=0; item < cGlyphs; item++) /* total piAdvance */ + fMaxPosX += piAdvance[item]; + + if (iX >= fMaxPosX) /* iX too large */ + { + *piCP = cChars; + *piTrailing = FALSE; + return S_OK; + } + + fAvePosX = fMaxPosX / cGlyphs; + for (item = 0; item < cGlyphs && iPosX < iX; item++) + iPosX = fAvePosX * (item +1); + if (iPosX - iX > fAvePosX/2) + *piTrailing = 0; + else + *piTrailing = 1; /* yep we are over half way */ + + *piCP = item -1; /* Return character position */ + TRACE("*piCP=%d iPposX=%d\n", *piCP, iPosX); return S_OK; }
1
0
0
0
Robert Shearman : ole32: Implement CoRegisterPSClsid.
by Alexandre Julliard
21 Jul '06
21 Jul '06
Module: wine Branch: refs/heads/master Commit: 2308d49bcba08d12582c99e2f43aebc1e0568df8 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=2308d49bcba08d12582c99e…
Author: Robert Shearman <rob(a)codeweavers.com> Date: Thu Jul 20 19:30:21 2006 +0100 ole32: Implement CoRegisterPSClsid. --- dlls/ole32/compobj.c | 105 ++++++++++++++++++++++++++++- dlls/ole32/compobj_private.h | 1 dlls/ole32/ole32.spec | 2 - dlls/ole32/tests/compobj.c | 152 ++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 256 insertions(+), 4 deletions(-) Diff:
http://source.winehq.org/git/?p=wine.git;a=commitdiff;h=2308d49bcba08d12582…
1
0
0
0
Juan Lang : msi: Don't use fixed-size buffers in AppSearch action.
by Alexandre Julliard
21 Jul '06
21 Jul '06
Module: wine Branch: refs/heads/master Commit: fb6bd2414bdf8634d633b8056d663b5ad789f160 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=fb6bd2414bdf8634d633b80…
Author: Juan Lang <juan_lang(a)yahoo.com> Date: Thu Jul 20 06:55:48 2006 -0700 msi: Don't use fixed-size buffers in AppSearch action. --- dlls/msi/appsearch.c | 64 ++++++++++++++------------------------------------ 1 files changed, 18 insertions(+), 46 deletions(-) diff --git a/dlls/msi/appsearch.c b/dlls/msi/appsearch.c index 598965e..2e317c1 100644 --- a/dlls/msi/appsearch.c +++ b/dlls/msi/appsearch.c @@ -872,9 +872,8 @@ static UINT ACTION_AppSearchDr(MSIPACKAG if (rc == ERROR_SUCCESS) { MSIRECORD *row = 0; - WCHAR buffer[MAX_PATH], expanded[MAX_PATH]; - LPWSTR path = NULL, parent = NULL; - DWORD sz; + WCHAR expanded[MAX_PATH]; + LPWSTR parentName = NULL, path = NULL, parent = NULL; int depth; rc = MSI_ViewExecute(view, 0); @@ -892,36 +891,25 @@ static UINT ACTION_AppSearchDr(MSIPACKAG } /* check whether parent is set */ - buffer[0] = 0; - sz=sizeof(buffer)/sizeof(buffer[0]); - rc = MSI_RecordGetStringW(row,2,buffer,&sz); - if (rc != ERROR_SUCCESS) - { - ERR("Error is %x\n",rc); - goto end; - } - else if (buffer[0]) + parentName = msi_dup_record_field(row,2); + if (parentName) { MSISIGNATURE parentSig; - rc = ACTION_AppSearchSigName(package, buffer, &parentSig, &parent); + rc = ACTION_AppSearchSigName(package, parentName, &parentSig, + &parent); ACTION_FreeSignature(&parentSig); + msi_free(parentName); } /* now look for path */ - buffer[0] = 0; - sz=sizeof(buffer)/sizeof(buffer[0]); - rc = MSI_RecordGetStringW(row,3,buffer,&sz); - if (rc != ERROR_SUCCESS) - { - ERR("Error is %x\n",rc); - goto end; - } + path = msi_dup_record_field(row,3); if (MSI_RecordIsNull(row,4)) depth = 0; else depth = MSI_RecordGetInteger(row,4); - ACTION_ExpandAnyPath(package, buffer, expanded, + ACTION_ExpandAnyPath(package, path, expanded, sizeof(expanded) / sizeof(expanded[0])); + msi_free(path); if (parent) { path = HeapAlloc(GetProcessHeap(), 0, strlenW(parent) + @@ -994,8 +982,7 @@ UINT ACTION_AppSearch(MSIPACKAGE *packag if (rc == ERROR_SUCCESS) { MSIRECORD *row = 0; - WCHAR propBuf[0x100], sigBuf[0x100]; - DWORD sz; + LPWSTR propName, sigName; rc = MSI_ViewExecute(view, 0); if (rc != ERROR_SUCCESS) @@ -1014,36 +1001,21 @@ UINT ACTION_AppSearch(MSIPACKAGE *packag } /* get property and signature */ - propBuf[0] = 0; - sz=sizeof(propBuf)/sizeof(propBuf[0]); - rc = MSI_RecordGetStringW(row,1,propBuf,&sz); - if (rc != ERROR_SUCCESS) - { - ERR("Error is %x\n",rc); - msiobj_release(&row->hdr); - break; - } - sigBuf[0] = 0; - sz=sizeof(sigBuf)/sizeof(sigBuf[0]); - rc = MSI_RecordGetStringW(row,2,sigBuf,&sz); - if (rc != ERROR_SUCCESS) - { - ERR("Error is %x\n",rc); - msiobj_release(&row->hdr); - break; - } + propName = msi_dup_record_field(row,1); + sigName = msi_dup_record_field(row,2); TRACE("Searching for Property %s, Signature_ %s\n", - debugstr_w(propBuf), debugstr_w(sigBuf)); + debugstr_w(propName), debugstr_w(sigName)); - rc = ACTION_AppSearchSigName(package, sigBuf, &sig, &value); + rc = ACTION_AppSearchSigName(package, sigName, &sig, &value); if (value) { - MSI_SetPropertyW(package, propBuf, value); + MSI_SetPropertyW(package, propName, value); msi_free(value); } - ACTION_FreeSignature(&sig); + msi_free(propName); + msi_free(sigName); msiobj_release(&row->hdr); }
1
0
0
0
Roderick Colenbrander : dinput8: DirectInput8Create rewrite.
by Alexandre Julliard
21 Jul '06
21 Jul '06
Module: wine Branch: refs/heads/master Commit: 951f4657b796dd128c6797e65fe497faee4f12f5 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=951f4657b796dd128c6797e…
Author: Roderick Colenbrander <thunderbird2k(a)gmx.net> Date: Thu Jul 20 12:42:23 2006 +0200 dinput8: DirectInput8Create rewrite. --- dlls/dinput8/Makefile.in | 2 +- dlls/dinput8/dinput8_main.c | 39 +++++++++++++++++++++++++++++++++++---- tools/wine.inf | 3 +++ 3 files changed, 39 insertions(+), 5 deletions(-) diff --git a/dlls/dinput8/Makefile.in b/dlls/dinput8/Makefile.in index 34135c1..4466d1d 100644 --- a/dlls/dinput8/Makefile.in +++ b/dlls/dinput8/Makefile.in @@ -4,7 +4,7 @@ SRCDIR = @srcdir@ VPATH = @srcdir@ MODULE = dinput8.dll IMPORTLIB = libdinput8.$(IMPLIBEXT) -IMPORTS = dinput kernel32 +IMPORTS = dinput ole32 advapi32 kernel32 EXTRALIBS = -luuid -ldxguid C_SRCS = \ diff --git a/dlls/dinput8/dinput8_main.c b/dlls/dinput8/dinput8_main.c index 54ea66e..95aa919 100644 --- a/dlls/dinput8/dinput8_main.c +++ b/dlls/dinput8/dinput8_main.c @@ -51,8 +51,39 @@ static void UnlockModule(void) * DirectInput8Create (DINPUT8.@) */ HRESULT WINAPI DirectInput8Create(HINSTANCE hinst, DWORD dwVersion, REFIID riid, LPVOID *ppDI, LPUNKNOWN punkOuter) { - /* TODO: Create the interface using CoCreateInstance as that's what windows does too and check if the version number >= 0x800 */ - return DirectInputCreateEx(hinst, dwVersion, riid, ppDI, punkOuter); + HRESULT hr; + + TRACE("hInst (%p), dwVersion: %ld, riid (%s), punkOuter (%p))\n", hinst, dwVersion, debugstr_guid(riid), punkOuter); + + /* The specified version needs to be dinput8 (0x800) or higher */ + if(dwVersion < 0x800) + return DIERR_OLDDIRECTINPUTVERSION; + + if( !(IsEqualGUID(&IID_IDirectInput8A, riid) || IsEqualGUID(&IID_IDirectInput8W, riid) || IsEqualGUID(&IID_IUnknown, riid)) ) + return DIERR_INVALIDPARAM; + + CoInitialize(NULL); + + hr = CoCreateInstance( &CLSID_DirectInput8, punkOuter, CLSCTX_INPROC_SERVER, riid, ppDI); + if(FAILED(hr)) { + ERR("CoCreateInstance failed with hr = %ld\n", hr); + return DIERR_INVALIDPARAM; + } + + CoUninitialize(); + + /* When aggregation is used (punkOuter!=NULL) the application needs to manually call Initialize. */ + if(punkOuter == NULL && IsEqualGUID(&IID_IDirectInput8A, riid)) { + LPDIRECTINPUTA DI = (LPDIRECTINPUTA)*ppDI; + IDirectInput8_Initialize(DI, hinst, dwVersion); + } + + if(punkOuter == NULL && IsEqualGUID(&IID_IDirectInput8W, riid)) { + LPDIRECTINPUTW DI = (LPDIRECTINPUTW)*ppDI; + IDirectInput8_Initialize(DI, hinst, dwVersion); + } + + return S_OK; } /******************************************************************************* @@ -84,8 +115,8 @@ static HRESULT WINAPI DI8CF_CreateInstan IClassFactoryImpl *This = (IClassFactoryImpl *)iface; TRACE("(%p)->(%p,%s,%p)\n",This,pOuter,debugstr_guid(riid),ppobj); - if( IsEqualGUID( &IID_IDirectInput8A, riid ) || IsEqualGUID( &IID_IDirectInput8W, riid ) ) { - return DirectInput8Create(0, DIRECTINPUT_VERSION, riid, ppobj, pOuter); + if( IsEqualGUID( &IID_IDirectInput8A, riid ) || IsEqualGUID( &IID_IDirectInput8W, riid ) || IsEqualGUID( &IID_IUnknown, riid )) { + return DirectInputCreateEx(0, DIRECTINPUT_VERSION, riid, ppobj, pOuter); } ERR("(%p,%p,%s,%p) Interface not found!\n",This,pOuter,debugstr_guid(riid),ppobj); diff --git a/tools/wine.inf b/tools/wine.inf index d1a280e..316c25a 100644 --- a/tools/wine.inf +++ b/tools/wine.inf @@ -126,6 +126,9 @@ HKCR,AVIFile\Extensions\AVI,,,"{00020000 HKCR,AVIFile\Extensions\WAV,,,"{00020003-0000-0000-C000-000000000046}" HKCR,AVIFile\RIFFHandlers\AVI,,,"{00020000-0000-0000-C000-000000000046}" HKCR,AVIFile\RIFFHandlers\WAVE,,,"{00020003-0000-0000-C000-000000000046}" +HKCR,CLSID\{25E609E4-B259-11CF-BFC7-444553540000},,,"DirectInput8 Object" +HKCR,CLSID\{25E609E4-B259-11CF-BFC7-444553540000}\InProcServer32,,,"dinput8.dll" +HKCR,CLSID\{25E609E4-B259-11CF-BFC7-444553540000}\InProcServer32,ThreadingModel,,"Both" HKCR,TypeLib\{00020430-0000-0000-C000-000000000046}\1.0,,,"OLE Automation" HKCR,TypeLib\{00020430-0000-0000-C000-000000000046}\1.0\0\win16,,,"stdole.tlb" HKCR,TypeLib\{00020430-0000-0000-C000-000000000046}\1.0\0\win32,,,"stdole32.tlb"
1
0
0
0
Benjamin Arai : oleaut32: OLEFontImpl_GetIDsOfNames conformance test.
by Alexandre Julliard
21 Jul '06
21 Jul '06
Module: wine Branch: refs/heads/master Commit: 31e3ad7150f5e308e5ead6f49fa0e87f7d2bafc4 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=31e3ad7150f5e308e5ead6f…
Author: Benjamin Arai <me(a)benjaminarai.com> Date: Wed Jul 19 18:08:38 2006 -0700 oleaut32: OLEFontImpl_GetIDsOfNames conformance test. --- dlls/oleaut32/tests/olefont.c | 111 +++++++++++++++++++++++++++++++++++++++++ 1 files changed, 111 insertions(+), 0 deletions(-) diff --git a/dlls/oleaut32/tests/olefont.c b/dlls/oleaut32/tests/olefont.c index 9525eb3..e17d66a 100644 --- a/dlls/oleaut32/tests/olefont.c +++ b/dlls/oleaut32/tests/olefont.c @@ -2,6 +2,7 @@ * OLEFONT test program * * Copyright 2003 Marcus Meissner + * Copyright 2006 (Google) Benjamin Arai * * * This library is free software; you can redistribute it and/or @@ -295,6 +296,115 @@ static void test_font_events_disp(void) IFont_Release(pFont2); } +void test_names_ids(WCHAR* w_name_1, const char* a_name_1, + WCHAR* w_name_2, const char* a_name_2, + LCID lcid, DISPID id_1, DISPID id_2, + HRESULT hres_expect, int numnames) +{ + LPVOID pvObj = NULL; + IFontDisp *fontdisp = NULL; + HRESULT hres; + DISPID rgDispId[2] = {0xdeadbeef, 0xdeadbeef}; + LPOLESTR names[2] = {w_name_1, w_name_2}; + + pOleCreateFontIndirect(NULL, &IID_IFontDisp, &pvObj); + fontdisp = pvObj; + + hres = IFontDisp_GetIDsOfNames(fontdisp, &IID_NULL, names, numnames, + lcid, rgDispId); + + /* test hres */ + ok(hres == hres_expect, + "GetIDsOfNames: \"%s\", \"%s\" returns 0x%08lx, expected 0x%08lx.\n", + a_name_1, a_name_2, hres, hres_expect); + + /* test first DISPID */ + ok(rgDispId[0]==id_1, + "GetIDsOfNames: \"%s\" gets DISPID 0x%08lx, expected 0x%08lx.\n", + a_name_1, rgDispId[0], id_1); + + /* test second DISPID is present */ + if (numnames == 2) + { + ok(rgDispId[1]==id_2, + "GetIDsOfNames: ..., \"%s\" gets DISPID 0x%08lx, expected 0x%08lx.\n", + a_name_2, rgDispId[1], id_2); + } + + IFontDisp_Release(fontdisp); +} + +void test_GetIDsOfNames(void) +{ + WCHAR name_Name[] = {'N','a','m','e',0}; + WCHAR name_Italic[] = {'I','t','a','l','i','c',0}; + WCHAR name_Size[] = {'S','i','z','e',0}; + WCHAR name_Bold[] = {'B','o','l','d',0}; + WCHAR name_Underline[] = {'U','n','d','e','r','l','i','n','e',0}; + WCHAR name_Strikethrough[] = {'S','t','r','i','k','e','t','h','r','o','u','g','h',0}; + WCHAR name_Weight[] = {'W','e','i','g','h','t',0}; + WCHAR name_Charset[] = {'C','h','a','r','s','e','t',0}; + WCHAR name_Foo[] = {'F','o','o',0}; + WCHAR name_nAmE[] = {'n','A','m','E',0}; + WCHAR name_Nom[] = {'N','o','m',0}; + + LCID en_us = MAKELCID(MAKELANGID(LANG_ENGLISH,SUBLANG_ENGLISH_US), + SORT_DEFAULT); + LCID fr_fr = MAKELCID(MAKELANGID(LANG_FRENCH,SUBLANG_FRENCH), + SORT_DEFAULT); + + /* Test DISPID_FONTs for the various properties. */ + test_names_ids(name_Name, "Name", NULL, "", en_us, + DISPID_FONT_NAME, 0, S_OK,1); + test_names_ids(name_Size, "Size", NULL, "", en_us, + DISPID_FONT_SIZE, 0, S_OK,1); + test_names_ids(name_Bold, "Bold", NULL, "", en_us, + DISPID_FONT_BOLD, 0, S_OK,1); + test_names_ids(name_Italic, "Italic", NULL, "", en_us, + DISPID_FONT_ITALIC, 0, S_OK,1); + test_names_ids(name_Underline, "Underline", NULL, "", en_us, + DISPID_FONT_UNDER, 0, S_OK,1); + test_names_ids(name_Strikethrough, "Strikethrough", NULL, "", en_us, + DISPID_FONT_STRIKE, 0, S_OK,1); + test_names_ids(name_Weight, "Weight", NULL, "", en_us, + DISPID_FONT_WEIGHT, 0, S_OK,1); + test_names_ids(name_Charset, "Charset", NULL, "", en_us, + DISPID_FONT_CHARSET, 0, S_OK,1); + + /* Capitalization doesn't matter. */ + test_names_ids(name_nAmE, "nAmE", NULL, "", en_us, + DISPID_FONT_NAME, 0, S_OK,1); + + /* Unknown name. */ + test_names_ids(name_Foo, "Foo", NULL, "", en_us, + DISPID_UNKNOWN, 0, DISP_E_UNKNOWNNAME,1); + + /* Pass several names: first is processed, */ + /* second gets DISPID_UNKNOWN and doesn't affect retval. */ + test_names_ids(name_Italic, "Italic", name_Name, "Name", en_us, + DISPID_FONT_ITALIC, DISPID_UNKNOWN, S_OK,2); + test_names_ids(name_Italic, "Italic", name_Foo, "Foo", en_us, + DISPID_FONT_ITALIC, DISPID_UNKNOWN, S_OK,2); + + /* Locale ID has no effect. */ + test_names_ids(name_Name, "Name", NULL, "", fr_fr, + DISPID_FONT_NAME, 0, S_OK,1); + test_names_ids(name_Nom, "This is not a font", NULL, "", fr_fr, + DISPID_UNKNOWN, 0, DISP_E_UNKNOWNNAME,1); + + /* One of the arguments are invalid */ + test_names_ids(name_Name, "Name", NULL, "", en_us, + 0xdeadbeef, 0xdeadbeef, E_INVALIDARG,0); + test_names_ids(name_Italic, "Italic", NULL, "", en_us, + 0xdeadbeef, 0xdeadbeef, E_INVALIDARG,0); + test_names_ids(name_Foo, "Foo", NULL, "", en_us, + 0xdeadbeef, 0xdeadbeef, E_INVALIDARG,0); + + /* Crazy locale ID? */ + test_names_ids(name_Name, "Name", NULL, "", -1, + DISPID_FONT_NAME, 0, S_OK,1); +} + START_TEST(olefont) { hOleaut32 = LoadLibraryA("oleaut32.dll"); @@ -316,4 +426,5 @@ START_TEST(olefont) /* test_ifont_sizes(186000, 0, 72, 2540, -19, "rounding"); */ /* test rounding */ test_font_events_disp(); + test_GetIDsOfNames(); }
1
0
0
0
Benjamin Arai : oleaut32: Implements OLEFontImpl_GetIDsOfNames.
by Alexandre Julliard
21 Jul '06
21 Jul '06
Module: wine Branch: refs/heads/master Commit: f75b9f190f368956949277983a09757d3e5b1a67 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=f75b9f190f3689569492779…
Author: Benjamin Arai <me(a)benjaminarai.com> Date: Wed Jul 19 18:06:14 2006 -0700 oleaut32: Implements OLEFontImpl_GetIDsOfNames. --- dlls/oleaut32/olefont.c | 33 +++++++++++++++++++++++++++++---- 1 files changed, 29 insertions(+), 4 deletions(-) diff --git a/dlls/oleaut32/olefont.c b/dlls/oleaut32/olefont.c index 6c5ea27..8ce3e00 100644 --- a/dlls/oleaut32/olefont.c +++ b/dlls/oleaut32/olefont.c @@ -5,6 +5,7 @@ * interface and the OleCreateFontIndirect API call. * * Copyright 1999 Francis Beaudet + * Copyright 2006 (Google) Benjamin Arai * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -1347,11 +1348,35 @@ static HRESULT WINAPI OLEFontImpl_GetIDs LCID lcid, DISPID* rgDispId) { + ITypeInfo * pTInfo; + HRESULT hres; + OLEFontImpl *this = impl_from_IDispatch(iface); - FIXME("(%p,%s,%p,%d,%04x,%p), stub!\n", this, debugstr_guid(riid), rgszNames, - cNames, (int)lcid, rgDispId - ); - return E_NOTIMPL; + + TRACE("(%p,%s,%p,cNames=%d,lcid=%04x,%p)\n", this, debugstr_guid(riid), + rgszNames, cNames, (int)lcid, rgDispId); + + if (cNames == 0) + { + return E_INVALIDARG; + } + else + { + /* retrieve type information */ + hres = OLEFontImpl_GetTypeInfo(iface, 0, lcid, &pTInfo); + + if (FAILED(hres)) + { + ERR("GetTypeInfo failed.\n"); + return hres; + } + + /* convert names to DISPIDs */ + hres = DispGetIDsOfNames (pTInfo, rgszNames, cNames, rgDispId); + ITypeInfo_Release(pTInfo); + + return hres; + } } /************************************************************************
1
0
0
0
Bang Jun-Young : comdlg32: Remove redundant headers.
by Alexandre Julliard
21 Jul '06
21 Jul '06
Module: wine Branch: refs/heads/master Commit: 4988fad2325fafd5e6c076e8efd896fc5a94d21b URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=4988fad2325fafd5e6c076e…
Author: Bang Jun-Young <bang.junyoung(a)gmail.com> Date: Wed Jul 19 17:22:55 2006 +0900 comdlg32: Remove redundant headers. --- dlls/comdlg32/filedlg31.c | 4 ---- 1 files changed, 0 insertions(+), 4 deletions(-) diff --git a/dlls/comdlg32/filedlg31.c b/dlls/comdlg32/filedlg31.c index 79141fa..55c94b8 100644 --- a/dlls/comdlg32/filedlg31.c +++ b/dlls/comdlg32/filedlg31.c @@ -33,11 +33,7 @@ #include "wine/debug.h" #include "cderr.h" #include "winreg.h" #include "winternl.h" -#include "winuser.h" #include "commdlg.h" -#include "cderr.h" -#include "winreg.h" -#include "winternl.h" #include "shlwapi.h" WINE_DEFAULT_DEBUG_CHANNEL(commdlg);
1
0
0
0
Ge van Geldorp : gdi: Use variables of correct size.
by Alexandre Julliard
21 Jul '06
21 Jul '06
Module: wine Branch: refs/heads/master Commit: 1e554e870b89a1c87f6af58e78ee07d443279f61 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=1e554e870b89a1c87f6af58…
Author: Ge van Geldorp <ge(a)gse.nl> Date: Wed Jul 19 09:17:49 2006 +0200 gdi: Use variables of correct size. --- dlls/gdi/freetype.c | 14 +++++++------- 1 files changed, 7 insertions(+), 7 deletions(-) diff --git a/dlls/gdi/freetype.c b/dlls/gdi/freetype.c index 7fb62bd..2a6024c 100644 --- a/dlls/gdi/freetype.c +++ b/dlls/gdi/freetype.c @@ -814,7 +814,7 @@ #ifdef HAVE_FREETYPE_FTWINFNT_H CHARSETINFO csi; TRACE("pix_h %d charset %d dpi %dx%d pt %d\n", winfnt_header.pixel_height, winfnt_header.charset, winfnt_header.vertical_resolution,winfnt_header.horizontal_resolution, winfnt_header.nominal_point_size); - if(TranslateCharsetInfo((DWORD*)(UINT)winfnt_header.charset, &csi, TCI_SRCCHARSET)) + if(TranslateCharsetInfo((DWORD*)(UINT_PTR)winfnt_header.charset, &csi, TCI_SRCCHARSET)) memcpy(&fs, &csi.fs, sizeof(csi.fs)); internal_leading = winfnt_header.internal_leading; } @@ -1901,7 +1901,7 @@ static int get_nearest_charset(Face *fac DWORD fs0; *cp = acp; - if(TranslateCharsetInfo((DWORD*)acp, &csi, TCI_SRCCODEPAGE)) + if(TranslateCharsetInfo((DWORD*)(INT_PTR)acp, &csi, TCI_SRCCODEPAGE)) if(csi.fs.fsCsb[0] & face->fs.fsCsb[0]) return csi.ciCharset; @@ -2305,7 +2305,7 @@ GdiFont WineEngCreateFontInstance(DC *dc if(!strcmpiW(lf.lfFaceName, SymbolW)) lf.lfCharSet = SYMBOL_CHARSET; - if(!TranslateCharsetInfo((DWORD*)(INT)lf.lfCharSet, &csi, TCI_SRCCHARSET)) { + if(!TranslateCharsetInfo((DWORD*)(INT_PTR)lf.lfCharSet, &csi, TCI_SRCCHARSET)) { switch(lf.lfCharSet) { case DEFAULT_CHARSET: csi.fs.fsCsb[0] = 0; @@ -2351,7 +2351,7 @@ GdiFont WineEngCreateFontInstance(DC *dc corresponding to the current ansi codepage */ if(!csi.fs.fsCsb[0]) { INT acp = GetACP(); - if(!TranslateCharsetInfo((DWORD*)acp, &csi, TCI_SRCCODEPAGE)) { + if(!TranslateCharsetInfo((DWORD*)(INT_PTR)acp, &csi, TCI_SRCCODEPAGE)) { FIXME("TCI failed on codepage %d\n", acp); csi.fs.fsCsb[0] = 0; } else @@ -3924,7 +3924,7 @@ DWORD WineEngGetFontData(GdiFont font, D DWORD cbData) { FT_Face ft_face = font->ft_face; - DWORD len; + FT_ULong len; FT_Error err; TRACE("font=%p, table=%08lx, offset=%08lx, buf=%p, cbData=%lx\n", @@ -3947,7 +3947,7 @@ DWORD WineEngGetFontData(GdiFont font, D if(pFT_Load_Sfnt_Table) { /* make sure value of len is the value freetype says it needs */ if( buf && len) { - DWORD needed = 0; + FT_ULong needed = 0; err = pFT_Load_Sfnt_Table(ft_face, table, offset, NULL, &needed); if( !err && needed < len) len = needed; } @@ -3969,7 +3969,7 @@ #ifdef HAVE_FREETYPE_INTERNAL_SFNT_H } /* make sure value of len is the value freetype says it needs */ if( buf && len) { - DWORD needed = 0; + FT_ULong needed = 0; err = sfnt->load_any(tt_face, table, offset, NULL, &needed); if( !err && needed < len) len = needed; }
1
0
0
0
appdb/ ./index.php ./scripts.js include/html.p ...
by WineHQ
21 Jul '06
21 Jul '06
ChangeSet ID: 26699 CVSROOT: /opt/cvs-commit Module name: appdb Changes by: wineowner(a)winehq.org 2006/07/20 23:34:58 Modified files: . : index.php scripts.js include : html.php testData.php util.php Log message: Chris Morgan <cmorgan(a)alum.wpi.edu> Make table rows clickable using javascript. Use this functionality in the top X lists and in the test results table Patch:
http://cvs.winehq.org/patch.py?id=26699
Old revision New revision Changes Path 1.37 1.38 +0 -1 appdb/index.php 1.3 1.4 +19 -0 appdb/scripts.js 1.8 1.9 +8 -0 appdb/include/html.php 1.5 1.6 +3 -2 appdb/include/testData.php 1.72 1.73 +3 -2 appdb/include/util.php Index: appdb/index.php diff -u -p appdb/index.php:1.37 appdb/index.php:1.38 --- appdb/index.php:1.37 21 Jul 2006 4:34:58 -0000 +++ appdb/index.php 21 Jul 2006 4:34:58 -0000 @@ -13,7 +13,6 @@ require(BASE."include/incl.php"); apidb_header("Wine Application Database"); ?> - <img src="images/appdb_montage.jpg" width=391 height=266 align=right alt="Wine AppDB"> <h1>Welcome</h1> Index: appdb/scripts.js diff -u -p appdb/scripts.js:1.3 appdb/scripts.js:1.4 --- appdb/scripts.js:1.3 21 Jul 2006 4:34:58 -0000 +++ appdb/scripts.js 21 Jul 2006 4:34:58 -0000 @@ -18,3 +18,22 @@ function deleteURL(text, url) { self.location = url; } } + +function ChangeTrColor(tableRow, bHighLight, sHighlightColor, sInactiveColor) +{ + if (bHighLight) + { + tableRow.style.backgroundColor = sHighlightColor; + tableRow.style.cursor = "hand"; + } + else + { + tableRow.style.backgroundColor = sInactiveColor; + tableRow.style.cursor = "pointer"; + } +} + +function DoNav(sUrl) +{ + document.location.href = sUrl; +} Index: appdb/include/html.php diff -u -p appdb/include/html.php:1.8 appdb/include/html.php:1.9 --- appdb/include/html.php:1.8 21 Jul 2006 4:34:58 -0000 +++ appdb/include/html.php 21 Jul 2006 4:34:58 -0000 @@ -62,6 +62,14 @@ function html_tr($arr, $class = "", $ext return do_html_tr("td", $arr, $class, $extra); } +function html_tr_highlight_clickable($sClass, $sHighlightColor, $sInactiveColor, $sUrl) +{ + echo '<tr class='.$sClass.' '. + 'onmouseover="ChangeTrColor(this, true, \''.$sHighlightColor.'\', \''.$sInactiveColor.'\');"'. + 'onmouseout="ChangeTrColor(this, false, \''.$sHighlightColor.'\', \''.$sInactiveColor.'\');"'. + 'onclick="DoNav(\''.$sUrl.'\');">'; +} + // HTML TABLE function html_table_begin($extra = "") { Index: appdb/include/testData.php diff -u -p appdb/include/testData.php:1.5 appdb/include/testData.php:1.6 --- appdb/include/testData.php:1.5 21 Jul 2006 4:34:58 -0000 +++ appdb/include/testData.php 21 Jul 2006 4:34:58 -0000 @@ -409,15 +409,16 @@ class testData{ $oSubmitter = new User($oTest->iSubmitterId); $oDistribution = new distribution($oTest->iDistributionId); $bgcolor = $oTest->sTestedRating; - echo '<tr class='.$bgcolor.'>',"\n"; /* if the test we are displaying is this test then */ /* mark it as the current test */ if ($oTest->iTestingId == $this->iTestingId) { + echo '<tr class='.$bgcolor.'>',"\n"; echo ' <td align="center" class="color2"><b>Current</b></td>',"\n"; - } else + } else /* make all non-current rows clickable so clicking on them selects the test as current */ { + html_tr_highlight_clickable($bgcolor, "", "color2", $link.$oTest->iTestingId); echo ' <td align="center" class="color2">[<a href="'.$link.$oTest->iTestingId; if(is_string($showAll)) Index: appdb/include/util.php diff -u -p appdb/include/util.php:1.72 appdb/include/util.php:1.73 --- appdb/include/util.php:1.72 21 Jul 2006 4:34:58 -0000 +++ appdb/include/util.php 21 Jul 2006 4:34:58 -0000 @@ -280,9 +280,10 @@ function outputTopXRow($oRow) $oVersion = new Version($oRow->versionId); $oApp = new Application($oVersion->iAppId); $img = Screenshot::get_random_screenshot_img(null, $oRow->versionId, false); // image, disable extra formatting + html_tr_highlight_clickable("white", "white", "white", 'appview.php?iVersionId='.$oRow->versionId); echo ' - <tr class="white"> - <td class="app_name"><a href="appview.php?iVersionId='.$oRow->versionId.'">'.$oApp->sName.' '.$oVersion->sName.'</a></td> + <td class="app_name"> + <a href="appview.php?iVersionId='.$oRow->versionId.'">'.$oApp->sName.' '.$oVersion->sName.'</a></td> <td>'.util_trim_description($oApp->sDescription).'</td> <td><center>'.$img.'</center></td> </tr>';
1
0
0
0
appdb/. apidb.css
by WineHQ
21 Jul '06
21 Jul '06
ChangeSet ID: 26698 CVSROOT: /opt/cvs-commit Module name: appdb Changes by: wineowner(a)winehq.org 2006/07/20 23:27:01 Modified files: . : apidb.css Log message: Chris Morgan <cmorgan(a)alum.wpi.edu> Shift magnifying glass icon 10px left to put it near the corner of the thumbnail it is overlaying Patch:
http://cvs.winehq.org/patch.py?id=26698
Old revision New revision Changes Path 1.16 1.17 +1 -1 appdb/apidb.css Index: appdb/apidb.css diff -u -p appdb/apidb.css:1.16 appdb/apidb.css:1.17 --- appdb/apidb.css:1.16 21 Jul 2006 4:27: 1 -0000 +++ appdb/apidb.css 21 Jul 2006 4:27: 1 -0000 @@ -234,4 +234,4 @@ TD.app_name { width: 150px } #editor { height: 25em; width:700px; } /* zoom image overlay style */ -.zoom_overlay { position:relative; top:10px; left:0px; margin-left:-32px; padding:0px; } +.zoom_overlay { position:relative; top:10px; left:10px; margin-left:-32px; padding:0px; }
1
0
0
0
← Newer
1
...
28
29
30
31
32
33
34
...
86
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
Results per page:
10
25
50
100
200