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
March 2008
----- 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
4 participants
1001 discussions
Start a n
N
ew thread
Nathan Beckmann : gdiplus: Tests for GdipLockBitmapBits/ GdipUnlockBitmapBits.
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: 738e74a14bbda4bb55f366e2290a26b5dd0c8267 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=738e74a14bbda4bb55f366e22…
Author: Nathan Beckmann <nathan.beckmann(a)gmail.com> Date: Fri Mar 7 01:19:02 2008 -0800 gdiplus: Tests for GdipLockBitmapBits/GdipUnlockBitmapBits. --- dlls/gdiplus/tests/image.c | 106 ++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 106 insertions(+), 0 deletions(-) diff --git a/dlls/gdiplus/tests/image.c b/dlls/gdiplus/tests/image.c index 895ff35..4047fee 100644 --- a/dlls/gdiplus/tests/image.c +++ b/dlls/gdiplus/tests/image.c @@ -171,6 +171,111 @@ static void test_encoders(void) GdipFree(codecs); } +static void test_LockBits(void) +{ + GpStatus stat; + GpBitmap *bm; + GpRect rect; + BitmapData bd; + const REAL WIDTH = 10.0, HEIGHT = 20.0; + + bm = NULL; + stat = GdipCreateBitmapFromScan0(WIDTH, HEIGHT, 0, PixelFormat24bppRGB, NULL, &bm); + expect(Ok, stat); + + rect.X = 2; + rect.Y = 3; + rect.Width = 4; + rect.Height = 5; + + /* read-only */ + stat = GdipBitmapLockBits(bm, &rect, ImageLockModeRead, PixelFormat24bppRGB, &bd); + expect(Ok, stat); + + if (stat == Ok) { + stat = GdipBitmapUnlockBits(bm, &bd); + expect(Ok, stat); + } + + /* read-only, consecutive */ + stat = GdipBitmapLockBits(bm, &rect, ImageLockModeRead, PixelFormat24bppRGB, &bd); + expect(Ok, stat); + + if (stat == Ok) { + stat = GdipBitmapUnlockBits(bm, &bd); + expect(Ok, stat); + } + + stat = GdipDisposeImage((GpImage*)bm); + expect(Ok, stat); + stat = GdipCreateBitmapFromScan0(WIDTH, HEIGHT, 0, PixelFormat24bppRGB, NULL, &bm); + expect(Ok, stat); + + /* read x2 */ + stat = GdipBitmapLockBits(bm, &rect, ImageLockModeRead, PixelFormat24bppRGB, &bd); + expect(Ok, stat); + todo_wine { + stat = GdipBitmapLockBits(bm, &rect, ImageLockModeRead, PixelFormat24bppRGB, &bd); + expect(WrongState, stat); + } + + stat = GdipBitmapUnlockBits(bm, &bd); + expect(Ok, stat); + + stat = GdipDisposeImage((GpImage*)bm); + expect(Ok, stat); + stat = GdipCreateBitmapFromScan0(WIDTH, HEIGHT, 0, PixelFormat24bppRGB, NULL, &bm); + expect(Ok, stat); + + /* write, no modification */ + stat = GdipBitmapLockBits(bm, &rect, ImageLockModeWrite, PixelFormat24bppRGB, &bd); + expect(Ok, stat); + + if (stat == Ok) { + stat = GdipBitmapUnlockBits(bm, &bd); + expect(Ok, stat); + } + + /* write, consecutive */ + todo_wine { + stat = GdipBitmapLockBits(bm, &rect, ImageLockModeWrite, PixelFormat24bppRGB, &bd); + expect(Ok, stat); + } + + if (stat == Ok) { + stat = GdipBitmapUnlockBits(bm, &bd); + expect(Ok, stat); + } + + stat = GdipDisposeImage((GpImage*)bm); + expect(Ok, stat); + stat = GdipCreateBitmapFromScan0(WIDTH, HEIGHT, 0, PixelFormat24bppRGB, NULL, &bm); + expect(Ok, stat); + + /* write, modify */ + stat = GdipBitmapLockBits(bm, &rect, ImageLockModeWrite, PixelFormat24bppRGB, &bd); + expect(Ok, stat); + + if (stat == Ok) { + if (bd.Scan0) + ((char*)bd.Scan0)[2] = 0xff; + + stat = GdipBitmapUnlockBits(bm, &bd); + expect(Ok, stat); + } + + stat = GdipDisposeImage((GpImage*)bm); + expect(Ok, stat); + + /* dispose locked */ + stat = GdipCreateBitmapFromScan0(WIDTH, HEIGHT, 0, PixelFormat24bppRGB, NULL, &bm); + expect(Ok, stat); + stat = GdipBitmapLockBits(bm, &rect, ImageLockModeRead, PixelFormat24bppRGB, &bd); + expect(Ok, stat); + stat = GdipDisposeImage((GpImage*)bm); + expect(Ok, stat); +} + START_TEST(image) { struct GdiplusStartupInput gdiplusStartupInput; @@ -187,6 +292,7 @@ START_TEST(image) test_GetImageDimension(); test_LoadingImages(); test_encoders(); + test_LockBits(); GdiplusShutdown(gdiplusToken); }
1
0
0
0
Nathan Beckmann : gdiplus: Fix memory leak in GdipLockBitmapBits.
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: 08d49d3e335acb5f9188af827265b955ca430d7b URL:
http://source.winehq.org/git/wine.git/?a=commit;h=08d49d3e335acb5f9188af827…
Author: Nathan Beckmann <nathan.beckmann(a)gmail.com> Date: Fri Mar 7 01:19:03 2008 -0800 gdiplus: Fix memory leak in GdipLockBitmapBits. --- dlls/gdiplus/image.c | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/dlls/gdiplus/image.c b/dlls/gdiplus/image.c index 7009197..6b827ba 100644 --- a/dlls/gdiplus/image.c +++ b/dlls/gdiplus/image.c @@ -170,8 +170,7 @@ GpStatus WINGDIPAPI GdipBitmapLockBits(GpBitmap* bitmap, GDIPCONST GpRect* rect, bitmap->lockmode = flags; bitmap->numlocks++; - if(flags & ImageLockModeWrite) - bitmap->bitmapbits = buff; + bitmap->bitmapbits = buff; return Ok; } @@ -198,7 +197,8 @@ GpStatus WINGDIPAPI GdipBitmapUnlockBits(GpBitmap* bitmap, if(!(--bitmap->numlocks)) bitmap->lockmode = 0; - GdipFree(lockeddata->Scan0); + GdipFree(bitmap->bitmapbits); + bitmap->bitmapbits = NULL; return Ok; } @@ -225,6 +225,7 @@ GpStatus WINGDIPAPI GdipBitmapUnlockBits(GpBitmap* bitmap, } GdipFree(bitmap->bitmapbits); + bitmap->bitmapbits = NULL; return Ok; } @@ -426,6 +427,8 @@ GpStatus WINGDIPAPI GdipDisposeImage(GpImage *image) IPicture_get_CurDC(image->picture, &hdc); DeleteDC(hdc); IPicture_Release(image->picture); + if (image->type == ImageTypeBitmap) + GdipFree(((GpBitmap*)image)->bitmapbits); GdipFree(image); return Ok;
1
0
0
0
Jeremy White : gdi32: Revise CreateScalableFontResourceA to pass through CreateScalableFontResourceW .
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: 5e1dd9577d41cd6a397c3da1c8c4a537dc37403a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5e1dd9577d41cd6a397c3da1c…
Author: Jeremy White <jwhite(a)winehq.org> Date: Fri Mar 7 10:11:09 2008 -0600 gdi32: Revise CreateScalableFontResourceA to pass through CreateScalableFontResourceW. --- dlls/gdi32/font.c | 64 +++++++++++++++++++++++++++++++++++++++------------- 1 files changed, 48 insertions(+), 16 deletions(-) diff --git a/dlls/gdi32/font.c b/dlls/gdi32/font.c index 7f29936..de82e70 100644 --- a/dlls/gdi32/font.c +++ b/dlls/gdi32/font.c @@ -2367,23 +2367,41 @@ BOOL WINAPI CreateScalableFontResourceA( DWORD fHidden, LPCSTR lpszFontFile, LPCSTR lpszCurrentPath ) { - HANDLE f; + LPWSTR lpszResourceFileW = NULL; + LPWSTR lpszFontFileW = NULL; + LPWSTR lpszCurrentPathW = NULL; + int len; + BOOL ret; - /* fHidden=1 - only visible for the calling app, read-only, not - * enumbered with EnumFonts/EnumFontFamilies - * lpszCurrentPath can be NULL - */ - FIXME("(%d,%s,%s,%s): stub\n", - fHidden, debugstr_a(lpszResourceFile), debugstr_a(lpszFontFile), - debugstr_a(lpszCurrentPath) ); + if (lpszResourceFile) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszResourceFile, -1, NULL, 0); + lpszResourceFileW = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszResourceFile, -1, lpszResourceFileW, len); + } - /* If the output file already exists, return the ERROR_FILE_EXISTS error as specified in MSDN */ - if ((f = CreateFileA(lpszResourceFile, 0, 0, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0)) != INVALID_HANDLE_VALUE) { - CloseHandle(f); - SetLastError(ERROR_FILE_EXISTS); - return FALSE; + if (lpszFontFile) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszFontFile, -1, NULL, 0); + lpszFontFileW = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszFontFile, -1, lpszFontFileW, len); } - return FALSE; /* create failed */ + + if (lpszCurrentPath) + { + len = MultiByteToWideChar(CP_ACP, 0, lpszCurrentPath, -1, NULL, 0); + lpszCurrentPathW = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, lpszCurrentPath, -1, lpszCurrentPathW, len); + } + + ret = CreateScalableFontResourceW(fHidden, lpszResourceFileW, + lpszFontFileW, lpszCurrentPathW); + + HeapFree(GetProcessHeap(), 0, lpszResourceFileW); + HeapFree(GetProcessHeap(), 0, lpszFontFileW); + HeapFree(GetProcessHeap(), 0, lpszCurrentPathW); + + return ret; } /*********************************************************************** @@ -2394,8 +2412,22 @@ BOOL WINAPI CreateScalableFontResourceW( DWORD fHidden, LPCWSTR lpszFontFile, LPCWSTR lpszCurrentPath ) { - FIXME("(%d,%p,%p,%p): stub\n", - fHidden, lpszResourceFile, lpszFontFile, lpszCurrentPath ); + HANDLE f; + FIXME("(%d,%s,%s,%s): stub\n", + fHidden, debugstr_w(lpszResourceFile), debugstr_w(lpszFontFile), + debugstr_w(lpszCurrentPath) ); + + /* fHidden=1 - only visible for the calling app, read-only, not + * enumbered with EnumFonts/EnumFontFamilies + * lpszCurrentPath can be NULL + */ + + /* If the output file already exists, return the ERROR_FILE_EXISTS error as specified in MSDN */ + if ((f = CreateFileW(lpszResourceFile, 0, 0, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0)) != INVALID_HANDLE_VALUE) { + CloseHandle(f); + SetLastError(ERROR_FILE_EXISTS); + return FALSE; + } return FALSE; /* create failed */ }
1
0
0
0
Tony Wasserka : d3dx9: Add the _D3DXERR enumeration.
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: bcb7311516791a2276a3054ac3d0d43129d5e18a URL:
http://source.winehq.org/git/wine.git/?a=commit;h=bcb7311516791a2276a3054ac…
Author: Tony Wasserka <tony.wasserka(a)freenet.de> Date: Sat Mar 8 14:25:15 2008 +0100 d3dx9: Add the _D3DXERR enumeration. --- include/d3dx9.h | 15 +++++++++++++++ 1 files changed, 15 insertions(+), 0 deletions(-) diff --git a/include/d3dx9.h b/include/d3dx9.h index 5d9fd5f..dce0aeb 100644 --- a/include/d3dx9.h +++ b/include/d3dx9.h @@ -25,4 +25,19 @@ #include "d3dx9math.h" #include "d3dx9core.h" +#define _FACDD 0x876 +#define MAKE_DDHRESULT(code) MAKE_HRESULT(1, _FACDD, code) + +enum _D3DXERR { + D3DXERR_CANNOTMODIFYINDEXBUFFER = MAKE_DDHRESULT(2900), + D3DXERR_INVALIDMESH = MAKE_DDHRESULT(2901), + D3DXERR_CANNOTATTRSORT = MAKE_DDHRESULT(2902), + D3DXERR_SKINNINGNOTSUPPORTED = MAKE_DDHRESULT(2903), + D3DXERR_TOOMANYINFLUENCES = MAKE_DDHRESULT(2904), + D3DXERR_INVALIDDATA = MAKE_DDHRESULT(2905), + D3DXERR_LOADEDMESHASNODATA = MAKE_DDHRESULT(2906), + D3DXERR_DUPLICATENAMEDFRAGMENT = MAKE_DDHRESULT(2907), + D3DXERR_CANNOTREMOVELASTITEM = MAKE_DDHRESULT(2908), +}; + #endif
1
0
0
0
Alexandre Julliard : msvcrt/tests: The new string functions don' t have to exist.
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: fea9fb4f476463e0fa7bc44944e1f37bdfd8dd77 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=fea9fb4f476463e0fa7bc4494…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Mon Mar 10 11:30:45 2008 +0100 msvcrt/tests: The new string functions don't have to exist. --- dlls/msvcrt/tests/string.c | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dlls/msvcrt/tests/string.c b/dlls/msvcrt/tests/string.c index 4201c5e..926a9cf 100644 --- a/dlls/msvcrt/tests/string.c +++ b/dlls/msvcrt/tests/string.c @@ -616,10 +616,10 @@ START_TEST(string) ok(hMsvcrt != 0, "GetModuleHandleA failed\n"); SET(pmemcpy,"memcpy"); SET(pmemcmp,"memcmp"); - SET(pstrcpy_s,"strcpy_s"); - SET(pstrcat_s,"strcat_s"); - SET(p_mbsnbcpy_s,"_mbsnbcpy_s"); - SET(p_wcscpy_s,"wcscpy_s"); + pstrcpy_s = (void *)GetProcAddress( hMsvcrt,"strcpy_s" ); + pstrcat_s = (void *)GetProcAddress( hMsvcrt,"strcat_s" ); + p_mbsnbcpy_s = (void *)GetProcAddress( hMsvcrt,"_mbsnbcpy_s" ); + p_wcscpy_s = (void *)GetProcAddress( hMsvcrt,"wcscpy_s" ); /* MSVCRT memcpy behaves like memmove for overlapping moves, MFC42 CString::Insert seems to rely on that behaviour */
1
0
0
0
Jacek Caban : jscript: Added stub DLL.
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: fa23a2c4b68ce2dd5d506075099949d3e476d78d URL:
http://source.winehq.org/git/wine.git/?a=commit;h=fa23a2c4b68ce2dd5d5060750…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sun Mar 9 00:07:57 2008 +0100 jscript: Added stub DLL. --- Makefile.in | 2 + configure | 3 ++ configure.ac | 1 + dlls/Makefile.in | 1 + dlls/jscript/Makefile.in | 14 +++++++ dlls/jscript/jscript.spec | 4 ++ dlls/jscript/jscript_main.c | 85 +++++++++++++++++++++++++++++++++++++++++++ 7 files changed, 110 insertions(+), 0 deletions(-) diff --git a/Makefile.in b/Makefile.in index 6b22eb0..34b4e56 100644 --- a/Makefile.in +++ b/Makefile.in @@ -288,6 +288,7 @@ ALL_MAKEFILES = \ dlls/itircl/Makefile \ dlls/itss/Makefile \ dlls/itss/tests/Makefile \ + dlls/jscript/Makefile \ dlls/kernel32/Makefile \ dlls/kernel32/tests/Makefile \ dlls/localspl/Makefile \ @@ -705,6 +706,7 @@ dlls/iphlpapi/tests/Makefile: dlls/iphlpapi/tests/Makefile.in dlls/Maketest.rule dlls/itircl/Makefile: dlls/itircl/Makefile.in dlls/Makedll.rules dlls/itss/Makefile: dlls/itss/Makefile.in dlls/Makedll.rules dlls/itss/tests/Makefile: dlls/itss/tests/Makefile.in dlls/Maketest.rules +dlls/jscript/Makefile: dlls/jscript/Makefile.in dlls/Makedll.rules dlls/kernel32/Makefile: dlls/kernel32/Makefile.in dlls/Makedll.rules dlls/kernel32/tests/Makefile: dlls/kernel32/tests/Makefile.in dlls/Maketest.rules dlls/localspl/Makefile: dlls/localspl/Makefile.in dlls/Makedll.rules diff --git a/configure b/configure index 22ab9f4..32a85c3 100755 --- a/configure +++ b/configure @@ -21438,6 +21438,8 @@ ac_config_files="$ac_config_files dlls/itss/Makefile" ac_config_files="$ac_config_files dlls/itss/tests/Makefile" +ac_config_files="$ac_config_files dlls/jscript/Makefile" + ac_config_files="$ac_config_files dlls/kernel32/Makefile" ac_config_files="$ac_config_files dlls/kernel32/tests/Makefile" @@ -22678,6 +22680,7 @@ do "dlls/itircl/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/itircl/Makefile" ;; "dlls/itss/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/itss/Makefile" ;; "dlls/itss/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/itss/tests/Makefile" ;; + "dlls/jscript/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/jscript/Makefile" ;; "dlls/kernel32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/kernel32/Makefile" ;; "dlls/kernel32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/kernel32/tests/Makefile" ;; "dlls/localspl/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/localspl/Makefile" ;; diff --git a/configure.ac b/configure.ac index c2d628b..f239a68 100644 --- a/configure.ac +++ b/configure.ac @@ -1792,6 +1792,7 @@ AC_CONFIG_FILES([dlls/iphlpapi/tests/Makefile]) AC_CONFIG_FILES([dlls/itircl/Makefile]) AC_CONFIG_FILES([dlls/itss/Makefile]) AC_CONFIG_FILES([dlls/itss/tests/Makefile]) +AC_CONFIG_FILES([dlls/jscript/Makefile]) AC_CONFIG_FILES([dlls/kernel32/Makefile]) AC_CONFIG_FILES([dlls/kernel32/tests/Makefile]) AC_CONFIG_FILES([dlls/localspl/Makefile]) diff --git a/dlls/Makefile.in b/dlls/Makefile.in index 9ed67df..1fe9309 100644 --- a/dlls/Makefile.in +++ b/dlls/Makefile.in @@ -117,6 +117,7 @@ BASEDIRS = \ iphlpapi \ itircl \ itss \ + jscript \ kernel32 \ localspl \ localui \ diff --git a/dlls/jscript/Makefile.in b/dlls/jscript/Makefile.in new file mode 100644 index 0000000..c1ce428 --- /dev/null +++ b/dlls/jscript/Makefile.in @@ -0,0 +1,14 @@ +TOPSRCDIR = @top_srcdir@ +TOPOBJDIR = ../.. +SRCDIR = @srcdir@ +VPATH = @srcdir@ +MODULE = jscript.dll +IMPORTS = kernel32 +EXTRALIBS = -luuid + +C_SRCS = \ + jscript_main.c + +@MAKE_DLL_RULES@ + +@DEPENDENCIES@ # everything below this line is overwritten by make depend diff --git a/dlls/jscript/jscript.spec b/dlls/jscript/jscript.spec new file mode 100644 index 0000000..b16365d --- /dev/null +++ b/dlls/jscript/jscript.spec @@ -0,0 +1,4 @@ +@ stdcall -private DllCanUnloadNow() +@ stdcall -private DllGetClassObject(ptr ptr ptr) +@ stdcall -private DllRegisterServer() +@ stdcall -private DllUnregisterServer() diff --git a/dlls/jscript/jscript_main.c b/dlls/jscript/jscript_main.c new file mode 100644 index 0000000..807a821 --- /dev/null +++ b/dlls/jscript/jscript_main.c @@ -0,0 +1,85 @@ +/* + * Copyright 2008 Jacek Caban for CodeWeavers + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "config.h" + +#include <stdarg.h> + +#define COBJMACROS + +#include "windef.h" +#include "winbase.h" + +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(jscript); + +/****************************************************************** + * DllMain (jscript.@) + */ +BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpv) +{ + TRACE("(%p %d %p)\n", hInstDLL, fdwReason, lpv); + + switch(fdwReason) + { + case DLL_WINE_PREATTACH: + return FALSE; /* prefer native version */ + case DLL_PROCESS_ATTACH: + DisableThreadLibraryCalls(hInstDLL); + break; + } + + return TRUE; +} + +/*********************************************************************** + * DllGetClassObject (jscript.@) + */ +HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID *ppv) +{ + FIXME("%s %s %p\n", debugstr_guid(rclsid), debugstr_guid(riid), ppv); + return CLASS_E_CLASSNOTAVAILABLE; +} + +/*********************************************************************** + * DllCanUnloadNow (jscript.@) + */ +HRESULT WINAPI DllCanUnloadNow(void) +{ + FIXME("()\n"); + return S_FALSE; +} + +/*********************************************************************** + * DllRegisterServer (jscript.@) + */ +HRESULT WINAPI DllRegisterServer(void) +{ + FIXME("()\n"); + return S_OK; +} + +/*********************************************************************** + * DllUnregisterServer (jscript.@) + */ +HRESULT WINAPI DllUnregisterServer(void) +{ + FIXME("()\n"); + return S_OK; +}
1
0
0
0
Jacek Caban : urlmon: Fixed MapUrlToZone test on IE7.
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: bbfae3deffcb395bc068ff5111f682c3cc09b584 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=bbfae3deffcb395bc068ff511…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sat Mar 8 20:15:45 2008 +0100 urlmon: Fixed MapUrlToZone test on IE7. --- dlls/urlmon/sec_mgr.c | 2 +- dlls/urlmon/tests/misc.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/dlls/urlmon/sec_mgr.c b/dlls/urlmon/sec_mgr.c index 0b56ba4..6ed72dc 100644 --- a/dlls/urlmon/sec_mgr.c +++ b/dlls/urlmon/sec_mgr.c @@ -66,7 +66,7 @@ static HRESULT map_url_to_zone(LPCWSTR url, DWORD *zone) if(FAILED(hres)) return hres; if(!*schema) - return 0x80041001; + return E_INVALIDARG; /* file protocol is a special case */ if(!strcmpW(schema, wszFile)) { diff --git a/dlls/urlmon/tests/misc.c b/dlls/urlmon/tests/misc.c index 50a40b1..01c5eaf 100644 --- a/dlls/urlmon/tests/misc.c +++ b/dlls/urlmon/tests/misc.c @@ -754,7 +754,8 @@ static void test_SecurityManager(void) zone = 100; hres = IInternetSecurityManager_MapUrlToZone(secmgr, secmgr_tests[i].url, &zone, 0); - ok(hres == secmgr_tests[i].zone_hres, + ok(hres == secmgr_tests[i].zone_hres /* IE <=6 */ + || (FAILED(secmgr_tests[i].zone_hres) && hres == E_INVALIDARG), /* IE7 */ "[%d] MapUrlToZone failed: %08x, expected %08x\n", i, hres, secmgr_tests[i].zone_hres); if(SUCCEEDED(hres))
1
0
0
0
Jacek Caban : mshtml: Use load group to find NSContainer in AsyncOpen if URI has no associated container .
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: 75fe97dc0b1447f4e731a6a1a2c15f129c339a42 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=75fe97dc0b1447f4e731a6a1a…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sat Mar 8 20:15:30 2008 +0100 mshtml: Use load group to find NSContainer in AsyncOpen if URI has no associated container. --- dlls/mshtml/nsio.c | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++- 1 files changed, 52 insertions(+), 1 deletions(-) diff --git a/dlls/mshtml/nsio.c b/dlls/mshtml/nsio.c index f684f2a..d55546d 100644 --- a/dlls/mshtml/nsio.c +++ b/dlls/mshtml/nsio.c @@ -634,6 +634,48 @@ static HRESULT create_mon_for_nschannel(nsChannel *channel, IMoniker **mon) return hres; } +static NSContainer *get_nscontainer_from_load_group(nsChannel *This) +{ + NSContainer *container; + nsIChannel *channel; + nsIRequest *req; + nsIWineURI *wine_uri; + nsIURI *uri; + nsresult nsres; + + nsres = nsILoadGroup_GetDefaultLoadRequest(This->load_group, &req); + if(NS_FAILED(nsres)) { + ERR("GetDefaultLoadRequest failed: %08x\n", nsres); + return NULL; + } + + nsres = nsIRequest_QueryInterface(req, &IID_nsIChannel, (void**)&channel); + nsIRequest_Release(req); + if(NS_FAILED(nsres)) { + WARN("Could not get nsIChannel interface: %08x\n", nsres); + return NULL; + } + + nsres = nsIChannel_GetURI(channel, &uri); + nsIChannel_Release(channel); + if(NS_FAILED(nsres)) { + ERR("GetURI failed: %08x\n", nsres); + return NULL; + } + + nsres = nsIURI_QueryInterface(uri, &IID_nsIWineURI, (void**)&wine_uri); + nsIURI_Release(uri); + if(NS_FAILED(nsres)) { + TRACE("Could not get nsIWineURI: %08x\n", nsres); + return NULL; + } + + nsIWineURI_GetNSContainer(wine_uri, &container); + nsIWineURI_Release(wine_uri); + + return container; +} + static nsresult async_open_doc_uri(nsChannel *This, NSContainer *container, nsIStreamListener *listener, nsISupports *context, BOOL *open) { @@ -774,6 +816,13 @@ static nsresult NSAPI nsChannel_AsyncOpen(nsIHttpChannel *iface, nsIStreamListen TRACE("(%p)->(%p %p)\n", This, aListener, aContext); nsIWineURI_GetNSContainer(This->uri, &container); + + if(!container && This->load_group) { + container = get_nscontainer_from_load_group(This); + if(container) + nsIWineURI_SetNSContainer(This->uri, container); + } + if(!container) { TRACE("container = NULL\n"); return This->channel @@ -2043,7 +2092,7 @@ static nsresult NSAPI nsIOService_NewURI(nsIIOService *iface, const nsACString * } nsACString_Init(&spec_str, spec); - nsres = nsIIOService_NewURI(nsio, aSpec, aOriginCharset, aBaseURI, &uri); + nsres = nsIIOService_NewURI(nsio, &spec_str, aOriginCharset, aBaseURI, &uri); nsACString_Finish(&spec_str); if(NS_FAILED(nsres)) TRACE("NewURI failed: %08x\n", nsres); @@ -2058,6 +2107,8 @@ static nsresult NSAPI nsIOService_NewURI(nsIIOService *iface, const nsACString * } } + TRACE("nscontainer = %p\n", nscontainer); + nsres = create_uri(uri, nscontainer, &wine_uri); *_retval = (nsIURI*)wine_uri;
1
0
0
0
Jacek Caban : mshtml: Added IHTMLScriptElement:get_type implementation.
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: 134dad7ecdc2113c0e7d4f43ec7f52e6ef89f9b9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=134dad7ecdc2113c0e7d4f43e…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sat Mar 8 20:14:38 2008 +0100 mshtml: Added IHTMLScriptElement:get_type implementation. --- dlls/mshtml/htmlscript.c | 25 +++++++++++++++++++++++-- dlls/mshtml/nsiface.idl | 24 ++++++++++++++++++++++++ dlls/mshtml/tests/dom.c | 19 ++++++++++++++++++- 3 files changed, 65 insertions(+), 3 deletions(-) diff --git a/dlls/mshtml/htmlscript.c b/dlls/mshtml/htmlscript.c index fa7867d..5bf4a18 100644 --- a/dlls/mshtml/htmlscript.c +++ b/dlls/mshtml/htmlscript.c @@ -39,6 +39,8 @@ typedef struct { HTMLElement element; const IHTMLScriptElementVtbl *lpHTMLScriptElementVtbl; + + nsIDOMHTMLScriptElement *nsscript; } HTMLScriptElement; #define HTMLSCRIPT(x) ((IHTMLScriptElement*) &(x)->lpHTMLScriptElementVtbl) @@ -203,8 +205,22 @@ static HRESULT WINAPI HTMLScriptElement_put_type(IHTMLScriptElement *iface, BSTR static HRESULT WINAPI HTMLScriptElement_get_type(IHTMLScriptElement *iface, BSTR *p) { HTMLScriptElement *This = HTMLSCRIPT_THIS(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + const PRUnichar *nstype; + nsAString nstype_str; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&nstype_str, NULL); + nsres = nsIDOMHTMLScriptElement_GetType(This->nsscript, &nstype_str); + if(NS_FAILED(nsres)) + ERR("GetType failed: %08x\n", nsres); + + nsAString_GetData(&nstype_str, &nstype); + *p = *nstype ? SysAllocString(nstype) : NULL; + nsAString_Finish(&nstype_str); + + return S_OK; } static const IHTMLScriptElementVtbl HTMLScriptElementVtbl = { @@ -277,11 +293,16 @@ static const NodeImplVtbl HTMLScriptElementImplVtbl = { HTMLElement *HTMLScriptElement_Create(nsIDOMHTMLElement *nselem) { HTMLScriptElement *ret = heap_alloc(sizeof(HTMLScriptElement)); + nsresult nsres; HTMLElement_Init(&ret->element); ret->lpHTMLScriptElementVtbl = &HTMLScriptElementVtbl; ret->element.node.vtbl = &HTMLScriptElementImplVtbl; + nsres = nsIDOMHTMLElement_QueryInterface(nselem, &IID_nsIDOMHTMLScriptElement, (void**)&ret->nsscript); + if(NS_FAILED(nsres)) + ERR("Could not get nsIDOMHTMLScriptElement: %08x\n", nsres); + return &ret->element; } diff --git a/dlls/mshtml/nsiface.idl b/dlls/mshtml/nsiface.idl index 2f60cda..03115d9 100644 --- a/dlls/mshtml/nsiface.idl +++ b/dlls/mshtml/nsiface.idl @@ -1273,6 +1273,30 @@ interface nsIDOMHTMLTextAreaElement : nsIDOMHTMLElement [ object, + uuid(a6cf90b1-15b3-11d2-932e-00805f8add32), + local + /* FROZEN */ +] +interface nsIDOMHTMLScriptElement : nsIDOMHTMLElement +{ + nsresult GetText(nsAString *aText); + nsresult SetText(const nsAString *aText); + nsresult GetHtmlFor(nsAString *aHtmlFor); + nsresult SetHtmlFor(const nsAString *aHtmlFor); + nsresult GetEvent(nsAString *aEvent); + nsresult SetEvent(const nsAString *aEvent); + nsresult GetCharset(nsAString *aCharset); + nsresult SetCharset(const nsAString *aCharset); + nsresult GetDefer(PRBool *aDefer); + nsresult SetDefer(PRBool aDefer); + nsresult GetSrc(nsAString *aSrc); + nsresult SetSrc(const nsAString *aSrc); + nsresult GetType(nsAString *aType); + nsresult SetType(const nsAString *aType); +} + +[ + object, uuid(94928ab3-8b63-11d3-989d-001083010e9b), local /* FROZEN */ diff --git a/dlls/mshtml/tests/dom.c b/dlls/mshtml/tests/dom.c index 60ddb6f..68a2130 100644 --- a/dlls/mshtml/tests/dom.c +++ b/dlls/mshtml/tests/dom.c @@ -43,7 +43,7 @@ static const char elem_test_str[] = "<select id=\"s\"><option id=\"x\">opt1</option><option id=\"y\">opt2</option></select>" "<textarea id=\"X\">text text</textarea>" "<table><tbody></tbody></table>" - "<script type=\"text/javascript\"></script>" + "<script id=\"sc\" type=\"text/javascript\"></script>" "</body></html>"; static const char indent_test_str[] = "<html><head><title>test</title></head><body>abc<br /><a href=\"about:blank\">123</a></body></html>"; @@ -54,6 +54,8 @@ static WCHAR characterW[] = {'c','h','a','r','a','c','t','e','r',0}; static WCHAR texteditW[] = {'t','e','x','t','e','d','i','t',0}; static WCHAR wordW[] = {'w','o','r','d',0}; +static const WCHAR text_javascriptW[] = {'t','e','x','t','/','j','a','v','a','s','c','r','i','p','t',0}; + typedef enum { ET_NONE, ET_HTML, @@ -1193,6 +1195,7 @@ static void test_elems(IHTMLDocument2 *doc) static const WCHAR xW[] = {'x',0}; static const WCHAR sW[] = {'s',0}; + static const WCHAR scW[] = {'s','c',0}; static const WCHAR xxxW[] = {'x','x','x',0}; static const elem_type_t all_types[] = { @@ -1250,6 +1253,20 @@ static void test_elems(IHTMLDocument2 *doc) IHTMLElement_Release(elem); } + elem = get_elem_by_id(doc, scW, TRUE); + if(elem) { + IHTMLScriptElement *script; + BSTR type; + + hres = IHTMLElement_QueryInterface(elem, &IID_IHTMLScriptElement, (void**)&script); + ok(hres == S_OK, "Could not get IHTMLScriptElement interface: %08x\n", hres); + + hres = IHTMLScriptElement_get_type(script, &type); + ok(hres == S_OK, "get_type failed: %08x\n", hres); + ok(!lstrcmpW(type, text_javascriptW), "Unexpected type %s\n", dbgstr_w(type)); + SysFreeString(type); + } + test_stylesheets(doc); test_create_option_elem(doc); }
1
0
0
0
Andrew Talbot : ntdll: Assign to structs instead of using memcpy.
by Alexandre Julliard
10 Mar '08
10 Mar '08
Module: wine Branch: master Commit: 5ecd33e2f9910090a3ecebcb354e62f246e60de7 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=5ecd33e2f9910090a3ecebcb3…
Author: Andrew Talbot <andrew.talbot(a)talbotville.com> Date: Sat Mar 8 15:37:05 2008 +0000 ntdll: Assign to structs instead of using memcpy. --- dlls/ntdll/reg.c | 2 +- dlls/ntdll/sec.c | 4 ++-- dlls/ntdll/time.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dlls/ntdll/reg.c b/dlls/ntdll/reg.c index 9c9509d..9d9de0e 100644 --- a/dlls/ntdll/reg.c +++ b/dlls/ntdll/reg.c @@ -96,7 +96,7 @@ NTSTATUS WINAPI RtlpNtCreateKey( PHANDLE retkey, ACCESS_MASK access, const OBJEC if (attr) { - memcpy( &oa, attr, sizeof oa ); + oa = *attr; oa.Attributes &= ~(OBJ_PERMANENT|OBJ_EXCLUSIVE); attr = &oa; } diff --git a/dlls/ntdll/sec.c b/dlls/ntdll/sec.c index ea24414..79a356b 100644 --- a/dlls/ntdll/sec.c +++ b/dlls/ntdll/sec.c @@ -158,7 +158,7 @@ NTSTATUS WINAPI RtlAllocateAndInitializeSid ( tmp_sid->Revision = SID_REVISION; if (pIdentifierAuthority) - memcpy(&tmp_sid->IdentifierAuthority, pIdentifierAuthority, sizeof(SID_IDENTIFIER_AUTHORITY)); + tmp_sid->IdentifierAuthority = *pIdentifierAuthority; tmp_sid->SubAuthorityCount = nSubAuthorityCount; switch( nSubAuthorityCount ) @@ -302,7 +302,7 @@ BOOL WINAPI RtlInitializeSid( pisid->Revision = SID_REVISION; pisid->SubAuthorityCount = nSubAuthorityCount; if (pIdentifierAuthority) - memcpy(&pisid->IdentifierAuthority, pIdentifierAuthority, sizeof (SID_IDENTIFIER_AUTHORITY)); + pisid->IdentifierAuthority = *pIdentifierAuthority; for (i = 0; i < nSubAuthorityCount; i++) *RtlSubAuthoritySid(pSid, i) = 0; diff --git a/dlls/ntdll/time.c b/dlls/ntdll/time.c index cd23958..e6e4ed2 100644 --- a/dlls/ntdll/time.c +++ b/dlls/ntdll/time.c @@ -684,7 +684,7 @@ static void find_reg_tz_info(RTL_TIME_ZONE_INFORMATION *tzi) if (match_tz_info(tzi, ®_tzi)) { - memcpy(tzi, ®_tzi, sizeof(*tzi)); + *tzi = reg_tzi; NtClose(hkey); return; }
1
0
0
0
← Newer
1
...
75
76
77
78
79
80
81
...
101
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
Results per page:
10
25
50
100
200