ReactOS.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
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
List overview
Download
Ros-diffs
December 2008
----- 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
ros-diffs@reactos.org
31 participants
710 discussions
Start a n
N
ew thread
[cwittich] 38414: sync lz32 winetest to wine 1.1.11
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 05:24:41 2008 New Revision: 38414 URL:
http://svn.reactos.org/svn/reactos?rev=38414&view=rev
Log: sync lz32 winetest to wine 1.1.11 Modified: trunk/rostests/winetests/lz32/lzexpand_main.c Modified: trunk/rostests/winetests/lz32/lzexpand_main.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/lz32/lzexpand_m…
============================================================================== --- trunk/rostests/winetests/lz32/lzexpand_main.c [iso-8859-1] (original) +++ trunk/rostests/winetests/lz32/lzexpand_main.c [iso-8859-1] Sun Dec 28 05:24:41 2008 @@ -230,7 +230,8 @@ /* d, using underscore-terminated file name. */ file = LZOpenFileA(_terminated, &test, OF_EXIST); ok(file >= 0, "LZOpenFileA failed on switching to a compressed file name\n"); - ok(test.cBytes == sizeof(OFSTRUCT), + ok(test.cBytes == sizeof(OFSTRUCT) || + broken(test.cBytes == 40), /* win95 */ "LZOpenFileA set test.cBytes to %d\n", test.cBytes); ok(test.nErrCode == 0, "LZOpenFileA set test.nErrCode to %d\n", test.nErrCode); @@ -370,7 +371,7 @@ ok(test.cBytes == sizeof(OFSTRUCT), "LZOpenFileA set test.cBytes to %d\n", test.cBytes); ok(test.nErrCode == ERROR_SUCCESS || - test.nErrCode == ERROR_FILE_NOT_FOUND, /* win9x */ + broken(test.nErrCode != ERROR_SUCCESS), /* win9x */ "LZOpenFileA set test.nErrCode to %d\n", test.nErrCode); ok(lstrcmpA(test.szPathName, expected) == 0, "LZOpenFileA returned '%s', but was expected to return '%s'\n", @@ -388,7 +389,8 @@ /* a, for reading. */ file = LZOpenFileA(filename_, &test, OF_READ); ok(file >= 0, "LZOpenFileA failed on read\n"); - ok(test.cBytes == sizeof(OFSTRUCT), + ok(test.cBytes == sizeof(OFSTRUCT) || + broken(test.cBytes == 40), /* win95 */ "LZOpenFileA set test.cBytes to %d\n", test.cBytes); ok(test.nErrCode == ERROR_SUCCESS, "LZOpenFileA set test.nErrCode to %d\n", test.nErrCode); @@ -403,7 +405,8 @@ /* b, for writing. */ file = LZOpenFileA(filename_, &test, OF_WRITE); ok(file >= 0, "LZOpenFileA failed on write\n"); - ok(test.cBytes == sizeof(OFSTRUCT), + ok(test.cBytes == sizeof(OFSTRUCT) || + broken(test.cBytes == 40), /* win95 */ "LZOpenFileA set test.cBytes to %d\n", test.cBytes); ok(test.nErrCode == ERROR_SUCCESS, "LZOpenFileA set test.nErrCode to %d\n", test.nErrCode); @@ -418,7 +421,8 @@ /* c, for reading and writing. */ file = LZOpenFileA(filename_, &test, OF_READWRITE); ok(file >= 0, "LZOpenFileA failed on read/write\n"); - ok(test.cBytes == sizeof(OFSTRUCT), + ok(test.cBytes == sizeof(OFSTRUCT) || + broken(test.cBytes == 40), /* win95 */ "LZOpenFileA set test.cBytes to %d\n", test.cBytes); ok(test.nErrCode == ERROR_SUCCESS, "LZOpenFileA set test.nErrCode to %d\n", test.nErrCode); @@ -433,7 +437,8 @@ /* d, for checking file existence. */ file = LZOpenFileA(filename_, &test, OF_EXIST); ok(file >= 0, "LZOpenFileA failed on read/write\n"); - ok(test.cBytes == sizeof(OFSTRUCT), + ok(test.cBytes == sizeof(OFSTRUCT) || + broken(test.cBytes == 40), /* win95 */ "LZOpenFileA set test.cBytes to %d\n", test.cBytes); ok(test.nErrCode == ERROR_SUCCESS, "LZOpenFileA set test.nErrCode to %d\n", test.nErrCode); @@ -448,7 +453,8 @@ /* Delete the file then make sure it doesn't exist anymore. */ file = LZOpenFileA(filename_, &test, OF_DELETE); ok(file >= 0, "LZOpenFileA failed on delete\n"); - ok(test.cBytes == sizeof(OFSTRUCT), + ok(test.cBytes == sizeof(OFSTRUCT) || + broken(test.cBytes == 40), /* win95 */ "LZOpenFileA set test.cBytes to %d\n", test.cBytes); ok(test.nErrCode == ERROR_SUCCESS, "LZOpenFileA set test.nErrCode to %d\n", test.nErrCode); @@ -764,13 +770,13 @@ SetLastError(0xfaceabee); /* Check for nonexistent file. */ file = LZOpenFileW(badfilenameW, &test, OF_READ); - ok(GetLastError() == ERROR_FILE_NOT_FOUND || GetLastError() == ERROR_CALL_NOT_IMPLEMENTED, - "GetLastError() returns %d\n", GetLastError()); if(GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) { - trace("LZOpenFileW call not implemented, skipping rest of the test\n"); + win_skip("LZOpenFileW call is not implemented\n"); return; } + ok(GetLastError() == ERROR_FILE_NOT_FOUND, + "GetLastError() returns %d\n", GetLastError()); ok(file == LZERROR_BADINHANDLE, "LZOpenFileW succeeded on nonexistent file\n"); LZClose(file);
15 years, 12 months
1
0
0
0
[cwittich] 38413: sync mstask winetest to wine 1.1.11
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 05:22:23 2008 New Revision: 38413 URL:
http://svn.reactos.org/svn/reactos?rev=38413&view=rev
Log: sync mstask winetest to wine 1.1.11 Modified: trunk/rostests/winetests/mstask/task.c Modified: trunk/rostests/winetests/mstask/task.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/mstask/task.c?r…
============================================================================== --- trunk/rostests/winetests/mstask/task.c [iso-8859-1] (original) +++ trunk/rostests/winetests/mstask/task.c [iso-8859-1] Sun Dec 28 05:22:23 2008 @@ -121,7 +121,7 @@ ok(hres == S_OK, "GetApplicationName failed: %08x\n", hres); if (hres == S_OK) { - ok(!lstrcmpW(stored_name, empty), + ok(!lstrcmpiW(stored_name, empty), "Got %s, expected empty string\n", dbgstr_w(stored_name)); CoTaskMemFree(stored_name); } @@ -136,7 +136,7 @@ if (hres == S_OK) { full_name = path_resolve_name(non_application_name); - ok(!lstrcmpW(stored_name, full_name), "Got %s, expected %s\n", + ok(!lstrcmpiW(stored_name, full_name), "Got %s, expected %s\n", dbgstr_w(stored_name), dbgstr_w(full_name)); CoTaskMemFree(stored_name); } @@ -151,7 +151,7 @@ if (hres == S_OK) { full_name = path_resolve_name(notepad_exe); - ok(!lstrcmpW(stored_name, full_name), "Got %s, expected %s\n", + ok(!lstrcmpiW(stored_name, full_name), "Got %s, expected %s\n", dbgstr_w(stored_name), dbgstr_w(full_name)); CoTaskMemFree(stored_name); } @@ -164,9 +164,13 @@ ok(hres == S_OK, "GetApplicationName failed: %08x\n", hres); if (hres == S_OK) { - full_name = path_resolve_name(notepad); - ok(!lstrcmpW(stored_name, full_name), "Got %s, expected %s\n", - dbgstr_w(stored_name), dbgstr_w(full_name)); + full_name = path_resolve_name(notepad_exe); /* XP SP1 appends .exe */ + if (lstrcmpiW(stored_name, full_name) != 0) + { + full_name = path_resolve_name(notepad); + ok(!lstrcmpiW(stored_name, full_name), "Got %s, expected %s\n", + dbgstr_w(stored_name), dbgstr_w(full_name)); + } CoTaskMemFree(stored_name); } @@ -181,7 +185,7 @@ if (hres == S_OK) { full_name = path_resolve_name(non_application_name); - ok(!lstrcmpW(stored_name, full_name), "Got %s, expected %s\n", + ok(!lstrcmpiW(stored_name, full_name), "Got %s, expected %s\n", dbgstr_w(stored_name), dbgstr_w(full_name)); CoTaskMemFree(stored_name); } @@ -193,7 +197,7 @@ ok(hres == S_OK, "GetApplicationName failed: %08x\n", hres); if (hres == S_OK) { - ok(!lstrcmpW(stored_name, empty), + ok(!lstrcmpiW(stored_name, empty), "Got %s, expected empty string\n", dbgstr_w(stored_name)); CoTaskMemFree(stored_name); } @@ -466,7 +470,10 @@ ok(hres == S_OK, "Failed setting dummy account with no password: %08x\n", hres); hres = ITask_GetAccountInformation(test_task, &account_name); - ok(hres == S_OK, "GetAccountInformation failed: %08x\n", hres); + ok(hres == S_OK || + broken(hres == HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) || + hres == SCHED_E_CANNOT_OPEN_TASK), + "GetAccountInformation failed: %08x\n", hres); if (hres == S_OK) { ok(!lstrcmpW(account_name, dummy_account_name), @@ -482,7 +489,10 @@ ok(hres == S_OK, "Failed setting dummy account with password: %08x\n", hres); hres = ITask_GetAccountInformation(test_task, &account_name); - ok(hres == S_OK, "GetAccountInformation failed: %08x\n", hres); + ok(hres == S_OK || + broken(hres == HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) || + hres == SCHED_E_CANNOT_OPEN_TASK), + "GetAccountInformation failed: %08x\n", hres); if (hres == S_OK) { ok(!lstrcmpW(account_name, dummy_account_name_b), @@ -495,7 +505,10 @@ hres = ITask_SetAccountInformation(test_task, empty, NULL); ok(hres == S_OK, "Failed setting system account: %08x\n", hres); hres = ITask_GetAccountInformation(test_task, &account_name); - ok(hres == S_OK, "GetAccountInformation failed: %08x\n", hres); + ok(hres == S_OK || + broken(hres == HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) || + hres == SCHED_E_CANNOT_OPEN_TASK), + "GetAccountInformation failed: %08x\n", hres); if (hres == S_OK) { ok(!lstrcmpW(account_name, empty),
15 years, 12 months
1
0
0
0
[silverblade] 38412: Misc. code changes I forgot to commit previously. Just wanted to get this into the branch before I do more work on this.
by silverblade@svn.reactos.org
Author: silverblade Date: Sun Dec 28 04:53:31 2008 New Revision: 38412 URL:
http://svn.reactos.org/svn/reactos?rev=38412&view=rev
Log: Misc. code changes I forgot to commit previously. Just wanted to get this into the branch before I do more work on this. Added: branches/silverblade-audio/lib/drivers/sound/mmebuddy/capabilities.c (with props) branches/silverblade-audio/lib/drivers/sound/mmebuddy/functiontable.c (with props) branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/format.c (with props) Modified: branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h branches/silverblade-audio/lib/drivers/sound/mmebuddy/auxiliary/auxMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/deviceinstance.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/midi/midMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/midi/modMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/mixer/mxdMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/widMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wodMessage.c Modified: branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/include/react…
============================================================================== --- branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h [iso-8859-1] (original) +++ branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -127,6 +127,7 @@ typedef UCHAR MMDEVICE_TYPE, *PMMDEVICE_TYPE; struct _SOUND_DEVICE; +struct _SOUND_DEVICE_INSTANCE; #define DEFINE_GETCAPS_FUNCTYPE(func_typename, caps_type) \ @@ -144,32 +145,29 @@ DEFINE_GETCAPS_FUNCTYPE(MMGETMIDIOUTCAPS_FUNC, LPMIDIOUTCAPS); DEFINE_GETCAPS_FUNCTYPE(MMGETMIDIINCAPS_FUNC, LPMIDIINCAPS ); +typedef MMRESULT (*MMWAVEQUERYFORMATSUPPORT_FUNC)( + IN struct _SOUND_DEVICE* Device, + IN PWAVEFORMATEX WaveFormat, + IN DWORD WaveFormatSize); + +typedef MMRESULT (*MMWAVESETFORMAT_FUNC)( + IN struct _SOUND_DEVICE_INSTANCE* Instance, + IN PWAVEFORMATEX WaveFormat, + IN DWORD WaveFormatSize); + typedef struct _MMFUNCTION_TABLE { union { - MMGETCAPS_FUNC GetCapabilities; - MMGETWAVEOUTCAPS_FUNC GetWaveOutCapabilities; - MMGETWAVEINCAPS_FUNC GetWaveInCapabilities; - MMGETMIDIOUTCAPS_FUNC GetMidiOutCapabilities; - MMGETMIDIINCAPS_FUNC GetMidiInCapabilities; + MMGETCAPS_FUNC GetCapabilities; + MMGETWAVEOUTCAPS_FUNC GetWaveOutCapabilities; + MMGETWAVEINCAPS_FUNC GetWaveInCapabilities; + MMGETMIDIOUTCAPS_FUNC GetMidiOutCapabilities; + MMGETMIDIINCAPS_FUNC GetMidiInCapabilities; }; -/* - MMCREATEINSTANCE_FUNC Constructor; - MMDESTROYINSTANCE_FUNC Destructor; - MMGETCAPS_FUNC GetCapabilities; - - MMWAVEQUERYFORMAT_FUNC QueryWaveFormat; - MMWAVESETFORMAT_FUNC SetWaveFormat; - MMWAVEQUEUEBUFFER_FUNC QueueWaveBuffer; - - MMGETWAVESTATE_FUNC GetWaveDeviceState; - MMSETWAVESTATE_FUNC PauseWaveDevice; - MMSETWAVESTATE_FUNC RestartWaveDevice; - MMSETWAVESTATE_FUNC ResetWaveDevice; - MMSETWAVESTATE_FUNC BreakWaveDeviceLoop; -*/ + MMWAVEQUERYFORMATSUPPORT_FUNC QueryWaveFormatSupport; + MMWAVESETFORMAT_FUNC SetWaveFormat; } MMFUNCTION_TABLE, *PMMFUNCTION_TABLE; typedef struct _SOUND_DEVICE @@ -299,6 +297,24 @@ IsValidSoundDeviceInstance( IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance); +MMRESULT +CreateSoundDeviceInstance( + IN PSOUND_DEVICE SoundDevice, + OUT PSOUND_DEVICE_INSTANCE* SoundDeviceInstance); + +MMRESULT +DestroySoundDeviceInstance( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance); + +MMRESULT +DestroyAllSoundDeviceInstances( + IN PSOUND_DEVICE SoundDevice); + +MMRESULT +GetSoundDeviceFromInstance( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance, + OUT PSOUND_DEVICE* SoundDevice); + /* nt4.c @@ -358,6 +374,35 @@ MMRESULT TranslateInternalMmResult( IN MMRESULT Result); + + +/* + wave/format.c +*/ + +MMRESULT +QueryWaveDeviceFormatSupport( + IN PSOUND_DEVICE SoundDevice, + IN LPWAVEFORMATEX Format, + IN DWORD FormatSize); + +MMRESULT +DefaultQueryWaveDeviceFormatSupport( + IN PSOUND_DEVICE SoundDevice, + IN LPWAVEFORMATEX Format, + IN DWORD FormatSize); + +MMRESULT +SetWaveDeviceFormat( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance, + IN LPWAVEFORMATEX Format, + IN DWORD FormatSize); + +MMRESULT +DefaultSetWaveDeviceFormat( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance, + IN LPWAVEFORMATEX Format, + IN DWORD FormatSize); /* Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/auxiliary/auxMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/auxiliary/auxMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/auxiliary/auxMessage.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -41,7 +41,18 @@ Result = GetSoundDeviceCount(AUX_DEVICE_TYPE); break; } + + case AUXDM_GETDEVCAPS : + { + Result = MmeGetSoundDeviceCapabilities(AUX_DEVICE_TYPE, + DeviceId, + (PVOID) Parameter1, + Parameter2); + break; + } } + + SND_TRACE(L"auxMessage returning MMRESULT %d\n", Result); ReleaseEntrypointMutex(AUX_DEVICE_TYPE); Added: branches/silverblade-audio/lib/drivers/sound/mmebuddy/capabilities.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/capabilities.c (added) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/capabilities.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -1,0 +1,207 @@ +/* + * PROJECT: ReactOS Sound System "MME Buddy" Library + * LICENSE: GPL - See COPYING in the top level directory + * FILE: lib/sound/mmebuddy/capabilities.c + * + * PURPOSE: Queries sound devices for their capabilities. + * + * PROGRAMMERS: Andrew Greenwood (silverblade(a)reactos.org) +*/ + +#include <windows.h> +#include <mmsystem.h> +#include <ntddk.h> +#include <ntddsnd.h> +#include <mmebuddy.h> + +/* + This is a helper function to alleviate some of the repetition involved with + implementing the various MME message functions. +*/ +MMRESULT +MmeGetSoundDeviceCapabilities( + IN MMDEVICE_TYPE DeviceType, + IN DWORD DeviceId, + IN PVOID Capabilities, + IN DWORD CapabilitiesSize) +{ + PSOUND_DEVICE SoundDevice; + MMRESULT Result; + + SND_TRACE(L"MME *_GETCAPS for device %d of type %d\n", DeviceId, DeviceType); + + /* Our parameter checks are done elsewhere */ + Result = GetSoundDevice(DeviceType, DeviceId, &SoundDevice); + + if ( Result != MMSYSERR_NOERROR ) + return Result; + + return GetSoundDeviceCapabilities(SoundDevice, + Capabilities, + CapabilitiesSize); +} + +/* + Obtains the capabilities of a sound device. This routine ensures that the + supplied CapabilitiesSize parameter at least meets the minimum size of the + relevant capabilities structure. + + Ultimately, it will call the GetCapabilities function specified in the + sound device's function table. Note that there are several of these, in a + union. This is simply to avoid manually typecasting when implementing the + functions. +*/ +MMRESULT +GetSoundDeviceCapabilities( + IN PSOUND_DEVICE SoundDevice, + OUT PVOID Capabilities, + IN DWORD CapabilitiesSize) +{ + MMDEVICE_TYPE DeviceType; + PMMFUNCTION_TABLE FunctionTable; + BOOLEAN GoodSize = FALSE; + MMRESULT Result; + + VALIDATE_MMSYS_PARAMETER( IsValidSoundDevice(SoundDevice) ); + VALIDATE_MMSYS_PARAMETER( Capabilities ); + VALIDATE_MMSYS_PARAMETER( CapabilitiesSize > 0 ); + + /* Obtain the device type */ + Result = GetSoundDeviceType(SoundDevice, &DeviceType); + SND_ASSERT( Result == MMSYSERR_NOERROR ); + + if ( Result != MMSYSERR_NOERROR ) + return TranslateInternalMmResult(Result); + + /* Obtain the function table */ + Result = GetSoundDeviceFunctionTable(SoundDevice, &FunctionTable); + SND_ASSERT( Result == MMSYSERR_NOERROR ); + + if ( Result != MMSYSERR_NOERROR ) + return TranslateInternalMmResult(Result); + + /* Check that the capabilities structure is of a valid size */ + switch ( DeviceType ) + { + case WAVE_OUT_DEVICE_TYPE : + { + GoodSize = CapabilitiesSize >= sizeof(WAVEOUTCAPS); + break; + } + case WAVE_IN_DEVICE_TYPE : + { + GoodSize = CapabilitiesSize >= sizeof(WAVEINCAPS); + break; + } + case MIDI_OUT_DEVICE_TYPE : + { + GoodSize = CapabilitiesSize >= sizeof(MIDIOUTCAPS); + break; + } + case MIDI_IN_DEVICE_TYPE : + { + GoodSize = CapabilitiesSize >= sizeof(MIDIINCAPS); + break; + } + /* TODO: Others... */ + default : + { + SND_ASSERT(FALSE); + } + }; + + if ( ! GoodSize ) + { + SND_ERR(L"Device capabilities structure too small\n"); + return MMSYSERR_INVALPARAM; + } + + /* Call the "get capabilities" function within the function table */ + SND_ASSERT( FunctionTable->GetCapabilities ); + + if ( ! FunctionTable->GetCapabilities ) + return MMSYSERR_NOTSUPPORTED; + + return FunctionTable->GetCapabilities(SoundDevice, + Capabilities, + CapabilitiesSize); +} + +/* + Provides a default implementation for the "get capabilities" request, + using the standard IOCTLs used by NT4 sound drivers. +*/ +MMRESULT +DefaultGetSoundDeviceCapabilities( + IN PSOUND_DEVICE SoundDevice, + OUT PVOID Capabilities, + IN DWORD CapabilitiesSize) +{ + MMRESULT Result; + MMDEVICE_TYPE DeviceType; + PWSTR DevicePath; + DWORD IoCtl; + DWORD BytesTransferred; + HANDLE DeviceHandle; + + /* If these are bad there's an internal error with MME-Buddy! */ + SND_ASSERT( SoundDevice ); + SND_ASSERT( Capabilities ); + SND_ASSERT( CapabilitiesSize > 0 ); + + SND_TRACE(L"Default get-capabilities routine called\n"); + + /* Get the device type */ + Result = GetSoundDeviceType(SoundDevice, &DeviceType); + SND_ASSERT( Result == MMSYSERR_NOERROR ); + + if ( Result != MMSYSERR_NOERROR ); + return TranslateInternalMmResult(Result); + + /* Get the device path */ + Result = GetSoundDevicePath(SoundDevice, &DevicePath); + SND_ASSERT( Result == MMSYSERR_NOERROR ); + + if ( Result != MMSYSERR_NOERROR ); + return TranslateInternalMmResult(Result); + + /* Choose the appropriate IOCTL */ + if ( IS_WAVE_DEVICE_TYPE(DeviceType) ) + { + IoCtl = IOCTL_WAVE_GET_CAPABILITIES; + } + else if ( IS_MIDI_DEVICE_TYPE(DeviceType) ) + { + IoCtl = IOCTL_MIDI_GET_CAPABILITIES; + } + else + { + /* TODO */ + SND_ASSERT( FALSE ); + } + + /* Get the capabilities information from the driver */ + Result = OpenKernelSoundDeviceByName(DevicePath, TRUE, &DeviceHandle); + + if ( Result != MMSYSERR_NOERROR ) + { + SND_ERR(L"Failed to open %wS\n", DevicePath); + return TranslateInternalMmResult(Result); + } + + Result = QueryDevice(DeviceHandle, + IoCtl, + Capabilities, + CapabilitiesSize, + &BytesTransferred, + NULL); + + CloseKernelSoundDevice(DeviceHandle); + + if ( Result != MMSYSERR_NOERROR ) + { + SND_ERR(L"Retrieval of capabilities information failed\n"); + } + + return Result; +} Propchange: branches/silverblade-audio/lib/drivers/sound/mmebuddy/capabilities.c ------------------------------------------------------------------------------ svn:eol-style = native Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/deviceinstance.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/deviceinstance.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/deviceinstance.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -9,12 +9,86 @@ */ #include <windows.h> +#include <mmsystem.h> #include <mmebuddy.h> + +MMRESULT +AllocateSoundDeviceInstance( + OUT PSOUND_DEVICE_INSTANCE* SoundDeviceInstance) +{ + PSOUND_DEVICE_INSTANCE NewInstance; + + VALIDATE_MMSYS_PARAMETER( SoundDeviceInstance ); + + /* Allocate memory for the new instance */ + NewInstance = AllocateStruct(SOUND_DEVICE_INSTANCE); + + if ( ! NewInstance ) + return MMSYSERR_NOMEM; + + /* Provide the caller with the new instance pointer */ + *SoundDeviceInstance = NewInstance; + + return MMSYSERR_NOERROR; +} + +VOID +FreeSoundDeviceInstance( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance) +{ + SND_ASSERT( SoundDeviceInstance ); + FreeMemory(SoundDeviceInstance); +} BOOLEAN IsValidSoundDeviceInstance( IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance) { - /* TODO */ - return TRUE; + /* TODO - do this better */ + return ( SoundDeviceInstance != NULL ); } + +MMRESULT +ListSoundDeviceInstance( + IN PSOUND_DEVICE SoundDevice, + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance) +{ + return MMSYSERR_NOTSUPPORTED; +} + +MMRESULT +UnlistSoundDeviceInstance( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance) +{ + return MMSYSERR_NOTSUPPORTED; +} + +MMRESULT +CreateSoundDeviceInstance( + IN PSOUND_DEVICE SoundDevice, + OUT PSOUND_DEVICE_INSTANCE* SoundDeviceInstance) +{ + return MMSYSERR_NOTSUPPORTED; +} + +MMRESULT +DestroySoundDeviceInstance( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance) +{ + return MMSYSERR_NOTSUPPORTED; +} + +MMRESULT +DestroyAllSoundDeviceInstances( + IN PSOUND_DEVICE SoundDevice) +{ + return MMSYSERR_NOTSUPPORTED; +} + +MMRESULT +GetSoundDeviceFromInstance( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance, + OUT PSOUND_DEVICE* SoundDevice) +{ + return MMSYSERR_NOTSUPPORTED; +} Added: branches/silverblade-audio/lib/drivers/sound/mmebuddy/functiontable.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/functiontable.c (added) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/functiontable.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -1,0 +1,78 @@ +/* + * PROJECT: ReactOS Sound System "MME Buddy" Library + * LICENSE: GPL - See COPYING in the top level directory + * FILE: lib/sound/mmebuddy/functiontable.c + * + * PURPOSE: Routes function calls through a function table, calling + * implementation-defined routines or a default function, depending + * on configuration. + * + * PROGRAMMERS: Andrew Greenwood (silverblade(a)reactos.org) +*/ + +#include <windows.h> +#include <mmebuddy.h> + +/* + Attaches a function table to a sound device. Any NULL entries in this + table are automatically set to point to a default routine to handle + the appropriate function. If NULL is passed as the function table itself, + the entire function table will use only the default routines. +*/ +MMRESULT +SetSoundDeviceFunctionTable( + IN PSOUND_DEVICE SoundDevice, + IN PMMFUNCTION_TABLE FunctionTable OPTIONAL) +{ + VALIDATE_MMSYS_PARAMETER( IsValidSoundDevice(SoundDevice) ); + /*VALIDATE_MMSYS_PARAMETER( FunctionTable );*/ + + /* Zero out the existing function table (if present) */ + ZeroMemory(&SoundDevice->FunctionTable, sizeof(MMFUNCTION_TABLE)); + + /* Fill in the client-supplied functions, if provided */ + if ( FunctionTable ) + { + CopyMemory(&SoundDevice->FunctionTable, + FunctionTable, + sizeof(MMFUNCTION_TABLE)); + } + + /* Plug any gaps in the function table */ + if ( ! SoundDevice->FunctionTable.GetCapabilities ) + { + SoundDevice->FunctionTable.GetCapabilities = + DefaultGetSoundDeviceCapabilities; + } + + if ( ! SoundDevice->FunctionTable.QueryWaveFormatSupport ) + { + SoundDevice->FunctionTable.QueryWaveFormatSupport = + DefaultQueryWaveDeviceFormatSupport; + } + + if ( ! SoundDevice->FunctionTable.SetWaveFormat ) + { + SoundDevice->FunctionTable.SetWaveFormat = + DefaultSetWaveDeviceFormat; + } + + return MMSYSERR_NOERROR; +} + +/* + Retrieves the function table for a sound device, as previously set using + SetSoundDeviceFunctionTable. +*/ +MMRESULT +GetSoundDeviceFunctionTable( + IN PSOUND_DEVICE SoundDevice, + OUT PMMFUNCTION_TABLE* FunctionTable) +{ + VALIDATE_MMSYS_PARAMETER( IsValidSoundDevice(SoundDevice) ); + VALIDATE_MMSYS_PARAMETER( FunctionTable ); + + *FunctionTable = &SoundDevice->FunctionTable; + + return MMSYSERR_NOERROR; +} Propchange: branches/silverblade-audio/lib/drivers/sound/mmebuddy/functiontable.c ------------------------------------------------------------------------------ svn:eol-style = native Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/midi/midMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/midi/midMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/midi/midMessage.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -41,7 +41,18 @@ Result = GetSoundDeviceCount(MIDI_IN_DEVICE_TYPE); break; } + + case MIDM_GETDEVCAPS : + { + Result = MmeGetSoundDeviceCapabilities(MIDI_IN_DEVICE_TYPE, + DeviceId, + (PVOID) Parameter1, + Parameter2); + break; + } } + + SND_TRACE(L"midMessage returning MMRESULT %d\n", Result); ReleaseEntrypointMutex(MIDI_IN_DEVICE_TYPE); Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/midi/modMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/midi/modMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/midi/modMessage.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -41,7 +41,18 @@ Result = GetSoundDeviceCount(MIDI_OUT_DEVICE_TYPE); break; } + + case MODM_GETDEVCAPS : + { + Result = MmeGetSoundDeviceCapabilities(MIDI_OUT_DEVICE_TYPE, + DeviceId, + (PVOID) Parameter1, + Parameter2); + break; + } } + + SND_TRACE(L"modMessage returning MMRESULT %d\n", Result); ReleaseEntrypointMutex(MIDI_OUT_DEVICE_TYPE); Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/mixer/mxdMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/mixer/mxdMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/mixer/mxdMessage.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -41,7 +41,18 @@ Result = GetSoundDeviceCount(MIXER_DEVICE_TYPE); break; } + + case MXDM_GETDEVCAPS : + { + Result = MmeGetSoundDeviceCapabilities(MIXER_DEVICE_TYPE, + DeviceId, + (PVOID) Parameter1, + Parameter2); + break; + } } + + SND_TRACE(L"mxdMessage returning MMRESULT %d\n", Result); ReleaseEntrypointMutex(MIXER_DEVICE_TYPE); Added: branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/format.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/format.c (added) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/format.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -1,0 +1,59 @@ +/* + * PROJECT: ReactOS Sound System "MME Buddy" Library + * LICENSE: GPL - See COPYING in the top level directory + * FILE: lib/sound/mmebuddy/wave/format.c + * + * PURPOSE: Queries and sets wave device format (sample rate, etc.) + * + * PROGRAMMERS: Andrew Greenwood (silverblade(a)reactos.org) +*/ + +#include <windows.h> +#include <mmsystem.h> +#include <ntddk.h> +#include <ntddsnd.h> +#include <mmebuddy.h> + +MMRESULT +QueryWaveDeviceFormatSupport( + IN PSOUND_DEVICE SoundDevice, + IN LPWAVEFORMATEX Format, + IN DWORD FormatSize) +{ + MMRESULT Result; + MMDEVICE_TYPE DeviceType; + MMFUNCTION_TABLE FunctionTable; + + SND_TRACE(L"Querying wave format support\n"); + + VALIDATE_MMSYS_PARAMETER( IsValidSoundDevice(SoundDevice) ); + VALIDATE_MMSYS_PARAMETER( Format ); + VALIDATE_MMSYS_PARAMETER( FormatSize >= sizeof(WAVEFORMATEX) ); + + Result = GetSoundDeviceType(SoundDevice, &DeviceType); + SND_ASSERT( Result == MMSYSERR_NOERROR ); + + /* Ensure we have a wave device (TODO: check if wavein as well) */ + VALIDATE_MMSYS_PARAMETER( IS_WAVE_DEVICE_TYPE(DeviceType) ); + + /* Obtain the function table */ + Result = GetSoundDeviceFunctionTable(SoundDevice, &FunctionTable); + SND_ASSERT( Result == MMSYSERR_NOERROR ); + + if ( Result != MMSYSERR_NOERROR ) + return TranslateInternalMmResult(Result); + + SND_ASSERT( FunctionTable->QueryWaveFormatSupport ); + + return FunctionTable->QueryWaveFormatSupport(SoundDevice, Format, FormatSize); +} + +MMRESULT +SetWaveDeviceFormat( + IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance, + IN LPWAVEFORMATEX Format, + IN DWORD FormatSize) +{ + SND_TRACE(L"Setting wave format\n"); + return MMSYSERR_NOTSUPPORTED; +} Propchange: branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/format.c ------------------------------------------------------------------------------ svn:eol-style = native Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/widMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/widMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/widMessage.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -53,6 +53,8 @@ } } + SND_TRACE(L"widMessage returning MMRESULT %d\n", Result); + ReleaseEntrypointMutex(WAVE_IN_DEVICE_TYPE); return Result; Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wodMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wodMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wodMessage.c [iso-8859-1] Sun Dec 28 04:53:31 2008 @@ -51,7 +51,71 @@ Parameter2); break; } + + case WODM_OPEN : + { + PSOUND_DEVICE SoundDevice; + PSOUND_DEVICE_INSTANCE SoundDeviceInstance; + LPWAVEOPENDESC OpenParameters = (LPWAVEOPENDESC) Parameter1; + + /* Obtain the sound device */ + Result = GetSoundDevice(WAVE_OUT_DEVICE_TYPE, DeviceId, &SoundDevice); + + if ( Result != MMSYSERR_NOERROR ); + break; + + /* See if the device supports this format */ + Result = QueryWaveDeviceFormatSupport(SoundDevice, + OpenParameters->lpFormat, + sizeof(WAVEFORMATEX)); + + if ( Parameter2 & WAVE_FORMAT_QUERY ) + { + /* Nothing more to be done - keep the result */ + break; + } + + /* The MME API should provide us with a place to store a handle */ + SND_ASSERT( PrivateHandle ); + if ( ! PrivateHandle ) + { + /* Not so much an invalid parameter as something messed up!! */ + SND_ERR(L"MME API supplied a NULL private handle pointer!\n"); + Result = MMSYSERR_ERROR; + break; + } + + /* Spawn an instance of the sound device */ + Result = CreateSoundDeviceInstance(SoundDevice, &SoundDeviceInstance); + + if ( Result != MMSYSERR_NOERROR ) + { + SND_ERR(L"Failed to create sound device instance\n"); + break; + } + + /* Set the sample rate, bits per sample, etc. */ + Result = SetWaveDeviceFormat(SoundDeviceInstance, + OpenParameters->lpFormat, + sizeof(WAVEFORMATEX)); + + if ( Result != MMSYSERR_NOERROR ) + { + SND_ERR(L"Failed to set wave device format\n"); + DestroySoundDeviceInstance(SoundDeviceInstance); + break; + } + + break; + } + + case WODM_CLOSE : + { + break; + } } + + SND_TRACE(L"wodMessage returning MMRESULT %d\n", Result); ReleaseEntrypointMutex(WAVE_OUT_DEVICE_TYPE);
15 years, 12 months
1
0
0
0
[cwittich] 38411: sync comdlg32 winetest to wine 1.1.11
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 04:42:08 2008 New Revision: 38411 URL:
http://svn.reactos.org/svn/reactos?rev=38411&view=rev
Log: sync comdlg32 winetest to wine 1.1.11 Added: trunk/rostests/winetests/comdlg32/rsrc.rc (with props) Modified: trunk/rostests/winetests/comdlg32/comdlg32.rbuild trunk/rostests/winetests/comdlg32/filedlg.c trunk/rostests/winetests/comdlg32/printdlg.c Modified: trunk/rostests/winetests/comdlg32/comdlg32.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/comdlg32/comdlg…
============================================================================== --- trunk/rostests/winetests/comdlg32/comdlg32.rbuild [iso-8859-1] (original) +++ trunk/rostests/winetests/comdlg32/comdlg32.rbuild [iso-8859-1] Sun Dec 28 04:42:08 2008 @@ -7,9 +7,11 @@ <file>filedlg.c</file> <file>printdlg.c</file> <file>testlist.c</file> + <file>rsrc.rc</file> <library>wine</library> <library>comdlg32</library> <library>user32</library> + <library>gdi32</library> <library>kernel32</library> <library>ntdll</library> </module> Modified: trunk/rostests/winetests/comdlg32/filedlg.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/comdlg32/filedl…
============================================================================== --- trunk/rostests/winetests/comdlg32/filedlg.c [iso-8859-1] (original) +++ trunk/rostests/winetests/comdlg32/filedlg.c [iso-8859-1] Sun Dec 28 04:42:08 2008 @@ -22,6 +22,10 @@ #include <windows.h> #include <wine/test.h> +#include "initguid.h" +#include "shlguid.h" +#define COBJMACROS +#include "shobjidl.h" /* ##### */ @@ -131,9 +135,144 @@ } } +static UINT CALLBACK create_view_window2_hook(HWND dlg, UINT msg, WPARAM wParam, LPARAM lParam) +{ + if (msg == WM_NOTIFY) + { + if (((LPNMHDR)lParam)->code == CDN_FOLDERCHANGE) + { + IShellBrowser *shell_browser = (IShellBrowser *)SendMessage(GetParent(dlg), WM_USER + 7 /* WM_GETISHELLBROWSER */, 0, 0); + IShellView *shell_view = NULL; + IShellView2 *shell_view2 = NULL; + SV2CVW2_PARAMS view_params; + FOLDERSETTINGS folder_settings; + HRESULT hr; + RECT rect = {0, 0, 0, 0}; + + hr = IShellBrowser_QueryActiveShellView(shell_browser, &shell_view); + ok(SUCCEEDED(hr), "QueryActiveShellView returned %#x\n", hr); + if (FAILED(hr)) goto cleanup; + + hr = IShellView_QueryInterface(shell_view, &IID_IShellView2, (void **)&shell_view2); + if (hr == E_NOINTERFACE) + { + skip("IShellView2 not supported\n"); + goto cleanup; + } + ok(SUCCEEDED(hr), "QueryInterface returned %#x\n", hr); + if (FAILED(hr)) goto cleanup; + + hr = IShellView2_DestroyViewWindow(shell_view2); + ok(SUCCEEDED(hr), "DestroyViewWindow returned %#x\n", hr); + + folder_settings.ViewMode = FVM_LIST; + folder_settings.fFlags = 0; + + view_params.cbSize = sizeof(view_params); + view_params.psvPrev = NULL; + view_params.pfs = &folder_settings; + view_params.psbOwner = shell_browser; + view_params.prcView = ▭ + view_params.pvid = NULL; + view_params.hwndView = NULL; + + hr = IShellView2_CreateViewWindow2(shell_view2, &view_params); + ok(SUCCEEDED(hr), "CreateViewWindow2 returned %#x\n", hr); + if (FAILED(hr)) goto cleanup; + + hr = IShellView2_GetCurrentInfo(shell_view2, &folder_settings); + ok(SUCCEEDED(hr), "GetCurrentInfo returned %#x\n", hr); + ok(folder_settings.ViewMode == FVM_LIST, "view mode is %d, expected %d\n", folder_settings.ViewMode, FVM_LIST); + + hr = IShellView2_DestroyViewWindow(shell_view2); + ok(SUCCEEDED(hr), "DestroyViewWindow returned %#x\n", hr); + + /* XP and W2K3 need this. On Win9x and W2K the call to DestroyWindow() fails and has + * no side effects. NT4 doesn't get here. (FIXME: Vista doesn't get here yet). + */ + DestroyWindow(view_params.hwndView); + + view_params.pvid = &VID_Details; + hr = IShellView2_CreateViewWindow2(shell_view2, &view_params); + ok(SUCCEEDED(hr), "CreateViewWindow2 returned %#x\n", hr); + if (FAILED(hr)) goto cleanup; + + hr = IShellView2_GetCurrentInfo(shell_view2, &folder_settings); + ok(SUCCEEDED(hr), "GetCurrentInfo returned %#x\n", hr); + ok(folder_settings.ViewMode == FVM_DETAILS || + broken(folder_settings.ViewMode == FVM_LIST), /* Win9x */ + "view mode is %d, expected %d\n", folder_settings.ViewMode, FVM_DETAILS); + +cleanup: + if (shell_view2) IShellView2_Release(shell_view2); + if (shell_view) IShellView_Release(shell_view); + PostMessage(GetParent(dlg), WM_COMMAND, IDCANCEL, 0); + } + } + return 0; +} + +static LONG_PTR WINAPI template_hook(HWND dlg, UINT msg, WPARAM wParam, LPARAM lParam) +{ + if (msg == WM_INITDIALOG) + { + HWND p,cb; + INT sel; + p = GetParent(dlg); + ok(p!=NULL, "Failed to get parent of template\n"); + cb = GetDlgItem(p,0x470); + ok(cb!=NULL, "Failed to get filter combobox\n"); + sel = SendMessage(cb, CB_GETCURSEL, 0, 0); + ok (sel != -1, "Failed to get selection from filter listbox\n"); + } + if (msg == WM_NOTIFY) + { + if (((LPNMHDR)lParam)->code == CDN_FOLDERCHANGE) + PostMessage(GetParent(dlg), WM_COMMAND, IDCANCEL, 0); + } + return 0; +} + +static void test_create_view_window2(void) +{ + OPENFILENAMEA ofn = {0}; + char filename[1024] = {0}; + DWORD ret; + + ofn.lStructSize = sizeof(ofn); + ofn.lpstrFile = filename; + ofn.nMaxFile = 1042; + ofn.lpfnHook = create_view_window2_hook; + ofn.Flags = OFN_ENABLEHOOK | OFN_EXPLORER; + ret = GetOpenFileNameA(&ofn); + ok(!ret, "GetOpenFileNameA returned %#x\n", ret); + ret = CommDlgExtendedError(); + ok(!ret, "CommDlgExtendedError returned %#x\n", ret); +} + +static void test_create_view_template(void) +{ + OPENFILENAMEA ofn = {0}; + char filename[1024] = {0}; + DWORD ret; + + ofn.lStructSize = sizeof(ofn); + ofn.lpstrFile = filename; + ofn.nMaxFile = 1042; + ofn.lpfnHook = (LPOFNHOOKPROC)template_hook; + ofn.Flags = OFN_ENABLEHOOK | OFN_EXPLORER| OFN_ENABLETEMPLATE; + ofn.hInstance = GetModuleHandleA(NULL); + ofn.lpTemplateName = "template1"; + ofn.lpstrFilter="text\0*.txt\0All\0*\0\0"; + ret = GetOpenFileNameA(&ofn); + ok(!ret, "GetOpenFileNameA returned %#x\n", ret); + ret = CommDlgExtendedError(); + ok(!ret, "CommDlgExtendedError returned %#x\n", ret); +} START_TEST(filedlg) { test_DialogCancel(); - -} + test_create_view_window2(); + test_create_view_template(); +} Modified: trunk/rostests/winetests/comdlg32/printdlg.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/comdlg32/printd…
============================================================================== --- trunk/rostests/winetests/comdlg32/printdlg.c [iso-8859-1] (original) +++ trunk/rostests/winetests/comdlg32/printdlg.c [iso-8859-1] Sun Dec 28 04:42:08 2008 @@ -289,6 +289,77 @@ } +static BOOL abort_proc_called = FALSE; +static BOOL CALLBACK abort_proc(HDC hdc, int error) { return abort_proc_called = TRUE; } +static void test_abort_proc(void) +{ + HDC print_dc; + RECT rect = {0, 0, 100, 100}; + DOCINFOA doc_info = {0}; + PRINTDLGA pd = {0}; + char filename[MAX_PATH]; + + if (!GetTempFileNameA(".", "prn", 0, filename)) + { + skip("Failed to create a temporary file name\n"); + return; + } + + pd.lStructSize = sizeof(pd); + pd.Flags = PD_RETURNDEFAULT | PD_ALLPAGES | PD_RETURNDC | PD_PRINTTOFILE; + pd.nFromPage = 1; + pd.nToPage = 1; + pd.nCopies = 1; + + if (!PrintDlgA(&pd)) + { + skip("No default printer available.\n"); + ok(DeleteFileA(filename), "Failed to delete temporary file\n"); + return; + } + + ok(pd.hDC != NULL, "PrintDlg didn't return a DC.\n"); + if (!(print_dc = pd.hDC)) + { + ok(DeleteFileA(filename), "Failed to delete temporary file\n"); + return; + } + + ok(SetAbortProc(print_dc, abort_proc) > 0, "SetAbortProc failed\n"); + ok(!abort_proc_called, "AbortProc got called unexpectedly by SetAbortProc.\n"); + abort_proc_called = FALSE; + + doc_info.cbSize = sizeof(doc_info); + doc_info.lpszDocName = "Some document"; + doc_info.lpszOutput = filename; + + ok(StartDocA(print_dc, &doc_info) > 0, "StartDocA failed\n"); + ok(abort_proc_called, "AbortProc didn't get called by StartDoc.\n"); + abort_proc_called = FALSE; + + ok(StartPage(print_dc) > 0, "StartPage failed\n"); + ok(!abort_proc_called, "AbortProc got called unexpectedly by StartPage.\n"); + abort_proc_called = FALSE; + + ok(FillRect(print_dc, &rect, (HBRUSH)(COLOR_BACKGROUND + 1)), "FillRect failed\n"); + ok(!abort_proc_called, "AbortProc got called unexpectedly by StretchBlt.\n"); + abort_proc_called = FALSE; + + ok(EndPage(print_dc) > 0, "EndPage failed\n"); + ok(!abort_proc_called, "AbortProc got called unexpectedly by EndPage.\n"); + abort_proc_called = FALSE; + + ok(EndDoc(print_dc) > 0, "EndDoc failed\n"); + ok(!abort_proc_called, "AbortProc got called unexpectedly by EndDoc.\n"); + abort_proc_called = FALSE; + + ok(DeleteDC(print_dc), "DeleteDC failed\n"); + ok(!abort_proc_called, "AbortProc got called unexpectedly by DeleteDC.\n"); + abort_proc_called = FALSE; + + ok(DeleteFileA(filename), "Failed to delete temporary file\n"); +} + /* ########################### */ START_TEST(printdlg) @@ -299,6 +370,7 @@ test_PageSetupDlgA(); test_PrintDlgA(); + test_abort_proc(); /* PrintDlgEx not present before w2k */ if (ptr) { Added: trunk/rostests/winetests/comdlg32/rsrc.rc URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/comdlg32/rsrc.r…
============================================================================== --- trunk/rostests/winetests/comdlg32/rsrc.rc (added) +++ trunk/rostests/winetests/comdlg32/rsrc.rc [iso-8859-1] Sun Dec 28 04:42:08 2008 @@ -1,0 +1,34 @@ +/* Resources for the common dialog unit test suite. + * + * Copyright 2008 CodeWeavers, Aric Stewart + * + * 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 "windef.h" +#include "winuser.h" + +TEMPLATE1 DIALOG LOADONCALL MOVEABLE DISCARDABLE 5, 43, 227, 215 +STYLE WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS +FONT 8, "MS Shell Dlg" +{ + LTEXT "Path:",-1,28,4,36,8 + LTEXT "Text1",-1,4,16,20,40 + LTEXT "Selected:",-1,32,49,40,8 + EDITTEXT 55,74,47,200,12,ES_AUTOHSCROLL + LTEXT "Text2",-1,232,20,65,8 + LTEXT "",-1,28,16,204,31 + EDITTEXT 56,65,2,200,12,ES_AUTOHSCROLL +} Propchange: trunk/rostests/winetests/comdlg32/rsrc.rc ------------------------------------------------------------------------------ svn:eol-style = native
15 years, 12 months
1
0
0
0
[cwittich] 38410: add some missing GUIDs
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 04:41:07 2008 New Revision: 38410 URL:
http://svn.reactos.org/svn/reactos?rev=38410&view=rev
Log: add some missing GUIDs Modified: trunk/reactos/include/psdk/shlguid.h Modified: trunk/reactos/include/psdk/shlguid.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/shlguid.h?rev…
============================================================================== --- trunk/reactos/include/psdk/shlguid.h [iso-8859-1] (original) +++ trunk/reactos/include/psdk/shlguid.h [iso-8859-1] Sun Dec 28 04:41:07 2008 @@ -147,4 +147,13 @@ DEFINE_GUID(CLSID_CDocBrowsePropertyPage, 0x3050F3B4, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B); DEFINE_GUID(CLSID_CImageBrowsePropertyPage, 0x3050F3B3, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B); +DEFINE_GUID(VID_LargeIcons, 0x0057d0e0, 0x3573, 0x11cf, 0xae, 0x69, 0x08, 0x00, 0x2b, 0x2e, 0x12, 0x62); +DEFINE_GUID(VID_SmallIcons, 0x089000c0, 0x3573, 0x11cf, 0xae, 0x69, 0x08, 0x00, 0x2b, 0x2e, 0x12, 0x62); +DEFINE_GUID(VID_List, 0x0e1fa5e0, 0x3573, 0x11cf, 0xae, 0x69, 0x08, 0x00, 0x2b, 0x2e, 0x12, 0x62); +DEFINE_GUID(VID_Details, 0x137e7700, 0x3573, 0x11cf, 0xae, 0x69, 0x08, 0x00, 0x2b, 0x2e, 0x12, 0x62); +DEFINE_GUID(VID_Thumbnails, 0x8bebb290, 0x52d0, 0x11d0, 0xb7, 0xf4, 0x00, 0xc0, 0x4f, 0xd7, 0x06, 0xec); +DEFINE_GUID(VID_Tile, 0x65f125e5, 0x7be1, 0x4810, 0xba, 0x9d, 0xd2, 0x71, 0xc8, 0x43, 0x2c, 0xe3); +DEFINE_GUID(VID_ThumbStrip, 0x8eefa624, 0xd1e9, 0x445b, 0x94, 0xb7, 0x74, 0xfb, 0xce, 0x2e, 0xa1, 0x1a); + + #endif /* __WINE_SHLGUID_H */
15 years, 12 months
1
0
0
0
[cwittich] 38409: sync advpack winetest to wine 1.1.11
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 04:36:50 2008 New Revision: 38409 URL:
http://svn.reactos.org/svn/reactos?rev=38409&view=rev
Log: sync advpack winetest to wine 1.1.11 Modified: trunk/rostests/winetests/advpack/advpack.c trunk/rostests/winetests/advpack/files.c trunk/rostests/winetests/advpack/install.c Modified: trunk/rostests/winetests/advpack/advpack.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/advpack/advpack…
============================================================================== --- trunk/rostests/winetests/advpack/advpack.c [iso-8859-1] (original) +++ trunk/rostests/winetests/advpack/advpack.c [iso-8859-1] Sun Dec 28 04:36:50 2008 @@ -264,7 +264,7 @@ if(hr == HRESULT_FROM_WIN32(ERROR_MOD_NOT_FOUND)) { - trace("WinNT 3.51 detected. Skipping tests for TranslateInfString()\n"); + win_skip("WinNT 3.51 detected. Skipping tests for TranslateInfString()\n"); return; } @@ -324,6 +324,13 @@ HRESULT hr; char buffer[MAX_PATH]; DWORD size = MAX_PATH; + + hr = pOpenINFEngine(inf_file, NULL, 0, &hinf, NULL); + if (hr == E_UNEXPECTED) + { + skip("Skipping tests on win9x because of brokenness\n"); + return; + } create_inf_file(); Modified: trunk/rostests/winetests/advpack/files.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/advpack/files.c…
============================================================================== --- trunk/rostests/winetests/advpack/files.c [iso-8859-1] (original) +++ trunk/rostests/winetests/advpack/files.c [iso-8859-1] Sun Dec 28 04:36:50 2008 @@ -97,6 +97,7 @@ static void test_AddDelBackupEntry(void) { + BOOL ret; HRESULT res; CHAR path[MAX_PATH]; CHAR windir[MAX_PATH]; @@ -165,7 +166,10 @@ res = pAddDelBackupEntry("one\0three\0", NULL, "basename", AADBE_DEL_ENTRY); SetFileAttributesA(path, FILE_ATTRIBUTE_NORMAL); ok(res == S_OK, "Expected S_OK, got %d\n", res); - ok(DeleteFileA(path), "Expected path to exist\n"); + ret = DeleteFileA(path); + ok(ret == TRUE || + broken(ret == FALSE), /* win98 */ + "Expected path to exist\n"); } /* the FCI callbacks */ Modified: trunk/rostests/winetests/advpack/install.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/advpack/install…
============================================================================== --- trunk/rostests/winetests/advpack/install.c [iso-8859-1] (original) +++ trunk/rostests/winetests/advpack/install.c [iso-8859-1] Sun Dec 28 04:36:50 2008 @@ -55,27 +55,20 @@ return (((err & SPAPI_MASK) ^ SPAPI_PREFIX) == 0); } -static void append_str(char **str, const char *data) -{ - sprintf(*str, data); - *str += strlen(*str); -} - static void create_inf_file(LPCSTR filename) { - char data[1024]; - char *ptr = data; DWORD dwNumberOfBytesWritten; HANDLE hf = CreateFile(filename, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); - append_str(&ptr, "[Version]\n"); - append_str(&ptr, "Signature=\"$Chicago$\"\n"); - append_str(&ptr, "AdvancedINF=2.5\n"); - append_str(&ptr, "[DefaultInstall]\n"); - append_str(&ptr, "CheckAdminRights=1\n"); - - WriteFile(hf, data, ptr - data, &dwNumberOfBytesWritten, NULL); + static const char data[] = + "[Version]\n" + "Signature=\"$Chicago$\"\n" + "AdvancedINF=2.5\n" + "[DefaultInstall]\n" + "CheckAdminRights=1\n"; + + WriteFile(hf, data, sizeof(data) - 1, &dwNumberOfBytesWritten, NULL); CloseHandle(hf); }
15 years, 12 months
1
0
0
0
[cwittich] 38408: sync comcat winetest to wine 1.1.11
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 04:35:04 2008 New Revision: 38408 URL:
http://svn.reactos.org/svn/reactos?rev=38408&view=rev
Log: sync comcat winetest to wine 1.1.11 Modified: trunk/rostests/winetests/comcat/comcat.c Modified: trunk/rostests/winetests/comcat/comcat.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/comcat/comcat.c…
============================================================================== --- trunk/rostests/winetests/comcat/comcat.c [iso-8859-1] (original) +++ trunk/rostests/winetests/comcat/comcat.c [iso-8859-1] Sun Dec 28 04:35:04 2008 @@ -21,6 +21,7 @@ #define COBJMACROS #include <stdio.h> +#include <initguid.h> #include <windows.h> #include "objbase.h"
15 years, 12 months
1
0
0
0
[cwittich] 38407: sync cabinet winetest to wine 1.1.11
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 04:32:41 2008 New Revision: 38407 URL:
http://svn.reactos.org/svn/reactos?rev=38407&view=rev
Log: sync cabinet winetest to wine 1.1.11 Modified: trunk/rostests/winetests/cabinet/fdi.c Modified: trunk/rostests/winetests/cabinet/fdi.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/cabinet/fdi.c?r…
============================================================================== --- trunk/rostests/winetests/cabinet/fdi.c [iso-8859-1] (original) +++ trunk/rostests/winetests/cabinet/fdi.c [iso-8859-1] Sun Dec 28 04:32:41 2008 @@ -594,7 +594,7 @@ } -INT_PTR __cdecl CopyProgress (FDINOTIFICATIONTYPE fdint, PFDINOTIFICATION pfdin) +static INT_PTR __cdecl CopyProgress(FDINOTIFICATIONTYPE fdint, PFDINOTIFICATION pfdin) { return 0; }
15 years, 12 months
1
0
0
0
[cwittich] 38406: sync msi winetest to wine 1.1.11
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 04:25:32 2008 New Revision: 38406 URL:
http://svn.reactos.org/svn/reactos?rev=38406&view=rev
Log: sync msi winetest to wine 1.1.11 Modified: trunk/rostests/winetests/msi/automation.c trunk/rostests/winetests/msi/db.c trunk/rostests/winetests/msi/format.c trunk/rostests/winetests/msi/install.c trunk/rostests/winetests/msi/msi.c trunk/rostests/winetests/msi/package.c trunk/rostests/winetests/msi/record.c trunk/rostests/winetests/msi/source.c [This mail would be too long, it was shortened to contain the URLs only.] Modified: trunk/rostests/winetests/msi/automation.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/msi/automation.…
Modified: trunk/rostests/winetests/msi/db.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/msi/db.c?rev=38…
Modified: trunk/rostests/winetests/msi/format.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/msi/format.c?re…
Modified: trunk/rostests/winetests/msi/install.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/msi/install.c?r…
Modified: trunk/rostests/winetests/msi/msi.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/msi/msi.c?rev=3…
Modified: trunk/rostests/winetests/msi/package.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/msi/package.c?r…
Modified: trunk/rostests/winetests/msi/record.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/msi/record.c?re…
Modified: trunk/rostests/winetests/msi/source.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/msi/source.c?re…
15 years, 12 months
1
0
0
0
[cwittich] 38405: update system restore header
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Dec 28 04:23:32 2008 New Revision: 38405 URL:
http://svn.reactos.org/svn/reactos?rev=38405&view=rev
Log: update system restore header Modified: trunk/reactos/include/psdk/srrestoreptapi.h Modified: trunk/reactos/include/psdk/srrestoreptapi.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/srrestoreptap…
============================================================================== --- trunk/reactos/include/psdk/srrestoreptapi.h [iso-8859-1] (original) +++ trunk/reactos/include/psdk/srrestoreptapi.h [iso-8859-1] Sun Dec 28 04:23:32 2008 @@ -26,6 +26,13 @@ #endif /* Defines */ + +/* Event types */ +#define BEGIN_NESTED_SYSTEM_CHANGE 102 +#define END_NESTED_SYSTEM_CHANGE 103 + +/* Restore point types */ +#define APPLICATION_INSTALL 0 #define MAX_DESC 64 #define MAX_DESC_W 256
15 years, 12 months
1
0
0
0
← Newer
1
...
6
7
8
9
10
11
12
...
71
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
Results per page:
10
25
50
100
200