diff -Nru wine1.7-1.7.28/ANNOUNCE wine1.7-1.7.31/ANNOUNCE --- wine1.7-1.7.28/ANNOUNCE 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/ANNOUNCE 2014-11-14 13:28:17.000000000 +0000 @@ -1,15 +1,16 @@ -The Wine development release 1.7.28 is now available. +The Wine development release 1.7.31 is now available. What's new in this release (see below for details): - - Support for conditional compilation in JavaScript. - - Bidirectional text support in DirectWrite. - - Stubs for DirectPlay Voice support. + - New version of the Gecko engine based on Firefox 34. + - Support for the Visual Studio 2013 version of the C/C++ runtimes. + - More font metrics support in DirectWrite. + - Some more Direct2D work. - Various bug fixes. The source is available from the following locations: - http://prdownloads.sourceforge.net/wine/wine-1.7.28.tar.bz2 - http://mirrors.ibiblio.org/wine/source/1.7/wine-1.7.28.tar.bz2 + http://prdownloads.sourceforge.net/wine/wine-1.7.31.tar.bz2 + http://mirrors.ibiblio.org/wine/source/1.7/wine-1.7.31.tar.bz2 Binary packages for various distributions will be available from: @@ -25,225 +26,312 @@ ---------------------------------------------------------------- -Bugs fixed in 1.7.28 (total 21): +Bugs fixed in 1.7.31 (total 51): - 20799 (not a Wine bug) Multiple games using OpenAL freezes/crashes during the startup - 22469 FileMaker Pro 11: Text is upside down when builtin gdiplus is used - 22987 Irfan view - "Can't paste image from clipboard !" - 23667 CDBurnerXP 3.0 desktop shortcut uses a generic wine glass icon - 25705 Action buttons in Lemmings could not be clicked - 25715 native dxdiag crashes with builtin quartz - 26738 Steam crashes using ALSA - 27978 QuickBooks Premier 2011 crash on start - 31043 Segfault when trying to run Direct3D or OpenGL apps - 31378 Built in IE - U-Haul dealer network Point of Sale page unusable - 31815 Rhapsody 4.0 crashes on startup - 34923 SolidWorks 2014 installer needs ieframe IWebBrowser2::Refresh2 - 35019 ToDoList 6.9.b12 (MFC app) crashes when deleting a task - 35121 Multiple applications/games fail to start with WinVer set to 'Windows 7' (FindFirstFileExW needs FIND_FIRST_EX_LARGE_FETCH support)(FotoQuelle Fotosoftware v4.13, QT5) - 37198 Pale Moon Portable 24.7.x fails on startup, reporting "Couldn't load XPCOM" (needs msvcp110.dll '?_BADOFF@std@@3_JB' also exported for 32-bit arch) - 37221 biet-o-matic 2.14.12: Crashes when past eBay item number with context menu (right click, past) - 37290 Baltie educational programming language does not run. - 37304 Different paper size enumerations between cloned printers - 37305 ApexDC fails to do file operations (file:FindFirstFileExW) - 37319 [Ubuntu 12.04][Wine.1.4.x/1.6.x] Steam - can't purchase games due to an invalid SSL cerificate - 37339 Excel 2010 Cant save or open files with Pivot Tables + 3766 GRE Powerprep Software crashes + 9190 Warhammer: Dark Omen doesn't launch + 10085 Adobe Bridge CS2 complains that it can't start due to licensing restrictions (affects photoshop) + 10212 Microsoft Crimson Skies crashes after startup + 13632 ShipSimulator 2008 freezes after start playing (needs d3dx9_36.D3DXCreatePolygon) + 16584 chaostheory music lack of drums + 16699 OpenGL anti-aliasing capabilities of graphics driver not exposed to Google Sketchup 7/8 (needs WGL_SWAP_COPY_ARB support) + 16832 Hinterland fails to run, wine reports Unhandled page fault to NULL + 18289 wine gets some wrong charcodes on some keyboard mappings + 18689 Wine serial-handling consumes 100% CPU when using USB->Serial-converter + 24787 WoW 4.x D3D: Player shadow broken with orm=backbuffer + 25247 Alien Swarm: Can't join or create game, game hangs + 25342 Bionic Commando: Rearmed. Dark foreground graphics + 25392 Unable to start qm.exe from state-machine.com website on Ubuntu 10.04 LTS + 25399 EasyCash & Tax crashes when executing "Select New Datadirectory" menu entry + 27736 Virtual Sailor 7 settings screen: boats and scenery options are unavailable + 28675 FUEL: Abandoned Vehicles Do Not Appear where they should + 29861 MiPony crashes after startup with null pointer access in fire_event + 30492 VMware vSphere Client v5.0 Update 1 fails, needs ntoskrnl.exe.IoRegisterPlugPlayNotification + 30572 Multiple applications need vectored continue handler support (.NET 3.x/4.x/Silverlight, Lync from Office 2013) + 30737 Dde_OnRequest should return groups_data instead of NULL + 31410 Hamster Free eBook Converter 1.0.0.x installer crashes on startup + 32111 Element Client for Perfect World crashes on startup + 32448 WoW, The memory could not be "read". Sound/video performance issues + 32825 ThunderMini: hangs randomly after change the status of the file + 32977 Solidworks 2012 needs unimplemented function dwmapi.dll.DwmInvalidateIconicBitmaps (Win7 mode) + 32978 Solidworks 2012 : OpenGL Display refresh problems with keyboard events (mouse is OK) + 33323 Garena Messenger crashes on startup + 33993 Microsoft Jet fails to install + 34184 Skype 6.6 and above cannot start, Runtime error 217 at 00XXXXXX, Loading of typelib L"uc.tlb" failed with error 1006 + 34539 Final Fantasy XIV Benchmark: moving the window inside a virtual desktop causes mouse focus issues + 34573 Cinema 4D R15 crashes on unimplemented function IPHLPAPI.DLL.NotifyIpInterfaceChange + 34857 Hoyle Casino 2011 game won't launch. + 34915 user32:msg fails on Windows XP + 34941 Ruby 1.9.x interpreter hangs with OS-level thread concurrency error (critical section not initialized in msvcrt internal semi-documented 'ioinfo' struct) + 35133 The Incredible Adventures of Van Helsing (Steam) crashes with built-in d3dx9_36 + 35722 MS Visual C++ 2008 Redistributable KB-hotfix installer, part of Nero 10 installer crashes on unimplemented function msi.dll.MsiRemovePatchesW + 36713 Watch_Dogs requires ws2_32.inet_pton + 36752 mp3DirectCut 2.20 crashes when stopping mp3 playback + 37074 Ironclads series: missing text in the menus without native d3dx9_36 + 37120 PVS-Studio Error: Equivalent branches of if operator + 37354 Battle.net launcher does not start in Windows 7 mode: "Cannot load Qt platform plugin Windows" (FindFirstFileExW needs info level 'FindExInfoBasic' support) + 37374 Behringer X-32 Edit crashes on startup + 37381 Matlab 2010 crashes on unimplemented function msvcr80.dll._ungetc_nolock + 37461 Sid Meier's Civilization: Beyond Earth (Steam) crashes on unimplemented function msvcp110.dll.?length@?$codecvt@GDH@std@@QBEHAAHPBD1I@Z + 37490 dwrite/analyzer.c:1226:5: warning: comparison of unsigned expression < 0 is always false + 37493 Silverlight 5.1 msi installer fails with Wine 1.7.30 - Transform doesn't update ProductVersion property + 37511 Multiple games and applications need 'msvcp120.dll' (PPSSPP 0.9.x) + 37519 ooVoo 3.6.x (video chat client) doesn't launch + 37539 Altap Salamander 3.04 crashes on startup on missing shell32.RegenerateUserEnvironment + 37548 .NET applications using native .NET Frameworks fail to load, reporting 'CLR error: 80004005. The program will now terminate.' ('RtlAddVectoredContinueHandler' is a stub) ---------------------------------------------------------------- -Changes since 1.7.27: +Changes since 1.7.30: -Akihiro Sagawa (3): - ntdll/tests: Remove duplicated entry. - ntdll/tests: Add KeyNameInformation tests. - po: Update Japanese translation. +Alex Henrie (4): + kernel32/tests: Add UTF-7 non-encoded surrounding characters tests. + kernel32/tests: Add UTF-7 encoded surrounding characters tests. + kernel32/tests: Add UTF-7 stray + sign removal tests. + kernel32/tests: Add UTF-7 implicit termination tests. Alexandre Julliard (2): - secur32/tests: Update test for the new certificate on winehq.org. - kernel32/tests: Fix overlapped status checks for 64-bit. + msvcp60: Add some missing exports. + configure: Don't require libXext for Xrender. -Alistair Leslie-Hughes (7): - dpvoice: Add IDirectPlayVoiceClient Support. - dpvoice: Add IDirectPlayVoiceServer support. - dpvoice: Add DirectPlay Voice test. - dpvoice: Add IDirectPlayVoiceTest stub interface. - dpnet: Implement IDirectPlay8Address AddComponent. - dpnet: Show SetSP adds a component. - dpnet: Implement IDirectPlay8Address Duplicate. - -Andreas Fuchs (1): - kernel32: Ignore flags on FindFirstFileExW. - -Andrei Slăvoiu (2): - wined3d: Adjust the Intel fallbacks to better reflect reality. - wined3d: Pass the capabilities directly to d3d_level_from_gl_info and rename it to d3d_level_from_caps. - -André Hentschel (5): - d3d10core: Fix out of bounds access (Coverity). - dwrite: Check correct variable (Coverity). - ntdll: Use a dynamic buffer for change notification data. - winegcc: Respect TMPDIR environment variable. - winemenubuilder: Respect TMPDIR environment variable. - -François Gouget (3): - dpnet/tests: Add a trailing '\n' to some ok() calls. - d2d1: Add a trailing '\n' to a FIXME(). - Assorted spelling fixes. - -Frédéric Delanoy (2): - po: Update French translation. - Assorted spelling/grammar fixes. - -Hans Leidekker (3): - wininet/tests: Update test data to match the new certificate on winehq.org. - wininet: Protect the request headers array with a critical section. - msi: Include the terminating null in the buffer size for decoded stream names. - -Hao Peng (1): - mshtml: Add IHTMLAnchorElement::search propertyimplementation. - -Henri Verbeet (23): - d3d8: Get rid of the format switching code in d3d8_device_CopyRects(). - ddraw: Move the pitch / linear size validation from ddraw_surface_init() to ddraw_surface_create(). - ddraw: Set user memory in ddraw_surface_create() instead of ddraw_surface_init(). - wined3d: Replace wined3d_surface_update_desc() with wined3d_texture_update_desc(). - wined3d: Get rid of SFLAG_DONOTFREE. - wined3d: Use wined3d_texture_set_color_key() to manipulate the color-key in surface_blt_special(). - wined3d: Use a lookup table in d3dfmt_get_conv(). - wined3d: Get rid of the "use_texturing" parameter to d3dfmt_get_conv(). - wined3d: Pass a texture to d3dfmt_get_conv(). - wined3d: Use a more consistent naming for wined3d_conversion_type elements. - wined3d: Get rid of the WINED3D_CT_NONE case in d3dfmt_convert_surface(). - wined3d: Fix the pitch handling in the no-palette WINED3D_CT_P8 case. - wined3d: Convert to WINED3DFMT_B8G8R8A8_UNORM for WINED3D_CT_P8. - wined3d: Convert to WINED3DFMT_B5G5R5A1_UNORM for WINED3D_CT_CK_B5G6R5. - wined3d: Convert to WINED3DFMT_B8G8R8A8_UNORM for WINED3D_CT_CK_B8G8R8. - wined3d: Convert to WINED3DFMT_B8G8R8A8_UNORM for WINED3D_CT_CK_B8G8R8X8. - wined3d: Just store the wined3d format in color_key_info[]. - wined3d: Introduce a separate function for WINED3D_CT_P8. - wined3d: Introduce a separate function for WINED3D_CT_CK_B5G6R5. - wined3d: Introduce a separate function for WINED3D_CT_CK_B5G5R5X1. - wined3d: Introduce a separate function for WINED3D_CT_CK_B8G8R8. - wined3d: Introduce a separate function for WINED3D_CT_CK_B8G8R8X8. - wined3d: Introduce a separate function for WINED3D_CT_CK_B8G8R8A8. - -Jacek Caban (40): - vbscript: Don't try to convert int to short in return_int. - mshtml: Don't share nsform reference with nsnode. - mshtml: Don't share nsinput reference with nsnode. - mshtml: Don't share nsframe and nsiframe reference with nsnode. - mshtml: Don't share nsstyle reference with nsnode. - mshtml: Don't share nslink reference with nsnode. - mshtml: Don't share nsanchor reference with nsnode. - mshtml: Don't share nsselect reference with nsnode. - mshtml: Don't share nsoption reference with nsnode. - mshtml: Don't share nstextarea reference with nsnode. - mshtml: Don't share nstable reference with nsnode. - mshtml: Don't share nscell reference with nsnode. - mshtml: Don't share nsobject reference with nsnode. - ieframe: Added partial Refresh2 implementation. - mshtml: Don't share nsimg reference with nsnode. - mshtml: Don't share nsscript reference with nsnode. - mshtml: Don't share nsrow reference with nsnode. - mshtml: Don't share nsbutton reference with nsnode. - mshtml: Use UTF-8 encoding in NewURI by default. - mshtml: Use proper type for text node in exec_hyperlink. - mshtml: Don't assume that nsIDOMHTMLElement inherits from nsIDOMNode in HTMLDocument_createStyleSheet. - mshtml: Removed no longer needed assert. - jscript: Move parser related declarations to separated header. - jscript: Return double from parse_numeric_literal and parse_double_literal. - jscript: Added new ccval_t type for CC variable values. - jscript: Moved skipping spaces to separated function. - jscript: Added conditional compilation @set support. - jscript/tests: Added @set tests. - jscript: Added support for conditional compilation @if/@elif/@else/@end. - jscript: Added tests for @if/@elif/@else/@end. - jscript: Implicitly turn CC on for @set instruction. - jscript: Implicitly turn CC on for @if instruction. - jscript: Added support for '-' CC expression. - mshtml: Don't assume that nsIDOMHTML*Element interfaces inherit from nsIDOMHTMLElement in htmlinput.c. - mshtml: Don't assume that nsIDOMHTML*Element interfaces inherit from nsIDOMHTMLElement in htmloption.c. - mshtml: Don't assume that nsIDOMHTML*Element interfaces inherit from nsIDOMHTMLElement in htmlscript.c. - mshtml: Don't assume that nsIDOMHTMLScriptElement inherits from nsIDOMHTMLElement in get_script_guid. - jscript: Added parser rules for missing expressions. - jscript: Added support for '==' CC expression. - jscript: Added support for relational CC expressions. - -Jactry Zeng (1): - riched20: Set editor->reOle to NULL when IRichEditOle is released. - -Johannes Brandstätter (1): - d3d10core: Add support for map_type flags D3D10_MAP_READ, D3D10_MAP_WRITE_NO_OVERWRITE and D3D10_MAP_DISCARD. - -Joris van der Wel (1): - server: A new function "set_sd_defaults_from_token". - -Ken Thomases (2): - winemac: Don't invalidate the window shadow on every draw if it's merely shaped and not color-keyed or using per-pixel alpha. - winemac: Properly ignore attempts to set a window's shape to its current shape. - -Lauri Kenttä (1): - po: Update Finnish translation. - -Marcus Meissner (6): - dwrite: Use correct variable (Coverity). - dwrite: Fixed NULL ptr deref before check (Coverity). - dwrite: Avoid NULL ptr dereference (Coverity). - wbemprox: Fixed a memory leak in get_sd (Coverity). - dwrite: Check correct variable for NULL (Coverity). - dxgi: Added missing unlock (Coverity). - -Nikolay Sivov (12): - usp10: Use proper type for return value. - dwrite: Use proper type for return value. - dwrite: Implement itemization by script id using Unicode.org data. - include: Update dwrite headers to match SDK 8.1. - dwrite: Update to IDWriteTextAnalyzer2. - dwrite: Allow underscores in script names. - dwrite: Implement GetScriptProperties(). - dwrite: Implement GetTextComplexity(). - po: Update Russian translation. - dwrite: Implement AnalyzeBidi(). - usp10: Remove comment that's no longer true. - dwrite: Implement CreateNumberSubstitution(). - -Piotr Caban (4): - user32: Return early on child windows in DrawMenuBar. - user32/tests: Add initial WindowFromPoint tests. - user32/tests: Add cross-process WindowFromPoint tests. - user32/tests: Add cross-process mouse click test. - -Qian Hong (5): - mshtml: Using UTF-8 as default charset in bind_mon_to_wstr. - mshtml: Don't pass NULL string pointer to jscript engine. - appwiz.cpl: Fixed typo. - winmm: Also initialize sound device thread in mixerGetControlDetails. - jscript: Ignore BOM mark in next_token. - -Ralf Habacker (1): - wineps.drv: For each printer start page size and source index with the same value. - -Sebastian Lackner (8): - msvcp110: Export ?_BADOFF@std@@3_JB on both i386 and win64. - shlwapi/tests: Add SH*Shared inter-process tests. - shlwapi: Fixed swapped argument order in SHLWAPI_DupSharedHandle command. - kernel32/tests: Add tests for FindFirstFileExA with FIND_FIRST_EX_LARGE_FETCH flag. - kernel32/tests: Add tests for FindFirstFileExA with FIND_FIRST_EX_CASE_SENSITIVE flag. - shlwapi/tests: Add test for SHMapHandle. - shlwapi: Fix swapped argument order in SHMapHandle. - shlwapi: Remove unnecessary internal function SHLWAPI_DupSharedHandle. - -Shuai Meng (1): - vbscript: Implemented RGB. +Amine Khaldi (1): + gdi32/tests: Add basic tests for the handling of dwCount parameter in ExtCreateRegion. -Stefan Dösinger (1): - d3d8: Return the correct value in CreateAdditionalSwapChain. +André Hentschel (6): + urlmon/tests: Clarify ok() condition (PVS-Studio). + user32/tests: Clarify ok() condition (PVS-Studio). + ntdll/tests: Clarify ok() conditions (PVS-Studio). + xmllite/tests: Clarify ok() condition (PVS-Studio). + avifil32: Simplify comparing two unsigned ints (PVS-Studio). + ntdll/tests: Get rid of "defined but not used" warnings on non-x86(_64) platforms. + +Austin English (4): + msi: Add stubs for MsiRemovePatches(A/W). + ntoskrnl.exe: Add a stub for IoRegisterPlugPlayNotification. + shell32: Add a stub for RegenerateUserEnvironment. + ntdll: Add stubs for vectored continue handler. + +Bruno Jesus (12): + comctl32/tests: Remove dead assignments in treeview.c (Cppcheck). + comctl32/tests: Remove a dead assignment in misc.c (Cppcheck). + mciavi32: Initialize a variable (Cppcheck). + crypt32: Remove dead assignments in cert.c (Cppcheck). + compobj.dll16: Remove dead assignments in compobj.c (Cppcheck). + ws2_32: Add tests and implement inet_pton. + dinput: Ensure variable is initialized when #define is not found (Cppcheck). + po: Update Brazilian Portuguese translation. + version: Handle NULL puLen parameter for VerQueryValueA/W. + server: Add a missing socket protocol attribution. + server: Store the time of the socket connection. + ole32: Avoid a possible null dereference. + +Chen Yuan (2): + mshtml: Add IHTMLStyle5::maxWidth property implementation. + mshtml: Add IHTMLStyle5::maxHeight property implementation. + +Guillaume Charifi (1): + oleaut32: Implement TLB dependencies lookup in resources. + +Hans Leidekker (6): + msi: Pass a database pointer to msi_clone_properties instead of a package pointer. + msi: Update properties after each transform that affects the property table. + msi: Call execute_script directly in InstallFinalize. + advapi32: Return success from LsaAddAccountRights. + server: Set the security descriptor of named pipe objects. + odbc32: Add a version resource. + +Henri Verbeet (14): + d3d10core: Implement d3d10_device_ClearState(). + d3d10core/tests: Add a test for ID3D10Device_ClearState(). + d2d1: Pass the correct vtbl in d2d_linear_gradient_brush_init(). + d2d1: Implement d2d_gradient_GetGradientStopCount(). + d2d1: Implement d2d_gradient_GetGradientStops(). + wined3d: Make a copy of shader signature string data. + wined3d: Calculate the SM4 output mapping in shader_sm4_init(). + d3d10core: Free the output signature after creating the wined3d shader. + wined3d: Use the input signature to setup SM4 pixel shader input semantics. + d3d10core: Set wined3d state in d3d10_device_OMSetBlendState(). + d2d1: Add an initial d2d_d3d_render_target_FillRectangle() implementation. + d2d1: Implement d2d_solid_color_brush_SetColor(). + d2d1: Implement d2d_solid_color_brush_GetColor(). + d2d1: Implement d2d_solid_color_brush_SetOpacity(). + +Huw D. M. Davies (4): + comctl32/tests: Post a key-down message rather than use keybd_event. + mlang: Accept "ascii" as an alias for "us-ascii". + user32: Make the combo's listbox a topmost window. + winemac: WS_EX_DLGMODALFRAME shouldn't prevent the window being resizeable. + +Iván Matellanes (12): + msvcrt: Avoid locking the file in _fclose_nolock. + msvcrt: Use correct type for fread and fwrite return values. + msvcrt: Added _fputc_nolock implementation. + msvcrt: Added _fputwc_nolock implementation. + msvcrt: Added _ungetc_nolock implementation. + msvcrt: Added _ungetwc_nolock implementation. + msvcrt: Added _getc_nolock implementation. + msvcrt: Added _getwc_nolock implementation. + msvcrt: Added _putc_nolock implementation. + msvcrt: Added _putwc_nolock implementation. + msvcrt: Add missing declarations in wchar.h. + msvcrt: Added _fread_nolock_s implementation. + +Jacek Caban (14): + mshtml: Wine Gecko 2.34 release. + urlmon: Update existing session if user agent changes. + mshtml: Added IHTMLTable:cellPadding property implementation. + mshtml: Added IHTMLScriptElement:onerror property semi-stub implementation. + mshtml: Added IDispatchEx support to HTMLTxtRange object. + mshtml: Added support for IDispatchEx to HTMLSelectionObject object. + mshtml: Ignore query and hash parts in res protocol handler. + mshtml: Added IHTMLTxtRange::moveToElementText implementation. + mshtml: Moved IHTMLElement2 implementation to htmlelem.c. + mshtml: Added IHTMLElement2::put_dir implementation. + mshtml: Added IHTMLTxtRange::pasteHTML implementation. + mshtml: Properly handle errors in IHTMLStyleSheet::get_rules now that Gecko part is fixed. + wpcapi.idl: Added WPCFLAG_RESTRICTION declaration. + mshtml: Fixed tests on recent IEs. + +Jonas Maebe (1): + wined3d: Add NVIDIA Geforce GT 750M to supported device list. + +Jonathan Vollebregt (7): + reg/tests: Delete keys manually to prevent timeout on winxp/win2k. + reg/tests: Move key format test section below first key creation. + reg/tests: Test for empty type and empty binary input. + reg/tests: Test result for deleting key that doesn't exist. + advapi32/tests: Add trailing slashes tests for RegOpen/CreateKey. + advapi32/tests: Fix bad cleanup in test_reg_create_key. + advapi32/tests: Test RegDeleteKey with empty string parameter. + +Marcus Meissner (1): + dwrite: Fixed memory leak on error (Coverity). + +Mark Harmstone (1): + winealsa: Disable channel remapping for capture devices. + +Matteo Bruni (11): + wined3d: Add ATI1N texture format support. + wined3d: Dirtify pixel shader on texture format change. + d3d9/tests: Add a test for ATI1N and ATI2N texture formats. + d3d8/tests: Add a test for ATI1N and ATI2N texture formats. + d3d9/tests: Add an ATI1N entry to the test_volume_blocks test. + d3d8/tests: Add an ATI1N entry to the test_volume_blocks test. + winex11.drv: Actually report WGL_SWAP_EXCHANGE_ARB as the swap method. + winex11.drv: Add support for GLX_OML_swap_method. + d3dx9: Handle GUID_WICPixelFormat8bppGray format. + d3dx9: Use an alpha-capable format when creating textures with a color key. + d3dx9: Improve the scoring for fallback formats. + +Michael Stefaniuc (17): + urlmon/tests: Visually separate two if statements (PVS-Studio). + crypt32/tests: Avoid an always true ok() condition (PVS-Studio). + d3d8/tests: Remove an always false condition (PVS-Studio). + gdi32: Remove a basically unused variable (PVS-Studio). + advapi32/tests: Simplify empty string check (PVS-Studio). + shlwapi/tests: Simplify empty string check (PVS-Studio). + msi: Simplify check for an empty string (PVS-Studio). + shell32: Simplify check for empty string (PVS-Studio). + wininet: Simplify the check for an empty string (PVS-Studio). + riched20/tests: Simplify the check for an empty string (PVS-Studio). + gameux: Simplify the check for an empty string (PVS-Studio). + mciwave: Simplify the check for an empty string (PVS-Studio). + crypt32/tests: Remove an unused assignment (PVS-Studio). + oleaut32/tests: Simplify the check for an empty string (PVS-Studio). + avifil32: Simplify the check for an empty string (PVS-Studio). + appwiz.cpl: Simplify the check for an empty string (PVS-Studio). + fusion/tests: Simplify the check for an empty string (PVS-Studio). + +Nikolay Sivov (21): + msvcr120: Added VS2013 CRT dll. + dwrite: Map Mac language id to locale name. + dwrite: Remove null checks for family and collection pointers, those are always set now. + dwrite/tests: Some tests for custom font collections. + dwrite: Fix setting oblique simulation on font creation. + dwrite: Fix compiler warning regarding unsigned type of enum member. + dwrite: Implement GetFaceNames(). + dwrite: Implement remaining methods of IDWriteLocalizedStrings. + dpnet/tests: Fix a test failure caused by uninitialized argument. + user32/tests: Use win_skip() where appropriate. + dwrite: Don't cache fontface instance in font data. + dwrite: File and factory are always set now for all collections. + dwrite: Added a separate helper to fill font metrics structure. + dwrite: Use public APIs to get file streams from fontface. + dwrite: Implement GetMetrics() for fontface. + dwrite: Implement GetMetrics() for DWRITE_FONT_METRICS1. + dwrite: Added a basic test for TryGetFontTable(). + dwrite: Respond to IID_IDWriteTextLayout1 too. + dwrite: Implement ConvertFontToLOGFONT(). + include: Add a couple more defines for D3DPRESENT_* flags. + dwrite: Remove OpenType language id from cache. + +Piotr Caban (6): + msvcp110: Add codecvt::length export. + user32: Move IME window procedure to user32. + msvcrt: Initialize file descriptor critical section. + msvcrt: Rename msvcrt_get_ioinfo function. + msvcrt: Use fd critical section in _commit. + msvcrt: Use fd critical section in _close. + +Qian Hong (2): + user32: Add more exception handlings for timer callbacks. + user32/tests: Test exception handling for timer callbacks. + +Sebastian Lackner (20): + iphlpapi: Add stub for CancelMibChangeNotify2. + iphlpapi: Add stub for NotifyIpInterfaceChange. + user32: Fix invalid argument passed to ExtCreateRegion. + kernel32: Set proper error codes if FindFirstFileExW doesn't support specific search_ops / levels. + winealsa.drv: Avoid endless loop if registry keys are not accessible. + kernel32: Implement FindFirstFileExW level FindExInfoBasic. + kernel32/tests: Add tests for FindFirstFileExW level FindExInfoBasic. + winecoreaudio.drv: Avoid endless loop if registry keys are not accessible. + usp10: Silence repeated GSUB_apply_ChainContext[Subst|Pos] FIXMEs. + user32/tests: Add tests for MsgWaitForMultipleObjectsEx. + ntoskrnl.exe: Fix incorrect interpretation of SIB byte when parsing x86 opcode. + krnl386.exe16: Fix incorrect interpretation of SIB byte when parsing x86 opcode. + d3dx9_36: Implement D3DXCreatePolygon. + d3dx9_36/tests: Add tests for D3DXCreatePolygon. + d3dx9_36/tests: Remove code to skip test which should never fail. + ntdll/tests: Add basic tests for Rtl[Add|Remove]VectoredContinueHandler. + ntdll: Implement Rtl[Add|Remove]VectoredContinueHandler semi-stubs. + d3dx9_36: Allow NULL pointer for optional arguments of D3DXIntersectTri. + psapi/tests: Add tests for GetPerformanceInfo function. + kernel32: Fix implementation of K32GetPerformanceInfo. + +Stefan Dösinger (15): + d3d9/tests: Check if the current display settings match the registry settings. + d3d8/tests: Check if the current display settings match the registry settings. + d3d9/tests: The device restores the mode settings from the registry. + d3d8/tests: The device restores the mode settings from the registry. + ddraw/tests: Check if the current display settings match the registry settings. + ddraw/tests: Fix some COM macro versions in test_coop_level_mode_set. + d3d9/tests: Fix some wndproc comparison error messages. + d3d8/tests: Fix some wndproc comparison error messages. + d3d9/tests: Allow passing a resolution to reset_device. + ddraw/tests: Rename modes and rectangles in test_coop_level_mode_set. + ddraw/tests: Ddraw restores the mode settings from the registry. + d3d/tests: Test fog interpolation. + d3d9/tests: Allow passing a resolution to reset_device in d3d9ex. + d3d8/tests: Allow passing a resolution to reset_device. + wined3d: Add new D3DCREATE flags. + +Vincent Povirk (9): + windowscodecs: Fix race condition loading libpng. + windowscodecs: Treat missing GUID list keys as empty. + windowscodecs: Implement MetadataReaderInfo_GetContainerFormats. + windowscodecs: Implement MetadataReaderInfo_GetPatterns. + windowscodecs: Implement MetadataReaderInfo_MatchesPattern. + windowscodecs: Don't check undefined memory in tests on Wine. + windowscodecs: Implement ComponentFactory_CreateMetadataReaderFromContainer. + windowscodecs: Add fallback to unknown metadata reader. + ole32: Add support for pasting CF_BITMAP. -Thomas Faber (1): - wined3d: Use correct FXCAPS constant in wined3d_get_device_caps. +Yifu Wang (1): + msvcp120: Added VS2013 CPP runtime dll. -Vincent Povirk (1): - gdiplus: Process a row instead of a column in inner conversion loop. +YongHao Hu (1): + msvcp90: Add std_Ctraits::Isnan implementation. -- Alexandre Julliard diff -Nru wine1.7-1.7.28/AUTHORS wine1.7-1.7.31/AUTHORS --- wine1.7-1.7.28/AUTHORS 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/AUTHORS 2014-11-14 13:28:17.000000000 +0000 @@ -225,6 +225,7 @@ Charles Vaughn Charles Welton Cheer Xiao +Chen Yuan Chia-I Wu Choe Hwanjin Chris Faherty @@ -313,6 +314,7 @@ David Grant David Hammerton David Hedberg +David Heidelberger David Hemmo David Howells David Kiefer @@ -549,6 +551,7 @@ Ivan de Saedeleer Ivan Gyurdiev Ivan Leo Puoti +Iván Matellanes Ivan Sinitsin Ivan Vojtko Ivan Wong @@ -1440,6 +1443,7 @@ XueFeng Chang Yann Droneaud Yaron Shahrabani +Yifu Wang Yngvi Sigurjonsson Yong Chi YongHao Hu diff -Nru wine1.7-1.7.28/configure wine1.7-1.7.31/configure --- wine1.7-1.7.28/configure 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/configure 2014-11-14 13:28:17.000000000 +0000 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for Wine 1.7.28. +# Generated by GNU Autoconf 2.69 for Wine 1.7.31. # # Report bugs to . # @@ -580,8 +580,8 @@ # Identity of this package. PACKAGE_NAME='Wine' PACKAGE_TARNAME='wine' -PACKAGE_VERSION='1.7.28' -PACKAGE_STRING='Wine 1.7.28' +PACKAGE_VERSION='1.7.31' +PACKAGE_STRING='Wine 1.7.31' PACKAGE_BUGREPORT='wine-devel@winehq.org' PACKAGE_URL='http://www.winehq.org' @@ -1068,6 +1068,7 @@ enable_jscript enable_jsproxy enable_kernel32 +enable_ksuser enable_ktmw32 enable_loadperf enable_localspl @@ -1122,6 +1123,7 @@ enable_msvcm90 enable_msvcp100 enable_msvcp110 +enable_msvcp120 enable_msvcp60 enable_msvcp70 enable_msvcp71 @@ -1129,6 +1131,7 @@ enable_msvcp90 enable_msvcr100 enable_msvcr110 +enable_msvcr120 enable_msvcr70 enable_msvcr71 enable_msvcr80 @@ -1146,6 +1149,7 @@ enable_msxml4 enable_msxml6 enable_nddeapi +enable_ndis_sys enable_netapi32 enable_netcfgx enable_netprofm @@ -1179,6 +1183,7 @@ enable_pidgen enable_powrprof enable_printui +enable_prntvpt enable_propsys enable_psapi enable_pstorec @@ -1363,6 +1368,7 @@ enable_spoolsv enable_start enable_svchost +enable_systeminfo enable_taskkill enable_tasklist enable_taskmgr @@ -1981,7 +1987,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures Wine 1.7.28 to adapt to many kinds of systems. +\`configure' configures Wine 1.7.31 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -2050,7 +2056,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of Wine 1.7.28:";; + short | recursive ) echo "Configuration of Wine 1.7.31:";; esac cat <<\_ACEOF @@ -2246,7 +2252,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -Wine configure 1.7.28 +Wine configure 1.7.31 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2764,7 +2770,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by Wine $as_me 1.7.28, which was +It was created by Wine $as_me 1.7.31, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -7717,9 +7723,31 @@ APPKIT_LIBS="-framework AppKit" LDEXECFLAGS="-image_base 0x7bf00000 -Wl,-segaddr,WINE_DOS,0x00001000,-segaddr,WINE_SHAREDHEAP,0x7f000000,-sectcreate,__TEXT,__info_plist,wine_info.plist" - case $host_os in - darwin11*) LDEXECFLAGS="-Wl,-macosx_version_min,10.6 $LDEXECFLAGS" ;; - esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -Wl,-no_pie" >&5 +$as_echo_n "checking whether the compiler supports -Wl,-no_pie... " >&6; } +if ${ac_cv_cflags__Wl__no_pie+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_wine_try_cflags_saved=$CFLAGS +CFLAGS="$CFLAGS -Wl,-no_pie" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int main(int argc, char **argv) { return 0; } +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_cflags__Wl__no_pie=yes +else + ac_cv_cflags__Wl__no_pie=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +CFLAGS=$ac_wine_try_cflags_saved +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cflags__Wl__no_pie" >&5 +$as_echo "$ac_cv_cflags__Wl__no_pie" >&6; } +if test "x$ac_cv_cflags__Wl__no_pie" = xyes; then : + LDEXECFLAGS="-Wl,-no_pie $LDEXECFLAGS" +fi if test "$ac_cv_header_DiskArbitration_DiskArbitration_h" = "yes" then DISKARBITRATION_LIBS="-framework DiskArbitration -framework CoreFoundation" @@ -9790,7 +9818,7 @@ esac fi - if test "$ac_cv_header_X11_extensions_Xrender_h" = "yes" -a "x$ac_cv_lib_soname_X11" != "x" -a "x$ac_cv_lib_soname_Xext" != "x" + if test "$ac_cv_header_X11_extensions_Xrender_h" = "yes" -a "x$ac_cv_lib_soname_X11" != "x" then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -lXrender" >&5 $as_echo_n "checking for -lXrender... " >&6; } @@ -17034,6 +17062,7 @@ wine_fn_config_test dlls/kernel32/tests kernel32_test wine_fn_config_dll keyboard.drv16 enable_win16 wine_fn_config_dll krnl386.exe16 enable_win16 implib kernel +wine_fn_config_dll ksuser enable_ksuser wine_fn_config_dll ktmw32 enable_ktmw32 wine_fn_config_dll loadperf enable_loadperf implib wine_fn_config_dll localspl enable_localspl po @@ -17111,6 +17140,7 @@ wine_fn_config_dll msvcp100 enable_msvcp100 wine_fn_config_test dlls/msvcp100/tests msvcp100_test wine_fn_config_dll msvcp110 enable_msvcp110 +wine_fn_config_dll msvcp120 enable_msvcp120 wine_fn_config_dll msvcp60 enable_msvcp60 wine_fn_config_test dlls/msvcp60/tests msvcp60_test wine_fn_config_dll msvcp70 enable_msvcp70 @@ -17121,6 +17151,7 @@ wine_fn_config_dll msvcr100 enable_msvcr100 implib wine_fn_config_test dlls/msvcr100/tests msvcr100_test wine_fn_config_dll msvcr110 enable_msvcr110 implib +wine_fn_config_dll msvcr120 enable_msvcr120 implib wine_fn_config_dll msvcr70 enable_msvcr70 implib wine_fn_config_dll msvcr71 enable_msvcr71 implib wine_fn_config_dll msvcr80 enable_msvcr80 implib @@ -17144,6 +17175,7 @@ wine_fn_config_dll msxml4 enable_msxml4 clean wine_fn_config_dll msxml6 enable_msxml6 clean wine_fn_config_dll nddeapi enable_nddeapi implib +wine_fn_config_dll ndis.sys enable_ndis_sys wine_fn_config_dll netapi32 enable_netapi32 implib wine_fn_config_test dlls/netapi32/tests netapi32_test wine_fn_config_dll netcfgx enable_netcfgx clean @@ -17199,6 +17231,7 @@ wine_fn_config_dll pidgen enable_pidgen wine_fn_config_dll powrprof enable_powrprof implib wine_fn_config_dll printui enable_printui +wine_fn_config_dll prntvpt enable_prntvpt wine_fn_config_dll propsys enable_propsys clean,implib wine_fn_config_test dlls/propsys/tests propsys_test wine_fn_config_dll psapi enable_psapi implib @@ -17474,6 +17507,7 @@ wine_fn_config_program spoolsv enable_spoolsv install wine_fn_config_program start enable_start install,po wine_fn_config_program svchost enable_svchost install +wine_fn_config_program systeminfo enable_systeminfo install wine_fn_config_program taskkill enable_taskkill install,po wine_fn_config_program tasklist enable_tasklist install wine_fn_config_program taskmgr enable_taskmgr install,po @@ -18179,7 +18213,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by Wine $as_me 1.7.28, which was +This file was extended by Wine $as_me 1.7.31, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -18250,7 +18284,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -Wine config.status 1.7.28 +Wine config.status 1.7.31 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" diff -Nru wine1.7-1.7.28/configure.ac wine1.7-1.7.31/configure.ac --- wine1.7-1.7.28/configure.ac 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/configure.ac 2014-11-14 13:28:17.000000000 +0000 @@ -760,9 +760,8 @@ AC_SUBST(CORESERVICES_LIBS,"-framework CoreServices") AC_SUBST(APPKIT_LIBS,"-framework AppKit") LDEXECFLAGS="-image_base 0x7bf00000 -Wl,-segaddr,WINE_DOS,0x00001000,-segaddr,WINE_SHAREDHEAP,0x7f000000,-sectcreate,__TEXT,__info_plist,wine_info.plist" - case $host_os in - darwin11*) LDEXECFLAGS="-Wl,-macosx_version_min,10.6 $LDEXECFLAGS" ;; - esac + WINE_TRY_CFLAGS([-Wl,-no_pie], + [LDEXECFLAGS="-Wl,-no_pie $LDEXECFLAGS"]) if test "$ac_cv_header_DiskArbitration_DiskArbitration_h" = "yes" then dnl DiskArbitration API is not public on Darwin < 8.0, use it only if header found @@ -1162,7 +1161,7 @@ [libXxf86vm ${notice_platform}development files not found, XFree86 Vidmode won't be supported.]) dnl *** Check for Transform functions in Xrender - if test "$ac_cv_header_X11_extensions_Xrender_h" = "yes" -a "x$ac_cv_lib_soname_X11" != "x" -a "x$ac_cv_lib_soname_Xext" != "x" + if test "$ac_cv_header_X11_extensions_Xrender_h" = "yes" -a "x$ac_cv_lib_soname_X11" != "x" then WINE_CHECK_SONAME(Xrender,XRenderQueryExtension, [AC_CHECK_LIB(Xrender,XRenderSetPictureTransform, @@ -2943,6 +2942,7 @@ WINE_CONFIG_TEST(dlls/kernel32/tests) WINE_CONFIG_DLL(keyboard.drv16,enable_win16) WINE_CONFIG_DLL(krnl386.exe16,enable_win16,[implib],[kernel]) +WINE_CONFIG_DLL(ksuser) WINE_CONFIG_DLL(ktmw32) WINE_CONFIG_DLL(loadperf,,[implib]) WINE_CONFIG_DLL(localspl,,[po]) @@ -3020,6 +3020,7 @@ WINE_CONFIG_DLL(msvcp100) WINE_CONFIG_TEST(dlls/msvcp100/tests) WINE_CONFIG_DLL(msvcp110) +WINE_CONFIG_DLL(msvcp120) WINE_CONFIG_DLL(msvcp60) WINE_CONFIG_TEST(dlls/msvcp60/tests) WINE_CONFIG_DLL(msvcp70) @@ -3030,6 +3031,7 @@ WINE_CONFIG_DLL(msvcr100,,[implib]) WINE_CONFIG_TEST(dlls/msvcr100/tests) WINE_CONFIG_DLL(msvcr110,,[implib]) +WINE_CONFIG_DLL(msvcr120,,[implib]) WINE_CONFIG_DLL(msvcr70,,[implib]) WINE_CONFIG_DLL(msvcr71,,[implib]) WINE_CONFIG_DLL(msvcr80,,[implib]) @@ -3053,6 +3055,7 @@ WINE_CONFIG_DLL(msxml4,,[clean]) WINE_CONFIG_DLL(msxml6,,[clean]) WINE_CONFIG_DLL(nddeapi,,[implib]) +WINE_CONFIG_DLL(ndis.sys) WINE_CONFIG_DLL(netapi32,,[implib]) WINE_CONFIG_TEST(dlls/netapi32/tests) WINE_CONFIG_DLL(netcfgx,,[clean]) @@ -3108,6 +3111,7 @@ WINE_CONFIG_DLL(pidgen) WINE_CONFIG_DLL(powrprof,,[implib]) WINE_CONFIG_DLL(printui) +WINE_CONFIG_DLL(prntvpt) WINE_CONFIG_DLL(propsys,,[clean,implib]) WINE_CONFIG_TEST(dlls/propsys/tests) WINE_CONFIG_DLL(psapi,,[implib]) @@ -3383,6 +3387,7 @@ WINE_CONFIG_PROGRAM(spoolsv,,[install]) WINE_CONFIG_PROGRAM(start,,[install,po]) WINE_CONFIG_PROGRAM(svchost,,[install]) +WINE_CONFIG_PROGRAM(systeminfo,,[install]) WINE_CONFIG_PROGRAM(taskkill,,[install,po]) WINE_CONFIG_PROGRAM(tasklist,,[install]) WINE_CONFIG_PROGRAM(taskmgr,,[install,po]) diff -Nru wine1.7-1.7.28/debian/changelog wine1.7-1.7.31/debian/changelog --- wine1.7-1.7.28/debian/changelog 2014-10-07 23:14:29.000000000 +0000 +++ wine1.7-1.7.31/debian/changelog 2014-11-16 18:59:07.000000000 +0000 @@ -1,3 +1,26 @@ +wine1.7 (1:1.7.31-0ubuntu1~ppa1) trusty; urgency=medium + + * New upstream release + - New version of the Gecko engine based on Firefox 34. + - Support for the Visual Studio 2013 version of the C/C++ runtimes. + - More font metrics support in DirectWrite. + - Some more Direct2D work. + - Various bug fixes. + * Recommend new gecko version (wine-gecko2.34) + + -- Scott Ritchie Sun, 16 Nov 2014 10:39:03 -0800 + +wine1.7 (1:1.7.30-0ubuntu1~ppa1) trusty; urgency=medium + + * New upstream release + - More support for fonts in DirectWrite. + - Improved ATL thunk support. + - A few more C runtime functions. + - Regedit import/export fixes. + - Various bug fixes. + + -- Maarten Lankhorst Wed, 05 Nov 2014 12:13:08 +0100 + wine1.7 (1:1.7.28-0ubuntu2~ppa1) trusty; urgency=medium * Last version was overwritten accidentally, reuploading diff -Nru wine1.7-1.7.28/debian/control wine1.7-1.7.31/debian/control --- wine1.7-1.7.28/debian/control 2014-10-06 22:49:19.000000000 +0000 +++ wine1.7-1.7.31/debian/control 2014-11-16 18:43:04.000000000 +0000 @@ -96,7 +96,7 @@ libxxf86vm1, p11-kit-modules, unixodbc, - wine-gecko2.24, + wine-gecko2.34, wine-mono4.5.2 Replaces: wine-i386, wine1.4-i386, wine1.5-i386, wine1.6-i386 Conflicts: wine-i386 @@ -148,7 +148,7 @@ libxxf86vm1, p11-kit-modules, unixodbc, - wine-gecko2.24, + wine-gecko2.34, wine-mono4.5.2 Replaces: wine-amd64, wine1.4-amd64, wine1.5-amd64, wine1.6-amd64 Conflicts: wine-amd64 diff -Nru wine1.7-1.7.28/dlls/advapi32/advapi32.spec wine1.7-1.7.31/dlls/advapi32/advapi32.spec --- wine1.7-1.7.28/dlls/advapi32/advapi32.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/advapi32/advapi32.spec 2014-11-14 13:28:17.000000000 +0000 @@ -806,7 +806,7 @@ # @ stub WmiMofEnumerateResourcesW # @ stub WmiNotificationRegistrationA # @ stub WmiNotificationRegistrationW -@ stub WmiOpenBlock +@ stdcall WmiOpenBlock(ptr long ptr) # @ stub WmiOpenTraceWithCursor # @ stub WmiParseTraceEvent # @ stub WmiQueryAllDataA diff -Nru wine1.7-1.7.28/dlls/advapi32/eventlog.c wine1.7-1.7.31/dlls/advapi32/eventlog.c --- wine1.7-1.7.28/dlls/advapi32/eventlog.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/advapi32/eventlog.c 2014-11-14 13:28:17.000000000 +0000 @@ -997,3 +997,12 @@ FIXME("%p %d %p: stub\n", propertiesarray, arraycount, guidcount); return ERROR_INVALID_PARAMETER; } + +/****************************************************************************** + * WmiOpenBlock [ADVAPI32.@] + */ +NTSTATUS WINAPI WmiOpenBlock(GUID *guid, ULONG access, PVOID *datablock) +{ + FIXME("%s %d %p: stub\n", debugstr_guid(guid), access, datablock); + return ERROR_SUCCESS; +} diff -Nru wine1.7-1.7.28/dlls/advapi32/lsa.c wine1.7-1.7.31/dlls/advapi32/lsa.c --- wine1.7-1.7.28/dlls/advapi32/lsa.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/advapi32/lsa.c 2014-11-14 13:28:17.000000000 +0000 @@ -118,7 +118,7 @@ ULONG count) { FIXME("(%p,%p,%p,0x%08x) stub\n", policy, sid, rights, count); - return STATUS_OBJECT_NAME_NOT_FOUND; + return STATUS_SUCCESS; } /****************************************************************************** diff -Nru wine1.7-1.7.28/dlls/advapi32/tests/registry.c wine1.7-1.7.31/dlls/advapi32/tests/registry.c --- wine1.7-1.7.28/dlls/advapi32/tests/registry.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/advapi32/tests/registry.c 2014-11-14 13:28:17.000000000 +0000 @@ -517,6 +517,33 @@ res = RegSetValueExA( test_key, "Test", 0, REG_BINARY, NULL, 0 ); ok( ERROR_SUCCESS == res || ERROR_INVALID_PARAMETER == res, "RegSetValueExA returned %d\n", res ); + /* test reading the value and data without setting them */ + val_count = 20; + data_count = 20; + type = 1234; + strcpy( value, "xxxxxxxxxx" ); + strcpy( data, "xxxxxxxxxx" ); + res = RegEnumValueA( test_key, 0, value, &val_count, NULL, &type, (LPBYTE)data, &data_count ); + ok( res == ERROR_SUCCESS, "expected ERROR_SUCCESS, got %d\n", res ); + ok( val_count == 4, "val_count set to %d instead of 4\n", val_count ); + ok( data_count == 0, "data_count set to %d instead of 0\n", data_count ); + ok( type == REG_BINARY, "type %d is not REG_BINARY\n", type ); + ok( !strcmp( value, "Test" ), "value is '%s' instead of Test\n", value ); + ok( !strcmp( data, "xxxxxxxxxx" ), "data is '%s' instead of xxxxxxxxxx\n", data ); + + val_count = 20; + data_count = 20; + type = 1234; + memcpy( valueW, xxxW, sizeof(xxxW) ); + memcpy( dataW, xxxW, sizeof(xxxW) ); + res = RegEnumValueW( test_key, 0, valueW, &val_count, NULL, &type, (BYTE*)dataW, &data_count ); + ok( res == ERROR_SUCCESS, "expected ERROR_SUCCESS, got %d\n", res ); + ok( val_count == 4, "val_count set to %d instead of 4\n", val_count ); + ok( data_count == 0, "data_count set to %d instead of 0\n", data_count ); + ok( type == REG_BINARY, "type %d is not REG_BINARY\n", type ); + ok( !memcmp( valueW, testW, sizeof(testW) ), "value is not 'Test'\n" ); + ok( !memcmp( dataW, xxxW, sizeof(xxxW) ), "data is not 'xxxxxxxxxx'\n" ); + res = RegSetValueExA( test_key, "Test", 0, REG_SZ, (const BYTE *)"foobar", 7 ); ok( res == 0, "RegSetValueExA failed error %d\n", res ); @@ -926,6 +953,11 @@ ok(hkResult != NULL, "hkResult != NULL\n"); RegCloseKey(hkResult); + /* trailing slashes */ + ret = RegOpenKeyA(HKEY_CURRENT_USER, "Software\\Wine\\Test\\\\", &hkResult); + ok(ret == ERROR_SUCCESS, "expected ERROR_SUCCESS, got %d\n", ret); + RegCloseKey(hkResult); + /* open nonexistent key * check that hkResult is set to NULL */ @@ -1109,7 +1141,7 @@ ok(error == ERROR_SUCCESS, "Expected RegSetKeySecurity to return success, got error %u\n", error); - bRet = RegSetKeySecurity(hkRoot32, DACL_SECURITY_INFORMATION, sd); + error = RegSetKeySecurity(hkRoot32, DACL_SECURITY_INFORMATION, sd); ok(error == ERROR_SUCCESS, "Expected RegSetKeySecurity to return success, got error %u\n", error); @@ -1187,10 +1219,16 @@ ok(ret == ERROR_BAD_PATHNAME, "expected ERROR_BAD_PATHNAME, got %d\n", ret); else { ok(!ret, "RegCreateKeyExA failed with error %d\n", ret); - RegDeleteKeyA(hkey1, NULL); + RegDeleteKeyA(hkey1, ""); RegCloseKey(hkey1); } + /* trailing backslash characters */ + ret = RegCreateKeyExA(hkey_main, "Subkey4\\\\", 0, NULL, 0, KEY_NOTIFY, NULL, &hkey1, NULL); + ok(ret == ERROR_SUCCESS, "RegCreateKeyExA failed with error %d\n", ret); + RegDeleteKeyA(hkey1, ""); + RegCloseKey(hkey1); + /* WOW64 flags - open an existing key */ hkey1 = NULL; ret = RegCreateKeyExA(HKEY_LOCAL_MACHINE, "Software", 0, NULL, 0, KEY_READ|KEY_WOW64_32KEY, NULL, &hkey1, NULL); @@ -1334,6 +1372,7 @@ static void test_reg_delete_key(void) { DWORD ret; + HKEY key; ret = RegDeleteKeyA(hkey_main, NULL); @@ -1352,6 +1391,15 @@ ret == ERROR_ACCESS_DENIED || ret == ERROR_BADKEY, /* Win95 */ "ret=%d\n", ret); + + ret = RegCreateKeyA(hkey_main, "deleteme", &key); + ok(ret == ERROR_SUCCESS, "Could not create key, got %d\n", ret); + ret = RegDeleteKeyA(key, ""); + ok(ret == ERROR_SUCCESS, "RegDeleteKeyA failed, got %d\n", ret); + RegCloseKey(key); + ret = RegOpenKeyA(hkey_main, "deleteme", &key); + ok(ret == ERROR_FILE_NOT_FOUND, "Key was not deleted, got %d\n", ret); + RegCloseKey(key); } static void test_reg_save_key(void) @@ -1519,7 +1567,7 @@ ret = RegQueryValueA(hkey_main, "subkey", val, NULL); ok(ret == ERROR_INVALID_PARAMETER, "Expected ERROR_INVALID_PARAMETER, got %d\n", ret); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); - ok(lstrlenA(val) == 0, "Expected val to be untouched, got %s\n", val); + ok(!val[0], "Expected val to be untouched, got %s\n", val); /* try a NULL value and size */ ret = RegQueryValueA(hkey_main, "subkey", NULL, NULL); @@ -1532,7 +1580,7 @@ ret = RegQueryValueA(hkey_main, "subkey", val, &size); ok(ret == ERROR_MORE_DATA, "Expected ERROR_MORE_DATA, got %d\n", ret); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); - ok(lstrlenA(val) == 0, "Expected val to be untouched, got %s\n", val); + ok(!val[0], "Expected val to be untouched, got %s\n", val); ok(size == 5, "Expected 5, got %d\n", size); /* successfully read the value using 'subkey' */ @@ -1561,7 +1609,7 @@ } ok(ret == ERROR_MORE_DATA, "Expected ERROR_MORE_DATA, got %d\n", ret); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); - ok(lstrlenW(valW) == 0, "Expected valW to be untouched\n"); + ok(!valW[0], "Expected valW to be untouched\n"); ok(size == sizeof(expected), "Got wrong size: %d\n", size); /* unicode - try size in WCHARS */ @@ -1570,7 +1618,7 @@ ret = RegQueryValueW(subkey, NULL, valW, &size); ok(ret == ERROR_MORE_DATA, "Expected ERROR_MORE_DATA, got %d\n", ret); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); - ok(lstrlenW(valW) == 0, "Expected valW to be untouched\n"); + ok(!valW[0], "Expected valW to be untouched\n"); ok(size == sizeof(expected), "Got wrong size: %d\n", size); /* unicode - successfully read the value */ @@ -1737,8 +1785,7 @@ ret = RegQueryValueA(subkey, NULL, buffer, &size); ok(ret == ERROR_SUCCESS, "Default value of subkey is not present\n"); - ok(!lstrlenA(buffer), - "Expected length 0 got length %u(%s)\n", lstrlenA(buffer), buffer); + ok(!buffer[0], "Expected length 0 got length %u(%s)\n", lstrlenA(buffer), buffer); size = MAX_PATH; ok(RegQueryValueA(subkey, "value", buffer, &size), "Value is still present\n"); diff -Nru wine1.7-1.7.28/dlls/advapi32/tests/security.c wine1.7-1.7.31/dlls/advapi32/tests/security.c --- wine1.7-1.7.28/dlls/advapi32/tests/security.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/advapi32/tests/security.c 2014-11-14 13:28:17.000000000 +0000 @@ -920,7 +920,6 @@ rc &= ~(FILE_ATTRIBUTE_NOT_CONTENT_INDEXED|FILE_ATTRIBUTE_COMPRESSED); ok(rc == FILE_ATTRIBUTE_ARCHIVE, "expected FILE_ATTRIBUTE_ARCHIVE got %#x\n", rc); - retSize = 0xdeadbeef; rc = GetFileSecurityA(file, OWNER_SECURITY_INFORMATION|GROUP_SECURITY_INFORMATION|DACL_SECURITY_INFORMATION, NULL, 0, &sdSize); ok(!rc, "GetFileSecurity should fail\n"); diff -Nru wine1.7-1.7.28/dlls/advapi32/tests/service.c wine1.7-1.7.31/dlls/advapi32/tests/service.c --- wine1.7-1.7.28/dlls/advapi32/tests/service.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/advapi32/tests/service.c 2014-11-14 13:28:17.000000000 +0000 @@ -1398,8 +1398,8 @@ SERVICE_STATUS status = services[i].ServiceStatus; /* lpServiceName and lpDisplayName should always be filled */ - ok(lstrlenA(services[i].lpServiceName) > 0, "Expected a service name\n"); - ok(lstrlenA(services[i].lpDisplayName) > 0, "Expected a display name\n"); + ok(services[i].lpServiceName[0], "Expected a service name\n"); + ok(services[i].lpDisplayName[0], "Expected a display name\n"); /* Decrement the counters to see if the functions calls return the same * numbers as the contents of these structures. @@ -1701,8 +1701,8 @@ SERVICE_STATUS_PROCESS status = exservices[i].ServiceStatusProcess; /* lpServiceName and lpDisplayName should always be filled */ - ok(lstrlenA(exservices[i].lpServiceName) > 0, "Expected a service name\n"); - ok(lstrlenA(exservices[i].lpDisplayName) > 0, "Expected a display name\n"); + ok(exservices[i].lpServiceName[0], "Expected a service name\n"); + ok(exservices[i].lpDisplayName[0], "Expected a display name\n"); /* Decrement the counters to see if the functions calls return the * same numbers as the contents of these structures. diff -Nru wine1.7-1.7.28/dlls/advpack/advpack.c wine1.7-1.7.31/dlls/advpack/advpack.c --- wine1.7-1.7.28/dlls/advpack/advpack.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/advpack/advpack.c 2014-11-14 13:28:17.000000000 +0000 @@ -679,7 +679,7 @@ dwBufferSize, NULL, NULL); } else - res = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + res = E_NOT_SUFFICIENT_BUFFER; } HeapFree(GetProcessHeap(), 0, bufferW); @@ -739,7 +739,7 @@ pszBuffer, dwBufferSize, pdwRequiredSize)) { if (dwBufferSize < *pdwRequiredSize) - hret = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + hret = E_NOT_SUFFICIENT_BUFFER; else hret = SPAPI_E_LINE_NOT_FOUND; } @@ -796,7 +796,7 @@ dwBufferSize, NULL, NULL); } else - res = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + res = E_NOT_SUFFICIENT_BUFFER; } HeapFree(GetProcessHeap(), 0, bufferW); @@ -854,7 +854,7 @@ pszBuffer, dwBufferSize, pdwRequiredSize)) { if (dwBufferSize < *pdwRequiredSize) - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; return SPAPI_E_LINE_NOT_FOUND; } diff -Nru wine1.7-1.7.28/dlls/advpack/tests/advpack.c wine1.7-1.7.31/dlls/advpack/tests/advpack.c --- wine1.7-1.7.28/dlls/advpack/tests/advpack.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/advpack/tests/advpack.c 2014-11-14 13:28:17.000000000 +0000 @@ -187,7 +187,6 @@ CloseHandle(hn); hr = pDelNode(lstrcatA(currDir, "\\DelNodeTestDir"), 0); ok (hr == S_OK, "DelNode failed deleting a directory containing multiple files\n"); - currDir[currDirLen] = '\0'; } static void append_str(char **str, const char *data, ...) diff -Nru wine1.7-1.7.28/dlls/api-ms-win-core-errorhandling-l1-1-1/api-ms-win-core-errorhandling-l1-1-1.spec wine1.7-1.7.31/dlls/api-ms-win-core-errorhandling-l1-1-1/api-ms-win-core-errorhandling-l1-1-1.spec --- wine1.7-1.7.28/dlls/api-ms-win-core-errorhandling-l1-1-1/api-ms-win-core-errorhandling-l1-1-1.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/api-ms-win-core-errorhandling-l1-1-1/api-ms-win-core-errorhandling-l1-1-1.spec 2014-11-14 13:28:17.000000000 +0000 @@ -1,9 +1,9 @@ -@ stub AddVectoredContinueHandler +@ stdcall AddVectoredContinueHandler(long ptr) kernel32.AddVectoredContinueHandler @ stdcall AddVectoredExceptionHandler(long ptr) kernel32.AddVectoredExceptionHandler @ stdcall GetErrorMode() kernel32.GetErrorMode @ stdcall GetLastError() kernel32.GetLastError @ stdcall RaiseException(long long long ptr) kernel32.RaiseException -@ stub RemoveVectoredContinueHandler +@ stdcall RemoveVectoredContinueHandler(ptr) kernel32.RemoveVectoredContinueHandler @ stdcall RemoveVectoredExceptionHandler(ptr) kernel32.RemoveVectoredExceptionHandler @ stdcall RestoreLastError(long) kernel32.RestoreLastError @ stdcall SetErrorMode(long) kernel32.SetErrorMode diff -Nru wine1.7-1.7.28/dlls/api-ms-win-core-memory-l1-1-1/api-ms-win-core-memory-l1-1-1.spec wine1.7-1.7.31/dlls/api-ms-win-core-memory-l1-1-1/api-ms-win-core-memory-l1-1-1.spec --- wine1.7-1.7.28/dlls/api-ms-win-core-memory-l1-1-1/api-ms-win-core-memory-l1-1-1.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/api-ms-win-core-memory-l1-1-1/api-ms-win-core-memory-l1-1-1.spec 2014-11-14 13:28:17.000000000 +0000 @@ -5,7 +5,7 @@ @ stdcall FlushViewOfFile(ptr long) kernel32.FlushViewOfFile @ stub GetLargePageMinimum @ stub GetProcessWorkingSetSizeEx -@ stub GetSystemFileCacheSize +@ stdcall GetSystemFileCacheSize(ptr ptr ptr) kernel32.GetSystemFileCacheSize @ stdcall GetWriteWatch(long ptr long ptr ptr ptr) kernel32.GetWriteWatch @ stdcall MapViewOfFile(long long long long long) kernel32.MapViewOfFile @ stdcall MapViewOfFileEx(long long long long long ptr) kernel32.MapViewOfFileEx @@ -16,7 +16,7 @@ @ stdcall ReadProcessMemory(long ptr ptr long ptr) kernel32.ReadProcessMemory @ stdcall ResetWriteWatch(ptr long) kernel32.ResetWriteWatch @ stub SetProcessWorkingSetSizeEx -@ stub SetSystemFileCacheSize +@ stdcall SetSystemFileCacheSize(long long long) kernel32.SetSystemFileCacheSize @ stdcall UnmapViewOfFile(ptr) kernel32.UnmapViewOfFile @ stub UnmapViewOfFileEx @ stdcall VirtualAlloc(ptr long long long) kernel32.VirtualAlloc diff -Nru wine1.7-1.7.28/dlls/appwiz.cpl/addons.c wine1.7-1.7.31/dlls/appwiz.cpl/addons.c --- wine1.7-1.7.28/dlls/appwiz.cpl/addons.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/appwiz.cpl/addons.c 2014-11-14 13:28:17.000000000 +0000 @@ -52,14 +52,14 @@ WINE_DEFAULT_DEBUG_CHANNEL(appwizcpl); -#define GECKO_VERSION "2.24" +#define GECKO_VERSION "2.34" #ifdef __i386__ #define ARCH_STRING "x86" -#define GECKO_SHA "b4923c0565e6cbd20075a0d4119ce3b48424f962" +#define GECKO_SHA "e9646cf9d683a6f4e254bcff3864a863fe8287e9" #elif defined(__x86_64__) #define ARCH_STRING "x86_64" -#define GECKO_SHA "da65fb99a53d87c831030ec8787e31d797f60e60" +#define GECKO_SHA "2b4274f7c3b22b74c35ebc0423bb943597af3945" #else #define ARCH_STRING "" #define GECKO_SHA "???" diff -Nru wine1.7-1.7.28/dlls/appwiz.cpl/appwiz.c wine1.7-1.7.31/dlls/appwiz.cpl/appwiz.c --- wine1.7-1.7.28/dlls/appwiz.cpl/appwiz.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/appwiz.cpl/appwiz.c 2014-11-14 13:28:17.000000000 +0000 @@ -567,7 +567,7 @@ /* if hKey is null, lpKeyName contains the string we want to check */ if (hKey == NULL) { - if ((lpKeyName) && (lstrlenW(lpKeyName) > 0)) + if (lpKeyName && lpKeyName[0]) SetWindowTextW(hWndDlgItem, lpKeyName); else SetWindowTextW(hWndDlgItem, lpAltMessage); @@ -577,7 +577,7 @@ buflen = MAX_STRING_LEN; if ((RegQueryValueExW(hKey, lpKeyName, 0, 0, (LPBYTE) buf, &buflen) == - ERROR_SUCCESS) && (lstrlenW(buf) > 0)) + ERROR_SUCCESS) && buf[0]) SetWindowTextW(hWndDlgItem, buf); else SetWindowTextW(hWndDlgItem, lpAltMessage); diff -Nru wine1.7-1.7.28/dlls/atl/registrar.c wine1.7-1.7.31/dlls/atl/registrar.c --- wine1.7-1.7.28/dlls/atl/registrar.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/atl/registrar.c 2014-11-14 13:28:17.000000000 +0000 @@ -184,7 +184,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOOL do_register) { - LPCOLESTR iter = *pstr; + LPCOLESTR iter; HRESULT hres; LONG lres; HKEY hkey = 0; @@ -380,7 +380,7 @@ { LPCOLESTR iter = data; strbuf buf; - HRESULT hres = S_OK; + HRESULT hres; unsigned int i; strbuf_init(&buf); diff -Nru wine1.7-1.7.28/dlls/authz/authz.c wine1.7-1.7.31/dlls/authz/authz.c --- wine1.7-1.7.28/dlls/authz/authz.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/authz/authz.c 2014-11-14 13:28:17.000000000 +0000 @@ -56,3 +56,14 @@ SetLastError(ERROR_CALL_NOT_IMPLEMENTED); return FALSE; } + + +/*********************************************************************** + * AuthzInstallSecurityEventSource (AUTHZ.@) + */ +BOOL WINAPI AuthzInstallSecurityEventSource(DWORD dwFlags, LPVOID pRegistration) +{ + FIXME("(0x%X,%p): stub\n", dwFlags, pRegistration); + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} diff -Nru wine1.7-1.7.28/dlls/authz/authz.spec wine1.7-1.7.31/dlls/authz/authz.spec --- wine1.7-1.7.28/dlls/authz/authz.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/authz/authz.spec 2014-11-14 13:28:17.000000000 +0000 @@ -14,7 +14,7 @@ @ stub AuthzInitializeObjectAccessAuditEvent @ stub AuthzInitializeObjectAccessAuditEvent2 @ stdcall AuthzInitializeResourceManager(long ptr ptr ptr wstr ptr) -@ stub AuthzInstallSecurityEventSource +@ stdcall AuthzInstallSecurityEventSource(long ptr) @ stub AuthzOpenObjectAudit @ stub AuthzRegisterSecurityEventSource @ stub AuthzReportSecurityEvent diff -Nru wine1.7-1.7.28/dlls/avifil32/avifile.c wine1.7-1.7.31/dlls/avifil32/avifile.c --- wine1.7-1.7.28/dlls/avifil32/avifile.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/avifil32/avifile.c 2014-11-14 13:28:17.000000000 +0000 @@ -465,13 +465,12 @@ This->ppStreams[nStream] != NULL) { /* ... so delete it now */ HeapFree(GetProcessHeap(), 0, This->ppStreams[nStream]); - - if (This->fInfo.dwStreams - nStream > 0) - memcpy(This->ppStreams + nStream, This->ppStreams + nStream + 1, - (This->fInfo.dwStreams - nStream) * sizeof(IAVIStreamImpl*)); + This->fInfo.dwStreams--; + if (nStream < This->fInfo.dwStreams) + memmove(&This->ppStreams[nStream], &This->ppStreams[nStream + 1], + (This->fInfo.dwStreams - nStream) * sizeof(This->ppStreams[0])); This->ppStreams[This->fInfo.dwStreams] = NULL; - This->fInfo.dwStreams--; This->fDirty = TRUE; /* This->fInfo will be updated further when asked for */ @@ -1461,7 +1460,7 @@ dwPos += ((pStream->cbFormat + 1) & ~1U); if (pStream->lpHandlerData != NULL && pStream->cbHandlerData > 0) dwPos += 2 * sizeof(DWORD) + ((pStream->cbHandlerData + 1) & ~1U); - if (lstrlenW(pStream->sInfo.szName) > 0) + if (pStream->sInfo.szName[0]) dwPos += 2 * sizeof(DWORD) + ((lstrlenW(pStream->sInfo.szName) + 1) & ~1U); } @@ -2220,7 +2219,7 @@ } /* ... an optional name for this stream ... */ - if (lstrlenW(pStream->sInfo.szName) > 0) { + if (pStream->sInfo.szName[0]) { LPSTR str; ck.ckid = ckidSTREAMNAME; diff -Nru wine1.7-1.7.28/dlls/avifil32/editstream.c wine1.7-1.7.31/dlls/avifil32/editstream.c --- wine1.7-1.7.28/dlls/avifil32/editstream.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/avifil32/editstream.c 2014-11-14 13:28:17.000000000 +0000 @@ -169,10 +169,9 @@ /* remove part nr */ IAVIStream_Release(This->pStreams[nr].pStream); This->nStreams--; - if (This->nStreams - nr > 0) { - memmove(This->pStreams + nr, This->pStreams + nr + 1, - (This->nStreams - nr) * sizeof(EditStreamTable)); - } + if (nr < This->nStreams) + memmove(&This->pStreams[nr], &This->pStreams[nr + 1], + (This->nStreams - nr) * sizeof(This->pStreams[0])); This->pStreams[This->nStreams].pStream = NULL; This->pStreams[This->nStreams].dwStart = 0; This->pStreams[This->nStreams].dwLength = 0; diff -Nru wine1.7-1.7.28/dlls/bcrypt/bcrypt_main.c wine1.7-1.7.31/dlls/bcrypt/bcrypt_main.c --- wine1.7-1.7.28/dlls/bcrypt/bcrypt_main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/bcrypt/bcrypt_main.c 2014-11-14 13:28:17.000000000 +0000 @@ -108,3 +108,10 @@ *enabled = FALSE; return STATUS_SUCCESS; } + +NTSTATUS WINAPI BCryptGetProperty(BCRYPT_HANDLE obj, LPCWSTR prop, UCHAR *buffer, ULONG count, ULONG *res, ULONG flags) +{ + FIXME("%p, %s, %p, %u, %p, %08x - stub\n", obj, wine_dbgstr_w(prop), buffer, count, res, flags); + + return STATUS_NOT_IMPLEMENTED; +} diff -Nru wine1.7-1.7.28/dlls/bcrypt/bcrypt.spec wine1.7-1.7.31/dlls/bcrypt/bcrypt.spec --- wine1.7-1.7.28/dlls/bcrypt/bcrypt.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/bcrypt/bcrypt.spec 2014-11-14 13:28:17.000000000 +0000 @@ -28,7 +28,7 @@ @ stub BCryptGenerateKeyPair @ stub BCryptGenerateSymmetricKey @ stdcall BCryptGetFipsAlgorithmMode(ptr) -@ stub BCryptGetProperty +@ stdcall BCryptGetProperty(ptr wstr ptr long ptr long) @ stub BCryptHashData @ stub BCryptImportKey @ stub BCryptImportKeyPair diff -Nru wine1.7-1.7.28/dlls/cfgmgr32/cfgmgr32.spec wine1.7-1.7.31/dlls/cfgmgr32/cfgmgr32.spec --- wine1.7-1.7.28/dlls/cfgmgr32/cfgmgr32.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/cfgmgr32/cfgmgr32.spec 2014-11-14 13:28:17.000000000 +0000 @@ -84,8 +84,8 @@ @ stub CM_Get_Device_Interface_ListW @ stub CM_Get_Device_Interface_List_ExA @ stub CM_Get_Device_Interface_List_ExW -@ stub CM_Get_Device_Interface_List_SizeA -@ stub CM_Get_Device_Interface_List_SizeW +@ stdcall CM_Get_Device_Interface_List_SizeA(ptr ptr str long) setupapi.CM_Get_Device_Interface_List_SizeA +@ stdcall CM_Get_Device_Interface_List_SizeW(ptr ptr wstr long) setupapi.CM_Get_Device_Interface_List_SizeW @ stdcall CM_Get_Device_Interface_List_Size_ExA(ptr ptr str long ptr) setupapi.CM_Get_Device_Interface_List_Size_ExA @ stdcall CM_Get_Device_Interface_List_Size_ExW(ptr ptr wstr long ptr) setupapi.CM_Get_Device_Interface_List_Size_ExW @ stub CM_Get_First_Log_Conf diff -Nru wine1.7-1.7.28/dlls/comctl32/comctl32undoc.c wine1.7-1.7.31/dlls/comctl32/comctl32undoc.c --- wine1.7-1.7.28/dlls/comctl32/comctl32undoc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/comctl32undoc.c 2014-11-14 13:28:17.000000000 +0000 @@ -690,8 +690,8 @@ /* get values from key 'MRUList' */ if (newkey) { datasize = (mp->extview.uMax + 1) * sizeof(WCHAR); - if((err=RegQueryValueExW( newkey, strMRUList, 0, &type, - (LPBYTE)mp->realMRU, &datasize))) { + if (RegQueryValueExW( newkey, strMRUList, 0, &type, + (LPBYTE)mp->realMRU, &datasize)) { /* not present - set size to 1 (will become 0 later) */ datasize = 1; *mp->realMRU = 0; diff -Nru wine1.7-1.7.28/dlls/comctl32/imagelist.c wine1.7-1.7.31/dlls/comctl32/imagelist.c --- wine1.7-1.7.28/dlls/comctl32/imagelist.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/imagelist.c 2014-11-14 13:28:17.000000000 +0000 @@ -599,6 +599,7 @@ INT dxHotspot, INT dyHotspot) { INT cx, cy; + POINT src, dst; TRACE("(himlTrack=%p iTrack=%d dx=%d dy=%d)\n", himlTrack, iTrack, dxHotspot, dyHotspot); @@ -606,8 +607,11 @@ if (!is_valid(himlTrack)) return FALSE; + if (iTrack >= himlTrack->cCurImage) + return FALSE; + if (InternalDrag.himl) - ImageList_EndDrag (); + return FALSE; cx = himlTrack->cx; cy = himlTrack->cy; @@ -622,10 +626,12 @@ InternalDrag.dyHotspot = dyHotspot; /* copy image */ - BitBlt (InternalDrag.himl->hdcImage, 0, 0, cx, cy, himlTrack->hdcImage, iTrack * cx, 0, SRCCOPY); - - /* copy mask */ - BitBlt (InternalDrag.himl->hdcMask, 0, 0, cx, cy, himlTrack->hdcMask, iTrack * cx, 0, SRCCOPY); + imagelist_point_from_index(InternalDrag.himl, 0, &dst); + imagelist_point_from_index(himlTrack, iTrack, &src); + BitBlt(InternalDrag.himl->hdcImage, dst.x, dst.y, cx, cy, himlTrack->hdcImage, src.x, src.y, + SRCCOPY); + BitBlt(InternalDrag.himl->hdcMask, dst.x, dst.y, cx, cy, himlTrack->hdcMask, src.x, src.y, + SRCCOPY); InternalDrag.himl->cCurImage = 1; diff -Nru wine1.7-1.7.28/dlls/comctl32/propsheet.c wine1.7-1.7.31/dlls/comctl32/propsheet.c --- wine1.7-1.7.28/dlls/comctl32/propsheet.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/propsheet.c 2014-11-14 13:28:17.000000000 +0000 @@ -2430,15 +2430,16 @@ HWND hwndBack = GetDlgItem(hwndDlg, IDC_BACK_BUTTON); HWND hwndNext = GetDlgItem(hwndDlg, IDC_NEXT_BUTTON); HWND hwndFinish = GetDlgItem(hwndDlg, IDC_FINISH_BUTTON); + BOOL enable_finish = ((dwFlags & PSWIZB_FINISH) || psInfo->hasFinish) && !(dwFlags & PSWIZB_DISABLEDFINISH); TRACE("%d\n", dwFlags); - EnableWindow(hwndBack, FALSE); - EnableWindow(hwndNext, FALSE); - EnableWindow(hwndFinish, FALSE); + EnableWindow(hwndBack, dwFlags & PSWIZB_BACK); + EnableWindow(hwndNext, dwFlags & PSWIZB_NEXT); + EnableWindow(hwndFinish, enable_finish); /* set the default pushbutton to an enabled button */ - if (((dwFlags & PSWIZB_FINISH) || psInfo->hasFinish) && !(dwFlags & PSWIZB_DISABLEDFINISH)) + if (enable_finish) SendMessageW(hwndDlg, DM_SETDEFID, IDC_FINISH_BUTTON, 0); else if (dwFlags & PSWIZB_NEXT) SendMessageW(hwndDlg, DM_SETDEFID, IDC_NEXT_BUTTON, 0); @@ -2447,13 +2448,6 @@ else SendMessageW(hwndDlg, DM_SETDEFID, IDCANCEL, 0); - - if (dwFlags & PSWIZB_BACK) - EnableWindow(hwndBack, TRUE); - - if (dwFlags & PSWIZB_NEXT) - EnableWindow(hwndNext, TRUE); - if (!psInfo->hasFinish) { if ((dwFlags & PSWIZB_FINISH) || (dwFlags & PSWIZB_DISABLEDFINISH)) @@ -2463,9 +2457,6 @@ /* Show the Finish button */ ShowWindow(hwndFinish, SW_SHOW); - - if (!(dwFlags & PSWIZB_DISABLEDFINISH)) - EnableWindow(hwndFinish, TRUE); } else { @@ -2475,8 +2466,6 @@ ShowWindow(hwndNext, SW_SHOW); } } - else if (!(dwFlags & PSWIZB_DISABLEDFINISH)) - EnableWindow(hwndFinish, TRUE); } /****************************************************************************** diff -Nru wine1.7-1.7.28/dlls/comctl32/string.c wine1.7-1.7.31/dlls/comctl32/string.c --- wine1.7-1.7.28/dlls/comctl32/string.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/string.c 2014-11-14 13:28:17.000000000 +0000 @@ -855,16 +855,15 @@ BOOL WINAPI IntlStrEqWorkerA(BOOL bCase, LPCSTR lpszStr, LPCSTR lpszComp, int iLen) { - DWORD dwFlags = LOCALE_USE_CP_ACP; + DWORD dwFlags; int iRet; TRACE("(%d,%s,%s,%d)\n", bCase, debugstr_a(lpszStr), debugstr_a(lpszComp), iLen); /* FIXME: This flag is undocumented and unknown by our CompareString. - * We need a define for it. */ - dwFlags = 0x10000000; + dwFlags = LOCALE_RETURN_GENITIVE_NAMES; if (!bCase) dwFlags |= NORM_IGNORECASE; iRet = CompareStringA(GetThreadLocale(), @@ -891,9 +890,8 @@ debugstr_w(lpszStr),debugstr_w(lpszComp), iLen); /* FIXME: This flag is undocumented and unknown by our CompareString. - * We need a define for it. */ - dwFlags = 0x10000000; + dwFlags = LOCALE_RETURN_GENITIVE_NAMES; if (!bCase) dwFlags |= NORM_IGNORECASE; iRet = CompareStringW(GetThreadLocale(), diff -Nru wine1.7-1.7.28/dlls/comctl32/tests/comboex.c wine1.7-1.7.31/dlls/comctl32/tests/comboex.c --- wine1.7-1.7.28/dlls/comctl32/tests/comboex.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/tests/comboex.c 2014-11-14 13:28:17.000000000 +0000 @@ -127,7 +127,7 @@ static void test_comboboxex(void) { HWND myHwnd = 0; - LONG res = -1; + LONG res; COMBOBOXEXITEMA cbexItem; static const char *first_item = "First Item", *second_item = "Second Item", diff -Nru wine1.7-1.7.28/dlls/comctl32/tests/dpa.c wine1.7-1.7.31/dlls/comctl32/tests/dpa.c --- wine1.7-1.7.28/dlls/comctl32/tests/dpa.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/tests/dpa.c 2014-11-14 13:28:17.000000000 +0000 @@ -271,7 +271,7 @@ ok(rc, "dw2=0x%x\n", dw2); /* Clone into an old DPA */ - p = NULL; SetLastError(ERROR_SUCCESS); + SetLastError(ERROR_SUCCESS); p = pDPA_Clone(dpa, dpa3); ok(p == dpa3, "p=%p\n", p); rc=CheckDPA(dpa3, 0x123456, &dw3); diff -Nru wine1.7-1.7.28/dlls/comctl32/tests/imagelist.c wine1.7-1.7.31/dlls/comctl32/tests/imagelist.c --- wine1.7-1.7.28/dlls/comctl32/tests/imagelist.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/tests/imagelist.c 2014-11-14 13:28:17.000000000 +0000 @@ -253,6 +253,50 @@ #endif /* VISIBLE */ } +static void test_begindrag(void) +{ + HIMAGELIST himl = createImageList(7,13); + HIMAGELIST drag; + BOOL ret; + int count; + POINT hotspot; + + count = ImageList_GetImageCount(himl); + ok(count > 2, "Tests need an ImageList with more than 2 images\n"); + + /* Two BeginDrag() without EndDrag() in between */ + ret = ImageList_BeginDrag(himl, 1, 0, 0); + drag = ImageList_GetDragImage(NULL, NULL); + ok(ret && drag, "ImageList_BeginDrag() failed\n"); + ret = ImageList_BeginDrag(himl, 0, 3, 5); + ok(!ret, "ImageList_BeginDrag() returned TRUE\n"); + drag = ImageList_GetDragImage(NULL, &hotspot); + ok(!!drag, "No active ImageList drag left\n"); + ok(hotspot.x == 0 && hotspot.y == 0, "New ImageList drag was created\n"); + ImageList_EndDrag(); + drag = ImageList_GetDragImage(NULL, NULL); + ok(!drag, "ImageList drag was not destroyed\n"); + + /* Invalid image index */ + ImageList_BeginDrag(himl, 0, 0, 0); + ret = ImageList_BeginDrag(himl, count, 3, 5); + ok(!ret, "ImageList_BeginDrag() returned TRUE\n"); + drag = ImageList_GetDragImage(NULL, &hotspot); + ok(drag && hotspot.x == 0 && hotspot.y == 0, "Active drag should not have been canceled\n"); + ImageList_EndDrag(); + drag = ImageList_GetDragImage(NULL, NULL); + ok(!drag, "ImageList drag was not destroyed\n"); + /* Invalid negative image indexes succeed */ + ret = ImageList_BeginDrag(himl, -17, 0, 0); + drag = ImageList_GetDragImage(NULL, NULL); + ok(ret && drag, "ImageList drag was created\n"); + ImageList_EndDrag(); + ret = ImageList_BeginDrag(himl, -1, 0, 0); + drag = ImageList_GetDragImage(NULL, NULL); + ok(ret && drag, "ImageList drag was created\n"); + ImageList_EndDrag(); +} + static void test_hotspot(void) { struct hotspot { @@ -2087,6 +2131,7 @@ InitCommonControls(); test_create_destroy(); + test_begindrag(); test_hotspot(); test_add_remove(); test_imagecount(); diff -Nru wine1.7-1.7.28/dlls/comctl32/tests/misc.c wine1.7-1.7.31/dlls/comctl32/tests/misc.c --- wine1.7-1.7.28/dlls/comctl32/tests/misc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/tests/misc.c 2014-11-14 13:28:17.000000000 +0000 @@ -75,7 +75,7 @@ static char dest[MAX_PATH]; int sourcelen; int destsize = MAX_PATH; - int count = -1; + int count; sourcelen = strlen(source) + 1; diff -Nru wine1.7-1.7.28/dlls/comctl32/tests/propsheet.c wine1.7-1.7.31/dlls/comctl32/tests/propsheet.c --- wine1.7-1.7.28/dlls/comctl32/tests/propsheet.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/tests/propsheet.c 2014-11-14 13:28:17.000000000 +0000 @@ -279,6 +279,37 @@ return FALSE; } +static WNDPROC old_nav_dialog_proc; + +static LRESULT CALLBACK new_nav_dialog_proc( HWND hwnd, UINT msg, WPARAM wp, LPARAM lp ) +{ + switch (msg) + { + case DM_SETDEFID: + ok( IsWindowEnabled( GetDlgItem(hwnd, wp) ), "button is not enabled\n" ); + break; + } + return CallWindowProcW( old_nav_dialog_proc, hwnd, msg, wp, lp ); +} + +static LRESULT CALLBACK hook_proc( int code, WPARAM wp, LPARAM lp ) +{ + static BOOL done; + if (code == HCBT_CREATEWND) + { + CBT_CREATEWNDW *c = (CBT_CREATEWNDW *)lp; + + /* The first dialog created will be the parent dialog */ + if (!done && c->lpcs->lpszClass == MAKEINTRESOURCEW(WC_DIALOG)) + { + old_nav_dialog_proc = (WNDPROC)SetWindowLongPtrW( (HWND)wp, GWLP_WNDPROC, (LONG_PTR)new_nav_dialog_proc ); + done = TRUE; + } + } + + return CallNextHookEx( NULL, code, wp, lp ); +} + static void test_wiznavigation(void) { HPROPSHEETPAGE hpsp[4]; @@ -291,6 +322,10 @@ BOOL hwndtoindex_supported = TRUE; const INT nextID = 12324; const INT backID = 12323; + HHOOK hook; + + /* set up a hook proc in order to subclass the main dialog early on */ + hook = SetWindowsHookExW( WH_CBT, hook_proc, NULL, GetCurrentThreadId() ); /* create the property sheet pages */ memset(psp, 0, sizeof(PROPSHEETPAGEA) * 4); @@ -400,6 +435,7 @@ ok(defidres == MAKELRESULT(nextID, DC_HASDEFID), "Expected default button ID to be %d, is %d\n", nextID, LOWORD(defidres)); DestroyWindow(hdlg); + UnhookWindowsHookEx( hook ); } static void test_buttons(void) @@ -488,7 +524,7 @@ static void test_custom_default_button(void) { - HWND hdlg; + HWND hdlg, page; PROPSHEETPAGEA psp[1]; PROPSHEETHEADERA psh; MSG msg; @@ -532,7 +568,8 @@ /* At this point, the combobox should have keyboard focus, so we press ENTER. * Pull the lever, Kronk! */ - keybd_event(VK_RETURN, 0, 0, 0); + page = (HWND)SendMessageW(hdlg, PSM_GETCURRENTPAGEHWND, 0, 0); + PostMessageW(GetDlgItem(page, IDC_PS_COMBO1), WM_KEYDOWN, VK_RETURN, 0); /* Process all the messages in the queue for this thread. */ while (PeekMessageA(&msg, NULL, 0, 0, PM_REMOVE)) diff -Nru wine1.7-1.7.28/dlls/comctl32/tests/treeview.c wine1.7-1.7.31/dlls/comctl32/tests/treeview.c --- wine1.7-1.7.28/dlls/comctl32/tests/treeview.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/tests/treeview.c 2014-11-14 13:28:17.000000000 +0000 @@ -663,7 +663,7 @@ static void test_get_set_bkcolor(void) { - COLORREF crColor = RGB(0,0,0); + COLORREF crColor; HWND hTree; hTree = create_treeview_control(0); @@ -719,9 +719,9 @@ static void test_get_set_indent(void) { - int ulIndent = -1; - int ulMinIndent = -1; - int ulMoreThanTwiceMin = -1; + int ulIndent; + int ulMinIndent; + int ulMoreThanTwiceMin; HWND hTree; hTree = create_treeview_control(0); @@ -914,7 +914,7 @@ static void test_get_set_textcolor(void) { /* If the value is -1, the control is using the system color for the text color. */ - COLORREF crColor = RGB(0,0,0); + COLORREF crColor; HWND hTree; hTree = create_treeview_control(0); @@ -974,8 +974,8 @@ static void test_get_set_unicodeformat(void) { - BOOL bPreviousSetting = FALSE; - BOOL bNewSetting = FALSE; + BOOL bPreviousSetting; + BOOL bNewSetting; HWND hTree; hTree = create_treeview_control(0); diff -Nru wine1.7-1.7.28/dlls/comctl32/tooltips.c wine1.7-1.7.31/dlls/comctl32/tooltips.c --- wine1.7-1.7.28/dlls/comctl32/tooltips.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comctl32/tooltips.c 2014-11-14 13:28:17.000000000 +0000 @@ -234,7 +234,7 @@ static inline DWORD TOOLTIPS_notify_customdraw (DWORD dwDrawStage, NMTTCUSTOMDRAW *lpnmttcd) { - LRESULT result = CDRF_DODEFAULT; + LRESULT result; lpnmttcd->nmcd.dwDrawStage = dwDrawStage; TRACE("Notifying stage %d, flags %x, id %x\n", lpnmttcd->nmcd.dwDrawStage, diff -Nru wine1.7-1.7.28/dlls/comdlg32/cdlg.h wine1.7-1.7.31/dlls/comdlg32/cdlg.h --- wine1.7-1.7.28/dlls/comdlg32/cdlg.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comdlg32/cdlg.h 2014-11-14 13:28:17.000000000 +0000 @@ -24,7 +24,7 @@ #include "dlgs.h" /* Common dialogs implementation globals */ -#define COMDLG32_Atom ((ATOM)0xa000) /* MS uses this one to identify props */ +#define COMDLG32_Atom MAKEINTATOM(0xa000) /* MS uses this one to identify props */ extern HINSTANCE COMDLG32_hInstance DECLSPEC_HIDDEN; diff -Nru wine1.7-1.7.28/dlls/comdlg32/filedlg.c wine1.7-1.7.31/dlls/comdlg32/filedlg.c --- wine1.7-1.7.28/dlls/comdlg32/filedlg.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/comdlg32/filedlg.c 2014-11-14 13:28:17.000000000 +0000 @@ -1599,9 +1599,7 @@ /* initdir does not have to be a directory. If a file is * specified, the dir part is taken */ if( PathIsDirectoryW(tmpBuf)) { - if (tmpBuf[lstrlenW(tmpBuf)-1] != '\\') { - lstrcatW(tmpBuf, szwSlash); - } + PathAddBackslashW( tmpBuf ); lstrcatW(tmpBuf, szwStar); } result = GetFullPathNameW(tmpBuf, MAX_PATH, tmpBuf2, &nameBit); @@ -3270,7 +3268,6 @@ int iIndentation; TEXTMETRICW tm; LPSFOLDER tmpFolder; - LookInInfos *liInfos = GetPropA(pDIStruct->hwndItem,LookInInfosStr); UINT shgfi_flags = SHGFI_PIDL | SHGFI_OPENICON | SHGFI_SYSICONINDEX | SHGFI_DISPLAYNAME; UINT icon_width, icon_height; @@ -3293,16 +3290,8 @@ shgfi_flags |= SHGFI_SMALLICON; } - if(pDIStruct->itemID == liInfos->uSelectedItem) - { - ilItemImage = (HIMAGELIST) SHGetFileInfoW ((LPCWSTR) tmpFolder->pidlItem, - 0, &sfi, sizeof (sfi), shgfi_flags ); - } - else - { - ilItemImage = (HIMAGELIST) SHGetFileInfoW ((LPCWSTR) tmpFolder->pidlItem, - 0, &sfi, sizeof (sfi), shgfi_flags ); - } + ilItemImage = (HIMAGELIST) SHGetFileInfoW ((LPCWSTR) tmpFolder->pidlItem, + 0, &sfi, sizeof (sfi), shgfi_flags ); /* Is this item selected ? */ if(pDIStruct->itemState & ODS_SELECTED) @@ -3320,16 +3309,10 @@ /* Do not indent item if drawing in the edit of the combo */ if(pDIStruct->itemState & ODS_COMBOBOXEDIT) - { iIndentation = 0; - ilItemImage = (HIMAGELIST) SHGetFileInfoW ((LPCWSTR) tmpFolder->pidlItem, - 0, &sfi, sizeof (sfi), shgfi_flags ); - - } else - { iIndentation = tmpFolder->m_iIndent; - } + /* Draw text and icon */ /* Initialise the icon display area */ diff -Nru wine1.7-1.7.28/dlls/compobj.dll16/compobj.c wine1.7-1.7.31/dlls/compobj.dll16/compobj.c --- wine1.7-1.7.28/dlls/compobj.dll16/compobj.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/compobj.dll16/compobj.c 2014-11-14 13:28:17.000000000 +0000 @@ -668,18 +668,17 @@ { char *buf,buf2[80]; LONG buf2len; - HRESULT err; HKEY xhkey; buf = HeapAlloc(GetProcessHeap(),0,strlen(progid)+8); sprintf(buf,"%s\\CLSID",progid); - if ((err=RegOpenKeyA(HKEY_CLASSES_ROOT,buf,&xhkey))) { + if (RegOpenKeyA(HKEY_CLASSES_ROOT,buf,&xhkey)) { HeapFree(GetProcessHeap(),0,buf); return CO_E_CLASSSTRING; } HeapFree(GetProcessHeap(),0,buf); buf2len = sizeof(buf2); - if ((err=RegQueryValueA(xhkey,NULL,buf2,&buf2len))) { + if (RegQueryValueA(xhkey,NULL,buf2,&buf2len)) { RegCloseKey(xhkey); return CO_E_CLASSSTRING; } diff -Nru wine1.7-1.7.28/dlls/crypt32/cert.c wine1.7-1.7.31/dlls/crypt32/cert.c --- wine1.7-1.7.28/dlls/crypt32/cert.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/crypt32/cert.c 2014-11-14 13:28:17.000000000 +0000 @@ -984,7 +984,7 @@ { CRYPT_KEY_PROV_INFO copy; WCHAR containerW[MAX_PATH]; - BOOL matches = FALSE; + BOOL matches; MultiByteToWideChar(CP_ACP, 0, container, -1, containerW, sizeof(containerW) / sizeof(containerW[0])); @@ -1142,7 +1142,7 @@ BOOL WINAPI CryptFindCertificateKeyProvInfo(PCCERT_CONTEXT pCert, DWORD dwFlags, void *pvReserved) { - BOOL matches = FALSE; + BOOL matches; TRACE("(%p, %08x, %p)\n", pCert, dwFlags, pvReserved); @@ -2887,7 +2887,7 @@ static BOOL CRYPT_IsBitInFieldSet(const struct BitField *field, DWORD bit) { - BOOL set = FALSE; + BOOL set; DWORD indexIndex = bit / BITS_PER_DWORD; assert(field->cIndexes); @@ -3099,7 +3099,6 @@ CryptMemFree(szProvider); } } - size = sizeof(info.dwKeySpec); /* in case no CRYPT_KEY_PROV_INFO given, * we always use AT_SIGNATURE key spec */ diff -Nru wine1.7-1.7.28/dlls/crypt32/rootstore.c wine1.7-1.7.31/dlls/crypt32/rootstore.c --- wine1.7-1.7.28/dlls/crypt32/rootstore.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/crypt32/rootstore.c 2014-11-14 13:28:17.000000000 +0000 @@ -489,6 +489,7 @@ "/usr/share/ca-certificates/ca-bundle.crt", "/usr/local/share/certs/", "/etc/sfw/openssl/certs", + "/etc/security/cacerts", /* Android */ }; static const BYTE authenticode[] = { diff -Nru wine1.7-1.7.28/dlls/crypt32/tests/ctl.c wine1.7-1.7.31/dlls/crypt32/tests/ctl.c --- wine1.7-1.7.28/dlls/crypt32/tests/ctl.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/crypt32/tests/ctl.c 2014-11-14 13:28:17.000000000 +0000 @@ -390,20 +390,8 @@ signedCTLWithCTLInnerContentAndBadSig, sizeof(signedCTLWithCTLInnerContentAndBadSig), CERT_STORE_ADD_NEW, NULL); - if (ret) - { - /* win9x */ - ok(GetLastError() == CRYPT_E_NOT_FOUND || - GetLastError() == OSS_DATA_ERROR /* some win98 */, - "Expected CRYPT_E_NOT_FOUND, got %08x\n", GetLastError()); - } - else - { - ok(!ret && (GetLastError() == CRYPT_E_EXISTS || - GetLastError() == OSS_DATA_ERROR), - "expected CRYPT_E_EXISTS or OSS_DATA_ERROR, got %d %08x\n", ret, - GetLastError()); - } + ok(!ret && (GetLastError() == CRYPT_E_EXISTS || GetLastError() == OSS_DATA_ERROR), + "expected CRYPT_E_EXISTS or OSS_DATA_ERROR, got %d %08x\n", ret, GetLastError()); CertCloseStore(store, 0); store = CertOpenStore(CERT_STORE_PROV_MEMORY, 0, 0, diff -Nru wine1.7-1.7.28/dlls/crypt32/tests/encode.c wine1.7-1.7.31/dlls/crypt32/tests/encode.c --- wine1.7-1.7.28/dlls/crypt32/tests/encode.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/crypt32/tests/encode.c 2014-11-14 13:28:17.000000000 +0000 @@ -3732,7 +3732,7 @@ case CERT_ALT_NAME_IP_ADDRESS: ok(U(*got).IPAddress.cbData == U(*expected).IPAddress.cbData, "Unexpected IP address length %d\n", U(*got).IPAddress.cbData); - ok(!memcmp(U(*got).IPAddress.pbData, U(*got).IPAddress.pbData, + ok(!memcmp(U(*got).IPAddress.pbData, U(*expected).IPAddress.pbData, U(*got).IPAddress.cbData), "Unexpected value\n"); break; } @@ -5762,7 +5762,6 @@ info.SubjectAlgorithm.Parameters.cbData = 0; info.ThisUpdate.dwLowDateTime = info.ThisUpdate.dwHighDateTime = 0; info.NextUpdate.dwLowDateTime = info.NextUpdate.dwHighDateTime = 0; - info.SubjectAlgorithm.pszObjId = oid2; info.SubjectAlgorithm.pszObjId = NULL; value1.cbData = sizeof(emptySequence); value1.pbData = (LPBYTE)emptySequence; diff -Nru wine1.7-1.7.28/dlls/crypt32/tests/msg.c wine1.7-1.7.31/dlls/crypt32/tests/msg.c --- wine1.7-1.7.28/dlls/crypt32/tests/msg.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/crypt32/tests/msg.c 2014-11-14 13:28:17.000000000 +0000 @@ -2666,12 +2666,12 @@ ok(got->Issuer.cbData == expected->Issuer.cbData, "Expected issuer size %d, got %d\n", expected->Issuer.cbData, got->Issuer.cbData); - ok(!memcmp(got->Issuer.pbData, got->Issuer.pbData, got->Issuer.cbData), + ok(!memcmp(got->Issuer.pbData, expected->Issuer.pbData, got->Issuer.cbData), "Unexpected issuer\n"); ok(got->SerialNumber.cbData == expected->SerialNumber.cbData, "Expected serial number size %d, got %d\n", expected->SerialNumber.cbData, got->SerialNumber.cbData); - ok(!memcmp(got->SerialNumber.pbData, got->SerialNumber.pbData, + ok(!memcmp(got->SerialNumber.pbData, expected->SerialNumber.pbData, got->SerialNumber.cbData), "Unexpected serial number\n"); /* FIXME: check more things */ } diff -Nru wine1.7-1.7.28/dlls/d2d1/brush.c wine1.7-1.7.31/dlls/d2d1/brush.c --- wine1.7-1.7.28/dlls/d2d1/brush.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d2d1/brush.c 2014-11-14 13:28:17.000000000 +0000 @@ -66,7 +66,10 @@ TRACE("%p decreasing refcount to %u.\n", iface, refcount); if (!refcount) + { + HeapFree(GetProcessHeap(), 0, gradient->stops); HeapFree(GetProcessHeap(), 0, gradient); + } return refcount; } @@ -80,15 +83,23 @@ static UINT32 STDMETHODCALLTYPE d2d_gradient_GetGradientStopCount(ID2D1GradientStopCollection *iface) { - FIXME("iface %p stub!\n", iface); + struct d2d_gradient *gradient = impl_from_ID2D1GradientStopCollection(iface); - return 0; + TRACE("iface %p.\n", iface); + + return gradient->stop_count; } static void STDMETHODCALLTYPE d2d_gradient_GetGradientStops(ID2D1GradientStopCollection *iface, D2D1_GRADIENT_STOP *stops, UINT32 stop_count) { - FIXME("iface %p, stops %p, stop_count %u stub!\n", iface, stops, stop_count); + struct d2d_gradient *gradient = impl_from_ID2D1GradientStopCollection(iface); + + TRACE("iface %p, stops %p, stop_count %u.\n", iface, stops, stop_count); + + memcpy(stops, gradient->stops, min(gradient->stop_count, stop_count) * sizeof(*stops)); + if (stop_count > gradient->stop_count) + memset(stops, 0, (stop_count - gradient->stop_count) * sizeof(*stops)); } static D2D1_GAMMA STDMETHODCALLTYPE d2d_gradient_GetColorInterpolationGamma(ID2D1GradientStopCollection *iface) @@ -117,20 +128,29 @@ d2d_gradient_GetExtendMode, }; -void d2d_gradient_init(struct d2d_gradient *gradient, ID2D1RenderTarget *render_target, +HRESULT d2d_gradient_init(struct d2d_gradient *gradient, ID2D1RenderTarget *render_target, const D2D1_GRADIENT_STOP *stops, UINT32 stop_count, D2D1_GAMMA gamma, D2D1_EXTEND_MODE extend_mode) { FIXME("Ignoring gradient properties.\n"); gradient->ID2D1GradientStopCollection_iface.lpVtbl = &d2d_gradient_vtbl; gradient->refcount = 1; + + gradient->stop_count = stop_count; + if (!(gradient->stops = HeapAlloc(GetProcessHeap(), 0, stop_count * sizeof(*stops)))) + return E_OUTOFMEMORY; + memcpy(gradient->stops, stops, stop_count * sizeof(*stops)); + + return S_OK; } static void d2d_brush_init(struct d2d_brush *brush, ID2D1RenderTarget *render_target, - const D2D1_BRUSH_PROPERTIES *desc, const struct ID2D1BrushVtbl *vtbl) + enum d2d_brush_type type, const D2D1_BRUSH_PROPERTIES *desc, const struct ID2D1BrushVtbl *vtbl) { brush->ID2D1Brush_iface.lpVtbl = vtbl; brush->refcount = 1; + brush->opacity = desc ? desc->opacity : 1.0f; + brush->type = type; } static inline struct d2d_brush *impl_from_ID2D1SolidColorBrush(ID2D1SolidColorBrush *iface) @@ -191,7 +211,11 @@ static void STDMETHODCALLTYPE d2d_solid_color_brush_SetOpacity(ID2D1SolidColorBrush *iface, float opacity) { - FIXME("iface %p, opacity %.8e stub!\n", iface, opacity); + struct d2d_brush *brush = impl_from_ID2D1SolidColorBrush(iface); + + TRACE("iface %p, opacity %.8e.\n", iface, opacity); + + brush->opacity = opacity; } static void STDMETHODCALLTYPE d2d_solid_color_brush_SetTransform(ID2D1SolidColorBrush *iface, @@ -224,16 +248,20 @@ static void STDMETHODCALLTYPE d2d_solid_color_brush_SetColor(ID2D1SolidColorBrush *iface, const D2D1_COLOR_F *color) { - FIXME("iface %p, color %p stub!\n", iface, color); + struct d2d_brush *brush = impl_from_ID2D1SolidColorBrush(iface); + + TRACE("iface %p, color %p.\n", iface, color); + + brush->u.solid.color = *color; } static D2D1_COLOR_F * STDMETHODCALLTYPE d2d_solid_color_brush_GetColor(ID2D1SolidColorBrush *iface, D2D1_COLOR_F *color) { - static const D2D1_COLOR_F black = {0.0f, 0.0f, 0.0f, 1.0f}; + struct d2d_brush *brush = impl_from_ID2D1SolidColorBrush(iface); - FIXME("iface %p, color %p stub!\n", iface, color); + TRACE("iface %p, color %p.\n", iface, color); - *color = black; + *color = brush->u.solid.color; return color; } @@ -256,7 +284,9 @@ { FIXME("Ignoring brush properties.\n"); - d2d_brush_init(brush, render_target, desc, (ID2D1BrushVtbl *)&d2d_solid_color_brush_vtbl); + d2d_brush_init(brush, render_target, D2D_BRUSH_TYPE_SOLID, desc, + (ID2D1BrushVtbl *)&d2d_solid_color_brush_vtbl); + brush->u.solid.color = *color; } static inline struct d2d_brush *impl_from_ID2D1LinearGradientBrush(ID2D1LinearGradientBrush *iface) @@ -412,5 +442,15 @@ { FIXME("Ignoring brush properties.\n"); - d2d_brush_init(brush, render_target, brush_desc, (ID2D1BrushVtbl *)&d2d_solid_color_brush_vtbl); + d2d_brush_init(brush, render_target, D2D_BRUSH_TYPE_LINEAR, brush_desc, + (ID2D1BrushVtbl *)&d2d_linear_gradient_brush_vtbl); +} + +struct d2d_brush *unsafe_impl_from_ID2D1Brush(ID2D1Brush *iface) +{ + if (!iface) + return NULL; + assert(iface->lpVtbl == (const ID2D1BrushVtbl *)&d2d_solid_color_brush_vtbl + || iface->lpVtbl == (const ID2D1BrushVtbl *)&d2d_linear_gradient_brush_vtbl); + return CONTAINING_RECORD(iface, struct d2d_brush, ID2D1Brush_iface); } diff -Nru wine1.7-1.7.28/dlls/d2d1/d2d1_private.h wine1.7-1.7.31/dlls/d2d1/d2d1_private.h --- wine1.7-1.7.28/dlls/d2d1/d2d1_private.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d2d1/d2d1_private.h 2014-11-14 13:28:17.000000000 +0000 @@ -21,9 +21,20 @@ #include "wine/debug.h" +#include #include #define COBJMACROS #include "d2d1.h" +#ifdef D2D1_INIT_GUID +#include "initguid.h" +#endif +#include "dwrite.h" + +enum d2d_brush_type +{ + D2D_BRUSH_TYPE_SOLID, + D2D_BRUSH_TYPE_LINEAR, +}; struct d2d_clip_stack { @@ -35,18 +46,20 @@ struct d2d_d3d_render_target { ID2D1RenderTarget ID2D1RenderTarget_iface; + IDWriteTextRenderer IDWriteTextRenderer_iface; LONG refcount; ID3D10Device *device; ID3D10RenderTargetView *view; ID3D10StateBlock *stateblock; + ID3D10InputLayout *il; + unsigned int vb_stride; + ID3D10Buffer *vb; + ID3D10VertexShader *vs; + ID3D10RasterizerState *rs; + ID3D10BlendState *bs; - ID3D10InputLayout *clear_il; - unsigned int clear_vb_stride; - ID3D10Buffer *clear_vb; - ID3D10VertexShader *clear_vs; - ID3D10PixelShader *clear_ps; - ID3D10RasterizerState *clear_rs; + ID3D10PixelShader *rect_solid_ps; D2D1_SIZE_U pixel_size; D2D1_MATRIX_3X2_F transform; @@ -80,9 +93,12 @@ { ID2D1GradientStopCollection ID2D1GradientStopCollection_iface; LONG refcount; + + D2D1_GRADIENT_STOP *stops; + UINT32 stop_count; }; -void d2d_gradient_init(struct d2d_gradient *gradient, ID2D1RenderTarget *render_target, +HRESULT d2d_gradient_init(struct d2d_gradient *gradient, ID2D1RenderTarget *render_target, const D2D1_GRADIENT_STOP *stops, UINT32 stop_count, D2D1_GAMMA gamma, D2D1_EXTEND_MODE extend_mode) DECLSPEC_HIDDEN; @@ -90,6 +106,17 @@ { ID2D1Brush ID2D1Brush_iface; LONG refcount; + + float opacity; + + enum d2d_brush_type type; + union + { + struct + { + D2D1_COLOR_F color; + } solid; + } u; }; void d2d_solid_color_brush_init(struct d2d_brush *brush, ID2D1RenderTarget *render_target, @@ -97,6 +124,7 @@ void d2d_linear_gradient_brush_init(struct d2d_brush *brush, ID2D1RenderTarget *render_target, const D2D1_LINEAR_GRADIENT_BRUSH_PROPERTIES *gradient_brush_desc, const D2D1_BRUSH_PROPERTIES *brush_desc, ID2D1GradientStopCollection *gradient) DECLSPEC_HIDDEN; +struct d2d_brush *unsafe_impl_from_ID2D1Brush(ID2D1Brush *iface) DECLSPEC_HIDDEN; struct d2d_stroke_style { diff -Nru wine1.7-1.7.28/dlls/d2d1/factory.c wine1.7-1.7.31/dlls/d2d1/factory.c --- wine1.7-1.7.28/dlls/d2d1/factory.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d2d1/factory.c 2014-11-14 13:28:17.000000000 +0000 @@ -19,6 +19,7 @@ #include "config.h" #include "wine/port.h" +#define D2D1_INIT_GUID #include "d2d1_private.h" WINE_DEFAULT_DEBUG_CHANNEL(d2d); diff -Nru wine1.7-1.7.28/dlls/d2d1/render_target.c wine1.7-1.7.31/dlls/d2d1/render_target.c --- wine1.7-1.7.28/dlls/d2d1/render_target.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d2d1/render_target.c 2014-11-14 13:28:17.000000000 +0000 @@ -26,6 +26,12 @@ #define INITIAL_CLIP_STACK_SIZE 4 +struct d2d_draw_text_layout_ctx +{ + ID2D1Brush *brush; + D2D1_DRAW_TEXT_OPTIONS options; +}; + static void d2d_point_transform(D2D1_POINT_2F *dst, const D2D1_MATRIX_3X2_F *matrix, float x, float y) { dst->x = x * matrix->_11 + y * matrix->_21 + matrix->_31; @@ -115,6 +121,63 @@ --stack->count; } +static void d2d_draw(struct d2d_d3d_render_target *render_target, ID3D10Buffer *vs_cb, + ID3D10PixelShader *ps, ID3D10Buffer *ps_cb, BOOL blend) +{ + ID3D10Device *device = render_target->device; + unsigned int offset; + D3D10_VIEWPORT vp; + HRESULT hr; + static const float blend_factor[] = {1.0f, 1.0f, 1.0f, 1.0f}; + + vp.TopLeftX = 0; + vp.TopLeftY = 0; + vp.Width = render_target->pixel_size.width; + vp.Height = render_target->pixel_size.height; + vp.MinDepth = 0.0f; + vp.MaxDepth = 1.0f; + + if (FAILED(hr = render_target->stateblock->lpVtbl->Capture(render_target->stateblock))) + { + WARN("Failed to capture stateblock, hr %#x.\n", hr); + return; + } + + ID3D10Device_ClearState(device); + + ID3D10Device_IASetInputLayout(device, render_target->il); + ID3D10Device_IASetPrimitiveTopology(device, D3D10_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP); + offset = 0; + ID3D10Device_IASetVertexBuffers(device, 0, 1, &render_target->vb, + &render_target->vb_stride, &offset); + ID3D10Device_VSSetConstantBuffers(device, 0, 1, &vs_cb); + ID3D10Device_VSSetShader(device, render_target->vs); + ID3D10Device_PSSetConstantBuffers(device, 0, 1, &ps_cb); + ID3D10Device_PSSetShader(device, ps); + ID3D10Device_RSSetViewports(device, 1, &vp); + if (render_target->clip_stack.count) + { + const D2D1_RECT_F *clip_rect; + D3D10_RECT scissor_rect; + + clip_rect = &render_target->clip_stack.stack[render_target->clip_stack.count - 1]; + scissor_rect.left = clip_rect->left + 0.5f; + scissor_rect.top = clip_rect->top + 0.5f; + scissor_rect.right = clip_rect->right + 0.5f; + scissor_rect.bottom = clip_rect->bottom + 0.5f; + ID3D10Device_RSSetScissorRects(device, 1, &scissor_rect); + ID3D10Device_RSSetState(device, render_target->rs); + } + ID3D10Device_OMSetRenderTargets(device, 1, &render_target->view, NULL); + if (blend) + ID3D10Device_OMSetBlendState(device, render_target->bs, blend_factor, D3D10_DEFAULT_SAMPLE_MASK); + + ID3D10Device_Draw(device, 4, 0); + + if (FAILED(hr = render_target->stateblock->lpVtbl->Apply(render_target->stateblock))) + WARN("Failed to apply stateblock, hr %#x.\n", hr); +} + static inline struct d2d_d3d_render_target *impl_from_ID2D1RenderTarget(ID2D1RenderTarget *iface) { return CONTAINING_RECORD(iface, struct d2d_d3d_render_target, ID2D1RenderTarget_iface); @@ -159,13 +222,14 @@ if (!refcount) { d2d_clip_stack_cleanup(&render_target->clip_stack); - ID3D10RenderTargetView_Release(render_target->view); - ID3D10RasterizerState_Release(render_target->clear_rs); - ID3D10PixelShader_Release(render_target->clear_ps); - ID3D10VertexShader_Release(render_target->clear_vs); - ID3D10Buffer_Release(render_target->clear_vb); - ID3D10InputLayout_Release(render_target->clear_il); + ID3D10PixelShader_Release(render_target->rect_solid_ps); + ID3D10BlendState_Release(render_target->bs); + ID3D10RasterizerState_Release(render_target->rs); + ID3D10VertexShader_Release(render_target->vs); + ID3D10Buffer_Release(render_target->vb); + ID3D10InputLayout_Release(render_target->il); render_target->stateblock->lpVtbl->Release(render_target->stateblock); + ID3D10RenderTargetView_Release(render_target->view); ID3D10Device_Release(render_target->device); HeapFree(GetProcessHeap(), 0, render_target); } @@ -329,6 +393,7 @@ ID2D1GradientStopCollection **gradient) { struct d2d_gradient *object; + HRESULT hr; TRACE("iface %p, stops %p, stop_count %u, gamma %#x, extend_mode %#x, gradient %p.\n", iface, stops, stop_count, gamma, extend_mode, gradient); @@ -336,7 +401,12 @@ if (!(object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*object)))) return E_OUTOFMEMORY; - d2d_gradient_init(object, iface, stops, stop_count, gamma, extend_mode); + if (FAILED(hr = d2d_gradient_init(object, iface, stops, stop_count, gamma, extend_mode))) + { + WARN("Failed to initialize gradient, hr %#x.\n", hr); + HeapFree(GetProcessHeap(), 0, object); + return hr; + } TRACE("Created gradient %p.\n", object); *gradient = &object->ID2D1GradientStopCollection_iface; @@ -426,7 +496,89 @@ static void STDMETHODCALLTYPE d2d_d3d_render_target_FillRectangle(ID2D1RenderTarget *iface, const D2D1_RECT_F *rect, ID2D1Brush *brush) { - FIXME("iface %p, rect %p, brush %p stub!\n", iface, rect, brush); + struct d2d_d3d_render_target *render_target = impl_from_ID2D1RenderTarget(iface); + struct d2d_brush *brush_impl = unsafe_impl_from_ID2D1Brush(brush); + D3D10_SUBRESOURCE_DATA buffer_data; + D3D10_BUFFER_DESC buffer_desc; + ID3D10Buffer *vs_cb, *ps_cb; + D2D1_COLOR_F color; + float tmp_x, tmp_y; + HRESULT hr; + struct + { + float _11, _21, _31, pad0; + float _12, _22, _32, pad1; + } transform; + + TRACE("iface %p, rect %p, brush %p.\n", iface, rect, brush); + + if (brush_impl->type != D2D_BRUSH_TYPE_SOLID) + { + FIXME("Unhandled brush type %#x.\n", brush_impl->type); + return; + } + + /* Translate from clip space to world (D2D rendertarget) space, taking the + * dpi and rendertarget transform into account. */ + tmp_x = (2.0f * render_target->dpi_x) / (96.0f * render_target->pixel_size.width); + tmp_y = -(2.0f * render_target->dpi_y) / (96.0f * render_target->pixel_size.height); + transform._11 = render_target->transform._11 * tmp_x; + transform._21 = render_target->transform._21 * tmp_x; + transform._31 = render_target->transform._31 * tmp_x - 1.0f; + transform.pad0 = 0.0f; + transform._12 = render_target->transform._12 * tmp_y; + transform._22 = render_target->transform._22 * tmp_y; + transform._32 = render_target->transform._32 * tmp_y + 1.0f; + transform.pad1 = 0.0f; + + /* Translate from world space to object space. */ + tmp_x = rect->left + (rect->right - rect->left) / 2.0f; + tmp_y = rect->top + (rect->bottom - rect->top) / 2.0f; + transform._31 += tmp_x * transform._11 + tmp_y * transform._21; + transform._32 += tmp_x * transform._12 + tmp_y * transform._22; + tmp_x = (rect->right - rect->left) / 2.0f; + tmp_y = (rect->bottom - rect->top) / 2.0f; + transform._11 *= tmp_x; + transform._12 *= tmp_x; + transform._21 *= tmp_y; + transform._22 *= tmp_y; + + buffer_desc.ByteWidth = sizeof(transform); + buffer_desc.Usage = D3D10_USAGE_DEFAULT; + buffer_desc.BindFlags = D3D10_BIND_CONSTANT_BUFFER; + buffer_desc.CPUAccessFlags = 0; + buffer_desc.MiscFlags = 0; + + buffer_data.pSysMem = &transform; + buffer_data.SysMemPitch = 0; + buffer_data.SysMemSlicePitch = 0; + + if (FAILED(hr = ID3D10Device_CreateBuffer(render_target->device, &buffer_desc, &buffer_data, &vs_cb))) + { + WARN("Failed to create constant buffer, hr %#x.\n", hr); + return; + } + + color = brush_impl->u.solid.color; + color.r *= brush_impl->opacity; + color.g *= brush_impl->opacity; + color.b *= brush_impl->opacity; + color.a *= brush_impl->opacity; + + buffer_desc.ByteWidth = sizeof(color); + buffer_data.pSysMem = &color; + + if (FAILED(hr = ID3D10Device_CreateBuffer(render_target->device, &buffer_desc, &buffer_data, &ps_cb))) + { + WARN("Failed to create constant buffer, hr %#x.\n", hr); + ID3D10Buffer_Release(vs_cb); + return; + } + + d2d_draw(render_target, vs_cb, render_target->rect_solid_ps, ps_cb, TRUE); + + ID3D10Buffer_Release(ps_cb); + ID3D10Buffer_Release(vs_cb); } static void STDMETHODCALLTYPE d2d_d3d_render_target_DrawRoundedRectangle(ID2D1RenderTarget *iface, @@ -503,8 +655,19 @@ static void STDMETHODCALLTYPE d2d_d3d_render_target_DrawTextLayout(ID2D1RenderTarget *iface, D2D1_POINT_2F origin, IDWriteTextLayout *layout, ID2D1Brush *brush, D2D1_DRAW_TEXT_OPTIONS options) { - FIXME("iface %p, origin {%.8e, %.8e}, layout %p, brush %p, options %#x stub!\n", + struct d2d_d3d_render_target *render_target = impl_from_ID2D1RenderTarget(iface); + struct d2d_draw_text_layout_ctx ctx; + HRESULT hr; + + TRACE("iface %p, origin {%.8e, %.8e}, layout %p, brush %p, options %#x.\n", iface, origin.x, origin.y, layout, brush, options); + + ctx.brush = brush; + ctx.options = options; + + if (FAILED(hr = IDWriteTextLayout_Draw(layout, + &ctx, &render_target->IDWriteTextRenderer_iface, origin.x, origin.y))) + FIXME("Failed to draw text layout, hr %#x.\n", hr); } static void STDMETHODCALLTYPE d2d_d3d_render_target_DrawGlyphRun(ID2D1RenderTarget *iface, @@ -660,75 +823,47 @@ struct d2d_d3d_render_target *render_target = impl_from_ID2D1RenderTarget(iface); D3D10_SUBRESOURCE_DATA buffer_data; D3D10_BUFFER_DESC buffer_desc; - unsigned int offset; - D3D10_VIEWPORT vp; - ID3D10Buffer *cb; + ID3D10Buffer *vs_cb, *ps_cb; HRESULT hr; + static float transform[] = + { + 1.0f, 0.0f, 0.0f, 0.0f, + 0.0f, -1.0f, 0.0f, 0.0f, + }; + TRACE("iface %p, color %p.\n", iface, color); - buffer_desc.ByteWidth = sizeof(*color); + buffer_desc.ByteWidth = sizeof(transform); buffer_desc.Usage = D3D10_USAGE_DEFAULT; buffer_desc.BindFlags = D3D10_BIND_CONSTANT_BUFFER; buffer_desc.CPUAccessFlags = 0; buffer_desc.MiscFlags = 0; - buffer_data.pSysMem = color; + buffer_data.pSysMem = transform; buffer_data.SysMemPitch = 0; buffer_data.SysMemSlicePitch = 0; - if (FAILED(hr = ID3D10Device_CreateBuffer(render_target->device, &buffer_desc, &buffer_data, &cb))) + if (FAILED(hr = ID3D10Device_CreateBuffer(render_target->device, &buffer_desc, &buffer_data, &vs_cb))) { WARN("Failed to create constant buffer, hr %#x.\n", hr); return; } - vp.TopLeftX = 0; - vp.TopLeftY = 0; - vp.Width = render_target->pixel_size.width; - vp.Height = render_target->pixel_size.height; - vp.MinDepth = 0.0f; - vp.MaxDepth = 1.0f; + buffer_desc.ByteWidth = sizeof(*color); + buffer_data.pSysMem = color; - if (FAILED(hr = render_target->stateblock->lpVtbl->Capture(render_target->stateblock))) + if (FAILED(hr = ID3D10Device_CreateBuffer(render_target->device, &buffer_desc, &buffer_data, &ps_cb))) { - WARN("Failed to capture stateblock, hr %#x.\n", hr); - ID3D10Buffer_Release(cb); + WARN("Failed to create constant buffer, hr %#x.\n", hr); + ID3D10Buffer_Release(vs_cb); return; } - ID3D10Device_ClearState(render_target->device); - - ID3D10Device_IASetInputLayout(render_target->device, render_target->clear_il); - ID3D10Device_IASetPrimitiveTopology(render_target->device, D3D10_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP); - offset = 0; - ID3D10Device_IASetVertexBuffers(render_target->device, 0, 1, - &render_target->clear_vb, &render_target->clear_vb_stride, &offset); - ID3D10Device_VSSetShader(render_target->device, render_target->clear_vs); - ID3D10Device_PSSetConstantBuffers(render_target->device, 0, 1, &cb); - ID3D10Device_PSSetShader(render_target->device, render_target->clear_ps); - ID3D10Device_RSSetViewports(render_target->device, 1, &vp); - if (render_target->clip_stack.count) - { - const D2D1_RECT_F *clip_rect; - D3D10_RECT scissor_rect; - - clip_rect = &render_target->clip_stack.stack[render_target->clip_stack.count - 1]; - scissor_rect.left = clip_rect->left + 0.5f; - scissor_rect.top = clip_rect->top + 0.5f; - scissor_rect.right = clip_rect->right + 0.5f; - scissor_rect.bottom = clip_rect->bottom + 0.5f; - ID3D10Device_RSSetScissorRects(render_target->device, 1, &scissor_rect); - ID3D10Device_RSSetState(render_target->device, render_target->clear_rs); - } - ID3D10Device_OMSetRenderTargets(render_target->device, 1, &render_target->view, NULL); - - ID3D10Device_Draw(render_target->device, 4, 0); - - if (FAILED(hr = render_target->stateblock->lpVtbl->Apply(render_target->stateblock))) - WARN("Failed to apply stateblock, hr %#x.\n", hr); + d2d_draw(render_target, vs_cb, render_target->rect_solid_ps, ps_cb, FALSE); - ID3D10Buffer_Release(cb); + ID3D10Buffer_Release(ps_cb); + ID3D10Buffer_Release(vs_cb); } static void STDMETHODCALLTYPE d2d_d3d_render_target_BeginDraw(ID2D1RenderTarget *iface) @@ -883,6 +1018,124 @@ d2d_d3d_render_target_IsSupported, }; +static inline struct d2d_d3d_render_target *impl_from_IDWriteTextRenderer(IDWriteTextRenderer *iface) +{ + return CONTAINING_RECORD(iface, struct d2d_d3d_render_target, IDWriteTextRenderer_iface); +} + +static HRESULT STDMETHODCALLTYPE d2d_text_renderer_QueryInterface(IDWriteTextRenderer *iface, REFIID iid, void **out) +{ + TRACE("iface %p, iid %s, out %p.\n", iface, debugstr_guid(iid), out); + + if (IsEqualGUID(iid, &IID_IDWriteTextRenderer) + || IsEqualGUID(iid, &IID_IDWritePixelSnapping) + || IsEqualGUID(iid, &IID_IUnknown)) + { + IDWriteTextRenderer_AddRef(iface); + *out = iface; + return S_OK; + } + + WARN("%s not implemented, returning E_NOINTERFACE.\n", debugstr_guid(iid)); + + *out = NULL; + return E_NOINTERFACE; +} + +static ULONG STDMETHODCALLTYPE d2d_text_renderer_AddRef(IDWriteTextRenderer *iface) +{ + struct d2d_d3d_render_target *render_target = impl_from_IDWriteTextRenderer(iface); + + TRACE("iface %p.\n", iface); + + return d2d_d3d_render_target_AddRef(&render_target->ID2D1RenderTarget_iface); +} + +static ULONG STDMETHODCALLTYPE d2d_text_renderer_Release(IDWriteTextRenderer *iface) +{ + struct d2d_d3d_render_target *render_target = impl_from_IDWriteTextRenderer(iface); + + TRACE("iface %p.\n", iface); + + return d2d_d3d_render_target_Release(&render_target->ID2D1RenderTarget_iface); +} + +static HRESULT STDMETHODCALLTYPE d2d_text_renderer_IsPixelSnappingDisabled(IDWriteTextRenderer *iface, + void *ctx, BOOL *disabled) +{ + FIXME("iface %p, ctx %p, disabled %p stub!\n", iface, ctx, disabled); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_text_renderer_GetCurrentTransform(IDWriteTextRenderer *iface, + void *ctx, DWRITE_MATRIX *transform) +{ + FIXME("iface %p, ctx %p, transform %p stub!\n", iface, ctx, transform); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_text_renderer_GetPixelsPerDip(IDWriteTextRenderer *iface, void *ctx, float *ppd) +{ + FIXME("iface %p, ctx %p, ppd %p stub!\n", iface, ctx, ppd); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_text_renderer_DrawGlyphRun(IDWriteTextRenderer *iface, void *ctx, + float baseline_origin_x, float baseline_origin_y, DWRITE_MEASURING_MODE measuring_mode, + const DWRITE_GLYPH_RUN *glyph_run, const DWRITE_GLYPH_RUN_DESCRIPTION *desc, IUnknown *effect) +{ + FIXME("iface %p, ctx %p, baseline_origin_x %.8e, baseline_origin_y %.8e, " + "measuring_mode %#x, glyph_run %p, desc %p, effect %p stub!\n", + iface, ctx, baseline_origin_x, baseline_origin_y, + measuring_mode, glyph_run, desc, effect); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_text_renderer_DrawUnderline(IDWriteTextRenderer *iface, void *ctx, + float baseline_origin_x, float baseline_origin_y, const DWRITE_UNDERLINE *underline, IUnknown *effect) +{ + FIXME("iface %p, ctx %p, baseline_origin_x %.8e, baseline_origin_y %.8e, underline %p, effect %p stub!\n", + iface, ctx, baseline_origin_x, baseline_origin_y, underline, effect); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_text_renderer_DrawStrikethrough(IDWriteTextRenderer *iface, void *ctx, + float baseline_origin_x, float baseline_origin_y, const DWRITE_STRIKETHROUGH *strikethrough, IUnknown *effect) +{ + FIXME("iface %p, ctx %p, baseline_origin_x %.8e, baseline_origin_y %.8e, strikethrough %p, effect %p stub!\n", + iface, ctx, baseline_origin_x, baseline_origin_y, strikethrough, effect); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_text_renderer_DrawInlineObject(IDWriteTextRenderer *iface, void *ctx, + float origin_x, float origin_y, IDWriteInlineObject *object, BOOL is_sideways, BOOL is_rtl, IUnknown *effect) +{ + FIXME("iface %p, ctx %p, origin_x %.8e, origin_y %.8e, object %p, is_sideways %#x, is_rtl %#x, effect %p stub!\n", + iface, ctx, origin_x, origin_y, object, is_sideways, is_rtl, effect); + + return E_NOTIMPL; +} + +static const struct IDWriteTextRendererVtbl d2d_text_renderer_vtbl = +{ + d2d_text_renderer_QueryInterface, + d2d_text_renderer_AddRef, + d2d_text_renderer_Release, + d2d_text_renderer_IsPixelSnappingDisabled, + d2d_text_renderer_GetCurrentTransform, + d2d_text_renderer_GetPixelsPerDip, + d2d_text_renderer_DrawGlyphRun, + d2d_text_renderer_DrawUnderline, + d2d_text_renderer_DrawStrikethrough, + d2d_text_renderer_DrawInlineObject, +}; + HRESULT d2d_d3d_render_target_init(struct d2d_d3d_render_target *render_target, ID2D1Factory *factory, IDXGISurface *surface, const D2D1_RENDER_TARGET_PROPERTIES *desc) { @@ -891,35 +1144,34 @@ DXGI_SURFACE_DESC surface_desc; D3D10_RASTERIZER_DESC rs_desc; D3D10_BUFFER_DESC buffer_desc; + D3D10_BLEND_DESC blend_desc; ID3D10Resource *resource; HRESULT hr; - static const D3D10_INPUT_ELEMENT_DESC clear_il_desc[] = + static const D3D10_INPUT_ELEMENT_DESC il_desc[] = { {"POSITION", 0, DXGI_FORMAT_R32G32_FLOAT, 0, 0, D3D10_INPUT_PER_VERTEX_DATA, 0}, }; - static const DWORD clear_vs_code[] = + static const DWORD vs_code[] = { - /* float4 main(float4 position : POSITION) : SV_POSITION + /* float3x2 transform; + * + * float4 main(float4 position : POSITION) : SV_POSITION * { - * return position; + * return float4(mul(position.xyw, transform), position.zw); * } */ - 0x43425844, 0x1fa8c27f, 0x52d2f21d, 0xc196fdb7, 0x376f283a, 0x00000001, 0x000001b4, 0x00000005, - 0x00000034, 0x0000008c, 0x000000c0, 0x000000f4, 0x00000138, 0x46454452, 0x00000050, 0x00000000, - 0x00000000, 0x00000000, 0x0000001c, 0xfffe0400, 0x00000100, 0x0000001c, 0x7263694d, 0x666f736f, - 0x52282074, 0x4c482029, 0x53204c53, 0x65646168, 0x6f432072, 0x6c69706d, 0x39207265, 0x2e30332e, - 0x30303239, 0x3336312e, 0xab003438, 0x4e475349, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, + 0x43425844, 0x0add3194, 0x205f74ec, 0xab527fe7, 0xbe6ad704, 0x00000001, 0x00000128, 0x00000003, + 0x0000002c, 0x00000060, 0x00000094, 0x4e475349, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000000, 0x00000003, 0x00000000, 0x00000f0f, 0x49534f50, 0x4e4f4954, 0xababab00, 0x4e47534f, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000001, 0x00000003, - 0x00000000, 0x0000000f, 0x505f5653, 0x5449534f, 0x004e4f49, 0x52444853, 0x0000003c, 0x00010040, - 0x0000000f, 0x0300005f, 0x001010f2, 0x00000000, 0x04000067, 0x001020f2, 0x00000000, 0x00000001, - 0x05000036, 0x001020f2, 0x00000000, 0x00101e46, 0x00000000, 0x0100003e, 0x54415453, 0x00000074, - 0x00000002, 0x00000000, 0x00000000, 0x00000002, 0x00000000, 0x00000000, 0x00000000, 0x00000001, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000002, 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x0000000f, 0x505f5653, 0x5449534f, 0x004e4f49, 0x52444853, 0x0000008c, 0x00010040, + 0x00000023, 0x04000059, 0x00208e46, 0x00000000, 0x00000002, 0x0300005f, 0x001010f2, 0x00000000, + 0x04000067, 0x001020f2, 0x00000000, 0x00000001, 0x08000010, 0x00102012, 0x00000000, 0x00101346, + 0x00000000, 0x00208246, 0x00000000, 0x00000000, 0x08000010, 0x00102022, 0x00000000, 0x00101346, + 0x00000000, 0x00208246, 0x00000000, 0x00000001, 0x05000036, 0x001020c2, 0x00000000, 0x00101ea6, + 0x00000000, 0x0100003e, }; - static const DWORD clear_ps_code[] = + static const DWORD rect_solid_ps_code[] = { /* float4 color; * @@ -927,35 +1179,24 @@ * { * return color; * } */ - 0x43425844, 0xecd3cc9d, 0x0025bc77, 0x7a333165, 0x5b04c7e4, 0x00000001, 0x0000022c, 0x00000005, - 0x00000034, 0x00000100, 0x00000134, 0x00000168, 0x000001b0, 0x46454452, 0x000000c4, 0x00000001, - 0x00000048, 0x00000001, 0x0000001c, 0xffff0400, 0x00000100, 0x00000090, 0x0000003c, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000001, 0x00000000, 0x6f6c4724, 0x736c6162, - 0xababab00, 0x0000003c, 0x00000001, 0x00000060, 0x00000010, 0x00000000, 0x00000000, 0x00000078, - 0x00000000, 0x00000010, 0x00000002, 0x00000080, 0x00000000, 0x6f6c6f63, 0xabab0072, 0x00030001, - 0x00040001, 0x00000000, 0x00000000, 0x7263694d, 0x666f736f, 0x52282074, 0x4c482029, 0x53204c53, - 0x65646168, 0x6f432072, 0x6c69706d, 0x39207265, 0x2e30332e, 0x30303239, 0x3336312e, 0xab003438, - 0x4e475349, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000001, 0x00000003, - 0x00000000, 0x0000000f, 0x505f5653, 0x5449534f, 0x004e4f49, 0x4e47534f, 0x0000002c, 0x00000001, - 0x00000008, 0x00000020, 0x00000000, 0x00000000, 0x00000003, 0x00000000, 0x0000000f, 0x545f5653, - 0x65677261, 0xabab0074, 0x52444853, 0x00000040, 0x00000040, 0x00000010, 0x04000059, 0x00208e46, - 0x00000000, 0x00000001, 0x03000065, 0x001020f2, 0x00000000, 0x06000036, 0x001020f2, 0x00000000, - 0x00208e46, 0x00000000, 0x00000000, 0x0100003e, 0x54415453, 0x00000074, 0x00000002, 0x00000000, - 0x00000000, 0x00000001, 0x00000000, 0x00000000, 0x00000000, 0x00000001, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000002, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, + 0x43425844, 0x88eefcfd, 0x93d6fd47, 0x173c242f, 0x0106d07a, 0x00000001, 0x000000dc, 0x00000003, + 0x0000002c, 0x00000060, 0x00000094, 0x4e475349, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, + 0x00000000, 0x00000001, 0x00000003, 0x00000000, 0x0000000f, 0x505f5653, 0x5449534f, 0x004e4f49, + 0x4e47534f, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000000, 0x00000003, + 0x00000000, 0x0000000f, 0x545f5653, 0x65677261, 0xabab0074, 0x52444853, 0x00000040, 0x00000040, + 0x00000010, 0x04000059, 0x00208e46, 0x00000000, 0x00000001, 0x03000065, 0x001020f2, 0x00000000, + 0x06000036, 0x001020f2, 0x00000000, 0x00208e46, 0x00000000, 0x00000000, 0x0100003e, }; static const struct { float x, y; } - clear_quad[] = + quad[] = { - {-1.0f, -1.0f}, {-1.0f, 1.0f}, - { 1.0f, -1.0f}, + {-1.0f, -1.0f}, { 1.0f, 1.0f}, + { 1.0f, -1.0f}, }; static const D2D1_MATRIX_3X2_F identity = { @@ -967,6 +1208,7 @@ FIXME("Ignoring render target properties.\n"); render_target->ID2D1RenderTarget_iface.lpVtbl = &d2d_d3d_render_target_vtbl; + render_target->IDWriteTextRenderer_iface.lpVtbl = &d2d_text_renderer_vtbl; render_target->refcount = 1; if (FAILED(hr = IDXGISurface_GetDevice(surface, &IID_ID3D10Device, (void **)&render_target->device))) @@ -1001,46 +1243,39 @@ goto err; } - if (FAILED(hr = ID3D10Device_CreateInputLayout(render_target->device, clear_il_desc, - sizeof(clear_il_desc) / sizeof(*clear_il_desc), clear_vs_code, sizeof(clear_vs_code), - &render_target->clear_il))) + if (FAILED(hr = ID3D10Device_CreateInputLayout(render_target->device, il_desc, + sizeof(il_desc) / sizeof(*il_desc), vs_code, sizeof(vs_code), + &render_target->il))) { WARN("Failed to create clear input layout, hr %#x.\n", hr); goto err; } - buffer_desc.ByteWidth = sizeof(clear_quad); + buffer_desc.ByteWidth = sizeof(quad); buffer_desc.Usage = D3D10_USAGE_DEFAULT; buffer_desc.BindFlags = D3D10_BIND_VERTEX_BUFFER; buffer_desc.CPUAccessFlags = 0; buffer_desc.MiscFlags = 0; - buffer_data.pSysMem = clear_quad; + buffer_data.pSysMem = quad; buffer_data.SysMemPitch = 0; buffer_data.SysMemSlicePitch = 0; - render_target->clear_vb_stride = sizeof(*clear_quad); + render_target->vb_stride = sizeof(*quad); if (FAILED(hr = ID3D10Device_CreateBuffer(render_target->device, - &buffer_desc, &buffer_data, &render_target->clear_vb))) + &buffer_desc, &buffer_data, &render_target->vb))) { WARN("Failed to create clear vertex buffer, hr %#x.\n", hr); goto err; } if (FAILED(hr = ID3D10Device_CreateVertexShader(render_target->device, - clear_vs_code, sizeof(clear_vs_code), &render_target->clear_vs))) + vs_code, sizeof(vs_code), &render_target->vs))) { WARN("Failed to create clear vertex shader, hr %#x.\n", hr); goto err; } - if (FAILED(hr = ID3D10Device_CreatePixelShader(render_target->device, - clear_ps_code, sizeof(clear_ps_code), &render_target->clear_ps))) - { - WARN("Failed to create clear pixel shader, hr %#x.\n", hr); - goto err; - } - rs_desc.FillMode = D3D10_FILL_SOLID; rs_desc.CullMode = D3D10_CULL_BACK; rs_desc.FrontCounterClockwise = FALSE; @@ -1051,12 +1286,34 @@ rs_desc.ScissorEnable = TRUE; rs_desc.MultisampleEnable = FALSE; rs_desc.AntialiasedLineEnable = FALSE; - if (FAILED(hr = ID3D10Device_CreateRasterizerState(render_target->device, &rs_desc, &render_target->clear_rs))) + if (FAILED(hr = ID3D10Device_CreateRasterizerState(render_target->device, &rs_desc, &render_target->rs))) { WARN("Failed to create clear rasterizer state, hr %#x.\n", hr); goto err; } + memset(&blend_desc, 0, sizeof(blend_desc)); + blend_desc.BlendEnable[0] = TRUE; + blend_desc.SrcBlend = D3D10_BLEND_SRC_ALPHA; + blend_desc.DestBlend = D3D10_BLEND_INV_SRC_ALPHA; + blend_desc.BlendOp = D3D10_BLEND_OP_ADD; + blend_desc.SrcBlendAlpha = D3D10_BLEND_ZERO; + blend_desc.DestBlendAlpha = D3D10_BLEND_ONE; + blend_desc.BlendOpAlpha = D3D10_BLEND_OP_ADD; + blend_desc.RenderTargetWriteMask[0] = D3D10_COLOR_WRITE_ENABLE_ALL; + if (FAILED(hr = ID3D10Device_CreateBlendState(render_target->device, &blend_desc, &render_target->bs))) + { + WARN("Failed to create blend state, hr %#x.\n", hr); + goto err; + } + + if (FAILED(hr = ID3D10Device_CreatePixelShader(render_target->device, + rect_solid_ps_code, sizeof(rect_solid_ps_code), &render_target->rect_solid_ps))) + { + WARN("Failed to create clear pixel shader, hr %#x.\n", hr); + goto err; + } + if (FAILED(hr = IDXGISurface_GetDesc(surface, &surface_desc))) { WARN("Failed to get surface desc, hr %#x.\n", hr); @@ -1086,20 +1343,22 @@ return S_OK; err: - if (render_target->view) - ID3D10RenderTargetView_Release(render_target->view); - if (render_target->clear_rs) - ID3D10RasterizerState_Release(render_target->clear_rs); - if (render_target->clear_ps) - ID3D10PixelShader_Release(render_target->clear_ps); - if (render_target->clear_vs) - ID3D10VertexShader_Release(render_target->clear_vs); - if (render_target->clear_vb) - ID3D10Buffer_Release(render_target->clear_vb); - if (render_target->clear_il) - ID3D10InputLayout_Release(render_target->clear_il); + if (render_target->rect_solid_ps) + ID3D10PixelShader_Release(render_target->rect_solid_ps); + if (render_target->bs) + ID3D10BlendState_Release(render_target->bs); + if (render_target->rs) + ID3D10RasterizerState_Release(render_target->rs); + if (render_target->vs) + ID3D10VertexShader_Release(render_target->vs); + if (render_target->vb) + ID3D10Buffer_Release(render_target->vb); + if (render_target->il) + ID3D10InputLayout_Release(render_target->il); if (render_target->stateblock) render_target->stateblock->lpVtbl->Release(render_target->stateblock); + if (render_target->view) + ID3D10RenderTargetView_Release(render_target->view); if (render_target->device) ID3D10Device_Release(render_target->device); return hr; diff -Nru wine1.7-1.7.28/dlls/d3d10core/d3d10core_private.h wine1.7-1.7.31/dlls/d3d10core/d3d10core_private.h --- wine1.7-1.7.28/dlls/d3d10core/d3d10core_private.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d10core/d3d10core_private.h 2014-11-14 13:28:17.000000000 +0000 @@ -50,6 +50,7 @@ struct d3d10_shader_info { const DWORD *shader_code; + struct wined3d_shader_signature *input_signature; struct wined3d_shader_signature *output_signature; }; @@ -190,7 +191,6 @@ LONG refcount; struct wined3d_shader *wined3d_shader; - struct wined3d_shader_signature output_signature; ID3D10Device1 *device; }; @@ -205,7 +205,6 @@ LONG refcount; struct wined3d_shader *wined3d_shader; - struct wined3d_shader_signature output_signature; }; HRESULT d3d10_geometry_shader_init(struct d3d10_geometry_shader *shader, struct d3d10_device *device, @@ -219,7 +218,6 @@ LONG refcount; struct wined3d_shader *wined3d_shader; - struct wined3d_shader_signature output_signature; ID3D10Device1 *device; }; @@ -327,7 +325,6 @@ struct d3d10_blend_state *blend_state; float blend_factor[4]; - UINT sample_mask; struct d3d10_depthstencil_state *depth_stencil_state; UINT stencil_ref; struct d3d10_rasterizer_state *rasterizer_state; diff -Nru wine1.7-1.7.28/dlls/d3d10core/device.c wine1.7-1.7.31/dlls/d3d10core/device.c --- wine1.7-1.7.28/dlls/d3d10core/device.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d10core/device.c 2014-11-14 13:28:17.000000000 +0000 @@ -462,13 +462,53 @@ ID3D10BlendState *blend_state, const FLOAT blend_factor[4], UINT sample_mask) { struct d3d10_device *device = impl_from_ID3D10Device(iface); + const D3D10_BLEND_DESC *desc; - TRACE("iface %p, blend_state %p, blend_factor [%f %f %f %f], sample_mask 0x%08x.\n", + TRACE("iface %p, blend_state %p, blend_factor {%.8e %.8e %.8e %.8e}, sample_mask 0x%08x.\n", iface, blend_state, blend_factor[0], blend_factor[1], blend_factor[2], blend_factor[3], sample_mask); - device->blend_state = unsafe_impl_from_ID3D10BlendState(blend_state); + if (blend_factor[0] != 1.0f || blend_factor[1] != 1.0f || blend_factor[2] != 1.0f || blend_factor[3] != 1.0f) + FIXME("Ignoring blend factor {%.8e %.8e %.8e %.8e}.\n", + blend_factor[0], blend_factor[1], blend_factor[2], blend_factor[3]); memcpy(device->blend_factor, blend_factor, 4 * sizeof(*blend_factor)); - device->sample_mask = sample_mask; + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_MULTISAMPLEMASK, sample_mask); + if (!(device->blend_state = unsafe_impl_from_ID3D10BlendState(blend_state))) + { + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_ALPHABLENDENABLE, FALSE); + wined3d_device_set_render_state(device->wined3d_device, + WINED3D_RS_COLORWRITEENABLE, D3D10_COLOR_WRITE_ENABLE_ALL); + wined3d_device_set_render_state(device->wined3d_device, + WINED3D_RS_COLORWRITEENABLE1, D3D10_COLOR_WRITE_ENABLE_ALL); + wined3d_device_set_render_state(device->wined3d_device, + WINED3D_RS_COLORWRITEENABLE2, D3D10_COLOR_WRITE_ENABLE_ALL); + wined3d_device_set_render_state(device->wined3d_device, + WINED3D_RS_COLORWRITEENABLE3, D3D10_COLOR_WRITE_ENABLE_ALL); + return; + } + + desc = &device->blend_state->desc; + /* glSampleCoverage() */ + if (desc->AlphaToCoverageEnable) + FIXME("Ignoring AlphaToCoverageEnable %#x.\n", desc->AlphaToCoverageEnable); + /* glEnableIndexedEXT(GL_BLEND, ...) */ + FIXME("Per-rendertarget blend enable not implemented.\n"); + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_ALPHABLENDENABLE, desc->BlendEnable[0]); + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_SRCBLEND, desc->SrcBlend); + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_DESTBLEND, desc->DestBlend); + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_BLENDOP, desc->BlendOp); + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_SEPARATEALPHABLENDENABLE, TRUE); + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_SRCBLENDALPHA, desc->SrcBlendAlpha); + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_DESTBLENDALPHA, desc->DestBlendAlpha); + wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_BLENDOPALPHA, desc->BlendOpAlpha); + FIXME("Color mask > 3 not implemented.\n"); + wined3d_device_set_render_state(device->wined3d_device, + WINED3D_RS_COLORWRITEENABLE, desc->RenderTargetWriteMask[0]); + wined3d_device_set_render_state(device->wined3d_device, + WINED3D_RS_COLORWRITEENABLE1, desc->RenderTargetWriteMask[1]); + wined3d_device_set_render_state(device->wined3d_device, + WINED3D_RS_COLORWRITEENABLE2, desc->RenderTargetWriteMask[2]); + wined3d_device_set_render_state(device->wined3d_device, + WINED3D_RS_COLORWRITEENABLE3, desc->RenderTargetWriteMask[3]); } static void STDMETHODCALLTYPE d3d10_device_OMSetDepthStencilState(ID3D10Device1 *iface, @@ -1105,7 +1145,7 @@ if ((*blend_state = device->blend_state ? &device->blend_state->ID3D10BlendState_iface : NULL)) ID3D10BlendState_AddRef(*blend_state); memcpy(blend_factor, device->blend_factor, 4 * sizeof(*blend_factor)); - *sample_mask = device->sample_mask; + *sample_mask = wined3d_device_get_render_state(device->wined3d_device, WINED3D_RS_MULTISAMPLEMASK); } static void STDMETHODCALLTYPE d3d10_device_OMGetDepthStencilState(ID3D10Device1 *iface, @@ -1260,7 +1300,73 @@ static void STDMETHODCALLTYPE d3d10_device_ClearState(ID3D10Device1 *iface) { - FIXME("iface %p stub!\n", iface); + static const float blend_factor[] = {1.0f, 1.0f, 1.0f, 1.0f}; + struct d3d10_device *device = impl_from_ID3D10Device(iface); + unsigned int i; + + TRACE("iface %p.\n", iface); + + wined3d_device_set_vertex_shader(device->wined3d_device, NULL); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + wined3d_device_set_vs_sampler(device->wined3d_device, i, NULL); + } + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + wined3d_device_set_vs_resource_view(device->wined3d_device, i, NULL); + } + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + wined3d_device_set_vs_cb(device->wined3d_device, i, NULL); + } + wined3d_device_set_geometry_shader(device->wined3d_device, NULL); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + wined3d_device_set_gs_sampler(device->wined3d_device, i, NULL); + } + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + wined3d_device_set_gs_resource_view(device->wined3d_device, i, NULL); + } + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + wined3d_device_set_gs_cb(device->wined3d_device, i, NULL); + } + wined3d_device_set_pixel_shader(device->wined3d_device, NULL); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + wined3d_device_set_ps_sampler(device->wined3d_device, i, NULL); + } + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + wined3d_device_set_ps_resource_view(device->wined3d_device, i, NULL); + } + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + wined3d_device_set_ps_cb(device->wined3d_device, i, NULL); + } + for (i = 0; i < D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + wined3d_device_set_stream_source(device->wined3d_device, i, NULL, 0, 0); + } + wined3d_device_set_index_buffer(device->wined3d_device, NULL, WINED3DFMT_UNKNOWN); + wined3d_device_set_vertex_declaration(device->wined3d_device, NULL); + wined3d_device_set_primitive_type(device->wined3d_device, WINED3D_PT_UNDEFINED); + for (i = 0; i < D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT; ++i) + { + wined3d_device_set_rendertarget_view(device->wined3d_device, i, NULL, FALSE); + } + wined3d_device_set_depth_stencil_view(device->wined3d_device, NULL); + ID3D10Device1_OMSetDepthStencilState(iface, NULL, 0); + ID3D10Device1_OMSetBlendState(iface, NULL, blend_factor, D3D10_DEFAULT_SAMPLE_MASK); + ID3D10Device1_RSSetViewports(iface, 0, NULL); + ID3D10Device1_RSSetScissorRects(iface, 0, NULL); + ID3D10Device1_RSSetState(iface, NULL); + for (i = 0; i < D3D10_SO_BUFFER_SLOT_COUNT; ++i) + { + wined3d_device_set_stream_output(device->wined3d_device, i, NULL, 0); + } + wined3d_device_set_predication(device->wined3d_device, NULL, FALSE); } static void STDMETHODCALLTYPE d3d10_device_Flush(ID3D10Device1 *iface) @@ -2348,7 +2454,6 @@ device->blend_factor[1] = 1.0f; device->blend_factor[2] = 1.0f; device->blend_factor[3] = 1.0f; - device->sample_mask = D3D10_DEFAULT_SAMPLE_MASK; if (wine_rb_init(&device->depthstencil_states, &d3d10_depthstencil_state_rb_ops) == -1) { diff -Nru wine1.7-1.7.28/dlls/d3d10core/shader.c wine1.7-1.7.31/dlls/d3d10core/shader.c --- wine1.7-1.7.28/dlls/d3d10core/shader.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d10core/shader.c 2014-11-14 13:28:17.000000000 +0000 @@ -29,11 +29,16 @@ struct d3d10_shader_info *shader_info = ctx; HRESULT hr; - switch(tag) + switch (tag) { + case TAG_ISGN: + if (FAILED(hr = shader_parse_signature(data, data_size, shader_info->input_signature))) + return hr; + break; + case TAG_OSGN: - hr = shader_parse_signature(data, data_size, shader_info->output_signature); - if (FAILED(hr)) return hr; + if (FAILED(hr = shader_parse_signature(data, data_size, shader_info->output_signature))) + return hr; break; case TAG_SHDR: @@ -53,6 +58,7 @@ HRESULT hr; shader_info->shader_code = NULL; + memset(shader_info->input_signature, 0, sizeof(*shader_info->input_signature)); memset(shader_info->output_signature, 0, sizeof(*shader_info->output_signature)); hr = parse_dxbc(dxbc, dxbc_length, shdr_handler, shader_info); @@ -61,6 +67,7 @@ if (FAILED(hr)) { ERR("Failed to parse shader, hr %#x\n", hr); + shader_free_signature(shader_info->input_signature); shader_free_signature(shader_info->output_signature); } @@ -70,10 +77,7 @@ HRESULT shader_parse_signature(const char *data, DWORD data_size, struct wined3d_shader_signature *s) { struct wined3d_shader_signature_element *e; - unsigned int string_data_offset; - unsigned int string_data_size; const char *ptr = data; - char *string_data; unsigned int i; DWORD count; @@ -89,24 +93,12 @@ return E_OUTOFMEMORY; } - /* 2 DWORDs for the header, 6 for each element. */ - string_data_offset = 2 * sizeof(DWORD) + count * 6 * sizeof(DWORD); - string_data_size = data_size - string_data_offset; - string_data = HeapAlloc(GetProcessHeap(), 0, string_data_size); - if (!string_data) - { - ERR("Failed to allocate string data memory.\n"); - HeapFree(GetProcessHeap(), 0, e); - return E_OUTOFMEMORY; - } - memcpy(string_data, data + string_data_offset, string_data_size); - for (i = 0; i < count; ++i) { UINT name_offset; read_dword(&ptr, &name_offset); - e[i].semantic_name = string_data + (name_offset - string_data_offset); + e[i].semantic_name = data + name_offset; read_dword(&ptr, &e[i].semantic_idx); read_dword(&ptr, &e[i].sysval_semantic); read_dword(&ptr, &e[i].component_type); @@ -121,14 +113,12 @@ s->elements = e; s->element_count = count; - s->string_data = string_data; return S_OK; } void shader_free_signature(struct wined3d_shader_signature *s) { - HeapFree(GetProcessHeap(), 0, s->string_data); HeapFree(GetProcessHeap(), 0, s->elements); } @@ -248,9 +238,7 @@ static void STDMETHODCALLTYPE d3d10_vertex_shader_wined3d_object_destroyed(void *parent) { - struct d3d10_vertex_shader *shader = parent; - shader_free_signature(&shader->output_signature); - HeapFree(GetProcessHeap(), 0, shader); + HeapFree(GetProcessHeap(), 0, parent); } static const struct wined3d_parent_ops d3d10_vertex_shader_wined3d_parent_ops = @@ -261,28 +249,36 @@ HRESULT d3d10_vertex_shader_init(struct d3d10_vertex_shader *shader, struct d3d10_device *device, const void *byte_code, SIZE_T byte_code_length) { + struct wined3d_shader_signature output_signature; + struct wined3d_shader_signature input_signature; struct d3d10_shader_info shader_info; + struct wined3d_shader_desc desc; HRESULT hr; shader->ID3D10VertexShader_iface.lpVtbl = &d3d10_vertex_shader_vtbl; shader->refcount = 1; - shader_info.output_signature = &shader->output_signature; - hr = shader_extract_from_dxbc(byte_code, byte_code_length, &shader_info); - if (FAILED(hr)) + shader_info.input_signature = &input_signature; + shader_info.output_signature = &output_signature; + if (FAILED(hr = shader_extract_from_dxbc(byte_code, byte_code_length, &shader_info))) { ERR("Failed to extract shader, hr %#x.\n", hr); return hr; } - hr = wined3d_shader_create_vs(device->wined3d_device, shader_info.shader_code, - &shader->output_signature, shader, &d3d10_vertex_shader_wined3d_parent_ops, &shader->wined3d_shader, 4); + desc.byte_code = shader_info.shader_code; + desc.input_signature = &input_signature; + desc.output_signature = &output_signature; + desc.max_version = 4; + + hr = wined3d_shader_create_vs(device->wined3d_device, &desc, shader, + &d3d10_vertex_shader_wined3d_parent_ops, &shader->wined3d_shader); + shader_free_signature(&input_signature); + shader_free_signature(&output_signature); if (FAILED(hr)) { WARN("Failed to create wined3d vertex shader, hr %#x.\n", hr); - shader_free_signature(&shader->output_signature); - hr = E_INVALIDARG; - return hr; + return E_INVALIDARG; } shader->device = &device->ID3D10Device1_iface; @@ -398,9 +394,7 @@ static void STDMETHODCALLTYPE d3d10_geometry_shader_wined3d_object_destroyed(void *parent) { - struct d3d10_geometry_shader *shader = parent; - shader_free_signature(&shader->output_signature); - HeapFree(GetProcessHeap(), 0, shader); + HeapFree(GetProcessHeap(), 0, parent); } static const struct wined3d_parent_ops d3d10_geometry_shader_wined3d_parent_ops = @@ -411,28 +405,36 @@ HRESULT d3d10_geometry_shader_init(struct d3d10_geometry_shader *shader, struct d3d10_device *device, const void *byte_code, SIZE_T byte_code_length) { + struct wined3d_shader_signature output_signature; + struct wined3d_shader_signature input_signature; struct d3d10_shader_info shader_info; + struct wined3d_shader_desc desc; HRESULT hr; shader->ID3D10GeometryShader_iface.lpVtbl = &d3d10_geometry_shader_vtbl; shader->refcount = 1; - shader_info.output_signature = &shader->output_signature; - hr = shader_extract_from_dxbc(byte_code, byte_code_length, &shader_info); - if (FAILED(hr)) + shader_info.input_signature = &input_signature; + shader_info.output_signature = &output_signature; + if (FAILED(hr = shader_extract_from_dxbc(byte_code, byte_code_length, &shader_info))) { ERR("Failed to extract shader, hr %#x.\n", hr); return hr; } - hr = wined3d_shader_create_gs(device->wined3d_device, shader_info.shader_code, - &shader->output_signature, shader, &d3d10_geometry_shader_wined3d_parent_ops, &shader->wined3d_shader, 4); + desc.byte_code = shader_info.shader_code; + desc.input_signature = &input_signature; + desc.output_signature = &output_signature; + desc.max_version = 4; + + hr = wined3d_shader_create_gs(device->wined3d_device, &desc, shader, + &d3d10_geometry_shader_wined3d_parent_ops, &shader->wined3d_shader); + shader_free_signature(&input_signature); + shader_free_signature(&output_signature); if (FAILED(hr)) { WARN("Failed to create wined3d geometry shader, hr %#x.\n", hr); - shader_free_signature(&shader->output_signature); - hr = E_INVALIDARG; - return hr; + return E_INVALIDARG; } return S_OK; @@ -563,9 +565,7 @@ static void STDMETHODCALLTYPE d3d10_pixel_shader_wined3d_object_destroyed(void *parent) { - struct d3d10_pixel_shader *shader = parent; - shader_free_signature(&shader->output_signature); - HeapFree(GetProcessHeap(), 0, shader); + HeapFree(GetProcessHeap(), 0, parent); } static const struct wined3d_parent_ops d3d10_pixel_shader_wined3d_parent_ops = @@ -576,28 +576,36 @@ HRESULT d3d10_pixel_shader_init(struct d3d10_pixel_shader *shader, struct d3d10_device *device, const void *byte_code, SIZE_T byte_code_length) { + struct wined3d_shader_signature output_signature; + struct wined3d_shader_signature input_signature; struct d3d10_shader_info shader_info; + struct wined3d_shader_desc desc; HRESULT hr; shader->ID3D10PixelShader_iface.lpVtbl = &d3d10_pixel_shader_vtbl; shader->refcount = 1; - shader_info.output_signature = &shader->output_signature; - hr = shader_extract_from_dxbc(byte_code, byte_code_length, &shader_info); - if (FAILED(hr)) + shader_info.input_signature = &input_signature; + shader_info.output_signature = &output_signature; + if (FAILED(hr = shader_extract_from_dxbc(byte_code, byte_code_length, &shader_info))) { ERR("Failed to extract shader, hr %#x.\n", hr); return hr; } - hr = wined3d_shader_create_ps(device->wined3d_device, shader_info.shader_code, - &shader->output_signature, shader, &d3d10_pixel_shader_wined3d_parent_ops, &shader->wined3d_shader, 4); + desc.byte_code = shader_info.shader_code; + desc.input_signature = &input_signature; + desc.output_signature = &output_signature; + desc.max_version = 4; + + hr = wined3d_shader_create_ps(device->wined3d_device, &desc, shader, + &d3d10_pixel_shader_wined3d_parent_ops, &shader->wined3d_shader); + shader_free_signature(&input_signature); + shader_free_signature(&output_signature); if (FAILED(hr)) { WARN("Failed to create wined3d pixel shader, hr %#x.\n", hr); - shader_free_signature(&shader->output_signature); - hr = E_INVALIDARG; - return hr; + return E_INVALIDARG; } shader->device = &device->ID3D10Device1_iface; diff -Nru wine1.7-1.7.28/dlls/d3d10core/tests/device.c wine1.7-1.7.31/dlls/d3d10core/tests/device.c --- wine1.7-1.7.28/dlls/d3d10core/tests/device.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d10core/tests/device.c 2014-11-14 13:28:17.000000000 +0000 @@ -20,6 +20,7 @@ #include "initguid.h" #include "d3d10.h" #include "wine/test.h" +#include static ULONG get_refcount(IUnknown *iface) { @@ -27,6 +28,22 @@ return IUnknown_Release(iface); } +static BOOL compare_float(float f, float g, unsigned int ulps) +{ + int x = *(int *)&f; + int y = *(int *)&g; + + if (x < 0) + x = INT_MIN - x; + if (y < 0) + y = INT_MIN - y; + + if (abs(x - y) > ulps) + return FALSE; + + return TRUE; +} + static BOOL compare_color(DWORD c1, DWORD c2, BYTE max_diff) { if (abs((c1 & 0xff) - (c2 & 0xff)) > max_diff) @@ -1186,6 +1203,856 @@ DestroyWindow(window); } +static void test_clear_state(void) +{ + static const D3D10_INPUT_ELEMENT_DESC layout_desc[] = + { + {"POSITION", 0, DXGI_FORMAT_R32G32B32A32_FLOAT, 0, 0, D3D10_INPUT_PER_VERTEX_DATA, 0}, + }; +#if 0 +float4 main(float4 pos : POSITION) : POSITION +{ + return pos; +} +#endif + static const DWORD simple_vs[] = + { + 0x43425844, 0x66689e7c, 0x643f0971, 0xb7f67ff4, 0xabc48688, 0x00000001, 0x000000d4, 0x00000003, + 0x0000002c, 0x00000060, 0x00000094, 0x4e475349, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, + 0x00000000, 0x00000000, 0x00000003, 0x00000000, 0x00000f0f, 0x49534f50, 0x4e4f4954, 0xababab00, + 0x4e47534f, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000000, 0x00000003, + 0x00000000, 0x0000000f, 0x49534f50, 0x4e4f4954, 0xababab00, 0x52444853, 0x00000038, 0x00010040, + 0x0000000e, 0x0300005f, 0x001010f2, 0x00000000, 0x03000065, 0x001020f2, 0x00000000, 0x05000036, + 0x001020f2, 0x00000000, 0x00101e46, 0x00000000, 0x0100003e, + }; + +#if 0 +struct gs_out +{ + float4 pos : SV_POSITION; +}; + +[maxvertexcount(4)] +void main(point float4 vin[1] : POSTION, inout TriangleStream vout) +{ + float offset = 0.1 * vin[0].w; + gs_out v; + + v.pos = float4(vin[0].x - offset, vin[0].y - offset, vin[0].z, vin[0].w); + vout.Append(v); + v.pos = float4(vin[0].x - offset, vin[0].y + offset, vin[0].z, vin[0].w); + vout.Append(v); + v.pos = float4(vin[0].x + offset, vin[0].y - offset, vin[0].z, vin[0].w); + vout.Append(v); + v.pos = float4(vin[0].x + offset, vin[0].y + offset, vin[0].z, vin[0].w); + vout.Append(v); +} +#endif + static const DWORD simple_gs[] = + { + 0x43425844, 0x9786dfb7, 0xad78ae61, 0x34364b9a, 0xf3b719f8, 0x00000001, 0x00000238, 0x00000003, + 0x0000002c, 0x0000005c, 0x00000090, 0x4e475349, 0x00000028, 0x00000001, 0x00000008, 0x00000020, + 0x00000000, 0x00000000, 0x00000003, 0x00000000, 0x00000f0f, 0x54534f50, 0x004e4f49, 0x4e47534f, + 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000001, 0x00000003, 0x00000000, + 0x0000000f, 0x505f5653, 0x5449534f, 0x004e4f49, 0x52444853, 0x000001a0, 0x00020040, 0x00000068, + 0x0400005f, 0x002010f2, 0x00000001, 0x00000000, 0x02000068, 0x00000001, 0x0100085d, 0x0100285c, + 0x04000067, 0x001020f2, 0x00000000, 0x00000001, 0x0200005e, 0x00000004, 0x0f000032, 0x00100032, + 0x00000000, 0x80201ff6, 0x00000041, 0x00000000, 0x00000000, 0x00004002, 0x3dcccccd, 0x3dcccccd, + 0x00000000, 0x00000000, 0x00201046, 0x00000000, 0x00000000, 0x05000036, 0x00102032, 0x00000000, + 0x00100046, 0x00000000, 0x06000036, 0x001020c2, 0x00000000, 0x00201ea6, 0x00000000, 0x00000000, + 0x01000013, 0x05000036, 0x00102012, 0x00000000, 0x0010000a, 0x00000000, 0x0e000032, 0x00100052, + 0x00000000, 0x00201ff6, 0x00000000, 0x00000000, 0x00004002, 0x3dcccccd, 0x00000000, 0x3dcccccd, + 0x00000000, 0x00201106, 0x00000000, 0x00000000, 0x05000036, 0x00102022, 0x00000000, 0x0010002a, + 0x00000000, 0x06000036, 0x001020c2, 0x00000000, 0x00201ea6, 0x00000000, 0x00000000, 0x01000013, + 0x05000036, 0x00102012, 0x00000000, 0x0010000a, 0x00000000, 0x05000036, 0x00102022, 0x00000000, + 0x0010001a, 0x00000000, 0x06000036, 0x001020c2, 0x00000000, 0x00201ea6, 0x00000000, 0x00000000, + 0x01000013, 0x05000036, 0x00102032, 0x00000000, 0x00100086, 0x00000000, 0x06000036, 0x001020c2, + 0x00000000, 0x00201ea6, 0x00000000, 0x00000000, 0x01000013, 0x0100003e, + }; + +#if 0 +float4 main(float4 color : COLOR) : SV_TARGET +{ + return color; +} +#endif + static const DWORD simple_ps[] = + { + 0x43425844, 0x08c2b568, 0x17d33120, 0xb7d82948, 0x13a570fb, 0x00000001, 0x000000d0, 0x00000003, + 0x0000002c, 0x0000005c, 0x00000090, 0x4e475349, 0x00000028, 0x00000001, 0x00000008, 0x00000020, + 0x00000000, 0x00000000, 0x00000003, 0x00000000, 0x00000f0f, 0x4f4c4f43, 0xabab0052, 0x4e47534f, + 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000000, 0x00000003, 0x00000000, + 0x0000000f, 0x545f5653, 0x45475241, 0xabab0054, 0x52444853, 0x00000038, 0x00000040, 0x0000000e, + 0x03001062, 0x001010f2, 0x00000000, 0x03000065, 0x001020f2, 0x00000000, 0x05000036, 0x001020f2, + 0x00000000, 0x00101e46, 0x00000000, 0x0100003e, + }; + + D3D10_VIEWPORT tmp_viewport[D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE]; + ID3D10ShaderResourceView *tmp_srv[D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT]; + ID3D10ShaderResourceView *srv[D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT]; + ID3D10RenderTargetView *tmp_rtv[D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT]; + RECT tmp_rect[D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE]; + ID3D10SamplerState *tmp_sampler[D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT]; + ID3D10RenderTargetView *rtv[D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT]; + ID3D10Texture2D *rt_texture[D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT]; + ID3D10Buffer *cb[D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT]; + ID3D10Buffer *tmp_buffer[D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT]; + ID3D10SamplerState *sampler[D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT]; + ID3D10Buffer *buffer[D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT]; + UINT offset[D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT]; + UINT stride[D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT]; + ID3D10Buffer *so_buffer[D3D10_SO_BUFFER_SLOT_COUNT]; + ID3D10InputLayout *tmp_input_layout, *input_layout; + ID3D10DepthStencilState *tmp_ds_state, *ds_state; + ID3D10BlendState *tmp_blend_state, *blend_state; + ID3D10RasterizerState *tmp_rs_state, *rs_state; + ID3D10Predicate *tmp_predicate, *predicate; + D3D10_SHADER_RESOURCE_VIEW_DESC srv_desc; + ID3D10DepthStencilView *tmp_dsv, *dsv; + D3D10_PRIMITIVE_TOPOLOGY topology; + D3D10_TEXTURE2D_DESC texture_desc; + ID3D10GeometryShader *tmp_gs, *gs; + D3D10_DEPTH_STENCIL_DESC ds_desc; + ID3D10VertexShader *tmp_vs, *vs; + D3D10_SAMPLER_DESC sampler_desc; + D3D10_QUERY_DESC predicate_desc; + ID3D10PixelShader *tmp_ps, *ps; + D3D10_RASTERIZER_DESC rs_desc; + D3D10_BUFFER_DESC buffer_desc; + D3D10_BLEND_DESC blend_desc; + ID3D10Texture2D *ds_texture; + float blend_factor[4]; + ID3D10Device *device; + BOOL predicate_value; + DXGI_FORMAT format; + UINT sample_mask; + UINT stencil_ref; + ULONG refcount; + UINT count, i; + HRESULT hr; + + if (!(device = create_device())) + { + skip("Failed to create device, skipping tests.\n"); + return; + } + + /* Verify the initial state after device creation. */ + + ID3D10Device_VSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected constant buffer %p in slot %u.\n", tmp_buffer[i], i); + } + ID3D10Device_VSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(!tmp_srv[i], "Got unexpected shader resource view %p in slot %u.\n", tmp_srv[i], i); + } + ID3D10Device_VSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(!tmp_sampler[i], "Got unexpected sampler %p in slot %u.\n", tmp_sampler[i], i); + } + ID3D10Device_VSGetShader(device, &tmp_vs); + ok(!tmp_vs, "Got unexpected vertex shader %p.\n", tmp_vs); + + ID3D10Device_GSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected constant buffer %p in slot %u.\n", tmp_buffer[i], i); + } + ID3D10Device_GSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(!tmp_srv[i], "Got unexpected shader resource view %p in slot %u.\n", tmp_srv[i], i); + } + ID3D10Device_GSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(!tmp_sampler[i], "Got unexpected sampler %p in slot %u.\n", tmp_sampler[i], i); + } + ID3D10Device_GSGetShader(device, &tmp_gs); + ok(!tmp_gs, "Got unexpected geometry shader %p.\n", tmp_gs); + + ID3D10Device_PSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected constant buffer %p in slot %u.\n", tmp_buffer[i], i); + } + ID3D10Device_PSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(!tmp_srv[i], "Got unexpected shader resource view %p in slot %u.\n", tmp_srv[i], i); + } + ID3D10Device_PSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(!tmp_sampler[i], "Got unexpected sampler %p in slot %u.\n", tmp_sampler[i], i); + } + ID3D10Device_PSGetShader(device, &tmp_ps); + ok(!tmp_ps, "Got unexpected pixel shader %p.\n", tmp_ps); + + ID3D10Device_IAGetVertexBuffers(device, 0, D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT, tmp_buffer, stride, offset); + for (i = 0; i < D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected vertex buffer %p in slot %u.\n", tmp_buffer[i], i); + ok(!stride[i], "Got unexpected stride %u in slot %u.\n", stride[i], i); + ok(!offset[i], "Got unexpected offset %u in slot %u.\n", offset[i], i); + } + ID3D10Device_IAGetIndexBuffer(device, tmp_buffer, &format, offset); + ok(!tmp_buffer[0], "Got unexpected index buffer %p.\n", tmp_buffer[0]); + ok(format == DXGI_FORMAT_UNKNOWN, "Got unexpected index buffer format %#x.\n", format); + ok(!offset[0], "Got unexpected index buffer offset %u.\n", offset[0]); + ID3D10Device_IAGetInputLayout(device, &tmp_input_layout); + ok(!tmp_input_layout, "Got unexpected input layout %p.\n", tmp_input_layout); + ID3D10Device_IAGetPrimitiveTopology(device, &topology); + ok(topology == D3D10_PRIMITIVE_TOPOLOGY_UNDEFINED, "Got unexpected primitive topology %#x.\n", topology); + + ID3D10Device_OMGetBlendState(device, &tmp_blend_state, blend_factor, &sample_mask); + ok(!tmp_blend_state, "Got unexpected blend state %p.\n", tmp_blend_state); + ok(blend_factor[0] == 1.0f && blend_factor[1] == 1.0f + && blend_factor[2] == 1.0f && blend_factor[3] == 1.0f, + "Got unexpected blend factor {%.8e, %.8e, %.8e, %.8e}.\n", + blend_factor[0], blend_factor[1], blend_factor[2], blend_factor[3]); + ok(sample_mask == D3D10_DEFAULT_SAMPLE_MASK, "Got unexpected sample mask %#x.\n", sample_mask); + ID3D10Device_OMGetDepthStencilState(device, &tmp_ds_state, &stencil_ref); + ok(!tmp_ds_state, "Got unexpected depth stencil state %p.\n", tmp_ds_state); + ok(!stencil_ref, "Got unexpected stencil ref %u.\n", stencil_ref); + ID3D10Device_OMGetRenderTargets(device, D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT, tmp_rtv, &tmp_dsv); + for (i = 0; i < D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT; ++i) + { + ok(!tmp_rtv[i], "Got unexpected render target view %p in slot %u.\n", tmp_rtv[i], i); + } + ok(!tmp_dsv, "Got unexpected depth stencil view %p.\n", tmp_dsv); + + ID3D10Device_RSGetScissorRects(device, &count, NULL); + todo_wine ok(!count, "Got unexpected scissor rect count %u.\n", count); + memset(tmp_rect, 0x55, sizeof(tmp_rect)); + count = D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; + ID3D10Device_RSGetScissorRects(device, &count, tmp_rect); + for (i = 0; i < D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; ++i) + { + ok(!tmp_rect[i].left && !tmp_rect[i].top && !tmp_rect[i].right && !tmp_rect[i].bottom, + "Got unexpected scissor rect {%d, %d, %d, %d} in slot %u.\n", + tmp_rect[i].left, tmp_rect[i].top, tmp_rect[i].right, tmp_rect[i].bottom, i); + } + ID3D10Device_RSGetViewports(device, &count, NULL); + todo_wine ok(!count, "Got unexpected viewport count %u.\n", count); + memset(tmp_viewport, 0x55, sizeof(tmp_viewport)); + count = D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; + ID3D10Device_RSGetViewports(device, &count, tmp_viewport); + for (i = 0; i < D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; ++i) + { + ok(!tmp_viewport[i].TopLeftX && !tmp_viewport[i].TopLeftY && !tmp_viewport[i].Width + && !tmp_viewport[i].Height && !tmp_viewport[i].MinDepth && !tmp_viewport[i].MaxDepth, + "Got unexpected viewport {%d, %d, %u, %u, %.8e, %.8e} in slot %u.\n", + tmp_viewport[i].TopLeftX, tmp_viewport[i].TopLeftY, tmp_viewport[i].Width, + tmp_viewport[i].Height, tmp_viewport[i].MinDepth, tmp_viewport[i].MaxDepth, i); + } + ID3D10Device_RSGetState(device, &tmp_rs_state); + ok(!tmp_rs_state, "Got unexpected rasterizer state %p.\n", tmp_rs_state); + + ID3D10Device_SOGetTargets(device, D3D10_SO_BUFFER_SLOT_COUNT, tmp_buffer, offset); + for (i = 0; i < D3D10_SO_BUFFER_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected stream output %p in slot %u.\n", tmp_buffer[i], i); + ok(!offset[i], "Got unexpected stream output offset %u in slot %u.\n", offset[i], i); + } + + ID3D10Device_GetPredication(device, &tmp_predicate, &predicate_value); + ok(!tmp_predicate, "Got unexpected predicate %p.\n", tmp_predicate); + ok(!predicate_value, "Got unexpected predicate value %#x.\n", predicate_value); + + /* Create resources. */ + + buffer_desc.ByteWidth = 1024; + buffer_desc.Usage = D3D10_USAGE_DEFAULT; + buffer_desc.BindFlags = D3D10_BIND_CONSTANT_BUFFER; + buffer_desc.CPUAccessFlags = 0; + buffer_desc.MiscFlags = 0; + + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + hr = ID3D10Device_CreateBuffer(device, &buffer_desc, NULL, &cb[i]); + ok(SUCCEEDED(hr), "Failed to create buffer, hr %#x.\n", hr); + } + + buffer_desc.BindFlags = D3D10_BIND_VERTEX_BUFFER | D3D10_BIND_INDEX_BUFFER | D3D10_BIND_SHADER_RESOURCE; + + for (i = 0; i < D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + hr = ID3D10Device_CreateBuffer(device, &buffer_desc, NULL, &buffer[i]); + ok(SUCCEEDED(hr), "Failed to create buffer, hr %#x.\n", hr); + + stride[i] = (i + 1) * 4; + offset[i] = (i + 1) * 16; + } + + buffer_desc.BindFlags = D3D10_BIND_STREAM_OUTPUT; + + for (i = 0; i < D3D10_SO_BUFFER_SLOT_COUNT; ++i) + { + hr = ID3D10Device_CreateBuffer(device, &buffer_desc, NULL, &so_buffer[i]); + ok(SUCCEEDED(hr), "Failed to create buffer, hr %#x.\n", hr); + } + + srv_desc.Format = DXGI_FORMAT_R32G32B32A32_FLOAT; + srv_desc.ViewDimension = D3D10_SRV_DIMENSION_BUFFER; + U(srv_desc).Buffer.ElementOffset = 0; + U(srv_desc).Buffer.ElementWidth = 64; + + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + hr = ID3D10Device_CreateShaderResourceView(device, + (ID3D10Resource *)buffer[i % D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT], &srv_desc, &srv[i]); + ok(SUCCEEDED(hr), "Failed to create shader resource view, hr %#x.\n", hr); + } + + sampler_desc.Filter = D3D10_FILTER_MIN_MAG_MIP_LINEAR; + sampler_desc.AddressU = D3D10_TEXTURE_ADDRESS_CLAMP; + sampler_desc.AddressV = D3D10_TEXTURE_ADDRESS_CLAMP; + sampler_desc.AddressW = D3D10_TEXTURE_ADDRESS_CLAMP; + sampler_desc.MipLODBias = 0.0f; + sampler_desc.MaxAnisotropy = 16; + sampler_desc.ComparisonFunc = D3D10_COMPARISON_NEVER; + sampler_desc.BorderColor[0] = 0.0f; + sampler_desc.BorderColor[1] = 0.0f; + sampler_desc.BorderColor[2] = 0.0f; + sampler_desc.BorderColor[3] = 0.0f; + sampler_desc.MinLOD = 0.0f; + sampler_desc.MaxLOD = 16.0f; + + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + sampler_desc.MinLOD = (float)i; + + hr = ID3D10Device_CreateSamplerState(device, &sampler_desc, &sampler[i]); + ok(SUCCEEDED(hr), "Failed to create sampler state, hr %#x.\n", hr); + } + + hr = ID3D10Device_CreateVertexShader(device, simple_vs, sizeof(simple_vs), &vs); + ok(SUCCEEDED(hr), "Failed to create vertex shader, hr %#x.\n", hr); + + hr = ID3D10Device_CreateGeometryShader(device, simple_gs, sizeof(simple_gs), &gs); + ok(SUCCEEDED(hr), "Failed to create geometry shader, hr %#x.\n", hr); + + hr = ID3D10Device_CreatePixelShader(device, simple_ps, sizeof(simple_ps), &ps); + ok(SUCCEEDED(hr), "Failed to create pixel shader, hr %#x.\n", hr); + + hr = ID3D10Device_CreateInputLayout(device, layout_desc, sizeof(layout_desc) / sizeof(*layout_desc), + simple_vs, sizeof(simple_vs), &input_layout); + ok(SUCCEEDED(hr), "Failed to create input layout, hr %#x.\n", hr); + + blend_desc.AlphaToCoverageEnable = FALSE; + blend_desc.BlendEnable[0] = FALSE; + blend_desc.BlendEnable[1] = FALSE; + blend_desc.BlendEnable[2] = FALSE; + blend_desc.BlendEnable[3] = FALSE; + blend_desc.BlendEnable[4] = FALSE; + blend_desc.BlendEnable[5] = FALSE; + blend_desc.BlendEnable[6] = FALSE; + blend_desc.BlendEnable[7] = FALSE; + blend_desc.SrcBlend = D3D10_BLEND_ONE; + blend_desc.DestBlend = D3D10_BLEND_ZERO; + blend_desc.BlendOp = D3D10_BLEND_OP_ADD; + blend_desc.SrcBlendAlpha = D3D10_BLEND_ONE; + blend_desc.DestBlendAlpha = D3D10_BLEND_ZERO; + blend_desc.BlendOpAlpha = D3D10_BLEND_OP_ADD; + blend_desc.RenderTargetWriteMask[0] = D3D10_COLOR_WRITE_ENABLE_ALL; + blend_desc.RenderTargetWriteMask[1] = D3D10_COLOR_WRITE_ENABLE_ALL; + blend_desc.RenderTargetWriteMask[2] = D3D10_COLOR_WRITE_ENABLE_ALL; + blend_desc.RenderTargetWriteMask[3] = D3D10_COLOR_WRITE_ENABLE_ALL; + blend_desc.RenderTargetWriteMask[4] = D3D10_COLOR_WRITE_ENABLE_ALL; + blend_desc.RenderTargetWriteMask[5] = D3D10_COLOR_WRITE_ENABLE_ALL; + blend_desc.RenderTargetWriteMask[6] = D3D10_COLOR_WRITE_ENABLE_ALL; + blend_desc.RenderTargetWriteMask[7] = D3D10_COLOR_WRITE_ENABLE_ALL; + + hr = ID3D10Device_CreateBlendState(device, &blend_desc, &blend_state); + ok(SUCCEEDED(hr), "Failed to create blend state, hr %#x.\n", hr); + + ds_desc.DepthEnable = TRUE; + ds_desc.DepthWriteMask = D3D10_DEPTH_WRITE_MASK_ALL; + ds_desc.DepthFunc = D3D10_COMPARISON_LESS; + ds_desc.StencilEnable = FALSE; + ds_desc.StencilReadMask = D3D10_DEFAULT_STENCIL_READ_MASK; + ds_desc.StencilWriteMask = D3D10_DEFAULT_STENCIL_WRITE_MASK; + ds_desc.FrontFace.StencilFailOp = D3D10_STENCIL_OP_KEEP; + ds_desc.FrontFace.StencilDepthFailOp = D3D10_STENCIL_OP_KEEP; + ds_desc.FrontFace.StencilPassOp = D3D10_STENCIL_OP_KEEP; + ds_desc.FrontFace.StencilFunc = D3D10_COMPARISON_ALWAYS; + ds_desc.BackFace.StencilFailOp = D3D10_STENCIL_OP_KEEP; + ds_desc.BackFace.StencilDepthFailOp = D3D10_STENCIL_OP_KEEP; + ds_desc.BackFace.StencilPassOp = D3D10_STENCIL_OP_KEEP; + ds_desc.BackFace.StencilFunc = D3D10_COMPARISON_ALWAYS; + + hr = ID3D10Device_CreateDepthStencilState(device, &ds_desc, &ds_state); + ok(SUCCEEDED(hr), "Failed to create depthstencil state, hr %#x.\n", hr); + + texture_desc.Width = 512; + texture_desc.Height = 512; + texture_desc.MipLevels = 1; + texture_desc.ArraySize = 1; + texture_desc.Format = DXGI_FORMAT_R8G8B8A8_UNORM; + texture_desc.SampleDesc.Count = 1; + texture_desc.SampleDesc.Quality = 0; + texture_desc.Usage = D3D10_USAGE_DEFAULT; + texture_desc.BindFlags = D3D10_BIND_RENDER_TARGET; + texture_desc.CPUAccessFlags = 0; + texture_desc.MiscFlags = 0; + + for (i = 0; i < D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT; ++i) + { + hr = ID3D10Device_CreateTexture2D(device, &texture_desc, NULL, &rt_texture[i]); + ok(SUCCEEDED(hr), "Failed to create texture, hr %#x.\n", hr); + } + + texture_desc.Format = DXGI_FORMAT_D24_UNORM_S8_UINT; + texture_desc.BindFlags = D3D10_BIND_DEPTH_STENCIL; + + hr = ID3D10Device_CreateTexture2D(device, &texture_desc, NULL, &ds_texture); + ok(SUCCEEDED(hr), "Failed to create texture, hr %#x.\n", hr); + + for (i = 0; i < D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT; ++i) + { + hr = ID3D10Device_CreateRenderTargetView(device, (ID3D10Resource *)rt_texture[i], NULL, &rtv[i]); + ok(SUCCEEDED(hr), "Failed to create rendertarget view, hr %#x.\n", hr); + } + + hr = ID3D10Device_CreateDepthStencilView(device, (ID3D10Resource *)ds_texture, NULL, &dsv); + ok(SUCCEEDED(hr), "Failed to create depthstencil view, hr %#x.\n", hr); + + for (i = 0; i < D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; ++i) + { + tmp_rect[i].left = i; + tmp_rect[i].top = i * 2; + tmp_rect[i].right = i + 1; + tmp_rect[i].bottom = (i + 1) * 2; + + tmp_viewport[i].TopLeftX = i * 3; + tmp_viewport[i].TopLeftY = i * 4; + tmp_viewport[i].Width = 3; + tmp_viewport[i].Height = 4; + tmp_viewport[i].MinDepth = i * 0.01f; + tmp_viewport[i].MaxDepth = (i + 1) * 0.01f; + } + + rs_desc.FillMode = D3D10_FILL_SOLID; + rs_desc.CullMode = D3D10_CULL_BACK; + rs_desc.FrontCounterClockwise = FALSE; + rs_desc.DepthBias = 0; + rs_desc.DepthBiasClamp = 0.0f; + rs_desc.SlopeScaledDepthBias = 0.0f; + rs_desc.DepthClipEnable = TRUE; + rs_desc.ScissorEnable = FALSE; + rs_desc.MultisampleEnable = FALSE; + rs_desc.AntialiasedLineEnable = FALSE; + + hr = ID3D10Device_CreateRasterizerState(device, &rs_desc, &rs_state); + ok(SUCCEEDED(hr), "Failed to create rasterizer state, hr %#x.\n", hr); + + predicate_desc.Query = D3D10_QUERY_OCCLUSION_PREDICATE; + predicate_desc.MiscFlags = 0; + + hr = ID3D10Device_CreatePredicate(device, &predicate_desc, &predicate); + ok(SUCCEEDED(hr), "Failed to create predicate, hr %#x.\n", hr); + + /* Setup state. */ + ID3D10Device_VSSetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, cb); + ID3D10Device_VSSetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, srv); + ID3D10Device_VSSetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, sampler); + ID3D10Device_VSSetShader(device, vs); + + ID3D10Device_GSSetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, cb); + ID3D10Device_GSSetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, srv); + ID3D10Device_GSSetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, sampler); + ID3D10Device_GSSetShader(device, gs); + + ID3D10Device_PSSetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, cb); + ID3D10Device_PSSetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, srv); + ID3D10Device_PSSetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, sampler); + ID3D10Device_PSSetShader(device, ps); + + ID3D10Device_IASetVertexBuffers(device, 0, D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT, buffer, stride, offset); + ID3D10Device_IASetIndexBuffer(device, buffer[0], DXGI_FORMAT_R32_UINT, offset[0]); + ID3D10Device_IASetInputLayout(device, input_layout); + ID3D10Device_IASetPrimitiveTopology(device, D3D10_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP); + + blend_factor[0] = 0.1f; + blend_factor[1] = 0.2f; + blend_factor[2] = 0.3f; + blend_factor[3] = 0.4f; + ID3D10Device_OMSetBlendState(device, blend_state, blend_factor, 0xff00ff00); + ID3D10Device_OMSetDepthStencilState(device, ds_state, 3); + ID3D10Device_OMSetRenderTargets(device, D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT, rtv, dsv); + + ID3D10Device_RSSetScissorRects(device, D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE, tmp_rect); + ID3D10Device_RSSetViewports(device, D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE, tmp_viewport); + ID3D10Device_RSSetState(device, rs_state); + + ID3D10Device_SOSetTargets(device, D3D10_SO_BUFFER_SLOT_COUNT, so_buffer, offset); + + ID3D10Device_SetPredication(device, predicate, TRUE); + + /* Verify the set state. */ + + ID3D10Device_VSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(tmp_buffer[i] == cb[i], "Got unexpected constant buffer %p in slot %u, expected %p.\n", + tmp_buffer[i], i, cb[i]); + ID3D10Buffer_Release(tmp_buffer[i]); + } + ID3D10Device_VSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(tmp_srv[i] == srv[i], "Got unexpected shader resource view %p in slot %u, expected %p.\n", + tmp_srv[i], i, srv[i]); + ID3D10ShaderResourceView_Release(tmp_srv[i]); + } + ID3D10Device_VSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(tmp_sampler[i] == sampler[i], "Got unexpected sampler %p in slot %u, expected %p.\n", + tmp_sampler[i], i, sampler[i]); + ID3D10SamplerState_Release(tmp_sampler[i]); + } + ID3D10Device_VSGetShader(device, &tmp_vs); + ok(tmp_vs == vs, "Got unexpected vertex shader %p, expected %p.\n", tmp_vs, vs); + ID3D10VertexShader_Release(tmp_vs); + + ID3D10Device_GSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(tmp_buffer[i] == cb[i], "Got unexpected constant buffer %p in slot %u, expected %p.\n", + tmp_buffer[i], i, cb[i]); + ID3D10Buffer_Release(tmp_buffer[i]); + } + ID3D10Device_GSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(tmp_srv[i] == srv[i], "Got unexpected shader resource view %p in slot %u, expected %p.\n", + tmp_srv[i], i, srv[i]); + ID3D10ShaderResourceView_Release(tmp_srv[i]); + } + ID3D10Device_GSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(tmp_sampler[i] == sampler[i], "Got unexpected sampler %p in slot %u, expected %p.\n", + tmp_sampler[i], i, sampler[i]); + ID3D10SamplerState_Release(tmp_sampler[i]); + } + ID3D10Device_GSGetShader(device, &tmp_gs); + ok(tmp_gs == gs, "Got unexpected geometry shader %p, expected %p.\n", tmp_gs, gs); + ID3D10GeometryShader_Release(tmp_gs); + + ID3D10Device_PSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(tmp_buffer[i] == cb[i], "Got unexpected constant buffer %p in slot %u, expected %p.\n", + tmp_buffer[i], i, cb[i]); + ID3D10Buffer_Release(tmp_buffer[i]); + } + ID3D10Device_PSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(tmp_srv[i] == srv[i], "Got unexpected shader resource view %p in slot %u, expected %p.\n", + tmp_srv[i], i, srv[i]); + ID3D10ShaderResourceView_Release(tmp_srv[i]); + } + ID3D10Device_PSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(tmp_sampler[i] == sampler[i], "Got unexpected sampler %p in slot %u, expected %p.\n", + tmp_sampler[i], i, sampler[i]); + ID3D10SamplerState_Release(tmp_sampler[i]); + } + ID3D10Device_PSGetShader(device, &tmp_ps); + ok(tmp_ps == ps, "Got unexpected pixel shader %p, expected %p.\n", tmp_ps, ps); + ID3D10PixelShader_Release(tmp_ps); + + ID3D10Device_IAGetVertexBuffers(device, 0, D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT, tmp_buffer, stride, offset); + for (i = 0; i < D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(tmp_buffer[i] == buffer[i], "Got unexpected vertex buffer %p in slot %u, expected %p.\n", + tmp_buffer[i], i, buffer[i]); + ok(stride[i] == (i + 1) * 4, "Got unexpected stride %u in slot %u.\n", stride[i], i); + ok(offset[i] == (i + 1) * 16, "Got unexpected offset %u in slot %u.\n", offset[i], i); + ID3D10Buffer_Release(tmp_buffer[i]); + } + ID3D10Device_IAGetIndexBuffer(device, tmp_buffer, &format, offset); + ok(tmp_buffer[0] == buffer[0], "Got unexpected index buffer %p, expected %p.\n", tmp_buffer[0], buffer[0]); + ID3D10Buffer_Release(tmp_buffer[0]); + ok(format == DXGI_FORMAT_R32_UINT, "Got unexpected index buffer format %#x.\n", format); + todo_wine ok(offset[0] == 16, "Got unexpected index buffer offset %u.\n", offset[0]); + ID3D10Device_IAGetInputLayout(device, &tmp_input_layout); + ok(tmp_input_layout == input_layout, "Got unexpected input layout %p, expected %p.\n", + tmp_input_layout, input_layout); + ID3D10InputLayout_Release(tmp_input_layout); + ID3D10Device_IAGetPrimitiveTopology(device, &topology); + ok(topology == D3D10_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP, "Got unexpected primitive topology %#x.\n", topology); + + ID3D10Device_OMGetBlendState(device, &tmp_blend_state, blend_factor, &sample_mask); + ok(tmp_blend_state == blend_state, "Got unexpected blend state %p, expected %p.\n", tmp_blend_state, blend_state); + ID3D10BlendState_Release(tmp_blend_state); + ok(blend_factor[0] == 0.1f && blend_factor[1] == 0.2f + && blend_factor[2] == 0.3f && blend_factor[3] == 0.4f, + "Got unexpected blend factor {%.8e, %.8e, %.8e, %.8e}.\n", + blend_factor[0], blend_factor[1], blend_factor[2], blend_factor[3]); + ok(sample_mask == 0xff00ff00, "Got unexpected sample mask %#x.\n", sample_mask); + ID3D10Device_OMGetDepthStencilState(device, &tmp_ds_state, &stencil_ref); + ok(tmp_ds_state == ds_state, "Got unexpected depth stencil state %p, expected %p.\n", tmp_ds_state, ds_state); + ID3D10DepthStencilState_Release(tmp_ds_state); + ok(stencil_ref == 3, "Got unexpected stencil ref %u.\n", stencil_ref); + ID3D10Device_OMGetRenderTargets(device, D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT, tmp_rtv, &tmp_dsv); + for (i = 0; i < D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT; ++i) + { + ok(tmp_rtv[i] == rtv[i], "Got unexpected render target view %p in slot %u, expected %p.\n", + tmp_rtv[i], i, rtv[i]); + ID3D10RenderTargetView_Release(tmp_rtv[i]); + } + ok(tmp_dsv == dsv, "Got unexpected depth stencil view %p, expected %p.\n", tmp_dsv, dsv); + ID3D10DepthStencilView_Release(tmp_dsv); + + ID3D10Device_RSGetScissorRects(device, &count, NULL); + todo_wine ok(count == D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE, + "Got unexpected scissor rect count %u.\n", count); + memset(tmp_rect, 0x55, sizeof(tmp_rect)); + ID3D10Device_RSGetScissorRects(device, &count, tmp_rect); + for (i = 0; i < count; ++i) + { + ok(tmp_rect[i].left == i + && tmp_rect[i].top == i * 2 + && tmp_rect[i].right == i + 1 + && tmp_rect[i].bottom == (i + 1) * 2, + "Got unexpected scissor rect {%d, %d, %d, %d} in slot %u.\n", + tmp_rect[i].left, tmp_rect[i].top, tmp_rect[i].right, tmp_rect[i].bottom, i); + } + ID3D10Device_RSGetViewports(device, &count, NULL); + todo_wine ok(count == D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE, + "Got unexpected viewport count %u.\n", count); + memset(tmp_viewport, 0x55, sizeof(tmp_viewport)); + ID3D10Device_RSGetViewports(device, &count, tmp_viewport); + for (i = 0; i < count; ++i) + { + ok(tmp_viewport[i].TopLeftX == i * 3 + && tmp_viewport[i].TopLeftY == i * 4 + && tmp_viewport[i].Width == 3 + && tmp_viewport[i].Height == 4 + && compare_float(tmp_viewport[i].MinDepth, i * 0.01f, 16) + && compare_float(tmp_viewport[i].MaxDepth, (i + 1) * 0.01f, 16), + "Got unexpected viewport {%d, %d, %u, %u, %.8e, %.8e} in slot %u.\n", + tmp_viewport[i].TopLeftX, tmp_viewport[i].TopLeftY, tmp_viewport[i].Width, + tmp_viewport[i].Height, tmp_viewport[i].MinDepth, tmp_viewport[i].MaxDepth, i); + } + ID3D10Device_RSGetState(device, &tmp_rs_state); + ok(tmp_rs_state == rs_state, "Got unexpected rasterizer state %p, expected %p.\n", tmp_rs_state, rs_state); + ID3D10RasterizerState_Release(tmp_rs_state); + + ID3D10Device_SOGetTargets(device, D3D10_SO_BUFFER_SLOT_COUNT, tmp_buffer, offset); + for (i = 0; i < D3D10_SO_BUFFER_SLOT_COUNT; ++i) + { + ok(tmp_buffer[i] == so_buffer[i], "Got unexpected stream output %p in slot %u, expected %p.\n", + tmp_buffer[i], i, buffer[i]); + ID3D10Buffer_Release(tmp_buffer[i]); + todo_wine ok(offset[i] == ~0u, "Got unexpected stream output offset %u in slot %u.\n", offset[i], i); + } + + ID3D10Device_GetPredication(device, &tmp_predicate, &predicate_value); + ok(tmp_predicate == predicate, "Got unexpected predicate %p, expected %p.\n", tmp_predicate, predicate); + ID3D10Predicate_Release(tmp_predicate); + ok(predicate_value, "Got unexpected predicate value %#x.\n", predicate_value); + + /* Verify ClearState(). */ + + ID3D10Device_ClearState(device); + + ID3D10Device_VSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected constant buffer %p in slot %u.\n", tmp_buffer[i], i); + } + ID3D10Device_VSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(!tmp_srv[i], "Got unexpected shader resource view %p in slot %u.\n", tmp_srv[i], i); + } + ID3D10Device_VSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(!tmp_sampler[i], "Got unexpected sampler %p in slot %u.\n", tmp_sampler[i], i); + } + ID3D10Device_VSGetShader(device, &tmp_vs); + ok(!tmp_vs, "Got unexpected vertex shader %p.\n", tmp_vs); + + ID3D10Device_GSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected constant buffer %p in slot %u.\n", tmp_buffer[i], i); + } + ID3D10Device_GSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(!tmp_srv[i], "Got unexpected shader resource view %p in slot %u.\n", tmp_srv[i], i); + } + ID3D10Device_GSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(!tmp_sampler[i], "Got unexpected sampler %p in slot %u.\n", tmp_sampler[i], i); + } + ID3D10Device_GSGetShader(device, &tmp_gs); + ok(!tmp_gs, "Got unexpected geometry shader %p.\n", tmp_gs); + + ID3D10Device_PSGetConstantBuffers(device, 0, D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT, tmp_buffer); + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected constant buffer %p in slot %u.\n", tmp_buffer[i], i); + } + ID3D10Device_PSGetShaderResources(device, 0, D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT, tmp_srv); + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(!tmp_srv[i], "Got unexpected shader resource view %p in slot %u.\n", tmp_srv[i], i); + } + ID3D10Device_PSGetSamplers(device, 0, D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT, tmp_sampler); + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ok(!tmp_sampler[i], "Got unexpected sampler %p in slot %u.\n", tmp_sampler[i], i); + } + ID3D10Device_PSGetShader(device, &tmp_ps); + ok(!tmp_ps, "Got unexpected pixel shader %p.\n", tmp_ps); + + ID3D10Device_IAGetVertexBuffers(device, 0, D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT, tmp_buffer, stride, offset); + for (i = 0; i < D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected vertex buffer %p in slot %u.\n", tmp_buffer[i], i); + todo_wine ok(!stride[i], "Got unexpected stride %u in slot %u.\n", stride[i], i); + todo_wine ok(!offset[i], "Got unexpected offset %u in slot %u.\n", offset[i], i); + } + ID3D10Device_IAGetIndexBuffer(device, tmp_buffer, &format, offset); + ok(!tmp_buffer[0], "Got unexpected index buffer %p.\n", tmp_buffer[0]); + ok(format == DXGI_FORMAT_UNKNOWN, "Got unexpected index buffer format %#x.\n", format); + ok(!offset[0], "Got unexpected index buffer offset %u.\n", offset[0]); + ID3D10Device_IAGetInputLayout(device, &tmp_input_layout); + ok(!tmp_input_layout, "Got unexpected input layout %p.\n", tmp_input_layout); + ID3D10Device_IAGetPrimitiveTopology(device, &topology); + ok(topology == D3D10_PRIMITIVE_TOPOLOGY_UNDEFINED, "Got unexpected primitive topology %#x.\n", topology); + + ID3D10Device_OMGetBlendState(device, &tmp_blend_state, blend_factor, &sample_mask); + ok(!tmp_blend_state, "Got unexpected blend state %p.\n", tmp_blend_state); + ok(blend_factor[0] == 1.0f && blend_factor[1] == 1.0f + && blend_factor[2] == 1.0f && blend_factor[3] == 1.0f, + "Got unexpected blend factor {%.8e, %.8e, %.8e, %.8e}.\n", + blend_factor[0], blend_factor[1], blend_factor[2], blend_factor[3]); + ok(sample_mask == D3D10_DEFAULT_SAMPLE_MASK, "Got unexpected sample mask %#x.\n", sample_mask); + ID3D10Device_OMGetDepthStencilState(device, &tmp_ds_state, &stencil_ref); + ok(!tmp_ds_state, "Got unexpected depth stencil state %p.\n", tmp_ds_state); + ok(!stencil_ref, "Got unexpected stencil ref %u.\n", stencil_ref); + ID3D10Device_OMGetRenderTargets(device, D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT, tmp_rtv, &tmp_dsv); + for (i = 0; i < D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT; ++i) + { + ok(!tmp_rtv[i], "Got unexpected render target view %p in slot %u.\n", tmp_rtv[i], i); + } + ok(!tmp_dsv, "Got unexpected depth stencil view %p.\n", tmp_dsv); + + ID3D10Device_RSGetScissorRects(device, &count, NULL); + todo_wine ok(!count, "Got unexpected scissor rect count %u.\n", count); + memset(tmp_rect, 0x55, sizeof(tmp_rect)); + count = D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; + ID3D10Device_RSGetScissorRects(device, &count, tmp_rect); + for (i = 0; i < D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; ++i) + { + if (!i) + todo_wine ok(!tmp_rect[i].left && !tmp_rect[i].top && !tmp_rect[i].right && !tmp_rect[i].bottom, + "Got unexpected scissor rect {%d, %d, %d, %d} in slot %u.\n", + tmp_rect[i].left, tmp_rect[i].top, tmp_rect[i].right, tmp_rect[i].bottom, i); + else + ok(!tmp_rect[i].left && !tmp_rect[i].top && !tmp_rect[i].right && !tmp_rect[i].bottom, + "Got unexpected scissor rect {%d, %d, %d, %d} in slot %u.\n", + tmp_rect[i].left, tmp_rect[i].top, tmp_rect[i].right, tmp_rect[i].bottom, i); + } + ID3D10Device_RSGetViewports(device, &count, NULL); + todo_wine ok(!count, "Got unexpected viewport count %u.\n", count); + memset(tmp_viewport, 0x55, sizeof(tmp_viewport)); + count = D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; + ID3D10Device_RSGetViewports(device, &count, tmp_viewport); + for (i = 0; i < D3D10_VIEWPORT_AND_SCISSORRECT_OBJECT_COUNT_PER_PIPELINE; ++i) + { + if (!i) + todo_wine ok(!tmp_viewport[i].TopLeftX && !tmp_viewport[i].TopLeftY && !tmp_viewport[i].Width + && !tmp_viewport[i].Height && !tmp_viewport[i].MinDepth && !tmp_viewport[i].MaxDepth, + "Got unexpected viewport {%d, %d, %u, %u, %.8e, %.8e} in slot %u.\n", + tmp_viewport[i].TopLeftX, tmp_viewport[i].TopLeftY, tmp_viewport[i].Width, + tmp_viewport[i].Height, tmp_viewport[i].MinDepth, tmp_viewport[i].MaxDepth, i); + else + ok(!tmp_viewport[i].TopLeftX && !tmp_viewport[i].TopLeftY && !tmp_viewport[i].Width + && !tmp_viewport[i].Height && !tmp_viewport[i].MinDepth && !tmp_viewport[i].MaxDepth, + "Got unexpected viewport {%d, %d, %u, %u, %.8e, %.8e} in slot %u.\n", + tmp_viewport[i].TopLeftX, tmp_viewport[i].TopLeftY, tmp_viewport[i].Width, + tmp_viewport[i].Height, tmp_viewport[i].MinDepth, tmp_viewport[i].MaxDepth, i); + } + ID3D10Device_RSGetState(device, &tmp_rs_state); + ok(!tmp_rs_state, "Got unexpected rasterizer state %p.\n", tmp_rs_state); + + ID3D10Device_SOGetTargets(device, D3D10_SO_BUFFER_SLOT_COUNT, tmp_buffer, offset); + for (i = 0; i < D3D10_SO_BUFFER_SLOT_COUNT; ++i) + { + ok(!tmp_buffer[i], "Got unexpected stream output %p in slot %u.\n", tmp_buffer[i], i); + ok(!offset[i], "Got unexpected stream output offset %u in slot %u.\n", offset[i], i); + } + + ID3D10Device_GetPredication(device, &tmp_predicate, &predicate_value); + ok(!tmp_predicate, "Got unexpected predicate %p.\n", tmp_predicate); + ok(!predicate_value, "Got unexpected predicate value %#x.\n", predicate_value); + + /* Cleanup. */ + + ID3D10Predicate_Release(predicate); + ID3D10RasterizerState_Release(rs_state); + ID3D10DepthStencilView_Release(dsv); + ID3D10Texture2D_Release(ds_texture); + + for (i = 0; i < D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT; ++i) + { + ID3D10RenderTargetView_Release(rtv[i]); + ID3D10Texture2D_Release(rt_texture[i]); + } + + ID3D10DepthStencilState_Release(ds_state); + ID3D10BlendState_Release(blend_state); + ID3D10InputLayout_Release(input_layout); + ID3D10VertexShader_Release(vs); + ID3D10GeometryShader_Release(gs); + ID3D10PixelShader_Release(ps); + + for (i = 0; i < D3D10_COMMONSHADER_SAMPLER_SLOT_COUNT; ++i) + { + ID3D10SamplerState_Release(sampler[i]); + } + + for (i = 0; i < D3D10_COMMONSHADER_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ID3D10ShaderResourceView_Release(srv[i]); + } + + for (i = 0; i < D3D10_SO_BUFFER_SLOT_COUNT; ++i) + { + ID3D10Buffer_Release(so_buffer[i]); + } + + for (i = 0; i < D3D10_IA_VERTEX_INPUT_RESOURCE_SLOT_COUNT; ++i) + { + ID3D10Buffer_Release(buffer[i]); + } + + for (i = 0; i < D3D10_COMMONSHADER_CONSTANT_BUFFER_API_SLOT_COUNT; ++i) + { + ID3D10Buffer_Release(cb[i]); + } + + refcount = ID3D10Device_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); +} + START_TEST(device) { test_create_texture2d(); @@ -1201,4 +2068,5 @@ test_create_predicate(); test_device_removed_reason(); test_scissor(); + test_clear_state(); } diff -Nru wine1.7-1.7.28/dlls/d3d8/shader.c wine1.7-1.7.31/dlls/d3d8/shader.c --- wine1.7-1.7.28/dlls/d3d8/shader.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d8/shader.c 2014-11-14 13:28:17.000000000 +0000 @@ -111,11 +111,19 @@ if (byte_code) { - if (usage) FIXME("Usage %#x not implemented.\n", usage); + struct wined3d_shader_desc desc; + + if (usage) + FIXME("Usage %#x not implemented.\n", usage); + + desc.byte_code = byte_code; + desc.input_signature = NULL; + desc.output_signature = NULL; + desc.max_version = 1; wined3d_mutex_lock(); - hr = wined3d_shader_create_vs(device->wined3d_device, byte_code, NULL /* output signature */, - shader, &d3d8_vertexshader_wined3d_parent_ops, &shader->wined3d_shader, 1); + hr = wined3d_shader_create_vs(device->wined3d_device, &desc, shader, + &d3d8_vertexshader_wined3d_parent_ops, &shader->wined3d_shader); wined3d_mutex_unlock(); if (FAILED(hr)) { @@ -152,13 +160,19 @@ HRESULT d3d8_pixel_shader_init(struct d3d8_pixel_shader *shader, struct d3d8_device *device, const DWORD *byte_code, DWORD shader_handle) { + struct wined3d_shader_desc desc; HRESULT hr; shader->handle = shader_handle; + desc.byte_code = byte_code; + desc.input_signature = NULL; + desc.output_signature = NULL; + desc.max_version = 1; + wined3d_mutex_lock(); - hr = wined3d_shader_create_ps(device->wined3d_device, byte_code, NULL, shader, - &d3d8_pixelshader_wined3d_parent_ops, &shader->wined3d_shader, 1); + hr = wined3d_shader_create_ps(device->wined3d_device, &desc, shader, + &d3d8_pixelshader_wined3d_parent_ops, &shader->wined3d_shader); wined3d_mutex_unlock(); if (FAILED(hr)) { diff -Nru wine1.7-1.7.28/dlls/d3d8/tests/device.c wine1.7-1.7.31/dlls/d3d8/tests/device.c --- wine1.7-1.7.28/dlls/d3d8/tests/device.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d8/tests/device.c 2014-11-14 13:28:17.000000000 +0000 @@ -31,11 +31,22 @@ float x, y, z; }; +#define CREATE_DEVICE_FULLSCREEN 0x01 +#define CREATE_DEVICE_FPU_PRESERVE 0x02 +#define CREATE_DEVICE_SWVP_ONLY 0x04 + +struct device_desc +{ + HWND device_window; + unsigned int width; + unsigned int height; + DWORD flags; +}; + #define GET_X_LPARAM(lp) ((int)(short)LOWORD(lp)) #define GET_Y_LPARAM(lp) ((int)(short)HIWORD(lp)) -static INT screen_width; -static INT screen_height; +static DEVMODEW registry_mode; static HRESULT (WINAPI *ValidateVertexShader)(DWORD *, DWORD *, DWORD *, int, DWORD *); static HRESULT (WINAPI *ValidatePixelShader)(DWORD *, DWORD *, int, DWORD *); @@ -78,46 +89,74 @@ } } -static IDirect3DDevice8 *create_device(IDirect3D8 *d3d8, HWND device_window, HWND focus_window, BOOL windowed) +static IDirect3DDevice8 *create_device(IDirect3D8 *d3d8, HWND focus_window, const struct device_desc *desc) { D3DPRESENT_PARAMETERS present_parameters = {0}; IDirect3DDevice8 *device; + DWORD behavior_flags = D3DCREATE_HARDWARE_VERTEXPROCESSING; - present_parameters.Windowed = windowed; - present_parameters.hDeviceWindow = device_window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - present_parameters.BackBufferWidth = screen_width; - present_parameters.BackBufferHeight = screen_height; + present_parameters.BackBufferWidth = 640; + present_parameters.BackBufferHeight = 480; present_parameters.BackBufferFormat = D3DFMT_A8R8G8B8; + present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; + present_parameters.hDeviceWindow = focus_window; + present_parameters.Windowed = TRUE; present_parameters.EnableAutoDepthStencil = TRUE; present_parameters.AutoDepthStencilFormat = D3DFMT_D24S8; + if (desc) + { + present_parameters.BackBufferWidth = desc->width; + present_parameters.BackBufferHeight = desc->height; + present_parameters.hDeviceWindow = desc->device_window; + present_parameters.Windowed = !(desc->flags & CREATE_DEVICE_FULLSCREEN); + if (desc->flags & CREATE_DEVICE_SWVP_ONLY) + behavior_flags = D3DCREATE_SOFTWARE_VERTEXPROCESSING; + if (desc->flags & CREATE_DEVICE_FPU_PRESERVE) + behavior_flags |= D3DCREATE_FPU_PRESERVE; + } + if (SUCCEEDED(IDirect3D8_CreateDevice(d3d8, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, &device))) return device; + behavior_flags, &present_parameters, &device))) + return device; present_parameters.AutoDepthStencilFormat = D3DFMT_D16; if (SUCCEEDED(IDirect3D8_CreateDevice(d3d8, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, &device))) return device; + behavior_flags, &present_parameters, &device))) + return device; + + if (desc && desc->flags & CREATE_DEVICE_SWVP_ONLY) + return NULL; + behavior_flags ^= (D3DCREATE_HARDWARE_VERTEXPROCESSING | D3DCREATE_SOFTWARE_VERTEXPROCESSING); if (SUCCEEDED(IDirect3D8_CreateDevice(d3d8, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_SOFTWARE_VERTEXPROCESSING, &present_parameters, &device))) return device; + behavior_flags, &present_parameters, &device))) + return device; return NULL; } -static HRESULT reset_device(IDirect3DDevice8 *device, HWND device_window, BOOL windowed) +static HRESULT reset_device(IDirect3DDevice8 *device, const struct device_desc *desc) { D3DPRESENT_PARAMETERS present_parameters = {0}; - present_parameters.Windowed = windowed; - present_parameters.hDeviceWindow = device_window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - present_parameters.BackBufferWidth = screen_width; - present_parameters.BackBufferHeight = screen_height; + present_parameters.BackBufferWidth = 640; + present_parameters.BackBufferHeight = 480; present_parameters.BackBufferFormat = D3DFMT_A8R8G8B8; + present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; + present_parameters.hDeviceWindow = NULL; + present_parameters.Windowed = TRUE; present_parameters.EnableAutoDepthStencil = TRUE; present_parameters.AutoDepthStencilFormat = D3DFMT_D24S8; + if (desc) + { + present_parameters.BackBufferWidth = desc->width; + present_parameters.BackBufferHeight = desc->height; + present_parameters.hDeviceWindow = desc->device_window; + present_parameters.Windowed = !(desc->flags & CREATE_DEVICE_FULLSCREEN); + } + return IDirect3DDevice8_Reset(device, &present_parameters); } @@ -195,7 +234,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -231,7 +270,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -367,7 +406,7 @@ CHECK_REFCOUNT(d3d, 1); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -702,7 +741,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -811,8 +850,7 @@ d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - device = create_device(d3d8, window, window, TRUE); - if (!device) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -885,7 +923,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -1539,7 +1577,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -1629,7 +1667,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -1823,7 +1861,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -1871,7 +1909,7 @@ ok(!!window, "Failed to create a window.\n"); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -1938,7 +1976,7 @@ ok(!!window, "Failed to create a window.\n"); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2151,7 +2189,8 @@ BOOL ret; p->dummy_window = CreateWindowA("d3d8_test_wndproc_wc", "d3d8_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); p->running_in_foreground = SetForegroundWindow(p->dummy_window); ret = SetEvent(p->window_created); @@ -2179,6 +2218,7 @@ static void test_wndproc(void) { struct wndproc_thread_param thread_params; + struct device_desc device_desc; IDirect3DDevice8 *device; WNDCLASSA wc = {0}; IDirect3D8 *d3d8; @@ -2212,9 +2252,11 @@ ok(!!thread_params.test_finished, "CreateEvent failed, last error %#x.\n", GetLastError()); focus_window = CreateWindowA("d3d8_test_wndproc_wc", "d3d8_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION , 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION , 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); device_window = CreateWindowA("d3d8_test_wndproc_wc", "d3d8_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION , 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION , 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); thread = CreateThread(NULL, 0, wndproc_thread, &thread_params, 0, &tid); ok(!!thread, "Failed to create thread, last error %#x.\n", GetLastError()); @@ -2246,8 +2288,11 @@ expect_messages = messages; - device = create_device(d3d8, device_window, focus_window, FALSE); - if (!device) + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d8, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -2274,8 +2319,7 @@ (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); ref = IDirect3DDevice8_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); @@ -2284,8 +2328,8 @@ ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", (LONG_PTR)test_proc, proc); - device = create_device(d3d8, focus_window, focus_window, FALSE); - if (!device) + device_desc.device_window = focus_window; + if (!(device = create_device(d3d8, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -2294,16 +2338,15 @@ ref = IDirect3DDevice8_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); - device = create_device(d3d8, device_window, focus_window, FALSE); - if (!device) + device_desc.device_window = device_window; + if (!(device = create_device(d3d8, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; } proc = SetWindowLongPtrA(focus_window, GWLP_WNDPROC, (LONG_PTR)DefWindowProcA); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); ref = IDirect3DDevice8_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); @@ -2330,6 +2373,7 @@ static void test_wndproc_windowed(void) { struct wndproc_thread_param thread_params; + struct device_desc device_desc; IDirect3DDevice8 *device; WNDCLASSA wc = {0}; IDirect3D8 *d3d8; @@ -2353,9 +2397,11 @@ ok(!!thread_params.test_finished, "CreateEvent failed, last error %#x.\n", GetLastError()); focus_window = CreateWindowA("d3d8_test_wndproc_wc", "d3d8_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); device_window = CreateWindowA("d3d8_test_wndproc_wc", "d3d8_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); thread = CreateThread(NULL, 0, wndproc_thread, &thread_params, 0, &tid); ok(!!thread, "Failed to create thread, last error %#x.\n", GetLastError()); @@ -2385,8 +2431,11 @@ filter_messages = focus_window; - device = create_device(d3d8, device_window, focus_window, TRUE); - if (!device) + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = 0; + if (!(device = create_device(d3d8, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -2408,7 +2457,8 @@ filter_messages = NULL; - hr = reset_device(device, device_window, FALSE); + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -2416,10 +2466,10 @@ (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); - hr = reset_device(device, device_window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -2437,8 +2487,8 @@ filter_messages = device_window; - device = create_device(d3d8, focus_window, focus_window, TRUE); - if (!device) + device_desc.device_window = focus_window; + if (!(device = create_device(d3d8, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -2446,7 +2496,8 @@ filter_messages = NULL; - hr = reset_device(device, focus_window, FALSE); + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -2454,10 +2505,10 @@ (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); - hr = reset_device(device, focus_window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -2473,8 +2524,8 @@ ref = IDirect3DDevice8_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); - device = create_device(d3d8, device_window, focus_window, TRUE); - if (!device) + device_desc.device_window = device_window; + if (!(device = create_device(d3d8, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -2482,7 +2533,8 @@ filter_messages = NULL; - hr = reset_device(device, device_window, FALSE); + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -2490,10 +2542,10 @@ (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); - hr = reset_device(device, device_window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -2553,7 +2605,7 @@ static void test_fpu_setup(void) { #if defined(D3D8_TEST_SET_FPU_CW) && defined(D3D8_TEST_GET_FPU_CW) - D3DPRESENT_PARAMETERS present_parameters; + struct device_desc device_desc; IDirect3DDevice8 *device; D3DDISPLAYMODE d3ddm; IDirect3D8 *d3d8; @@ -2561,7 +2613,8 @@ HRESULT hr; WORD cw; - window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_CAPTION, 0, 0, + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, 0, 0, 0, 0); ok(!!window, "Failed to create a window.\n"); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); @@ -2569,21 +2622,18 @@ hr = IDirect3D8_GetAdapterDisplayMode(d3d8, D3DADAPTER_DEFAULT, &d3ddm); ok(SUCCEEDED(hr), "GetAdapterDisplayMode failed, hr %#x.\n", hr); - memset(&present_parameters, 0, sizeof(present_parameters)); - present_parameters.Windowed = TRUE; - present_parameters.hDeviceWindow = window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - present_parameters.BackBufferFormat = d3ddm.Format; + device_desc.device_window = window; + device_desc.width = 640; + device_desc.height = 480; + device_desc.flags = 0; set_fpu_cw(0xf60); cw = get_fpu_cw(); ok(cw == 0xf60, "cw is %#x, expected 0xf60.\n", cw); - hr = IDirect3D8_CreateDevice(d3d8, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, window, - D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, &device); - if (FAILED(hr)) + if (!(device = create_device(d3d8, window, &device_desc))) { - skip("Failed to create a device, hr %#x.\n", hr); + skip("Failed to create a 3D device, skipping test.\n"); set_fpu_cw(0x37f); goto done; } @@ -2599,9 +2649,9 @@ cw = get_fpu_cw(); ok(cw == 0xf60, "cw is %#x, expected 0xf60.\n", cw); - hr = IDirect3D8_CreateDevice(d3d8, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, window, - D3DCREATE_HARDWARE_VERTEXPROCESSING | D3DCREATE_FPU_PRESERVE, &present_parameters, &device); - ok(SUCCEEDED(hr), "CreateDevice failed, hr %#x.\n", hr); + device_desc.flags = CREATE_DEVICE_FPU_PRESERVE; + device = create_device(d3d8, window, &device_desc); + ok(!!device, "CreateDevice failed.\n"); cw = get_fpu_cw(); ok(cw == 0xf60, "cw is %#x, expected 0xf60.\n", cw); @@ -2628,7 +2678,7 @@ ok(!!window, "Failed to create a window.\n"); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2678,8 +2728,11 @@ d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - device = create_device(d3d8, hwnd, hwnd, TRUE); - if (!device) goto cleanup; + if (!(device = create_device(d3d8, hwnd, NULL))) + { + skip("Failed to create a 3D device, skipping test.\n"); + goto cleanup; + } hr = IDirect3DDevice8_CreateRenderTarget(device, 64, 64, D3DFMT_A8R8G8B8, D3DMULTISAMPLE_NONE, FALSE, &rt); ok(SUCCEEDED(hr), "IDirect3DDevice8_CreateRenderTarget failed, hr %#x.\n", hr); @@ -2732,6 +2785,7 @@ RECT focus_rect, fullscreen_rect, r; LONG device_style, device_exstyle; LONG focus_style, focus_exstyle; + struct device_desc device_desc; LONG style, expected_style; IDirect3DDevice8 *device; IDirect3D8 *d3d8; @@ -2739,9 +2793,9 @@ ULONG ref; focus_window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); device_window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); @@ -2750,11 +2804,14 @@ focus_style = GetWindowLongA(focus_window, GWL_STYLE); focus_exstyle = GetWindowLongA(focus_window, GWL_EXSTYLE); - SetRect(&fullscreen_rect, 0, 0, screen_width, screen_height); + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); GetWindowRect(focus_window, &focus_rect); - device = create_device(d3d8, device_window, focus_window, FALSE); - if (!device) + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d8, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -2787,7 +2844,8 @@ focus_rect.left, focus_rect.top, focus_rect.right, focus_rect.bottom, r.left, r.top, r.right, r.bottom); - hr = reset_device(device, device_window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); style = GetWindowLongA(device_window, GWL_STYLE); @@ -2817,7 +2875,7 @@ DestroyWindow(focus_window); } -static void test_wrong_shader(void) +static void test_unsupported_shaders(void) { IDirect3DDevice8 *device; IDirect3D8 *d3d; @@ -2825,6 +2883,7 @@ DWORD vs, ps; HWND window; HRESULT hr; + D3DCAPS8 caps; static const DWORD vs_2_0[] = { @@ -2843,6 +2902,38 @@ 0x02000001, 0x800f0800, 0x80e40000, /* mov oC0, r0 */ 0x0000ffff /* end */ }; +#if 0 + vs_1_1 + dcl_position v0 + def c255, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c255 + mov oPos, r0 +#endif + static const DWORD vs_1_255[] = + { + 0xfffe0101, + 0x0000001f, 0x80000000, 0x900f0000, + 0x00000051, 0xa00f00ff, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x00000002, 0x800f0000, 0x90e40000, 0xa0e400ff, + 0x00000001, 0xc00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + vs_1_1 + dcl_position v0 + def c256, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c256 + mov oPos, r0 +#endif + static const DWORD vs_1_256[] = + { + 0xfffe0101, + 0x0000001f, 0x80000000, 0x900f0000, + 0x00000051, 0xa00f0100, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x00000002, 0x800f0000, 0x90e40000, 0xa0e40100, + 0x00000001, 0xc00f0000, 0x80e40000, + 0x0000ffff + }; static const DWORD decl[] = { @@ -2856,7 +2947,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -2876,6 +2967,23 @@ hr = IDirect3DDevice8_CreatePixelShader(device, ps_2_0, &ps); ok(hr == D3DERR_INVALIDCALL, "IDirect3DDevice8_CreatePixelShader returned %#08x\n", hr); + hr = IDirect3DDevice8_GetDeviceCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + if (caps.MaxVertexShaderConst < 256) + { + hr = IDirect3DDevice8_CreateVertexShader(device, decl, vs_1_255, &vs, 0); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + } + else + { + hr = IDirect3DDevice8_CreateVertexShader(device, decl, vs_1_255, &vs, 0); + ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice8_DeleteVertexShader(device, vs); + ok(hr == D3D_OK, "IDirect3DDevice8_DeleteVertexShader returned %#08x\n", hr); + hr = IDirect3DDevice8_CreateVertexShader(device, decl, vs_1_256, &vs, 0); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + } + refcount = IDirect3DDevice8_Release(device); ok(!refcount, "Device has %u references left.\n", refcount); IDirect3D8_Release(d3d); @@ -2884,52 +2992,119 @@ static void test_mode_change(void) { - RECT fullscreen_rect, focus_rect, r; + RECT d3d_rect, focus_rect, r; + struct device_desc device_desc; IDirect3DSurface8 *backbuffer; IDirect3DDevice8 *device; D3DSURFACE_DESC desc; IDirect3D8 *d3d8; DEVMODEW devmode; - UINT refcount; + ULONG refcount; + UINT adapter_mode_count, i; HRESULT hr; - DWORD ret; + BOOL ret; + LONG change_ret; + D3DDISPLAYMODE d3ddm; + DWORD d3d_width = 0, d3d_height = 0, user32_width = 0, user32_height = 0; - focus_window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); - device_window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - SetRect(&fullscreen_rect, 0, 0, screen_width, screen_height); - GetWindowRect(focus_window, &focus_rect); + adapter_mode_count = IDirect3D8_GetAdapterModeCount(d3d8, D3DADAPTER_DEFAULT); + for (i = 0; i < adapter_mode_count; ++i) + { + hr = IDirect3D8_EnumAdapterModes(d3d8, D3DADAPTER_DEFAULT, i, &d3ddm); + ok(SUCCEEDED(hr), "Failed to enumerate display mode, hr %#x.\n", hr); + + if (d3ddm.Format != D3DFMT_X8R8G8B8) + continue; + if (d3ddm.Width == registry_mode.dmPelsWidth && d3ddm.Height == registry_mode.dmPelsHeight) + continue; + /* The r200 driver on Windows XP enumerates modes like 320x200 and 320x240 but + * refuses to create a device at these sizes. */ + if (d3ddm.Width < 640 || d3ddm.Height < 480) + continue; + + if (!user32_width) + { + user32_width = d3ddm.Width; + user32_height = d3ddm.Height; + continue; + } - device = create_device(d3d8, device_window, focus_window, FALSE); - if (!device) + /* Make sure the d3d mode is smaller in width or height and at most + * equal in the other dimension than the mode passed to + * ChangeDisplaySettings. Otherwise Windows shrinks the window to + * the ChangeDisplaySettings parameters + 12. */ + if (d3ddm.Width == user32_width && d3ddm.Height == user32_height) + continue; + if (d3ddm.Width <= user32_width && d3ddm.Height <= user32_height) + { + d3d_width = d3ddm.Width; + d3d_height = d3ddm.Height; + break; + } + if (user32_width <= d3ddm.Width && user32_height <= d3ddm.Height) + { + d3d_width = user32_width; + d3d_height = user32_height; + user32_width = d3ddm.Width; + user32_height = d3ddm.Height; + break; + } + } + + if (!d3d_width) { - skip("Failed to create a D3D device, skipping tests.\n"); - goto done; + skip("Could not find adequate modes, skipping mode tests.\n"); + IDirect3D8_Release(d3d8); + return; } memset(&devmode, 0, sizeof(devmode)); devmode.dmSize = sizeof(devmode); devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; - devmode.dmPelsWidth = 640; - devmode.dmPelsHeight = 480; + devmode.dmPelsWidth = user32_width; + devmode.dmPelsHeight = user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + /* Make the windows visible, otherwise device::release does not restore the mode if + * the application is not in foreground like on the testbot. */ + focus_window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE, + 0, 0, user32_width / 2, user32_height / 2, 0, 0, 0, 0); + device_window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE, + 0, 0, user32_width / 2, user32_height / 2, 0, 0, 0, 0); - ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); - ok(ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", ret); + SetRect(&d3d_rect, 0, 0, d3d_width, d3d_height); + GetWindowRect(focus_window, &focus_rect); + + device_desc.device_window = device_window; + device_desc.width = d3d_width; + device_desc.height = d3d_height; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d8, focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + goto done; + } + + devmode.dmPelsWidth = user32_width; + devmode.dmPelsHeight = user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); - memset(&devmode, 0, sizeof(devmode)); - devmode.dmSize = sizeof(devmode); ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); ok(ret, "Failed to get display mode.\n"); - ok(devmode.dmPelsWidth == 640, "Got unexpect width %u.\n", devmode.dmPelsWidth); - ok(devmode.dmPelsHeight == 480, "Got unexpect height %u.\n", devmode.dmPelsHeight); + ok(devmode.dmPelsWidth == user32_width && devmode.dmPelsHeight == user32_height, + "Expected resolution %ux%u, got %ux%u.\n", + user32_width, user32_height, devmode.dmPelsWidth, devmode.dmPelsHeight); GetWindowRect(device_window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &d3d_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + d3d_rect.left, d3d_rect.top, d3d_rect.right, d3d_rect.bottom, r.left, r.top, r.right, r.bottom); GetWindowRect(focus_window, &r); ok(EqualRect(&r, &focus_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", @@ -2940,36 +3115,58 @@ ok(SUCCEEDED(hr), "Failed to get backbuffer, hr %#x.\n", hr); hr = IDirect3DSurface8_GetDesc(backbuffer, &desc); ok(SUCCEEDED(hr), "Failed to get backbuffer desc, hr %#x.\n", hr); - ok(desc.Width == screen_width, "Got unexpected backbuffer width %u.\n", desc.Width); - ok(desc.Height == screen_height, "Got unexpected backbuffer height %u.\n", desc.Height); + ok(desc.Width == d3d_width, "Got unexpected backbuffer width %u, expected %u.\n", + desc.Width, d3d_width); + ok(desc.Height == d3d_height, "Got unexpected backbuffer height %u, expected %u.\n", + desc.Height, d3d_height); IDirect3DSurface8_Release(backbuffer); refcount = IDirect3DDevice8_Release(device); ok(!refcount, "Device has %u references left.\n", refcount); - memset(&devmode, 0, sizeof(devmode)); - devmode.dmSize = sizeof(devmode); ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); ok(ret, "Failed to get display mode.\n"); - ok(devmode.dmPelsWidth == screen_width, "Got unexpect width %u.\n", devmode.dmPelsWidth); - ok(devmode.dmPelsHeight == screen_height, "Got unexpect height %u.\n", devmode.dmPelsHeight); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, devmode.dmPelsWidth, devmode.dmPelsHeight); + + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + /* The mode restore also happens when the device was created at the original screen size. */ + + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + ok(!!(device = create_device(d3d8, focus_window, &device_desc)), "Failed to create a D3D device.\n"); + + devmode.dmPelsWidth = user32_width; + devmode.dmPelsHeight = user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + refcount = IDirect3DDevice8_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); + + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, devmode.dmPelsWidth, devmode.dmPelsHeight); done: DestroyWindow(device_window); DestroyWindow(focus_window); IDirect3D8_Release(d3d8); - - memset(&devmode, 0, sizeof(devmode)); - devmode.dmSize = sizeof(devmode); - ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); - ok(ret, "Failed to get display mode.\n"); - ok(devmode.dmPelsWidth == screen_width, "Got unexpect width %u.\n", devmode.dmPelsWidth); - ok(devmode.dmPelsHeight == screen_height, "Got unexpect height %u.\n", devmode.dmPelsHeight); } static void test_device_window_reset(void) { RECT fullscreen_rect, device_rect, r; + struct device_desc device_desc; IDirect3DDevice8 *device; WNDCLASSA wc = {0}; IDirect3D8 *d3d8; @@ -2982,13 +3179,13 @@ ok(RegisterClassA(&wc), "Failed to register window class.\n"); focus_window = CreateWindowA("d3d8_test_wndproc_wc", "d3d8_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); device_window = CreateWindowA("d3d8_test_wndproc_wc", "d3d8_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - SetRect(&fullscreen_rect, 0, 0, screen_width, screen_height); + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); GetWindowRect(device_window, &device_rect); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -2998,8 +3195,11 @@ ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", (LONG_PTR)test_proc, proc); - device = create_device(d3d8, NULL, focus_window, FALSE); - if (!device) + device_desc.device_window = NULL; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d8, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3018,10 +3218,10 @@ ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); - hr = reset_device(device, device_window, FALSE); + device_desc.device_window = device_window; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device.\n"); GetWindowRect(focus_window, &r); @@ -3037,8 +3237,7 @@ ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); ref = IDirect3DDevice8_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); @@ -3066,8 +3265,7 @@ d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - device = create_device(d3d8, hwnd, hwnd, TRUE); - if (!device) + if (!(device = create_device(d3d8, hwnd, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3136,7 +3334,7 @@ d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3158,7 +3356,7 @@ IDirect3DSurface8_Release(rt); IDirect3DSurface8_Release(surface); - hr = reset_device(device, device_window, TRUE); + hr = reset_device(device, NULL); ok(SUCCEEDED(hr), "Failed to reset device.\n"); hr = IDirect3DDevice8_GetBackBuffer(device, 0, D3DBACKBUFFER_TYPE_MONO, &rt); @@ -3192,7 +3390,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -3208,8 +3406,8 @@ ok(SUCCEEDED(hr), "Failed to get viewport, hr %#x.\n", hr); ok(!vp.X, "Got unexpected vp.X %u.\n", vp.X); ok(!vp.Y, "Got unexpected vp.Y %u.\n", vp.Y); - ok(vp.Width == screen_width, "Got unexpected vp.Width %u.\n", vp.Width); - ok(vp.Height == screen_height, "Got unexpected vp.Height %u.\n", vp.Height); + ok(vp.Width == 640, "Got unexpected vp.Width %u.\n", vp.Width); + ok(vp.Height == 480, "Got unexpected vp.Height %u.\n", vp.Height); ok(vp.MinZ == 0.0f, "Got unexpected vp.MinZ %.8e.\n", vp.MinZ); ok(vp.MaxZ == 1.0f, "Got unexpected vp.MaxZ %.8e.\n", vp.MaxZ); @@ -3368,7 +3566,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -3466,7 +3664,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -3513,7 +3711,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -3602,7 +3800,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -3674,7 +3872,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -3710,7 +3908,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -3802,7 +4000,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -3910,7 +4108,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -4065,7 +4263,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -4112,7 +4310,7 @@ window = CreateWindowA("d3d8_test_wc", "d3d8_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -4196,7 +4394,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -4267,9 +4465,10 @@ {D3DFMT_DXT3, "D3DFMT_DXT3", 4, 4, FALSE, TRUE, TRUE }, {D3DFMT_DXT4, "D3DFMT_DXT4", 4, 4, FALSE, TRUE, TRUE }, {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, FALSE, TRUE, TRUE }, - /* ATI2N has 2x2 blocks on all AMD cards and Geforce 7 cards, + /* ATI1N and ATI2N have 2x2 blocks on all AMD cards and Geforce 7 cards, * which doesn't match the format spec. On newer Nvidia cards - * it has the correct 4x4 block size */ + * they have the correct 4x4 block size */ + {MAKEFOURCC('A','T','I','1'), "ATI1N", 4, 4, TRUE, FALSE, FALSE}, {MAKEFOURCC('A','T','I','2'), "ATI2N", 4, 4, TRUE, FALSE, FALSE}, /* Windows drivers generally enforce block-aligned locks for * YUY2 and UYVY. The notable exception is the AMD r500 driver @@ -4335,7 +4534,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -4608,7 +4807,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -4663,7 +4862,7 @@ IDirect3DVertexBuffer8 *buffer; static const unsigned int bufsize = 1024; D3DVERTEXBUFFER_DESC desc; - D3DPRESENT_PARAMETERS present_parameters = {0}; + struct device_desc device_desc; struct { float x, y, z; @@ -4674,15 +4873,11 @@ d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - present_parameters.Windowed = TRUE; - present_parameters.hDeviceWindow = window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - present_parameters.BackBufferWidth = screen_width; - present_parameters.BackBufferHeight = screen_height; - present_parameters.BackBufferFormat = D3DFMT_A8R8G8B8; - present_parameters.EnableAutoDepthStencil = FALSE; - if (FAILED(IDirect3D8_CreateDevice(d3d8, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, window, - D3DCREATE_SOFTWARE_VERTEXPROCESSING, &present_parameters, &device))) + device_desc.device_window = window; + device_desc.width = 640; + device_desc.height = 480; + device_desc.flags = CREATE_DEVICE_SWVP_ONLY; + if (!(device = create_device(d3d8, window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -4774,7 +4969,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -4895,7 +5090,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -5002,7 +5197,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -5108,7 +5303,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -5158,25 +5353,28 @@ unsigned int block_height; unsigned int block_depth; unsigned int block_size; - BOOL broken; + unsigned int broken; BOOL create_size_checked, core_fmt; } formats[] = { /* Scratch volumes enforce DXTn block locks, unlike their surface counterparts. * ATI2N and YUV blocks are not enforced on any tested card (r200, gtx 460). */ - {D3DFMT_DXT1, "D3DFMT_DXT1", 4, 4, 1, 8, FALSE, TRUE, TRUE }, - {D3DFMT_DXT2, "D3DFMT_DXT2", 4, 4, 1, 16, FALSE, TRUE, TRUE }, - {D3DFMT_DXT3, "D3DFMT_DXT3", 4, 4, 1, 16, FALSE, TRUE, TRUE }, - {D3DFMT_DXT4, "D3DFMT_DXT4", 4, 4, 1, 16, FALSE, TRUE, TRUE }, - {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 1, 16, FALSE, TRUE, TRUE }, - {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 1, 16, FALSE, TRUE, TRUE }, + {D3DFMT_DXT1, "D3DFMT_DXT1", 4, 4, 1, 8, 0, TRUE, TRUE }, + {D3DFMT_DXT2, "D3DFMT_DXT2", 4, 4, 1, 16, 0, TRUE, TRUE }, + {D3DFMT_DXT3, "D3DFMT_DXT3", 4, 4, 1, 16, 0, TRUE, TRUE }, + {D3DFMT_DXT4, "D3DFMT_DXT4", 4, 4, 1, 16, 0, TRUE, TRUE }, + {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 1, 16, 0, TRUE, TRUE }, + {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 1, 16, 0, TRUE, TRUE }, /* ATI2N has 2x2 blocks on all AMD cards and Geforce 7 cards, * which doesn't match the format spec. On newer Nvidia cards - * it has the correct 4x4 block size */ - {MAKEFOURCC('A','T','I','2'), "ATI2N", 4, 4, 1, 16, TRUE, FALSE, FALSE}, - {D3DFMT_YUY2, "D3DFMT_YUY2", 2, 1, 1, 4, TRUE, FALSE, TRUE }, - {D3DFMT_UYVY, "D3DFMT_UYVY", 2, 1, 1, 4, TRUE, FALSE, TRUE }, + * it has the correct 4x4 block size. + * ATI1N volume textures are only supported by AMD GPUs right + * now and locking offsets seem just wrong. */ + {MAKEFOURCC('A','T','I','1'), "ATI1N", 4, 4, 1, 8, 2, FALSE, FALSE}, + {MAKEFOURCC('A','T','I','2'), "ATI2N", 4, 4, 1, 16, 1, FALSE, FALSE}, + {D3DFMT_YUY2, "D3DFMT_YUY2", 2, 1, 1, 4, 1, FALSE, TRUE }, + {D3DFMT_UYVY, "D3DFMT_UYVY", 2, 1, 1, 4, 1, FALSE, TRUE }, }; static const struct { @@ -5218,7 +5416,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d8 = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d8, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d8, window, window, TRUE))) + if (!(device = create_device(d3d8, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d8); @@ -5324,10 +5522,14 @@ ok(SUCCEEDED(hr), "Failed to unlock volume texture, hr %#x.\n", hr); base = locked_box.pBits; - if (formats[i].broken) + if (formats[i].broken == 1) { expected_row_pitch = bytes_per_pixel * 24; } + else if (formats[i].broken == 2) + { + expected_row_pitch = 24; + } else { expected_row_pitch = (24 /* tex width */ + formats[i].block_height - 1) / formats[i].block_width @@ -5362,12 +5564,18 @@ ok(SUCCEEDED(hr), "Failed to lock volume texture, hr %#x, j %u.\n", hr, j); offset = (BYTE *)locked_box.pBits - base; - if (formats[i].broken) + if (formats[i].broken == 1) { expected_offset = box.Front * expected_slice_pitch + box.Top * expected_row_pitch + box.Left * bytes_per_pixel; } + else if (formats[i].broken == 2) + { + expected_offset = box.Front * expected_slice_pitch + + box.Top * expected_row_pitch + + box.Left; + } else { expected_offset = (box.Front / formats[i].block_depth) * expected_slice_pitch @@ -5535,7 +5743,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -5686,7 +5894,7 @@ test_format = GetPixelFormat(hdc); ok(test_format == format, "window has pixel format %d, expected %d\n", test_format, format); - if (!(device = create_device(d3d8, hwnd, hwnd, TRUE))) + if (!(device = create_device(d3d8, hwnd, NULL))) { skip("Failed to create device\n"); goto cleanup; @@ -5764,7 +5972,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -5820,7 +6028,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -5974,12 +6182,13 @@ ULONG refcount; HWND window; HRESULT hr; + D3DCAPS8 caps; window = CreateWindowA("static", "d3d8_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -5987,6 +6196,9 @@ return; } + hr = IDirect3DDevice8_GetDeviceCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + hr = IDirect3DDevice8_CreateImageSurface(device, 4, 4, D3DFMT_X8R8G8B8, &surface); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); hr = IDirect3DSurface8_GetDesc(surface, &surface_desc); @@ -6034,68 +6246,78 @@ IDirect3DSurface8_Release(surface); IDirect3DTexture8_Release(texture); - hr = IDirect3DDevice8_CreateCubeTexture(device, 1, 1, 0, D3DFMT_X8R8G8B8, - D3DPOOL_SYSTEMMEM, &cube_texture); - ok(SUCCEEDED(hr), "Failed to create cube texture, hr %#x.\n", hr); - type = IDirect3DCubeTexture8_GetType(cube_texture); - ok(type == D3DRTYPE_CUBETEXTURE, "Expected type D3DRTYPE_CUBETEXTURE, got %u.\n", type); - - hr = IDirect3DCubeTexture8_GetCubeMapSurface(cube_texture, - D3DCUBEMAP_FACE_NEGATIVE_X, 0, &surface); - ok(SUCCEEDED(hr), "Failed to get cube map surface, hr %#x.\n", hr); - hr = IDirect3DSurface8_GetDesc(surface, &surface_desc); - ok(SUCCEEDED(hr), "Failed to get surface description, hr %#x.\n", hr); - ok(surface_desc.Type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", - surface_desc.Type); - hr = IDirect3DCubeTexture8_GetLevelDesc(cube_texture, 0, &surface_desc); - ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); - ok(surface_desc.Type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", - surface_desc.Type); - IDirect3DSurface8_Release(surface); - IDirect3DCubeTexture8_Release(cube_texture); - - hr = IDirect3DDevice8_CreateVolumeTexture(device, 2, 4, 8, 4, 0, D3DFMT_X8R8G8B8, - D3DPOOL_SYSTEMMEM, &volume_texture); - type = IDirect3DVolumeTexture8_GetType(volume_texture); - ok(type == D3DRTYPE_VOLUMETEXTURE, "Expected type D3DRTYPE_VOLUMETEXTURE, got %u.\n", type); - - hr = IDirect3DVolumeTexture8_GetVolumeLevel(volume_texture, 0, &volume); - ok(SUCCEEDED(hr), "Failed to get volume level, hr %#x.\n", hr); - /* IDirect3DVolume8 is not an IDirect3DResource8 and has no GetType method. */ - hr = IDirect3DVolume8_GetDesc(volume, &volume_desc); - ok(SUCCEEDED(hr), "Failed to get volume description, hr %#x.\n", hr); - ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", - volume_desc.Type); - ok(volume_desc.Width == 2, "Expected width 2, got %u.\n", volume_desc.Width); - ok(volume_desc.Height == 4, "Expected height 4, got %u.\n", volume_desc.Height); - ok(volume_desc.Depth == 8, "Expected depth 8, got %u.\n", volume_desc.Depth); - hr = IDirect3DVolumeTexture8_GetLevelDesc(volume_texture, 0, &volume_desc); - ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); - ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", - volume_desc.Type); - ok(volume_desc.Width == 2, "Expected width 2, got %u.\n", volume_desc.Width); - ok(volume_desc.Height == 4, "Expected height 4, got %u.\n", volume_desc.Height); - ok(volume_desc.Depth == 8, "Expected depth 8, got %u.\n", volume_desc.Depth); - IDirect3DVolume8_Release(volume); + if (caps.TextureCaps & D3DPTEXTURECAPS_CUBEMAP) + { + hr = IDirect3DDevice8_CreateCubeTexture(device, 1, 1, 0, D3DFMT_X8R8G8B8, + D3DPOOL_SYSTEMMEM, &cube_texture); + ok(SUCCEEDED(hr), "Failed to create cube texture, hr %#x.\n", hr); + type = IDirect3DCubeTexture8_GetType(cube_texture); + ok(type == D3DRTYPE_CUBETEXTURE, "Expected type D3DRTYPE_CUBETEXTURE, got %u.\n", type); + + hr = IDirect3DCubeTexture8_GetCubeMapSurface(cube_texture, + D3DCUBEMAP_FACE_NEGATIVE_X, 0, &surface); + ok(SUCCEEDED(hr), "Failed to get cube map surface, hr %#x.\n", hr); + hr = IDirect3DSurface8_GetDesc(surface, &surface_desc); + ok(SUCCEEDED(hr), "Failed to get surface description, hr %#x.\n", hr); + ok(surface_desc.Type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", + surface_desc.Type); + hr = IDirect3DCubeTexture8_GetLevelDesc(cube_texture, 0, &surface_desc); + ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); + ok(surface_desc.Type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", + surface_desc.Type); + IDirect3DSurface8_Release(surface); + IDirect3DCubeTexture8_Release(cube_texture); + } + else + skip("Cube maps not supported.\n"); - hr = IDirect3DVolumeTexture8_GetVolumeLevel(volume_texture, 2, &volume); - ok(SUCCEEDED(hr), "Failed to get volume level, hr %#x.\n", hr); - hr = IDirect3DVolume8_GetDesc(volume, &volume_desc); - ok(SUCCEEDED(hr), "Failed to get volume description, hr %#x.\n", hr); - ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", - volume_desc.Type); - ok(volume_desc.Width == 1, "Expected width 1, got %u.\n", volume_desc.Width); - ok(volume_desc.Height == 1, "Expected height 1, got %u.\n", volume_desc.Height); - ok(volume_desc.Depth == 2, "Expected depth 2, got %u.\n", volume_desc.Depth); - hr = IDirect3DVolumeTexture8_GetLevelDesc(volume_texture, 2, &volume_desc); - ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); - ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", - volume_desc.Type); - ok(volume_desc.Width == 1, "Expected width 1, got %u.\n", volume_desc.Width); - ok(volume_desc.Height == 1, "Expected height 1, got %u.\n", volume_desc.Height); - ok(volume_desc.Depth == 2, "Expected depth 2, got %u.\n", volume_desc.Depth); - IDirect3DVolume8_Release(volume); - IDirect3DVolumeTexture8_Release(volume_texture); + if (caps.TextureCaps & D3DPTEXTURECAPS_MIPVOLUMEMAP) + { + hr = IDirect3DDevice8_CreateVolumeTexture(device, 2, 4, 8, 4, 0, D3DFMT_X8R8G8B8, + D3DPOOL_SYSTEMMEM, &volume_texture); + type = IDirect3DVolumeTexture8_GetType(volume_texture); + ok(type == D3DRTYPE_VOLUMETEXTURE, "Expected type D3DRTYPE_VOLUMETEXTURE, got %u.\n", type); + + hr = IDirect3DVolumeTexture8_GetVolumeLevel(volume_texture, 0, &volume); + ok(SUCCEEDED(hr), "Failed to get volume level, hr %#x.\n", hr); + /* IDirect3DVolume8 is not an IDirect3DResource8 and has no GetType method. */ + hr = IDirect3DVolume8_GetDesc(volume, &volume_desc); + ok(SUCCEEDED(hr), "Failed to get volume description, hr %#x.\n", hr); + ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", + volume_desc.Type); + ok(volume_desc.Width == 2, "Expected width 2, got %u.\n", volume_desc.Width); + ok(volume_desc.Height == 4, "Expected height 4, got %u.\n", volume_desc.Height); + ok(volume_desc.Depth == 8, "Expected depth 8, got %u.\n", volume_desc.Depth); + hr = IDirect3DVolumeTexture8_GetLevelDesc(volume_texture, 0, &volume_desc); + ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); + ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", + volume_desc.Type); + ok(volume_desc.Width == 2, "Expected width 2, got %u.\n", volume_desc.Width); + ok(volume_desc.Height == 4, "Expected height 4, got %u.\n", volume_desc.Height); + ok(volume_desc.Depth == 8, "Expected depth 8, got %u.\n", volume_desc.Depth); + IDirect3DVolume8_Release(volume); + + hr = IDirect3DVolumeTexture8_GetVolumeLevel(volume_texture, 2, &volume); + ok(SUCCEEDED(hr), "Failed to get volume level, hr %#x.\n", hr); + hr = IDirect3DVolume8_GetDesc(volume, &volume_desc); + ok(SUCCEEDED(hr), "Failed to get volume description, hr %#x.\n", hr); + ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", + volume_desc.Type); + ok(volume_desc.Width == 1, "Expected width 1, got %u.\n", volume_desc.Width); + ok(volume_desc.Height == 1, "Expected height 1, got %u.\n", volume_desc.Height); + ok(volume_desc.Depth == 2, "Expected depth 2, got %u.\n", volume_desc.Depth); + hr = IDirect3DVolumeTexture8_GetLevelDesc(volume_texture, 2, &volume_desc); + ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); + ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", + volume_desc.Type); + ok(volume_desc.Width == 1, "Expected width 1, got %u.\n", volume_desc.Width); + ok(volume_desc.Height == 1, "Expected height 1, got %u.\n", volume_desc.Height); + ok(volume_desc.Depth == 2, "Expected depth 2, got %u.\n", volume_desc.Depth); + IDirect3DVolume8_Release(volume); + IDirect3DVolumeTexture8_Release(volume_texture); + } + else + skip("Mipmapped volume maps not supported.\n"); refcount = IDirect3DDevice8_Release(device); ok(!refcount, "Device has %u references left.\n", refcount); @@ -6118,7 +6340,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -6200,7 +6422,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -6251,6 +6473,7 @@ static void test_lost_device(void) { + struct device_desc device_desc; IDirect3DDevice8 *device; IDirect3D8 *d3d; ULONG refcount; @@ -6262,7 +6485,11 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, FALSE))) + device_desc.device_window = window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d, window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -6295,14 +6522,15 @@ hr = IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3DERR_DEVICELOST, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, FALSE); + hr = reset_device(device, &device_desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice8_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice8_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); @@ -6323,7 +6551,8 @@ hr = IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, FALSE); + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice8_TestCooperativeLevel(device); todo_wine ok(hr == D3DERR_DEVICELOST, "Got unexpected hr %#x.\n", hr); @@ -6366,7 +6595,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate8(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D8_Release(d3d); @@ -6431,6 +6660,7 @@ HMODULE d3d8_handle = LoadLibraryA( "d3d8.dll" ); WNDCLASSA wc = {0}; IDirect3D8 *d3d8; + DEVMODEW current_mode; if (!d3d8_handle) { @@ -6438,6 +6668,18 @@ return; } + memset(¤t_mode, 0, sizeof(current_mode)); + current_mode.dmSize = sizeof(current_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, ¤t_mode), "Failed to get display mode.\n"); + registry_mode.dmSize = sizeof(registry_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_REGISTRY_SETTINGS, ®istry_mode), "Failed to get display mode.\n"); + if (current_mode.dmPelsWidth != registry_mode.dmPelsWidth + || current_mode.dmPelsHeight != registry_mode.dmPelsHeight) + { + skip("Current mode does not match registry mode, skipping test.\n"); + return; + } + wc.lpfnWndProc = DefWindowProcA; wc.lpszClassName = "d3d8_test_wc"; RegisterClassA(&wc); @@ -6452,9 +6694,6 @@ } IDirect3D8_Release(d3d8); - screen_width = GetSystemMetrics(SM_CXSCREEN); - screen_height = GetSystemMetrics(SM_CYSCREEN); - test_fpu_setup(); test_display_formats(); test_display_modes(); @@ -6477,7 +6716,7 @@ test_wndproc_windowed(); test_depth_stencil_size(); test_window_style(); - test_wrong_shader(); + test_unsupported_shaders(); test_mode_change(); test_device_window_reset(); test_reset_resources(); diff -Nru wine1.7-1.7.28/dlls/d3d8/tests/visual.c wine1.7-1.7.31/dlls/d3d8/tests/visual.c --- wine1.7-1.7.28/dlls/d3d8/tests/visual.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d8/tests/visual.c 2014-11-14 13:28:17.000000000 +0000 @@ -66,7 +66,7 @@ return 0xdeadbeef; } hr = IDirect3DTexture8_GetSurfaceLevel(tex, 0, &surf); - if(FAILED(hr) || !tex ) /* This is not a test */ + if (FAILED(hr)) /* This is not a test */ { trace("Can't get surface from texture, hr=%#08x\n", hr); ret = 0xdeadbeee; @@ -5058,6 +5058,309 @@ DestroyWindow(window); } +static void test_3dc_formats(void) +{ + static const char ati1n_data[] = + { + /* A 4x4 texture with the color component at 50%. */ + 0x7f, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + }; + static const char ati2n_data[] = + { + /* A 8x4 texture consisting of 2 4x4 blocks. The first block has 50% first color component, + * 0% second component. Second block is the opposite. */ + 0x7f, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + }; + static const struct + { + struct vec3 position; + struct vec2 texcoord; + } + quads[] = + { + {{-1.0f, -1.0f, 0.0f}, {0.0f, 0.0f}}, + {{-1.0f, 1.0f, 0.0f}, {0.0f, 1.0f}}, + {{ 0.0f, -1.0f, 1.0f}, {1.0f, 0.0f}}, + {{ 0.0f, 1.0f, 1.0f}, {1.0f, 1.0f}}, + + {{ 0.0f, -1.0f, 0.0f}, {0.0f, 0.0f}}, + {{ 0.0f, 1.0f, 0.0f}, {0.0f, 1.0f}}, + {{ 1.0f, -1.0f, 1.0f}, {1.0f, 0.0f}}, + {{ 1.0f, 1.0f, 1.0f}, {1.0f, 1.0f}}, + }; + static const DWORD ati1n_fourcc = MAKEFOURCC('A','T','I','1'); + static const DWORD ati2n_fourcc = MAKEFOURCC('A','T','I','2'); + static const struct + { + struct vec2 position; + D3DCOLOR amd; + D3DCOLOR nvidia; + } + expected_colors[] = + { + {{ 80, 240}, 0x003f3f3f, 0x007f0000}, + {{240, 240}, 0x003f3f3f, 0x007f0000}, + {{400, 240}, 0x00007fff, 0x00007fff}, + {{560, 240}, 0x007f00ff, 0x007f00ff}, + }; + IDirect3D8 *d3d; + IDirect3DDevice8 *device; + IDirect3DTexture8 *ati1n_texture, *ati2n_texture; + D3DCAPS8 caps; + D3DLOCKED_RECT rect; + D3DCOLOR color; + ULONG refcount; + HWND window; + HRESULT hr; + unsigned int i; + + window = CreateWindowA("static", "d3d8_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE, + 0, 0, 640, 480, NULL, NULL, NULL, NULL); + d3d = Direct3DCreate8(D3D_SDK_VERSION); + ok(!!d3d, "Failed to create a D3D object.\n"); + if (FAILED(IDirect3D8_CheckDeviceFormat(d3d, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, + D3DFMT_X8R8G8B8, 0, D3DRTYPE_TEXTURE, ati1n_fourcc))) + { + skip("ATI1N textures are not supported, skipping test.\n"); + goto done; + } + if (FAILED(IDirect3D8_CheckDeviceFormat(d3d, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, + D3DFMT_X8R8G8B8, 0, D3DRTYPE_TEXTURE, ati2n_fourcc))) + { + skip("ATI2N textures are not supported, skipping test.\n"); + goto done; + } + if (!(device = create_device(d3d, window, window, TRUE))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + goto done; + } + hr = IDirect3DDevice8_GetDeviceCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + if (!(caps.PrimitiveMiscCaps & D3DPMISCCAPS_TSSARGTEMP)) + { + skip("D3DTA_TEMP not supported, skipping tests.\n"); + IDirect3DDevice8_Release(device); + goto done; + } + + hr = IDirect3DDevice8_CreateTexture(device, 4, 4, 1, 0, ati1n_fourcc, + D3DPOOL_MANAGED, &ati1n_texture); + ok(SUCCEEDED(hr), "Failed to create texture, hr %#x.\n", hr); + + hr = IDirect3DTexture8_LockRect(ati1n_texture, 0, &rect, NULL, 0); + ok(SUCCEEDED(hr), "Failed to lock texture, hr %#x.\n", hr); + memcpy(rect.pBits, ati1n_data, sizeof(ati1n_data)); + hr = IDirect3DTexture8_UnlockRect(ati1n_texture, 0); + ok(SUCCEEDED(hr), "Failed to unlock texture, hr %#x.\n", hr); + + hr = IDirect3DDevice8_CreateTexture(device, 8, 4, 1, 0, ati2n_fourcc, + D3DPOOL_MANAGED, &ati2n_texture); + ok(SUCCEEDED(hr), "Failed to create texture, hr %#x.\n", hr); + + hr = IDirect3DTexture8_LockRect(ati2n_texture, 0, &rect, NULL, 0); + ok(SUCCEEDED(hr), "Failed to lock texture, hr %#x.\n", hr); + memcpy(rect.pBits, ati2n_data, sizeof(ati2n_data)); + hr = IDirect3DTexture8_UnlockRect(ati2n_texture, 0); + ok(SUCCEEDED(hr), "Failed to unlock texture, hr %#x.\n", hr); + + hr = IDirect3DDevice8_SetVertexShader(device, D3DFVF_XYZ | D3DFVF_TEX1 | D3DFVF_TEXCOORDSIZE2(0)); + ok(SUCCEEDED(hr), "Failed to set FVF, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTextureStageState(device, 0, D3DTSS_COLOROP, D3DTOP_BLENDTEXTUREALPHA); + ok(SUCCEEDED(hr), "Failed to set color op, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTextureStageState(device, 0, D3DTSS_COLORARG1, D3DTA_TEXTURE); + ok(SUCCEEDED(hr), "Failed to set color arg, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTextureStageState(device, 0, D3DTSS_COLORARG2, D3DTA_TEMP); + ok(SUCCEEDED(hr), "Failed to set color arg, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTextureStageState(device, 0, D3DTSS_ALPHAOP, D3DTOP_SELECTARG1); + ok(SUCCEEDED(hr), "Failed to set alpha op, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTextureStageState(device, 0, D3DTSS_ALPHAARG1, D3DTA_TEXTURE); + ok(SUCCEEDED(hr), "Failed to set alpha arg, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTextureStageState(device, 1, D3DTSS_COLOROP, D3DTOP_DISABLE); + ok(SUCCEEDED(hr), "Failed to set color op, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTextureStageState(device, 0, D3DTSS_MAGFILTER, D3DTEXF_POINT); + ok(SUCCEEDED(hr), "Failed to set mag filter, hr %#x.\n", hr); + + hr = IDirect3DDevice8_Clear(device, 0, NULL, D3DCLEAR_TARGET | D3DCLEAR_ZBUFFER, 0x00ff00ff, 1.0f, 0); + ok(SUCCEEDED(hr), "Failed to clear, hr %#x.\n", hr); + hr = IDirect3DDevice8_BeginScene(device); + ok(SUCCEEDED(hr), "Failed to begin scene, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTexture(device, 0, (IDirect3DBaseTexture8 *)ati1n_texture); + ok(SUCCEEDED(hr), "Failed to set texture, hr %#x.\n", hr); + hr = IDirect3DDevice8_DrawPrimitiveUP(device, D3DPT_TRIANGLESTRIP, 2, &quads[0], sizeof(*quads)); + ok(SUCCEEDED(hr), "Failed to draw, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTexture(device, 0, (IDirect3DBaseTexture8 *)ati2n_texture); + ok(SUCCEEDED(hr), "Failed to set texture, hr %#x.\n", hr); + hr = IDirect3DDevice8_DrawPrimitiveUP(device, D3DPT_TRIANGLESTRIP, 2, &quads[4], sizeof(*quads)); + ok(SUCCEEDED(hr), "Failed to draw, hr %#x.\n", hr); + hr = IDirect3DDevice8_EndScene(device); + ok(SUCCEEDED(hr), "Failed to end scene, hr %#x.\n", hr); + + hr = IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL); + ok(SUCCEEDED(hr), "Failed to present, hr %#x.\n", hr); + for (i = 0; i < 4; ++i) + { + color = getPixelColor(device, expected_colors[i].position.x, expected_colors[i].position.y); + ok (color_match(color, expected_colors[i].amd, 1) || color_match(color, expected_colors[i].nvidia, 1), + "Expected color 0x%08x or 0x%08x, got 0x%08x, case %u.\n", + expected_colors[i].amd, expected_colors[i].nvidia, color, i); + } + + IDirect3DTexture8_Release(ati2n_texture); + IDirect3DTexture8_Release(ati1n_texture); + refcount = IDirect3DDevice8_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); + +done: + IDirect3D8_Release(d3d); + DestroyWindow(window); +} + +static void fog_interpolation_test(void) +{ + HRESULT hr; + IDirect3DDevice8 *device; + IDirect3D8 *d3d; + ULONG refcount; + HWND window; + D3DCOLOR color; + static const struct + { + struct vec3 position; + D3DCOLOR diffuse; + D3DCOLOR specular; + } + quad[] = + { + {{-1.0f, -1.0f, 0.0f}, 0xffff0000, 0xff000000}, + {{-1.0f, 1.0f, 0.0f}, 0xffff0000, 0xff000000}, + {{ 1.0f, -1.0f, 1.0f}, 0xffff0000, 0x00000000}, + {{ 1.0f, 1.0f, 1.0f}, 0xffff0000, 0x00000000}, + }; + union + { + DWORD d; + float f; + } conv; + unsigned int i; + static const struct + { + D3DFOGMODE vfog, tfog; + D3DSHADEMODE shade; + D3DCOLOR middle_color; + BOOL todo; + } + tests[] = + { + {D3DFOG_NONE, D3DFOG_NONE, D3DSHADE_FLAT, 0x00007f80, FALSE}, + {D3DFOG_NONE, D3DFOG_NONE, D3DSHADE_GOURAUD, 0x00007f80, FALSE}, + {D3DFOG_EXP, D3DFOG_NONE, D3DSHADE_FLAT, 0x00007f80, TRUE}, + {D3DFOG_EXP, D3DFOG_NONE, D3DSHADE_GOURAUD, 0x00007f80, TRUE}, + {D3DFOG_NONE, D3DFOG_EXP, D3DSHADE_FLAT, 0x0000ea15, FALSE}, + {D3DFOG_NONE, D3DFOG_EXP, D3DSHADE_GOURAUD, 0x0000ea15, FALSE}, + {D3DFOG_EXP, D3DFOG_EXP, D3DSHADE_FLAT, 0x0000ea15, FALSE}, + {D3DFOG_EXP, D3DFOG_EXP, D3DSHADE_GOURAUD, 0x0000ea15, FALSE}, + }; + static const D3DMATRIX ident_mat = + {{{ + 1.0f, 0.0f, 0.0f, 0.0f, + 0.0f, 1.0f, 0.0f, 0.0f, + 0.0f, 0.0f, 1.0f, 0.0f, + 0.0f, 0.0f, 0.0f, 1.0f + }}}; + D3DCAPS8 caps; + + window = CreateWindowA("static", "d3d8_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE, + 0, 0, 640, 480, NULL, NULL, NULL, NULL); + d3d = Direct3DCreate8(D3D_SDK_VERSION); + ok(!!d3d, "Failed to create a D3D object.\n"); + + if (!(device = create_device(d3d, window, window, TRUE))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + IDirect3D8_Release(d3d); + DestroyWindow(window); + return; + } + + hr = IDirect3DDevice8_GetDeviceCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + if (!(caps.RasterCaps & D3DPRASTERCAPS_FOGTABLE)) + skip("D3DPRASTERCAPS_FOGTABLE not supported, skipping some fog tests\n"); + + hr = IDirect3DDevice8_SetVertexShader(device, D3DFVF_XYZ | D3DFVF_DIFFUSE | D3DFVF_SPECULAR); + ok(SUCCEEDED(hr), "Failed to set fvf, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_LIGHTING, FALSE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_ZENABLE, FALSE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_FOGENABLE, TRUE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_FOGCOLOR, 0x0000ff00); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + conv.f = 5.0; + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_FOGDENSITY, conv.d); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + + hr = IDirect3DDevice8_SetTextureStageState(device, 0, D3DTSS_COLOROP, D3DTOP_SELECTARG1); + ok(SUCCEEDED(hr), "Failed to set texture stage state, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetTextureStageState(device, 0, D3DTSS_COLORARG1, D3DTA_TFACTOR); + ok(SUCCEEDED(hr), "Failed to set texture stage state, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_TEXTUREFACTOR, 0x000000ff); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + + /* Some of the tests seem to depend on the projection matrix explicitly + * being set to an identity matrix, even though that's the default. + * (AMD Radeon X1600, AMD Radeon HD 6310, Windows 7). Without this, + * the drivers seem to use a static z = 1.0 input for the fog equation. + * The input value is independent of the actual z and w component of + * the vertex position. */ + hr = IDirect3DDevice8_SetTransform(device, D3DTS_PROJECTION, &ident_mat); + ok(SUCCEEDED(hr), "Failed to set projection transform, hr %#x.\n", hr); + + for (i = 0; i < sizeof(tests) / sizeof(*tests); i++) + { + if(!(caps.RasterCaps & D3DPRASTERCAPS_FOGTABLE) && tests[i].tfog) + continue; + + hr = IDirect3DDevice8_Clear(device, 0, NULL, D3DCLEAR_TARGET, 0x00808080, 0.0f, 0); + ok(SUCCEEDED(hr), "Failed to clear, hr %#x.\n", hr); + + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_SHADEMODE, tests[i].shade); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_FOGVERTEXMODE, tests[i].vfog); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice8_SetRenderState(device, D3DRS_FOGTABLEMODE, tests[i].tfog); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice8_BeginScene(device); + ok(SUCCEEDED(hr), "Failed to begin scene, hr %#x.\n", hr); + hr = IDirect3DDevice8_DrawPrimitiveUP(device, D3DPT_TRIANGLESTRIP, 2, quad, sizeof(*quad)); + ok(SUCCEEDED(hr), "Failed to draw, hr %#x.\n", hr); + hr = IDirect3DDevice8_EndScene(device); + ok(SUCCEEDED(hr), "Failed to end scene, hr %#x.\n", hr); + + color = getPixelColor(device, 0, 240); + ok(color_match(color, 0x000000ff, 2), "Got unexpected color 0x%08x, case %u.\n", color, i); + color = getPixelColor(device, 320, 240); + if (tests[i].todo) + todo_wine ok(color_match(color, tests[i].middle_color, 2), + "Got unexpected color 0x%08x, case %u.\n", color, i); + else + ok(color_match(color, tests[i].middle_color, 2), + "Got unexpected color 0x%08x, case %u.\n", color, i); + color = getPixelColor(device, 639, 240); + ok(color_match(color, 0x0000fd02, 2), "Got unexpected color 0x%08x, case %u.\n", color, i); + hr = IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL); + ok(SUCCEEDED(hr), "Failed to present, hr %#x.\n", hr); + } + + refcount = IDirect3DDevice8_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); + IDirect3D8_Release(d3d); + DestroyWindow(window); +} + START_TEST(visual) { D3DADAPTER_IDENTIFIER8 identifier; @@ -5107,4 +5410,6 @@ volume_dxt5_test(); volume_v16u16_test(); add_dirty_rect_test(); + test_3dc_formats(); + fog_interpolation_test(); } diff -Nru wine1.7-1.7.28/dlls/d3d9/shader.c wine1.7-1.7.31/dlls/d3d9/shader.c --- wine1.7-1.7.28/dlls/d3d9/shader.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d9/shader.c 2014-11-14 13:28:17.000000000 +0000 @@ -136,14 +136,20 @@ HRESULT vertexshader_init(struct d3d9_vertexshader *shader, struct d3d9_device *device, const DWORD *byte_code) { + struct wined3d_shader_desc desc; HRESULT hr; shader->refcount = 1; shader->IDirect3DVertexShader9_iface.lpVtbl = &d3d9_vertexshader_vtbl; + desc.byte_code = byte_code; + desc.input_signature = NULL; + desc.output_signature = NULL; + desc.max_version = 3; + wined3d_mutex_lock(); - hr = wined3d_shader_create_vs(device->wined3d_device, byte_code, NULL, - shader, &d3d9_vertexshader_wined3d_parent_ops, &shader->wined3d_shader, 3); + hr = wined3d_shader_create_vs(device->wined3d_device, &desc, shader, + &d3d9_vertexshader_wined3d_parent_ops, &shader->wined3d_shader); wined3d_mutex_unlock(); if (FAILED(hr)) { @@ -280,14 +286,20 @@ HRESULT pixelshader_init(struct d3d9_pixelshader *shader, struct d3d9_device *device, const DWORD *byte_code) { + struct wined3d_shader_desc desc; HRESULT hr; shader->refcount = 1; shader->IDirect3DPixelShader9_iface.lpVtbl = &d3d9_pixelshader_vtbl; + desc.byte_code = byte_code; + desc.input_signature = NULL; + desc.output_signature = NULL; + desc.max_version = 3; + wined3d_mutex_lock(); - hr = wined3d_shader_create_ps(device->wined3d_device, byte_code, NULL, shader, - &d3d9_pixelshader_wined3d_parent_ops, &shader->wined3d_shader, 3); + hr = wined3d_shader_create_ps(device->wined3d_device, &desc, shader, + &d3d9_pixelshader_wined3d_parent_ops, &shader->wined3d_shader); wined3d_mutex_unlock(); if (FAILED(hr)) { diff -Nru wine1.7-1.7.28/dlls/d3d9/tests/d3d9ex.c wine1.7-1.7.31/dlls/d3d9/tests/d3d9ex.c --- wine1.7-1.7.28/dlls/d3d9/tests/d3d9ex.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d9/tests/d3d9ex.c 2014-11-14 13:28:17.000000000 +0000 @@ -23,20 +23,25 @@ #define COBJMACROS #include "wine/test.h" -#include "winuser.h" -#include "wingdi.h" #include #include static HMODULE d3d9_handle = 0; - -static BOOL (WINAPI *pEnumDisplaySettingsExA)(const char *device_name, - DWORD mode_idx, DEVMODEA *mode, DWORD flags); -static LONG (WINAPI *pChangeDisplaySettingsExA)(const char *device_name, - DEVMODEA *mode, HWND window, DWORD flags, void *param); +static DEVMODEW registry_mode; static HRESULT (WINAPI *pDirect3DCreate9Ex)(UINT SDKVersion, IDirect3D9Ex **d3d9ex); +#define CREATE_DEVICE_FULLSCREEN 0x01 +#define CREATE_DEVICE_NOWINDOWCHANGES 0x02 + +struct device_desc +{ + HWND device_window; + unsigned int width; + unsigned int height; + DWORD flags; +}; + static HWND create_window(void) { WNDCLASSA wc = {0}; @@ -49,42 +54,76 @@ 0, 0, 640, 480, 0, 0, 0, 0); } -static IDirect3DDevice9Ex *create_device(HWND device_window, HWND focus_window, BOOL windowed) +/* try to make sure pending X events have been processed before continuing */ +static void flush_events(void) +{ + MSG msg; + int diff = 200; + int min_timeout = 100; + DWORD time = GetTickCount() + diff; + + while (diff > 0) + { + if (MsgWaitForMultipleObjects(0, NULL, FALSE, min_timeout, QS_ALLINPUT) == WAIT_TIMEOUT) + break; + while (PeekMessageA(&msg, 0, 0, 0, PM_REMOVE)) + DispatchMessageA(&msg); + diff = time - GetTickCount(); + } +} + +static IDirect3DDevice9Ex *create_device(HWND focus_window, const struct device_desc *desc) { D3DPRESENT_PARAMETERS present_parameters = {0}; IDirect3DDevice9Ex *device; D3DDISPLAYMODEEX mode, *m; IDirect3D9Ex *d3d9; + DWORD behavior_flags = D3DCREATE_HARDWARE_VERTEXPROCESSING; if (FAILED(pDirect3DCreate9Ex(D3D_SDK_VERSION, &d3d9))) return NULL; - present_parameters.Windowed = windowed; - present_parameters.hDeviceWindow = device_window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; present_parameters.BackBufferWidth = 640; present_parameters.BackBufferHeight = 480; present_parameters.BackBufferFormat = D3DFMT_A8R8G8B8; + present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; + present_parameters.hDeviceWindow = focus_window; + present_parameters.Windowed = TRUE; present_parameters.EnableAutoDepthStencil = TRUE; present_parameters.AutoDepthStencilFormat = D3DFMT_D24S8; + if (desc) + { + present_parameters.BackBufferWidth = desc->width; + present_parameters.BackBufferHeight = desc->height; + present_parameters.hDeviceWindow = desc->device_window; + present_parameters.Windowed = !(desc->flags & CREATE_DEVICE_FULLSCREEN); + if (desc->flags & CREATE_DEVICE_NOWINDOWCHANGES) + behavior_flags |= D3DCREATE_NOWINDOWCHANGES; + } + mode.Size = sizeof(mode); - mode.Width = 640; - mode.Height = 480; + mode.Width = present_parameters.BackBufferWidth; + mode.Height = present_parameters.BackBufferHeight; mode.RefreshRate = 0; mode.Format = D3DFMT_A8R8G8B8; mode.ScanLineOrdering = 0; - m = windowed ? NULL : &mode; + m = present_parameters.Windowed ? NULL : &mode; if (SUCCEEDED(IDirect3D9Ex_CreateDeviceEx(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, m, &device))) goto done; + behavior_flags, &present_parameters, m, &device))) + goto done; present_parameters.AutoDepthStencilFormat = D3DFMT_D16; if (SUCCEEDED(IDirect3D9Ex_CreateDeviceEx(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, m, &device))) goto done; + behavior_flags, &present_parameters, m, &device))) + goto done; + + behavior_flags ^= (D3DCREATE_HARDWARE_VERTEXPROCESSING | D3DCREATE_SOFTWARE_VERTEXPROCESSING); if (SUCCEEDED(IDirect3D9Ex_CreateDeviceEx(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_SOFTWARE_VERTEXPROCESSING, &present_parameters, m, &device))) goto done; + behavior_flags, &present_parameters, m, &device))) + goto done; device = NULL; @@ -93,19 +132,27 @@ return device; } -static HRESULT reset_device(IDirect3DDevice9Ex *device, HWND device_window, BOOL windowed) +static HRESULT reset_device(IDirect3DDevice9Ex *device, const struct device_desc *desc) { D3DPRESENT_PARAMETERS present_parameters = {0}; - present_parameters.Windowed = windowed; - present_parameters.hDeviceWindow = device_window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - present_parameters.BackBufferWidth = 1024; - present_parameters.BackBufferHeight = 768; + present_parameters.BackBufferWidth = 640; + present_parameters.BackBufferHeight = 480; present_parameters.BackBufferFormat = D3DFMT_A8R8G8B8; + present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; + present_parameters.hDeviceWindow = NULL; + present_parameters.Windowed = TRUE; present_parameters.EnableAutoDepthStencil = TRUE; present_parameters.AutoDepthStencilFormat = D3DFMT_D24S8; + if (desc) + { + present_parameters.BackBufferWidth = desc->width; + present_parameters.BackBufferHeight = desc->height; + present_parameters.hDeviceWindow = desc->device_window; + present_parameters.Windowed = !(desc->flags & CREATE_DEVICE_FULLSCREEN); + } + return IDirect3DDevice9_Reset(device, &present_parameters); } @@ -333,7 +380,7 @@ window = CreateWindowA("static", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); - if (!(device = create_device(window, window, TRUE))) + if (!(device = create_device(window, NULL))) { skip("Failed to create a D3D device, skipping swapchain GetDisplayModeEx tests.\n"); goto out; @@ -420,8 +467,7 @@ D3DDISPLAYMODE mode; D3DDISPLAYMODEEX mode_ex; D3DDISPLAYROTATION rotation; - HANDLE hdll; - DEVMODEA startmode; + DEVMODEW startmode; LONG retval; hr = pDirect3DCreate9Ex(D3D_SDK_VERSION, &d3d9ex); @@ -447,22 +493,16 @@ hr); ok(d3d9 != NULL && d3d9 != (void *) 0xdeadbeef, "QueryInterface returned interface %p, expected != NULL && != 0xdeadbeef\n", d3d9); - /* change displayorientation*/ - hdll = GetModuleHandleA("user32.dll"); - pEnumDisplaySettingsExA = (void*)GetProcAddress(hdll, "EnumDisplaySettingsExA"); - pChangeDisplaySettingsExA = (void*)GetProcAddress(hdll, "ChangeDisplaySettingsExA"); - - if (!pEnumDisplaySettingsExA || !pChangeDisplaySettingsExA) goto out; memset(&startmode, 0, sizeof(startmode)); startmode.dmSize = sizeof(startmode); - retval = pEnumDisplaySettingsExA(NULL, ENUM_CURRENT_SETTINGS, &startmode, 0); + retval = EnumDisplaySettingsExW(NULL, ENUM_CURRENT_SETTINGS, &startmode, 0); ok(retval, "Failed to retrieve current display mode, retval %d.\n", retval); if (!retval) goto out; startmode.dmFields = DM_DISPLAYORIENTATION | DM_PELSWIDTH | DM_PELSHEIGHT; S2(U1(startmode)).dmDisplayOrientation = DMDO_180; - retval = pChangeDisplaySettingsExA(NULL, &startmode, NULL, 0, NULL); + retval = ChangeDisplaySettingsExW(NULL, &startmode, NULL, 0, NULL); if(retval == DISP_CHANGE_BADMODE) { @@ -474,7 +514,7 @@ /* try retrieve orientation info with EnumDisplaySettingsEx*/ startmode.dmFields = 0; S2(U1(startmode)).dmDisplayOrientation = 0; - ok(pEnumDisplaySettingsExA(NULL, ENUM_CURRENT_SETTINGS, &startmode, EDS_ROTATEDMODE), "EnumDisplaySettingsEx failed\n"); + ok(EnumDisplaySettingsExW(NULL, ENUM_CURRENT_SETTINGS, &startmode, EDS_ROTATEDMODE), "EnumDisplaySettingsEx failed\n"); /*now that orientation has changed start tests for GetAdapterDisplayModeEx: invalid Size*/ memset(&mode_ex, 0, sizeof(mode_ex)); @@ -528,7 +568,7 @@ ok(mode_ex.ScanLineOrdering != 0, "ScanLineOrdering returned 0\n"); /* return to the default mode */ - pChangeDisplaySettingsExA(NULL, NULL, NULL, 0, NULL); + ChangeDisplaySettingsExW(NULL, NULL, NULL, 0, NULL); out: IDirect3D9_Release(d3d9); IDirect3D9Ex_Release(d3d9ex); @@ -551,7 +591,7 @@ D3DCAPS9 caps; window = create_window(); - if (!(device = create_device(window, window, TRUE))) + if (!(device = create_device(window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -681,7 +721,7 @@ UINT mode_count = 0; window = create_window(); - if (!(device = create_device(window, window, TRUE))) + if (!(device = create_device(window, NULL))) { skip("Failed to create a D3D device, skipping test.\n"); DestroyWindow(window); @@ -1049,7 +1089,7 @@ window = CreateWindowA("static", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); - if (!(device = create_device(window, window, TRUE))) + if (!(device = create_device(window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -1078,7 +1118,7 @@ IDirect3DSurface9_Release(surface); } - hr = reset_device(device, window, TRUE); + hr = reset_device(device, NULL); ok(SUCCEEDED(hr), "Failed to reset device.\n"); hr = IDirect3DDevice9_GetBackBuffer(device, 0, 0, D3DBACKBUFFER_TYPE_MONO, &rt); @@ -1115,7 +1155,7 @@ window = CreateWindowA("static", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); - if (!(device = create_device(window, window, TRUE))) + if (!(device = create_device(window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -1162,7 +1202,7 @@ window = CreateWindowA("static", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); - if (!(device = create_device(window, window, TRUE))) + if (!(device = create_device(window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -1201,10 +1241,15 @@ HWND window; HRESULT hr; BOOL ret; + struct device_desc desc; window = CreateWindowA("static", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, NULL, NULL, NULL, NULL); - if (!(device = create_device(window, window, FALSE))) + desc.device_window = window; + desc.width = 640; + desc.height = 480; + desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(window, &desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -1247,7 +1292,9 @@ hr = IDirect3DDevice9Ex_CheckDeviceState(device, NULL); ok(hr == S_PRESENT_OCCLUDED, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, FALSE); + desc.width = 1024; + desc.height = 768; + hr = reset_device(device, &desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice9Ex_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); @@ -1260,7 +1307,8 @@ hr = IDirect3DDevice9Ex_CheckDeviceState(device, NULL); ok(hr == S_PRESENT_OCCLUDED, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, TRUE); + desc.flags = 0; + hr = reset_device(device, &desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice9Ex_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); @@ -1273,7 +1321,7 @@ hr = IDirect3DDevice9Ex_CheckDeviceState(device, NULL); todo_wine ok(hr == S_PRESENT_MODE_CHANGED, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, TRUE); + hr = reset_device(device, &desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice9Ex_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); @@ -1312,7 +1360,8 @@ hr = IDirect3DDevice9Ex_CheckDeviceState(device, NULL); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, FALSE); + desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice9Ex_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); @@ -1331,8 +1380,875 @@ DestroyWindow(window); } +static void test_unsupported_shaders(void) +{ + static const DWORD simple_vs[] = + { + 0xfffe0101, /* vs_1_1 */ + 0x0000001f, 0x80000000, 0x900f0000, /* dcl_position0 v0 */ + 0x00000001, 0xc00f0000, 0x90e40000, /* mov oPos, v0 */ + 0x0000ffff, /* end */ + }; + static const DWORD simple_ps[] = + { + 0xffff0101, /* ps_1_1 */ + 0x00000001, 0x800f0000, 0x90e40000, /* mul r0, t0, r0 */ + 0x0000ffff, /* end */ + }; + static const DWORD vs_3_0[] = + { + 0xfffe0300, /* vs_3_0 */ + 0x0200001f, 0x80000000, 0x900f0000, /* dcl_position v0 */ + 0x0200001f, 0x80000000, 0xe00f0000, /* dcl_position o0 */ + 0x02000001, 0xe00f0000, 0x90e40000, /* mov o0, v0 */ + 0x0000ffff, /* end */ + }; + +#if 0 + float4 main(const float4 color : COLOR) : SV_TARGET + { + float4 o; + + o = color; + + return o; + } +#endif + static const DWORD ps_4_0[] = + { + 0x43425844, 0x4da9446f, 0xfbe1f259, 0x3fdb3009, 0x517521fa, 0x00000001, 0x000001ac, 0x00000005, + 0x00000034, 0x0000008c, 0x000000bc, 0x000000f0, 0x00000130, 0x46454452, 0x00000050, 0x00000000, + 0x00000000, 0x00000000, 0x0000001c, 0xffff0400, 0x00000100, 0x0000001c, 0x7263694d, 0x666f736f, + 0x52282074, 0x4c482029, 0x53204c53, 0x65646168, 0x6f432072, 0x6c69706d, 0x39207265, 0x2e39322e, + 0x2e323539, 0x31313133, 0xababab00, 0x4e475349, 0x00000028, 0x00000001, 0x00000008, 0x00000020, + 0x00000000, 0x00000000, 0x00000003, 0x00000000, 0x00000f0f, 0x4f4c4f43, 0xabab0052, 0x4e47534f, + 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000000, 0x00000003, 0x00000000, + 0x0000000f, 0x545f5653, 0x45475241, 0xabab0054, 0x52444853, 0x00000038, 0x00000040, 0x0000000e, + 0x03001062, 0x001010f2, 0x00000000, 0x03000065, 0x001020f2, 0x00000000, 0x05000036, 0x001020f2, + 0x00000000, 0x00101e46, 0x00000000, 0x0100003e, 0x54415453, 0x00000074, 0x00000002, 0x00000000, + 0x00000000, 0x00000002, 0x00000000, 0x00000000, 0x00000000, 0x00000001, 0x00000000, 0x00000000, + 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00000001, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, + 0x00000000, 0x00000000, 0x00000000, + }; +#if 0 + vs_1_1 + dcl_position v0 + def c255, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c255 + mov oPos, r0 +#endif + static const DWORD vs_1_255[] = + { + 0xfffe0101, + 0x0000001f, 0x80000000, 0x900f0000, + 0x00000051, 0xa00f00ff, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x00000002, 0x800f0000, 0x90e40000, 0xa0e400ff, + 0x00000001, 0xc00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + vs_1_1 + dcl_position v0 + def c256, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c256 + mov oPos, r0 +#endif + static const DWORD vs_1_256[] = + { + 0xfffe0101, + 0x0000001f, 0x80000000, 0x900f0000, + 0x00000051, 0xa00f0100, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x00000002, 0x800f0000, 0x90e40000, 0xa0e40100, + 0x00000001, 0xc00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + vs_3_0 + dcl_position v0 + dcl_position o0 + def c256, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c256 + mov o0, r0 +#endif + static const DWORD vs_3_256[] = + { + 0xfffe0300, + 0x0200001f, 0x80000000, 0x900f0000, + 0x0200001f, 0x80000000, 0xe00f0000, + 0x05000051, 0xa00f0100, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x03000002, 0x800f0000, 0x90e40000, 0xa0e40100, + 0x02000001, 0xe00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + vs_3_0 + dcl_position v0 + dcl_position o0 + defi i16, 1, 1, 1, 1 + rep i16 + add r0, r0, v0 + endrep + mov o0, r0 +#endif + static const DWORD vs_3_i16[] = + { + 0xfffe0300, + 0x0200001f, 0x80000000, 0x900f0000, + 0x0200001f, 0x80000000, 0xe00f0000, + 0x05000030, 0xf00f0010, 0x00000001, 0x00000001, 0x00000001, 0x00000001, + 0x01000026, 0xf0e40010, + 0x03000002, 0x800f0000, 0x80e40000, 0x90e40000, + 0x00000027, + 0x02000001, 0xe00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + vs_3_0 + dcl_position v0 + dcl_position o0 + defb b16, true + mov r0, v0 + if b16 + add r0, r0, v0 + endif + mov o0, r0 +#endif + static const DWORD vs_3_b16[] = + { + 0xfffe0300, + 0x0200001f, 0x80000000, 0x900f0000, + 0x0200001f, 0x80000000, 0xe00f0000, + 0x0200002f, 0xe00f0810, 0x00000001, + 0x02000001, 0x800f0000, 0x90e40000, + 0x01000028, 0xe0e40810, + 0x03000002, 0x800f0000, 0x80e40000, 0x90e40000, + 0x0000002b, + 0x02000001, 0xe00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + ps_1_1 + def c8, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c8 +#endif + static const DWORD ps_1_8[] = + { + 0xffff0101, + 0x00000051, 0xa00f0008, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x00000002, 0x800f0000, 0x90e40000, 0xa0e40008, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + ps_2_0 + def c32, 1.0, 1.0, 1.0, 1.0 + add oC0, v0, c32 +#endif + static const DWORD ps_2_32[] = + { + 0xffff0200, + 0x05000051, 0xa00f0020, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x03000002, 0x800f0000, 0x90e40000, 0xa0e40020, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + ps_3_0 + dcl_color0 v0 + def c224, 1.0, 1.0, 1.0, 1.0 + add oC0, v0, c224 +#endif + static const DWORD ps_3_224[] = + { + 0xffff0300, + 0x0200001f, 0x8000000a, 0x900f0000, + 0x05000051, 0xa00f00e0, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x03000002, 0x800f0800, 0x90e40000, 0xa0e400e0, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + ps_2_0 + defb b0, true + defi i0, 1, 1, 1, 1 + rep i0 + if b0 + add r0, r0, v0 + endif + endrep + mov oC0, r0 +#endif + static const DWORD ps_2_0_boolint[] = + { + 0xffff0200, + 0x0200002f, 0xe00f0800, 0x00000001, + 0x05000030, 0xf00f0000, 0x00000001, 0x00000001, 0x00000001, 0x00000001, + 0x01000026, 0xf0e40000, + 0x01000028, 0xe0e40800, + 0x03000002, 0x800f0000, 0x80e40000, 0x90e40000, + 0x0000002b, + 0x00000027, + 0x02000001, 0x800f0800, 0x80e40000, + 0x0000ffff + }; + + IDirect3DVertexShader9 *vs = NULL; + IDirect3DPixelShader9 *ps = NULL; + IDirect3DDevice9Ex *device; + ULONG refcount; + D3DCAPS9 caps; + HWND window; + HRESULT hr; + + window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, + 0, 0, 640, 480, 0, 0, 0, 0); + if (!(device = create_device(window, NULL))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + DestroyWindow(window); + return; + } + + hr = IDirect3DDevice9Ex_CreateVertexShader(device, simple_ps, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9Ex_CreatePixelShader(device, simple_vs, &ps); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9Ex_CreatePixelShader(device, ps_4_0, &ps); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + + hr = IDirect3DDevice9Ex_GetDeviceCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + + if (caps.VertexShaderVersion < D3DVS_VERSION(3, 0)) + { + hr = IDirect3DDevice9Ex_CreateVertexShader(device, vs_3_0, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + if (caps.VertexShaderVersion <= D3DVS_VERSION(1, 1) && caps.MaxVertexShaderConst < 256) + { + hr = IDirect3DDevice9Ex_CreateVertexShader(device, vs_1_255, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + } + else + { + skip("GPU supports SM2+, skipping SM1 test.\n"); + } + + skip("This GPU doesn't support SM3, skipping test with shader using unsupported constants.\n"); + } + else + { + skip("This GPU supports SM3, skipping unsupported shader test.\n"); + + hr = IDirect3DDevice9Ex_CreateVertexShader(device, vs_1_255, &vs); + ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); + IDirect3DVertexShader9_Release(vs); + hr = IDirect3DDevice9Ex_CreateVertexShader(device, vs_1_256, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9Ex_CreateVertexShader(device, vs_3_256, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9Ex_CreateVertexShader(device, vs_3_i16, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9Ex_CreateVertexShader(device, vs_3_b16, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + } + + if (caps.PixelShaderVersion < D3DPS_VERSION(3, 0)) + { + skip("This GPU doesn't support SM3, skipping test with shader using unsupported constants.\n"); + goto cleanup; + } + hr = IDirect3DDevice9Ex_CreatePixelShader(device, ps_1_8, &ps); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9Ex_CreatePixelShader(device, ps_2_32, &ps); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9Ex_CreatePixelShader(device, ps_3_224, &ps); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9Ex_CreatePixelShader(device, ps_2_0_boolint, &ps); + todo_wine ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + if (ps) + IDirect3DPixelShader9_Release(ps); + +cleanup: + refcount = IDirect3DDevice9Ex_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); + DestroyWindow(window); +} + +static HWND filter_messages; + +enum message_window +{ + DEVICE_WINDOW, + FOCUS_WINDOW, +}; + +struct message +{ + UINT message; + enum message_window window; +}; + +static const struct message *expect_messages; +static HWND device_window, focus_window; + +struct wndproc_thread_param +{ + HWND dummy_window; + HANDLE window_created; + HANDLE test_finished; + BOOL running_in_foreground; +}; + +static LRESULT CALLBACK test_proc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lparam) +{ + if (filter_messages && filter_messages == hwnd) + { + if (message != WM_DISPLAYCHANGE && message != WM_IME_NOTIFY) + todo_wine ok(0, "Received unexpected message %#x for window %p.\n", message, hwnd); + } + + if (expect_messages) + { + HWND w; + + switch (expect_messages->window) + { + case DEVICE_WINDOW: + w = device_window; + break; + + case FOCUS_WINDOW: + w = focus_window; + break; + + default: + w = NULL; + break; + }; + + if (hwnd == w && expect_messages->message == message) + ++expect_messages; + } + + return DefWindowProcA(hwnd, message, wparam, lparam); +} + +static DWORD WINAPI wndproc_thread(void *param) +{ + struct wndproc_thread_param *p = param; + DWORD res; + BOOL ret; + + p->dummy_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); + p->running_in_foreground = SetForegroundWindow(p->dummy_window); + + ret = SetEvent(p->window_created); + ok(ret, "SetEvent failed, last error %#x.\n", GetLastError()); + + for (;;) + { + MSG msg; + + while (PeekMessageA(&msg, 0, 0, 0, PM_REMOVE)) + DispatchMessageA(&msg); + res = WaitForSingleObject(p->test_finished, 100); + if (res == WAIT_OBJECT_0) + break; + if (res != WAIT_TIMEOUT) + { + ok(0, "Wait failed (%#x), last error %#x.\n", res, GetLastError()); + break; + } + } + + DestroyWindow(p->dummy_window); + + return 0; +} + +static void test_wndproc(void) +{ + struct wndproc_thread_param thread_params; + struct device_desc device_desc; + IDirect3DDevice9Ex *device; + WNDCLASSA wc = {0}; + HANDLE thread; + LONG_PTR proc; + ULONG ref; + DWORD res, tid; + HWND tmp; + + static const struct message messages[] = + { + {WM_WINDOWPOSCHANGING, FOCUS_WINDOW}, + {WM_ACTIVATE, FOCUS_WINDOW}, + {WM_SETFOCUS, FOCUS_WINDOW}, + {0, 0}, + }; + + wc.lpfnWndProc = test_proc; + wc.lpszClassName = "d3d9_test_wndproc_wc"; + ok(RegisterClassA(&wc), "Failed to register window class.\n"); + + thread_params.window_created = CreateEventA(NULL, FALSE, FALSE, NULL); + ok(!!thread_params.window_created, "CreateEvent failed, last error %#x.\n", GetLastError()); + thread_params.test_finished = CreateEventA(NULL, FALSE, FALSE, NULL); + ok(!!thread_params.test_finished, "CreateEvent failed, last error %#x.\n", GetLastError()); + + focus_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); + device_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); + thread = CreateThread(NULL, 0, wndproc_thread, &thread_params, 0, &tid); + ok(!!thread, "Failed to create thread, last error %#x.\n", GetLastError()); + + res = WaitForSingleObject(thread_params.window_created, INFINITE); + ok(res == WAIT_OBJECT_0, "Wait failed (%#x), last error %#x.\n", res, GetLastError()); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + trace("device_window %p, focus_window %p, dummy_window %p.\n", + device_window, focus_window, thread_params.dummy_window); + + tmp = GetFocus(); + ok(tmp == device_window, "Expected focus %p, got %p.\n", device_window, tmp); + if (thread_params.running_in_foreground) + { + tmp = GetForegroundWindow(); + ok(tmp == thread_params.dummy_window, "Expected foreground window %p, got %p.\n", + thread_params.dummy_window, tmp); + } + else + skip("Not running in foreground, skip foreground window test\n"); + + flush_events(); + + expect_messages = messages; + + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + goto done; + } + + ok(!expect_messages->message, "Expected message %#x for window %#x, but didn't receive it.\n", + expect_messages->message, expect_messages->window); + expect_messages = NULL; + + if (0) /* Disabled until we can make this work in a reliable way on Wine. */ + { + tmp = GetFocus(); + ok(tmp == focus_window, "Expected focus %p, got %p.\n", focus_window, tmp); + tmp = GetForegroundWindow(); + ok(tmp == focus_window, "Expected foreground window %p, got %p.\n", focus_window, tmp); + } + SetForegroundWindow(focus_window); + flush_events(); + + filter_messages = focus_window; + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); + + ref = IDirect3DDevice9Ex_Release(device); + ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + device_desc.device_window = focus_window; + if (!(device = create_device(focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + goto done; + } + + ref = IDirect3DDevice9Ex_Release(device); + ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); + + device_desc.device_window = device_window; + if (!(device = create_device(focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + goto done; + } + + proc = SetWindowLongPtrA(focus_window, GWLP_WNDPROC, (LONG_PTR)DefWindowProcA); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); + + ref = IDirect3DDevice9Ex_Release(device); + ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)DefWindowProcA, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)DefWindowProcA, proc); + +done: + filter_messages = NULL; + + SetEvent(thread_params.test_finished); + WaitForSingleObject(thread, INFINITE); + CloseHandle(thread_params.test_finished); + CloseHandle(thread_params.window_created); + CloseHandle(thread); + + DestroyWindow(device_window); + DestroyWindow(focus_window); + UnregisterClassA("d3d9_test_wndproc_wc", GetModuleHandleA(NULL)); +} + +static void test_wndproc_windowed(void) +{ + struct wndproc_thread_param thread_params; + struct device_desc device_desc; + IDirect3DDevice9Ex *device; + WNDCLASSA wc = {0}; + HANDLE thread; + LONG_PTR proc; + HRESULT hr; + ULONG ref; + DWORD res, tid; + HWND tmp; + + wc.lpfnWndProc = test_proc; + wc.lpszClassName = "d3d9_test_wndproc_wc"; + ok(RegisterClassA(&wc), "Failed to register window class.\n"); + + thread_params.window_created = CreateEventA(NULL, FALSE, FALSE, NULL); + ok(!!thread_params.window_created, "CreateEvent failed, last error %#x.\n", GetLastError()); + thread_params.test_finished = CreateEventA(NULL, FALSE, FALSE, NULL); + ok(!!thread_params.test_finished, "CreateEvent failed, last error %#x.\n", GetLastError()); + + focus_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); + device_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); + thread = CreateThread(NULL, 0, wndproc_thread, &thread_params, 0, &tid); + ok(!!thread, "Failed to create thread, last error %#x.\n", GetLastError()); + + res = WaitForSingleObject(thread_params.window_created, INFINITE); + ok(res == WAIT_OBJECT_0, "Wait failed (%#x), last error %#x.\n", res, GetLastError()); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + trace("device_window %p, focus_window %p, dummy_window %p.\n", + device_window, focus_window, thread_params.dummy_window); + + tmp = GetFocus(); + ok(tmp == device_window, "Expected focus %p, got %p.\n", device_window, tmp); + if (thread_params.running_in_foreground) + { + tmp = GetForegroundWindow(); + ok(tmp == thread_params.dummy_window, "Expected foreground window %p, got %p.\n", + thread_params.dummy_window, tmp); + } + else + skip("Not running in foreground, skip foreground window test\n"); + + filter_messages = focus_window; + + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = 0; + if (!(device = create_device(focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + goto done; + } + + tmp = GetFocus(); + ok(tmp == device_window, "Expected focus %p, got %p.\n", device_window, tmp); + tmp = GetForegroundWindow(); + ok(tmp == thread_params.dummy_window, "Expected foreground window %p, got %p.\n", + thread_params.dummy_window, tmp); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + filter_messages = NULL; + + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); + ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); + + device_desc.flags = 0; + hr = reset_device(device, &device_desc); + ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + filter_messages = focus_window; + + ref = IDirect3DDevice9Ex_Release(device); + ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); + + filter_messages = device_window; + + device_desc.device_window = focus_window; + if (!(device = create_device(focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + goto done; + } + + filter_messages = NULL; + + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); + ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); + + device_desc.flags = 0; + hr = reset_device(device, &device_desc); + ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + filter_messages = device_window; + + ref = IDirect3DDevice9Ex_Release(device); + ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); + + device_desc.device_window = device_window; + if (!(device = create_device(focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + goto done; + } + + filter_messages = NULL; + + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); + ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); + + device_desc.flags = 0; + hr = reset_device(device, &device_desc); + ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + + proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); + ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", + (LONG_PTR)test_proc, proc); + + filter_messages = device_window; + + ref = IDirect3DDevice9Ex_Release(device); + ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); + +done: + filter_messages = NULL; + + SetEvent(thread_params.test_finished); + WaitForSingleObject(thread, INFINITE); + CloseHandle(thread_params.test_finished); + CloseHandle(thread_params.window_created); + CloseHandle(thread); + + DestroyWindow(device_window); + DestroyWindow(focus_window); + UnregisterClassA("d3d9_test_wndproc_wc", GetModuleHandleA(NULL)); +} + +static void test_window_style(void) +{ + RECT focus_rect, device_rect, fullscreen_rect, r, r2; + LONG device_style, device_exstyle; + LONG focus_style, focus_exstyle; + struct device_desc device_desc; + LONG style; + IDirect3DDevice9Ex *device; + HRESULT hr; + ULONG ref; + static const struct + { + LONG style_flags; + DWORD device_flags; + } + tests[] = + { + {0, 0}, + {WS_VISIBLE, 0}, + {0, CREATE_DEVICE_NOWINDOWCHANGES}, + {WS_VISIBLE, CREATE_DEVICE_NOWINDOWCHANGES}, + }; + unsigned int i; + + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); + + for (i = 0; i < sizeof(tests) / sizeof(*tests); ++i) + { + focus_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW | tests[i].style_flags, + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); + device_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW | tests[i].style_flags, + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); + + device_style = GetWindowLongA(device_window, GWL_STYLE); + device_exstyle = GetWindowLongA(device_window, GWL_EXSTYLE); + focus_style = GetWindowLongA(focus_window, GWL_STYLE); + focus_exstyle = GetWindowLongA(focus_window, GWL_EXSTYLE); + + GetWindowRect(focus_window, &focus_rect); + GetWindowRect(device_window, &device_rect); + + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN | tests[i].device_flags; + if (!(device = create_device(focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + DestroyWindow(device_window); + DestroyWindow(focus_window); + return; + } + + style = GetWindowLongA(device_window, GWL_STYLE); + todo_wine ok(style == device_style, "Expected device window style %#x, got %#x, i=%u.\n", + device_style, style, i); + style = GetWindowLongA(device_window, GWL_EXSTYLE); + todo_wine ok(style == device_exstyle, "Expected device window extended style %#x, got %#x, i=%u.\n", + device_exstyle, style, i); + + style = GetWindowLongA(focus_window, GWL_STYLE); + ok(style == focus_style, "Expected focus window style %#x, got %#x, i=%u.\n", + focus_style, style, i); + style = GetWindowLongA(focus_window, GWL_EXSTYLE); + ok(style == focus_exstyle, "Expected focus window extended style %#x, got %#x, i=%u.\n", + focus_exstyle, style, i); + + GetWindowRect(device_window, &r); + if (tests[i].device_flags & CREATE_DEVICE_NOWINDOWCHANGES) + todo_wine ok(EqualRect(&r, &device_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}, i=%u.\n", + device_rect.left, device_rect.top, device_rect.right, device_rect.bottom, + r.left, r.top, r.right, r.bottom, i); + else + ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}, i=%u.\n", + fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + r.left, r.top, r.right, r.bottom, i); + GetClientRect(device_window, &r2); + todo_wine ok(!EqualRect(&r, &r2), "Client rect and window rect are equal, i=%u.\n", i); + GetWindowRect(focus_window, &r); + ok(EqualRect(&r, &focus_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}, i=%u.\n", + focus_rect.left, focus_rect.top, focus_rect.right, focus_rect.bottom, + r.left, r.top, r.right, r.bottom, i); + + device_desc.flags = 0; + hr = reset_device(device, &device_desc); + ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + + style = GetWindowLongA(device_window, GWL_STYLE); + if (tests[i].style_flags & WS_VISIBLE) + ok(style == device_style, "Expected device window style %#x, got %#x, i=%u.\n", + device_style, style, i); + else + todo_wine ok(style == device_style, "Expected device window style %#x, got %#x, i=%u.\n", + device_style, style, i); + style = GetWindowLongA(device_window, GWL_EXSTYLE); + todo_wine ok(style == device_exstyle, "Expected device window extended style %#x, got %#x, i=%u.\n", + device_exstyle, style, i); + + style = GetWindowLongA(focus_window, GWL_STYLE); + ok(style == focus_style, "Expected focus window style %#x, got %#x, i=%u.\n", + focus_style, style, i); + style = GetWindowLongA(focus_window, GWL_EXSTYLE); + ok(style == focus_exstyle, "Expected focus window extended style %#x, got %#x, i=%u.\n", + focus_exstyle, style, i); + + ref = IDirect3DDevice9Ex_Release(device); + ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); + + DestroyWindow(device_window); + DestroyWindow(focus_window); + } +} + START_TEST(d3d9ex) { + DEVMODEW current_mode; + d3d9_handle = LoadLibraryA("d3d9.dll"); if (!d3d9_handle) { @@ -1346,6 +2262,18 @@ return; } + memset(¤t_mode, 0, sizeof(current_mode)); + current_mode.dmSize = sizeof(current_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, ¤t_mode), "Failed to get display mode.\n"); + registry_mode.dmSize = sizeof(registry_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_REGISTRY_SETTINGS, ®istry_mode), "Failed to get display mode.\n"); + if (current_mode.dmPelsWidth != registry_mode.dmPelsWidth + || current_mode.dmPelsHeight != registry_mode.dmPelsHeight) + { + skip("Current mode does not match registry mode, skipping test.\n"); + return; + } + test_qi_base_to_ex(); test_qi_ex_to_base(); test_swapchain_get_displaymode_ex(); @@ -1357,4 +2285,8 @@ test_vidmem_accounting(); test_user_memory_getdc(); test_lost_device(); + test_unsupported_shaders(); + test_wndproc(); + test_wndproc_windowed(); + test_window_style(); } diff -Nru wine1.7-1.7.28/dlls/d3d9/tests/device.c wine1.7-1.7.31/dlls/d3d9/tests/device.c --- wine1.7-1.7.28/dlls/d3d9/tests/device.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d9/tests/device.c 2014-11-14 13:28:17.000000000 +0000 @@ -31,11 +31,23 @@ float x, y, z; }; +#define CREATE_DEVICE_FULLSCREEN 0x01 +#define CREATE_DEVICE_NOWINDOWCHANGES 0x02 +#define CREATE_DEVICE_FPU_PRESERVE 0x04 +#define CREATE_DEVICE_SWVP_ONLY 0x08 + +struct device_desc +{ + HWND device_window; + unsigned int width; + unsigned int height; + DWORD flags; +}; + #define GET_X_LPARAM(lp) ((int)(short)LOWORD(lp)) #define GET_Y_LPARAM(lp) ((int)(short)HIWORD(lp)) -static INT screen_width; -static INT screen_height; +static DEVMODEW registry_mode; static const DWORD simple_vs[] = { @@ -117,46 +129,76 @@ } } -static IDirect3DDevice9 *create_device(IDirect3D9 *d3d9, HWND device_window, HWND focus_window, BOOL windowed) +static IDirect3DDevice9 *create_device(IDirect3D9 *d3d9, HWND focus_window, const struct device_desc *desc) { D3DPRESENT_PARAMETERS present_parameters = {0}; IDirect3DDevice9 *device; + DWORD behavior_flags = D3DCREATE_HARDWARE_VERTEXPROCESSING; - present_parameters.Windowed = windowed; - present_parameters.hDeviceWindow = device_window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - present_parameters.BackBufferWidth = screen_width; - present_parameters.BackBufferHeight = screen_height; + present_parameters.BackBufferWidth = 640; + present_parameters.BackBufferHeight = 480; present_parameters.BackBufferFormat = D3DFMT_A8R8G8B8; + present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; + present_parameters.hDeviceWindow = focus_window; + present_parameters.Windowed = TRUE; present_parameters.EnableAutoDepthStencil = TRUE; present_parameters.AutoDepthStencilFormat = D3DFMT_D24S8; + if (desc) + { + present_parameters.BackBufferWidth = desc->width; + present_parameters.BackBufferHeight = desc->height; + present_parameters.hDeviceWindow = desc->device_window; + present_parameters.Windowed = !(desc->flags & CREATE_DEVICE_FULLSCREEN); + if (desc->flags & CREATE_DEVICE_SWVP_ONLY) + behavior_flags = D3DCREATE_SOFTWARE_VERTEXPROCESSING; + if (desc->flags & CREATE_DEVICE_NOWINDOWCHANGES) + behavior_flags |= D3DCREATE_NOWINDOWCHANGES; + if (desc->flags & CREATE_DEVICE_FPU_PRESERVE) + behavior_flags |= D3DCREATE_FPU_PRESERVE; + } + if (SUCCEEDED(IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, &device))) return device; + behavior_flags, &present_parameters, &device))) + return device; present_parameters.AutoDepthStencilFormat = D3DFMT_D16; if (SUCCEEDED(IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, &device))) return device; + behavior_flags, &present_parameters, &device))) + return device; + + if (desc && desc->flags & CREATE_DEVICE_SWVP_ONLY) + return NULL; + behavior_flags ^= (D3DCREATE_HARDWARE_VERTEXPROCESSING | D3DCREATE_SOFTWARE_VERTEXPROCESSING); if (SUCCEEDED(IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window, - D3DCREATE_SOFTWARE_VERTEXPROCESSING, &present_parameters, &device))) return device; + behavior_flags, &present_parameters, &device))) + return device; return NULL; } -static HRESULT reset_device(IDirect3DDevice9 *device, HWND device_window, BOOL windowed) +static HRESULT reset_device(IDirect3DDevice9 *device, const struct device_desc *desc) { D3DPRESENT_PARAMETERS present_parameters = {0}; - present_parameters.Windowed = windowed; - present_parameters.hDeviceWindow = device_window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - present_parameters.BackBufferWidth = screen_width; - present_parameters.BackBufferHeight = screen_height; + present_parameters.BackBufferWidth = 640; + present_parameters.BackBufferHeight = 480; present_parameters.BackBufferFormat = D3DFMT_A8R8G8B8; + present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; + present_parameters.hDeviceWindow = NULL; + present_parameters.Windowed = TRUE; present_parameters.EnableAutoDepthStencil = TRUE; present_parameters.AutoDepthStencilFormat = D3DFMT_D24S8; + if (desc) + { + present_parameters.BackBufferWidth = desc->width; + present_parameters.BackBufferHeight = desc->height; + present_parameters.hDeviceWindow = desc->device_window; + present_parameters.Windowed = !(desc->flags & CREATE_DEVICE_FULLSCREEN); + } + return IDirect3DDevice9_Reset(device, &present_parameters); } @@ -226,7 +268,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -281,7 +323,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -600,7 +642,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -702,7 +744,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -820,7 +862,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -894,7 +936,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -940,7 +982,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -972,7 +1014,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -1024,7 +1066,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -1183,7 +1225,7 @@ CHECK_REFCOUNT(d3d, 1); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -1504,7 +1546,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2155,7 +2197,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2279,7 +2321,7 @@ ok(!!window, "Failed to create a window.\n"); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2496,7 +2538,7 @@ 0, 0, 128, 128, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - device = create_device(d3d9, window, window, TRUE); + device = create_device(d3d9, window, NULL); if (!device) { skip("Failed to create a D3D device, skipping tests.\n"); @@ -2562,7 +2604,7 @@ ok(!!window, "Failed to create a window.\n"); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2662,7 +2704,7 @@ ok(!!window, "Failed to create a window.\n"); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2735,7 +2777,7 @@ ok(!!window, "Failed to create a window.\n"); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2788,7 +2830,7 @@ ok(!!window, "Failed to create a window.\n"); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a 3D device, skipping test.\n"); goto cleanup; @@ -2922,15 +2964,16 @@ static void test_scissor_size(void) { + struct device_desc device_desc; IDirect3D9 *d3d9_ptr; unsigned int i; static struct { - int winx; int winy; int backx; int backy; BOOL window; + int winx; int winy; int backx; int backy; DWORD flags; } scts[] = { /* scissor tests */ - {800, 600, 640, 480, TRUE}, - {800, 600, 640, 480, FALSE}, - {640, 480, 800, 600, TRUE}, - {640, 480, 800, 600, FALSE}, + {800, 600, 640, 480, 0}, + {800, 600, 640, 480, CREATE_DEVICE_FULLSCREEN}, + {640, 480, 800, 600, 0}, + {640, 480, 800, 600, CREATE_DEVICE_FULLSCREEN}, }; d3d9_ptr = Direct3DCreate9(D3D_SDK_VERSION); @@ -2938,7 +2981,6 @@ for(i=0; idummy_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); p->running_in_foreground = SetForegroundWindow(p->dummy_window); ret = SetEvent(p->window_created); @@ -3139,6 +3173,7 @@ static void test_wndproc(void) { struct wndproc_thread_param thread_params; + struct device_desc device_desc; IDirect3DDevice9 *device; WNDCLASSA wc = {0}; IDirect3D9 *d3d9; @@ -3169,9 +3204,11 @@ ok(!!thread_params.test_finished, "CreateEvent failed, last error %#x.\n", GetLastError()); focus_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); device_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); thread = CreateThread(NULL, 0, wndproc_thread, &thread_params, 0, &tid); ok(!!thread, "Failed to create thread, last error %#x.\n", GetLastError()); @@ -3203,8 +3240,11 @@ expect_messages = messages; - device = create_device(d3d9, device_window, focus_window, FALSE); - if (!device) + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d9, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3231,8 +3271,7 @@ (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); ref = IDirect3DDevice9_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); @@ -3241,8 +3280,8 @@ ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", (LONG_PTR)test_proc, proc); - device = create_device(d3d9, focus_window, focus_window, FALSE); - if (!device) + device_desc.device_window = focus_window; + if (!(device = create_device(d3d9, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3251,16 +3290,15 @@ ref = IDirect3DDevice9_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); - device = create_device(d3d9, device_window, focus_window, FALSE); - if (!device) + device_desc.device_window = device_window; + if (!(device = create_device(d3d9, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; } proc = SetWindowLongPtrA(focus_window, GWLP_WNDPROC, (LONG_PTR)DefWindowProcA); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); ref = IDirect3DDevice9_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); @@ -3287,6 +3325,7 @@ static void test_wndproc_windowed(void) { struct wndproc_thread_param thread_params; + struct device_desc device_desc; IDirect3DDevice9 *device; WNDCLASSA wc = {0}; IDirect3D9 *d3d9; @@ -3310,9 +3349,11 @@ ok(!!thread_params.test_finished, "CreateEvent failed, last error %#x.\n", GetLastError()); focus_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); device_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", - WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + WS_MAXIMIZE | WS_VISIBLE | WS_CAPTION, 0, 0, registry_mode.dmPelsWidth, + registry_mode.dmPelsHeight, 0, 0, 0, 0); thread = CreateThread(NULL, 0, wndproc_thread, &thread_params, 0, &tid); ok(!!thread, "Failed to create thread, last error %#x.\n", GetLastError()); @@ -3342,8 +3383,11 @@ filter_messages = focus_window; - device = create_device(d3d9, device_window, focus_window, TRUE); - if (!device) + device_desc.device_window = device_window; + device_desc.width = 640; + device_desc.height = 480; + device_desc.flags = 0; + if (!(device = create_device(d3d9, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3365,7 +3409,10 @@ filter_messages = NULL; - hr = reset_device(device, device_window, FALSE); + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -3373,10 +3420,10 @@ (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); - hr = reset_device(device, device_window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -3394,8 +3441,8 @@ filter_messages = device_window; - device = create_device(d3d9, focus_window, focus_window, TRUE); - if (!device) + device_desc.device_window = focus_window; + if (!(device = create_device(d3d9, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3403,7 +3450,8 @@ filter_messages = NULL; - hr = reset_device(device, focus_window, FALSE); + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -3411,10 +3459,10 @@ (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); - hr = reset_device(device, focus_window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -3430,8 +3478,8 @@ ref = IDirect3DDevice9_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); - device = create_device(d3d9, device_window, focus_window, TRUE); - if (!device) + device_desc.device_window = device_window; + if (!(device = create_device(d3d9, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3439,7 +3487,9 @@ filter_messages = NULL; - hr = reset_device(device, device_window, FALSE); + device_desc.device_window = device_window; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -3447,10 +3497,10 @@ (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); - hr = reset_device(device, device_window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -3487,6 +3537,7 @@ IDirect3DDevice9 *device = NULL; IDirect3D9 *d3d; ATOM atom; + struct device_desc device_desc; static const struct message messages[] = { {WM_ACTIVATEAPP, FOCUS_WINDOW}, @@ -3505,7 +3556,7 @@ ok(atom, "Failed to register a new window class. GetLastError:%d\n", GetLastError()); device_window = focus_window = CreateWindowExA(0, wc.lpszClassName, "Test Reset Fullscreen", 0, - 0, 0, screen_width, screen_height, NULL, NULL, NULL, NULL); + 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, NULL, NULL, NULL, NULL); ok(device_window != NULL, "Failed to create a window. GetLastError:%d\n", GetLastError()); /* @@ -3514,8 +3565,7 @@ * could show the window (such as ShowWindow or SetWindowPos) yet, * WM_ACTIVATEAPP will not have been sent. */ - device = create_device(d3d, device_window, focus_window, TRUE); - if (!device) + if (!(device = create_device(d3d, device_window, NULL))) { skip("Unable to create device. Skipping test.\n"); goto cleanup; @@ -3526,7 +3576,11 @@ * This will force the window to be shown and will cause the WM_ACTIVATEAPP * message to be sent. */ - ok(SUCCEEDED(reset_device(device, device_window, FALSE)), "Failed to reset device.\n"); + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.device_window = device_window; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + ok(SUCCEEDED(reset_device(device, &device_desc)), "Failed to reset device.\n"); flush_events(); ok(expect_messages->message == 0, "Expected to receive message %#x.\n", expect_messages->message); @@ -3570,32 +3624,30 @@ static void test_fpu_setup(void) { #if defined(D3D9_TEST_SET_FPU_CW) && defined(D3D9_TEST_GET_FPU_CW) - D3DPRESENT_PARAMETERS present_parameters; + struct device_desc device_desc; IDirect3DDevice9 *device; HWND window = NULL; IDirect3D9 *d3d9; - HRESULT hr; WORD cw; - window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_CAPTION, 0, 0, screen_width, screen_height, 0, 0, 0, 0); + window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_CAPTION, 0, 0, + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, 0, 0, 0, 0); ok(!!window, "Failed to create a window.\n"); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - memset(&present_parameters, 0, sizeof(present_parameters)); - present_parameters.Windowed = TRUE; - present_parameters.hDeviceWindow = window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; + device_desc.device_window = window; + device_desc.width = 640; + device_desc.height = 480; + device_desc.flags = 0; set_fpu_cw(0xf60); cw = get_fpu_cw(); ok(cw == 0xf60, "cw is %#x, expected 0xf60.\n", cw); - hr = IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, window, - D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, &device); - if (FAILED(hr)) + if (!(device = create_device(d3d9, window, &device_desc))) { - skip("Failed to create a device, hr %#x.\n", hr); + skip("Failed to create a 3D device, skipping test.\n"); set_fpu_cw(0x37f); goto done; } @@ -3611,9 +3663,9 @@ cw = get_fpu_cw(); ok(cw == 0xf60, "cw is %#x, expected 0xf60.\n", cw); - hr = IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, window, - D3DCREATE_HARDWARE_VERTEXPROCESSING | D3DCREATE_FPU_PRESERVE, &present_parameters, &device); - ok(SUCCEEDED(hr), "CreateDevice failed, hr %#x.\n", hr); + device_desc.flags = CREATE_DEVICE_FPU_PRESERVE; + device = create_device(d3d9, window, &device_desc); + ok(device != NULL, "CreateDevice failed.\n"); cw = get_fpu_cw(); ok(cw == 0xf60, "cw is %#x, expected 0xf60.\n", cw); @@ -3629,91 +3681,125 @@ static void test_window_style(void) { - RECT focus_rect, fullscreen_rect, r; + RECT focus_rect, device_rect, fullscreen_rect, r, r2; LONG device_style, device_exstyle; LONG focus_style, focus_exstyle; + struct device_desc device_desc; LONG style, expected_style; IDirect3DDevice9 *device; IDirect3D9 *d3d9; HRESULT hr; ULONG ref; + static const struct + { + DWORD device_flags; + LONG style, exstyle; + } + tests[] = + { + {0, WS_VISIBLE, WS_EX_TOPMOST}, + {CREATE_DEVICE_NOWINDOWCHANGES, 0}, + }; + unsigned int i; - focus_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); - device_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); - device_style = GetWindowLongA(device_window, GWL_STYLE); - device_exstyle = GetWindowLongA(device_window, GWL_EXSTYLE); - focus_style = GetWindowLongA(focus_window, GWL_STYLE); - focus_exstyle = GetWindowLongA(focus_window, GWL_EXSTYLE); - - SetRect(&fullscreen_rect, 0, 0, screen_width, screen_height); - GetWindowRect(focus_window, &focus_rect); - - device = create_device(d3d9, device_window, focus_window, FALSE); - if (!device) + for (i = 0; i < sizeof(tests) / sizeof(*tests); ++i) { - skip("Failed to create a D3D device, skipping tests.\n"); - goto done; - } - - style = GetWindowLongA(device_window, GWL_STYLE); - expected_style = device_style | WS_VISIBLE; - todo_wine ok(style == expected_style, "Expected device window style %#x, got %#x.\n", - expected_style, style); - style = GetWindowLongA(device_window, GWL_EXSTYLE); - expected_style = device_exstyle | WS_EX_TOPMOST; - todo_wine ok(style == expected_style, "Expected device window extended style %#x, got %#x.\n", - expected_style, style); - - style = GetWindowLongA(focus_window, GWL_STYLE); - ok(style == focus_style, "Expected focus window style %#x, got %#x.\n", - focus_style, style); - style = GetWindowLongA(focus_window, GWL_EXSTYLE); - ok(style == focus_exstyle, "Expected focus window extended style %#x, got %#x.\n", - focus_exstyle, style); - - GetWindowRect(device_window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, - r.left, r.top, r.right, r.bottom); - GetClientRect(device_window, &r); - todo_wine ok(!EqualRect(&r, &fullscreen_rect), "Client rect and window rect are equal.\n"); - GetWindowRect(focus_window, &r); - ok(EqualRect(&r, &focus_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - focus_rect.left, focus_rect.top, focus_rect.right, focus_rect.bottom, - r.left, r.top, r.right, r.bottom); + focus_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); + device_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); + + device_style = GetWindowLongA(device_window, GWL_STYLE); + device_exstyle = GetWindowLongA(device_window, GWL_EXSTYLE); + focus_style = GetWindowLongA(focus_window, GWL_STYLE); + focus_exstyle = GetWindowLongA(focus_window, GWL_EXSTYLE); + + GetWindowRect(focus_window, &focus_rect); + GetWindowRect(device_window, &device_rect); + + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN | tests[i].device_flags; + if (!(device = create_device(d3d9, focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + DestroyWindow(device_window); + DestroyWindow(focus_window); + break; + } - hr = reset_device(device, device_window, TRUE); - ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + style = GetWindowLongA(device_window, GWL_STYLE); + expected_style = device_style | tests[i].style; + todo_wine ok(style == expected_style, "Expected device window style %#x, got %#x, i=%u.\n", + expected_style, style, i); + style = GetWindowLongA(device_window, GWL_EXSTYLE); + expected_style = device_exstyle | tests[i].exstyle; + todo_wine ok(style == expected_style, "Expected device window extended style %#x, got %#x, i=%u.\n", + expected_style, style, i); + + style = GetWindowLongA(focus_window, GWL_STYLE); + ok(style == focus_style, "Expected focus window style %#x, got %#x, i=%u.\n", + focus_style, style, i); + style = GetWindowLongA(focus_window, GWL_EXSTYLE); + ok(style == focus_exstyle, "Expected focus window extended style %#x, got %#x, i=%u.\n", + focus_exstyle, style, i); + + GetWindowRect(device_window, &r); + if (tests[i].device_flags & CREATE_DEVICE_NOWINDOWCHANGES) + todo_wine ok(EqualRect(&r, &device_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}, i=%u.\n", + device_rect.left, device_rect.top, device_rect.right, device_rect.bottom, + r.left, r.top, r.right, r.bottom, i); + else + ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}, i=%u.\n", + fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + r.left, r.top, r.right, r.bottom, i); + GetClientRect(device_window, &r2); + todo_wine ok(!EqualRect(&r, &r2), "Client rect and window rect are equal.\n"); + GetWindowRect(focus_window, &r); + ok(EqualRect(&r, &focus_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}, i=%u.\n", + focus_rect.left, focus_rect.top, focus_rect.right, focus_rect.bottom, + r.left, r.top, r.right, r.bottom, i); + + device_desc.flags = 0; + hr = reset_device(device, &device_desc); + ok(SUCCEEDED(hr), "Failed to reset device, hr %#x.\n", hr); + + style = GetWindowLongA(device_window, GWL_STYLE); + expected_style = device_style | tests[i].style; + if (tests[i].device_flags & CREATE_DEVICE_NOWINDOWCHANGES) + todo_wine ok(style == expected_style, "Expected device window style %#x, got %#x, i=%u.\n", + expected_style, style, i); + else + ok(style == expected_style, "Expected device window style %#x, got %#x, i=%u.\n", + expected_style, style, i); + style = GetWindowLongA(device_window, GWL_EXSTYLE); + expected_style = device_exstyle | tests[i].exstyle; + if (tests[i].device_flags & CREATE_DEVICE_NOWINDOWCHANGES) + todo_wine ok(style == expected_style, "Expected device window extended style %#x, got %#x, i=%u.\n", + expected_style, style, i); + else + ok(style == expected_style, "Expected device window extended style %#x, got %#x, i=%u.\n", + expected_style, style, i); - style = GetWindowLongA(device_window, GWL_STYLE); - expected_style = device_style | WS_VISIBLE; - ok(style == expected_style, "Expected device window style %#x, got %#x.\n", - expected_style, style); - style = GetWindowLongA(device_window, GWL_EXSTYLE); - expected_style = device_exstyle | WS_EX_TOPMOST; - ok(style == expected_style, "Expected device window extended style %#x, got %#x.\n", - expected_style, style); - - style = GetWindowLongA(focus_window, GWL_STYLE); - ok(style == focus_style, "Expected focus window style %#x, got %#x.\n", - focus_style, style); - style = GetWindowLongA(focus_window, GWL_EXSTYLE); - ok(style == focus_exstyle, "Expected focus window extended style %#x, got %#x.\n", - focus_exstyle, style); + style = GetWindowLongA(focus_window, GWL_STYLE); + ok(style == focus_style, "Expected focus window style %#x, got %#x, i=%u.\n", + focus_style, style, i); + style = GetWindowLongA(focus_window, GWL_EXSTYLE); + ok(style == focus_exstyle, "Expected focus window extended style %#x, got %#x, i=%u.\n", + focus_exstyle, style, i); - ref = IDirect3DDevice9_Release(device); - ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); + ref = IDirect3DDevice9_Release(device); + ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); -done: + DestroyWindow(device_window); + DestroyWindow(focus_window); + } IDirect3D9_Release(d3d9); - - DestroyWindow(device_window); - DestroyWindow(focus_window); } static const POINT *expect_pos; @@ -3771,7 +3857,7 @@ d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - device = create_device(d3d9, window, window, TRUE); + device = create_device(d3d9, window, NULL); if (!device) { skip("Failed to create a D3D device, skipping tests.\n"); @@ -3835,52 +3921,115 @@ static void test_mode_change(void) { - RECT fullscreen_rect, focus_rect, r; + RECT d3d_rect, focus_rect, r; + struct device_desc device_desc; IDirect3DSurface9 *backbuffer; IDirect3DDevice9 *device; D3DSURFACE_DESC desc; IDirect3D9 *d3d9; DEVMODEW devmode; - UINT refcount; + ULONG refcount; + UINT adapter_mode_count, i; HRESULT hr; DWORD ret; + LONG change_ret; + D3DDISPLAYMODE d3ddm; + DWORD d3d_width = 0, d3d_height = 0, user32_width = 0, user32_height = 0; - focus_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); - device_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - SetRect(&fullscreen_rect, 0, 0, screen_width, screen_height); - GetWindowRect(focus_window, &focus_rect); + adapter_mode_count = IDirect3D9_GetAdapterModeCount(d3d9, D3DADAPTER_DEFAULT, D3DFMT_X8R8G8B8); + for (i = 0; i < adapter_mode_count; ++i) + { + hr = IDirect3D9_EnumAdapterModes(d3d9, D3DADAPTER_DEFAULT, D3DFMT_X8R8G8B8, i, &d3ddm); + ok(SUCCEEDED(hr), "Failed to enumerate display mode, hr %#x.\n", hr); - device = create_device(d3d9, device_window, focus_window, FALSE); - if (!device) + if (d3ddm.Width == registry_mode.dmPelsWidth && d3ddm.Height == registry_mode.dmPelsHeight) + continue; + /* The r200 driver on Windows XP enumerates modes like 320x200 and 320x240 but + * refuses to create a device at these sizes. */ + if (d3ddm.Width < 640 || d3ddm.Height < 480) + continue; + + if (!user32_width) + { + user32_width = d3ddm.Width; + user32_height = d3ddm.Height; + continue; + } + + /* Make sure the d3d mode is smaller in width or height and at most + * equal in the other dimension than the mode passed to + * ChangeDisplaySettings. Otherwise Windows shrinks the window to + * the ChangeDisplaySettings parameters + 12. */ + if (d3ddm.Width == user32_width && d3ddm.Height == user32_height) + continue; + if (d3ddm.Width <= user32_width && d3ddm.Height <= user32_height) + { + d3d_width = d3ddm.Width; + d3d_height = d3ddm.Height; + break; + } + if (user32_width <= d3ddm.Width && user32_height <= d3ddm.Height) + { + d3d_width = user32_width; + d3d_height = user32_height; + user32_width = d3ddm.Width; + user32_height = d3ddm.Height; + break; + } + } + + if (!d3d_width) { - skip("Failed to create a D3D device, skipping tests.\n"); - goto done; + skip("Could not find adequate modes, skipping mode tests.\n"); + IDirect3D9_Release(d3d9); + return; } memset(&devmode, 0, sizeof(devmode)); devmode.dmSize = sizeof(devmode); devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; - devmode.dmPelsWidth = 640; - devmode.dmPelsHeight = 480; + devmode.dmPelsWidth = user32_width; + devmode.dmPelsHeight = user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); - ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); - ok(ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", ret); + focus_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, + 0, 0, user32_width / 2, user32_height / 2, 0, 0, 0, 0); + device_window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, + 0, 0, user32_width / 2, user32_height / 2, 0, 0, 0, 0); + + SetRect(&d3d_rect, 0, 0, d3d_width, d3d_height); + GetWindowRect(focus_window, &focus_rect); + + device_desc.device_window = device_window; + device_desc.width = d3d_width; + device_desc.height = d3d_height; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d9, focus_window, &device_desc))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + goto done; + } + + devmode.dmPelsWidth = user32_width; + devmode.dmPelsHeight = user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); - memset(&devmode, 0, sizeof(devmode)); - devmode.dmSize = sizeof(devmode); ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); ok(ret, "Failed to get display mode.\n"); - ok(devmode.dmPelsWidth == 640, "Got unexpect width %u.\n", devmode.dmPelsWidth); - ok(devmode.dmPelsHeight == 480, "Got unexpect height %u.\n", devmode.dmPelsHeight); + ok(devmode.dmPelsWidth == user32_width && devmode.dmPelsHeight == user32_height, + "Expected resolution %ux%u, got %ux%u.\n", + user32_width, user32_height, devmode.dmPelsWidth, devmode.dmPelsHeight); GetWindowRect(device_window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &d3d_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + d3d_rect.left, d3d_rect.top, d3d_rect.right, d3d_rect.bottom, r.left, r.top, r.right, r.bottom); GetWindowRect(focus_window, &r); ok(EqualRect(&r, &focus_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", @@ -3891,36 +4040,58 @@ ok(SUCCEEDED(hr), "Failed to get backbuffer, hr %#x.\n", hr); hr = IDirect3DSurface9_GetDesc(backbuffer, &desc); ok(SUCCEEDED(hr), "Failed to get backbuffer desc, hr %#x.\n", hr); - ok(desc.Width == screen_width, "Got unexpected backbuffer width %u.\n", desc.Width); - ok(desc.Height == screen_height, "Got unexpected backbuffer height %u.\n", desc.Height); + ok(desc.Width == d3d_width, "Got unexpected backbuffer width %u, expected %u.\n", + desc.Width, d3d_width); + ok(desc.Height == d3d_height, "Got unexpected backbuffer height %u, expected %u.\n", + desc.Height, d3d_height); IDirect3DSurface9_Release(backbuffer); refcount = IDirect3DDevice9_Release(device); ok(!refcount, "Device has %u references left.\n", refcount); - memset(&devmode, 0, sizeof(devmode)); - devmode.dmSize = sizeof(devmode); ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); ok(ret, "Failed to get display mode.\n"); - ok(devmode.dmPelsWidth == screen_width, "Got unexpect width %u.\n", devmode.dmPelsWidth); - ok(devmode.dmPelsHeight == screen_height, "Got unexpect height %u.\n", devmode.dmPelsHeight); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, devmode.dmPelsWidth, devmode.dmPelsHeight); + + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + /* The mode restore also happens when the device was created at the original screen size. */ + + device_desc.device_window = device_window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + ok(!!(device = create_device(d3d9, focus_window, &device_desc)), "Failed to create a D3D device.\n"); + + devmode.dmPelsWidth = user32_width; + devmode.dmPelsHeight = user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + refcount = IDirect3DDevice9_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); + + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, devmode.dmPelsWidth, devmode.dmPelsHeight); done: DestroyWindow(device_window); DestroyWindow(focus_window); IDirect3D9_Release(d3d9); - - memset(&devmode, 0, sizeof(devmode)); - devmode.dmSize = sizeof(devmode); - ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); - ok(ret, "Failed to get display mode.\n"); - ok(devmode.dmPelsWidth == screen_width, "Got unexpect width %u.\n", devmode.dmPelsWidth); - ok(devmode.dmPelsHeight == screen_height, "Got unexpect height %u.\n", devmode.dmPelsHeight); } static void test_device_window_reset(void) { RECT fullscreen_rect, device_rect, r; + struct device_desc device_desc; IDirect3DDevice9 *device; WNDCLASSA wc = {0}; IDirect3D9 *d3d9; @@ -3933,13 +4104,13 @@ ok(RegisterClassA(&wc), "Failed to register window class.\n"); focus_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); device_window = CreateWindowA("d3d9_test_wndproc_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, - 0, 0, screen_width / 2, screen_height / 2, 0, 0, 0, 0); + 0, 0, registry_mode.dmPelsWidth / 2, registry_mode.dmPelsHeight / 2, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - SetRect(&fullscreen_rect, 0, 0, screen_width, screen_height); + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); GetWindowRect(device_window, &device_rect); proc = GetWindowLongPtrA(device_window, GWLP_WNDPROC); @@ -3949,8 +4120,11 @@ ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", (LONG_PTR)test_proc, proc); - device = create_device(d3d9, NULL, focus_window, FALSE); - if (!device) + device_desc.device_window = NULL; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d9, focus_window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -3969,10 +4143,10 @@ ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); - hr = reset_device(device, device_window, FALSE); + device_desc.device_window = device_window; + hr = reset_device(device, &device_desc); ok(SUCCEEDED(hr), "Failed to reset device.\n"); GetWindowRect(focus_window, &r); @@ -3988,8 +4162,7 @@ ok(proc == (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", (LONG_PTR)test_proc, proc); proc = GetWindowLongPtrA(focus_window, GWLP_WNDPROC); - ok(proc != (LONG_PTR)test_proc, "Expected wndproc %#lx, got %#lx.\n", - (LONG_PTR)test_proc, proc); + ok(proc != (LONG_PTR)test_proc, "Expected wndproc != %#lx.\n", (LONG_PTR)test_proc); ref = IDirect3DDevice9_Release(device); ok(ref == 0, "The device was not properly freed: refcount %u.\n", ref); @@ -4018,7 +4191,7 @@ d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -4047,7 +4220,7 @@ IDirect3DSurface9_Release(surface); } - hr = reset_device(device, device_window, TRUE); + hr = reset_device(device, NULL); ok(SUCCEEDED(hr), "Failed to reset device.\n"); hr = IDirect3DDevice9_GetBackBuffer(device, 0, 0, D3DBACKBUFFER_TYPE_MONO, &rt); @@ -4088,7 +4261,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); DestroyWindow(window); @@ -4103,14 +4276,14 @@ ok(SUCCEEDED(hr), "Failed to get viewport, hr %#x.\n", hr); ok(!vp.X, "Got unexpected vp.X %u.\n", vp.X); ok(!vp.Y, "Got unexpected vp.Y %u.\n", vp.Y); - ok(vp.Width == screen_width, "Got unexpected vp.Width %u.\n", vp.Width); - ok(vp.Height == screen_height, "Got unexpected vp.Height %u.\n", vp.Height); + ok(vp.Width == 640, "Got unexpected vp.Width %u.\n", vp.Width); + ok(vp.Height == 480, "Got unexpected vp.Height %u.\n", vp.Height); ok(vp.MinZ == 0.0f, "Got unexpected vp.MinZ %.8e.\n", vp.MinZ); ok(vp.MaxZ == 1.0f, "Got unexpected vp.MaxZ %.8e.\n", vp.MaxZ); hr = IDirect3DDevice9_GetScissorRect(device, &rect); ok(SUCCEEDED(hr), "Failed to get scissor rect, hr %#x.\n", hr); - ok(rect.left == 0 && rect.top == 0 && rect.right == screen_width && rect.bottom == screen_height, + ok(rect.left == 0 && rect.top == 0 && rect.right == 640 && rect.bottom == 480, "Got unexpected scissor rect {%d, %d, %d, %d}.\n", rect.left, rect.top, rect.right, rect.bottom); @@ -4196,7 +4369,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -4278,7 +4451,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -4346,7 +4519,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -4416,7 +4589,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -4486,7 +4659,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -4529,6 +4702,7 @@ 1.0f, 1.0f, 0.0f, 1.0f, -1.0f, 0.0f, }; + struct device_desc device_desc; IDirect3DQuery9 *query = NULL; unsigned int data_size, i; IDirect3DDevice9 *device; @@ -4542,13 +4716,17 @@ DWORD dword[2]; } data; BOOL broken_occlusion = FALSE; - DWORD expected = screen_width * screen_height; + DWORD expected = registry_mode.dmPelsWidth * registry_mode.dmPelsHeight; window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE, 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, FALSE))) + device_desc.device_window = window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d9, window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -4700,7 +4878,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -4863,7 +5041,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -4925,7 +5103,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -4985,7 +5163,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5047,7 +5225,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5090,7 +5268,7 @@ DestroyWindow(window); } -static void test_wrong_shader(void) +static void test_unsupported_shaders(void) { static const DWORD vs_3_0[] = { @@ -5128,6 +5306,182 @@ 0x00000000, 0x00000001, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, }; +#if 0 + vs_1_1 + dcl_position v0 + def c255, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c255 + mov oPos, r0 +#endif + static const DWORD vs_1_255[] = + { + 0xfffe0101, + 0x0000001f, 0x80000000, 0x900f0000, + 0x00000051, 0xa00f00ff, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x00000002, 0x800f0000, 0x90e40000, 0xa0e400ff, + 0x00000001, 0xc00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + vs_1_1 + dcl_position v0 + def c256, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c256 + mov oPos, r0 +#endif + static const DWORD vs_1_256[] = + { + 0xfffe0101, + 0x0000001f, 0x80000000, 0x900f0000, + 0x00000051, 0xa00f0100, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x00000002, 0x800f0000, 0x90e40000, 0xa0e40100, + 0x00000001, 0xc00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + vs_3_0 + dcl_position v0 + dcl_position o0 + def c256, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c256 + mov o0, r0 +#endif + static const DWORD vs_3_256[] = + { + 0xfffe0300, + 0x0200001f, 0x80000000, 0x900f0000, + 0x0200001f, 0x80000000, 0xe00f0000, + 0x05000051, 0xa00f0100, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x03000002, 0x800f0000, 0x90e40000, 0xa0e40100, + 0x02000001, 0xe00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + vs_3_0 + dcl_position v0 + dcl_position o0 + defi i16, 1, 1, 1, 1 + rep i16 + add r0, r0, v0 + endrep + mov o0, r0 +#endif + static const DWORD vs_3_i16[] = + { + 0xfffe0300, + 0x0200001f, 0x80000000, 0x900f0000, + 0x0200001f, 0x80000000, 0xe00f0000, + 0x05000030, 0xf00f0010, 0x00000001, 0x00000001, 0x00000001, 0x00000001, + 0x01000026, 0xf0e40010, + 0x03000002, 0x800f0000, 0x80e40000, 0x90e40000, + 0x00000027, + 0x02000001, 0xe00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + vs_3_0 + dcl_position v0 + dcl_position o0 + defb b16, true + mov r0, v0 + if b16 + add r0, r0, v0 + endif + mov o0, r0 +#endif + static const DWORD vs_3_b16[] = + { + 0xfffe0300, + 0x0200001f, 0x80000000, 0x900f0000, + 0x0200001f, 0x80000000, 0xe00f0000, + 0x0200002f, 0xe00f0810, 0x00000001, + 0x02000001, 0x800f0000, 0x90e40000, + 0x01000028, 0xe0e40810, + 0x03000002, 0x800f0000, 0x80e40000, 0x90e40000, + 0x0000002b, + 0x02000001, 0xe00f0000, 0x80e40000, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + ps_1_1 + def c8, 1.0, 1.0, 1.0, 1.0 + add r0, v0, c8 +#endif + static const DWORD ps_1_8[] = + { + 0xffff0101, + 0x00000051, 0xa00f0008, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x00000002, 0x800f0000, 0x90e40000, 0xa0e40008, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + ps_2_0 + def c32, 1.0, 1.0, 1.0, 1.0 + add oC0, v0, c32 +#endif + static const DWORD ps_2_32[] = + { + 0xffff0200, + 0x05000051, 0xa00f0020, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x03000002, 0x800f0000, 0x90e40000, 0xa0e40020, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + ps_3_0 + dcl_color0 v0 + def c224, 1.0, 1.0, 1.0, 1.0 + add oC0, v0, c224 +#endif + static const DWORD ps_3_224[] = + { + 0xffff0300, + 0x0200001f, 0x8000000a, 0x900f0000, + 0x05000051, 0xa00f00e0, 0x3f800000, 0x3f800000, 0x3f800000, 0x3f800000, + 0x03000002, 0x800f0800, 0x90e40000, 0xa0e400e0, + 0x0000ffff + }; +#if 0 + /* This shader source generates syntax errors with the native shader assembler + * due to the constant register index values. + * The bytecode was modified by hand to use the intended values. */ + ps_2_0 + defb b0, true + defi i0, 1, 1, 1, 1 + rep i0 + if b0 + add r0, r0, v0 + endif + endrep + mov oC0, r0 +#endif + static const DWORD ps_2_0_boolint[] = + { + 0xffff0200, + 0x0200002f, 0xe00f0800, 0x00000001, + 0x05000030, 0xf00f0000, 0x00000001, 0x00000001, 0x00000001, 0x00000001, + 0x01000026, 0xf0e40000, + 0x01000028, 0xe0e40800, + 0x03000002, 0x800f0000, 0x80e40000, 0x90e40000, + 0x0000002b, + 0x00000027, + 0x02000001, 0x800f0800, 0x80e40000, + 0x0000ffff + }; IDirect3DVertexShader9 *vs = NULL; IDirect3DPixelShader9 *ps = NULL; @@ -5142,7 +5496,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5164,10 +5518,52 @@ { hr = IDirect3DDevice9_CreateVertexShader(device, vs_3_0, &vs); ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + if (caps.VertexShaderVersion <= D3DVS_VERSION(1, 1) && caps.MaxVertexShaderConst < 256) + { + hr = IDirect3DDevice9_CreateVertexShader(device, vs_1_255, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + } + else + { + skip("GPU supports SM2+, skipping SM1 test.\n"); + } + + skip("This GPU doesn't support SM3, skipping test with shader using unsupported constants.\n"); } else + { skip("This GPU supports SM3, skipping unsupported shader test.\n"); + hr = IDirect3DDevice9_CreateVertexShader(device, vs_1_255, &vs); + ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); + IDirect3DVertexShader9_Release(vs); + hr = IDirect3DDevice9_CreateVertexShader(device, vs_1_256, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9_CreateVertexShader(device, vs_3_256, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9_CreateVertexShader(device, vs_3_i16, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9_CreateVertexShader(device, vs_3_b16, &vs); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + } + + if (caps.PixelShaderVersion < D3DPS_VERSION(3, 0)) + { + skip("This GPU doesn't support SM3, skipping test with shader using unsupported constants.\n"); + goto cleanup; + } + hr = IDirect3DDevice9_CreatePixelShader(device, ps_1_8, &ps); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9_CreatePixelShader(device, ps_2_32, &ps); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9_CreatePixelShader(device, ps_3_224, &ps); + ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + hr = IDirect3DDevice9_CreatePixelShader(device, ps_2_0_boolint, &ps); + todo_wine ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr); + if (ps) + IDirect3DPixelShader9_Release(ps); + +cleanup: refcount = IDirect3DDevice9_Release(device); ok(!refcount, "Device has %u references left.\n", refcount); IDirect3D9_Release(d3d); @@ -5190,7 +5586,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5352,7 +5748,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5425,7 +5821,7 @@ window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5555,7 +5951,7 @@ window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5626,7 +6022,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5661,7 +6057,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5707,7 +6103,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5777,7 +6173,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5860,6 +6256,7 @@ {D3DFMT_DXT3, "D3DFMT_DXT3", 4, 4, 16}, {D3DFMT_DXT4, "D3DFMT_DXT4", 4, 4, 16}, {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 16}, + {MAKEFOURCC('A','T','I','1'), "ATI1N", 1, 1, 1}, {MAKEFOURCC('A','T','I','2'), "ATI2N", 1, 1, 1}, }; unsigned int expected_offset, offset, i; @@ -5878,7 +6275,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -5970,7 +6367,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -6077,7 +6474,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -6267,7 +6664,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -6334,7 +6731,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -6383,7 +6780,7 @@ window = CreateWindowA("d3d9_test_wc", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -6477,7 +6874,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -6527,9 +6924,10 @@ {D3DFMT_DXT3, "D3DFMT_DXT3", 4, 4, FALSE, TRUE, TRUE }, {D3DFMT_DXT4, "D3DFMT_DXT4", 4, 4, FALSE, TRUE, TRUE }, {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, FALSE, TRUE, TRUE }, - /* ATI2N has 2x2 blocks on all AMD cards and Geforce 7 cards, + /* ATI1N and ATI2N have 2x2 blocks on all AMD cards and Geforce 7 cards, * which doesn't match the format spec. On newer Nvidia cards - * it has the correct 4x4 block size */ + * they have the correct 4x4 block size */ + {MAKEFOURCC('A','T','I','1'), "ATI1N", 4, 4, TRUE, FALSE, FALSE}, {MAKEFOURCC('A','T','I','2'), "ATI2N", 4, 4, TRUE, FALSE, FALSE}, {D3DFMT_YUY2, "D3DFMT_YUY2", 2, 1, FALSE, FALSE, TRUE }, {D3DFMT_UYVY, "D3DFMT_UYVY", 2, 1, FALSE, FALSE, TRUE }, @@ -6593,7 +6991,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -6905,7 +7303,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); DestroyWindow(window); @@ -6959,7 +7357,7 @@ IDirect3DVertexBuffer9 *buffer; static const unsigned int bufsize = 1024; D3DVERTEXBUFFER_DESC desc; - D3DPRESENT_PARAMETERS present_parameters = {0}; + struct device_desc device_desc; struct { float x, y, z; @@ -6970,15 +7368,11 @@ d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - present_parameters.Windowed = TRUE; - present_parameters.hDeviceWindow = window; - present_parameters.SwapEffect = D3DSWAPEFFECT_DISCARD; - present_parameters.BackBufferWidth = screen_width; - present_parameters.BackBufferHeight = screen_height; - present_parameters.BackBufferFormat = D3DFMT_A8R8G8B8; - present_parameters.EnableAutoDepthStencil = FALSE; - if (FAILED(IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, window, - D3DCREATE_SOFTWARE_VERTEXPROCESSING, &present_parameters, &device))) + device_desc.device_window = window; + device_desc.width = 640; + device_desc.height = 480; + device_desc.flags = CREATE_DEVICE_SWVP_ONLY; + if (!(device = create_device(d3d9, window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); DestroyWindow(window); @@ -7070,7 +7464,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -7173,7 +7567,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -7244,7 +7638,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -7351,7 +7745,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -7457,7 +7851,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -7507,25 +7901,28 @@ unsigned int block_height; unsigned int block_depth; unsigned int block_size; - BOOL broken; + unsigned int broken; BOOL create_size_checked, core_fmt; } formats[] = { /* Scratch volumes enforce DXTn block locks, unlike their surface counterparts. * ATI2N and YUV blocks are not enforced on any tested card (r200, gtx 460). */ - {D3DFMT_DXT1, "D3DFMT_DXT1", 4, 4, 1, 8, FALSE, TRUE, TRUE }, - {D3DFMT_DXT2, "D3DFMT_DXT2", 4, 4, 1, 16, FALSE, TRUE, TRUE }, - {D3DFMT_DXT3, "D3DFMT_DXT3", 4, 4, 1, 16, FALSE, TRUE, TRUE }, - {D3DFMT_DXT4, "D3DFMT_DXT4", 4, 4, 1, 16, FALSE, TRUE, TRUE }, - {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 1, 16, FALSE, TRUE, TRUE }, - {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 1, 16, FALSE, TRUE, TRUE }, + {D3DFMT_DXT1, "D3DFMT_DXT1", 4, 4, 1, 8, 0, TRUE, TRUE }, + {D3DFMT_DXT2, "D3DFMT_DXT2", 4, 4, 1, 16, 0, TRUE, TRUE }, + {D3DFMT_DXT3, "D3DFMT_DXT3", 4, 4, 1, 16, 0, TRUE, TRUE }, + {D3DFMT_DXT4, "D3DFMT_DXT4", 4, 4, 1, 16, 0, TRUE, TRUE }, + {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 1, 16, 0, TRUE, TRUE }, + {D3DFMT_DXT5, "D3DFMT_DXT5", 4, 4, 1, 16, 0, TRUE, TRUE }, /* ATI2N has 2x2 blocks on all AMD cards and Geforce 7 cards, * which doesn't match the format spec. On newer Nvidia cards - * it has the correct 4x4 block size */ - {MAKEFOURCC('A','T','I','2'), "ATI2N", 4, 4, 1, 16, TRUE, FALSE, FALSE}, - {D3DFMT_YUY2, "D3DFMT_YUY2", 2, 1, 1, 4, TRUE, FALSE, TRUE }, - {D3DFMT_UYVY, "D3DFMT_UYVY", 2, 1, 1, 4, TRUE, FALSE, TRUE }, + * it has the correct 4x4 block size. + * ATI1N volume textures are only supported by AMD GPUs right + * now and locking offsets seem just wrong. */ + {MAKEFOURCC('A','T','I','1'), "ATI1N", 4, 4, 1, 8, 2, FALSE, FALSE}, + {MAKEFOURCC('A','T','I','2'), "ATI2N", 4, 4, 1, 16, 1, FALSE, FALSE}, + {D3DFMT_YUY2, "D3DFMT_YUY2", 2, 1, 1, 4, 1, FALSE, TRUE }, + {D3DFMT_UYVY, "D3DFMT_UYVY", 2, 1, 1, 4, 1, FALSE, TRUE }, }; static const struct { @@ -7567,7 +7964,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d9 = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d9, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d9, window, window, TRUE))) + if (!(device = create_device(d3d9, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d9); @@ -7673,10 +8070,14 @@ ok(SUCCEEDED(hr), "Failed to unlock volume texture, hr %#x.\n", hr); base = locked_box.pBits; - if (formats[i].broken) + if (formats[i].broken == 1) { expected_row_pitch = bytes_per_pixel * 24; } + else if (formats[i].broken == 2) + { + expected_row_pitch = 24; + } else { expected_row_pitch = (24 /* tex width */ + formats[i].block_height - 1) / formats[i].block_width @@ -7711,12 +8112,18 @@ ok(SUCCEEDED(hr), "Failed to lock volume texture, hr %#x, j %u.\n", hr, j); offset = (BYTE *)locked_box.pBits - base; - if (formats[i].broken) + if (formats[i].broken == 1) { expected_offset = box.Front * expected_slice_pitch + box.Top * expected_row_pitch + box.Left * bytes_per_pixel; } + else if (formats[i].broken == 2) + { + expected_offset = box.Front * expected_slice_pitch + + box.Top * expected_row_pitch + + box.Left; + } else { expected_offset = (box.Front / formats[i].block_depth) * expected_slice_pitch @@ -7884,7 +8291,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -7982,7 +8389,7 @@ 0, 0, 640, 480, 0, 0, 0, 0); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -8135,7 +8542,7 @@ test_format = GetPixelFormat(hdc); ok(test_format == format, "window has pixel format %d, expected %d\n", test_format, format); - if (!(device = create_device(d3d9, hwnd, hwnd, TRUE))) + if (!(device = create_device(d3d9, hwnd, NULL))) { skip("Failed to create device\n"); goto cleanup; @@ -8213,7 +8620,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -8271,7 +8678,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -8439,7 +8846,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -8612,12 +9019,13 @@ ULONG refcount; HWND window; HRESULT hr; + D3DCAPS9 caps; window = CreateWindowA("static", "d3d9_test", WS_OVERLAPPEDWINDOW, 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -8625,6 +9033,9 @@ return; } + hr = IDirect3DDevice9_GetDeviceCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + hr = IDirect3DDevice9_CreateOffscreenPlainSurface(device, 4, 4, D3DFMT_X8R8G8B8, D3DPOOL_SYSTEMMEM, &surface, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -8685,71 +9096,81 @@ IDirect3DSurface9_Release(surface); IDirect3DTexture9_Release(texture); - hr = IDirect3DDevice9_CreateCubeTexture(device, 1, 1, 0, D3DFMT_X8R8G8B8, - D3DPOOL_SYSTEMMEM, &cube_texture, NULL); - ok(SUCCEEDED(hr), "Failed to create cube texture, hr %#x.\n", hr); - type = IDirect3DCubeTexture9_GetType(cube_texture); - ok(type == D3DRTYPE_CUBETEXTURE, "Expected type D3DRTYPE_CUBETEXTURE, got %u.\n", type); - - hr = IDirect3DCubeTexture9_GetCubeMapSurface(cube_texture, - D3DCUBEMAP_FACE_NEGATIVE_X, 0, &surface); - ok(SUCCEEDED(hr), "Failed to get cube map surface, hr %#x.\n", hr); - type = IDirect3DSurface9_GetType(surface); - ok(type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", type); - hr = IDirect3DSurface9_GetDesc(surface, &surface_desc); - ok(SUCCEEDED(hr), "Failed to get surface description, hr %#x.\n", hr); - ok(surface_desc.Type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", - surface_desc.Type); - hr = IDirect3DCubeTexture9_GetLevelDesc(cube_texture, 0, &surface_desc); - ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); - ok(surface_desc.Type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", - surface_desc.Type); - IDirect3DSurface9_Release(surface); - IDirect3DCubeTexture9_Release(cube_texture); - - hr = IDirect3DDevice9_CreateVolumeTexture(device, 2, 4, 8, 4, 0, D3DFMT_X8R8G8B8, - D3DPOOL_SYSTEMMEM, &volume_texture, NULL); - type = IDirect3DVolumeTexture9_GetType(volume_texture); - ok(type == D3DRTYPE_VOLUMETEXTURE, "Expected type D3DRTYPE_VOLUMETEXTURE, got %u.\n", type); - - hr = IDirect3DVolumeTexture9_GetVolumeLevel(volume_texture, 0, &volume); - ok(SUCCEEDED(hr), "Failed to get volume level, hr %#x.\n", hr); - /* IDirect3DVolume9 is not an IDirect3DResource9 and has no GetType method. */ - hr = IDirect3DVolume9_GetDesc(volume, &volume_desc); - ok(SUCCEEDED(hr), "Failed to get volume description, hr %#x.\n", hr); - ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", - volume_desc.Type); - ok(volume_desc.Width == 2, "Expected width 2, got %u.\n", volume_desc.Width); - ok(volume_desc.Height == 4, "Expected height 4, got %u.\n", volume_desc.Height); - ok(volume_desc.Depth == 8, "Expected depth 8, got %u.\n", volume_desc.Depth); - hr = IDirect3DVolumeTexture9_GetLevelDesc(volume_texture, 0, &volume_desc); - ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); - ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", - volume_desc.Type); - ok(volume_desc.Width == 2, "Expected width 2, got %u.\n", volume_desc.Width); - ok(volume_desc.Height == 4, "Expected height 4, got %u.\n", volume_desc.Height); - ok(volume_desc.Depth == 8, "Expected depth 8, got %u.\n", volume_desc.Depth); - IDirect3DVolume9_Release(volume); + if (caps.TextureCaps & D3DPTEXTURECAPS_CUBEMAP) + { + hr = IDirect3DDevice9_CreateCubeTexture(device, 1, 1, 0, D3DFMT_X8R8G8B8, + D3DPOOL_SYSTEMMEM, &cube_texture, NULL); + ok(SUCCEEDED(hr), "Failed to create cube texture, hr %#x.\n", hr); + type = IDirect3DCubeTexture9_GetType(cube_texture); + ok(type == D3DRTYPE_CUBETEXTURE, "Expected type D3DRTYPE_CUBETEXTURE, got %u.\n", type); + + hr = IDirect3DCubeTexture9_GetCubeMapSurface(cube_texture, + D3DCUBEMAP_FACE_NEGATIVE_X, 0, &surface); + ok(SUCCEEDED(hr), "Failed to get cube map surface, hr %#x.\n", hr); + type = IDirect3DSurface9_GetType(surface); + ok(type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", type); + hr = IDirect3DSurface9_GetDesc(surface, &surface_desc); + ok(SUCCEEDED(hr), "Failed to get surface description, hr %#x.\n", hr); + ok(surface_desc.Type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", + surface_desc.Type); + hr = IDirect3DCubeTexture9_GetLevelDesc(cube_texture, 0, &surface_desc); + ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); + ok(surface_desc.Type == D3DRTYPE_SURFACE, "Expected type D3DRTYPE_SURFACE, got %u.\n", + surface_desc.Type); + IDirect3DSurface9_Release(surface); + IDirect3DCubeTexture9_Release(cube_texture); + } + else + skip("Cube maps not supported.\n"); - hr = IDirect3DVolumeTexture9_GetVolumeLevel(volume_texture, 2, &volume); - ok(SUCCEEDED(hr), "Failed to get volume level, hr %#x.\n", hr); - /* IDirect3DVolume9 is not an IDirect3DResource9 and has no GetType method. */ - hr = IDirect3DVolume9_GetDesc(volume, &volume_desc); - ok(SUCCEEDED(hr), "Failed to get volume description, hr %#x.\n", hr); - ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", - volume_desc.Type); - ok(volume_desc.Width == 1, "Expected width 1, got %u.\n", volume_desc.Width); - ok(volume_desc.Height == 1, "Expected height 1, got %u.\n", volume_desc.Height); - ok(volume_desc.Depth == 2, "Expected depth 2, got %u.\n", volume_desc.Depth); - hr = IDirect3DVolumeTexture9_GetLevelDesc(volume_texture, 2, &volume_desc); - ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); - ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", - volume_desc.Type); - ok(volume_desc.Width == 1, "Expected width 1, got %u.\n", volume_desc.Width); - ok(volume_desc.Height == 1, "Expected height 1, got %u.\n", volume_desc.Height); - ok(volume_desc.Depth == 2, "Expected depth 2, got %u.\n", volume_desc.Depth); - IDirect3DVolume9_Release(volume); - IDirect3DVolumeTexture9_Release(volume_texture); + if (caps.TextureCaps & D3DPTEXTURECAPS_MIPVOLUMEMAP) + { + hr = IDirect3DDevice9_CreateVolumeTexture(device, 2, 4, 8, 4, 0, D3DFMT_X8R8G8B8, + D3DPOOL_SYSTEMMEM, &volume_texture, NULL); + type = IDirect3DVolumeTexture9_GetType(volume_texture); + ok(type == D3DRTYPE_VOLUMETEXTURE, "Expected type D3DRTYPE_VOLUMETEXTURE, got %u.\n", type); + + hr = IDirect3DVolumeTexture9_GetVolumeLevel(volume_texture, 0, &volume); + ok(SUCCEEDED(hr), "Failed to get volume level, hr %#x.\n", hr); + /* IDirect3DVolume9 is not an IDirect3DResource9 and has no GetType method. */ + hr = IDirect3DVolume9_GetDesc(volume, &volume_desc); + ok(SUCCEEDED(hr), "Failed to get volume description, hr %#x.\n", hr); + ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", + volume_desc.Type); + ok(volume_desc.Width == 2, "Expected width 2, got %u.\n", volume_desc.Width); + ok(volume_desc.Height == 4, "Expected height 4, got %u.\n", volume_desc.Height); + ok(volume_desc.Depth == 8, "Expected depth 8, got %u.\n", volume_desc.Depth); + hr = IDirect3DVolumeTexture9_GetLevelDesc(volume_texture, 0, &volume_desc); + ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); + ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", + volume_desc.Type); + ok(volume_desc.Width == 2, "Expected width 2, got %u.\n", volume_desc.Width); + ok(volume_desc.Height == 4, "Expected height 4, got %u.\n", volume_desc.Height); + ok(volume_desc.Depth == 8, "Expected depth 8, got %u.\n", volume_desc.Depth); + IDirect3DVolume9_Release(volume); + + hr = IDirect3DVolumeTexture9_GetVolumeLevel(volume_texture, 2, &volume); + ok(SUCCEEDED(hr), "Failed to get volume level, hr %#x.\n", hr); + /* IDirect3DVolume9 is not an IDirect3DResource9 and has no GetType method. */ + hr = IDirect3DVolume9_GetDesc(volume, &volume_desc); + ok(SUCCEEDED(hr), "Failed to get volume description, hr %#x.\n", hr); + ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", + volume_desc.Type); + ok(volume_desc.Width == 1, "Expected width 1, got %u.\n", volume_desc.Width); + ok(volume_desc.Height == 1, "Expected height 1, got %u.\n", volume_desc.Height); + ok(volume_desc.Depth == 2, "Expected depth 2, got %u.\n", volume_desc.Depth); + hr = IDirect3DVolumeTexture9_GetLevelDesc(volume_texture, 2, &volume_desc); + ok(SUCCEEDED(hr), "Failed to get level description, hr %#x.\n", hr); + ok(volume_desc.Type == D3DRTYPE_VOLUME, "Expected type D3DRTYPE_VOLUME, got %u.\n", + volume_desc.Type); + ok(volume_desc.Width == 1, "Expected width 1, got %u.\n", volume_desc.Width); + ok(volume_desc.Height == 1, "Expected height 1, got %u.\n", volume_desc.Height); + ok(volume_desc.Depth == 2, "Expected depth 2, got %u.\n", volume_desc.Depth); + IDirect3DVolume9_Release(volume); + IDirect3DVolumeTexture9_Release(volume_texture); + } + else + skip("Mipmapped volume maps not supported.\n"); refcount = IDirect3DDevice9_Release(device); ok(!refcount, "Device has %u references left.\n", refcount); @@ -8772,7 +9193,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -8854,7 +9275,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -8905,6 +9326,7 @@ static void test_lost_device(void) { + struct device_desc device_desc; IDirect3DDevice9 *device; IDirect3D9 *d3d; ULONG refcount; @@ -8916,7 +9338,11 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, FALSE))) + device_desc.device_window = window; + device_desc.width = registry_mode.dmPelsWidth; + device_desc.height = registry_mode.dmPelsHeight; + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + if (!(device = create_device(d3d, window, &device_desc))) { skip("Failed to create a D3D device, skipping tests.\n"); goto done; @@ -8943,14 +9369,15 @@ hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3DERR_DEVICELOST, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, FALSE); + hr = reset_device(device, &device_desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice9_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, TRUE); + device_desc.flags = 0; + hr = reset_device(device, &device_desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice9_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); @@ -8973,7 +9400,8 @@ hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); - hr = reset_device(device, window, FALSE); + device_desc.flags = CREATE_DEVICE_FULLSCREEN; + hr = reset_device(device, &device_desc); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); hr = IDirect3DDevice9_TestCooperativeLevel(device); ok(hr == D3D_OK, "Got unexpected hr %#x.\n", hr); @@ -9017,7 +9445,7 @@ 0, 0, 640, 480, NULL, NULL, NULL, NULL); d3d = Direct3DCreate9(D3D_SDK_VERSION); ok(!!d3d, "Failed to create a D3D object.\n"); - if (!(device = create_device(d3d, window, window, TRUE))) + if (!(device = create_device(d3d, window, NULL))) { skip("Failed to create a D3D device, skipping tests.\n"); IDirect3D9_Release(d3d); @@ -9120,6 +9548,19 @@ { WNDCLASSA wc = {0}; IDirect3D9 *d3d9; + DEVMODEW current_mode; + + memset(¤t_mode, 0, sizeof(current_mode)); + current_mode.dmSize = sizeof(current_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, ¤t_mode), "Failed to get display mode.\n"); + registry_mode.dmSize = sizeof(registry_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_REGISTRY_SETTINGS, ®istry_mode), "Failed to get display mode.\n"); + if (registry_mode.dmPelsWidth != current_mode.dmPelsWidth + || registry_mode.dmPelsHeight != current_mode.dmPelsHeight) + { + skip("Current mode does not match registry mode, skipping test.\n"); + return; + } if (!(d3d9 = Direct3DCreate9(D3D_SDK_VERSION))) { @@ -9132,9 +9573,6 @@ wc.lpszClassName = "d3d9_test_wc"; RegisterClassA(&wc); - screen_width = GetSystemMetrics(SM_CXSCREEN); - screen_height = GetSystemMetrics(SM_CYSCREEN); - test_get_set_vertex_declaration(); test_get_declaration(); test_fvf_decl_conversion(); @@ -9180,7 +9618,7 @@ test_vertex_shader_constant(); test_get_set_pixel_shader(); test_pixel_shader_constant(); - test_wrong_shader(); + test_unsupported_shaders(); test_texture_stage_states(); test_cube_textures(); test_mipmap_gen(); diff -Nru wine1.7-1.7.28/dlls/d3d9/tests/visual.c wine1.7-1.7.31/dlls/d3d9/tests/visual.c --- wine1.7-1.7.28/dlls/d3d9/tests/visual.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3d9/tests/visual.c 2014-11-14 13:28:17.000000000 +0000 @@ -16660,6 +16660,310 @@ DestroyWindow(window); } +static void test_3dc_formats(void) +{ + static const char ati1n_data[] = + { + /* A 4x4 texture with the color component at 50%. */ + 0x7f, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + }; + static const char ati2n_data[] = + { + /* A 8x4 texture consisting of 2 4x4 blocks. The first block has 50% first color component, + * 0% second component. Second block is the opposite. */ + 0x7f, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + }; + static const struct + { + struct vec3 position; + struct vec2 texcoord; + } + quads[] = + { + {{-1.0f, -1.0f, 0.0f}, {0.0f, 0.0f}}, + {{-1.0f, 1.0f, 0.0f}, {0.0f, 1.0f}}, + {{ 0.0f, -1.0f, 1.0f}, {1.0f, 0.0f}}, + {{ 0.0f, 1.0f, 1.0f}, {1.0f, 1.0f}}, + + {{ 0.0f, -1.0f, 0.0f}, {0.0f, 0.0f}}, + {{ 0.0f, 1.0f, 0.0f}, {0.0f, 1.0f}}, + {{ 1.0f, -1.0f, 1.0f}, {1.0f, 0.0f}}, + {{ 1.0f, 1.0f, 1.0f}, {1.0f, 1.0f}}, + }; + static const DWORD ati1n_fourcc = MAKEFOURCC('A','T','I','1'); + static const DWORD ati2n_fourcc = MAKEFOURCC('A','T','I','2'); + static const struct + { + struct vec2 position; + D3DCOLOR amd; + D3DCOLOR nvidia; + } + expected_colors[] = + { + {{ 80, 240}, 0x003f3f3f, 0x007f0000}, + {{240, 240}, 0x003f3f3f, 0x007f0000}, + {{400, 240}, 0x00007fff, 0x00007fff}, + {{560, 240}, 0x007f00ff, 0x007f00ff}, + }; + IDirect3D9 *d3d; + IDirect3DDevice9 *device; + IDirect3DTexture9 *ati1n_texture, *ati2n_texture; + D3DCAPS9 caps; + D3DLOCKED_RECT rect; + D3DCOLOR color; + ULONG refcount; + HWND window; + HRESULT hr; + unsigned int i; + + window = CreateWindowA("static", "d3d9_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE, + 0, 0, 640, 480, NULL, NULL, NULL, NULL); + d3d = Direct3DCreate9(D3D_SDK_VERSION); + ok(!!d3d, "Failed to create a D3D object.\n"); + if (FAILED(IDirect3D9_CheckDeviceFormat(d3d, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, + D3DFMT_X8R8G8B8, 0, D3DRTYPE_TEXTURE, ati1n_fourcc))) + { + skip("ATI1N textures are not supported, skipping test.\n"); + goto done; + } + if (FAILED(IDirect3D9_CheckDeviceFormat(d3d, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, + D3DFMT_X8R8G8B8, 0, D3DRTYPE_TEXTURE, ati2n_fourcc))) + { + skip("ATI2N textures are not supported, skipping test.\n"); + goto done; + } + if (!(device = create_device(d3d, window, window, TRUE))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + goto done; + } + hr = IDirect3DDevice9_GetDeviceCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + if (!(caps.PrimitiveMiscCaps & D3DPMISCCAPS_TSSARGTEMP)) + { + skip("D3DTA_TEMP not supported, skipping tests.\n"); + IDirect3DDevice9_Release(device); + goto done; + } + + hr = IDirect3DDevice9_CreateTexture(device, 4, 4, 1, 0, ati1n_fourcc, + D3DPOOL_MANAGED, &ati1n_texture, NULL); + ok(SUCCEEDED(hr), "Failed to create texture, hr %#x.\n", hr); + + hr = IDirect3DTexture9_LockRect(ati1n_texture, 0, &rect, NULL, 0); + ok(SUCCEEDED(hr), "Failed to lock texture, hr %#x.\n", hr); + memcpy(rect.pBits, ati1n_data, sizeof(ati1n_data)); + hr = IDirect3DTexture9_UnlockRect(ati1n_texture, 0); + ok(SUCCEEDED(hr), "Failed to unlock texture, hr %#x.\n", hr); + + hr = IDirect3DDevice9_CreateTexture(device, 8, 4, 1, 0, ati2n_fourcc, + D3DPOOL_MANAGED, &ati2n_texture, NULL); + ok(SUCCEEDED(hr), "Failed to create texture, hr %#x.\n", hr); + + hr = IDirect3DTexture9_LockRect(ati2n_texture, 0, &rect, NULL, 0); + ok(SUCCEEDED(hr), "Failed to lock texture, hr %#x.\n", hr); + memcpy(rect.pBits, ati2n_data, sizeof(ati2n_data)); + hr = IDirect3DTexture9_UnlockRect(ati2n_texture, 0); + ok(SUCCEEDED(hr), "Failed to unlock texture, hr %#x.\n", hr); + + hr = IDirect3DDevice9_SetFVF(device, D3DFVF_XYZ | D3DFVF_TEX1 | D3DFVF_TEXCOORDSIZE2(0)); + ok(SUCCEEDED(hr), "Failed to set FVF, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetTextureStageState(device, 0, D3DTSS_COLOROP, D3DTOP_BLENDTEXTUREALPHA); + ok(SUCCEEDED(hr), "Failed to set color op, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetTextureStageState(device, 0, D3DTSS_COLORARG1, D3DTA_TEXTURE); + ok(SUCCEEDED(hr), "Failed to set color arg, hr %#x.\n", hr); + /* The temporary register is initialized to 0. */ + hr = IDirect3DDevice9_SetTextureStageState(device, 0, D3DTSS_COLORARG2, D3DTA_TEMP); + ok(SUCCEEDED(hr), "Failed to set color arg, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetTextureStageState(device, 0, D3DTSS_ALPHAOP, D3DTOP_SELECTARG1); + ok(SUCCEEDED(hr), "Failed to set alpha op, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetTextureStageState(device, 0, D3DTSS_ALPHAARG1, D3DTA_TEXTURE); + ok(SUCCEEDED(hr), "Failed to set alpha arg, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetTextureStageState(device, 1, D3DTSS_COLOROP, D3DTOP_DISABLE); + ok(SUCCEEDED(hr), "Failed to set color op, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetSamplerState(device, 0, D3DSAMP_MAGFILTER, D3DTEXF_POINT); + ok(SUCCEEDED(hr), "Failed to set mag filter, hr %#x.\n", hr); + + hr = IDirect3DDevice9_Clear(device, 0, NULL, D3DCLEAR_TARGET | D3DCLEAR_ZBUFFER, 0x00ff00ff, 1.0f, 0); + ok(SUCCEEDED(hr), "Failed to clear, hr %#x.\n", hr); + hr = IDirect3DDevice9_BeginScene(device); + ok(SUCCEEDED(hr), "Failed to begin scene, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetTexture(device, 0, (IDirect3DBaseTexture9 *)ati1n_texture); + ok(SUCCEEDED(hr), "Failed to set texture, hr %#x.\n", hr); + hr = IDirect3DDevice9_DrawPrimitiveUP(device, D3DPT_TRIANGLESTRIP, 2, &quads[0], sizeof(*quads)); + ok(SUCCEEDED(hr), "Failed to draw, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetTexture(device, 0, (IDirect3DBaseTexture9 *)ati2n_texture); + ok(SUCCEEDED(hr), "Failed to set texture, hr %#x.\n", hr); + hr = IDirect3DDevice9_DrawPrimitiveUP(device, D3DPT_TRIANGLESTRIP, 2, &quads[4], sizeof(*quads)); + ok(SUCCEEDED(hr), "Failed to draw, hr %#x.\n", hr); + hr = IDirect3DDevice9_EndScene(device); + ok(SUCCEEDED(hr), "Failed to end scene, hr %#x.\n", hr); + + hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); + ok(SUCCEEDED(hr), "Failed to present, hr %#x.\n", hr); + for (i = 0; i < 4; ++i) + { + color = getPixelColor(device, expected_colors[i].position.x, expected_colors[i].position.y); + ok (color_match(color, expected_colors[i].amd, 1) || color_match(color, expected_colors[i].nvidia, 1), + "Expected color 0x%08x or 0x%08x, got 0x%08x, case %u.\n", + expected_colors[i].amd, expected_colors[i].nvidia, color, i); + } + + IDirect3DTexture9_Release(ati2n_texture); + IDirect3DTexture9_Release(ati1n_texture); + refcount = IDirect3DDevice9_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); + +done: + IDirect3D9_Release(d3d); + DestroyWindow(window); +} + +static void fog_interpolation_test(void) +{ + HRESULT hr; + IDirect3DDevice9 *device; + IDirect3D9 *d3d; + ULONG refcount; + HWND window; + D3DCOLOR color; + static const struct + { + struct vec3 position; + D3DCOLOR diffuse; + D3DCOLOR specular; + } + quad[] = + { + {{-1.0f, -1.0f, 0.0f}, 0xffff0000, 0xff000000}, + {{-1.0f, 1.0f, 0.0f}, 0xffff0000, 0xff000000}, + {{ 1.0f, -1.0f, 1.0f}, 0xffff0000, 0x00000000}, + {{ 1.0f, 1.0f, 1.0f}, 0xffff0000, 0x00000000}, + }; + union + { + DWORD d; + float f; + } conv; + unsigned int i; + static const struct + { + D3DFOGMODE vfog, tfog; + D3DSHADEMODE shade; + D3DCOLOR middle_color; + BOOL todo; + } + tests[] = + { + {D3DFOG_NONE, D3DFOG_NONE, D3DSHADE_FLAT, 0x00007f80, FALSE}, + {D3DFOG_NONE, D3DFOG_NONE, D3DSHADE_GOURAUD, 0x00007f80, FALSE}, + {D3DFOG_EXP, D3DFOG_NONE, D3DSHADE_FLAT, 0x00007f80, TRUE}, + {D3DFOG_EXP, D3DFOG_NONE, D3DSHADE_GOURAUD, 0x00007f80, TRUE}, + {D3DFOG_NONE, D3DFOG_EXP, D3DSHADE_FLAT, 0x0000ea15, FALSE}, + {D3DFOG_NONE, D3DFOG_EXP, D3DSHADE_GOURAUD, 0x0000ea15, FALSE}, + {D3DFOG_EXP, D3DFOG_EXP, D3DSHADE_FLAT, 0x0000ea15, FALSE}, + {D3DFOG_EXP, D3DFOG_EXP, D3DSHADE_GOURAUD, 0x0000ea15, FALSE}, + }; + static const D3DMATRIX ident_mat = + {{{ + 1.0f, 0.0f, 0.0f, 0.0f, + 0.0f, 1.0f, 0.0f, 0.0f, + 0.0f, 0.0f, 1.0f, 0.0f, + 0.0f, 0.0f, 0.0f, 1.0f + }}}; + D3DCAPS9 caps; + + window = CreateWindowA("static", "d3d9_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE, + 0, 0, 640, 480, NULL, NULL, NULL, NULL); + d3d = Direct3DCreate9(D3D_SDK_VERSION); + ok(!!d3d, "Failed to create a D3D object.\n"); + + if (!(device = create_device(d3d, window, window, TRUE))) + { + skip("Failed to create a D3D device, skipping tests.\n"); + IDirect3D9_Release(d3d); + DestroyWindow(window); + return; + } + + hr = IDirect3DDevice9_GetDeviceCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + if (!(caps.RasterCaps & D3DPRASTERCAPS_FOGTABLE)) + skip("D3DPRASTERCAPS_FOGTABLE not supported, skipping some fog tests\n"); + + hr = IDirect3DDevice9_SetFVF(device, D3DFVF_XYZ | D3DFVF_DIFFUSE | D3DFVF_SPECULAR); + ok(SUCCEEDED(hr), "Failed to set fvf, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_LIGHTING, FALSE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_ZENABLE, FALSE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_FOGENABLE, TRUE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_FOGCOLOR, 0x0000ff00); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + conv.f = 5.0; + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_FOGDENSITY, conv.d); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + + hr = IDirect3DDevice9_SetTextureStageState(device, 0, D3DTSS_COLOROP, D3DTOP_SELECTARG1); + ok(SUCCEEDED(hr), "Failed to set texture stage state, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetTextureStageState(device, 0, D3DTSS_COLORARG1, D3DTA_TFACTOR); + ok(SUCCEEDED(hr), "Failed to set texture stage state, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_TEXTUREFACTOR, 0x000000ff); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + + /* Some of the tests seem to depend on the projection matrix explicitly + * being set to an identity matrix, even though that's the default. + * (AMD Radeon X1600, AMD Radeon HD 6310, Windows 7). Without this, + * the drivers seem to use a static z = 1.0 input for the fog equation. + * The input value is independent of the actual z and w component of + * the vertex position. */ + hr = IDirect3DDevice9_SetTransform(device, D3DTS_PROJECTION, &ident_mat); + ok(SUCCEEDED(hr), "Failed to set projection transform, hr %#x.\n", hr); + + for (i = 0; i < sizeof(tests) / sizeof(*tests); i++) + { + if(!(caps.RasterCaps & D3DPRASTERCAPS_FOGTABLE) && tests[i].tfog) + continue; + + hr = IDirect3DDevice9_Clear(device, 0, NULL, D3DCLEAR_TARGET, 0x00808080, 0.0f, 0); + ok(SUCCEEDED(hr), "Failed to clear, hr %#x.\n", hr); + + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_SHADEMODE, tests[i].shade); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_FOGVERTEXMODE, tests[i].vfog); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice9_SetRenderState(device, D3DRS_FOGTABLEMODE, tests[i].tfog); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice9_BeginScene(device); + ok(SUCCEEDED(hr), "Failed to begin scene, hr %#x.\n", hr); + hr = IDirect3DDevice9_DrawPrimitiveUP(device, D3DPT_TRIANGLESTRIP, 2, quad, sizeof(*quad)); + ok(SUCCEEDED(hr), "Failed to draw, hr %#x.\n", hr); + hr = IDirect3DDevice9_EndScene(device); + ok(SUCCEEDED(hr), "Failed to end scene, hr %#x.\n", hr); + + color = getPixelColor(device, 0, 240); + ok(color_match(color, 0x000000ff, 2), "Got unexpected color 0x%08x, case %u.\n", color, i); + color = getPixelColor(device, 320, 240); + if (tests[i].todo) + todo_wine ok(color_match(color, tests[i].middle_color, 2), + "Got unexpected color 0x%08x, case %u.\n", color, i); + else + ok(color_match(color, tests[i].middle_color, 2), + "Got unexpected color 0x%08x, case %u.\n", color, i); + color = getPixelColor(device, 639, 240); + ok(color_match(color, 0x0000fd02, 2), "Got unexpected color 0x%08x, case %u.\n", color, i); + hr = IDirect3DDevice9_Present(device, NULL, NULL, NULL, NULL); + ok(SUCCEEDED(hr), "Failed to present, hr %#x.\n", hr); + } + + refcount = IDirect3DDevice9_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); + IDirect3D9_Release(d3d); + DestroyWindow(window); +} + START_TEST(visual) { D3DADAPTER_IDENTIFIER9 identifier; @@ -16767,4 +17071,6 @@ resz_test(); stencil_cull_test(); test_per_stage_constant(); + test_3dc_formats(); + fog_interpolation_test(); } diff -Nru wine1.7-1.7.28/dlls/d3dcompiler_43/utils.c wine1.7-1.7.31/dlls/d3dcompiler_43/utils.c --- wine1.7-1.7.28/dlls/d3dcompiler_43/utils.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dcompiler_43/utils.c 2014-11-14 13:28:17.000000000 +0000 @@ -2083,6 +2083,11 @@ "sat", + "pre++", + "pre--", + "post++", + "post--", + "+", "-", "*", @@ -2113,11 +2118,6 @@ "pow", - "pre++", - "pre--", - "post++", - "post--", - "lerp", ",", diff -Nru wine1.7-1.7.28/dlls/d3drm/d3drm.c wine1.7-1.7.31/dlls/d3drm/d3drm.c --- wine1.7-1.7.28/dlls/d3drm/d3drm.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3drm/d3drm.c 2014-11-14 13:28:17.000000000 +0000 @@ -1240,17 +1240,16 @@ /* Cannot be requested */ if (parent_frame) { - D3DRMMATRIX4D matrix; + D3DRMMATRIX4D *matrix; DWORD size; TRACE("Load Frame Transform Matrix data\n"); - size = sizeof(matrix); - hr = IDirectXFileData_GetData(data_object, NULL, &size, (void**)matrix); + hr = IDirectXFileData_GetData(data_object, NULL, &size, (void**)&matrix); if ((hr != DXFILE_OK) || (size != sizeof(matrix))) goto end; - hr = IDirect3DRMFrame3_AddTransform(parent_frame, D3DRMCOMBINE_REPLACE, matrix); + hr = IDirect3DRMFrame3_AddTransform(parent_frame, D3DRMCOMBINE_REPLACE, *matrix); if (FAILED(hr)) goto end; } diff -Nru wine1.7-1.7.28/dlls/d3dx9_24/d3dx9_24.spec wine1.7-1.7.31/dlls/d3dx9_24/d3dx9_24.spec --- wine1.7-1.7.28/dlls/d3dx9_24/d3dx9_24.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_24/d3dx9_24.spec 2014-11-14 13:28:17.000000000 +0000 @@ -72,7 +72,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_25/d3dx9_25.spec wine1.7-1.7.31/dlls/d3dx9_25/d3dx9_25.spec --- wine1.7-1.7.28/dlls/d3dx9_25/d3dx9_25.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_25/d3dx9_25.spec 2014-11-14 13:28:17.000000000 +0000 @@ -72,7 +72,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_26/d3dx9_26.spec wine1.7-1.7.31/dlls/d3dx9_26/d3dx9_26.spec --- wine1.7-1.7.28/dlls/d3dx9_26/d3dx9_26.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_26/d3dx9_26.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_27/d3dx9_27.spec wine1.7-1.7.31/dlls/d3dx9_27/d3dx9_27.spec --- wine1.7-1.7.28/dlls/d3dx9_27/d3dx9_27.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_27/d3dx9_27.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_28/d3dx9_28.spec wine1.7-1.7.31/dlls/d3dx9_28/d3dx9_28.spec --- wine1.7-1.7.28/dlls/d3dx9_28/d3dx9_28.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_28/d3dx9_28.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_29/d3dx9_29.spec wine1.7-1.7.31/dlls/d3dx9_29/d3dx9_29.spec --- wine1.7-1.7.28/dlls/d3dx9_29/d3dx9_29.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_29/d3dx9_29.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_30/d3dx9_30_main.c wine1.7-1.7.31/dlls/d3dx9_30/d3dx9_30_main.c --- wine1.7-1.7.28/dlls/d3dx9_30/d3dx9_30_main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_30/d3dx9_30_main.c 2014-11-14 13:28:17.000000000 +0000 @@ -30,6 +30,9 @@ #include "winuser.h" #include "d3dx9.h" +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(d3dx); /*********************************************************************** * DllMain. @@ -58,3 +61,17 @@ else return FALSE; } + +typedef enum _D3DX_CPU_OPTIMIZATION +{ + D3DX_NOT_OPTIMIZED = 0, + D3DX_3DNOW_OPTIMIZED = 1, + D3DX_SSE2_OPTIMIZED = 2, + D3DX_SSE_OPTIMIZED = 3 +} D3DX_CPU_OPTIMIZATION; + +D3DX_CPU_OPTIMIZATION WINAPI D3DXCpuOptimizations(BOOL enable) +{ + FIXME("%i - stub\n", enable); + return D3DX_NOT_OPTIMIZED; +} diff -Nru wine1.7-1.7.28/dlls/d3dx9_30/d3dx9_30.spec wine1.7-1.7.31/dlls/d3dx9_30/d3dx9_30.spec --- wine1.7-1.7.28/dlls/d3dx9_30/d3dx9_30.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_30/d3dx9_30.spec 2014-11-14 13:28:17.000000000 +0000 @@ -30,7 +30,7 @@ @ stdcall D3DXConcatenateMeshes(ptr long long ptr ptr ptr ptr ptr) d3dx9_36.D3DXConcatenateMeshes @ stdcall D3DXConvertMeshSubsetToSingleStrip(ptr long long ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToSingleStrip @ stdcall D3DXConvertMeshSubsetToStrips(ptr long long ptr ptr ptr ptr) d3dx9_36.D3DXConvertMeshSubsetToStrips -@ stub D3DXCpuOptimizations(long) +@ stdcall D3DXCpuOptimizations(long) @ stdcall D3DXCreateAnimationController(long long long long ptr) d3dx9_36.D3DXCreateAnimationController @ stdcall D3DXCreateBox(ptr float float float ptr ptr) d3dx9_36.D3DXCreateBox @ stdcall D3DXCreateBuffer(long ptr) d3dx9_36.D3DXCreateBuffer @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_31/d3dx9_31.spec wine1.7-1.7.31/dlls/d3dx9_31/d3dx9_31.spec --- wine1.7-1.7.28/dlls/d3dx9_31/d3dx9_31.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_31/d3dx9_31.spec 2014-11-14 13:28:17.000000000 +0000 @@ -75,7 +75,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_32/d3dx9_32.spec wine1.7-1.7.31/dlls/d3dx9_32/d3dx9_32.spec --- wine1.7-1.7.28/dlls/d3dx9_32/d3dx9_32.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_32/d3dx9_32.spec 2014-11-14 13:28:17.000000000 +0000 @@ -75,7 +75,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_33/d3dx9_33.spec wine1.7-1.7.31/dlls/d3dx9_33/d3dx9_33.spec --- wine1.7-1.7.28/dlls/d3dx9_33/d3dx9_33.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_33/d3dx9_33.spec 2014-11-14 13:28:17.000000000 +0000 @@ -75,7 +75,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_34/d3dx9_34.spec wine1.7-1.7.31/dlls/d3dx9_34/d3dx9_34.spec --- wine1.7-1.7.28/dlls/d3dx9_34/d3dx9_34.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_34/d3dx9_34.spec 2014-11-14 13:28:17.000000000 +0000 @@ -75,7 +75,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_35/d3dx9_35.spec wine1.7-1.7.31/dlls/d3dx9_35/d3dx9_35.spec --- wine1.7-1.7.28/dlls/d3dx9_35/d3dx9_35.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_35/d3dx9_35.spec 2014-11-14 13:28:17.000000000 +0000 @@ -75,7 +75,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_36/d3dx9_36.spec wine1.7-1.7.31/dlls/d3dx9_36/d3dx9_36.spec --- wine1.7-1.7.28/dlls/d3dx9_36/d3dx9_36.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_36/d3dx9_36.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stub D3DXCreateNPatchMesh(ptr ptr) @ stub D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) @ stub D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) -@ stub D3DXCreatePolygon(ptr long long ptr ptr) +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) @ stub D3DXCreatePRTBuffer(long long long ptr) @ stub D3DXCreatePRTBufferTex(long long long long ptr) @ stub D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) diff -Nru wine1.7-1.7.28/dlls/d3dx9_36/mesh.c wine1.7-1.7.31/dlls/d3dx9_36/mesh.c --- wine1.7-1.7.28/dlls/d3dx9_36/mesh.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_36/mesh.c 2014-11-14 13:28:17.000000000 +0000 @@ -2407,9 +2407,9 @@ D3DXVec4Transform(&vec, &vec, &m); if ( (vec.x >= 0.0f) && (vec.y >= 0.0f) && (vec.x + vec.y <= 1.0f) && (vec.z >= 0.0f) ) { - *pu = vec.x; - *pv = vec.y; - *pdist = fabsf( vec.z ); + if (pu) *pu = vec.x; + if (pv) *pv = vec.y; + if (pdist) *pdist = fabsf( vec.z ); return TRUE; } } @@ -4555,6 +4555,94 @@ D3DXVECTOR3 normal; }; +HRESULT WINAPI D3DXCreatePolygon(struct IDirect3DDevice9 *device, float length, UINT sides, + struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency) +{ + HRESULT hr; + ID3DXMesh *polygon; + struct vertex *vertices; + WORD (*faces)[3]; + DWORD (*adjacency_buf)[3]; + float scale; + unsigned int i; + + TRACE("device %p, length %f, sides %u, mesh %p, adjacency %p.\n", + device, length, sides, mesh, adjacency); + + if (!device || length < 0.0f || sides < 3 || !mesh) + return D3DERR_INVALIDCALL; + + if (FAILED(hr = D3DXCreateMeshFVF(sides, sides + 1, D3DXMESH_MANAGED, + D3DFVF_XYZ | D3DFVF_NORMAL, device, &polygon))) + { + return hr; + } + + if (FAILED(hr = polygon->lpVtbl->LockVertexBuffer(polygon, 0, (void **)&vertices))) + { + polygon->lpVtbl->Release(polygon); + return hr; + } + + if (FAILED(hr = polygon->lpVtbl->LockIndexBuffer(polygon, 0, (void **)&faces))) + { + polygon->lpVtbl->UnlockVertexBuffer(polygon); + polygon->lpVtbl->Release(polygon); + return hr; + } + + scale = 0.5f * length / sinf(D3DX_PI / sides); + + vertices[0].position.x = 0.0f; + vertices[0].position.y = 0.0f; + vertices[0].position.z = 0.0f; + vertices[0].normal.x = 0.0f; + vertices[0].normal.y = 0.0f; + vertices[0].normal.z = 1.0f; + + for (i = 0; i < sides; ++i) + { + vertices[i + 1].position.x = cosf(2.0f * D3DX_PI * i / sides) * scale; + vertices[i + 1].position.y = sinf(2.0f * D3DX_PI * i / sides) * scale; + vertices[i + 1].position.z = 0.0f; + vertices[i + 1].normal.x = 0.0f; + vertices[i + 1].normal.y = 0.0f; + vertices[i + 1].normal.z = 1.0f; + + faces[i][0] = 0; + faces[i][1] = i + 1; + faces[i][2] = i + 2; + } + + faces[sides - 1][2] = 1; + + polygon->lpVtbl->UnlockVertexBuffer(polygon); + polygon->lpVtbl->UnlockIndexBuffer(polygon); + + if (adjacency) + { + if (FAILED(hr = D3DXCreateBuffer(sides * sizeof(DWORD) * 3, adjacency))) + { + polygon->lpVtbl->Release(polygon); + return hr; + } + + adjacency_buf = ID3DXBuffer_GetBufferPointer(*adjacency); + for (i = 0; i < sides; ++i) + { + adjacency_buf[i][0] = i - 1; + adjacency_buf[i][1] = ~0U; + adjacency_buf[i][2] = i + 1; + } + adjacency_buf[0][0] = sides - 1; + adjacency_buf[sides - 1][2] = 0; + } + + *mesh = polygon; + + return D3D_OK; +} + HRESULT WINAPI D3DXCreateBox(struct IDirect3DDevice9 *device, float width, float height, float depth, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency) { diff -Nru wine1.7-1.7.28/dlls/d3dx9_36/surface.c wine1.7-1.7.31/dlls/d3dx9_36/surface.c --- wine1.7-1.7.28/dlls/d3dx9_36/surface.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_36/surface.c 2014-11-14 13:28:17.000000000 +0000 @@ -40,6 +40,7 @@ { &GUID_WICPixelFormat8bppIndexed, D3DFMT_P8 }, { &GUID_WICPixelFormat1bppIndexed, D3DFMT_P8 }, { &GUID_WICPixelFormat4bppIndexed, D3DFMT_P8 }, + { &GUID_WICPixelFormat8bppGray, D3DFMT_L8 }, { &GUID_WICPixelFormat16bppBGR555, D3DFMT_X1R5G5B5 }, { &GUID_WICPixelFormat16bppBGR565, D3DFMT_R5G6B5 }, { &GUID_WICPixelFormat24bppBGR, D3DFMT_R8G8B8 }, diff -Nru wine1.7-1.7.28/dlls/d3dx9_36/tests/mesh.c wine1.7-1.7.31/dlls/d3dx9_36/tests/mesh.c --- wine1.7-1.7.28/dlls/d3dx9_36/tests/mesh.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_36/tests/mesh.c 2014-11-14 13:28:17.000000000 +0000 @@ -1104,6 +1104,9 @@ ok( compare(exp_v,got_v), "Expected v = %f, got %f\n",exp_v,got_v); ok( compare(exp_dist,got_dist), "Expected distance = %f, got %f\n",exp_dist,got_dist); + got_res = D3DXIntersectTri(&vertex[0], &vertex[1], &vertex[2], &position, &ray, NULL, NULL, NULL); + ok(got_res == exp_res, "Expected result = %d, got %d\n", exp_res, got_res); + /*Only positive ray is taken in account*/ vertex[0].x = 1.0f; vertex[0].y = 0.0f; vertex[0].z = 0.0f; @@ -1119,6 +1122,9 @@ got_res = D3DXIntersectTri(&vertex[0],&vertex[1],&vertex[2],&position,&ray,&got_u,&got_v,&got_dist); ok( got_res == exp_res, "Expected result = %d, got %d\n",exp_res,got_res); + got_res = D3DXIntersectTri(&vertex[0], &vertex[1], &vertex[2], &position, &ray, NULL, NULL, NULL); + ok(got_res == exp_res, "Expected result = %d, got %d\n", exp_res, got_res); + /*Intersection between ray and triangle in a same plane is considered as empty*/ vertex[0].x = 4.0f; vertex[0].y = 0.0f; vertex[0].z = 0.0f; @@ -1133,6 +1139,9 @@ got_res = D3DXIntersectTri(&vertex[0],&vertex[1],&vertex[2],&position,&ray,&got_u,&got_v,&got_dist); ok( got_res == exp_res, "Expected result = %d, got %d\n",exp_res,got_res); + + got_res = D3DXIntersectTri(&vertex[0], &vertex[1], &vertex[2], &position, &ray, NULL, NULL, NULL); + ok(got_res == exp_res, "Expected result = %d, got %d\n", exp_res, got_res); } static void D3DXCreateMeshTest(void) @@ -2579,24 +2588,171 @@ hr = D3DXCreateBox(device,10.9f,20.0f,4.9f,&box, &ppBuffer); ok(hr==D3D_OK, "Expected D3D_OK, received %#x\n", hr); - if (FAILED(hr)) - { - skip("D3DXCreateBox failed\n"); - goto end; - } - buffer = ID3DXBuffer_GetBufferPointer(ppBuffer); for(i=0; i<36; i++) ok(adjacency[i]==buffer[i], "expected adjacency %d: %#x, received %#x\n",i,adjacency[i], buffer[i]); box->lpVtbl->Release(box); + ID3DXBuffer_Release(ppBuffer); test_box(device, 10.9f, 20.0f, 4.9f); -end: IDirect3DDevice9_Release(device); IDirect3D9_Release(d3d); - if (ppBuffer) ID3DXBuffer_Release(ppBuffer); + DestroyWindow(wnd); +} + +static BOOL compute_polygon(struct mesh *mesh, float length, unsigned int sides) +{ + unsigned int i; + float scale; + + if (!new_mesh(mesh, sides + 1, sides)) + return FALSE; + + scale = 0.5f * length / sinf(D3DX_PI / sides); + + mesh->vertices[0].position.x = 0.0f; + mesh->vertices[0].position.y = 0.0f; + mesh->vertices[0].position.z = 0.0f; + mesh->vertices[0].normal.x = 0.0f; + mesh->vertices[0].normal.y = 0.0f; + mesh->vertices[0].normal.z = 1.0f; + + for (i = 0; i < sides; ++i) + { + mesh->vertices[i + 1].position.x = cosf(2.0f * D3DX_PI * i / sides) * scale; + mesh->vertices[i + 1].position.y = sinf(2.0f * D3DX_PI * i / sides) * scale; + mesh->vertices[i + 1].position.z = 0.0f; + mesh->vertices[i + 1].normal.x = 0.0f; + mesh->vertices[i + 1].normal.y = 0.0f; + mesh->vertices[i + 1].normal.z = 1.0f; + + mesh->faces[i][0] = 0; + mesh->faces[i][1] = i + 1; + mesh->faces[i][2] = i + 2; + } + + mesh->faces[sides - 1][2] = 1; + + return TRUE; +} + +static void test_polygon(IDirect3DDevice9 *device, float length, unsigned int sides) +{ + HRESULT hr; + ID3DXMesh *polygon; + struct mesh mesh; + char name[64]; + + hr = D3DXCreatePolygon(device, length, sides, &polygon, NULL); + ok(hr == D3D_OK, "Got result %x, expected 0 (D3D_OK)\n", hr); + if (hr != D3D_OK) + { + skip("Couldn't create polygon\n"); + return; + } + + if (!compute_polygon(&mesh, length, sides)) + { + skip("Couldn't create mesh\n"); + polygon->lpVtbl->Release(polygon); + return; + } + + mesh.fvf = D3DFVF_XYZ | D3DFVF_NORMAL; + + sprintf(name, "polygon (%g, %d)", length, sides); + compare_mesh(name, polygon, &mesh); + + free_mesh(&mesh); + + polygon->lpVtbl->Release(polygon); +} + +static void D3DXCreatePolygonTest(void) +{ + HRESULT hr; + HWND wnd; + IDirect3D9 *d3d; + IDirect3DDevice9 *device; + D3DPRESENT_PARAMETERS d3dpp; + ID3DXMesh *polygon; + ID3DXBuffer *adjacency; + DWORD (*buffer)[3], buffer_size; + unsigned int i; + + if (!(wnd = CreateWindowA("static", "d3dx9_test", WS_OVERLAPPEDWINDOW, 0, 0, + 640, 480, NULL, NULL, NULL, NULL))) + { + skip("Couldn't create application window\n"); + return; + } + if (!(d3d = Direct3DCreate9(D3D_SDK_VERSION))) + { + skip("Couldn't create IDirect3D9 object\n"); + DestroyWindow(wnd); + return; + } + + memset(&d3dpp, 0, sizeof(d3dpp)); + d3dpp.Windowed = TRUE; + d3dpp.SwapEffect = D3DSWAPEFFECT_DISCARD; + hr = IDirect3D9_CreateDevice(d3d, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, wnd, + D3DCREATE_SOFTWARE_VERTEXPROCESSING, &d3dpp, &device); + if (FAILED(hr)) + { + skip("Failed to create IDirect3DDevice9 object %#x\n", hr); + IDirect3D9_Release(d3d); + DestroyWindow(wnd); + return; + } + + hr = D3DXCreatePolygon(device, 2.0f, 11, NULL, &adjacency); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, received %#x\n", hr); + + hr = D3DXCreatePolygon(NULL, 2.0f, 11, &polygon, &adjacency); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, received %#x\n", hr); + + hr = D3DXCreatePolygon(device, -2.0f, 11, &polygon, &adjacency); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, received %#x\n", hr); + + polygon = (void *)0xdeadbeef; + adjacency = (void *)0xdeadbeef; + hr = D3DXCreatePolygon(device, 2.0f, 0, &polygon, &adjacency); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, received %#x\n", hr); + ok(polygon == (void *)0xdeadbeef, "Polygon was changed to %p\n", polygon); + ok(adjacency == (void *)0xdeadbeef, "Adjacency was changed to %p\n", adjacency); + + hr = D3DXCreatePolygon(device, 2.0f, 2, &polygon, &adjacency); + ok(hr == D3DERR_INVALIDCALL, "Expected D3DERR_INVALIDCALL, received %#x\n", hr); + + adjacency = NULL; + hr = D3DXCreatePolygon(device, 3.0f, 11, &polygon, &adjacency); + ok(hr == D3D_OK, "Expected D3D_OK, received %#x\n", hr); + + buffer_size = ID3DXBuffer_GetBufferSize(adjacency); + ok(buffer_size == 33 * sizeof(DWORD), "Wrong adjacency buffer size %u\n", buffer_size); + + buffer = ID3DXBuffer_GetBufferPointer(adjacency); + for (i = 0; i < 11; ++i) + { + ok(buffer[i][0] == (i + 10) % 11, "Wrong adjacency[%d][0] = %u\n", i, buffer[i][0]); + ok(buffer[i][1] == ~0U, "Wrong adjacency[%d][1] = %u\n", i, buffer[i][1]); + ok(buffer[i][2] == (i + 1) % 11, "Wrong adjacency[%d][2] = %u\n", i, buffer[i][2]); + } + + polygon->lpVtbl->Release(polygon); + ID3DXBuffer_Release(adjacency); + + test_polygon(device, 2.0f, 3); + test_polygon(device, 10.0f, 3); + test_polygon(device, 10.0f, 5); + test_polygon(device, 10.0f, 10); + test_polygon(device, 20.0f, 10); + + IDirect3DDevice9_Release(device); + IDirect3D9_Release(d3d); DestroyWindow(wnd); } @@ -10458,6 +10614,7 @@ D3DXCreateMeshFVFTest(); D3DXLoadMeshTest(); D3DXCreateBoxTest(); + D3DXCreatePolygonTest(); D3DXCreateSphereTest(); D3DXCreateCylinderTest(); D3DXCreateTextTest(); diff -Nru wine1.7-1.7.28/dlls/d3dx9_36/tests/surface.c wine1.7-1.7.31/dlls/d3dx9_36/tests/surface.c --- wine1.7-1.7.28/dlls/d3dx9_36/tests/surface.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_36/tests/surface.c 2014-11-14 13:28:17.000000000 +0000 @@ -80,6 +80,16 @@ 0x00,0x00 }; +static const unsigned char png_grayscale[] = +{ + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d, 0x49, + 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x08, 0x00, + 0x00, 0x00, 0x00, 0x3a, 0x7e, 0x9b, 0x55, 0x00, 0x00, 0x00, 0x0a, 0x49, 0x44, + 0x41, 0x54, 0x08, 0xd7, 0x63, 0xf8, 0x0f, 0x00, 0x01, 0x01, 0x01, 0x00, 0x1b, + 0xb6, 0xee, 0x56, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, + 0x60, 0x82 +}; + /* 2x2 A8R8G8B8 pixel data */ static const unsigned char pixdata[] = { 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff @@ -493,6 +503,12 @@ ok(info.Depth == 1, "Got depth %u, expected 1\n", info.Depth); ok(info.Format == D3DFMT_P8, "Got format %u, expected %u\n", info.Format, D3DFMT_P8); + /* Grayscale PNG */ + hr = D3DXGetImageInfoFromFileInMemory(png_grayscale, sizeof(png_grayscale), &info); + ok(hr == D3D_OK, "D3DXGetImageInfoFromFileInMemory returned %#x, expected %#x\n", hr, D3D_OK); + ok(info.Depth == 1, "Got depth %u, expected 1\n", info.Depth); + ok(info.Format == D3DFMT_L8, "Got format %u, expected %u\n", info.Format, D3DFMT_L8); + /* test DDS support */ hr = D3DXGetImageInfoFromFileInMemory(dds_24bit, sizeof(dds_24bit), &info); ok(hr == D3D_OK, "D3DXGetImageInfoFromFileInMemory returned %#x, expected %#x\n", hr, D3D_OK); diff -Nru wine1.7-1.7.28/dlls/d3dx9_36/tests/texture.c wine1.7-1.7.31/dlls/d3dx9_36/tests/texture.c --- wine1.7-1.7.28/dlls/d3dx9_36/tests/texture.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_36/tests/texture.c 2014-11-14 13:28:17.000000000 +0000 @@ -87,6 +87,16 @@ 0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x84,0xef,0x7b,0xaa,0xab,0xab,0xab }; +static const unsigned char png_grayscale[] = +{ + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d, 0x49, + 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x08, 0x00, + 0x00, 0x00, 0x00, 0x3a, 0x7e, 0x9b, 0x55, 0x00, 0x00, 0x00, 0x0a, 0x49, 0x44, + 0x41, 0x54, 0x08, 0xd7, 0x63, 0xf8, 0x0f, 0x00, 0x01, 0x01, 0x01, 0x00, 0x1b, + 0xb6, 0xee, 0x56, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, + 0x60, 0x82 +}; + #define ADMITTED_ERROR 0.0001f static inline float relative_error(float expected, float got) @@ -1582,6 +1592,109 @@ D3DUSAGE_DYNAMIC | D3DUSAGE_AUTOGENMIPMAP, D3DFMT_UNKNOWN, D3DPOOL_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, NULL, NULL, &texture); ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x\n", hr, D3D_OK); if (SUCCEEDED(hr)) IDirect3DTexture9_Release(texture); + + /* Checking for color key format overrides. */ + hr = D3DXCreateTextureFromFileInMemoryEx(device, dds_16bit, sizeof(dds_16bit), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_UNKNOWN, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_X1R5G5B5, "Returned format %u, expected %u\n", desc.Format, D3DFMT_X1R5G5B5); + IDirect3DTexture9_Release(texture); + } + hr = D3DXCreateTextureFromFileInMemoryEx(device, dds_16bit, sizeof(dds_16bit), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_UNKNOWN, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0xff000000, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_A1R5G5B5, "Returned format %u, expected %u\n", desc.Format, D3DFMT_A1R5G5B5); + IDirect3DTexture9_Release(texture); + } + hr = D3DXCreateTextureFromFileInMemoryEx(device, dds_16bit, sizeof(dds_16bit), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_X1R5G5B5, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0xff000000, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_X1R5G5B5, "Returned format %u, expected %u\n", desc.Format, D3DFMT_X1R5G5B5); + IDirect3DTexture9_Release(texture); + } + + hr = D3DXCreateTextureFromFileInMemoryEx(device, dds_24bit, sizeof(dds_24bit), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_UNKNOWN, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_X8R8G8B8, "Returned format %u, expected %u\n", desc.Format, D3DFMT_X8R8G8B8); + IDirect3DTexture9_Release(texture); + } + hr = D3DXCreateTextureFromFileInMemoryEx(device, dds_24bit, sizeof(dds_24bit), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_UNKNOWN, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0xff000000, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_A8R8G8B8, "Returned format %u, expected %u\n", desc.Format, D3DFMT_A8R8G8B8); + IDirect3DTexture9_Release(texture); + } + hr = D3DXCreateTextureFromFileInMemoryEx(device, dds_24bit, sizeof(dds_24bit), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_X8R8G8B8, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0xff000000, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_X8R8G8B8, "Returned format %u, expected %u\n", desc.Format, D3DFMT_X8R8G8B8); + IDirect3DTexture9_Release(texture); + } + + hr = D3DXCreateTextureFromFileInMemoryEx(device, png_grayscale, sizeof(png_grayscale), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_UNKNOWN, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_L8, "Returned format %u, expected %u\n", desc.Format, D3DFMT_L8); + IDirect3DTexture9_Release(texture); + } + hr = D3DXCreateTextureFromFileInMemoryEx(device, png_grayscale, sizeof(png_grayscale), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_UNKNOWN, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0xff000000, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_A8L8, "Returned format %u, expected %u\n", desc.Format, D3DFMT_A8L8); + IDirect3DTexture9_Release(texture); + } + hr = D3DXCreateTextureFromFileInMemoryEx(device, png_grayscale, sizeof(png_grayscale), + D3DX_DEFAULT, D3DX_DEFAULT, D3DX_DEFAULT, 0, D3DFMT_L8, D3DPOOL_DEFAULT, + D3DX_DEFAULT, D3DX_DEFAULT, 0xff000000, NULL, NULL, &texture); + ok(hr == D3D_OK, "D3DXCreateTextureFromFileInMemoryEx returned %#x, expected %#x.\n", hr, D3D_OK); + if (SUCCEEDED(hr)) + { + IDirect3DTexture9_GetSurfaceLevel(texture, 0, &surface); + IDirect3DSurface9_GetDesc(surface, &desc); + ok(desc.Format == D3DFMT_L8, "Returned format %u, expected %u\n", desc.Format, D3DFMT_L8); + IDirect3DTexture9_Release(texture); + } } static void test_D3DXCreateCubeTextureFromFileInMemory(IDirect3DDevice9 *device) diff -Nru wine1.7-1.7.28/dlls/d3dx9_36/texture.c wine1.7-1.7.31/dlls/d3dx9_36/texture.c --- wine1.7-1.7.28/dlls/d3dx9_36/texture.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_36/texture.c 2014-11-14 13:28:17.000000000 +0000 @@ -302,12 +302,13 @@ /* This format can be used, let's evaluate it. Weights chosen quite arbitrarily... */ - score = 16 - 4 * (curchannels - channels); + score = 512 * (curfmt->type == fmt->type); + score -= 32 * (curchannels - channels); for (j = 0; j < 4; j++) { int diff = curfmt->bits[j] - fmt->bits[j]; - score += 16 - (diff < 0 ? -diff * 4 : diff); + score -= (diff < 0 ? -diff * 8 : diff) * (j == 0 ? 1 : 2); } if (score > bestscore) @@ -538,6 +539,29 @@ return IDirect3DDevice9_CreateTexture(device, width, height, miplevels, usage, format, pool, texture, NULL); } +static D3DFORMAT get_alpha_replacement_format(D3DFORMAT format) +{ + static const struct + { + D3DFORMAT orig_format; + D3DFORMAT replacement_format; + } + replacement_formats[] = + { + {D3DFMT_X8R8G8B8, D3DFMT_A8R8G8B8}, + {D3DFMT_X1R5G5B5, D3DFMT_A1R5G5B5}, + {D3DFMT_X4R4G4B4, D3DFMT_A4R4G4B4}, + {D3DFMT_X8B8G8R8, D3DFMT_A8B8G8R8}, + {D3DFMT_L8, D3DFMT_A8L8}, + }; + unsigned int i; + + for (i = 0; i < sizeof(replacement_formats) / sizeof(replacement_formats[0]); ++i) + if (replacement_formats[i].orig_format == format) + return replacement_formats[i].replacement_format; + return format; +} + HRESULT WINAPI D3DXCreateTextureFromFileInMemoryEx(struct IDirect3DDevice9 *device, const void *srcdata, UINT srcdatasize, UINT width, UINT height, UINT miplevels, DWORD usage, D3DFORMAT format, D3DPOOL pool, DWORD filter, DWORD mipfilter, D3DCOLOR colorkey, D3DXIMAGE_INFO *srcinfo, @@ -546,7 +570,7 @@ IDirect3DTexture9 **texptr; IDirect3DTexture9 *buftex; IDirect3DSurface9 *surface; - BOOL dynamic_texture; + BOOL dynamic_texture, format_specified = FALSE; D3DXIMAGE_INFO imginfo; UINT loaded_miplevels, skip_levels; D3DCAPS9 caps; @@ -585,6 +609,8 @@ if (format == D3DFMT_UNKNOWN || format == D3DX_DEFAULT) format = imginfo.Format; + else + format_specified = TRUE; if (width == D3DX_FROM_FILE) { @@ -630,6 +656,9 @@ return hr; } + if (colorkey && !format_specified) + format = get_alpha_replacement_format(format); + if (imginfo.MipLevels < miplevels && (D3DFMT_DXT1 <= imginfo.Format && imginfo.Format <= D3DFMT_DXT5)) { FIXME("Generation of mipmaps for compressed pixel formats is not implemented yet\n"); diff -Nru wine1.7-1.7.28/dlls/d3dx9_37/d3dx9_37.spec wine1.7-1.7.31/dlls/d3dx9_37/d3dx9_37.spec --- wine1.7-1.7.28/dlls/d3dx9_37/d3dx9_37.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_37/d3dx9_37.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_38/d3dx9_38.spec wine1.7-1.7.31/dlls/d3dx9_38/d3dx9_38.spec --- wine1.7-1.7.28/dlls/d3dx9_38/d3dx9_38.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_38/d3dx9_38.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_39/d3dx9_39.spec wine1.7-1.7.31/dlls/d3dx9_39/d3dx9_39.spec --- wine1.7-1.7.28/dlls/d3dx9_39/d3dx9_39.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_39/d3dx9_39.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_40/d3dx9_40.spec wine1.7-1.7.31/dlls/d3dx9_40/d3dx9_40.spec --- wine1.7-1.7.28/dlls/d3dx9_40/d3dx9_40.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_40/d3dx9_40.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_41/d3dx9_41.spec wine1.7-1.7.31/dlls/d3dx9_41/d3dx9_41.spec --- wine1.7-1.7.28/dlls/d3dx9_41/d3dx9_41.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_41/d3dx9_41.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_42/d3dx9_42.spec wine1.7-1.7.31/dlls/d3dx9_42/d3dx9_42.spec --- wine1.7-1.7.28/dlls/d3dx9_42/d3dx9_42.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_42/d3dx9_42.spec 2014-11-14 13:28:17.000000000 +0000 @@ -76,7 +76,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dx9_43/d3dx9_43.spec wine1.7-1.7.31/dlls/d3dx9_43/d3dx9_43.spec --- wine1.7-1.7.28/dlls/d3dx9_43/d3dx9_43.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dx9_43/d3dx9_43.spec 2014-11-14 13:28:17.000000000 +0000 @@ -74,7 +74,7 @@ @ stdcall D3DXCreateNPatchMesh(ptr ptr) d3dx9_36.D3DXCreateNPatchMesh @ stdcall D3DXCreatePMeshFromStream(ptr long ptr ptr ptr ptr ptr) d3dx9_36.D3DXCreatePMeshFromStream @ stdcall D3DXCreatePatchMesh(ptr long long long ptr ptr ptr) d3dx9_36.D3DXCreatePatchMesh -@ stdcall D3DXCreatePolygon(ptr long long ptr ptr) d3dx9_36.D3DXCreatePolygon +@ stdcall D3DXCreatePolygon(ptr float long ptr ptr) d3dx9_36.D3DXCreatePolygon @ stdcall D3DXCreatePRTBuffer(long long long ptr) d3dx9_36.D3DXCreatePRTBuffer @ stdcall D3DXCreatePRTBufferTex(long long long long ptr) d3dx9_36.D3DXCreatePRTBufferTex @ stdcall D3DXCreatePRTCompBuffer(long long long ptr ptr ptr ptr) d3dx9_36.D3DXCreatePRTCompBuffer diff -Nru wine1.7-1.7.28/dlls/d3dxof/d3dxof.c wine1.7-1.7.31/dlls/d3dxof/d3dxof.c --- wine1.7-1.7.28/dlls/d3dxof/d3dxof.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/d3dxof/d3dxof.c 2014-11-14 13:28:17.000000000 +0000 @@ -39,7 +39,6 @@ static const struct IDirectXFileDataVtbl IDirectXFileData_Vtbl; static const struct IDirectXFileDataReferenceVtbl IDirectXFileDataReference_Vtbl; static const struct IDirectXFileEnumObjectVtbl IDirectXFileEnumObject_Vtbl; -static const struct IDirectXFileObjectVtbl IDirectXFileObject_Vtbl; static const struct IDirectXFileSaveObjectVtbl IDirectXFileSaveObject_Vtbl; static HRESULT IDirectXFileDataReferenceImpl_Create(IDirectXFileDataReferenceImpl** ppObj); diff -Nru wine1.7-1.7.28/dlls/dbghelp/dwarf.c wine1.7-1.7.31/dlls/dbghelp/dwarf.c --- wine1.7-1.7.28/dlls/dbghelp/dwarf.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dbghelp/dwarf.c 2014-11-14 13:28:17.000000000 +0000 @@ -1453,6 +1453,9 @@ case DW_TAG_subprogram: dwarf2_parse_subprogram(ctx, child); break; + case DW_TAG_const_type: + dwarf2_parse_const_type(ctx, child); + break; case DW_TAG_structure_type: case DW_TAG_class_type: case DW_TAG_union_type: @@ -1464,6 +1467,8 @@ case DW_TAG_variable: case DW_TAG_imported_declaration: case DW_TAG_ptr_to_member_type: + case DW_TAG_GNU_template_parameter_pack: + case DW_TAG_GNU_formal_parameter_pack: /* FIXME: some C++ related stuff */ break; default: @@ -1964,6 +1969,8 @@ case DW_TAG_template_type_param: case DW_TAG_template_value_param: case DW_TAG_GNU_call_site: + case DW_TAG_GNU_template_parameter_pack: + case DW_TAG_GNU_formal_parameter_pack: /* FIXME: no support in dbghelp's internals so far */ break; default: diff -Nru wine1.7-1.7.28/dlls/ddraw/tests/ddraw1.c wine1.7-1.7.31/dlls/ddraw/tests/ddraw1.c --- wine1.7-1.7.28/dlls/ddraw/tests/ddraw1.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ddraw/tests/ddraw1.c 2014-11-14 13:28:17.000000000 +0000 @@ -21,6 +21,8 @@ #include "wine/test.h" #include "d3d.h" +static DEVMODEW registry_mode; + struct create_window_thread_param { HWND window; @@ -2007,7 +2009,7 @@ style = GetWindowLongA(window, GWL_STYLE); exstyle = GetWindowLongA(window, GWL_EXSTYLE); - SetRect(&fullscreen_rect, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN)); + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); @@ -2100,10 +2102,39 @@ return test_proc(hwnd, message, wparam, lparam); } +struct test_coop_level_mode_set_enum_param +{ + DWORD ddraw_width, ddraw_height, user32_width, user32_height; +}; + +static HRESULT CALLBACK test_coop_level_mode_set_enum_cb(DDSURFACEDESC *surface_desc, void *context) +{ + struct test_coop_level_mode_set_enum_param *param = context; + + if (U1(surface_desc->ddpfPixelFormat).dwRGBBitCount != registry_mode.dmBitsPerPel) + return DDENUMRET_OK; + if (surface_desc->dwWidth == registry_mode.dmPelsWidth + && surface_desc->dwHeight == registry_mode.dmPelsHeight) + return DDENUMRET_OK; + + if (!param->ddraw_width) + { + param->ddraw_width = surface_desc->dwWidth; + param->ddraw_height = surface_desc->dwHeight; + return DDENUMRET_OK; + } + if (surface_desc->dwWidth == param->ddraw_width && surface_desc->dwHeight == param->ddraw_height) + return DDENUMRET_OK; + + param->user32_width = surface_desc->dwWidth; + param->user32_height = surface_desc->dwHeight; + return DDENUMRET_CANCEL; +} + static void test_coop_level_mode_set(void) { IDirectDrawSurface *primary; - RECT fullscreen_rect, r, s; + RECT registry_rect, ddraw_rect, user32_rect, r; IDirectDraw *ddraw; DDSURFACEDESC ddsd; WNDCLASSA wc = {0}; @@ -2111,6 +2142,10 @@ HRESULT hr; ULONG ref; MSG msg; + struct test_coop_level_mode_set_enum_param param; + DEVMODEW devmode; + BOOL ret; + LONG change_ret; static const UINT exclusive_messages[] = { @@ -2130,6 +2165,33 @@ ddraw = create_ddraw(); ok(!!ddraw, "Failed to create a ddraw object.\n"); + memset(¶m, 0, sizeof(param)); + hr = IDirectDraw_EnumDisplayModes(ddraw, 0, NULL, ¶m, test_coop_level_mode_set_enum_cb); + ok(SUCCEEDED(hr), "Failed to enumerate display mode, hr %#x.\n", hr); + ref = IDirectDraw_Release(ddraw); + ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); + + if (!param.user32_height) + { + skip("Fewer than 3 different modes supported, skipping mode restore test.\n"); + return; + } + + SetRect(®istry_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); + SetRect(&ddraw_rect, 0, 0, param.ddraw_width, param.ddraw_height); + SetRect(&user32_rect, 0, 0, param.user32_width, param.user32_height); + + memset(&devmode, 0, sizeof(devmode)); + devmode.dmSize = sizeof(devmode); + devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; + devmode.dmPelsWidth = param.user32_width; + devmode.dmPelsHeight = param.user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ddraw = create_ddraw(); + ok(!!ddraw, "Failed to create a ddraw object.\n"); + wc.lpfnWndProc = mode_set_proc; wc.lpszClassName = "ddraw_test_wndproc_wc"; ok(RegisterClassA(&wc), "Failed to register window class.\n"); @@ -2137,15 +2199,12 @@ window = CreateWindowA("ddraw_test_wndproc_wc", "ddraw_test", WS_OVERLAPPEDWINDOW, 0, 0, 100, 100, 0, 0, 0, 0); - SetRect(&fullscreen_rect, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN)); - SetRect(&s, 0, 0, 640, 480); - hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2157,14 +2216,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.user32_width, "Expected surface width %u, got %u.\n", + param.user32_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.user32_height, "Expected surface height %u, got %u.\n", + param.user32_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2172,26 +2231,26 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == s.right && screen_size.cy == s.bottom, + ok(screen_size.cx == param.ddraw_width && screen_size.cy == param.ddraw_height, "Expected screen size %ux%u, got %ux%u.\n", - s.right, s.bottom, screen_size.cx, screen_size.cy); + param.ddraw_width, param.ddraw_height, screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.user32_width, "Expected surface width %u, got %u.\n", + param.user32_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.user32_height, "Expected surface height %u, got %u.\n", + param.user32_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2203,14 +2262,33 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = exclusive_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(screen_size.cx == param.user32_width && screen_size.cy == param.user32_height, + "Expected screen size %ux%u, got %ux%u.\n", + param.user32_width, param.user32_height, screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2221,25 +2299,30 @@ hr = IDirectDraw_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); - ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + todo_wine ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == fullscreen_rect.right && screen_size.cy == fullscreen_rect.bottom, + todo_wine ok(screen_size.cx == registry_mode.dmPelsWidth + && screen_size.cy == registry_mode.dmPelsHeight, "Expected screen size %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size.cx, screen_size.cy); + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + todo_wine ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); + /* For Wine. */ + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2249,30 +2332,30 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2284,14 +2367,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2299,7 +2382,24 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = normal_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); if (hr == DDERR_NOEXCLUSIVEMODE /* NT4 testbot */) { win_skip("Broken SetDisplayMode(), skipping remaining tests.\n"); @@ -2314,16 +2414,16 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2335,14 +2435,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2358,18 +2458,28 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + devmode.dmPelsWidth, devmode.dmPelsHeight); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2379,14 +2489,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); /* DDSCL_NORMAL | DDSCL_FULLSCREEN behaves the same as just DDSCL_NORMAL. @@ -2396,16 +2506,16 @@ ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2417,14 +2527,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2432,7 +2542,27 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; + devmode.dmPelsWidth = param.user32_width; + devmode.dmPelsHeight = param.user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = normal_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2440,16 +2570,16 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2461,14 +2591,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2484,18 +2614,28 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + devmode.dmPelsWidth, devmode.dmPelsHeight); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2505,21 +2645,21 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); /* Unlike ddraw2-7, changing from EXCLUSIVE to NORMAL does not restore the resolution */ hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL); @@ -2534,10 +2674,10 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); hr = IDirectDraw_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); @@ -2546,8 +2686,8 @@ ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); done: @@ -2559,7 +2699,7 @@ static void test_coop_level_mode_set_multi(void) { IDirectDraw *ddraw1, *ddraw2; - UINT orig_w, orig_h, w, h; + UINT w, h; HWND window; HRESULT hr; ULONG ref; @@ -2569,9 +2709,6 @@ ddraw1 = create_ddraw(); ok(!!ddraw1, "Failed to create a ddraw object.\n"); - orig_w = GetSystemMetrics(SM_CXSCREEN); - orig_h = GetSystemMetrics(SM_CYSCREEN); - /* With just a single ddraw object, the display mode is restored on * release. */ hr = set_display_mode(ddraw1, 800, 600); @@ -2591,9 +2728,9 @@ ref = IDirectDraw_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* When there are multiple ddraw objects, the display mode is restored to * the initial mode, before the first SetDisplayMode() call. */ @@ -2616,16 +2753,16 @@ ref = IDirectDraw_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* Regardless of release ordering. */ ddraw1 = create_ddraw(); @@ -2647,16 +2784,16 @@ ref = IDirectDraw_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* But only for ddraw objects that called SetDisplayMode(). */ ddraw1 = create_ddraw(); @@ -2678,9 +2815,9 @@ ref = IDirectDraw_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* If there's a ddraw object that's currently in exclusive mode, it blocks * restoring the display mode. */ @@ -2713,9 +2850,9 @@ ref = IDirectDraw_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* Exclusive mode blocks mode setting on other ddraw objects in general. */ ddraw1 = create_ddraw(); @@ -2736,16 +2873,16 @@ ref = IDirectDraw_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); DestroyWindow(window); } @@ -4217,8 +4354,8 @@ surface_desc.dwSize = sizeof(surface_desc); surface_desc.dwFlags = DDSD_CAPS | DDSD_WIDTH | DDSD_HEIGHT; surface_desc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - surface_desc.dwWidth = GetSystemMetrics(SM_CXSCREEN); - surface_desc.dwHeight = GetSystemMetrics(SM_CYSCREEN); + surface_desc.dwWidth = registry_mode.dmPelsWidth; + surface_desc.dwHeight = registry_mode.dmPelsHeight; hr = IDirectDraw_CreateSurface(ddraw, &surface_desc, &surface2, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -4226,8 +4363,8 @@ surface_desc.dwSize = sizeof(surface_desc); surface_desc.dwFlags = DDSD_CAPS | DDSD_WIDTH | DDSD_HEIGHT; surface_desc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - surface_desc.dwWidth = GetSystemMetrics(SM_CXSCREEN); - surface_desc.dwHeight = GetSystemMetrics(SM_CYSCREEN); + surface_desc.dwWidth = registry_mode.dmPelsWidth; + surface_desc.dwHeight = registry_mode.dmPelsHeight; hr = IDirectDraw_CreateSurface(ddraw, &surface_desc, &surface3, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -5635,6 +5772,7 @@ START_TEST(ddraw1) { IDirectDraw *ddraw; + DEVMODEW current_mode; if (!(ddraw = create_ddraw())) { @@ -5643,6 +5781,18 @@ } IDirectDraw_Release(ddraw); + memset(¤t_mode, 0, sizeof(current_mode)); + current_mode.dmSize = sizeof(current_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, ¤t_mode), "Failed to get display mode.\n"); + registry_mode.dmSize = sizeof(registry_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_REGISTRY_SETTINGS, ®istry_mode), "Failed to get display mode.\n"); + if (registry_mode.dmPelsWidth != current_mode.dmPelsWidth + || registry_mode.dmPelsHeight != current_mode.dmPelsHeight) + { + skip("Current mode does not match registry mode, skipping test.\n"); + return; + } + test_coop_level_create_device_window(); test_clipper_blt(); test_coop_level_d3d_state(); diff -Nru wine1.7-1.7.28/dlls/ddraw/tests/ddraw2.c wine1.7-1.7.31/dlls/ddraw/tests/ddraw2.c --- wine1.7-1.7.28/dlls/ddraw/tests/ddraw2.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ddraw/tests/ddraw2.c 2014-11-14 13:28:17.000000000 +0000 @@ -21,6 +21,8 @@ #include "wine/test.h" #include "d3d.h" +static DEVMODEW registry_mode; + struct create_window_thread_param { HWND window; @@ -2195,7 +2197,7 @@ style = GetWindowLongA(window, GWL_STYLE); exstyle = GetWindowLongA(window, GWL_EXSTYLE); - SetRect(&fullscreen_rect, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN)); + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); @@ -2299,10 +2301,39 @@ return test_proc(hwnd, message, wparam, lparam); } +struct test_coop_level_mode_set_enum_param +{ + DWORD ddraw_width, ddraw_height, user32_width, user32_height; +}; + +static HRESULT CALLBACK test_coop_level_mode_set_enum_cb(DDSURFACEDESC *surface_desc, void *context) +{ + struct test_coop_level_mode_set_enum_param *param = context; + + if (U1(surface_desc->ddpfPixelFormat).dwRGBBitCount != registry_mode.dmBitsPerPel) + return DDENUMRET_OK; + if (surface_desc->dwWidth == registry_mode.dmPelsWidth + && surface_desc->dwHeight == registry_mode.dmPelsHeight) + return DDENUMRET_OK; + + if (!param->ddraw_width) + { + param->ddraw_width = surface_desc->dwWidth; + param->ddraw_height = surface_desc->dwHeight; + return DDENUMRET_OK; + } + if (surface_desc->dwWidth == param->ddraw_width && surface_desc->dwHeight == param->ddraw_height) + return DDENUMRET_OK; + + param->user32_width = surface_desc->dwWidth; + param->user32_height = surface_desc->dwHeight; + return DDENUMRET_CANCEL; +} + static void test_coop_level_mode_set(void) { IDirectDrawSurface *primary; - RECT fullscreen_rect, r, s; + RECT registry_rect, ddraw_rect, user32_rect, r; IDirectDraw2 *ddraw; DDSURFACEDESC ddsd; WNDCLASSA wc = {0}; @@ -2310,6 +2341,10 @@ HRESULT hr; ULONG ref; MSG msg; + struct test_coop_level_mode_set_enum_param param; + DEVMODEW devmode; + BOOL ret; + LONG change_ret; static const UINT exclusive_messages[] = { @@ -2329,6 +2364,33 @@ ddraw = create_ddraw(); ok(!!ddraw, "Failed to create a ddraw object.\n"); + memset(¶m, 0, sizeof(param)); + hr = IDirectDraw2_EnumDisplayModes(ddraw, 0, NULL, ¶m, test_coop_level_mode_set_enum_cb); + ok(SUCCEEDED(hr), "Failed to enumerate display mode, hr %#x.\n", hr); + ref = IDirectDraw2_Release(ddraw); + ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); + + if (!param.user32_height) + { + skip("Fewer than 3 different modes supported, skipping mode restore test.\n"); + return; + } + + SetRect(®istry_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); + SetRect(&ddraw_rect, 0, 0, param.ddraw_width, param.ddraw_height); + SetRect(&user32_rect, 0, 0, param.user32_width, param.user32_height); + + memset(&devmode, 0, sizeof(devmode)); + devmode.dmSize = sizeof(devmode); + devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; + devmode.dmPelsWidth = param.user32_width; + devmode.dmPelsHeight = param.user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ddraw = create_ddraw(); + ok(!!ddraw, "Failed to create a ddraw object.\n"); + wc.lpfnWndProc = mode_set_proc; wc.lpszClassName = "ddraw_test_wndproc_wc"; ok(RegisterClassA(&wc), "Failed to register window class.\n"); @@ -2341,15 +2403,12 @@ window2 = CreateWindowA("ddraw_test_wndproc_wc2", "ddraw_test", WS_OVERLAPPEDWINDOW, 0, 0, 100, 100, 0, 0, 0, 0); - SetRect(&fullscreen_rect, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN)); - SetRect(&s, 0, 0, 640, 480); - hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2361,14 +2420,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.user32_width, "Expected surface width %u, got %u.\n", + param.user32_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.user32_height, "Expected surface height %u, got %u.\n", + param.user32_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2376,26 +2435,26 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == s.right && screen_size.cy == s.bottom, + ok(screen_size.cx == param.ddraw_width && screen_size.cy == param.ddraw_height, "Expected screen size %ux%u, got %ux%u.\n", - s.right, s.bottom, screen_size.cx, screen_size.cy); + param.ddraw_width, param.ddraw_height, screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.user32_width, "Expected surface width %u, got %u.\n", + param.user32_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.user32_height, "Expected surface height %u, got %u.\n", + param.user32_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2407,14 +2466,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2422,28 +2481,52 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = IDirectDraw_RestoreDisplayMode(ddraw); - ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == fullscreen_rect.right && screen_size.cy == fullscreen_rect.bottom, + ok(screen_size.cx == param.user32_width && screen_size.cy == param.user32_height, "Expected screen size %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size.cx, screen_size.cy); + param.user32_width, param.user32_height, screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = exclusive_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = IDirectDraw2_RestoreDisplayMode(ddraw); + ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); + + todo_wine ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + todo_wine ok(screen_size.cx == registry_mode.dmPelsWidth + && screen_size.cy == registry_mode.dmPelsHeight, + "Expected screen size %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + todo_wine ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); + /* For Wine. */ + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2453,30 +2536,30 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2488,14 +2571,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2503,7 +2586,24 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = normal_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); if (hr == DDERR_NOEXCLUSIVEMODE /* NT4 testbot */) { win_skip("Broken SetDisplayMode(), skipping remaining tests.\n"); @@ -2518,16 +2618,16 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2539,14 +2639,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2562,18 +2662,28 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + devmode.dmPelsWidth, devmode.dmPelsHeight); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2583,14 +2693,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); /* DDSCL_NORMAL | DDSCL_FULLSCREEN behaves the same as just DDSCL_NORMAL. @@ -2600,16 +2710,16 @@ ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2621,14 +2731,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2636,7 +2746,27 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; + devmode.dmPelsWidth = param.user32_width; + devmode.dmPelsHeight = param.user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = normal_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2644,16 +2774,16 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2665,14 +2795,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2680,7 +2810,7 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = IDirectDraw_RestoreDisplayMode(ddraw); + hr = IDirectDraw2_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2688,18 +2818,28 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + devmode.dmPelsWidth, devmode.dmPelsHeight); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2709,21 +2849,21 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); /* Changing the coop level from EXCLUSIVE to NORMAL restores the screen resolution */ hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2736,13 +2876,15 @@ ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == fullscreen_rect.right && screen_size.cy == fullscreen_rect.bottom, + ok(screen_size.cx == registry_mode.dmPelsWidth + && screen_size.cy == registry_mode.dmPelsHeight, "Expected screen size %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size.cx, screen_size.cy); + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2754,16 +2896,16 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); /* The screen restore is a property of DDSCL_EXCLUSIVE */ hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL); @@ -2778,19 +2920,19 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface_Release(primary); - hr = IDirectDraw_RestoreDisplayMode(ddraw); + hr = IDirectDraw2_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); /* If the window is changed at the same time, messages are sent to the new window. */ hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2807,17 +2949,17 @@ expect_messages = NULL; ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); - ok(screen_size2.cx == fullscreen_rect.right && screen_size2.cy == fullscreen_rect.bottom, + ok(screen_size2.cx == registry_mode.dmPelsWidth && screen_size2.cy == registry_mode.dmPelsHeight, "Expected screen size 2 %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size2.cx, screen_size2.cy); + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, screen_size2.cx, screen_size2.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); GetWindowRect(window2, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2829,18 +2971,18 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface_Release(primary); ref = IDirectDraw2_Release(ddraw); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); done: @@ -2854,7 +2996,7 @@ static void test_coop_level_mode_set_multi(void) { IDirectDraw2 *ddraw1, *ddraw2; - UINT orig_w, orig_h, w, h; + UINT w, h; HWND window; HRESULT hr; ULONG ref; @@ -2864,9 +3006,6 @@ ddraw1 = create_ddraw(); ok(!!ddraw1, "Failed to create a ddraw object.\n"); - orig_w = GetSystemMetrics(SM_CXSCREEN); - orig_h = GetSystemMetrics(SM_CYSCREEN); - /* With just a single ddraw object, the display mode is restored on * release. */ hr = set_display_mode(ddraw1, 800, 600); @@ -2886,9 +3025,9 @@ ref = IDirectDraw2_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* When there are multiple ddraw objects, the display mode is restored to * the initial mode, before the first SetDisplayMode() call. */ @@ -2911,16 +3050,16 @@ ref = IDirectDraw2_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw2_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* Regardless of release ordering. */ ddraw1 = create_ddraw(); @@ -2942,16 +3081,16 @@ ref = IDirectDraw2_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw2_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* But only for ddraw objects that called SetDisplayMode(). */ ddraw1 = create_ddraw(); @@ -2973,9 +3112,9 @@ ref = IDirectDraw2_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* If there's a ddraw object that's currently in exclusive mode, it blocks * restoring the display mode. */ @@ -3008,9 +3147,9 @@ ref = IDirectDraw2_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* Exclusive mode blocks mode setting on other ddraw objects in general. */ ddraw1 = create_ddraw(); @@ -3031,16 +3170,16 @@ ref = IDirectDraw2_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw2_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); DestroyWindow(window); } @@ -5293,8 +5432,8 @@ surface_desc.dwSize = sizeof(surface_desc); surface_desc.dwFlags = DDSD_CAPS | DDSD_WIDTH | DDSD_HEIGHT; surface_desc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - surface_desc.dwWidth = GetSystemMetrics(SM_CXSCREEN); - surface_desc.dwHeight = GetSystemMetrics(SM_CYSCREEN); + surface_desc.dwWidth = registry_mode.dmPelsWidth; + surface_desc.dwHeight = registry_mode.dmPelsHeight; hr = IDirectDraw2_CreateSurface(ddraw, &surface_desc, &surface2, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -5302,8 +5441,8 @@ surface_desc.dwSize = sizeof(surface_desc); surface_desc.dwFlags = DDSD_CAPS | DDSD_WIDTH | DDSD_HEIGHT; surface_desc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - surface_desc.dwWidth = GetSystemMetrics(SM_CXSCREEN); - surface_desc.dwHeight = GetSystemMetrics(SM_CYSCREEN); + surface_desc.dwWidth = registry_mode.dmPelsWidth; + surface_desc.dwHeight = registry_mode.dmPelsHeight; hr = IDirectDraw2_CreateSurface(ddraw, &surface_desc, &surface3, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -6711,6 +6850,7 @@ START_TEST(ddraw2) { IDirectDraw2 *ddraw; + DEVMODEW current_mode; if (!(ddraw = create_ddraw())) { @@ -6719,6 +6859,18 @@ } IDirectDraw2_Release(ddraw); + memset(¤t_mode, 0, sizeof(current_mode)); + current_mode.dmSize = sizeof(current_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, ¤t_mode), "Failed to get display mode.\n"); + registry_mode.dmSize = sizeof(registry_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_REGISTRY_SETTINGS, ®istry_mode), "Failed to get display mode.\n"); + if (registry_mode.dmPelsWidth != current_mode.dmPelsWidth + || registry_mode.dmPelsHeight != current_mode.dmPelsHeight) + { + skip("Current mode does not match registry mode, skipping test.\n"); + return; + } + test_coop_level_create_device_window(); test_clipper_blt(); test_coop_level_d3d_state(); diff -Nru wine1.7-1.7.28/dlls/ddraw/tests/ddraw4.c wine1.7-1.7.31/dlls/ddraw/tests/ddraw4.c --- wine1.7-1.7.28/dlls/ddraw/tests/ddraw4.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ddraw/tests/ddraw4.c 2014-11-14 13:28:17.000000000 +0000 @@ -22,6 +22,8 @@ #include #include "d3d.h" +static DEVMODEW registry_mode; + struct vec2 { float x, y; @@ -2382,7 +2384,7 @@ style = GetWindowLongA(window, GWL_STYLE); exstyle = GetWindowLongA(window, GWL_EXSTYLE); - SetRect(&fullscreen_rect, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN)); + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); @@ -2486,10 +2488,39 @@ return test_proc(hwnd, message, wparam, lparam); } +struct test_coop_level_mode_set_enum_param +{ + DWORD ddraw_width, ddraw_height, user32_width, user32_height; +}; + +static HRESULT CALLBACK test_coop_level_mode_set_enum_cb(DDSURFACEDESC2 *surface_desc, void *context) +{ + struct test_coop_level_mode_set_enum_param *param = context; + + if (U1(U4(surface_desc)->ddpfPixelFormat).dwRGBBitCount != registry_mode.dmBitsPerPel) + return DDENUMRET_OK; + if (surface_desc->dwWidth == registry_mode.dmPelsWidth + && surface_desc->dwHeight == registry_mode.dmPelsHeight) + return DDENUMRET_OK; + + if (!param->ddraw_width) + { + param->ddraw_width = surface_desc->dwWidth; + param->ddraw_height = surface_desc->dwHeight; + return DDENUMRET_OK; + } + if (surface_desc->dwWidth == param->ddraw_width && surface_desc->dwHeight == param->ddraw_height) + return DDENUMRET_OK; + + param->user32_width = surface_desc->dwWidth; + param->user32_height = surface_desc->dwHeight; + return DDENUMRET_CANCEL; +} + static void test_coop_level_mode_set(void) { IDirectDrawSurface4 *primary; - RECT fullscreen_rect, r, s; + RECT registry_rect, ddraw_rect, user32_rect, r; IDirectDraw4 *ddraw; DDSURFACEDESC2 ddsd; WNDCLASSA wc = {0}; @@ -2497,6 +2528,10 @@ HRESULT hr; ULONG ref; MSG msg; + struct test_coop_level_mode_set_enum_param param; + DEVMODEW devmode; + BOOL ret; + LONG change_ret; static const UINT exclusive_messages[] = { @@ -2516,6 +2551,33 @@ ddraw = create_ddraw(); ok(!!ddraw, "Failed to create a ddraw object.\n"); + memset(¶m, 0, sizeof(param)); + hr = IDirectDraw4_EnumDisplayModes(ddraw, 0, NULL, ¶m, test_coop_level_mode_set_enum_cb); + ok(SUCCEEDED(hr), "Failed to enumerate display mode, hr %#x.\n", hr); + ref = IDirectDraw4_Release(ddraw); + ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); + + if (!param.user32_height) + { + skip("Fewer than 3 different modes supported, skipping mode restore test.\n"); + return; + } + + SetRect(®istry_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); + SetRect(&ddraw_rect, 0, 0, param.ddraw_width, param.ddraw_height); + SetRect(&user32_rect, 0, 0, param.user32_width, param.user32_height); + + memset(&devmode, 0, sizeof(devmode)); + devmode.dmSize = sizeof(devmode); + devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; + devmode.dmPelsWidth = param.user32_width; + devmode.dmPelsHeight = param.user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ddraw = create_ddraw(); + ok(!!ddraw, "Failed to create a ddraw object.\n"); + wc.lpfnWndProc = mode_set_proc; wc.lpszClassName = "ddraw_test_wndproc_wc"; ok(RegisterClassA(&wc), "Failed to register window class.\n"); @@ -2528,15 +2590,12 @@ window2 = CreateWindowA("ddraw_test_wndproc_wc2", "ddraw_test", WS_OVERLAPPEDWINDOW, 0, 0, 100, 100, 0, 0, 0, 0); - SetRect(&fullscreen_rect, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN)); - SetRect(&s, 0, 0, 640, 480); - hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2548,14 +2607,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.user32_width, "Expected surface width %u, got %u.\n", + param.user32_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.user32_height, "Expected surface height %u, got %u.\n", + param.user32_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2563,26 +2622,26 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == s.right && screen_size.cy == s.bottom, + ok(screen_size.cx == param.ddraw_width && screen_size.cy == param.ddraw_height, "Expected screen size %ux%u, got %ux%u.\n", - s.right, s.bottom, screen_size.cx, screen_size.cy); + param.ddraw_width, param.ddraw_height, screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.user32_width, "Expected surface width %u, got %u.\n", + param.user32_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.user32_height, "Expected surface height %u, got %u.\n", + param.user32_height, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2594,14 +2653,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2609,28 +2668,52 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = IDirectDraw_RestoreDisplayMode(ddraw); - ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == fullscreen_rect.right && screen_size.cy == fullscreen_rect.bottom, + ok(screen_size.cx == param.user32_width && screen_size.cy == param.user32_height, "Expected screen size %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size.cx, screen_size.cy); + param.user32_width, param.user32_height, screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = exclusive_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = IDirectDraw4_RestoreDisplayMode(ddraw); + ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); + + todo_wine ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + todo_wine ok(screen_size.cx == registry_mode.dmPelsWidth + && screen_size.cy == registry_mode.dmPelsHeight, + "Expected screen size %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + todo_wine ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); + /* For Wine. */ + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2640,30 +2723,30 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2675,14 +2758,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2690,7 +2773,24 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = normal_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2698,16 +2798,16 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2719,14 +2819,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2734,7 +2834,7 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = IDirectDraw_RestoreDisplayMode(ddraw); + hr = IDirectDraw4_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2742,18 +2842,28 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + devmode.dmPelsWidth, devmode.dmPelsHeight); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2763,14 +2873,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); /* DDSCL_NORMAL | DDSCL_FULLSCREEN behaves the same as just DDSCL_NORMAL. @@ -2780,16 +2890,16 @@ ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2801,14 +2911,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2816,7 +2926,27 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; + devmode.dmPelsWidth = param.user32_width; + devmode.dmPelsHeight = param.user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = normal_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2824,16 +2954,16 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2845,14 +2975,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2860,7 +2990,7 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = IDirectDraw_RestoreDisplayMode(ddraw); + hr = IDirectDraw4_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2868,18 +2998,28 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + devmode.dmPelsWidth, devmode.dmPelsHeight); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2889,21 +3029,21 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface4_Release(primary); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); /* Changing the coop level from EXCLUSIVE to NORMAL restores the screen resolution */ hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2916,13 +3056,15 @@ ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == fullscreen_rect.right && screen_size.cy == fullscreen_rect.bottom, + ok(screen_size.cx == registry_mode.dmPelsWidth + && screen_size.cy == registry_mode.dmPelsHeight, "Expected screen size %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size.cx, screen_size.cy); + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2932,18 +3074,18 @@ hr = IDirectDraw4_CreateSurface(ddraw, &ddsd, &primary, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); - hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); + hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); - IDirectDrawSurface_Release(primary); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); + IDirectDrawSurface4_Release(primary); /* The screen restore is a property of DDSCL_EXCLUSIVE */ hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL); @@ -2956,21 +3098,21 @@ hr = IDirectDraw4_CreateSurface(ddraw, &ddsd, &primary, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); - hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); + hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); - IDirectDrawSurface_Release(primary); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); + IDirectDrawSurface4_Release(primary); - hr = IDirectDraw_RestoreDisplayMode(ddraw); + hr = IDirectDraw4_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); /* If the window is changed at the same time, messages are sent to the new window. */ hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2987,17 +3129,17 @@ expect_messages = NULL; ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); - ok(screen_size2.cx == fullscreen_rect.right && screen_size2.cy == fullscreen_rect.bottom, + ok(screen_size2.cx == registry_mode.dmPelsWidth && screen_size2.cy == registry_mode.dmPelsHeight, "Expected screen size 2 %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size2.cx, screen_size2.cy); + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, screen_size2.cx, screen_size2.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); GetWindowRect(window2, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -3007,20 +3149,20 @@ hr = IDirectDraw4_CreateSurface(ddraw, &ddsd, &primary, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); - hr = IDirectDrawSurface_GetSurfaceDesc(primary, &ddsd); + hr = IDirectDrawSurface4_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); - IDirectDrawSurface_Release(primary); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); + IDirectDrawSurface4_Release(primary); ref = IDirectDraw4_Release(ddraw); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); expect_messages = NULL; @@ -3033,7 +3175,7 @@ static void test_coop_level_mode_set_multi(void) { IDirectDraw4 *ddraw1, *ddraw2; - UINT orig_w, orig_h, w, h; + UINT w, h; HWND window; HRESULT hr; ULONG ref; @@ -3043,9 +3185,6 @@ ddraw1 = create_ddraw(); ok(!!ddraw1, "Failed to create a ddraw object.\n"); - orig_w = GetSystemMetrics(SM_CXSCREEN); - orig_h = GetSystemMetrics(SM_CYSCREEN); - /* With just a single ddraw object, the display mode is restored on * release. */ hr = set_display_mode(ddraw1, 800, 600); @@ -3058,9 +3197,9 @@ ref = IDirectDraw4_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* When there are multiple ddraw objects, the display mode is restored to * the initial mode, before the first SetDisplayMode() call. */ @@ -3083,16 +3222,16 @@ ref = IDirectDraw4_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw4_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* Regardless of release ordering. */ ddraw1 = create_ddraw(); @@ -3114,16 +3253,16 @@ ref = IDirectDraw4_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw4_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* But only for ddraw objects that called SetDisplayMode(). */ ddraw1 = create_ddraw(); @@ -3145,9 +3284,9 @@ ref = IDirectDraw4_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* If there's a ddraw object that's currently in exclusive mode, it blocks * restoring the display mode. */ @@ -3180,9 +3319,9 @@ ref = IDirectDraw4_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* Exclusive mode blocks mode setting on other ddraw objects in general. */ ddraw1 = create_ddraw(); @@ -3203,16 +3342,16 @@ ref = IDirectDraw4_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw4_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); DestroyWindow(window); } @@ -6075,8 +6214,8 @@ surface_desc.dwSize = sizeof(surface_desc); surface_desc.dwFlags = DDSD_CAPS | DDSD_WIDTH | DDSD_HEIGHT; surface_desc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - surface_desc.dwWidth = GetSystemMetrics(SM_CXSCREEN); - surface_desc.dwHeight = GetSystemMetrics(SM_CYSCREEN); + surface_desc.dwWidth = registry_mode.dmPelsWidth; + surface_desc.dwHeight = registry_mode.dmPelsHeight; hr = IDirectDraw4_CreateSurface(ddraw, &surface_desc, &surface2, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -6084,8 +6223,8 @@ surface_desc.dwSize = sizeof(surface_desc); surface_desc.dwFlags = DDSD_CAPS | DDSD_WIDTH | DDSD_HEIGHT; surface_desc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - surface_desc.dwWidth = GetSystemMetrics(SM_CXSCREEN); - surface_desc.dwHeight = GetSystemMetrics(SM_CYSCREEN); + surface_desc.dwWidth = registry_mode.dmPelsWidth; + surface_desc.dwHeight = registry_mode.dmPelsHeight; hr = IDirectDraw4_CreateSurface(ddraw, &surface_desc, &surface3, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -7786,6 +7925,7 @@ START_TEST(ddraw4) { IDirectDraw4 *ddraw; + DEVMODEW current_mode; if (!(ddraw = create_ddraw())) { @@ -7794,6 +7934,18 @@ } IDirectDraw4_Release(ddraw); + memset(¤t_mode, 0, sizeof(current_mode)); + current_mode.dmSize = sizeof(current_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, ¤t_mode), "Failed to get display mode.\n"); + registry_mode.dmSize = sizeof(registry_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_REGISTRY_SETTINGS, ®istry_mode), "Failed to get display mode.\n"); + if (registry_mode.dmPelsWidth != current_mode.dmPelsWidth + || registry_mode.dmPelsHeight != current_mode.dmPelsHeight) + { + skip("Current mode does not match registry mode, skipping test.\n"); + return; + } + test_process_vertices(); test_coop_level_create_device_window(); test_clipper_blt(); diff -Nru wine1.7-1.7.28/dlls/ddraw/tests/ddraw7.c wine1.7-1.7.31/dlls/ddraw/tests/ddraw7.c --- wine1.7-1.7.28/dlls/ddraw/tests/ddraw7.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ddraw/tests/ddraw7.c 2014-11-14 13:28:17.000000000 +0000 @@ -23,6 +23,7 @@ #include "d3d.h" static HRESULT (WINAPI *pDirectDrawCreateEx)(GUID *guid, void **ddraw, REFIID iid, IUnknown *outer_unknown); +static DEVMODEW registry_mode; struct vec2 { @@ -2061,7 +2062,7 @@ style = GetWindowLongA(window, GWL_STYLE); exstyle = GetWindowLongA(window, GWL_EXSTYLE); - SetRect(&fullscreen_rect, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN)); + SetRect(&fullscreen_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); @@ -2164,10 +2165,39 @@ return test_proc(hwnd, message, wparam, lparam); } +struct test_coop_level_mode_set_enum_param +{ + DWORD ddraw_width, ddraw_height, user32_width, user32_height; +}; + +static HRESULT CALLBACK test_coop_level_mode_set_enum_cb(DDSURFACEDESC2 *surface_desc, void *context) +{ + struct test_coop_level_mode_set_enum_param *param = context; + + if (U1(U4(surface_desc)->ddpfPixelFormat).dwRGBBitCount != registry_mode.dmBitsPerPel) + return DDENUMRET_OK; + if (surface_desc->dwWidth == registry_mode.dmPelsWidth + && surface_desc->dwHeight == registry_mode.dmPelsHeight) + return DDENUMRET_OK; + + if (!param->ddraw_width) + { + param->ddraw_width = surface_desc->dwWidth; + param->ddraw_height = surface_desc->dwHeight; + return DDENUMRET_OK; + } + if (surface_desc->dwWidth == param->ddraw_width && surface_desc->dwHeight == param->ddraw_height) + return DDENUMRET_OK; + + param->user32_width = surface_desc->dwWidth; + param->user32_height = surface_desc->dwHeight; + return DDENUMRET_CANCEL; +} + static void test_coop_level_mode_set(void) { IDirectDrawSurface7 *primary; - RECT fullscreen_rect, r, s; + RECT registry_rect, ddraw_rect, user32_rect, r; IDirectDraw7 *ddraw; DDSURFACEDESC2 ddsd; WNDCLASSA wc = {0}; @@ -2175,6 +2205,10 @@ HRESULT hr; ULONG ref; MSG msg; + struct test_coop_level_mode_set_enum_param param; + DEVMODEW devmode; + BOOL ret; + LONG change_ret; static const UINT exclusive_messages[] = { @@ -2194,6 +2228,33 @@ ddraw = create_ddraw(); ok(!!ddraw, "Failed to create a ddraw object.\n"); + memset(¶m, 0, sizeof(param)); + hr = IDirectDraw7_EnumDisplayModes(ddraw, 0, NULL, ¶m, test_coop_level_mode_set_enum_cb); + ok(SUCCEEDED(hr), "Failed to enumerate display mode, hr %#x.\n", hr); + ref = IDirectDraw7_Release(ddraw); + ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); + + if (!param.user32_height) + { + skip("Fewer than 3 different modes supported, skipping mode restore test.\n"); + return; + } + + SetRect(®istry_rect, 0, 0, registry_mode.dmPelsWidth, registry_mode.dmPelsHeight); + SetRect(&ddraw_rect, 0, 0, param.ddraw_width, param.ddraw_height); + SetRect(&user32_rect, 0, 0, param.user32_width, param.user32_height); + + memset(&devmode, 0, sizeof(devmode)); + devmode.dmSize = sizeof(devmode); + devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; + devmode.dmPelsWidth = param.user32_width; + devmode.dmPelsHeight = param.user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ddraw = create_ddraw(); + ok(!!ddraw, "Failed to create a ddraw object.\n"); + wc.lpfnWndProc = mode_set_proc; wc.lpszClassName = "ddraw_test_wndproc_wc"; ok(RegisterClassA(&wc), "Failed to register window class.\n"); @@ -2206,15 +2267,12 @@ window2 = CreateWindowA("ddraw_test_wndproc_wc2", "ddraw_test", WS_OVERLAPPEDWINDOW, 0, 0, 100, 100, 0, 0, 0, 0); - SetRect(&fullscreen_rect, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN)); - SetRect(&s, 0, 0, 640, 480); - hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2226,14 +2284,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.user32_width, "Expected surface width %u, got %u.\n", + param.user32_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.user32_height, "Expected surface height %u, got %u.\n", + param.user32_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2241,26 +2299,26 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == s.right && screen_size.cy == s.bottom, + ok(screen_size.cx == param.ddraw_width && screen_size.cy == param.ddraw_height, "Expected screen size %ux%u, got %ux%u.\n", - s.right, s.bottom, screen_size.cx, screen_size.cy); + param.ddraw_width, param.ddraw_height, screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.user32_width, "Expected surface width %u, got %u.\n", + param.user32_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.user32_height, "Expected surface height %u, got %u.\n", + param.user32_height, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2272,14 +2330,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2287,28 +2345,52 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = IDirectDraw_RestoreDisplayMode(ddraw); - ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == fullscreen_rect.right && screen_size.cy == fullscreen_rect.bottom, + ok(screen_size.cx == param.user32_width && screen_size.cy == param.user32_height, "Expected screen size %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size.cx, screen_size.cy); + param.user32_width, param.user32_height, screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, &user32_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + user32_rect.left, user32_rect.top, user32_rect.right, user32_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = exclusive_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = IDirectDraw7_RestoreDisplayMode(ddraw); + ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); + + todo_wine ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + todo_wine ok(screen_size.cx == registry_mode.dmPelsWidth + && screen_size.cy == registry_mode.dmPelsHeight, + "Expected screen size %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + todo_wine ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); + /* For Wine. */ + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2318,30 +2400,30 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2353,14 +2435,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2368,7 +2450,24 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = normal_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2376,16 +2475,16 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2397,14 +2496,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2420,18 +2519,28 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + devmode.dmPelsWidth, devmode.dmPelsHeight); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2441,14 +2550,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); /* DDSCL_NORMAL | DDSCL_FULLSCREEN behaves the same as just DDSCL_NORMAL. @@ -2458,16 +2567,16 @@ ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2479,14 +2588,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2494,7 +2603,27 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = set_display_mode(ddraw, 640, 480); + devmode.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT; + devmode.dmPelsWidth = param.user32_width; + devmode.dmPelsHeight = param.user32_height; + change_ret = ChangeDisplaySettingsW(&devmode, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + + ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); + expect_messages = NULL; + ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); + + GetWindowRect(window, &r); + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, + r.left, r.top, r.right, r.bottom); + + PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); + expect_messages = normal_messages; + screen_size.cx = 0; + screen_size.cy = 0; + + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2502,16 +2631,16 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); memset(&ddsd, 0, sizeof(ddsd)); @@ -2523,14 +2652,14 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2538,7 +2667,7 @@ screen_size.cx = 0; screen_size.cy = 0; - hr = IDirectDraw_RestoreDisplayMode(ddraw); + hr = IDirectDraw7_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); @@ -2546,18 +2675,28 @@ ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); + ret = EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, &devmode); + ok(ret, "Failed to get display mode.\n"); + todo_wine ok(devmode.dmPelsWidth == registry_mode.dmPelsWidth + && devmode.dmPelsHeight == registry_mode.dmPelsHeight, + "Expected resolution %ux%u, got %ux%u.\n", + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + devmode.dmPelsWidth, devmode.dmPelsHeight); + change_ret = ChangeDisplaySettingsW(NULL, CDS_FULLSCREEN); + ok(change_ret == DISP_CHANGE_SUCCESSFUL, "Failed to change display mode, ret %#x.\n", change_ret); + memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd); ddsd.dwFlags = DDSD_CAPS; @@ -2567,21 +2706,21 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); /* Changing the coop level from EXCLUSIVE to NORMAL restores the screen resolution */ hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2594,13 +2733,15 @@ ok(!*expect_messages, "Expected message %#x, but didn't receive it.\n", *expect_messages); expect_messages = NULL; - ok(screen_size.cx == fullscreen_rect.right && screen_size.cy == fullscreen_rect.bottom, + ok(screen_size.cx == registry_mode.dmPelsWidth + && screen_size.cy == registry_mode.dmPelsHeight, "Expected screen size %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size.cx, screen_size.cy); + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, + screen_size.cx, screen_size.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2612,16 +2753,16 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); /* The screen restore is a property of DDSCL_EXCLUSIVE */ hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL); @@ -2636,19 +2777,19 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == s.right - s.left, "Expected surface width %u, got %u.\n", - s.right - s.left, ddsd.dwWidth); - ok(ddsd.dwHeight == s.bottom - s.top, "Expected surface height %u, got %u.\n", - s.bottom - s.top, ddsd.dwHeight); + ok(ddsd.dwWidth == param.ddraw_width, "Expected surface width %u, got %u.\n", + param.ddraw_width, ddsd.dwWidth); + ok(ddsd.dwHeight == param.ddraw_height, "Expected surface height %u, got %u.\n", + param.ddraw_height, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); - hr = IDirectDraw_RestoreDisplayMode(ddraw); + hr = IDirectDraw7_RestoreDisplayMode(ddraw); ok(SUCCEEDED(hr), "RestoreDisplayMode failed, hr %#x.\n", hr); /* If the window is changed at the same time, messages are sent to the new window. */ hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN); ok(SUCCEEDED(hr), "SetCooperativeLevel failed, hr %#x.\n", hr); - hr = set_display_mode(ddraw, 640, 480); + hr = set_display_mode(ddraw, param.ddraw_width, param.ddraw_height); ok(SUCCEEDED(hr), "Failed to set display mode, hr %#x.\n", hr); PeekMessageA(&msg, 0, 0, 0, PM_NOREMOVE); @@ -2665,17 +2806,17 @@ expect_messages = NULL; ok(!screen_size.cx && !screen_size.cy, "Got unexpected screen size %ux%u.\n", screen_size.cx, screen_size.cy); - ok(screen_size2.cx == fullscreen_rect.right && screen_size2.cy == fullscreen_rect.bottom, + ok(screen_size2.cx == registry_mode.dmPelsWidth && screen_size2.cy == registry_mode.dmPelsHeight, "Expected screen size 2 %ux%u, got %ux%u.\n", - fullscreen_rect.right, fullscreen_rect.bottom, screen_size2.cx, screen_size2.cy); + registry_mode.dmPelsWidth, registry_mode.dmPelsHeight, screen_size2.cx, screen_size2.cy); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); GetWindowRect(window2, &r); - ok(EqualRect(&r, &fullscreen_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - fullscreen_rect.left, fullscreen_rect.top, fullscreen_rect.right, fullscreen_rect.bottom, + ok(EqualRect(&r, ®istry_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + registry_rect.left, registry_rect.top, registry_rect.right, registry_rect.bottom, r.left, r.top, r.right, r.bottom); memset(&ddsd, 0, sizeof(ddsd)); @@ -2687,18 +2828,18 @@ ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n",hr); hr = IDirectDrawSurface7_GetSurfaceDesc(primary, &ddsd); ok(SUCCEEDED(hr), "Failed to get surface desc, hr %#x.\n", hr); - ok(ddsd.dwWidth == fullscreen_rect.right - fullscreen_rect.left, "Expected surface width %u, got %u.\n", - fullscreen_rect.right - fullscreen_rect.left, ddsd.dwWidth); - ok(ddsd.dwHeight == fullscreen_rect.bottom - fullscreen_rect.top, "Expected surface height %u, got %u.\n", - fullscreen_rect.bottom - fullscreen_rect.top, ddsd.dwHeight); + ok(ddsd.dwWidth == registry_mode.dmPelsWidth, "Expected surface width %u, got %u.\n", + registry_mode.dmPelsWidth, ddsd.dwWidth); + ok(ddsd.dwHeight == registry_mode.dmPelsHeight, "Expected surface height %u, got %u.\n", + registry_mode.dmPelsHeight, ddsd.dwHeight); IDirectDrawSurface7_Release(primary); ref = IDirectDraw7_Release(ddraw); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); GetWindowRect(window, &r); - ok(EqualRect(&r, &s), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", - s.left, s.top, s.right, s.bottom, + ok(EqualRect(&r, &ddraw_rect), "Expected {%d, %d, %d, %d}, got {%d, %d, %d, %d}.\n", + ddraw_rect.left, ddraw_rect.top, ddraw_rect.right, ddraw_rect.bottom, r.left, r.top, r.right, r.bottom); expect_messages = NULL; @@ -2711,7 +2852,7 @@ static void test_coop_level_mode_set_multi(void) { IDirectDraw7 *ddraw1, *ddraw2; - UINT orig_w, orig_h, w, h; + UINT w, h; HWND window; HRESULT hr; ULONG ref; @@ -2721,9 +2862,6 @@ ddraw1 = create_ddraw(); ok(!!ddraw1, "Failed to create a ddraw object.\n"); - orig_w = GetSystemMetrics(SM_CXSCREEN); - orig_h = GetSystemMetrics(SM_CYSCREEN); - /* With just a single ddraw object, the display mode is restored on * release. */ hr = set_display_mode(ddraw1, 800, 600); @@ -2736,9 +2874,9 @@ ref = IDirectDraw7_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* When there are multiple ddraw objects, the display mode is restored to * the initial mode, before the first SetDisplayMode() call. */ @@ -2761,16 +2899,16 @@ ref = IDirectDraw7_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw7_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* Regardless of release ordering. */ ddraw1 = create_ddraw(); @@ -2792,16 +2930,16 @@ ref = IDirectDraw7_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw7_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* But only for ddraw objects that called SetDisplayMode(). */ ddraw1 = create_ddraw(); @@ -2823,9 +2961,9 @@ ref = IDirectDraw7_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* If there's a ddraw object that's currently in exclusive mode, it blocks * restoring the display mode. */ @@ -2858,9 +2996,9 @@ ref = IDirectDraw7_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); /* Exclusive mode blocks mode setting on other ddraw objects in general. */ ddraw1 = create_ddraw(); @@ -2881,16 +3019,16 @@ ref = IDirectDraw7_Release(ddraw1); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); ref = IDirectDraw7_Release(ddraw2); ok(ref == 0, "The ddraw object was not properly freed: refcount %u.\n", ref); w = GetSystemMetrics(SM_CXSCREEN); - ok(w == orig_w, "Got unexpected screen width %u.\n", w); + ok(w == registry_mode.dmPelsWidth, "Got unexpected screen width %u.\n", w); h = GetSystemMetrics(SM_CYSCREEN); - ok(h == orig_h, "Got unexpected screen height %u.\n", h); + ok(h == registry_mode.dmPelsHeight, "Got unexpected screen height %u.\n", h); DestroyWindow(window); } @@ -5913,8 +6051,8 @@ surface_desc.dwSize = sizeof(surface_desc); surface_desc.dwFlags = DDSD_CAPS | DDSD_WIDTH | DDSD_HEIGHT; surface_desc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - surface_desc.dwWidth = GetSystemMetrics(SM_CXSCREEN); - surface_desc.dwHeight = GetSystemMetrics(SM_CYSCREEN); + surface_desc.dwWidth = registry_mode.dmPelsWidth; + surface_desc.dwHeight = registry_mode.dmPelsHeight; hr = IDirectDraw7_CreateSurface(ddraw, &surface_desc, &surface2, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -5922,8 +6060,8 @@ surface_desc.dwSize = sizeof(surface_desc); surface_desc.dwFlags = DDSD_CAPS | DDSD_WIDTH | DDSD_HEIGHT; surface_desc.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN; - surface_desc.dwWidth = GetSystemMetrics(SM_CXSCREEN); - surface_desc.dwHeight = GetSystemMetrics(SM_CYSCREEN); + surface_desc.dwWidth = registry_mode.dmPelsWidth; + surface_desc.dwHeight = registry_mode.dmPelsHeight; hr = IDirectDraw7_CreateSurface(ddraw, &surface_desc, &surface3, NULL); ok(SUCCEEDED(hr), "Failed to create surface, hr %#x.\n", hr); @@ -7626,10 +7764,135 @@ DestroyWindow(window); } +static void fog_interpolation_test(void) +{ + HRESULT hr; + IDirect3DDevice7 *device; + IDirectDrawSurface7 *rt; + ULONG refcount; + HWND window; + D3DCOLOR color; + static struct + { + struct vec3 position; + D3DCOLOR diffuse; + D3DCOLOR specular; + } + quad[] = + { + {{-1.0f, -1.0f, 0.0f}, 0xffff0000, 0xff000000}, + {{-1.0f, 1.0f, 0.0f}, 0xffff0000, 0xff000000}, + {{ 1.0f, -1.0f, 1.0f}, 0xffff0000, 0x00000000}, + {{ 1.0f, 1.0f, 1.0f}, 0xffff0000, 0x00000000}, + }; + union + { + DWORD d; + float f; + } conv; + unsigned int i; + static const struct + { + D3DFOGMODE vfog, tfog; + D3DSHADEMODE shade; + D3DCOLOR middle_color; + BOOL todo; + } + tests[] = + { + {D3DFOG_NONE, D3DFOG_NONE, D3DSHADE_FLAT, 0x00007f80, FALSE}, + {D3DFOG_NONE, D3DFOG_NONE, D3DSHADE_GOURAUD, 0x00007f80, FALSE}, + {D3DFOG_EXP, D3DFOG_NONE, D3DSHADE_FLAT, 0x00007f80, TRUE}, + {D3DFOG_EXP, D3DFOG_NONE, D3DSHADE_GOURAUD, 0x00007f80, TRUE}, + {D3DFOG_NONE, D3DFOG_EXP, D3DSHADE_FLAT, 0x0000ea15, FALSE}, + {D3DFOG_NONE, D3DFOG_EXP, D3DSHADE_GOURAUD, 0x0000ea15, FALSE}, + {D3DFOG_EXP, D3DFOG_EXP, D3DSHADE_FLAT, 0x0000ea15, FALSE}, + {D3DFOG_EXP, D3DFOG_EXP, D3DSHADE_GOURAUD, 0x0000ea15, FALSE}, + }; + D3DDEVICEDESC7 caps; + + window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW, + 0, 0, 640, 480, 0, 0, 0, 0); + + if (!(device = create_device(window, DDSCL_NORMAL))) + { + skip("Failed to create a 3D device, skipping test.\n"); + DestroyWindow(window); + return; + } + + hr = IDirect3DDevice7_GetRenderTarget(device, &rt); + ok(SUCCEEDED(hr), "Failed to get render target, hr %#x.\n", hr); + hr = IDirect3DDevice7_GetCaps(device, &caps); + ok(SUCCEEDED(hr), "Failed to get device caps, hr %#x.\n", hr); + if (!(caps.dpcTriCaps.dwRasterCaps & D3DPRASTERCAPS_FOGTABLE)) + skip("D3DPRASTERCAPS_FOGTABLE not supported, skipping some fog tests\n"); + + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_LIGHTING, FALSE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_ZENABLE, FALSE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_FOGENABLE, TRUE); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_FOGCOLOR, 0x0000ff00); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + conv.f = 5.0; + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_FOGDENSITY, conv.d); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + + hr = IDirect3DDevice7_SetTextureStageState(device, 0, D3DTSS_COLOROP, D3DTOP_SELECTARG1); + ok(SUCCEEDED(hr), "Failed to set texture stage state, hr %#x.\n", hr); + hr = IDirect3DDevice7_SetTextureStageState(device, 0, D3DTSS_COLORARG1, D3DTA_TFACTOR); + ok(SUCCEEDED(hr), "Failed to set texture stage state, hr %#x.\n", hr); + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_TEXTUREFACTOR, 0x000000ff); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + + for (i = 0; i < sizeof(tests) / sizeof(*tests); i++) + { + if(!(caps.dpcTriCaps.dwRasterCaps & D3DPRASTERCAPS_FOGTABLE) && tests[i].tfog) + continue; + + hr = IDirect3DDevice7_Clear(device, 0, NULL, D3DCLEAR_TARGET, 0x00808080, 0.0f, 0); + ok(SUCCEEDED(hr), "Failed to clear, hr %#x.\n", hr); + + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_SHADEMODE, tests[i].shade); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_FOGVERTEXMODE, tests[i].vfog); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice7_SetRenderState(device, D3DRENDERSTATE_FOGTABLEMODE, tests[i].tfog); + ok(SUCCEEDED(hr), "Failed to set render state, hr %#x.\n", hr); + hr = IDirect3DDevice7_BeginScene(device); + ok(SUCCEEDED(hr), "Failed to begin scene, hr %#x.\n", hr); + hr = IDirect3DDevice7_DrawPrimitive(device, D3DPT_TRIANGLESTRIP, + D3DFVF_XYZ | D3DFVF_DIFFUSE | D3DFVF_SPECULAR, quad, 4, 0); + ok(SUCCEEDED(hr), "Failed to draw, hr %#x.\n", hr); + hr = IDirect3DDevice7_EndScene(device); + ok(SUCCEEDED(hr), "Failed to end scene, hr %#x.\n", hr); + + color = get_surface_color(rt, 0, 240); + ok(compare_color(color, 0x000000ff, 2), "Got unexpected color 0x%08x, case %u.\n", color, i); + color = get_surface_color(rt, 320, 240); + if (tests[i].todo) + todo_wine ok(compare_color(color, tests[i].middle_color, 2), + "Got unexpected color 0x%08x, case %u.\n", color, i); + else + ok(compare_color(color, tests[i].middle_color, 2), + "Got unexpected color 0x%08x, case %u.\n", color, i); + color = get_surface_color(rt, 639, 240); + ok(compare_color(color, 0x0000fd02, 2), "Got unexpected color 0x%08x, case %u.\n", color, i); + } + + IDirectDrawSurface7_Release(rt); + refcount = IDirect3DDevice7_Release(device); + ok(!refcount, "Device has %u references left.\n", refcount); + DestroyWindow(window); +} + START_TEST(ddraw7) { HMODULE module = GetModuleHandleA("ddraw.dll"); IDirectDraw7 *ddraw; + DEVMODEW current_mode; if (!(pDirectDrawCreateEx = (void *)GetProcAddress(module, "DirectDrawCreateEx"))) { @@ -7644,6 +7907,18 @@ } IDirectDraw7_Release(ddraw); + memset(¤t_mode, 0, sizeof(current_mode)); + current_mode.dmSize = sizeof(current_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_CURRENT_SETTINGS, ¤t_mode), "Failed to get display mode.\n"); + registry_mode.dmSize = sizeof(registry_mode); + ok(EnumDisplaySettingsW(NULL, ENUM_REGISTRY_SETTINGS, ®istry_mode), "Failed to get display mode.\n"); + if (registry_mode.dmPelsWidth != current_mode.dmPelsWidth + || registry_mode.dmPelsHeight != current_mode.dmPelsHeight) + { + skip("Current mode does not match registry mode, skipping test.\n"); + return; + } + test_process_vertices(); test_coop_level_create_device_window(); test_clipper_blt(); @@ -7699,4 +7974,5 @@ test_lost_device(); test_resource_priority(); test_surface_desc_lock(); + fog_interpolation_test(); } diff -Nru wine1.7-1.7.28/dlls/dinput/joystick_linux.c wine1.7-1.7.31/dlls/dinput/joystick_linux.c --- wine1.7-1.7.28/dlls/dinput/joystick_linux.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dinput/joystick_linux.c 2014-11-14 13:28:17.000000000 +0000 @@ -169,6 +169,9 @@ WARN("ioctl(%s,JSIOCGAXES) failed: %s, defauting to 2\n", joydev.device, strerror(errno)); joydev.axis_count = 2; } +#else + WARN("reading number of joystick axes unsupported in this platform, defaulting to 2\n"); + joydev.axis_count = 2; #endif #ifdef JSIOCGBUTTONS if (ioctl(fd, JSIOCGBUTTONS, &joydev.button_count) < 0) @@ -176,6 +179,9 @@ WARN("ioctl(%s,JSIOCGBUTTONS) failed: %s, defauting to 2\n", joydev.device, strerror(errno)); joydev.button_count = 2; } +#else + WARN("reading number of joystick buttons unsupported in this platform, defaulting to 2\n"); + joydev.button_count = 2; #endif if (ioctl(fd, JSIOCGAXMAP, axes_map) < 0) diff -Nru wine1.7-1.7.28/dlls/dmsynth/synth.c wine1.7-1.7.31/dlls/dmsynth/synth.c --- wine1.7-1.7.28/dlls/dmsynth/synth.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dmsynth/synth.c 2014-11-14 13:28:17.000000000 +0000 @@ -511,7 +511,7 @@ } if (DataLength < sizeof(DWORD)) - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; if (IsEqualGUID(&Property->u.s.Set, &GUID_DMUS_PROP_INSTRUMENT2)) { diff -Nru wine1.7-1.7.28/dlls/dmsynth/synthsink.c wine1.7-1.7.31/dlls/dmsynth/synthsink.c --- wine1.7-1.7.28/dlls/dmsynth/synthsink.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dmsynth/synthsink.c 2014-11-14 13:28:17.000000000 +0000 @@ -223,7 +223,7 @@ } if (DataLength < sizeof(DWORD)) - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; if (IsEqualGUID(&Property->u.s.Set, &GUID_DMUS_PROP_SinkUsesDSound)) { diff -Nru wine1.7-1.7.28/dlls/dmusic/port.c wine1.7-1.7.31/dlls/dmusic/port.c --- wine1.7-1.7.28/dlls/dmusic/port.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dmusic/port.c 2014-11-14 13:28:17.000000000 +0000 @@ -49,9 +49,7 @@ { TRACE("(%p, %s, %p)\n", iface, debugstr_dmguid(riid), ret_iface); - if (IsEqualIID(riid, &IID_IUnknown) || - IsEqualIID(riid, &IID_IDirectMusicDownloadedInstrument) || - IsEqualIID(riid, &IID_IDirectMusicDownloadedInstrument8)) + if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IDirectMusicDownloadedInstrument)) { IDirectMusicDownloadedInstrument_AddRef(iface); *ret_iface = iface; @@ -132,19 +130,15 @@ TRACE("(%p/%p)->(%s, %p)\n", iface, This, debugstr_dmguid(riid), ret_iface); - if (IsEqualIID (riid, &IID_IUnknown) || - IsEqualGUID(riid, &IID_IDirectMusicPort) || - IsEqualGUID(riid, &IID_IDirectMusicPort8)) { + if (IsEqualIID(riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_IDirectMusicPort)) { *ret_iface = &This->IDirectMusicPort_iface; IDirectMusicPort_AddRef((LPDIRECTMUSICPORT)*ret_iface); return S_OK; - } else if (IsEqualGUID(riid, &IID_IDirectMusicPortDownload) || - IsEqualGUID(riid, &IID_IDirectMusicPortDownload8)) { + } else if (IsEqualGUID(riid, &IID_IDirectMusicPortDownload)) { *ret_iface = &This->IDirectMusicPortDownload_iface; IDirectMusicPortDownload_AddRef((LPDIRECTMUSICPORTDOWNLOAD)*ret_iface); return S_OK; - } else if (IsEqualGUID(riid, &IID_IDirectMusicThru) || - IsEqualGUID(riid, &IID_IDirectMusicThru8)) { + } else if (IsEqualGUID(riid, &IID_IDirectMusicThru)) { *ret_iface = &This->IDirectMusicThru_iface; IDirectMusicThru_AddRef((LPDIRECTMUSICTHRU)*ret_iface); return S_OK; diff -Nru wine1.7-1.7.28/dlls/dplayx/tests/dplayx.c wine1.7-1.7.31/dlls/dplayx/tests/dplayx.c --- wine1.7-1.7.28/dlls/dplayx/tests/dplayx.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dplayx/tests/dplayx.c 2014-11-14 13:28:17.000000000 +0000 @@ -685,7 +685,7 @@ } hr = IDirectPlayX_InitializeConnection( pDP, pAddress, 0 ); - todo_wine checkHR( DP_OK, hr ); + checkHR( DP_OK, hr ); HeapFree( GetProcessHeap(), 0, pAddress ); @@ -743,7 +743,7 @@ if ( hr == DP_OK ) IDirectPlayX_Release( pDP ); hr = DirectPlayCreate( (LPGUID) &DPSPGUID_TCPIP, &pDP, NULL ); - todo_wine checkHR( DP_OK, hr ); + checkHR( DP_OK, hr ); if ( hr == DP_OK ) IDirectPlayX_Release( pDP ); @@ -915,9 +915,9 @@ if( IsEqualGUID(lpguidSP, &DPSPGUID_TCPIP) ) { hr = IDirectPlayX_InitializeConnection( pDP, lpConnection, 0 ); - todo_wine checkHR( DP_OK, hr ); + checkHR( DP_OK, hr ); hr = IDirectPlayX_InitializeConnection( pDP, lpConnection, 0 ); - todo_wine checkHR( DPERR_ALREADYINITIALIZED, hr ); + checkHR( DPERR_ALREADYINITIALIZED, hr ); } return TRUE; @@ -976,7 +976,7 @@ { hr = IDirectPlayX_GetCaps( pDP, &dpcaps, dwFlags ); - todo_wine checkHR( DP_OK, hr ); + checkHR( DP_OK, hr ); if ( hr == DP_OK ) @@ -1085,7 +1085,7 @@ /* Uninitialized dpsd */ hr = IDirectPlayX_Open( pDP_server, &dpsd_server, DPOPEN_CREATE ); - todo_wine checkHR( DPERR_INVALIDPARAMS, hr ); + checkHR( DPERR_INVALIDPARAMS, hr ); dpsd_server.dwSize = sizeof(DPSESSIONDESC2); @@ -1095,7 +1095,7 @@ /* Regular operation */ hr = IDirectPlayX_Open( pDP_server, &dpsd_server, DPOPEN_CREATE ); - todo_wine checkHR( DP_OK, hr ); + checkHR( DP_OK, hr ); /* Opening twice */ hr = IDirectPlayX_Open( pDP_server, &dpsd_server, DPOPEN_CREATE ); @@ -1698,12 +1698,16 @@ checkHR( DPERR_INVALIDPARAMS, hr ); hr = IDirectPlayX_GetSessionDesc( pDP[0], NULL, NULL ); checkHR( DPERR_INVALIDPARAM, hr ); +if(0) +{ + /* Crashes under Win7 */ hr = IDirectPlayX_GetSessionDesc( pDP[0], lpData[0], NULL ); checkHR( DPERR_INVALIDPARAM, hr ); dwDataSize=-1; hr = IDirectPlayX_GetSessionDesc( pDP[0], lpData[0], &dwDataSize ); checkHR( DPERR_INVALIDPARAMS, hr ); check( -1, dwDataSize ); +} /* Get: Insufficient buffer size */ dwDataSize=0; @@ -2498,10 +2502,14 @@ checkHR( DPERR_INVALIDPLAYER, hr ); check( 1024, dwDataSize ); +if(0) +{ + /* Crashes under Win7 */ dwDataSize = -1; hr = IDirectPlayX_GetPlayerName( pDP[0], dpid[0], lpData, &dwDataSize ); checkHR( DPERR_INVALIDPARAMS, hr ); check( -1, dwDataSize ); +} hr = IDirectPlayX_GetPlayerName( pDP[0], dpid[0], lpData, NULL ); checkHR( DPERR_INVALIDPARAMS, hr ); @@ -5789,6 +5797,9 @@ check( -1, dwNumBytes ); /* - Remote players */ +if(0) +{ + /* Crash under Win7 */ dwNumMsgs = dwNumBytes = -1; hr = IDirectPlayX_GetMessageQueue( pDP[0], 0, dpid[3], DPMESSAGEQUEUE_RECEIVE, @@ -5796,6 +5807,7 @@ checkHR( DPERR_INVALIDPLAYER, hr ); /* Player 3 is remote */ check( -1, dwNumMsgs ); check( -1, dwNumBytes ); +} dwNumMsgs = dwNumBytes = -1; hr = IDirectPlayX_GetMessageQueue( pDP[0], dpid[3], 0, diff -Nru wine1.7-1.7.28/dlls/dpnet/address.c wine1.7-1.7.31/dlls/dpnet/address.c --- wine1.7-1.7.28/dlls/dpnet/address.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dpnet/address.c 2014-11-14 13:28:17.000000000 +0000 @@ -316,9 +316,53 @@ static HRESULT WINAPI IDirectPlay8AddressImpl_GetComponentByName(IDirectPlay8Address *iface, const WCHAR *const pwszName, void *pvBuffer, DWORD *pdwBufferSize, DWORD *pdwDataType) { - IDirectPlay8AddressImpl *This = impl_from_IDirectPlay8Address(iface); - TRACE("(%p): stub\n", This); - return DPN_OK; + IDirectPlay8AddressImpl *This = impl_from_IDirectPlay8Address(iface); + struct component *entry; + + TRACE("(%p)->(%p %p %p %p)\n", This, pwszName, pvBuffer, pdwBufferSize, pdwDataType); + + if(!pwszName || !pdwBufferSize || !pdwDataType || (!pvBuffer && pdwBufferSize)) + return E_POINTER; + + LIST_FOR_EACH_ENTRY(entry, &This->components, struct component, entry) + { + if (lstrcmpW(pwszName, entry->name) == 0) + { + TRACE("Found %s\n", debugstr_w(pwszName)); + + if(*pdwBufferSize < entry->size) + { + *pdwBufferSize = entry->size; + return DPNERR_BUFFERTOOSMALL; + } + + *pdwBufferSize = entry->size; + *pdwDataType = entry->type; + + switch (entry->type) + { + case DPNA_DATATYPE_DWORD: + memcpy(pvBuffer, &entry->data.value, sizeof(DWORD)); + break; + case DPNA_DATATYPE_GUID: + memcpy(pvBuffer, &entry->data.guid, sizeof(GUID)); + break; + case DPNA_DATATYPE_STRING: + memcpy(pvBuffer, &entry->data.string, entry->size); + break; + case DPNA_DATATYPE_STRING_ANSI: + memcpy(pvBuffer, &entry->data.ansi, entry->size); + break; + case DPNA_DATATYPE_BINARY: + memcpy(pvBuffer, &entry->data.binary, entry->size); + break; + } + + return S_OK; + } + } + + return DPNERR_DOESNOTEXIST; } static HRESULT WINAPI IDirectPlay8AddressImpl_GetComponentByIndex(IDirectPlay8Address *iface, @@ -364,7 +408,6 @@ list_add_tail(&This->components, &entry->entry); } - entry->size = dwDataSize; switch (dwDataType) { case DPNA_DATATYPE_DWORD: @@ -402,6 +445,8 @@ break; } + entry->size = dwDataSize; + return DPN_OK; } diff -Nru wine1.7-1.7.28/dlls/dpnet/tests/address.c wine1.7-1.7.31/dlls/dpnet/tests/address.c --- wine1.7-1.7.28/dlls/dpnet/tests/address.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dpnet/tests/address.c 2014-11-14 13:28:17.000000000 +0000 @@ -102,11 +102,38 @@ hr = IDirectPlay8Address_AddComponent(localaddr, DPNA_KEY_PORT, &port, sizeof(DWORD), DPNA_DATATYPE_DWORD); ok(hr == S_OK, "got 0x%08x\n", hr); + hr = IDirectPlay8Address_GetComponentByName(localaddr, NULL, &compguid, &size, &type); + ok(hr == E_POINTER, "got 0x%08x\n", hr); + + size = sizeof(GUID)-1; + hr = IDirectPlay8Address_GetComponentByName(localaddr, UNKNOWN, NULL, &size, &type); + ok(hr == E_POINTER, "got 0x%08x\n", hr); + + size = sizeof(GUID); + hr = IDirectPlay8Address_GetComponentByName(localaddr, UNKNOWN, NULL, &size, &type); + ok(hr == E_POINTER, "got 0x%08x\n", hr); + + hr = IDirectPlay8Address_GetComponentByName(localaddr, UNKNOWN, &compguid, NULL, &type); + ok(hr == E_POINTER, "got 0x%08x\n", hr); + + size = sizeof(GUID)-1; + hr = IDirectPlay8Address_GetComponentByName(localaddr, UNKNOWN, &compguid, &size, NULL); + ok(hr == E_POINTER, "got 0x%08x\n", hr); + + size = sizeof(GUID); + hr = IDirectPlay8Address_GetComponentByName(localaddr, UNKNOWN, &compguid, &size, NULL); + ok(hr == E_POINTER, "got 0x%08x\n", hr); + + size = sizeof(GUID)-1; + hr = IDirectPlay8Address_GetComponentByName(localaddr, UNKNOWN, &compguid, &size, &type); + ok(hr == DPNERR_BUFFERTOOSMALL, "got 0x%08x\n", hr); + ok(size == sizeof(GUID), "got %d\n", size); + size = sizeof(GUID); hr = IDirectPlay8Address_GetComponentByName(localaddr, UNKNOWN, &compguid, &size, &type); - todo_wine ok(IsEqualGUID(&compguid, &IID_Random), "incorrect guid\n"); - ok(size == sizeof(GUID), "incorrect size\n"); - todo_wine ok(type == DPNA_DATATYPE_GUID, "incorrect type\n"); + ok(IsEqualGUID(&compguid, &IID_Random), "incorrect guid\n"); + ok(size == sizeof(GUID), "incorrect size got %d\n", size); + ok(type == DPNA_DATATYPE_GUID, "incorrect type\n"); ok(hr == S_OK, "got 0x%08x\n", hr); hr = IDirectPlay8Address_GetNumComponents(localaddr, NULL); diff -Nru wine1.7-1.7.28/dlls/dwmapi/dwmapi_main.c wine1.7-1.7.31/dlls/dwmapi/dwmapi_main.c --- wine1.7-1.7.28/dlls/dwmapi/dwmapi_main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwmapi/dwmapi_main.c 2014-11-14 13:28:17.000000000 +0000 @@ -234,3 +234,21 @@ return E_NOTIMPL; } + +/********************************************************************** + * DwmAttachMilContent (DWMAPI.@) + */ +HRESULT WINAPI DwmAttachMilContent(HWND hwnd) +{ + FIXME("(%p) stub\n", hwnd); + return E_NOTIMPL; +} + +/********************************************************************** + * DwmDetachMilContent (DWMAPI.@) + */ +HRESULT WINAPI DwmDetachMilContent(HWND hwnd) +{ + FIXME("(%p) stub\n", hwnd); + return E_NOTIMPL; +} diff -Nru wine1.7-1.7.28/dlls/dwmapi/dwmapi.spec wine1.7-1.7.31/dlls/dwmapi/dwmapi.spec --- wine1.7-1.7.28/dlls/dwmapi/dwmapi.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwmapi/dwmapi.spec 2014-11-14 13:28:17.000000000 +0000 @@ -20,9 +20,9 @@ 119 stub @ 120 stub @ -@ stub DwmAttachMilContent +@ stdcall DwmAttachMilContent(long) @ stdcall DwmDefWindowProc(long long long long ptr) -@ stub DwmDetachMilContent +@ stdcall DwmDetachMilContent(long) @ stdcall DwmEnableBlurBehindWindow(ptr ptr) @ stdcall DwmEnableMMCSS(long) @ stdcall DwmExtendFrameIntoClientArea(long ptr) diff -Nru wine1.7-1.7.28/dlls/dwrite/analyzer.c wine1.7-1.7.31/dlls/dwrite/analyzer.c --- wine1.7-1.7.28/dlls/dwrite/analyzer.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/analyzer.c 2014-11-14 13:28:17.000000000 +0000 @@ -21,8 +21,6 @@ #define COBJMACROS -#include "dwrite.h" -#include "dwrite_2.h" #include "dwrite_private.h" #include "scripts.h" @@ -34,6 +32,7 @@ struct dwritescript_properties { DWRITE_SCRIPT_PROPERTIES props; BOOL is_complex; + const struct scriptshaping_ops *ops; }; /* NOTE: keep this array synced with script ids from scripts.h */ @@ -94,7 +93,7 @@ { /* Khoj */ { 0x6a6f684b, 322, 1, 0x0020, 0, 0, 0, 0, 0, 0, 0 } }, { /* Sind */ { 0x646e6953, 318, 1, 0x0020, 0, 0, 0, 0, 0, 0, 0 } }, { /* Laoo */ { 0x6f6f614c, 356, 8, 0x0020, 1, 0, 1, 0, 1, 0, 0 }, TRUE }, - { /* Latn */ { 0x6e74614c, 215, 1, 0x0020, 0, 1, 1, 0, 0, 0, 0 } }, + { /* Latn */ { 0x6e74614c, 215, 1, 0x0020, 0, 1, 1, 0, 0, 0, 0 }, FALSE, &latn_shaping_ops }, { /* Lepc */ { 0x6370654c, 335, 8, 0x0020, 1, 1, 1, 0, 0, 0, 0 } }, { /* Limb */ { 0x626d694c, 336, 8, 0x0020, 1, 1, 1, 0, 0, 0, 0 } }, { /* Lina */ { 0x616e694c, 400, 1, 0x0020, 0, 0, 0, 0, 0, 0, 0 } }, @@ -179,6 +178,16 @@ return CONTAINING_RECORD(iface, struct dwrite_numbersubstitution, IDWriteNumberSubstitution_iface); } +static inline UINT32 decode_surrogate_pair(const WCHAR *str, UINT32 index, UINT32 end) +{ + if (index < end-1 && IS_SURROGATE_PAIR(str[index], str[index+1])) { + UINT32 ch = 0x10000 + ((str[index] - 0xd800) << 10) + (str[index+1] - 0xdc00); + TRACE("surrogate pair (%x %x) => %x\n", str[index], str[index+1], ch); + return ch; + } + return 0; +} + static inline UINT16 get_char_script(WCHAR c) { UINT16 script = get_table_entry(wine_scripts_table, c); @@ -827,17 +836,130 @@ } static HRESULT WINAPI dwritetextanalyzer_GetGlyphs(IDWriteTextAnalyzer2 *iface, - WCHAR const* text, UINT32 length, IDWriteFontFace* font_face, BOOL is_sideways, + WCHAR const* text, UINT32 length, IDWriteFontFace* fontface, BOOL is_sideways, BOOL is_rtl, DWRITE_SCRIPT_ANALYSIS const* analysis, WCHAR const* locale, IDWriteNumberSubstitution* substitution, DWRITE_TYPOGRAPHIC_FEATURES const** features, UINT32 const* feature_range_len, UINT32 feature_ranges, UINT32 max_glyph_count, UINT16* clustermap, DWRITE_SHAPING_TEXT_PROPERTIES* text_props, UINT16* glyph_indices, DWRITE_SHAPING_GLYPH_PROPERTIES* glyph_props, UINT32* actual_glyph_count) { - FIXME("(%s:%u %p %d %d %p %s %p %p %p %u %u %p %p %p %p %p): stub\n", debugstr_wn(text, length), - length, font_face, is_sideways, is_rtl, analysis, debugstr_w(locale), substitution, features, feature_range_len, + const struct dwritescript_properties *scriptprops; + struct scriptshaping_context context; + struct scriptshaping_cache *cache; + WCHAR *string; + BOOL update_cluster; + UINT32 i, g; + HRESULT hr = S_OK; + UINT16 script; + + TRACE("(%s:%u %p %d %d %p %s %p %p %p %u %u %p %p %p %p %p)\n", debugstr_wn(text, length), + length, fontface, is_sideways, is_rtl, analysis, debugstr_w(locale), substitution, features, feature_range_len, feature_ranges, max_glyph_count, clustermap, text_props, glyph_indices, glyph_props, actual_glyph_count); - return E_NOTIMPL; + + script = analysis->script > Script_LastId ? Script_Unknown : analysis->script; + + if (max_glyph_count < length) + return E_NOT_SUFFICIENT_BUFFER; + + if (substitution) + FIXME("number substitution is not supported.\n"); + + for (i = 0; i < length; i++) { + /* FIXME: set to better values */ + glyph_props[i].justification = text[i] == ' ' ? SCRIPT_JUSTIFY_BLANK : SCRIPT_JUSTIFY_CHARACTER; + glyph_props[i].isClusterStart = 1; + glyph_props[i].isDiacritic = 0; + glyph_props[i].isZeroWidthSpace = 0; + glyph_props[i].reserved = 0; + + /* FIXME: have the shaping engine set this */ + text_props[i].isShapedAlone = 0; + text_props[i].reserved = 0; + + clustermap[i] = i; + } + + for (; i < max_glyph_count; i++) { + glyph_props[i].justification = SCRIPT_JUSTIFY_NONE; + glyph_props[i].isClusterStart = 0; + glyph_props[i].isDiacritic = 0; + glyph_props[i].isZeroWidthSpace = 0; + glyph_props[i].reserved = 0; + } + + string = heap_alloc(sizeof(WCHAR)*length); + if (!string) + return E_OUTOFMEMORY; + + for (i = 0, g = 0, update_cluster = FALSE; i < length; i++) { + UINT32 codepoint; + + if (!update_cluster) { + codepoint = decode_surrogate_pair(text, i, length); + if (!codepoint) { + codepoint = is_rtl ? bidi_get_mirrored_char(text[i]) : text[i]; + string[i] = codepoint; + } + else { + string[i] = text[i]; + string[i+1] = text[i+1]; + update_cluster = TRUE; + } + + hr = IDWriteFontFace_GetGlyphIndices(fontface, &codepoint, 1, &glyph_indices[g]); + if (FAILED(hr)) + goto done; + + g++; + } + else { + INT32 k; + + update_cluster = FALSE; + /* mark surrogate halves with same cluster */ + clustermap[i] = clustermap[i-1]; + /* update following clusters */ + for (k = i + 1; k >= 0 && k < length; k++) + clustermap[k]--; + } + } + *actual_glyph_count = g; + + hr = create_scriptshaping_cache(fontface, &cache); + if (FAILED(hr)) + goto done; + + context.cache = cache; + context.text = text; + context.length = length; + context.is_rtl = is_rtl; + context.max_glyph_count = max_glyph_count; + context.language_tag = DWRITE_MAKE_OPENTYPE_TAG('d','f','l','t'); + if (locale) { + WCHAR tag[5]; + if (GetLocaleInfoEx(locale, LOCALE_SOPENTYPELANGUAGETAG, tag, sizeof(tag)/sizeof(WCHAR))) + context.language_tag = DWRITE_MAKE_OPENTYPE_TAG(tag[0],tag[1],tag[2],tag[3]); + } + + scriptprops = &dwritescripts_properties[script]; + if (scriptprops->ops && scriptprops->ops->contextual_shaping) { + hr = scriptprops->ops->contextual_shaping(&context, clustermap, glyph_indices, actual_glyph_count); + if (FAILED(hr)) + goto done; + } + + /* FIXME: apply default features */ + + if (scriptprops->ops && scriptprops->ops->set_text_glyphs_props) + hr = scriptprops->ops->set_text_glyphs_props(&context, clustermap, glyph_indices, *actual_glyph_count, text_props, glyph_props); + else + hr = default_shaping_ops.set_text_glyphs_props(&context, clustermap, glyph_indices, *actual_glyph_count, text_props, glyph_props); + +done: + release_scriptshaping_cache(cache); + heap_free(string); + + return hr; } static HRESULT WINAPI dwritetextanalyzer_GetGlyphPlacements(IDWriteTextAnalyzer2 *iface, @@ -1114,7 +1236,7 @@ *ret = NULL; - if (method < DWRITE_NUMBER_SUBSTITUTION_METHOD_FROM_CULTURE || method > DWRITE_NUMBER_SUBSTITUTION_METHOD_TRADITIONAL) + if ((UINT32)method > DWRITE_NUMBER_SUBSTITUTION_METHOD_TRADITIONAL) return E_INVALIDARG; if (method != DWRITE_NUMBER_SUBSTITUTION_METHOD_NONE && !IsValidLocaleName(locale)) diff -Nru wine1.7-1.7.28/dlls/dwrite/bidi.c wine1.7-1.7.31/dlls/dwrite/bidi.c --- wine1.7-1.7.28/dlls/dwrite/bidi.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/bidi.c 2014-11-14 13:28:17.000000000 +0000 @@ -48,7 +48,6 @@ #include "wine/debug.h" #include "wine/list.h" -#include "dwrite.h" #include "dwrite_private.h" WINE_DEFAULT_DEBUG_CHANNEL(bidi); @@ -198,6 +197,12 @@ } } +WCHAR bidi_get_mirrored_char(WCHAR ch) +{ + extern const WCHAR wine_mirror_map[]; + return ch + wine_mirror_map[wine_mirror_map[ch >> 8] + (ch & 0xff)]; +} + /* RESOLVE EXPLICIT */ static inline UINT8 get_greater_even_level(UINT8 level) diff -Nru wine1.7-1.7.28/dlls/dwrite/dwrite_private.h wine1.7-1.7.31/dlls/dwrite/dwrite_private.h --- wine1.7-1.7.28/dlls/dwrite/dwrite_private.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/dwrite_private.h 2014-11-14 13:28:17.000000000 +0000 @@ -16,6 +16,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#include "dwrite_2.h" + #include "wine/debug.h" #include "wine/unicode.h" @@ -87,7 +89,6 @@ return table[table[table[ch >> 8] + ((ch >> 4) & 0x0f)] + (ch & 0xf)]; } -extern HRESULT create_font_from_logfont(const LOGFONTW*, IDWriteFont**) DECLSPEC_HIDDEN; extern HRESULT convert_fontface_to_logfont(IDWriteFontFace*, LOGFONTW*) DECLSPEC_HIDDEN; extern HRESULT create_numbersubstitution(DWRITE_NUMBER_SUBSTITUTION_METHOD,const WCHAR *locale,BOOL,IDWriteNumberSubstitution**) DECLSPEC_HIDDEN; extern HRESULT create_textformat(const WCHAR*,IDWriteFontCollection*,DWRITE_FONT_WEIGHT,DWRITE_FONT_STYLE,DWRITE_FONT_STRETCH, @@ -95,20 +96,75 @@ extern HRESULT create_textlayout(const WCHAR*,UINT32,IDWriteTextFormat*,FLOAT,FLOAT,IDWriteTextLayout**) DECLSPEC_HIDDEN; extern HRESULT create_trimmingsign(IDWriteInlineObject**) DECLSPEC_HIDDEN; extern HRESULT create_typography(IDWriteTypography**) DECLSPEC_HIDDEN; -extern HRESULT get_gdiinterop(IDWriteGdiInterop**) DECLSPEC_HIDDEN; +extern HRESULT create_gdiinterop(IDWriteFactory*,IDWriteGdiInterop**) DECLSPEC_HIDDEN; +extern void release_gdiinterop(IDWriteGdiInterop*) DECLSPEC_HIDDEN; extern HRESULT create_localizedstrings(IDWriteLocalizedStrings**) DECLSPEC_HIDDEN; extern HRESULT add_localizedstring(IDWriteLocalizedStrings*,const WCHAR*,const WCHAR*) DECLSPEC_HIDDEN; extern HRESULT clone_localizedstring(IDWriteLocalizedStrings *iface, IDWriteLocalizedStrings **strings) DECLSPEC_HIDDEN; -extern HRESULT get_system_fontcollection(IDWriteFontCollection**) DECLSPEC_HIDDEN; +extern HRESULT get_system_fontcollection(IDWriteFactory*,IDWriteFontCollection**) DECLSPEC_HIDDEN; extern HRESULT get_textanalyzer(IDWriteTextAnalyzer**) DECLSPEC_HIDDEN; extern HRESULT create_font_file(IDWriteFontFileLoader *loader, const void *reference_key, UINT32 key_size, IDWriteFontFile **font_file) DECLSPEC_HIDDEN; extern HRESULT create_localfontfileloader(IDWriteLocalFontFileLoader** iface) DECLSPEC_HIDDEN; -extern HRESULT font_create_fontface(IDWriteFactory *iface, DWRITE_FONT_FACE_TYPE facetype, UINT32 files_number, IDWriteFontFile* const* font_files, UINT32 index, DWRITE_FONT_SIMULATIONS sim_flags, IDWriteFontFace **font_face) DECLSPEC_HIDDEN; +extern HRESULT create_fontface(DWRITE_FONT_FACE_TYPE,UINT32,IDWriteFontFile* const*,UINT32,DWRITE_FONT_SIMULATIONS,IDWriteFontFace2**) DECLSPEC_HIDDEN; +extern HRESULT create_font_collection(IDWriteFactory*,IDWriteFontFileEnumerator*,BOOL,IDWriteFontCollection**) DECLSPEC_HIDDEN; +extern BOOL is_system_collection(IDWriteFontCollection*) DECLSPEC_HIDDEN; /* Opentype font table functions */ -extern HRESULT analyze_opentype_font(const void* font_data, UINT32* font_count, DWRITE_FONT_FILE_TYPE *file_type, DWRITE_FONT_FACE_TYPE *face_type, BOOL *supported) DECLSPEC_HIDDEN; -extern HRESULT find_font_table(IDWriteFontFileStream *stream, UINT32 font_index, UINT32 tag, const void** table_data, void** table_context, UINT32 *table_size, BOOL* found) DECLSPEC_HIDDEN; -extern VOID OpenType_CMAP_GetGlyphIndex(LPVOID data, DWORD utf32c, LPWORD pgi, DWORD flags) DECLSPEC_HIDDEN; -extern VOID get_font_properties(LPCVOID os2, LPCVOID head, LPCVOID post, DWRITE_FONT_METRICS *metrics, DWRITE_FONT_STRETCH *stretch, DWRITE_FONT_WEIGHT *weight, DWRITE_FONT_STYLE *style) DECLSPEC_HIDDEN; +extern HRESULT opentype_analyze_font(IDWriteFontFileStream*,UINT32*,DWRITE_FONT_FILE_TYPE*,DWRITE_FONT_FACE_TYPE*,BOOL*) DECLSPEC_HIDDEN; +extern HRESULT opentype_get_font_table(IDWriteFontFileStream*,DWRITE_FONT_FACE_TYPE,UINT32,UINT32,const void**,void**,UINT32*,BOOL*) DECLSPEC_HIDDEN; +extern void opentype_cmap_get_glyphindex(void*,UINT32,UINT16*) DECLSPEC_HIDDEN; +extern HRESULT opentype_cmap_get_unicode_ranges(void*,UINT32,DWRITE_UNICODE_RANGE*,UINT32*) DECLSPEC_HIDDEN; +extern void opentype_get_font_properties(const void*,const void*,DWRITE_FONT_STRETCH*,DWRITE_FONT_WEIGHT*,DWRITE_FONT_STYLE*) DECLSPEC_HIDDEN; +extern void opentype_get_font_metrics(const void*,const void*,const void*,DWRITE_FONT_METRICS1*) DECLSPEC_HIDDEN; +extern HRESULT opentype_get_font_strings_from_id(const void*,DWRITE_INFORMATIONAL_STRING_ID,IDWriteLocalizedStrings**) DECLSPEC_HIDDEN; + +extern HRESULT bidi_computelevels(const WCHAR*,UINT32,UINT8,UINT8*,UINT8*) DECLSPEC_HIDDEN; +extern WCHAR bidi_get_mirrored_char(WCHAR) DECLSPEC_HIDDEN; + +/* Glyph shaping */ +enum SCRIPT_JUSTIFY +{ + SCRIPT_JUSTIFY_NONE, + SCRIPT_JUSTIFY_ARABIC_BLANK, + SCRIPT_JUSTIFY_CHARACTER, + SCRIPT_JUSTIFY_RESERVED1, + SCRIPT_JUSTIFY_BLANK, + SCRIPT_JUSTIFY_RESERVED2, + SCRIPT_JUSTIFY_RESERVED3, + SCRIPT_JUSTIFY_ARABIC_NORMAL, + SCRIPT_JUSTIFY_ARABIC_KASHIDA, + SCRIPT_JUSTIFY_ARABIC_ALEF, + SCRIPT_JUSTIFY_ARABIC_HA, + SCRIPT_JUSTIFY_ARABIC_RA, + SCRIPT_JUSTIFY_ARABIC_BA, + SCRIPT_JUSTIFY_ARABIC_BARA, + SCRIPT_JUSTIFY_ARABIC_SEEN, + SCRIPT_JUSTIFY_ARABIC_SEEN_M +}; + +struct scriptshaping_cache; + +struct scriptshaping_context +{ + struct scriptshaping_cache *cache; + UINT32 language_tag; + + const WCHAR *text; + UINT32 length; + BOOL is_rtl; + + UINT32 max_glyph_count; +}; + +extern HRESULT create_scriptshaping_cache(IDWriteFontFace*,struct scriptshaping_cache**) DECLSPEC_HIDDEN; +extern void release_scriptshaping_cache(struct scriptshaping_cache*) DECLSPEC_HIDDEN; + +struct scriptshaping_ops +{ + HRESULT (*contextual_shaping)(struct scriptshaping_context *context, UINT16 *clustermap, UINT16 *glyph_indices, UINT32* actual_glyph_count); + HRESULT (*set_text_glyphs_props)(struct scriptshaping_context *context, UINT16 *clustermap, UINT16 *glyph_indices, + UINT32 glyphcount, DWRITE_SHAPING_TEXT_PROPERTIES *text_props, DWRITE_SHAPING_GLYPH_PROPERTIES *glyph_props); +}; -extern HRESULT bidi_computelevels(const WCHAR*,UINT32,UINT8,UINT8*,UINT8*); +extern const struct scriptshaping_ops default_shaping_ops DECLSPEC_HIDDEN; +extern const struct scriptshaping_ops latn_shaping_ops DECLSPEC_HIDDEN; diff -Nru wine1.7-1.7.28/dlls/dwrite/font.c wine1.7-1.7.31/dlls/dwrite/font.c --- wine1.7-1.7.28/dlls/dwrite/font.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/font.c 2014-11-14 13:28:17.000000000 +0000 @@ -1,7 +1,8 @@ /* * Font and collections * - * Copyright 2012 Nikolay Sivov for CodeWeavers + * Copyright 2012, 2014 Nikolay Sivov for CodeWeavers + * Copyright 2014 Aric Stewart for CodeWeavers * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -20,29 +21,17 @@ #define COBJMACROS -#include "dwrite.h" #include "dwrite_private.h" WINE_DEFAULT_DEBUG_CHANNEL(dwrite); -#define MS_MAKE_TAG(ch0, ch1, ch2, ch3) \ - ((DWORD)(BYTE)(ch0) | ((DWORD)(BYTE)(ch1) << 8) | \ - ((DWORD)(BYTE)(ch2) << 16) | ((DWORD)(BYTE)(ch3) << 24)) - -#define MS_HEAD_TAG MS_MAKE_TAG('h','e','a','d') -#define MS_OS2_TAG MS_MAKE_TAG('O','S','/','2') -#define MS_POST_TAG MS_MAKE_TAG('p','o','s','t') -#define MS_CMAP_TAG MS_MAKE_TAG('c','m','a','p') +#define MS_HEAD_TAG DWRITE_MAKE_OPENTYPE_TAG('h','e','a','d') +#define MS_OS2_TAG DWRITE_MAKE_OPENTYPE_TAG('O','S','/','2') +#define MS_POST_TAG DWRITE_MAKE_OPENTYPE_TAG('p','o','s','t') +#define MS_CMAP_TAG DWRITE_MAKE_OPENTYPE_TAG('c','m','a','p') +#define MS_NAME_TAG DWRITE_MAKE_OPENTYPE_TAG('n','a','m','e') -struct dwrite_fontface_data { - LONG ref; - - DWRITE_FONT_FACE_TYPE type; - UINT32 file_count; - IDWriteFontFile ** files; - DWRITE_FONT_SIMULATIONS simulations; - UINT32 index; -}; +static const IID IID_issystemcollection = {0x14d88047,0x331f,0x4cd3,{0xbc,0xa8,0x3e,0x67,0x99,0xaf,0x34,0x75}}; struct dwrite_font_data { LONG ref; @@ -50,29 +39,36 @@ DWRITE_FONT_STYLE style; DWRITE_FONT_STRETCH stretch; DWRITE_FONT_WEIGHT weight; - DWRITE_FONT_SIMULATIONS simulations; - DWRITE_FONT_METRICS metrics; + DWRITE_FONT_METRICS1 metrics; + IDWriteLocalizedStrings *info_strings[DWRITE_INFORMATIONAL_STRING_POSTSCRIPT_CID_NAME+1]; - struct dwrite_fontface_data *face_data; + /* data needed to create fontface instance */ + IDWriteFactory *factory; + DWRITE_FONT_FACE_TYPE face_type; + IDWriteFontFile *file; + UINT32 face_index; WCHAR *facename; }; struct dwrite_fontfamily_data { + LONG ref; + IDWriteLocalizedStrings *familyname; struct dwrite_font_data **fonts; - UINT32 font_count; - UINT32 alloc; + UINT32 font_count; + UINT32 font_alloc; }; struct dwrite_fontcollection { IDWriteFontCollection IDWriteFontCollection_iface; LONG ref; - WCHAR **families; - UINT32 count; - int alloc; + struct dwrite_fontfamily_data **family_data; + UINT32 family_count; + UINT32 family_alloc; + BOOL is_system; }; struct dwrite_fontfamily { @@ -85,36 +81,43 @@ }; struct dwrite_font { - IDWriteFont IDWriteFont_iface; + IDWriteFont2 IDWriteFont2_iface; LONG ref; - BOOL is_system; IDWriteFontFamily *family; - IDWriteFontFace *face; + USHORT simulations; struct dwrite_font_data *data; }; #define DWRITE_FONTTABLE_MAGIC 0xededfafa -struct dwrite_fonttable { +struct dwrite_fonttablecontext { UINT32 magic; - LPVOID context; + void *context; UINT32 file_index; }; +struct dwrite_fonttable { + void *data; + void *context; + UINT32 size; +}; + struct dwrite_fontface { - IDWriteFontFace IDWriteFontFace_iface; + IDWriteFontFace2 IDWriteFontFace2_iface; LONG ref; - struct dwrite_fontface_data *data; + IDWriteFontFileStream **streams; + IDWriteFontFile **files; + UINT32 file_count; + UINT32 index; - LPVOID CMAP_table; - LPVOID CMAP_context; - DWORD CMAP_size; + USHORT simulations; + DWRITE_FONT_FACE_TYPE type; + DWRITE_FONT_METRICS1 metrics; - BOOL is_system; - LOGFONTW logfont; + struct dwrite_fonttable cmap; }; struct dwrite_fontfile { @@ -127,18 +130,16 @@ IDWriteFontFileStream *stream; }; -static HRESULT create_fontfamily(IDWriteLocalizedStrings *familyname, IDWriteFontFamily **family); -static HRESULT create_font_base(IDWriteFont **font); -static HRESULT create_font_from_data(struct dwrite_font_data *data, IDWriteFont **font); +static HRESULT get_filestream_from_file(IDWriteFontFile*,IDWriteFontFileStream**); -static inline struct dwrite_fontface *impl_from_IDWriteFontFace(IDWriteFontFace *iface) +static inline struct dwrite_fontface *impl_from_IDWriteFontFace2(IDWriteFontFace2 *iface) { - return CONTAINING_RECORD(iface, struct dwrite_fontface, IDWriteFontFace_iface); + return CONTAINING_RECORD(iface, struct dwrite_fontface, IDWriteFontFace2_iface); } -static inline struct dwrite_font *impl_from_IDWriteFont(IDWriteFont *iface) +static inline struct dwrite_font *impl_from_IDWriteFont2(IDWriteFont2 *iface) { - return CONTAINING_RECORD(iface, struct dwrite_font, IDWriteFont_iface); + return CONTAINING_RECORD(iface, struct dwrite_font, IDWriteFont2_iface); } static inline struct dwrite_fontfile *impl_from_IDWriteFontFile(IDWriteFontFile *iface) @@ -156,26 +157,25 @@ return CONTAINING_RECORD(iface, struct dwrite_fontcollection, IDWriteFontCollection_iface); } -static HRESULT _dwritefontfile_GetFontFileStream(IDWriteFontFile *iface, IDWriteFontFileStream **stream) +static inline void* get_fontface_cmap(struct dwrite_fontface *fontface) { + BOOL exists = FALSE; HRESULT hr; - struct dwrite_fontfile *This = impl_from_IDWriteFontFile(iface); - if (!This->stream) - { - hr = IDWriteFontFileLoader_CreateStreamFromKey(This->loader, This->reference_key, This->key_size, &This->stream); - if (FAILED(hr)) - return hr; - } - if (This->stream) - { - IDWriteFontFileStream_AddRef(This->stream); - *stream = This->stream; - return S_OK; + + if (fontface->cmap.data) + return fontface->cmap.data; + + hr = IDWriteFontFace2_TryGetFontTable(&fontface->IDWriteFontFace2_iface, MS_CMAP_TAG, (const void**)&fontface->cmap.data, + &fontface->cmap.size, &fontface->cmap.context, &exists); + if (FAILED(hr) || !exists) { + ERR("Font does not have a CMAP table\n"); + return NULL; } - return E_FAIL; + + return fontface->cmap.data; } -static VOID _free_fontface_data(struct dwrite_fontface_data *data) +static void release_font_data(struct dwrite_font_data *data) { int i; if (!data) @@ -183,13 +183,19 @@ i = InterlockedDecrement(&data->ref); if (i > 0) return; - for (i = 0; i < data->file_count; i++) - IDWriteFontFile_Release(data->files[i]); - heap_free(data->files); + + for (i = DWRITE_INFORMATIONAL_STRING_NONE; i < sizeof(data->info_strings)/sizeof(data->info_strings[0]); i++) { + if (data->info_strings[i]) + IDWriteLocalizedStrings_Release(data->info_strings[i]); + } + + IDWriteFontFile_Release(data->file); + IDWriteFactory_Release(data->factory); + heap_free(data->facename); heap_free(data); } -static VOID _free_font_data(struct dwrite_font_data *data) +static VOID _free_fontfamily_data(struct dwrite_fontfamily_data *data) { int i; if (!data) @@ -197,21 +203,26 @@ i = InterlockedDecrement(&data->ref); if (i > 0) return; - _free_fontface_data(data->face_data); - heap_free(data->facename); + for (i = 0; i < data->font_count; i++) + release_font_data(data->fonts[i]); + heap_free(data->fonts); + IDWriteLocalizedStrings_Release(data->familyname); heap_free(data); } -static HRESULT WINAPI dwritefontface_QueryInterface(IDWriteFontFace *iface, REFIID riid, void **obj) +static HRESULT WINAPI dwritefontface_QueryInterface(IDWriteFontFace2 *iface, REFIID riid, void **obj) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), obj); - if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IDWriteFontFace)) + if (IsEqualIID(riid, &IID_IDWriteFontFace2) || + IsEqualIID(riid, &IID_IDWriteFontFace1) || + IsEqualIID(riid, &IID_IDWriteFontFace) || + IsEqualIID(riid, &IID_IUnknown)) { *obj = iface; - IDWriteFontFace_AddRef(iface); + IDWriteFontFace2_AddRef(iface); return S_OK; } @@ -219,261 +230,353 @@ return E_NOINTERFACE; } -static ULONG WINAPI dwritefontface_AddRef(IDWriteFontFace *iface) +static ULONG WINAPI dwritefontface_AddRef(IDWriteFontFace2 *iface) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); ULONG ref = InterlockedIncrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); return ref; } -static ULONG WINAPI dwritefontface_Release(IDWriteFontFace *iface) +static ULONG WINAPI dwritefontface_Release(IDWriteFontFace2 *iface) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); ULONG ref = InterlockedDecrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); - if (!ref) - { - if (This->CMAP_context) - IDWriteFontFace_ReleaseFontTable(iface, This->CMAP_context); - _free_fontface_data(This->data); + if (!ref) { + UINT32 i; + + if (This->cmap.context) + IDWriteFontFace2_ReleaseFontTable(iface, This->cmap.context); + for (i = 0; i < This->file_count; i++) { + if (This->streams[i]) + IDWriteFontFileStream_Release(This->streams[i]); + if (This->files[i]) + IDWriteFontFile_Release(This->files[i]); + } heap_free(This); } return ref; } -static DWRITE_FONT_FACE_TYPE WINAPI dwritefontface_GetType(IDWriteFontFace *iface) +static DWRITE_FONT_FACE_TYPE WINAPI dwritefontface_GetType(IDWriteFontFace2 *iface) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); TRACE("(%p)\n", This); - return This->data->type; + return This->type; } -static HRESULT WINAPI dwritefontface_GetFiles(IDWriteFontFace *iface, UINT32 *number_of_files, +static HRESULT WINAPI dwritefontface_GetFiles(IDWriteFontFace2 *iface, UINT32 *number_of_files, IDWriteFontFile **fontfiles) { + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); int i; - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + TRACE("(%p)->(%p %p)\n", This, number_of_files, fontfiles); if (fontfiles == NULL) { - *number_of_files = This->data->file_count; + *number_of_files = This->file_count; return S_OK; } - if (*number_of_files < This->data->file_count) + if (*number_of_files < This->file_count) return E_INVALIDARG; - for (i = 0; i < This->data->file_count; i++) + for (i = 0; i < This->file_count; i++) { - IDWriteFontFile_AddRef(This->data->files[i]); - fontfiles[i] = This->data->files[i]; + IDWriteFontFile_AddRef(This->files[i]); + fontfiles[i] = This->files[i]; } return S_OK; } -static UINT32 WINAPI dwritefontface_GetIndex(IDWriteFontFace *iface) +static UINT32 WINAPI dwritefontface_GetIndex(IDWriteFontFace2 *iface) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); TRACE("(%p)\n", This); - return This->data->index; + return This->index; } -static DWRITE_FONT_SIMULATIONS WINAPI dwritefontface_GetSimulations(IDWriteFontFace *iface) +static DWRITE_FONT_SIMULATIONS WINAPI dwritefontface_GetSimulations(IDWriteFontFace2 *iface) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); TRACE("(%p)\n", This); - return This->data->simulations; + return This->simulations; } -static BOOL WINAPI dwritefontface_IsSymbolFont(IDWriteFontFace *iface) +static BOOL WINAPI dwritefontface_IsSymbolFont(IDWriteFontFace2 *iface) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); FIXME("(%p): stub\n", This); return FALSE; } -static void WINAPI dwritefontface_GetMetrics(IDWriteFontFace *iface, DWRITE_FONT_METRICS *metrics) +static void WINAPI dwritefontface_GetMetrics(IDWriteFontFace2 *iface, DWRITE_FONT_METRICS *metrics) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); - FIXME("(%p)->(%p): stub\n", This, metrics); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + TRACE("(%p)->(%p)\n", This, metrics); + memcpy(metrics, &This->metrics, sizeof(*metrics)); } -static UINT16 WINAPI dwritefontface_GetGlyphCount(IDWriteFontFace *iface) +static UINT16 WINAPI dwritefontface_GetGlyphCount(IDWriteFontFace2 *iface) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); FIXME("(%p): stub\n", This); return 0; } -static HRESULT WINAPI dwritefontface_GetDesignGlyphMetrics(IDWriteFontFace *iface, +static HRESULT WINAPI dwritefontface_GetDesignGlyphMetrics(IDWriteFontFace2 *iface, UINT16 const *glyph_indices, UINT32 glyph_count, DWRITE_GLYPH_METRICS *metrics, BOOL is_sideways) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); FIXME("(%p)->(%p %u %p %d): stub\n", This, glyph_indices, glyph_count, metrics, is_sideways); return E_NOTIMPL; } -static HRESULT WINAPI dwritefontface_GetGlyphIndices(IDWriteFontFace *iface, UINT32 const *codepoints, +static HRESULT WINAPI dwritefontface_GetGlyphIndices(IDWriteFontFace2 *iface, UINT32 const *codepoints, UINT32 count, UINT16 *glyph_indices) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); unsigned int i; + void *data; - if (This->is_system) - { - HFONT hfont; - WCHAR *str; - HDC hdc; - - TRACE("(%p)->(%p %u %p)\n", This, codepoints, count, glyph_indices); - - str = heap_alloc(count*sizeof(WCHAR)); - if (!str) return E_OUTOFMEMORY; - - for (i = 0; i < count; i++) - str[i] = codepoints[i] < 0x10000 ? codepoints[i] : '?'; + TRACE("(%p)->(%p %u %p)\n", This, codepoints, count, glyph_indices); - hdc = CreateCompatibleDC(0); - hfont = CreateFontIndirectW(&This->logfont); - SelectObject(hdc, hfont); - - GetGlyphIndicesW(hdc, str, count, glyph_indices, 0); - heap_free(str); - - DeleteDC(hdc); - DeleteObject(hfont); + data = get_fontface_cmap(This); + if (!data) + return E_FAIL; - return S_OK; - } - else - { - HRESULT hr; - TRACE("(%p)->(%p %u %p)\n", This, codepoints, count, glyph_indices); - if (!This->CMAP_table) - { - BOOL exists = FALSE; - hr = IDWriteFontFace_TryGetFontTable(iface, MS_CMAP_TAG, (const void**)&This->CMAP_table, &This->CMAP_size, &This->CMAP_context, &exists); - if (FAILED(hr) || !exists) - { - ERR("Font does not have a CMAP table\n"); - return E_FAIL; - } - } + for (i = 0; i < count; i++) + opentype_cmap_get_glyphindex(data, codepoints[i], &glyph_indices[i]); - for (i = 0; i < count; i++) - { - OpenType_CMAP_GetGlyphIndex(This->CMAP_table, codepoints[i], &glyph_indices[i], 0); - } - return S_OK; - } + return S_OK; } -static HRESULT WINAPI dwritefontface_TryGetFontTable(IDWriteFontFace *iface, UINT32 table_tag, +static HRESULT WINAPI dwritefontface_TryGetFontTable(IDWriteFontFace2 *iface, UINT32 table_tag, const void **table_data, UINT32 *table_size, void **context, BOOL *exists) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); - if (This->is_system) - { - FIXME("(%p)->(%u %p %p %p %p): stub\n", This, table_tag, table_data, table_size, context, exists); - return E_NOTIMPL; - } - else - { - HRESULT hr = S_OK; - int i; - struct dwrite_fonttable *table; - - TRACE("(%p)->(%u %p %p %p %p)\n", This, table_tag, table_data, table_size, context, exists); - - table = heap_alloc(sizeof(struct dwrite_fonttable)); - if (!table) - return E_OUTOFMEMORY; - table->magic = DWRITE_FONTTABLE_MAGIC; + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + struct dwrite_fonttablecontext *tablecontext; + HRESULT hr = S_OK; + int i; - *exists = FALSE; - for (i = 0; i < This->data->file_count && !(*exists); i++) - { - IDWriteFontFileStream *stream; - hr = _dwritefontfile_GetFontFileStream(This->data->files[i], &stream); - if (FAILED(hr)) - continue; - table->file_index = i; + TRACE("(%p)->(%u %p %p %p %p)\n", This, table_tag, table_data, table_size, context, exists); - hr = find_font_table(stream, This->data->index, table_tag, table_data, &table->context, table_size, exists); + tablecontext = heap_alloc(sizeof(struct dwrite_fonttablecontext)); + if (!tablecontext) + return E_OUTOFMEMORY; + tablecontext->magic = DWRITE_FONTTABLE_MAGIC; - IDWriteFontFileStream_Release(stream); - } - if (FAILED(hr) && !*exists) - heap_free(table); - else - *context = (LPVOID)table; - return hr; + *exists = FALSE; + for (i = 0; i < This->file_count && !(*exists); i++) { + hr = opentype_get_font_table(This->streams[i], This->type, This->index, table_tag, table_data, &tablecontext->context, table_size, exists); + tablecontext->file_index = i; } + if (FAILED(hr) && !*exists) + heap_free(tablecontext); + else + *context = (void*)tablecontext; + + return hr; } -static void WINAPI dwritefontface_ReleaseFontTable(IDWriteFontFace *iface, void *table_context) +static void WINAPI dwritefontface_ReleaseFontTable(IDWriteFontFace2 *iface, void *table_context) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); - struct dwrite_fonttable *table = (struct dwrite_fonttable *)table_context; - IDWriteFontFileStream *stream; - HRESULT hr; + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + struct dwrite_fonttablecontext *tablecontext = (struct dwrite_fonttablecontext*)table_context; + TRACE("(%p)->(%p)\n", This, table_context); - if (table->magic != DWRITE_FONTTABLE_MAGIC) + if (tablecontext->magic != DWRITE_FONTTABLE_MAGIC) { TRACE("Invalid table magic\n"); return; } - hr = _dwritefontfile_GetFontFileStream(This->data->files[table->file_index], &stream); - if (FAILED(hr)) - return; - IDWriteFontFileStream_ReleaseFileFragment(stream, table->context); - IDWriteFontFileStream_Release(stream); - heap_free(table); + IDWriteFontFileStream_ReleaseFileFragment(This->streams[tablecontext->file_index], tablecontext->context); + heap_free(tablecontext); } -static HRESULT WINAPI dwritefontface_GetGlyphRunOutline(IDWriteFontFace *iface, FLOAT emSize, +static HRESULT WINAPI dwritefontface_GetGlyphRunOutline(IDWriteFontFace2 *iface, FLOAT emSize, UINT16 const *glyph_indices, FLOAT const* glyph_advances, DWRITE_GLYPH_OFFSET const *glyph_offsets, UINT32 glyph_count, BOOL is_sideways, BOOL is_rtl, IDWriteGeometrySink *geometrysink) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); FIXME("(%p)->(%f %p %p %p %u %d %d %p): stub\n", This, emSize, glyph_indices, glyph_advances, glyph_offsets, glyph_count, is_sideways, is_rtl, geometrysink); return E_NOTIMPL; } -static HRESULT WINAPI dwritefontface_GetRecommendedRenderingMode(IDWriteFontFace *iface, FLOAT emSize, +static HRESULT WINAPI dwritefontface_GetRecommendedRenderingMode(IDWriteFontFace2 *iface, FLOAT emSize, FLOAT pixels_per_dip, DWRITE_MEASURING_MODE mode, IDWriteRenderingParams* params, DWRITE_RENDERING_MODE* rendering_mode) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); FIXME("(%p)->(%f %f %d %p %p): stub\n", This, emSize, pixels_per_dip, mode, params, rendering_mode); return E_NOTIMPL; } -static HRESULT WINAPI dwritefontface_GetGdiCompatibleMetrics(IDWriteFontFace *iface, FLOAT emSize, FLOAT pixels_per_dip, +static HRESULT WINAPI dwritefontface_GetGdiCompatibleMetrics(IDWriteFontFace2 *iface, FLOAT emSize, FLOAT pixels_per_dip, DWRITE_MATRIX const *transform, DWRITE_FONT_METRICS *metrics) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); FIXME("(%p)->(%f %f %p %p): stub\n", This, emSize, pixels_per_dip, transform, metrics); return E_NOTIMPL; } -static HRESULT WINAPI dwritefontface_GetGdiCompatibleGlyphMetrics(IDWriteFontFace *iface, FLOAT emSize, FLOAT pixels_per_dip, +static HRESULT WINAPI dwritefontface_GetGdiCompatibleGlyphMetrics(IDWriteFontFace2 *iface, FLOAT emSize, FLOAT pixels_per_dip, DWRITE_MATRIX const *transform, BOOL use_gdi_natural, UINT16 const *glyph_indices, UINT32 glyph_count, DWRITE_GLYPH_METRICS *metrics, BOOL is_sideways) { - struct dwrite_fontface *This = impl_from_IDWriteFontFace(iface); + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); FIXME("(%p)->(%f %f %p %d %p %u %p %d): stub\n", This, emSize, pixels_per_dip, transform, use_gdi_natural, glyph_indices, glyph_count, metrics, is_sideways); return E_NOTIMPL; } -static const IDWriteFontFaceVtbl dwritefontfacevtbl = { +static void WINAPI dwritefontface1_GetMetrics(IDWriteFontFace2 *iface, DWRITE_FONT_METRICS1 *metrics) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + TRACE("(%p)->(%p)\n", This, metrics); + *metrics = This->metrics; +} + +static HRESULT WINAPI dwritefontface1_GetGdiCompatibleMetrics(IDWriteFontFace2 *iface, FLOAT em_size, FLOAT pixels_per_dip, + const DWRITE_MATRIX *transform, DWRITE_FONT_METRICS1 *metrics) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%f %f %p %p): stub\n", This, em_size, pixels_per_dip, transform, metrics); + return E_NOTIMPL; +} + +static void WINAPI dwritefontface1_GetCaretMetrics(IDWriteFontFace2 *iface, DWRITE_CARET_METRICS *metrics) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%p): stub\n", This, metrics); +} + +static HRESULT WINAPI dwritefontface1_GetUnicodeRanges(IDWriteFontFace2 *iface, UINT32 max_count, + DWRITE_UNICODE_RANGE *ranges, UINT32 *count) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + + TRACE("(%p)->(%u %p %p)\n", This, max_count, ranges, count); + + *count = 0; + if (max_count && !ranges) + return E_INVALIDARG; + + return opentype_cmap_get_unicode_ranges(get_fontface_cmap(This), max_count, ranges, count); +} + +static BOOL WINAPI dwritefontface1_IsMonospacedFont(IDWriteFontFace2 *iface) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p): stub\n", This); + return FALSE; +} + +static HRESULT WINAPI dwritefontface1_GetDesignGlyphAdvances(IDWriteFontFace2 *iface, + UINT32 glyph_count, UINT16 const *indices, INT32 *advances, BOOL is_sideways) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%u %p %p %d): stub\n", This, glyph_count, indices, advances, is_sideways); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritefontface1_GetGdiCompatibleGlyphAdvances(IDWriteFontFace2 *iface, + FLOAT em_size, FLOAT pixels_per_dip, const DWRITE_MATRIX *transform, BOOL use_gdi_natural, + BOOL is_sideways, UINT32 glyph_count, UINT16 const *indices, INT32 *advances) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%f %f %p %d %d %u %p %p): stub\n", This, em_size, pixels_per_dip, transform, + use_gdi_natural, is_sideways, glyph_count, indices, advances); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritefontface1_GetKerningPairAdjustments(IDWriteFontFace2 *iface, UINT32 glyph_count, + const UINT16 *indices, INT32 *adjustments) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%u %p %p): stub\n", This, glyph_count, indices, adjustments); + return E_NOTIMPL; +} + +static BOOL WINAPI dwritefontface1_HasKerningPairs(IDWriteFontFace2 *iface) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p): stub\n", This); + return FALSE; +} + +static HRESULT WINAPI dwritefontface1_GetRecommendedRenderingMode(IDWriteFontFace2 *iface, + FLOAT font_emsize, FLOAT dpiX, FLOAT dpiY, const DWRITE_MATRIX *transform, BOOL is_sideways, + DWRITE_OUTLINE_THRESHOLD threshold, DWRITE_MEASURING_MODE measuring_mode, DWRITE_RENDERING_MODE *rendering_mode) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%f %f %f %p %d %d %d %p): stub\n", This, font_emsize, dpiX, dpiY, transform, is_sideways, + threshold, measuring_mode, rendering_mode); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritefontface1_GetVerticalGlyphVariants(IDWriteFontFace2 *iface, UINT32 glyph_count, + const UINT16 *nominal_indices, UINT16 *vertical_indices) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%u %p %p): stub\n", This, glyph_count, nominal_indices, vertical_indices); + return E_NOTIMPL; +} + +static BOOL WINAPI dwritefontface1_HasVerticalGlyphVariants(IDWriteFontFace2 *iface) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p): stub\n", This); + return FALSE; +} + +static BOOL WINAPI dwritefontface2_IsColorFont(IDWriteFontFace2 *iface) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p): stub\n", This); + return FALSE; +} + +static UINT32 WINAPI dwritefontface2_GetColorPaletteCount(IDWriteFontFace2 *iface) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p): stub\n", This); + return 0; +} + +static UINT32 WINAPI dwritefontface2_GetPaletteEntryCount(IDWriteFontFace2 *iface) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p): stub\n", This); + return 0; +} + +static HRESULT WINAPI dwritefontface2_GetPaletteEntries(IDWriteFontFace2 *iface, UINT32 palette_index, + UINT32 first_entry_index, UINT32 entry_count, DWRITE_COLOR_F *entries) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%u %u %u %p): stub\n", This, palette_index, first_entry_index, entry_count, entries); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritefontface2_GetRecommendedRenderingMode(IDWriteFontFace2 *iface, FLOAT fontEmSize, + FLOAT dpiX, FLOAT dpiY, DWRITE_MATRIX const *transform, BOOL is_sideways, DWRITE_OUTLINE_THRESHOLD threshold, + DWRITE_MEASURING_MODE measuringmode, IDWriteRenderingParams *params, DWRITE_RENDERING_MODE *renderingmode, + DWRITE_GRID_FIT_MODE *gridfitmode) +{ + struct dwrite_fontface *This = impl_from_IDWriteFontFace2(iface); + FIXME("(%p)->(%f %f %f %p %d %d %d %p %p %p): stub\n", This, fontEmSize, dpiX, dpiY, transform, is_sideways, threshold, + measuringmode, params, renderingmode, gridfitmode); + return E_NOTIMPL; +} + +static const IDWriteFontFace2Vtbl dwritefontfacevtbl = { dwritefontface_QueryInterface, dwritefontface_AddRef, dwritefontface_Release, @@ -491,66 +594,129 @@ dwritefontface_GetGlyphRunOutline, dwritefontface_GetRecommendedRenderingMode, dwritefontface_GetGdiCompatibleMetrics, - dwritefontface_GetGdiCompatibleGlyphMetrics + dwritefontface_GetGdiCompatibleGlyphMetrics, + dwritefontface1_GetMetrics, + dwritefontface1_GetGdiCompatibleMetrics, + dwritefontface1_GetCaretMetrics, + dwritefontface1_GetUnicodeRanges, + dwritefontface1_IsMonospacedFont, + dwritefontface1_GetDesignGlyphAdvances, + dwritefontface1_GetGdiCompatibleGlyphAdvances, + dwritefontface1_GetKerningPairAdjustments, + dwritefontface1_HasKerningPairs, + dwritefontface1_GetRecommendedRenderingMode, + dwritefontface1_GetVerticalGlyphVariants, + dwritefontface1_HasVerticalGlyphVariants, + dwritefontface2_IsColorFont, + dwritefontface2_GetColorPaletteCount, + dwritefontface2_GetPaletteEntryCount, + dwritefontface2_GetPaletteEntries, + dwritefontface2_GetRecommendedRenderingMode }; -static HRESULT create_system_fontface(struct dwrite_font *font, IDWriteFontFace **face) +static void get_font_properties_from_stream(IDWriteFontFileStream *stream, DWRITE_FONT_FACE_TYPE face_type, + UINT32 face_index, DWRITE_FONT_METRICS1 *metrics, DWRITE_FONT_STRETCH *stretch, DWRITE_FONT_WEIGHT *weight, + DWRITE_FONT_STYLE *style) +{ + const void *tt_os2 = NULL, *tt_head = NULL, *tt_post = NULL; + void *os2_context, *head_context, *post_context; + DWRITE_FONT_STRETCH fontstretch; + DWRITE_FONT_WEIGHT fontweight; + DWRITE_FONT_STYLE fontstyle; + + opentype_get_font_table(stream, face_type, face_index, MS_OS2_TAG, &tt_os2, &os2_context, NULL, NULL); + opentype_get_font_table(stream, face_type, face_index, MS_HEAD_TAG, &tt_head, &head_context, NULL, NULL); + opentype_get_font_table(stream, face_type, face_index, MS_POST_TAG, &tt_post, &post_context, NULL, NULL); + + if (!stretch) stretch = &fontstretch; + if (!weight) weight = &fontweight; + if (!style) style = &fontstyle; + + opentype_get_font_properties(tt_os2, tt_head, stretch, weight, style); + opentype_get_font_metrics(tt_os2, tt_head, tt_post, metrics); + + if (tt_os2) + IDWriteFontFileStream_ReleaseFileFragment(stream, os2_context); + if (tt_head) + IDWriteFontFileStream_ReleaseFileFragment(stream, head_context); + if (tt_post) + IDWriteFontFileStream_ReleaseFileFragment(stream, post_context); +} + +HRESULT convert_fontface_to_logfont(IDWriteFontFace *face, LOGFONTW *logfont) { - struct dwrite_fontface *This; + DWRITE_FONT_SIMULATIONS simulations; + DWRITE_FONT_FACE_TYPE face_type; + IDWriteFontFileStream *stream; + DWRITE_FONT_METRICS1 metrics; + DWRITE_FONT_STRETCH stretch; + DWRITE_FONT_STYLE style; + DWRITE_FONT_WEIGHT weight; + IDWriteFontFile *file = NULL; + UINT32 index; + HRESULT hr; - *face = NULL; + memset(logfont, 0, sizeof(*logfont)); - This = heap_alloc(sizeof(struct dwrite_fontface)); - if (!This) return E_OUTOFMEMORY; - This->data = heap_alloc(sizeof(struct dwrite_fontface_data)); - if (!This->data) - { - heap_free(This); - return E_OUTOFMEMORY; + index = 1; + hr = IDWriteFontFace_GetFiles(face, &index, &file); + if (FAILED(hr) || !file) + return hr; + + hr = get_filestream_from_file(file, &stream); + if (FAILED(hr)) { + IDWriteFontFile_Release(file); + return hr; } - This->IDWriteFontFace_iface.lpVtbl = &dwritefontfacevtbl; - This->ref = 1; - This->data->type = DWRITE_FONT_FACE_TYPE_UNKNOWN; - This->data->file_count = 0; - This->data->files = NULL; - This->data->index = 0; - This->data->simulations = DWRITE_FONT_SIMULATIONS_NONE; - This->CMAP_table = NULL; - This->CMAP_context = NULL; - This->CMAP_size = 0; - - This->is_system = TRUE; - memset(&This->logfont, 0, sizeof(This->logfont)); - This->logfont.lfItalic = font->data->style == DWRITE_FONT_STYLE_ITALIC; - /* weight values from DWRITE_FONT_WEIGHT match values used for LOGFONT */ - This->logfont.lfWeight = font->data->weight; - strcpyW(This->logfont.lfFaceName, font->data->facename); + index = IDWriteFontFace_GetIndex(face); + face_type = IDWriteFontFace_GetType(face); + get_font_properties_from_stream(stream, face_type, index, &metrics, &stretch, &weight, &style); + IDWriteFontFileStream_Release(stream); + + simulations = IDWriteFontFace_GetSimulations(face); - *face = &This->IDWriteFontFace_iface; + logfont->lfCharSet = DEFAULT_CHARSET; + logfont->lfWeight = weight; + logfont->lfItalic = style == DWRITE_FONT_STYLE_ITALIC || (simulations & DWRITE_FONT_SIMULATIONS_OBLIQUE); + logfont->lfOutPrecision = OUT_OUTLINE_PRECIS; + /* TODO: set facename */ return S_OK; } -HRESULT convert_fontface_to_logfont(IDWriteFontFace *face, LOGFONTW *logfont) +static HRESULT get_fontface_from_font(struct dwrite_font *font, IDWriteFontFace2 **fontface) { - struct dwrite_fontface *fontface = impl_from_IDWriteFontFace(face); + struct dwrite_font_data *data = font->data; + IDWriteFontFace *face; + HRESULT hr; - *logfont = fontface->logfont; + *fontface = NULL; - return S_OK; + hr = IDWriteFactory_CreateFontFace(data->factory, data->face_type, 1, &data->file, + data->face_index, font->simulations, &face); + if (FAILED(hr)) + return hr; + + hr = IDWriteFontFace_QueryInterface(face, &IID_IDWriteFontFace2, (void**)fontface); + IDWriteFontFace_Release(face); + + return hr; } -static HRESULT WINAPI dwritefont_QueryInterface(IDWriteFont *iface, REFIID riid, void **obj) +static HRESULT WINAPI dwritefont_QueryInterface(IDWriteFont2 *iface, REFIID riid, void **obj) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), obj); - if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IDWriteFont)) + if (IsEqualIID(riid, &IID_IDWriteFont2) || + IsEqualIID(riid, &IID_IDWriteFont1) || + IsEqualIID(riid, &IID_IDWriteFont) || + IsEqualIID(riid, &IID_IUnknown)) { *obj = iface; - IDWriteFont_AddRef(iface); + IDWriteFont2_AddRef(iface); return S_OK; } @@ -558,35 +724,33 @@ return E_NOINTERFACE; } -static ULONG WINAPI dwritefont_AddRef(IDWriteFont *iface) +static ULONG WINAPI dwritefont_AddRef(IDWriteFont2 *iface) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); ULONG ref = InterlockedIncrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); return ref; } -static ULONG WINAPI dwritefont_Release(IDWriteFont *iface) +static ULONG WINAPI dwritefont_Release(IDWriteFont2 *iface) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); ULONG ref = InterlockedDecrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); - if (!ref) - { - if (This->face) IDWriteFontFace_Release(This->face); - if (This->family) IDWriteFontFamily_Release(This->family); - _free_font_data(This->data); + if (!ref) { + IDWriteFontFamily_Release(This->family); + release_font_data(This->data); heap_free(This); } return ref; } -static HRESULT WINAPI dwritefont_GetFontFamily(IDWriteFont *iface, IDWriteFontFamily **family) +static HRESULT WINAPI dwritefont_GetFontFamily(IDWriteFont2 *iface, IDWriteFontFamily **family) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); TRACE("(%p)->(%p)\n", This, family); *family = This->family; @@ -594,124 +758,271 @@ return S_OK; } -static DWRITE_FONT_WEIGHT WINAPI dwritefont_GetWeight(IDWriteFont *iface) +static DWRITE_FONT_WEIGHT WINAPI dwritefont_GetWeight(IDWriteFont2 *iface) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); TRACE("(%p)\n", This); return This->data->weight; } -static DWRITE_FONT_STRETCH WINAPI dwritefont_GetStretch(IDWriteFont *iface) +static DWRITE_FONT_STRETCH WINAPI dwritefont_GetStretch(IDWriteFont2 *iface) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); TRACE("(%p)\n", This); return This->data->stretch; } -static DWRITE_FONT_STYLE WINAPI dwritefont_GetStyle(IDWriteFont *iface) +static DWRITE_FONT_STYLE WINAPI dwritefont_GetStyle(IDWriteFont2 *iface) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); TRACE("(%p)\n", This); return This->data->style; } -static BOOL WINAPI dwritefont_IsSymbolFont(IDWriteFont *iface) +static BOOL WINAPI dwritefont_IsSymbolFont(IDWriteFont2 *iface) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); FIXME("(%p): stub\n", This); return FALSE; } -static HRESULT WINAPI dwritefont_GetFaceNames(IDWriteFont *iface, IDWriteLocalizedStrings **names) +static HRESULT WINAPI dwritefont_GetFaceNames(IDWriteFont2 *iface, IDWriteLocalizedStrings **names) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); - FIXME("(%p)->(%p): stub\n", This, names); - return E_NOTIMPL; + static const WCHAR boldobliqueW[] = {'B','o','l','d',' ','O','b','l','i','q','u','e',0}; + static const WCHAR obliqueW[] = {'O','b','l','i','q','u','e',0}; + static const WCHAR boldW[] = {'B','o','l','d',0}; + static const WCHAR enusW[] = {'e','n','-','u','s',0}; + + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + IDWriteLocalizedStrings *strings; + const WCHAR *name; + HRESULT hr; + + TRACE("(%p)->(%p)\n", This, names); + + *names = NULL; + + if (This->simulations == DWRITE_FONT_SIMULATIONS_NONE) { + BOOL exists; + return IDWriteFont2_GetInformationalStrings(iface, DWRITE_INFORMATIONAL_STRING_WIN32_SUBFAMILY_NAMES, + names, &exists); + } + + switch (This->simulations) { + case DWRITE_FONT_SIMULATIONS_BOLD|DWRITE_FONT_SIMULATIONS_OBLIQUE: + name = boldobliqueW; + break; + case DWRITE_FONT_SIMULATIONS_BOLD: + name = boldW; + break; + case DWRITE_FONT_SIMULATIONS_OBLIQUE: + name = obliqueW; + break; + default: + ERR("unknown simulations %d\n", This->simulations); + return E_FAIL; + } + + hr = create_localizedstrings(&strings); + if (FAILED(hr)) return hr; + + hr = add_localizedstring(strings, enusW, name); + if (FAILED(hr)) { + IDWriteLocalizedStrings_Release(strings); + return hr; + } + + *names = strings; + + return S_OK; } -static HRESULT WINAPI dwritefont_GetInformationalStrings(IDWriteFont *iface, +static HRESULT WINAPI dwritefont_GetInformationalStrings(IDWriteFont2 *iface, DWRITE_INFORMATIONAL_STRING_ID stringid, IDWriteLocalizedStrings **strings, BOOL *exists) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); - FIXME("(%p)->(%d %p %p): stub\n", This, stringid, strings, exists); - return E_NOTIMPL; + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + struct dwrite_font_data *data = This->data; + HRESULT hr; + + TRACE("(%p)->(%d %p %p)\n", This, stringid, strings, exists); + + *exists = FALSE; + *strings = NULL; + + if (stringid > DWRITE_INFORMATIONAL_STRING_POSTSCRIPT_CID_NAME || stringid == DWRITE_INFORMATIONAL_STRING_NONE) + return S_OK; + + if (!data->info_strings[stringid]) { + IDWriteFontFace2 *fontface; + const void *table_data; + BOOL table_exists; + void *context; + UINT32 size; + + hr = get_fontface_from_font(This, &fontface); + if (FAILED(hr)) + return hr; + + table_exists = FALSE; + hr = IDWriteFontFace2_TryGetFontTable(fontface, MS_NAME_TAG, &table_data, &size, &context, &table_exists); + if (FAILED(hr) || !table_exists) + WARN("no NAME table found.\n"); + + if (table_exists) { + hr = opentype_get_font_strings_from_id(table_data, stringid, &data->info_strings[stringid]); + if (FAILED(hr) || !data->info_strings[stringid]) + return hr; + IDWriteFontFace2_ReleaseFontTable(fontface, context); + } + } + + hr = clone_localizedstring(data->info_strings[stringid], strings); + if (FAILED(hr)) + return hr; + + *exists = TRUE; + return S_OK; } -static DWRITE_FONT_SIMULATIONS WINAPI dwritefont_GetSimulations(IDWriteFont *iface) +static DWRITE_FONT_SIMULATIONS WINAPI dwritefont_GetSimulations(IDWriteFont2 *iface) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); TRACE("(%p)\n", This); - return This->data->simulations; + return This->simulations; } -static void WINAPI dwritefont_GetMetrics(IDWriteFont *iface, DWRITE_FONT_METRICS *metrics) +static void WINAPI dwritefont_GetMetrics(IDWriteFont2 *iface, DWRITE_FONT_METRICS *metrics) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); + struct dwrite_font *This = impl_from_IDWriteFont2(iface); TRACE("(%p)->(%p)\n", This, metrics); - *metrics = This->data->metrics; + memcpy(metrics, &This->data->metrics, sizeof(*metrics)); } -static HRESULT WINAPI dwritefont_HasCharacter(IDWriteFont *iface, UINT32 value, BOOL *exists) +static HRESULT WINAPI dwritefont_HasCharacter(IDWriteFont2 *iface, UINT32 value, BOOL *exists) { - struct dwrite_font *This = impl_from_IDWriteFont(iface); - FIXME("(%p)->(0x%08x %p): stub\n", This, value, exists); - return E_NOTIMPL; -} + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + IDWriteFontFace2 *fontface; + UINT16 index; + HRESULT hr; -static HRESULT WINAPI dwritefont_CreateFontFace(IDWriteFont *iface, IDWriteFontFace **face) -{ - struct dwrite_font *This = impl_from_IDWriteFont(iface); + TRACE("(%p)->(0x%08x %p)\n", This, value, exists); - if (This->is_system) - { - TRACE("(%p)->(%p)\n", This, face); + *exists = FALSE; - if (!This->face) - { - HRESULT hr = create_system_fontface(This, &This->face); - if (FAILED(hr)) return hr; - } + hr = get_fontface_from_font(This, &fontface); + if (FAILED(hr)) + return hr; - *face = This->face; - IDWriteFontFace_AddRef(*face); + index = 0; + hr = IDWriteFontFace2_GetGlyphIndices(fontface, &value, 1, &index); + if (FAILED(hr)) + return hr; - return S_OK; - } - else - { - TRACE("(%p)->(%p)\n", This, face); + *exists = index != 0; + return S_OK; +} - if (!This->face) - { - HRESULT hr = font_create_fontface(NULL, This->data->face_data->type, This->data->face_data->file_count, This->data->face_data->files, This->data->face_data->index, This->data->face_data->simulations, &This->face); - if (FAILED(hr)) return hr; - } +static HRESULT WINAPI dwritefont_CreateFontFace(IDWriteFont2 *iface, IDWriteFontFace **face) +{ + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + HRESULT hr; - *face = This->face; + TRACE("(%p)->(%p)\n", This, face); + + hr = get_fontface_from_font(This, (IDWriteFontFace2**)face); + if (hr == S_OK) IDWriteFontFace_AddRef(*face); - return S_OK; - } + return hr; } -static const IDWriteFontVtbl dwritefontvtbl = { - dwritefont_QueryInterface, - dwritefont_AddRef, - dwritefont_Release, - dwritefont_GetFontFamily, - dwritefont_GetWeight, - dwritefont_GetStretch, - dwritefont_GetStyle, +static void WINAPI dwritefont1_GetMetrics(IDWriteFont2 *iface, DWRITE_FONT_METRICS1 *metrics) +{ + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + TRACE("(%p)->(%p)\n", This, metrics); + *metrics = This->data->metrics; +} + +static void WINAPI dwritefont1_GetPanose(IDWriteFont2 *iface, DWRITE_PANOSE *panose) +{ + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + FIXME("(%p)->(%p): stub\n", This, panose); +} + +static HRESULT WINAPI dwritefont1_GetUnicodeRanges(IDWriteFont2 *iface, UINT32 max_count, DWRITE_UNICODE_RANGE *ranges, UINT32 *count) +{ + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + IDWriteFontFace2 *fontface; + HRESULT hr; + + TRACE("(%p)->(%u %p %p)\n", This, max_count, ranges, count); + + hr = get_fontface_from_font(This, &fontface); + if (FAILED(hr)) + return hr; + + return IDWriteFontFace2_GetUnicodeRanges(fontface, max_count, ranges, count); +} + +static HRESULT WINAPI dwritefont1_IsMonospacedFont(IDWriteFont2 *iface) +{ + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + FIXME("(%p): stub\n", This); + return FALSE; +} + +static HRESULT WINAPI dwritefont2_IsColorFont(IDWriteFont2 *iface) +{ + struct dwrite_font *This = impl_from_IDWriteFont2(iface); + FIXME("(%p): stub\n", This); + return FALSE; +} + +static const IDWriteFont2Vtbl dwritefontvtbl = { + dwritefont_QueryInterface, + dwritefont_AddRef, + dwritefont_Release, + dwritefont_GetFontFamily, + dwritefont_GetWeight, + dwritefont_GetStretch, + dwritefont_GetStyle, dwritefont_IsSymbolFont, dwritefont_GetFaceNames, dwritefont_GetInformationalStrings, dwritefont_GetSimulations, dwritefont_GetMetrics, dwritefont_HasCharacter, - dwritefont_CreateFontFace + dwritefont_CreateFontFace, + dwritefont1_GetMetrics, + dwritefont1_GetPanose, + dwritefont1_GetUnicodeRanges, + dwritefont1_IsMonospacedFont, + dwritefont2_IsColorFont }; +static HRESULT create_font(struct dwrite_font_data *data, IDWriteFontFamily *family, DWRITE_FONT_SIMULATIONS simulations, + IDWriteFont **font) +{ + struct dwrite_font *This; + *font = NULL; + + This = heap_alloc(sizeof(struct dwrite_font)); + if (!This) return E_OUTOFMEMORY; + + This->IDWriteFont2_iface.lpVtbl = &dwritefontvtbl; + This->ref = 1; + This->family = family; + IDWriteFontFamily_AddRef(family); + This->simulations = simulations; + This->data = data; + InterlockedIncrement(&This->data->ref); + + *font = (IDWriteFont*)&This->IDWriteFont2_iface; + + return S_OK; +} + static HRESULT WINAPI dwritefontfamily_QueryInterface(IDWriteFontFamily *iface, REFIID riid, void **obj) { struct dwrite_fontfamily *This = impl_from_IDWriteFontFamily(iface); @@ -747,15 +1058,8 @@ if (!ref) { - int i; - IDWriteLocalizedStrings_Release(This->data->familyname); - - if (This->collection) - IDWriteFontCollection_Release(This->collection); - for (i = 0; i < This->data->font_count; i++) - _free_font_data(This->data->fonts[i]); - heap_free(This->data->fonts); - heap_free(This->data); + IDWriteFontCollection_Release(This->collection); + _free_fontfamily_data(This->data); heap_free(This); } @@ -766,14 +1070,10 @@ { struct dwrite_fontfamily *This = impl_from_IDWriteFontFamily(iface); TRACE("(%p)->(%p)\n", This, collection); - if (This->collection) - { - IDWriteFontCollection_AddRef(This->collection); - *collection = This->collection; - return S_OK; - } - else - return E_NOTIMPL; + + *collection = This->collection; + IDWriteFontCollection_AddRef(This->collection); + return S_OK; } static UINT32 WINAPI dwritefontfamily_GetFontCount(IDWriteFontFamily *iface) @@ -786,23 +1086,18 @@ static HRESULT WINAPI dwritefontfamily_GetFont(IDWriteFontFamily *iface, UINT32 index, IDWriteFont **font) { struct dwrite_fontfamily *This = impl_from_IDWriteFontFamily(iface); + TRACE("(%p)->(%u %p)\n", This, index, font); - if (This->data->font_count > 0) - { - HRESULT hr; - if (index >= This->data->font_count) - return E_INVALIDARG; - hr = create_font_from_data(This->data->fonts[index], font); - if (SUCCEEDED(hr)) - { - struct dwrite_font *font_data = impl_from_IDWriteFont(*font); - font_data->family = iface; - IDWriteFontFamily_AddRef(iface); - } - return hr; - } - else - return E_NOTIMPL; + + *font = NULL; + + if (This->data->font_count == 0) + return S_FALSE; + + if (index >= This->data->font_count) + return E_INVALIDARG; + + return create_font(This->data->fonts[index], iface, DWRITE_FONT_SIMULATIONS_NONE, font); } static HRESULT WINAPI dwritefontfamily_GetFamilyNames(IDWriteFontFamily *iface, IDWriteLocalizedStrings **names) @@ -811,44 +1106,48 @@ return clone_localizedstring(This->data->familyname, names); } +static inline BOOL is_matching_font_style(DWRITE_FONT_STYLE style, DWRITE_FONT_STYLE font_style) +{ + if (style == font_style) + return TRUE; + + if (((style == DWRITE_FONT_STYLE_ITALIC) || (style == DWRITE_FONT_STYLE_OBLIQUE)) && font_style == DWRITE_FONT_STYLE_NORMAL) + return TRUE; + + return FALSE; +} + static HRESULT WINAPI dwritefontfamily_GetFirstMatchingFont(IDWriteFontFamily *iface, DWRITE_FONT_WEIGHT weight, DWRITE_FONT_STRETCH stretch, DWRITE_FONT_STYLE style, IDWriteFont **font) { struct dwrite_fontfamily *This = impl_from_IDWriteFontFamily(iface); - LOGFONTW lf; + UINT32 min_weight_diff = ~0u; + int found = -1, i; TRACE("(%p)->(%d %d %d %p)\n", This, weight, stretch, style, font); - /* fallback for system font collections */ - if (This->data->font_count == 0) - { - memset(&lf, 0, sizeof(lf)); - lf.lfWeight = weight; - lf.lfItalic = style == DWRITE_FONT_STYLE_ITALIC; - IDWriteLocalizedStrings_GetString(This->data->familyname, 0, lf.lfFaceName, LF_FACESIZE); - - return create_font_from_logfont(&lf, font); - } - else - { - int i; - for (i = 0; i < This->data->font_count; i++) - { - if (style == This->data->fonts[i]->style && - weight == This->data->fonts[i]->weight && - stretch == This->data->fonts[i]->stretch) - { - HRESULT hr; - hr = create_font_from_data(This->data->fonts[i], font); - if (SUCCEEDED(hr)) - { - struct dwrite_font *font_data = impl_from_IDWriteFont(*font); - font_data->family = iface; - IDWriteFontFamily_AddRef(iface); - } - return hr; + for (i = 0; i < This->data->font_count; i++) { + if (is_matching_font_style(style, This->data->fonts[i]->style) && stretch == This->data->fonts[i]->stretch) { + DWRITE_FONT_WEIGHT font_weight = This->data->fonts[i]->weight; + UINT32 weight_diff = abs(font_weight - weight); + if (weight_diff < min_weight_diff) { + min_weight_diff = weight_diff; + found = i; } } + } + + if (found != -1) { + DWRITE_FONT_SIMULATIONS simulations = DWRITE_FONT_SIMULATIONS_NONE; + + if (((style == DWRITE_FONT_STYLE_ITALIC) || (style == DWRITE_FONT_STYLE_OBLIQUE)) && + This->data->fonts[found]->style == DWRITE_FONT_STYLE_NORMAL) { + simulations = DWRITE_FONT_SIMULATIONS_OBLIQUE; + } + return create_font(This->data->fonts[found], iface, simulations, font); + } + else { + *font = NULL; return DWRITE_E_NOFONT; } } @@ -873,6 +1172,33 @@ dwritefontfamily_GetMatchingFonts }; +static HRESULT create_fontfamily(struct dwrite_fontfamily_data *data, IDWriteFontCollection *collection, IDWriteFontFamily **family) +{ + struct dwrite_fontfamily *This; + + *family = NULL; + + This = heap_alloc(sizeof(struct dwrite_fontfamily)); + if (!This) return E_OUTOFMEMORY; + + This->IDWriteFontFamily_iface.lpVtbl = &fontfamilyvtbl; + This->ref = 1; + This->collection = collection; + IDWriteFontCollection_AddRef(collection); + This->data = data; + InterlockedIncrement(&This->data->ref); + + *family = &This->IDWriteFontFamily_iface; + + return S_OK; +} + +BOOL is_system_collection(IDWriteFontCollection *collection) +{ + void *obj; + return IDWriteFontCollection_QueryInterface(collection, &IID_issystemcollection, (void**)&obj) == S_OK; +} + static HRESULT WINAPI dwritefontcollection_QueryInterface(IDWriteFontCollection *iface, REFIID riid, void **obj) { struct dwrite_fontcollection *This = impl_from_IDWriteFontCollection(iface); @@ -887,6 +1213,10 @@ } *obj = NULL; + + if (This->is_system && IsEqualIID(riid, &IID_issystemcollection)) + return S_OK; + return E_NOINTERFACE; } @@ -905,11 +1235,10 @@ ULONG ref = InterlockedDecrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); - if (!ref) - { - for (i = 0; i < This->count; i++) - heap_free(This->families[i]); - heap_free(This->families); + if (!ref) { + for (i = 0; i < This->family_count; i++) + _free_fontfamily_data(This->family_data[i]); + heap_free(This->family_data); heap_free(This); } @@ -920,58 +1249,130 @@ { struct dwrite_fontcollection *This = impl_from_IDWriteFontCollection(iface); TRACE("(%p)\n", This); - return This->count; + return This->family_count; } static HRESULT WINAPI dwritefontcollection_GetFontFamily(IDWriteFontCollection *iface, UINT32 index, IDWriteFontFamily **family) { struct dwrite_fontcollection *This = impl_from_IDWriteFontCollection(iface); - HRESULT hr; - IDWriteLocalizedStrings *familyname; - static const WCHAR enusW[] = {'e','n','-','u','s',0}; TRACE("(%p)->(%u %p)\n", This, index, family); - if (index >= This->count) - { + if (index >= This->family_count) { *family = NULL; return E_FAIL; } - hr = create_localizedstrings(&familyname); - if (FAILED(hr)) - return hr; - add_localizedstring(familyname, enusW, This->families[index]); + return create_fontfamily(This->family_data[index], iface, family); +} + +static HRESULT collection_find_family(struct dwrite_fontcollection *collection, const WCHAR *name, UINT32 *index, BOOL *exists) +{ + UINT32 i; - return create_fontfamily(familyname, family); + if (collection->family_count) { + for (i = 0; i < collection->family_count; i++) { + IDWriteLocalizedStrings *family_name = collection->family_data[i]->familyname; + HRESULT hr; + int j; + + for (j = 0; j < IDWriteLocalizedStrings_GetCount(family_name); j++) { + WCHAR buffer[255]; + hr = IDWriteLocalizedStrings_GetString(family_name, j, buffer, 255); + if (SUCCEEDED(hr)) { + if (!strcmpW(buffer, name)) { + *index = i; + *exists = TRUE; + return S_OK; + } + } + } + } + *index = (UINT32)-1; + *exists = FALSE; + } + + return S_OK; } static HRESULT WINAPI dwritefontcollection_FindFamilyName(IDWriteFontCollection *iface, const WCHAR *name, UINT32 *index, BOOL *exists) { struct dwrite_fontcollection *This = impl_from_IDWriteFontCollection(iface); - UINT32 i; - TRACE("(%p)->(%s %p %p)\n", This, debugstr_w(name), index, exists); + return collection_find_family(This, name, index, exists); +} - for (i = 0; i < This->count; i++) - if (!strcmpW(This->families[i], name)) - { - *index = i; - *exists = TRUE; - return S_OK; - } +static BOOL is_same_fontfile(IDWriteFontFile *left, IDWriteFontFile *right) +{ + UINT32 left_key_size, right_key_size; + const void *left_key, *right_key; + HRESULT hr; - *index = (UINT32)-1; - *exists = FALSE; + if (left == right) + return TRUE; - return S_OK; + hr = IDWriteFontFile_GetReferenceKey(left, &left_key, &left_key_size); + if (FAILED(hr)) + return FALSE; + + hr = IDWriteFontFile_GetReferenceKey(right, &right_key, &right_key_size); + if (FAILED(hr)) + return FALSE; + + if (left_key_size != right_key_size) + return FALSE; + + return !memcmp(left_key, right_key, left_key_size); } static HRESULT WINAPI dwritefontcollection_GetFontFromFontFace(IDWriteFontCollection *iface, IDWriteFontFace *face, IDWriteFont **font) { struct dwrite_fontcollection *This = impl_from_IDWriteFontCollection(iface); - FIXME("(%p)->(%p %p): stub\n", This, face, font); - return E_NOTIMPL; + struct dwrite_fontfamily_data *found_family = NULL; + struct dwrite_font_data *found_font = NULL; + DWRITE_FONT_SIMULATIONS simulations; + IDWriteFontFamily *family; + UINT32 i, j, face_index; + IDWriteFontFile *file; + HRESULT hr; + + TRACE("(%p)->(%p %p)\n", This, face, font); + + *font = NULL; + + if (!face) + return E_INVALIDARG; + + i = 1; + hr = IDWriteFontFace_GetFiles(face, &i, &file); + if (FAILED(hr)) + return hr; + face_index = IDWriteFontFace_GetIndex(face); + + for (i = 0; i < This->family_count; i++) { + struct dwrite_fontfamily_data *family_data = This->family_data[i]; + for (j = 0; j < family_data->font_count; j++) { + struct dwrite_font_data *font_data = family_data->fonts[j]; + + if (face_index == font_data->face_index && is_same_fontfile(file, font_data->file)) { + found_font = font_data; + found_family = family_data; + break; + } + } + } + + if (!found_font) + return E_INVALIDARG; + + hr = create_fontfamily(found_family, iface, &family); + if (FAILED(hr)) + return hr; + + simulations = IDWriteFontFace_GetSimulations(face); + hr = create_font(found_font, family, simulations, font); + IDWriteFontFamily_Release(family); + return hr; } static const IDWriteFontCollectionVtbl fontcollectionvtbl = { @@ -984,234 +1385,405 @@ dwritefontcollection_GetFontFromFontFace }; -static HRESULT add_family_syscollection(struct dwrite_fontcollection *collection, const WCHAR *family) +static HRESULT fontfamily_add_font(struct dwrite_fontfamily_data *family_data, struct dwrite_font_data *font_data) { - /* check for duplicate family name */ - if (collection->count && !strcmpW(collection->families[collection->count-1], family)) return S_OK; + if (family_data->font_count + 1 >= family_data->font_alloc) { + struct dwrite_font_data **new_list; + UINT32 new_alloc; + + new_alloc = family_data->font_alloc * 2; + new_list = heap_realloc(family_data->fonts, sizeof(*family_data->fonts) * new_alloc); + if (!new_list) + return E_OUTOFMEMORY; + family_data->fonts = new_list; + family_data->font_alloc = new_alloc; + } - /* double array length */ - if (collection->count == collection->alloc) - { - collection->alloc *= 2; - collection->families = heap_realloc(collection->families, collection->alloc*sizeof(WCHAR*)); + family_data->fonts[family_data->font_count] = font_data; + InterlockedIncrement(&font_data->ref); + family_data->font_count++; + return S_OK; +} + +static HRESULT fontcollection_add_family(struct dwrite_fontcollection *collection, struct dwrite_fontfamily_data *family) +{ + if (collection->family_alloc < collection->family_count + 1) { + struct dwrite_fontfamily_data **new_list; + UINT32 new_alloc; + + new_alloc = collection->family_alloc * 2; + new_list = heap_realloc(collection->family_data, sizeof(*new_list) * new_alloc); + if (!new_list) + return E_OUTOFMEMORY; + + collection->family_alloc = new_alloc; + collection->family_data = new_list; } - collection->families[collection->count++] = heap_strdupW(family); - TRACE("family name %s\n", debugstr_w(family)); + collection->family_data[collection->family_count] = family; + collection->family_count++; return S_OK; } -static INT CALLBACK enum_font_families(const LOGFONTW *lf, const TEXTMETRICW *tm, DWORD type, LPARAM lParam) +static HRESULT init_font_collection(struct dwrite_fontcollection *collection, BOOL is_system) { - struct dwrite_fontcollection *collection = (struct dwrite_fontcollection*)lParam; - return add_family_syscollection(collection, lf->lfFaceName) == S_OK; + collection->IDWriteFontCollection_iface.lpVtbl = &fontcollectionvtbl; + collection->ref = 1; + collection->family_count = 0; + collection->family_alloc = 2; + collection->is_system = is_system; + + collection->family_data = heap_alloc(sizeof(*collection->family_data)*2); + if (!collection->family_data) + return E_OUTOFMEMORY; + + return S_OK; } -HRESULT get_system_fontcollection(IDWriteFontCollection **collection) +static HRESULT get_filestream_from_file(IDWriteFontFile *file, IDWriteFontFileStream **stream) { - struct dwrite_fontcollection *This; - LOGFONTW lf; - HDC hdc; + IDWriteFontFileLoader *loader; + const void *key; + UINT32 key_size; + HRESULT hr; - *collection = NULL; + *stream = NULL; - This = heap_alloc(sizeof(struct dwrite_fontcollection)); - if (!This) return E_OUTOFMEMORY; + hr = IDWriteFontFile_GetReferenceKey(file, &key, &key_size); + if (FAILED(hr)) + return hr; - This->IDWriteFontCollection_iface.lpVtbl = &fontcollectionvtbl; - This->ref = 1; - This->alloc = 50; - This->count = 0; - This->families = heap_alloc(This->alloc*sizeof(WCHAR*)); + hr = IDWriteFontFile_GetLoader(file, &loader); + if (FAILED(hr)) + return hr; - TRACE("building system font collection:\n"); + hr = IDWriteFontFileLoader_CreateStreamFromKey(loader, key, key_size, stream); + IDWriteFontFileLoader_Release(loader); + if (FAILED(hr)) + return hr; - hdc = CreateCompatibleDC(0); - memset(&lf, 0, sizeof(lf)); - lf.lfCharSet = DEFAULT_CHARSET; - lf.lfPitchAndFamily = DEFAULT_PITCH; - lf.lfFaceName[0] = 0; - EnumFontFamiliesExW(hdc, &lf, enum_font_families, (LPARAM)This, 0); - DeleteDC(hdc); + return hr; +} - *collection = &This->IDWriteFontCollection_iface; +static HRESULT init_font_data(IDWriteFactory *factory, IDWriteFontFile *file, UINT32 face_index, DWRITE_FONT_FACE_TYPE face_type, struct dwrite_font_data *data) +{ + void *os2_context, *head_context, *post_context; + const void *tt_os2 = NULL, *tt_head = NULL, *tt_post = NULL; + IDWriteFontFileStream *stream; + HRESULT hr; + + hr = get_filestream_from_file(file, &stream); + if (FAILED(hr)) + return hr; + + data->factory = factory; + data->file = file; + data->face_index = face_index; + data->face_type = face_type; + IDWriteFontFile_AddRef(file); + IDWriteFactory_AddRef(factory); + + opentype_get_font_table(stream, face_type, face_index, MS_OS2_TAG, &tt_os2, &os2_context, NULL, NULL); + opentype_get_font_table(stream, face_type, face_index, MS_HEAD_TAG, &tt_head, &head_context, NULL, NULL); + opentype_get_font_table(stream, face_type, face_index, MS_POST_TAG, &tt_post, &post_context, NULL, NULL); + + opentype_get_font_properties(tt_os2, tt_head, &data->stretch, &data->weight, &data->style); + opentype_get_font_metrics(tt_os2, tt_head, tt_post, &data->metrics); + + if (tt_os2) + IDWriteFontFileStream_ReleaseFileFragment(stream, os2_context); + if (tt_head) + IDWriteFontFileStream_ReleaseFileFragment(stream, head_context); + if (tt_post) + IDWriteFontFileStream_ReleaseFileFragment(stream, post_context); + IDWriteFontFileStream_Release(stream); return S_OK; } -static HRESULT create_fontfamily(IDWriteLocalizedStrings *familyname, IDWriteFontFamily **family) +static HRESULT init_fontfamily_data(IDWriteLocalizedStrings *familyname, struct dwrite_fontfamily_data *data) { - struct dwrite_fontfamily *This; + data->ref = 1; + data->font_count = 0; + data->font_alloc = 2; + + data->fonts = heap_alloc(sizeof(*data->fonts)*data->font_alloc); + if (!data->fonts) { + heap_free(data); + return E_OUTOFMEMORY; + } - *family = NULL; + data->familyname = familyname; + IDWriteLocalizedStrings_AddRef(familyname); - This = heap_alloc(sizeof(struct dwrite_fontfamily)); - if (!This) return E_OUTOFMEMORY; - This->data = heap_alloc(sizeof(struct dwrite_fontfamily_data)); - if (!This->data) - { - heap_free(This); - return E_OUTOFMEMORY; + return S_OK; +} + +HRESULT create_font_collection(IDWriteFactory* factory, IDWriteFontFileEnumerator *enumerator, BOOL is_system, IDWriteFontCollection **ret) +{ + struct dwrite_fontcollection *collection; + BOOL current = FALSE; + HRESULT hr; + + *ret = NULL; + + collection = heap_alloc(sizeof(struct dwrite_fontcollection)); + if (!collection) return E_OUTOFMEMORY; + + hr = init_font_collection(collection, is_system); + if (FAILED(hr)) { + heap_free(collection); + return hr; } - This->IDWriteFontFamily_iface.lpVtbl = &fontfamilyvtbl; - This->ref = 1; - This->data->font_count = 0; - This->data->alloc = 2; - This->data->fonts = heap_alloc(sizeof(*This->data->fonts) * 2); - This->collection = NULL; - This->data->familyname = familyname; + *ret = &collection->IDWriteFontCollection_iface; - *family = &This->IDWriteFontFamily_iface; + TRACE("building font collection:\n"); + + while (1) { + DWRITE_FONT_FACE_TYPE face_type; + DWRITE_FONT_FILE_TYPE file_type; + IDWriteFontFile *file; + UINT32 face_count; + BOOL supported; + int i; + + current = FALSE; + hr = IDWriteFontFileEnumerator_MoveNext(enumerator, ¤t); + if (FAILED(hr) || !current) + break; + + hr = IDWriteFontFileEnumerator_GetCurrentFontFile(enumerator, &file); + if (FAILED(hr)) + break; + + hr = IDWriteFontFile_Analyze(file, &supported, &file_type, &face_type, &face_count); + if (FAILED(hr) || !supported || face_count == 0) { + TRACE("unsupported font (0x%08x, %d, %u)\n", hr, supported, face_count); + IDWriteFontFile_Release(file); + continue; + } + + for (i = 0; i < face_count; i++) { + IDWriteLocalizedStrings *family_name = NULL; + struct dwrite_font_data *font_data; + const void *name_table; + void *name_context; + IDWriteFontFileStream *stream; + WCHAR buffer[255]; + UINT32 index; + BOOL exists; + + /* alloc and init new font data structure */ + font_data = heap_alloc_zero(sizeof(struct dwrite_font_data)); + init_font_data(factory, file, i, face_type, font_data); + + hr = get_filestream_from_file(file, &stream); + if (FAILED(hr)) { + heap_free (font_data); + return hr; + } + + /* get family name from font file */ + name_table = NULL; + opentype_get_font_table(stream, face_type, i, MS_NAME_TAG, &name_table, &name_context, NULL, NULL); + if (name_table) + hr = opentype_get_font_strings_from_id(name_table, DWRITE_INFORMATIONAL_STRING_WIN32_FAMILY_NAMES, &family_name); + IDWriteFontFileStream_Release(stream); + + if (FAILED(hr) || !family_name) { + WARN("unable to get family name from font\n"); + continue; + } + + buffer[0] = 0; + IDWriteLocalizedStrings_GetString(family_name, 0, buffer, sizeof(buffer)/sizeof(WCHAR)); + + exists = FALSE; + hr = collection_find_family(collection, buffer, &index, &exists); + if (exists) + hr = fontfamily_add_font(collection->family_data[index], font_data); + else { + struct dwrite_fontfamily_data *family_data; + + /* create and init new family */ + family_data = heap_alloc(sizeof(*family_data)); + init_fontfamily_data(family_name, family_data); + + /* add font to family, family - to collection */ + fontfamily_add_font(family_data, font_data); + fontcollection_add_family(collection, family_data); + } + + IDWriteLocalizedStrings_Release(family_name); + } + + IDWriteFontFile_Release(file); + }; return S_OK; } -static HRESULT create_font_from_data(struct dwrite_font_data *data, IDWriteFont **font) +struct system_fontfile_enumerator { - struct dwrite_font *This; - *font = NULL; + IDWriteFontFileEnumerator IDWriteFontFileEnumerator_iface; + LONG ref; - This = heap_alloc(sizeof(struct dwrite_font)); - if (!This) return E_OUTOFMEMORY; + IDWriteFactory *factory; + HKEY hkey; + int index; +}; - This->IDWriteFont_iface.lpVtbl = &dwritefontvtbl; - This->ref = 1; - This->face = NULL; - This->family = NULL; - This->is_system = FALSE; - This->data = data; - InterlockedIncrement(&This->data->ref); +static inline struct system_fontfile_enumerator *impl_from_IDWriteFontFileEnumerator(IDWriteFontFileEnumerator* iface) +{ + return CONTAINING_RECORD(iface, struct system_fontfile_enumerator, IDWriteFontFileEnumerator_iface); +} + +static HRESULT WINAPI systemfontfileenumerator_QueryInterface(IDWriteFontFileEnumerator *iface, REFIID riid, void **obj) +{ + *obj = NULL; - *font = &This->IDWriteFont_iface; + if (IsEqualIID(riid, &IID_IDWriteFontFileEnumerator) || IsEqualIID(riid, &IID_IUnknown)) { + IDWriteFontFileEnumerator_AddRef(iface); + *obj = iface; + return S_OK; + } - return S_OK; + return E_NOINTERFACE; } -static HRESULT create_font_base(IDWriteFont **font) +static ULONG WINAPI systemfontfileenumerator_AddRef(IDWriteFontFileEnumerator *iface) { - struct dwrite_font_data *data; - HRESULT ret; + struct system_fontfile_enumerator *enumerator = impl_from_IDWriteFontFileEnumerator(iface); + return InterlockedIncrement(&enumerator->ref); +} - *font = NULL; - data = heap_alloc(sizeof(*data)); - if (!data) return E_OUTOFMEMORY; +static ULONG WINAPI systemfontfileenumerator_Release(IDWriteFontFileEnumerator *iface) +{ + struct system_fontfile_enumerator *enumerator = impl_from_IDWriteFontFileEnumerator(iface); + ULONG ref = InterlockedDecrement(&enumerator->ref); - data->ref = 0; - data->face_data = NULL; + if (!ref) { + IDWriteFactory_Release(enumerator->factory); + RegCloseKey(enumerator->hkey); + heap_free(enumerator); + } - ret = create_font_from_data( data, font ); - if (FAILED(ret)) heap_free( data ); - return ret; + return ref; } -HRESULT create_font_from_logfont(const LOGFONTW *logfont, IDWriteFont **font) +static HRESULT WINAPI systemfontfileenumerator_GetCurrentFontFile(IDWriteFontFileEnumerator *iface, IDWriteFontFile **file) { - const WCHAR* facename, *familyname; - IDWriteLocalizedStrings *name; - struct dwrite_font *This; - IDWriteFontFamily *family; - OUTLINETEXTMETRICW *otm; + struct system_fontfile_enumerator *enumerator = impl_from_IDWriteFontFileEnumerator(iface); + DWORD ret, type, count; HRESULT hr; - HFONT hfont; - HDC hdc; - int ret; - static const WCHAR enusW[] = {'e','n','-','u','s',0}; - LPVOID tt_os2 = NULL; - LPVOID tt_head = NULL; - LPVOID tt_post = NULL; - LONG size; - - hr = create_font_base(font); - if (FAILED(hr)) - return hr; + BYTE *data; - This = impl_from_IDWriteFont(*font); + *file = NULL; - hfont = CreateFontIndirectW(logfont); - if (!hfont) - { - heap_free(This->data); - heap_free(This); - return DWRITE_E_NOFONT; - } + if (enumerator->index < 0) + return E_FAIL; - hdc = CreateCompatibleDC(0); - SelectObject(hdc, hfont); + if (RegEnumValueW(enumerator->hkey, enumerator->index, NULL, NULL, NULL, &type, NULL, &count)) + return E_FAIL; - ret = GetOutlineTextMetricsW(hdc, 0, NULL); - otm = heap_alloc(ret); - if (!otm) - { - heap_free(This->data); - heap_free(This); - DeleteDC(hdc); - DeleteObject(hfont); + if (!(data = heap_alloc(count))) return E_OUTOFMEMORY; - } - otm->otmSize = ret; - ret = GetOutlineTextMetricsW(hdc, otm->otmSize, otm); - size = GetFontData(hdc, MS_OS2_TAG, 0, NULL, 0); - if (size != GDI_ERROR) - { - tt_os2 = heap_alloc(size); - GetFontData(hdc, MS_OS2_TAG, 0, tt_os2, size); - } - size = GetFontData(hdc, MS_HEAD_TAG, 0, NULL, 0); - if (size != GDI_ERROR) - { - tt_head = heap_alloc(size); - GetFontData(hdc, MS_HEAD_TAG, 0, tt_head, size); + ret = RegEnumValueW(enumerator->hkey, enumerator->index, NULL, NULL, NULL, &type, data, &count); + if (ret) { + heap_free(data); + return E_FAIL; } - size = GetFontData(hdc, MS_POST_TAG, 0, NULL, 0); - if (size != GDI_ERROR) - { - tt_post = heap_alloc(size); - GetFontData(hdc, MS_POST_TAG, 0, tt_post, size); + + hr = IDWriteFactory_CreateFontFileReference(enumerator->factory, (WCHAR*)data, NULL, file); + heap_free(data); + return hr; +} + +static HRESULT WINAPI systemfontfileenumerator_MoveNext(IDWriteFontFileEnumerator *iface, BOOL *current) +{ + struct system_fontfile_enumerator *enumerator = impl_from_IDWriteFontFileEnumerator(iface); + + *current = FALSE; + enumerator->index++; + + /* iterate until we find next string value */ + while (1) { + DWORD type = 0, count; + if (RegEnumValueW(enumerator->hkey, enumerator->index, NULL, NULL, NULL, &type, NULL, &count)) + break; + if (type == REG_SZ) { + *current = TRUE; + break; + } + enumerator->index++; } - get_font_properties(tt_os2, tt_head, tt_post, &This->data->metrics, &This->data->stretch, &This->data->weight, &This->data->style); - heap_free(tt_os2); - heap_free(tt_head); - heap_free(tt_post); + TRACE("index = %d, current = %d\n", enumerator->index, *current); + return S_OK; +} - if (logfont->lfItalic) - This->data->style = DWRITE_FONT_STYLE_ITALIC; +static const struct IDWriteFontFileEnumeratorVtbl systemfontfileenumeratorvtbl = +{ + systemfontfileenumerator_QueryInterface, + systemfontfileenumerator_AddRef, + systemfontfileenumerator_Release, + systemfontfileenumerator_MoveNext, + systemfontfileenumerator_GetCurrentFontFile +}; - DeleteDC(hdc); - DeleteObject(hfont); +static HRESULT create_system_fontfile_enumerator(IDWriteFactory *factory, IDWriteFontFileEnumerator **ret) +{ + struct system_fontfile_enumerator *enumerator; + static const WCHAR fontslistW[] = { + 'S','o','f','t','w','a','r','e','\\','M','i','c','r','o','s','o','f','t','\\', + 'W','i','n','d','o','w','s',' ','N','T','\\','C','u','r','r','e','n','t','V','e','r','s','i','o','n','\\', + 'F','o','n','t','s',0 + }; - facename = (WCHAR*)((char*)otm + (ptrdiff_t)otm->otmpFaceName); - familyname = (WCHAR*)((char*)otm + (ptrdiff_t)otm->otmpFamilyName); - TRACE("facename=%s, familyname=%s\n", debugstr_w(facename), debugstr_w(familyname)); + *ret = NULL; - hr = create_localizedstrings(&name); - if (FAILED(hr)) - { - heap_free(This); - return hr; - } - add_localizedstring(name, enusW, familyname); - hr = create_fontfamily(name, &family); + enumerator = heap_alloc(sizeof(*enumerator)); + if (!enumerator) + return E_OUTOFMEMORY; - heap_free(otm); - if (hr != S_OK) - { - heap_free(This->data); - heap_free(This); - return hr; + enumerator->IDWriteFontFileEnumerator_iface.lpVtbl = &systemfontfileenumeratorvtbl; + enumerator->ref = 1; + enumerator->factory = factory; + enumerator->index = -1; + IDWriteFactory_AddRef(factory); + + if (RegOpenKeyExW(HKEY_LOCAL_MACHINE, fontslistW, 0, GENERIC_READ, &enumerator->hkey)) { + ERR("failed to open fonts list key\n"); + IDWriteFactory_Release(factory); + heap_free(enumerator); + return E_FAIL; } - This->is_system = TRUE; - This->family = family; - This->data->simulations = DWRITE_FONT_SIMULATIONS_NONE; - This->data->facename = heap_strdupW(logfont->lfFaceName); + *ret = &enumerator->IDWriteFontFileEnumerator_iface; return S_OK; } +HRESULT get_system_fontcollection(IDWriteFactory *factory, IDWriteFontCollection **collection) +{ + IDWriteFontFileEnumerator *enumerator; + HRESULT hr; + + *collection = NULL; + + hr = create_system_fontfile_enumerator(factory, &enumerator); + if (FAILED(hr)) + return hr; + + TRACE("building system font collection for factory %p\n", factory); + hr = create_font_collection(factory, enumerator, TRUE, collection); + IDWriteFontFileEnumerator_Release(enumerator); + return hr; +} + static HRESULT WINAPI dwritefontfile_QueryInterface(IDWriteFontFile *iface, REFIID riid, void **obj) { struct dwrite_fontfile *This = impl_from_IDWriteFontFile(iface); @@ -1277,13 +1849,11 @@ static HRESULT WINAPI dwritefontfile_Analyze(IDWriteFontFile *iface, BOOL *isSupportedFontType, DWRITE_FONT_FILE_TYPE *fontFileType, DWRITE_FONT_FACE_TYPE *fontFaceType, UINT32 *numberOfFaces) { - HRESULT hr; - const void *font_data; - void *context; + struct dwrite_fontfile *This = impl_from_IDWriteFontFile(iface); IDWriteFontFileStream *stream; + HRESULT hr; - struct dwrite_fontfile *This = impl_from_IDWriteFontFile(iface); - FIXME("(%p)->(%p, %p, %p, %p): Stub\n", This, isSupportedFontType, fontFileType, fontFaceType, numberOfFaces); + TRACE("(%p)->(%p, %p, %p, %p)\n", This, isSupportedFontType, fontFileType, fontFaceType, numberOfFaces); *isSupportedFontType = FALSE; *fontFileType = DWRITE_FONT_FILE_TYPE_UNKNOWN; @@ -1294,12 +1864,9 @@ hr = IDWriteFontFileLoader_CreateStreamFromKey(This->loader, This->reference_key, This->key_size, &stream); if (FAILED(hr)) return S_OK; - hr = IDWriteFontFileStream_ReadFileFragment(stream, &font_data, 0, 28, &context); - if (SUCCEEDED(hr)) - { - hr = analyze_opentype_font(font_data, numberOfFaces, fontFileType, fontFaceType, isSupportedFontType); - IDWriteFontFileStream_ReleaseFileFragment(stream, context); - } + + hr = opentype_analyze_font(stream, numberOfFaces, fontFileType, fontFaceType, isSupportedFontType); + /* TODO: Further Analysis */ IDWriteFontFileStream_Release(stream); return S_OK; @@ -1335,59 +1902,75 @@ return S_OK; } -HRESULT font_create_fontface(IDWriteFactory *iface, DWRITE_FONT_FACE_TYPE facetype, UINT32 files_number, IDWriteFontFile* const* font_files, UINT32 index, DWRITE_FONT_SIMULATIONS sim_flags, IDWriteFontFace **font_face) +static HRESULT get_stream_from_file(IDWriteFontFile *file, IDWriteFontFileStream **stream) { - int i; - struct dwrite_fontface *This; + IDWriteFontFileLoader *loader; + UINT32 key_size; + const void *key; + HRESULT hr; + + *stream = NULL; + hr = IDWriteFontFile_GetLoader(file, &loader); + if (FAILED(hr)) + return hr; + + hr = IDWriteFontFile_GetReferenceKey(file, &key, &key_size); + if (FAILED(hr)) { + IDWriteFontFileLoader_Release(loader); + return hr; + } + + hr = IDWriteFontFileLoader_CreateStreamFromKey(loader, key, key_size, stream); + IDWriteFontFileLoader_Release(loader); + + return hr; +} + +HRESULT create_fontface(DWRITE_FONT_FACE_TYPE facetype, UINT32 files_number, IDWriteFontFile* const* font_files, UINT32 index, + DWRITE_FONT_SIMULATIONS simulations, IDWriteFontFace2 **ret) +{ + struct dwrite_fontface *fontface; HRESULT hr = S_OK; + int i; - *font_face = NULL; + fontface = heap_alloc(sizeof(struct dwrite_fontface)); + if (!fontface) + return E_OUTOFMEMORY; - This = heap_alloc(sizeof(struct dwrite_fontface)); - if (!This) return E_OUTOFMEMORY; - This->data = heap_alloc(sizeof(struct dwrite_fontface_data)); - if (!This->data) - { - heap_free(This); + fontface->files = heap_alloc_zero(sizeof(*fontface->files) * files_number); + fontface->streams = heap_alloc_zero(sizeof(*fontface->streams) * files_number); + + if (!fontface->files || !fontface->streams) { + heap_free(fontface->files); + heap_free(fontface->streams); + heap_free(fontface); return E_OUTOFMEMORY; } - This->IDWriteFontFace_iface.lpVtbl = &dwritefontfacevtbl; - This->ref = 1; - This->data->ref = 1; - This->data->type = facetype; - This->data->file_count = files_number; - This->data->files = heap_alloc(sizeof(*This->data->files) * files_number); - This->CMAP_table = NULL; - This->CMAP_context = NULL; - This->CMAP_size = 0; - /* Verify font file streams */ - for (i = 0; i < This->data->file_count && SUCCEEDED(hr); i++) - { - IDWriteFontFileStream *stream; - hr = _dwritefontfile_GetFontFileStream(font_files[i], &stream); - if (SUCCEEDED(hr)) - IDWriteFontFileStream_Release(stream); - } - if (FAILED(hr)) - { - heap_free(This->data->files); - heap_free(This->data); - heap_free(This); - return hr; - } - for (i = 0; i < This->data->file_count; i++) - { - This->data->files[i] = font_files[i]; + fontface->IDWriteFontFace2_iface.lpVtbl = &dwritefontfacevtbl; + fontface->ref = 1; + fontface->type = facetype; + fontface->file_count = files_number; + fontface->cmap.data = NULL; + fontface->cmap.context = NULL; + fontface->cmap.size = 0; + fontface->index = index; + fontface->simulations = simulations; + + for (i = 0; i < fontface->file_count; i++) { + hr = get_stream_from_file(font_files[i], &fontface->streams[i]); + if (FAILED(hr)) { + IDWriteFontFace2_Release(&fontface->IDWriteFontFace2_iface); + return hr; + } + + fontface->files[i] = font_files[i]; IDWriteFontFile_AddRef(font_files[i]); } - This->data->index = index; - This->data->simulations = sim_flags; - This->is_system = FALSE; - - *font_face = &This->IDWriteFontFace_iface; + get_font_properties_from_stream(fontface->streams[0], facetype, index, &fontface->metrics, NULL, NULL, NULL); + *ret = &fontface->IDWriteFontFace2_iface; return S_OK; } diff -Nru wine1.7-1.7.28/dlls/dwrite/gdiinterop.c wine1.7-1.7.31/dlls/dwrite/gdiinterop.c --- wine1.7-1.7.28/dlls/dwrite/gdiinterop.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/gdiinterop.c 2014-11-14 13:28:17.000000000 +0000 @@ -25,7 +25,6 @@ #include "windef.h" #include "winbase.h" #include "wingdi.h" -#include "dwrite.h" #include "dwrite_private.h" #include "wine/debug.h" @@ -34,13 +33,14 @@ struct gdiinterop { IDWriteGdiInterop IDWriteGdiInterop_iface; - LONG ref; + IDWriteFactory *factory; }; struct rendertarget { IDWriteBitmapRenderTarget IDWriteBitmapRenderTarget_iface; LONG ref; + FLOAT pixels_per_dip; DWRITE_MATRIX m; SIZE size; HDC hdc; @@ -141,15 +141,21 @@ static FLOAT WINAPI rendertarget_GetPixelsPerDip(IDWriteBitmapRenderTarget *iface) { struct rendertarget *This = impl_from_IDWriteBitmapRenderTarget(iface); - FIXME("(%p): stub\n", This); - return 1.0; + TRACE("(%p)\n", This); + return This->pixels_per_dip; } static HRESULT WINAPI rendertarget_SetPixelsPerDip(IDWriteBitmapRenderTarget *iface, FLOAT pixels_per_dip) { struct rendertarget *This = impl_from_IDWriteBitmapRenderTarget(iface); - FIXME("(%p)->(%f): stub\n", This, pixels_per_dip); - return E_NOTIMPL; + + TRACE("(%p)->(%.2f)\n", This, pixels_per_dip); + + if (pixels_per_dip <= 0.0) + return E_INVALIDARG; + + This->pixels_per_dip = pixels_per_dip; + return S_OK; } static HRESULT WINAPI rendertarget_GetCurrentTransform(IDWriteBitmapRenderTarget *iface, DWRITE_MATRIX *transform) @@ -230,6 +236,7 @@ target->m.m11 = target->m.m22 = 1.0; target->m.m12 = target->m.m21 = 0.0; target->m.dx = target->m.dy = 0.0; + target->pixels_per_dip = 1.0; *ret = &target->IDWriteBitmapRenderTarget_iface; @@ -242,7 +249,8 @@ TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), obj); - if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IDWriteGdiInterop)) + if (IsEqualIID(riid, &IID_IDWriteGdiInterop) || + IsEqualIID(riid, &IID_IUnknown)) { *obj = iface; IDWriteGdiInterop_AddRef(iface); @@ -256,42 +264,116 @@ static ULONG WINAPI gdiinterop_AddRef(IDWriteGdiInterop *iface) { struct gdiinterop *This = impl_from_IDWriteGdiInterop(iface); - ULONG ref = InterlockedIncrement(&This->ref); - TRACE("(%p)->(%d)\n", This, ref); - return ref; + TRACE("(%p)\n", This); + return IDWriteFactory_AddRef(This->factory); } static ULONG WINAPI gdiinterop_Release(IDWriteGdiInterop *iface) { struct gdiinterop *This = impl_from_IDWriteGdiInterop(iface); - ULONG ref = InterlockedDecrement(&This->ref); - - TRACE("(%p)->(%d)\n", This, ref); - - if (!ref) - { - heap_free(This); - } - return ref; + TRACE("(%p)\n", This); + return IDWriteFactory_Release(This->factory); } static HRESULT WINAPI gdiinterop_CreateFontFromLOGFONT(IDWriteGdiInterop *iface, LOGFONTW const *logfont, IDWriteFont **font) { struct gdiinterop *This = impl_from_IDWriteGdiInterop(iface); + IDWriteFontCollection *collection; + IDWriteFontFamily *family; + DWRITE_FONT_STYLE style; + BOOL exists = FALSE; + UINT32 index; + HRESULT hr; + TRACE("(%p)->(%p %p)\n", This, logfont, font); + *font = NULL; + if (!logfont) return E_INVALIDARG; - return create_font_from_logfont(logfont, font); + hr = IDWriteFactory_GetSystemFontCollection(This->factory, &collection, FALSE); + if (FAILED(hr)) { + ERR("failed to get system font collection: 0x%08x.\n", hr); + return hr; + } + + hr = IDWriteFontCollection_FindFamilyName(collection, logfont->lfFaceName, &index, &exists); + if (FAILED(hr)) { + IDWriteFontCollection_Release(collection); + goto done; + } + + if (!exists) { + hr = DWRITE_E_NOFONT; + goto done; + } + + hr = IDWriteFontCollection_GetFontFamily(collection, index, &family); + if (FAILED(hr)) + goto done; + + style = logfont->lfItalic ? DWRITE_FONT_STYLE_ITALIC : DWRITE_FONT_STYLE_NORMAL; + hr = IDWriteFontFamily_GetFirstMatchingFont(family, logfont->lfWeight, DWRITE_FONT_STRETCH_NORMAL, style, font); + IDWriteFontFamily_Release(family); + +done: + IDWriteFontCollection_Release(collection); + return hr; } static HRESULT WINAPI gdiinterop_ConvertFontToLOGFONT(IDWriteGdiInterop *iface, IDWriteFont *font, LOGFONTW *logfont, BOOL *is_systemfont) { struct gdiinterop *This = impl_from_IDWriteGdiInterop(iface); - FIXME("(%p)->(%p %p %p): stub\n", This, font, logfont, is_systemfont); - return E_NOTIMPL; + static const WCHAR enusW[] = {'e','n','-','u','s',0}; + DWRITE_FONT_SIMULATIONS simulations; + IDWriteFontCollection *collection; + IDWriteLocalizedStrings *name; + IDWriteFontFamily *family; + DWRITE_FONT_STYLE style; + UINT32 index; + BOOL exists; + HRESULT hr; + + TRACE("(%p)->(%p %p %p)\n", This, font, logfont, is_systemfont); + + *is_systemfont = FALSE; + + if (!font) + return E_INVALIDARG; + + hr = IDWriteFont_GetFontFamily(font, &family); + if (FAILED(hr)) + return hr; + + hr = IDWriteFontFamily_GetFontCollection(family, &collection); + IDWriteFontFamily_Release(family); + if (FAILED(hr)) + return hr; + + *is_systemfont = is_system_collection(collection); + IDWriteFontCollection_Release(collection); + + simulations = IDWriteFont_GetSimulations(font); + style = IDWriteFont_GetStyle(font); + + logfont->lfCharSet = DEFAULT_CHARSET; + logfont->lfWeight = IDWriteFont_GetWeight(font); + logfont->lfItalic = style == DWRITE_FONT_STYLE_ITALIC || (simulations & DWRITE_FONT_SIMULATIONS_OBLIQUE); + logfont->lfOutPrecision = OUT_OUTLINE_PRECIS; + logfont->lfFaceName[0] = 0; + + exists = FALSE; + hr = IDWriteFont_GetInformationalStrings(font, DWRITE_INFORMATIONAL_STRING_WIN32_FAMILY_NAMES, &name, &exists); + if (FAILED(hr) || !exists) + return hr; + + IDWriteLocalizedStrings_FindLocaleName(name, enusW, &index, &exists); + IDWriteLocalizedStrings_GetString(name, index, logfont->lfFaceName, sizeof(logfont->lfFaceName)/sizeof(WCHAR)); + IDWriteLocalizedStrings_Release(name); + + return S_OK; } static HRESULT WINAPI gdiinterop_ConvertFontFaceToLOGFONT(IDWriteGdiInterop *iface, @@ -306,8 +388,28 @@ HDC hdc, IDWriteFontFace **fontface) { struct gdiinterop *This = impl_from_IDWriteGdiInterop(iface); - FIXME("(%p)->(%p %p): stub\n", This, hdc, fontface); - return E_NOTIMPL; + IDWriteFont *font; + LOGFONTW logfont; + HFONT hfont; + HRESULT hr; + + TRACE("(%p)->(%p %p)\n", This, hdc, fontface); + + *fontface = NULL; + + hfont = GetCurrentObject(hdc, OBJ_FONT); + if (!hfont) + return E_INVALIDARG; + GetObjectW(hfont, sizeof(logfont), &logfont); + + hr = IDWriteGdiInterop_CreateFontFromLOGFONT(iface, &logfont, &font); + if (FAILED(hr)) + return hr; + + hr = IDWriteFont_CreateFontFace(font, fontface); + IDWriteFont_Release(font); + + return hr; } static HRESULT WINAPI gdiinterop_CreateBitmapRenderTarget(IDWriteGdiInterop *iface, @@ -329,7 +431,7 @@ gdiinterop_CreateBitmapRenderTarget }; -HRESULT get_gdiinterop(IDWriteGdiInterop **ret) +HRESULT create_gdiinterop(IDWriteFactory *factory, IDWriteGdiInterop **ret) { struct gdiinterop *This; @@ -339,8 +441,14 @@ if (!This) return E_OUTOFMEMORY; This->IDWriteGdiInterop_iface.lpVtbl = &gdiinteropvtbl; - This->ref = 1; + This->factory = factory; *ret= &This->IDWriteGdiInterop_iface; return S_OK; } + +void release_gdiinterop(IDWriteGdiInterop *iface) +{ + struct gdiinterop *interop = impl_from_IDWriteGdiInterop(iface); + heap_free(interop); +} diff -Nru wine1.7-1.7.28/dlls/dwrite/layout.c wine1.7-1.7.31/dlls/dwrite/layout.c --- wine1.7-1.7.28/dlls/dwrite/layout.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/layout.c 2014-11-14 13:28:17.000000000 +0000 @@ -25,7 +25,6 @@ #include "windef.h" #include "winbase.h" #include "wingdi.h" -#include "dwrite.h" #include "dwrite_private.h" #include "wine/list.h" @@ -100,7 +99,7 @@ }; struct dwrite_textlayout { - IDWriteTextLayout IDWriteTextLayout_iface; + IDWriteTextLayout2 IDWriteTextLayout2_iface; LONG ref; WCHAR *str; @@ -112,7 +111,7 @@ }; struct dwrite_textformat { - IDWriteTextFormat IDWriteTextFormat_iface; + IDWriteTextFormat1 IDWriteTextFormat1_iface; LONG ref; struct dwrite_textformat_data format; }; @@ -131,7 +130,7 @@ UINT32 count; }; -static const IDWriteTextFormatVtbl dwritetextformatvtbl; +static const IDWriteTextFormat1Vtbl dwritetextformatvtbl; static void release_format_data(struct dwrite_textformat_data *data) { @@ -141,19 +140,19 @@ heap_free(data->locale); } -static inline struct dwrite_textlayout *impl_from_IDWriteTextLayout(IDWriteTextLayout *iface) +static inline struct dwrite_textlayout *impl_from_IDWriteTextLayout2(IDWriteTextLayout2 *iface) { - return CONTAINING_RECORD(iface, struct dwrite_textlayout, IDWriteTextLayout_iface); + return CONTAINING_RECORD(iface, struct dwrite_textlayout, IDWriteTextLayout2_iface); } -static inline struct dwrite_textformat *impl_from_IDWriteTextFormat(IDWriteTextFormat *iface) +static inline struct dwrite_textformat *impl_from_IDWriteTextFormat1(IDWriteTextFormat1 *iface) { - return CONTAINING_RECORD(iface, struct dwrite_textformat, IDWriteTextFormat_iface); + return CONTAINING_RECORD(iface, struct dwrite_textformat, IDWriteTextFormat1_iface); } -static inline struct dwrite_textformat *unsafe_impl_from_IDWriteTextFormat(IDWriteTextFormat *iface) +static inline struct dwrite_textformat *unsafe_impl_from_IDWriteTextFormat1(IDWriteTextFormat1 *iface) { - return iface->lpVtbl == &dwritetextformatvtbl ? impl_from_IDWriteTextFormat(iface) : NULL; + return iface->lpVtbl == &dwritetextformatvtbl ? impl_from_IDWriteTextFormat1(iface) : NULL; } static inline struct dwrite_trimmingsign *impl_from_IDWriteInlineObject(IDWriteInlineObject *iface) @@ -519,18 +518,20 @@ return S_OK; } -static HRESULT WINAPI dwritetextlayout_QueryInterface(IDWriteTextLayout *iface, REFIID riid, void **obj) +static HRESULT WINAPI dwritetextlayout_QueryInterface(IDWriteTextLayout2 *iface, REFIID riid, void **obj) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), obj); - if (IsEqualIID(riid, &IID_IUnknown) || + if (IsEqualIID(riid, &IID_IDWriteTextLayout2) || + IsEqualIID(riid, &IID_IDWriteTextLayout1) || + IsEqualIID(riid, &IID_IDWriteTextLayout) || IsEqualIID(riid, &IID_IDWriteTextFormat) || - IsEqualIID(riid, &IID_IDWriteTextLayout)) + IsEqualIID(riid, &IID_IUnknown)) { *obj = iface; - IDWriteTextLayout_AddRef(iface); + IDWriteTextLayout2_AddRef(iface); return S_OK; } @@ -539,17 +540,17 @@ return E_NOINTERFACE; } -static ULONG WINAPI dwritetextlayout_AddRef(IDWriteTextLayout *iface) +static ULONG WINAPI dwritetextlayout_AddRef(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); ULONG ref = InterlockedIncrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); return ref; } -static ULONG WINAPI dwritetextlayout_Release(IDWriteTextLayout *iface) +static ULONG WINAPI dwritetextlayout_Release(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); ULONG ref = InterlockedDecrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); @@ -564,110 +565,110 @@ return ref; } -static HRESULT WINAPI dwritetextlayout_SetTextAlignment(IDWriteTextLayout *iface, DWRITE_TEXT_ALIGNMENT alignment) +static HRESULT WINAPI dwritetextlayout_SetTextAlignment(IDWriteTextLayout2 *iface, DWRITE_TEXT_ALIGNMENT alignment) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%d): stub\n", This, alignment); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetParagraphAlignment(IDWriteTextLayout *iface, DWRITE_PARAGRAPH_ALIGNMENT alignment) +static HRESULT WINAPI dwritetextlayout_SetParagraphAlignment(IDWriteTextLayout2 *iface, DWRITE_PARAGRAPH_ALIGNMENT alignment) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%d): stub\n", This, alignment); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetWordWrapping(IDWriteTextLayout *iface, DWRITE_WORD_WRAPPING wrapping) +static HRESULT WINAPI dwritetextlayout_SetWordWrapping(IDWriteTextLayout2 *iface, DWRITE_WORD_WRAPPING wrapping) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%d): stub\n", This, wrapping); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetReadingDirection(IDWriteTextLayout *iface, DWRITE_READING_DIRECTION direction) +static HRESULT WINAPI dwritetextlayout_SetReadingDirection(IDWriteTextLayout2 *iface, DWRITE_READING_DIRECTION direction) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%d): stub\n", This, direction); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetFlowDirection(IDWriteTextLayout *iface, DWRITE_FLOW_DIRECTION direction) +static HRESULT WINAPI dwritetextlayout_SetFlowDirection(IDWriteTextLayout2 *iface, DWRITE_FLOW_DIRECTION direction) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%d): stub\n", This, direction); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetIncrementalTabStop(IDWriteTextLayout *iface, FLOAT tabstop) +static HRESULT WINAPI dwritetextlayout_SetIncrementalTabStop(IDWriteTextLayout2 *iface, FLOAT tabstop) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%f): stub\n", This, tabstop); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetTrimming(IDWriteTextLayout *iface, DWRITE_TRIMMING const *trimming, +static HRESULT WINAPI dwritetextlayout_SetTrimming(IDWriteTextLayout2 *iface, DWRITE_TRIMMING const *trimming, IDWriteInlineObject *trimming_sign) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%p %p): stub\n", This, trimming, trimming_sign); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetLineSpacing(IDWriteTextLayout *iface, DWRITE_LINE_SPACING_METHOD spacing, +static HRESULT WINAPI dwritetextlayout_SetLineSpacing(IDWriteTextLayout2 *iface, DWRITE_LINE_SPACING_METHOD spacing, FLOAT line_spacing, FLOAT baseline) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%d %f %f): stub\n", This, spacing, line_spacing, baseline); return E_NOTIMPL; } -static DWRITE_TEXT_ALIGNMENT WINAPI dwritetextlayout_GetTextAlignment(IDWriteTextLayout *iface) +static DWRITE_TEXT_ALIGNMENT WINAPI dwritetextlayout_GetTextAlignment(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.textalignment; } -static DWRITE_PARAGRAPH_ALIGNMENT WINAPI dwritetextlayout_GetParagraphAlignment(IDWriteTextLayout *iface) +static DWRITE_PARAGRAPH_ALIGNMENT WINAPI dwritetextlayout_GetParagraphAlignment(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.paralign; } -static DWRITE_WORD_WRAPPING WINAPI dwritetextlayout_GetWordWrapping(IDWriteTextLayout *iface) +static DWRITE_WORD_WRAPPING WINAPI dwritetextlayout_GetWordWrapping(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p): stub\n", This); return This->format.wrapping; } -static DWRITE_READING_DIRECTION WINAPI dwritetextlayout_GetReadingDirection(IDWriteTextLayout *iface) +static DWRITE_READING_DIRECTION WINAPI dwritetextlayout_GetReadingDirection(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.readingdir; } -static DWRITE_FLOW_DIRECTION WINAPI dwritetextlayout_GetFlowDirection(IDWriteTextLayout *iface) +static DWRITE_FLOW_DIRECTION WINAPI dwritetextlayout_GetFlowDirection(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.flow; } -static FLOAT WINAPI dwritetextlayout_GetIncrementalTabStop(IDWriteTextLayout *iface) +static FLOAT WINAPI dwritetextlayout_GetIncrementalTabStop(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p): stub\n", This); return 0.0; } -static HRESULT WINAPI dwritetextlayout_GetTrimming(IDWriteTextLayout *iface, DWRITE_TRIMMING *options, +static HRESULT WINAPI dwritetextlayout_GetTrimming(IDWriteTextLayout2 *iface, DWRITE_TRIMMING *options, IDWriteInlineObject **trimming_sign) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)->(%p %p)\n", This, options, trimming_sign); @@ -678,10 +679,10 @@ return S_OK; } -static HRESULT WINAPI dwritetextlayout_GetLineSpacing(IDWriteTextLayout *iface, DWRITE_LINE_SPACING_METHOD *method, +static HRESULT WINAPI dwritetextlayout_GetLineSpacing(IDWriteTextLayout2 *iface, DWRITE_LINE_SPACING_METHOD *method, FLOAT *spacing, FLOAT *baseline) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)->(%p %p %p)\n", This, method, spacing, baseline); @@ -691,9 +692,9 @@ return S_OK; } -static HRESULT WINAPI dwritetextlayout_GetFontCollection(IDWriteTextLayout *iface, IDWriteFontCollection **collection) +static HRESULT WINAPI dwritetextlayout_GetFontCollection(IDWriteTextLayout2 *iface, IDWriteFontCollection **collection) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)->(%p)\n", This, collection); @@ -703,16 +704,16 @@ return S_OK; } -static UINT32 WINAPI dwritetextlayout_GetFontFamilyNameLength(IDWriteTextLayout *iface) +static UINT32 WINAPI dwritetextlayout_GetFontFamilyNameLength(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.family_len; } -static HRESULT WINAPI dwritetextlayout_GetFontFamilyName(IDWriteTextLayout *iface, WCHAR *name, UINT32 size) +static HRESULT WINAPI dwritetextlayout_GetFontFamilyName(IDWriteTextLayout2 *iface, WCHAR *name, UINT32 size) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)->(%p %u)\n", This, name, size); @@ -721,44 +722,44 @@ return S_OK; } -static DWRITE_FONT_WEIGHT WINAPI dwritetextlayout_GetFontWeight(IDWriteTextLayout *iface) +static DWRITE_FONT_WEIGHT WINAPI dwritetextlayout_GetFontWeight(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.weight; } -static DWRITE_FONT_STYLE WINAPI dwritetextlayout_GetFontStyle(IDWriteTextLayout *iface) +static DWRITE_FONT_STYLE WINAPI dwritetextlayout_GetFontStyle(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.style; } -static DWRITE_FONT_STRETCH WINAPI dwritetextlayout_GetFontStretch(IDWriteTextLayout *iface) +static DWRITE_FONT_STRETCH WINAPI dwritetextlayout_GetFontStretch(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.stretch; } -static FLOAT WINAPI dwritetextlayout_GetFontSize(IDWriteTextLayout *iface) +static FLOAT WINAPI dwritetextlayout_GetFontSize(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.fontsize; } -static UINT32 WINAPI dwritetextlayout_GetLocaleNameLength(IDWriteTextLayout *iface) +static UINT32 WINAPI dwritetextlayout_GetLocaleNameLength(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->format.locale_len; } -static HRESULT WINAPI dwritetextlayout_GetLocaleName(IDWriteTextLayout *iface, WCHAR *name, UINT32 size) +static HRESULT WINAPI dwritetextlayout_GetLocaleName(IDWriteTextLayout2 *iface, WCHAR *name, UINT32 size) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)->(%p %u)\n", This, name, size); @@ -767,25 +768,33 @@ return S_OK; } -static HRESULT WINAPI dwritetextlayout_SetMaxWidth(IDWriteTextLayout *iface, FLOAT maxWidth) +static HRESULT WINAPI dwritetextlayout_SetMaxWidth(IDWriteTextLayout2 *iface, FLOAT maxWidth) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)->(%.1f)\n", This, maxWidth); + + if (maxWidth < 0.0) + return E_INVALIDARG; + This->maxwidth = maxWidth; return S_OK; } -static HRESULT WINAPI dwritetextlayout_SetMaxHeight(IDWriteTextLayout *iface, FLOAT maxHeight) +static HRESULT WINAPI dwritetextlayout_SetMaxHeight(IDWriteTextLayout2 *iface, FLOAT maxHeight) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)->(%.1f)\n", This, maxHeight); + + if (maxHeight < 0.0) + return E_INVALIDARG; + This->maxheight = maxHeight; return S_OK; } -static HRESULT WINAPI dwritetextlayout_SetFontCollection(IDWriteTextLayout *iface, IDWriteFontCollection* collection, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetFontCollection(IDWriteTextLayout2 *iface, IDWriteFontCollection* collection, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value value; TRACE("(%p)->(%p %s)\n", This, collection, debugstr_range(&range)); @@ -798,16 +807,16 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_FONTCOLL, &value); } -static HRESULT WINAPI dwritetextlayout_SetFontFamilyName(IDWriteTextLayout *iface, WCHAR const *name, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetFontFamilyName(IDWriteTextLayout2 *iface, WCHAR const *name, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%s %s): stub\n", This, debugstr_w(name), debugstr_range(&range)); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetFontWeight(IDWriteTextLayout *iface, DWRITE_FONT_WEIGHT weight, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetFontWeight(IDWriteTextLayout2 *iface, DWRITE_FONT_WEIGHT weight, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value value; TRACE("(%p)->(%d %s)\n", This, weight, debugstr_range(&range)); @@ -820,9 +829,9 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_WEIGHT, &value); } -static HRESULT WINAPI dwritetextlayout_SetFontStyle(IDWriteTextLayout *iface, DWRITE_FONT_STYLE style, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetFontStyle(IDWriteTextLayout2 *iface, DWRITE_FONT_STYLE style, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value value; TRACE("(%p)->(%d %s)\n", This, style, debugstr_range(&range)); @@ -835,9 +844,9 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_STYLE, &value); } -static HRESULT WINAPI dwritetextlayout_SetFontStretch(IDWriteTextLayout *iface, DWRITE_FONT_STRETCH stretch, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetFontStretch(IDWriteTextLayout2 *iface, DWRITE_FONT_STRETCH stretch, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value value; TRACE("(%p)->(%d %s)\n", This, stretch, debugstr_range(&range)); @@ -850,9 +859,9 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_STRETCH, &value); } -static HRESULT WINAPI dwritetextlayout_SetFontSize(IDWriteTextLayout *iface, FLOAT size, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetFontSize(IDWriteTextLayout2 *iface, FLOAT size, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value value; TRACE("(%p)->(%.2f %s)\n", This, size, debugstr_range(&range)); @@ -865,9 +874,9 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_FONTSIZE, &value); } -static HRESULT WINAPI dwritetextlayout_SetUnderline(IDWriteTextLayout *iface, BOOL underline, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetUnderline(IDWriteTextLayout2 *iface, BOOL underline, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value value; TRACE("(%p)->(%d %s)\n", This, underline, debugstr_range(&range)); @@ -880,9 +889,9 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_UNDERLINE, &value); } -static HRESULT WINAPI dwritetextlayout_SetStrikethrough(IDWriteTextLayout *iface, BOOL strikethrough, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetStrikethrough(IDWriteTextLayout2 *iface, BOOL strikethrough, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value value; TRACE("(%p)->(%d %s)\n", This, strikethrough, debugstr_range(&range)); @@ -895,9 +904,9 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_STRIKETHROUGH, &value); } -static HRESULT WINAPI dwritetextlayout_SetDrawingEffect(IDWriteTextLayout *iface, IUnknown* effect, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetDrawingEffect(IDWriteTextLayout2 *iface, IUnknown* effect, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value value; TRACE("(%p)->(%p %s)\n", This, effect, debugstr_range(&range)); @@ -910,9 +919,9 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_EFFECT, &value); } -static HRESULT WINAPI dwritetextlayout_SetInlineObject(IDWriteTextLayout *iface, IDWriteInlineObject *object, DWRITE_TEXT_RANGE r) +static HRESULT WINAPI dwritetextlayout_SetInlineObject(IDWriteTextLayout2 *iface, IDWriteInlineObject *object, DWRITE_TEXT_RANGE r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range_attr_value attr; TRACE("(%p)->(%p %s)\n", This, object, debugstr_range(&r)); @@ -926,38 +935,38 @@ return set_layout_range_attr(This, LAYOUT_RANGE_ATTR_INLINE, &attr); } -static HRESULT WINAPI dwritetextlayout_SetTypography(IDWriteTextLayout *iface, IDWriteTypography* typography, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetTypography(IDWriteTextLayout2 *iface, IDWriteTypography* typography, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%p %s): stub\n", This, typography, debugstr_range(&range)); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_SetLocaleName(IDWriteTextLayout *iface, WCHAR const* locale, DWRITE_TEXT_RANGE range) +static HRESULT WINAPI dwritetextlayout_SetLocaleName(IDWriteTextLayout2 *iface, WCHAR const* locale, DWRITE_TEXT_RANGE range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%s %s): stub\n", This, debugstr_w(locale), debugstr_range(&range)); return E_NOTIMPL; } -static FLOAT WINAPI dwritetextlayout_GetMaxWidth(IDWriteTextLayout *iface) +static FLOAT WINAPI dwritetextlayout_GetMaxWidth(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->maxwidth; } -static FLOAT WINAPI dwritetextlayout_GetMaxHeight(IDWriteTextLayout *iface) +static FLOAT WINAPI dwritetextlayout_GetMaxHeight(IDWriteTextLayout2 *iface) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); TRACE("(%p)\n", This); return This->maxheight; } -static HRESULT WINAPI dwritetextlayout_layout_GetFontCollection(IDWriteTextLayout *iface, UINT32 position, +static HRESULT WINAPI dwritetextlayout_layout_GetFontCollection(IDWriteTextLayout2 *iface, UINT32 position, IDWriteFontCollection** collection, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, collection, r); @@ -970,26 +979,26 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_layout_GetFontFamilyNameLength(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_layout_GetFontFamilyNameLength(IDWriteTextLayout2 *iface, UINT32 pos, UINT32* len, DWRITE_TEXT_RANGE *range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%d %p %p): stub\n", This, pos, len, range); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_layout_GetFontFamilyName(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_layout_GetFontFamilyName(IDWriteTextLayout2 *iface, UINT32 position, WCHAR* name, UINT32 name_size, DWRITE_TEXT_RANGE *range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%u %p %u %p): stub\n", This, position, name, name_size, range); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_layout_GetFontWeight(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_layout_GetFontWeight(IDWriteTextLayout2 *iface, UINT32 position, DWRITE_FONT_WEIGHT *weight, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, weight, r); @@ -1003,10 +1012,10 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_layout_GetFontStyle(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_layout_GetFontStyle(IDWriteTextLayout2 *iface, UINT32 position, DWRITE_FONT_STYLE *style, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, style, r); @@ -1020,10 +1029,10 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_layout_GetFontStretch(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_layout_GetFontStretch(IDWriteTextLayout2 *iface, UINT32 position, DWRITE_FONT_STRETCH *stretch, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, stretch, r); @@ -1037,10 +1046,10 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_layout_GetFontSize(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_layout_GetFontSize(IDWriteTextLayout2 *iface, UINT32 position, FLOAT *size, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, size, r); @@ -1054,10 +1063,10 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_GetUnderline(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_GetUnderline(IDWriteTextLayout2 *iface, UINT32 position, BOOL *underline, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, underline, r); @@ -1071,10 +1080,10 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_GetStrikethrough(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_GetStrikethrough(IDWriteTextLayout2 *iface, UINT32 position, BOOL *strikethrough, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, strikethrough, r); @@ -1088,10 +1097,10 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_GetDrawingEffect(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_GetDrawingEffect(IDWriteTextLayout2 *iface, UINT32 position, IUnknown **effect, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, effect, r); @@ -1107,10 +1116,10 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_GetInlineObject(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_GetInlineObject(IDWriteTextLayout2 *iface, UINT32 position, IDWriteInlineObject **object, DWRITE_TEXT_RANGE *r) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); struct layout_range *range; TRACE("(%p)->(%u %p %p)\n", This, position, object, r); @@ -1123,102 +1132,197 @@ return return_range(range, r); } -static HRESULT WINAPI dwritetextlayout_GetTypography(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_GetTypography(IDWriteTextLayout2 *iface, UINT32 position, IDWriteTypography** typography, DWRITE_TEXT_RANGE *range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%u %p %p): stub\n", This, position, typography, range); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_layout_GetLocaleNameLength(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_layout_GetLocaleNameLength(IDWriteTextLayout2 *iface, UINT32 position, UINT32* length, DWRITE_TEXT_RANGE *range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%u %p %p): stub\n", This, position, length, range); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_layout_GetLocaleName(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_layout_GetLocaleName(IDWriteTextLayout2 *iface, UINT32 position, WCHAR* name, UINT32 name_size, DWRITE_TEXT_RANGE *range) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%u %p %u %p): stub\n", This, position, name, name_size, range); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_Draw(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_Draw(IDWriteTextLayout2 *iface, void *context, IDWriteTextRenderer* renderer, FLOAT originX, FLOAT originY) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%p %p %f %f): stub\n", This, context, renderer, originX, originY); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_GetLineMetrics(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_GetLineMetrics(IDWriteTextLayout2 *iface, DWRITE_LINE_METRICS *metrics, UINT32 max_count, UINT32 *actual_count) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%p %u %p): stub\n", This, metrics, max_count, actual_count); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_GetMetrics(IDWriteTextLayout *iface, DWRITE_TEXT_METRICS *metrics) +static HRESULT WINAPI dwritetextlayout_GetMetrics(IDWriteTextLayout2 *iface, DWRITE_TEXT_METRICS *metrics) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%p): stub\n", This, metrics); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_GetOverhangMetrics(IDWriteTextLayout *iface, DWRITE_OVERHANG_METRICS *overhangs) +static HRESULT WINAPI dwritetextlayout_GetOverhangMetrics(IDWriteTextLayout2 *iface, DWRITE_OVERHANG_METRICS *overhangs) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%p): stub\n", This, overhangs); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_GetClusterMetrics(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_GetClusterMetrics(IDWriteTextLayout2 *iface, DWRITE_CLUSTER_METRICS *metrics, UINT32 max_count, UINT32* act_count) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%p %u %p): stub\n", This, metrics, max_count, act_count); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_DetermineMinWidth(IDWriteTextLayout *iface, FLOAT* min_width) +static HRESULT WINAPI dwritetextlayout_DetermineMinWidth(IDWriteTextLayout2 *iface, FLOAT* min_width) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%p): stub\n", This, min_width); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_HitTestPoint(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_HitTestPoint(IDWriteTextLayout2 *iface, FLOAT pointX, FLOAT pointY, BOOL* is_trailinghit, BOOL* is_inside, DWRITE_HIT_TEST_METRICS *metrics) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%f %f %p %p %p): stub\n", This, pointX, pointY, is_trailinghit, is_inside, metrics); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_HitTestTextPosition(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_HitTestTextPosition(IDWriteTextLayout2 *iface, UINT32 textPosition, BOOL is_trailinghit, FLOAT* pointX, FLOAT* pointY, DWRITE_HIT_TEST_METRICS *metrics) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%u %d %p %p %p): stub\n", This, textPosition, is_trailinghit, pointX, pointY, metrics); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextlayout_HitTestTextRange(IDWriteTextLayout *iface, +static HRESULT WINAPI dwritetextlayout_HitTestTextRange(IDWriteTextLayout2 *iface, UINT32 textPosition, UINT32 textLength, FLOAT originX, FLOAT originY, DWRITE_HIT_TEST_METRICS *metrics, UINT32 max_metricscount, UINT32* actual_metricscount) { - struct dwrite_textlayout *This = impl_from_IDWriteTextLayout(iface); + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); FIXME("(%p)->(%u %u %f %f %p %u %p): stub\n", This, textPosition, textLength, originX, originY, metrics, max_metricscount, actual_metricscount); return E_NOTIMPL; } -static const IDWriteTextLayoutVtbl dwritetextlayoutvtbl = { +static HRESULT WINAPI dwritetextlayout1_SetPairKerning(IDWriteTextLayout2 *iface, BOOL is_pairkerning_enabled, + DWRITE_TEXT_RANGE range) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%d %s): stub\n", This, is_pairkerning_enabled, debugstr_range(&range)); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritetextlayout1_GetPairKerning(IDWriteTextLayout2 *iface, UINT32 position, BOOL *is_pairkerning_enabled, + DWRITE_TEXT_RANGE *range) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%p %p): stub\n", This, is_pairkerning_enabled, range); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritetextlayout1_SetCharacterSpacing(IDWriteTextLayout2 *iface, FLOAT leading_spacing, FLOAT trailing_spacing, + FLOAT minimum_advance_width, DWRITE_TEXT_RANGE range) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%f %f %f %s): stub\n", This, leading_spacing, trailing_spacing, minimum_advance_width, debugstr_range(&range)); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritetextlayout1_GetCharacterSpacing(IDWriteTextLayout2 *iface, UINT32 position, FLOAT* leading_spacing, + FLOAT* trailing_spacing, FLOAT* minimum_advance_width, DWRITE_TEXT_RANGE *range) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%u %p %p %p %p): stub\n", This, position, leading_spacing, trailing_spacing, minimum_advance_width, range); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritetextlayout2_GetMetrics(IDWriteTextLayout2 *iface, DWRITE_TEXT_METRICS1 *metrics) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%p): stub\n", This, metrics); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritetextlayout2_SetVerticalGlyphOrientation(IDWriteTextLayout2 *iface, DWRITE_VERTICAL_GLYPH_ORIENTATION orientation) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%d): stub\n", This, orientation); + return E_NOTIMPL; +} + +static DWRITE_VERTICAL_GLYPH_ORIENTATION WINAPI dwritetextlayout2_GetVerticalGlyphOrientation(IDWriteTextLayout2 *iface) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p): stub\n", This); + return DWRITE_VERTICAL_GLYPH_ORIENTATION_DEFAULT; +} + +static HRESULT WINAPI dwritetextlayout2_SetLastLineWrapping(IDWriteTextLayout2 *iface, BOOL lastline_wrapping_enabled) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%d): stub\n", This, lastline_wrapping_enabled); + return E_NOTIMPL; +} + +static BOOL WINAPI dwritetextlayout2_GetLastLineWrapping(IDWriteTextLayout2 *iface) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p): stub\n", This); + return FALSE; +} + +static HRESULT WINAPI dwritetextlayout2_SetOpticalAlignment(IDWriteTextLayout2 *iface, DWRITE_OPTICAL_ALIGNMENT alignment) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%d): stub\n", This, alignment); + return E_NOTIMPL; +} + +static DWRITE_OPTICAL_ALIGNMENT WINAPI dwritetextlayout2_GetOpticalAlignment(IDWriteTextLayout2 *iface) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p): stub\n", This); + return DWRITE_OPTICAL_ALIGNMENT_NONE; +} + +static HRESULT WINAPI dwritetextlayout2_SetFontFallback(IDWriteTextLayout2 *iface, IDWriteFontFallback *fallback) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%p): stub\n", This, fallback); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritetextlayout2_GetFontFallback(IDWriteTextLayout2 *iface, IDWriteFontFallback **fallback) +{ + struct dwrite_textlayout *This = impl_from_IDWriteTextLayout2(iface); + FIXME("(%p)->(%p): stub\n", This, fallback); + return E_NOTIMPL; +} + +static const IDWriteTextLayout2Vtbl dwritetextlayoutvtbl = { dwritetextlayout_QueryInterface, dwritetextlayout_AddRef, dwritetextlayout_Release, @@ -1285,7 +1389,20 @@ dwritetextlayout_DetermineMinWidth, dwritetextlayout_HitTestPoint, dwritetextlayout_HitTestTextPosition, - dwritetextlayout_HitTestTextRange + dwritetextlayout_HitTestTextRange, + dwritetextlayout1_SetPairKerning, + dwritetextlayout1_GetPairKerning, + dwritetextlayout1_SetCharacterSpacing, + dwritetextlayout1_GetCharacterSpacing, + dwritetextlayout2_GetMetrics, + dwritetextlayout2_SetVerticalGlyphOrientation, + dwritetextlayout2_GetVerticalGlyphOrientation, + dwritetextlayout2_SetLastLineWrapping, + dwritetextlayout2_GetLastLineWrapping, + dwritetextlayout2_SetOpticalAlignment, + dwritetextlayout2_GetOpticalAlignment, + dwritetextlayout2_SetFontFallback, + dwritetextlayout2_GetFontFallback }; static void layout_format_from_textformat(struct dwrite_textlayout *layout, IDWriteTextFormat *format) @@ -1294,7 +1411,7 @@ memset(&layout->format, 0, sizeof(layout->format)); - if ((f = unsafe_impl_from_IDWriteTextFormat(format))) + if ((f = unsafe_impl_from_IDWriteTextFormat1((IDWriteTextFormat1*)format))) { layout->format = f->format; layout->format.locale = heap_strdupW(f->format.locale); @@ -1349,7 +1466,7 @@ This = heap_alloc(sizeof(struct dwrite_textlayout)); if (!This) return E_OUTOFMEMORY; - This->IDWriteTextLayout_iface.lpVtbl = &dwritetextlayoutvtbl; + This->IDWriteTextLayout2_iface.lpVtbl = &dwritetextlayoutvtbl; This->ref = 1; This->str = heap_strdupnW(str, len); This->len = len; @@ -1360,12 +1477,12 @@ list_init(&This->ranges); range = alloc_layout_range(This, &r); if (!range) { - IDWriteTextLayout_Release(&This->IDWriteTextLayout_iface); + IDWriteTextLayout2_Release(&This->IDWriteTextLayout2_iface); return E_OUTOFMEMORY; } list_add_head(&This->ranges, &range->entry); - *layout = &This->IDWriteTextLayout_iface; + *layout = (IDWriteTextLayout*)&This->IDWriteTextLayout2_iface; return S_OK; } @@ -1468,17 +1585,18 @@ return S_OK; } -static HRESULT WINAPI dwritetextformat_QueryInterface(IDWriteTextFormat *iface, REFIID riid, void **obj) +static HRESULT WINAPI dwritetextformat_QueryInterface(IDWriteTextFormat1 *iface, REFIID riid, void **obj) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), obj); - if (IsEqualIID(riid, &IID_IUnknown) || - IsEqualIID(riid, &IID_IDWriteTextFormat)) + if (IsEqualIID(riid, &IID_IDWriteTextFormat1) || + IsEqualIID(riid, &IID_IDWriteTextFormat) || + IsEqualIID(riid, &IID_IUnknown)) { *obj = iface; - IDWriteTextFormat_AddRef(iface); + IDWriteTextFormat1_AddRef(iface); return S_OK; } @@ -1487,17 +1605,17 @@ return E_NOINTERFACE; } -static ULONG WINAPI dwritetextformat_AddRef(IDWriteTextFormat *iface) +static ULONG WINAPI dwritetextformat_AddRef(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); ULONG ref = InterlockedIncrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); return ref; } -static ULONG WINAPI dwritetextformat_Release(IDWriteTextFormat *iface) +static ULONG WINAPI dwritetextformat_Release(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); ULONG ref = InterlockedDecrement(&This->ref); TRACE("(%p)->(%d)\n", This, ref); @@ -1511,57 +1629,57 @@ return ref; } -static HRESULT WINAPI dwritetextformat_SetTextAlignment(IDWriteTextFormat *iface, DWRITE_TEXT_ALIGNMENT alignment) +static HRESULT WINAPI dwritetextformat_SetTextAlignment(IDWriteTextFormat1 *iface, DWRITE_TEXT_ALIGNMENT alignment) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%d)\n", This, alignment); This->format.textalignment = alignment; return S_OK; } -static HRESULT WINAPI dwritetextformat_SetParagraphAlignment(IDWriteTextFormat *iface, DWRITE_PARAGRAPH_ALIGNMENT alignment) +static HRESULT WINAPI dwritetextformat_SetParagraphAlignment(IDWriteTextFormat1 *iface, DWRITE_PARAGRAPH_ALIGNMENT alignment) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%d)\n", This, alignment); This->format.paralign = alignment; return S_OK; } -static HRESULT WINAPI dwritetextformat_SetWordWrapping(IDWriteTextFormat *iface, DWRITE_WORD_WRAPPING wrapping) +static HRESULT WINAPI dwritetextformat_SetWordWrapping(IDWriteTextFormat1 *iface, DWRITE_WORD_WRAPPING wrapping) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%d)\n", This, wrapping); This->format.wrapping = wrapping; return S_OK; } -static HRESULT WINAPI dwritetextformat_SetReadingDirection(IDWriteTextFormat *iface, DWRITE_READING_DIRECTION direction) +static HRESULT WINAPI dwritetextformat_SetReadingDirection(IDWriteTextFormat1 *iface, DWRITE_READING_DIRECTION direction) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%d)\n", This, direction); This->format.readingdir = direction; return S_OK; } -static HRESULT WINAPI dwritetextformat_SetFlowDirection(IDWriteTextFormat *iface, DWRITE_FLOW_DIRECTION direction) +static HRESULT WINAPI dwritetextformat_SetFlowDirection(IDWriteTextFormat1 *iface, DWRITE_FLOW_DIRECTION direction) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%d)\n", This, direction); This->format.flow = direction; return S_OK; } -static HRESULT WINAPI dwritetextformat_SetIncrementalTabStop(IDWriteTextFormat *iface, FLOAT tabstop) +static HRESULT WINAPI dwritetextformat_SetIncrementalTabStop(IDWriteTextFormat1 *iface, FLOAT tabstop) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); FIXME("(%p)->(%f): stub\n", This, tabstop); return E_NOTIMPL; } -static HRESULT WINAPI dwritetextformat_SetTrimming(IDWriteTextFormat *iface, DWRITE_TRIMMING const *trimming, +static HRESULT WINAPI dwritetextformat_SetTrimming(IDWriteTextFormat1 *iface, DWRITE_TRIMMING const *trimming, IDWriteInlineObject *trimming_sign) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%p %p)\n", This, trimming, trimming_sign); This->format.trimming = *trimming; @@ -1573,10 +1691,10 @@ return S_OK; } -static HRESULT WINAPI dwritetextformat_SetLineSpacing(IDWriteTextFormat *iface, DWRITE_LINE_SPACING_METHOD method, +static HRESULT WINAPI dwritetextformat_SetLineSpacing(IDWriteTextFormat1 *iface, DWRITE_LINE_SPACING_METHOD method, FLOAT spacing, FLOAT baseline) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%d %f %f)\n", This, method, spacing, baseline); This->format.spacingmethod = method; This->format.spacing = spacing; @@ -1584,52 +1702,52 @@ return S_OK; } -static DWRITE_TEXT_ALIGNMENT WINAPI dwritetextformat_GetTextAlignment(IDWriteTextFormat *iface) +static DWRITE_TEXT_ALIGNMENT WINAPI dwritetextformat_GetTextAlignment(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.textalignment; } -static DWRITE_PARAGRAPH_ALIGNMENT WINAPI dwritetextformat_GetParagraphAlignment(IDWriteTextFormat *iface) +static DWRITE_PARAGRAPH_ALIGNMENT WINAPI dwritetextformat_GetParagraphAlignment(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.paralign; } -static DWRITE_WORD_WRAPPING WINAPI dwritetextformat_GetWordWrapping(IDWriteTextFormat *iface) +static DWRITE_WORD_WRAPPING WINAPI dwritetextformat_GetWordWrapping(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.wrapping; } -static DWRITE_READING_DIRECTION WINAPI dwritetextformat_GetReadingDirection(IDWriteTextFormat *iface) +static DWRITE_READING_DIRECTION WINAPI dwritetextformat_GetReadingDirection(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.readingdir; } -static DWRITE_FLOW_DIRECTION WINAPI dwritetextformat_GetFlowDirection(IDWriteTextFormat *iface) +static DWRITE_FLOW_DIRECTION WINAPI dwritetextformat_GetFlowDirection(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.flow; } -static FLOAT WINAPI dwritetextformat_GetIncrementalTabStop(IDWriteTextFormat *iface) +static FLOAT WINAPI dwritetextformat_GetIncrementalTabStop(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); FIXME("(%p): stub\n", This); return 0.0; } -static HRESULT WINAPI dwritetextformat_GetTrimming(IDWriteTextFormat *iface, DWRITE_TRIMMING *options, +static HRESULT WINAPI dwritetextformat_GetTrimming(IDWriteTextFormat1 *iface, DWRITE_TRIMMING *options, IDWriteInlineObject **trimming_sign) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%p %p)\n", This, options, trimming_sign); *options = This->format.trimming; @@ -1639,10 +1757,10 @@ return S_OK; } -static HRESULT WINAPI dwritetextformat_GetLineSpacing(IDWriteTextFormat *iface, DWRITE_LINE_SPACING_METHOD *method, +static HRESULT WINAPI dwritetextformat_GetLineSpacing(IDWriteTextFormat1 *iface, DWRITE_LINE_SPACING_METHOD *method, FLOAT *spacing, FLOAT *baseline) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%p %p %p)\n", This, method, spacing, baseline); *method = This->format.spacingmethod; @@ -1651,9 +1769,9 @@ return S_OK; } -static HRESULT WINAPI dwritetextformat_GetFontCollection(IDWriteTextFormat *iface, IDWriteFontCollection **collection) +static HRESULT WINAPI dwritetextformat_GetFontCollection(IDWriteTextFormat1 *iface, IDWriteFontCollection **collection) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%p)\n", This, collection); @@ -1663,16 +1781,16 @@ return S_OK; } -static UINT32 WINAPI dwritetextformat_GetFontFamilyNameLength(IDWriteTextFormat *iface) +static UINT32 WINAPI dwritetextformat_GetFontFamilyNameLength(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.family_len; } -static HRESULT WINAPI dwritetextformat_GetFontFamilyName(IDWriteTextFormat *iface, WCHAR *name, UINT32 size) +static HRESULT WINAPI dwritetextformat_GetFontFamilyName(IDWriteTextFormat1 *iface, WCHAR *name, UINT32 size) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%p %u)\n", This, name, size); @@ -1681,44 +1799,44 @@ return S_OK; } -static DWRITE_FONT_WEIGHT WINAPI dwritetextformat_GetFontWeight(IDWriteTextFormat *iface) +static DWRITE_FONT_WEIGHT WINAPI dwritetextformat_GetFontWeight(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.weight; } -static DWRITE_FONT_STYLE WINAPI dwritetextformat_GetFontStyle(IDWriteTextFormat *iface) +static DWRITE_FONT_STYLE WINAPI dwritetextformat_GetFontStyle(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.style; } -static DWRITE_FONT_STRETCH WINAPI dwritetextformat_GetFontStretch(IDWriteTextFormat *iface) +static DWRITE_FONT_STRETCH WINAPI dwritetextformat_GetFontStretch(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.stretch; } -static FLOAT WINAPI dwritetextformat_GetFontSize(IDWriteTextFormat *iface) +static FLOAT WINAPI dwritetextformat_GetFontSize(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.fontsize; } -static UINT32 WINAPI dwritetextformat_GetLocaleNameLength(IDWriteTextFormat *iface) +static UINT32 WINAPI dwritetextformat_GetLocaleNameLength(IDWriteTextFormat1 *iface) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)\n", This); return This->format.locale_len; } -static HRESULT WINAPI dwritetextformat_GetLocaleName(IDWriteTextFormat *iface, WCHAR *name, UINT32 size) +static HRESULT WINAPI dwritetextformat_GetLocaleName(IDWriteTextFormat1 *iface, WCHAR *name, UINT32 size) { - struct dwrite_textformat *This = impl_from_IDWriteTextFormat(iface); + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); TRACE("(%p)->(%p %u)\n", This, name, size); @@ -1727,7 +1845,63 @@ return S_OK; } -static const IDWriteTextFormatVtbl dwritetextformatvtbl = { +static HRESULT WINAPI dwritetextformat1_SetVerticalGlyphOrientation(IDWriteTextFormat1 *iface, DWRITE_VERTICAL_GLYPH_ORIENTATION orientation) +{ + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); + FIXME("(%p)->(%d): stub\n", This, orientation); + return E_NOTIMPL; +} + +static DWRITE_VERTICAL_GLYPH_ORIENTATION WINAPI dwritetextformat1_GetVerticalGlyphOrientation(IDWriteTextFormat1 *iface) +{ + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); + FIXME("(%p): stub\n", This); + return DWRITE_VERTICAL_GLYPH_ORIENTATION_DEFAULT; +} + +static HRESULT WINAPI dwritetextformat1_SetLastLineWrapping(IDWriteTextFormat1 *iface, BOOL lastline_wrapping_enabled) +{ + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); + FIXME("(%p)->(%d): stub\n", This, lastline_wrapping_enabled); + return E_NOTIMPL; +} + +static BOOL WINAPI dwritetextformat1_GetLastLineWrapping(IDWriteTextFormat1 *iface) +{ + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); + FIXME("(%p): stub\n", This); + return FALSE; +} + +static HRESULT WINAPI dwritetextformat1_SetOpticalAlignment(IDWriteTextFormat1 *iface, DWRITE_OPTICAL_ALIGNMENT alignment) +{ + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); + FIXME("(%p)->(%d): stub\n", This, alignment); + return E_NOTIMPL; +} + +static DWRITE_OPTICAL_ALIGNMENT WINAPI dwritetextformat1_GetOpticalAlignment(IDWriteTextFormat1 *iface) +{ + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); + FIXME("(%p): stub\n", This); + return DWRITE_OPTICAL_ALIGNMENT_NONE; +} + +static HRESULT WINAPI dwritetextformat1_SetFontFallback(IDWriteTextFormat1 *iface, IDWriteFontFallback *fallback) +{ + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); + FIXME("(%p)->(%p): stub\n", This, fallback); + return E_NOTIMPL; +} + +static HRESULT WINAPI dwritetextformat1_GetFontFallback(IDWriteTextFormat1 *iface, IDWriteFontFallback **fallback) +{ + struct dwrite_textformat *This = impl_from_IDWriteTextFormat1(iface); + FIXME("(%p)->(%p): stub\n", This, fallback); + return E_NOTIMPL; +} + +static const IDWriteTextFormat1Vtbl dwritetextformatvtbl = { dwritetextformat_QueryInterface, dwritetextformat_AddRef, dwritetextformat_Release, @@ -1755,7 +1929,15 @@ dwritetextformat_GetFontStretch, dwritetextformat_GetFontSize, dwritetextformat_GetLocaleNameLength, - dwritetextformat_GetLocaleName + dwritetextformat_GetLocaleName, + dwritetextformat1_SetVerticalGlyphOrientation, + dwritetextformat1_GetVerticalGlyphOrientation, + dwritetextformat1_SetLastLineWrapping, + dwritetextformat1_GetLastLineWrapping, + dwritetextformat1_SetOpticalAlignment, + dwritetextformat1_GetOpticalAlignment, + dwritetextformat1_SetFontFallback, + dwritetextformat1_GetFontFallback }; HRESULT create_textformat(const WCHAR *family_name, IDWriteFontCollection *collection, DWRITE_FONT_WEIGHT weight, DWRITE_FONT_STYLE style, @@ -1768,7 +1950,7 @@ This = heap_alloc(sizeof(struct dwrite_textformat)); if (!This) return E_OUTOFMEMORY; - This->IDWriteTextFormat_iface.lpVtbl = &dwritetextformatvtbl; + This->IDWriteTextFormat1_iface.lpVtbl = &dwritetextformatvtbl; This->ref = 1; This->format.family_name = heap_strdupW(family_name); This->format.family_len = strlenW(family_name); @@ -1799,7 +1981,7 @@ else ERR("Collection should always be set\n"); - *format = &This->IDWriteTextFormat_iface; + *format = (IDWriteTextFormat*)&This->IDWriteTextFormat1_iface; return S_OK; } diff -Nru wine1.7-1.7.28/dlls/dwrite/main.c wine1.7-1.7.31/dlls/dwrite/main.c --- wine1.7-1.7.28/dlls/dwrite/main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/main.c 2014-11-14 13:28:17.000000000 +0000 @@ -27,14 +27,16 @@ #include "winuser.h" #include "initguid.h" -#include "dwrite.h" -#include "dwrite_2.h" #include "dwrite_private.h" #include "wine/debug.h" +#include "wine/list.h" WINE_DEFAULT_DEBUG_CHANNEL(dwrite); +static IDWriteFactory *shared_factory; +static void release_shared_factory(IDWriteFactory*); + BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD reason, LPVOID reserved) { switch (reason) @@ -44,6 +46,9 @@ case DLL_PROCESS_ATTACH: DisableThreadLibraryCalls( hinstDLL ); break; + case DLL_PROCESS_DETACH: + if (reserved) break; + release_shared_factory(shared_factory); } return TRUE; } @@ -251,22 +256,57 @@ WCHAR const *locale_name, UINT32 *index, BOOL *exists) { struct localizedstrings *This = impl_from_IDWriteLocalizedStrings(iface); - FIXME("(%p)->(%s %p %p): stub\n", This, debugstr_w(locale_name), index, exists); - return E_NOTIMPL; + UINT32 i; + + TRACE("(%p)->(%s %p %p)\n", This, debugstr_w(locale_name), index, exists); + + *exists = FALSE; + *index = ~0; + + for (i = 0; i < This->count; i++) { + if (!strcmpiW(This->data[i].locale, locale_name)) { + *exists = TRUE; + *index = i; + break; + } + } + + return S_OK; } static HRESULT WINAPI localizedstrings_GetLocaleNameLength(IDWriteLocalizedStrings *iface, UINT32 index, UINT32 *length) { struct localizedstrings *This = impl_from_IDWriteLocalizedStrings(iface); - FIXME("(%p)->(%u %p): stub\n", This, index, length); - return E_NOTIMPL; + + TRACE("(%p)->(%u %p)\n", This, index, length); + + if (index >= This->count) { + *length = (UINT32)-1; + return E_FAIL; + } + + *length = strlenW(This->data[index].locale); + return S_OK; } -static HRESULT WINAPI localizedstrings_GetLocaleName(IDWriteLocalizedStrings *iface, UINT32 index, WCHAR *locale_name, UINT32 size) +static HRESULT WINAPI localizedstrings_GetLocaleName(IDWriteLocalizedStrings *iface, UINT32 index, WCHAR *buffer, UINT32 size) { struct localizedstrings *This = impl_from_IDWriteLocalizedStrings(iface); - FIXME("(%p)->(%u %p %u): stub\n", This, index, locale_name, size); - return E_NOTIMPL; + + TRACE("(%p)->(%u %p %u)\n", This, index, buffer, size); + + if (index >= This->count) { + if (buffer) *buffer = 0; + return E_FAIL; + } + + if (size < strlenW(This->data[index].locale)+1) { + if (buffer) *buffer = 0; + return E_NOT_SUFFICIENT_BUFFER; + } + + strcpyW(buffer, This->data[index].locale); + return S_OK; } static HRESULT WINAPI localizedstrings_GetStringLength(IDWriteLocalizedStrings *iface, UINT32 index, UINT32 *length) @@ -356,48 +396,71 @@ return S_OK; } -HRESULT clone_localizedstring(IDWriteLocalizedStrings *iface, IDWriteLocalizedStrings **strings) -{ - struct localizedstrings *This = impl_from_IDWriteLocalizedStrings(iface); - struct localizedstrings *New; +HRESULT clone_localizedstring(IDWriteLocalizedStrings *iface, IDWriteLocalizedStrings **ret) + { + struct localizedstrings *strings, *strings_clone; int i; - *strings = NULL; + *ret = NULL; - New = heap_alloc(sizeof(struct localizedstrings)); - if (!New) return E_OUTOFMEMORY; + if (!iface) + return S_FALSE; - New->IDWriteLocalizedStrings_iface.lpVtbl = &localizedstringsvtbl; - New->ref = 1; - New->count = This->count; - New->data = heap_alloc(sizeof(struct localizedpair) * New->count); - if (!New->data) { - heap_free(New); + strings = impl_from_IDWriteLocalizedStrings(iface); + strings_clone = heap_alloc(sizeof(struct localizedstrings)); + if (!strings_clone) return E_OUTOFMEMORY; + + strings_clone->IDWriteLocalizedStrings_iface.lpVtbl = &localizedstringsvtbl; + strings_clone->ref = 1; + strings_clone->count = strings->count; + strings_clone->data = heap_alloc(sizeof(struct localizedpair) * strings_clone->count); + if (!strings_clone->data) { + heap_free(strings_clone); return E_OUTOFMEMORY; } - for (i = 0; i < New->count; i++) + for (i = 0; i < strings_clone->count; i++) { - New->data[i].locale = heap_strdupW(This->data[i].locale); - New->data[i].string = heap_strdupW(This->data[i].string); + strings_clone->data[i].locale = heap_strdupW(strings->data[i].locale); + strings_clone->data[i].string = heap_strdupW(strings->data[i].string); } - New->alloc = New->count; + strings_clone->alloc = strings_clone->count; - *strings = &New->IDWriteLocalizedStrings_iface; + *ret = &strings_clone->IDWriteLocalizedStrings_iface; return S_OK; } -struct dwritefactory{ +struct collectionloader +{ + struct list entry; + IDWriteFontCollectionLoader *loader; +}; + +struct fontfacecached +{ + struct list entry; + IDWriteFontFace *fontface; +}; + +struct fileloader +{ + struct list entry; + struct list fontfaces; + IDWriteFontFileLoader *loader; +}; + +struct dwritefactory { IDWriteFactory IDWriteFactory_iface; LONG ref; - IDWriteLocalFontFileLoader* localfontfileloader; IDWriteFontCollection *system_collection; + IDWriteGdiInterop *gdiinterop; - IDWriteFontCollectionLoader **loaders; - LONG loader_count; - IDWriteFontFileLoader **file_loaders; - LONG file_loader_count; + IDWriteLocalFontFileLoader* localfontfileloader; + struct list localfontfaces; + + struct list collection_loaders; + struct list file_loaders; }; static inline struct dwritefactory *impl_from_IDWriteFactory(IDWriteFactory *iface) @@ -405,6 +468,85 @@ return CONTAINING_RECORD(iface, struct dwritefactory, IDWriteFactory_iface); } +static void release_fontface_cache(struct list *fontfaces) +{ + struct fontfacecached *fontface, *fontface2; + LIST_FOR_EACH_ENTRY_SAFE(fontface, fontface2, fontfaces, struct fontfacecached, entry) { + list_remove(&fontface->entry); + IDWriteFontFace_Release(fontface->fontface); + heap_free(fontface); + } +} + +static void release_fileloader(struct fileloader *fileloader) +{ + list_remove(&fileloader->entry); + release_fontface_cache(&fileloader->fontfaces); + IDWriteFontFileLoader_Release(fileloader->loader); + heap_free(fileloader); +} + +static void release_dwritefactory(struct dwritefactory *factory) +{ + struct fileloader *fileloader, *fileloader2; + struct collectionloader *loader, *loader2; + + if (factory->localfontfileloader) + IDWriteLocalFontFileLoader_Release(factory->localfontfileloader); + release_fontface_cache(&factory->localfontfaces); + + LIST_FOR_EACH_ENTRY_SAFE(loader, loader2, &factory->collection_loaders, struct collectionloader, entry) { + list_remove(&loader->entry); + IDWriteFontCollectionLoader_Release(loader->loader); + heap_free(loader); + } + + LIST_FOR_EACH_ENTRY_SAFE(fileloader, fileloader2, &factory->file_loaders, struct fileloader, entry) + release_fileloader(fileloader); + + if (factory->system_collection) + IDWriteFontCollection_Release(factory->system_collection); + if (factory->gdiinterop) + release_gdiinterop(factory->gdiinterop); + heap_free(factory); +} + +static void release_shared_factory(IDWriteFactory *iface) +{ + struct dwritefactory *factory; + if (!iface) return; + factory = impl_from_IDWriteFactory(iface); + release_dwritefactory(factory); +} + +static struct fileloader *factory_get_file_loader(struct dwritefactory *factory, IDWriteFontFileLoader *loader) +{ + struct fileloader *entry, *found = NULL; + + LIST_FOR_EACH_ENTRY(entry, &factory->file_loaders, struct fileloader, entry) { + if (entry->loader == loader) { + found = entry; + break; + } + } + + return found; +} + +static struct collectionloader *factory_get_collection_loader(struct dwritefactory *factory, IDWriteFontCollectionLoader *loader) +{ + struct collectionloader *entry, *found = NULL; + + LIST_FOR_EACH_ENTRY(entry, &factory->collection_loaders, struct collectionloader, entry) { + if (entry->loader == loader) { + found = entry; + break; + } + } + + return found; +} + static HRESULT WINAPI dwritefactory_QueryInterface(IDWriteFactory *iface, REFIID riid, void **obj) { struct dwritefactory *This = impl_from_IDWriteFactory(iface); @@ -439,22 +581,8 @@ TRACE("(%p)->(%d)\n", This, ref); - if (!ref) { - int i; - if (This->localfontfileloader) - IDWriteLocalFontFileLoader_Release(This->localfontfileloader); - for (i = 0; i < This->loader_count; i++) - if (This->loaders[i]) - IDWriteFontCollectionLoader_Release(This->loaders[i]); - heap_free(This->loaders); - for (i = 0; i < This->file_loader_count; i++) - if (This->file_loaders[i]) - IDWriteFontFileLoader_Release(This->file_loaders[i]); - heap_free(This->file_loaders); - if (This->system_collection) - IDWriteFontCollection_Release(This->system_collection); - heap_free(This); - } + if (!ref) + release_dwritefactory(This); return ref; } @@ -470,7 +598,7 @@ FIXME("checking for system font updates not implemented\n"); if (!This->system_collection) - hr = get_system_fontcollection(&This->system_collection); + hr = get_system_fontcollection(iface, &This->system_collection); if (SUCCEEDED(hr)) IDWriteFontCollection_AddRef(This->system_collection); @@ -484,42 +612,51 @@ IDWriteFontCollectionLoader *loader, void const *key, UINT32 key_size, IDWriteFontCollection **collection) { struct dwritefactory *This = impl_from_IDWriteFactory(iface); - FIXME("(%p)->(%p %p %u %p): stub\n", This, loader, key, key_size, collection); - return E_NOTIMPL; + IDWriteFontFileEnumerator *enumerator; + struct collectionloader *found; + HRESULT hr; + + TRACE("(%p)->(%p %p %u %p)\n", This, loader, key, key_size, collection); + + *collection = NULL; + + if (!loader) + return E_INVALIDARG; + + found = factory_get_collection_loader(This, loader); + if (!found) + return E_INVALIDARG; + + hr = IDWriteFontCollectionLoader_CreateEnumeratorFromKey(found->loader, iface, key, key_size, &enumerator); + if (FAILED(hr)) + return hr; + + hr = create_font_collection(iface, enumerator, FALSE, collection); + IDWriteFontFileEnumerator_Release(enumerator); + return hr; } static HRESULT WINAPI dwritefactory_RegisterFontCollectionLoader(IDWriteFactory *iface, IDWriteFontCollectionLoader *loader) { - int i; struct dwritefactory *This = impl_from_IDWriteFactory(iface); + struct collectionloader *entry; TRACE("(%p)->(%p)\n", This, loader); - for (i = 0; i < This->loader_count; i++) - if (This->loaders[i] == loader) - return DWRITE_E_ALREADYREGISTERED; - else if (This->loaders[i] == NULL) - break; + if (!loader) + return E_INVALIDARG; - if (i == This->loader_count) - { - IDWriteFontCollectionLoader **new_list = NULL; - int new_count = 0; + if (factory_get_collection_loader(This, loader)) + return DWRITE_E_ALREADYREGISTERED; - new_count = This->loader_count * 2; - new_list = heap_realloc_zero(This->loaders, new_count * sizeof(*This->loaders)); + entry = heap_alloc(sizeof(*entry)); + if (!entry) + return E_OUTOFMEMORY; - if (!new_list) - return E_OUTOFMEMORY; - else - { - This->loader_count = new_count; - This->loaders = new_list; - } - } + entry->loader = loader; IDWriteFontCollectionLoader_AddRef(loader); - This->loaders[i] = loader; + list_add_tail(&This->collection_loaders, &entry->entry); return S_OK; } @@ -527,17 +664,21 @@ static HRESULT WINAPI dwritefactory_UnregisterFontCollectionLoader(IDWriteFactory *iface, IDWriteFontCollectionLoader *loader) { - int i; struct dwritefactory *This = impl_from_IDWriteFactory(iface); + struct collectionloader *found; TRACE("(%p)->(%p)\n", This, loader); - for (i = 0; i < This->loader_count; i++) - if (This->loaders[i] == loader) break; - if (i == This->loader_count) - return E_INVALIDARG; - IDWriteFontCollectionLoader_Release(This->loaders[i]); - This->loaders[i] = NULL; + if (!loader) + return E_INVALIDARG; + + found = factory_get_collection_loader(This, loader); + if (!found) + return E_INVALIDARG; + + IDWriteFontCollectionLoader_Release(found->loader); + list_remove(&found->entry); + heap_free(found); return S_OK; } @@ -561,30 +702,105 @@ static HRESULT WINAPI dwritefactory_CreateCustomFontFileReference(IDWriteFactory *iface, void const *reference_key, UINT32 key_size, IDWriteFontFileLoader *loader, IDWriteFontFile **font_file) { - int i; struct dwritefactory *This = impl_from_IDWriteFactory(iface); - HRESULT hr; TRACE("(%p)->(%p %u %p %p)\n", This, reference_key, key_size, loader, font_file); - if (loader == NULL) + if (!loader || !factory_get_file_loader(This, loader)) return E_INVALIDARG; - for (i = 0; i < This->file_loader_count; i++) - if (This->file_loaders[i] == loader) break; - if (i == This->file_loader_count) - return E_INVALIDARG; - hr = create_font_file(loader, reference_key, key_size, font_file); - return hr; + return create_font_file(loader, reference_key, key_size, font_file); } static HRESULT WINAPI dwritefactory_CreateFontFace(IDWriteFactory *iface, DWRITE_FONT_FACE_TYPE facetype, UINT32 files_number, IDWriteFontFile* const* font_files, - UINT32 index, DWRITE_FONT_SIMULATIONS sim_flags, IDWriteFontFace **font_face) + UINT32 index, DWRITE_FONT_SIMULATIONS simulations, IDWriteFontFace **font_face) { struct dwritefactory *This = impl_from_IDWriteFactory(iface); - TRACE("(%p)->(%d %u %p %u 0x%x %p)\n", This, facetype, files_number, font_files, index, sim_flags, font_face); - return font_create_fontface(iface, facetype, files_number, font_files, index, sim_flags, font_face); + IDWriteFontFileLoader *loader; + struct fontfacecached *cached; + struct list *fontfaces; + IDWriteFontFace2 *face; + const void *key; + UINT32 key_size; + HRESULT hr; + + TRACE("(%p)->(%d %u %p %u 0x%x %p)\n", This, facetype, files_number, font_files, index, simulations, font_face); + + *font_face = NULL; + + if (facetype != DWRITE_FONT_FACE_TYPE_TRUETYPE_COLLECTION && index) + return E_INVALIDARG; + + hr = IDWriteFontFile_GetReferenceKey(*font_files, &key, &key_size); + if (FAILED(hr)) + return hr; + + hr = IDWriteFontFile_GetLoader(*font_files, &loader); + if (FAILED(hr)) + return hr; + + if (loader == (IDWriteFontFileLoader*)This->localfontfileloader) { + fontfaces = &This->localfontfaces; + IDWriteFontFileLoader_Release(loader); + } + else { + struct fileloader *fileloader = factory_get_file_loader(This, loader); + IDWriteFontFileLoader_Release(loader); + if (!fileloader) + return E_INVALIDARG; + fontfaces = &fileloader->fontfaces; + } + + /* search through cache list */ + LIST_FOR_EACH_ENTRY(cached, fontfaces, struct fontfacecached, entry) { + UINT32 cached_key_size, count = 1, cached_face_index; + DWRITE_FONT_SIMULATIONS cached_simulations; + const void *cached_key; + IDWriteFontFile *file; + + cached_face_index = IDWriteFontFace_GetIndex(cached->fontface); + cached_simulations = IDWriteFontFace_GetSimulations(cached->fontface); + + /* skip earlier */ + if (cached_face_index != index || cached_simulations != simulations) + continue; + + hr = IDWriteFontFace_GetFiles(cached->fontface, &count, &file); + if (FAILED(hr)) + return hr; + + hr = IDWriteFontFile_GetReferenceKey(file, &cached_key, &cached_key_size); + IDWriteFontFile_Release(file); + if (FAILED(hr)) + return hr; + + if (cached_key_size == key_size && !memcmp(cached_key, key, key_size)) { + TRACE("returning cached fontface %p\n", cached->fontface); + *font_face = cached->fontface; + IDWriteFontFace_AddRef(*font_face); + return S_OK; + } + } + + hr = create_fontface(facetype, files_number, font_files, index, simulations, &face); + if (FAILED(hr)) + return hr; + + /* new cache entry */ + cached = heap_alloc(sizeof(*cached)); + if (!cached) { + IDWriteFontFace2_Release(face); + return hr; + } + + cached->fontface = (IDWriteFontFace*)face; + list_add_tail(fontfaces, &cached->entry); + + *font_face = cached->fontface; + IDWriteFontFace_AddRef(*font_face); + + return S_OK; } static HRESULT WINAPI dwritefactory_CreateRenderingParams(IDWriteFactory *iface, IDWriteRenderingParams **params) @@ -624,54 +840,50 @@ static HRESULT WINAPI dwritefactory_RegisterFontFileLoader(IDWriteFactory *iface, IDWriteFontFileLoader *loader) { - int i; struct dwritefactory *This = impl_from_IDWriteFactory(iface); + struct fileloader *entry; + TRACE("(%p)->(%p)\n", This, loader); if (!loader) return E_INVALIDARG; - for (i = 0; i < This->file_loader_count; i++) - if (This->file_loaders[i] == loader) - return DWRITE_E_ALREADYREGISTERED; - else if (This->file_loaders[i] == NULL) - break; + if ((IDWriteFontFileLoader*)This->localfontfileloader == loader) + return S_OK; - if (i == This->file_loader_count) - { - IDWriteFontFileLoader **new_list = NULL; - int new_count = 0; + if (factory_get_file_loader(This, loader)) + return DWRITE_E_ALREADYREGISTERED; - new_count = This->file_loader_count * 2; - new_list = heap_realloc_zero(This->file_loaders, new_count * sizeof(*This->file_loaders)); + entry = heap_alloc(sizeof(*entry)); + if (!entry) + return E_OUTOFMEMORY; - if (!new_list) - return E_OUTOFMEMORY; - else - { - This->file_loader_count = new_count; - This->file_loaders = new_list; - } - } + entry->loader = loader; + list_init(&entry->fontfaces); IDWriteFontFileLoader_AddRef(loader); - This->file_loaders[i] = loader; + list_add_tail(&This->file_loaders, &entry->entry); return S_OK; } static HRESULT WINAPI dwritefactory_UnregisterFontFileLoader(IDWriteFactory *iface, IDWriteFontFileLoader *loader) { - int i; struct dwritefactory *This = impl_from_IDWriteFactory(iface); + struct fileloader *found; + TRACE("(%p)->(%p)\n", This, loader); - for (i = 0; i < This->file_loader_count; i++) - if (This->file_loaders[i] == loader) break; - if (i == This->file_loader_count) - return E_INVALIDARG; - IDWriteFontFileLoader_Release(This->file_loaders[i]); - This->file_loaders[i] = NULL; + if (!loader) + return E_INVALIDARG; + + if ((IDWriteFontFileLoader*)This->localfontfileloader == loader) + return S_OK; + found = factory_get_file_loader(This, loader); + if (!found) + return E_INVALIDARG; + + release_fileloader(found); return S_OK; } @@ -704,8 +916,21 @@ static HRESULT WINAPI dwritefactory_GetGdiInterop(IDWriteFactory *iface, IDWriteGdiInterop **gdi_interop) { struct dwritefactory *This = impl_from_IDWriteFactory(iface); + TRACE("(%p)->(%p)\n", This, gdi_interop); - return get_gdiinterop(gdi_interop); + + *gdi_interop = NULL; + + if (!This->gdiinterop) { + HRESULT hr = create_gdiinterop(iface, &This->gdiinterop); + if (FAILED(hr)) + return hr; + } + + *gdi_interop = This->gdiinterop; + IDWriteGdiInterop_AddRef(*gdi_interop); + + return S_OK; } static HRESULT WINAPI dwritefactory_CreateTextLayout(IDWriteFactory *iface, WCHAR const* string, @@ -790,27 +1015,89 @@ dwritefactory_CreateGlyphRunAnalysis }; -HRESULT WINAPI DWriteCreateFactory(DWRITE_FACTORY_TYPE type, REFIID riid, IUnknown **factory) +static ULONG WINAPI shareddwritefactory_AddRef(IDWriteFactory *iface) { - struct dwritefactory *This; + struct dwritefactory *This = impl_from_IDWriteFactory(iface); + TRACE("(%p)\n", This); + return 2; +} - TRACE("(%d, %s, %p)\n", type, debugstr_guid(riid), factory); +static ULONG WINAPI shareddwritefactory_Release(IDWriteFactory *iface) +{ + struct dwritefactory *This = impl_from_IDWriteFactory(iface); + TRACE("(%p)\n", This); + return 1; +} + +static const struct IDWriteFactoryVtbl shareddwritefactoryvtbl = { + dwritefactory_QueryInterface, + shareddwritefactory_AddRef, + shareddwritefactory_Release, + dwritefactory_GetSystemFontCollection, + dwritefactory_CreateCustomFontCollection, + dwritefactory_RegisterFontCollectionLoader, + dwritefactory_UnregisterFontCollectionLoader, + dwritefactory_CreateFontFileReference, + dwritefactory_CreateCustomFontFileReference, + dwritefactory_CreateFontFace, + dwritefactory_CreateRenderingParams, + dwritefactory_CreateMonitorRenderingParams, + dwritefactory_CreateCustomRenderingParams, + dwritefactory_RegisterFontFileLoader, + dwritefactory_UnregisterFontFileLoader, + dwritefactory_CreateTextFormat, + dwritefactory_CreateTypography, + dwritefactory_GetGdiInterop, + dwritefactory_CreateTextLayout, + dwritefactory_CreateGdiCompatibleTextLayout, + dwritefactory_CreateEllipsisTrimmingSign, + dwritefactory_CreateTextAnalyzer, + dwritefactory_CreateNumberSubstitution, + dwritefactory_CreateGlyphRunAnalysis +}; + +static void init_dwritefactory(struct dwritefactory *factory, const struct IDWriteFactoryVtbl *vtbl) +{ + factory->IDWriteFactory_iface.lpVtbl = vtbl; + factory->ref = 1; + factory->localfontfileloader = NULL; + factory->system_collection = NULL; + factory->gdiinterop = NULL; + + list_init(&factory->collection_loaders); + list_init(&factory->file_loaders); + list_init(&factory->localfontfaces); +} + +HRESULT WINAPI DWriteCreateFactory(DWRITE_FACTORY_TYPE type, REFIID riid, IUnknown **ret) +{ + struct dwritefactory *factory; + + TRACE("(%d, %s, %p)\n", type, debugstr_guid(riid), ret); + + *ret = NULL; if (!IsEqualIID(riid, &IID_IDWriteFactory)) return E_FAIL; - This = heap_alloc(sizeof(struct dwritefactory)); - if (!This) return E_OUTOFMEMORY; + if (type == DWRITE_FACTORY_TYPE_SHARED && shared_factory) { + *ret = (IUnknown*)shared_factory; + IDWriteFactory_AddRef(shared_factory); + return S_OK; + } - This->IDWriteFactory_iface.lpVtbl = &dwritefactoryvtbl; - This->ref = 1; - This->localfontfileloader = NULL; - This->loader_count = 2; - This->loaders = heap_alloc_zero(sizeof(*This->loaders) * 2); - This->file_loader_count = 2; - This->file_loaders = heap_alloc_zero(sizeof(*This->file_loaders) * 2); - This->system_collection = NULL; + factory = heap_alloc(sizeof(struct dwritefactory)); + if (!factory) return E_OUTOFMEMORY; + + init_dwritefactory(factory, type == DWRITE_FACTORY_TYPE_SHARED ? &shareddwritefactoryvtbl : &dwritefactoryvtbl); - *factory = (IUnknown*)&This->IDWriteFactory_iface; + if (type == DWRITE_FACTORY_TYPE_SHARED) + if (InterlockedCompareExchangePointer((void**)&shared_factory, factory, NULL)) { + release_shared_factory(&factory->IDWriteFactory_iface); + *ret = (IUnknown*)shared_factory; + IDWriteFactory_AddRef(shared_factory); + return S_OK; + } + *ret = (IUnknown*)&factory->IDWriteFactory_iface; return S_OK; } diff -Nru wine1.7-1.7.28/dlls/dwrite/Makefile.in wine1.7-1.7.31/dlls/dwrite/Makefile.in --- wine1.7-1.7.28/dlls/dwrite/Makefile.in 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -11,5 +11,7 @@ layout.c \ linebreak.c \ main.c \ + mirror.c \ opentype.c \ - scripts.c + scripts.c \ + shape.c diff -Nru wine1.7-1.7.28/dlls/dwrite/mirror.c wine1.7-1.7.31/dlls/dwrite/mirror.c --- wine1.7-1.7.28/dlls/dwrite/mirror.c 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/mirror.c 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,437 @@ +/* Unicode BiDi mirroring */ +/* generated from http://www.unicode.org/Public/7.0.0/ucd/BidiMirroring.txt */ +/* DO NOT EDIT!! */ + +#include "wine/unicode.h" + +const WCHAR wine_mirror_map[3292] = +{ + /* index */ + 0x01d8, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x029e, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0303, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x03ca, 0x0100, 0x04c2, 0x05c1, 0x0100, 0x0100, 0x0100, 0x0659, + 0x0100, 0x0749, 0x0847, 0x0100, 0x0100, 0x0100, 0x0945, 0x0100, + 0x0a3d, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, + 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0100, 0x0ae4, 0x0bdc, + /* defaults */ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x0028 .. 0x00ff */ + 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0002, 0x0000, 0xfffe, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0002, 0x0000, 0xfffe, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0002, 0x0000, 0xfffe, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0010, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0xfff0, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x0f3a .. 0x0fff */ + 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x169b .. 0x16ff */ + 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x2039 .. 0x20ff */ + 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x2208 .. 0x22ff */ + 0x0003, 0x0003, 0x0003, 0xfffd, 0xfffd, 0xfffd, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x07e0, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x008a, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0720, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0838, 0x0000, + 0x083c, 0x083a, 0x0000, 0x083a, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0xff76, 0x0000, 0x0000, + 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0001, 0xffff, 0x0008, 0x0008, 0x0008, 0x0000, 0x0007, 0x0007, + 0x0000, 0x0000, 0xfff8, 0xfff8, 0xfff8, 0xfff9, 0xfff9, 0x0000, + /* 0x2301 .. 0x23ff */ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x2768 .. 0x27ff */ + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, + 0x0001, 0xffff, 0x0000, 0x0002, 0x0000, 0xfffe, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, + 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x2910 .. 0x29ff */ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0003, 0x0001, 0xffff, + 0xfffd, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, + 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0xf8e0, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0001, 0xffff, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xf820, 0x0000, 0x0000, + 0x0001, 0xffff, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, + /* 0x2a02 .. 0x2aff */ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, + 0xffff, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, + 0xffff, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0001, 0xffff, 0x0000, + 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, + 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0xf7c8, 0x0000, 0x0000, 0x0000, + 0x0000, 0xf7c6, 0xf7c4, 0xf7c6, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, + 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x2e02 .. 0x2eff */ + 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0001, + 0xffff, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0x3008 .. 0x30ff */ + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, + 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0xfe59 .. 0xfeff */ + 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + /* 0xff08 .. 0xffff */ + 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0002, 0x0000, 0xfffe, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0002, 0x0000, 0xfffe, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0002, 0x0000, 0xfffe, 0x0000, 0x0001, + 0xffff, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 +}; diff -Nru wine1.7-1.7.28/dlls/dwrite/opentype.c wine1.7-1.7.31/dlls/dwrite/opentype.c --- wine1.7-1.7.28/dlls/dwrite/opentype.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/opentype.c 2014-11-14 13:28:17.000000000 +0000 @@ -20,15 +20,10 @@ #define COBJMACROS -#include "dwrite.h" #include "dwrite_private.h" WINE_DEFAULT_DEBUG_CHANNEL(dwrite); -#define DWRITE_MAKE_OPENTYPE_TAG(ch0, ch1, ch2, ch3) \ - ((DWORD)(BYTE)(ch0) | ((DWORD)(BYTE)(ch1) << 8) | \ - ((DWORD)(BYTE)(ch2) << 16) | ((DWORD)(BYTE)(ch3) << 24)) - #define MS_TTCF_TAG DWRITE_MAKE_OPENTYPE_TAG('t','t','c','f') #define MS_OTTO_TAG DWRITE_MAKE_OPENTYPE_TAG('O','T','T','O') @@ -100,6 +95,12 @@ WORD endCode[1]; } CMAP_SegmentMapping_0; +enum OPENTYPE_CMAP_TABLE_FORMAT +{ + OPENTYPE_CMAP_TABLE_SEGMENT_MAPPING = 4, + OPENTYPE_CMAP_TABLE_SEGMENTED_COVERAGE = 12 +}; + /* PANOSE is 10 bytes in size, need to pack the structure properly */ #include "pshpack2.h" typedef struct @@ -184,11 +185,390 @@ } TT_OS2_V2; #include "poppack.h" -HRESULT analyze_opentype_font(const void* font_data, UINT32* font_count, DWRITE_FONT_FILE_TYPE *file_type, DWRITE_FONT_FACE_TYPE *face_type, BOOL *supported) +typedef struct { + WORD platformID; + WORD encodingID; + WORD languageID; + WORD nameID; + WORD length; + WORD offset; +} TT_NameRecord; + +typedef struct { + WORD format; + WORD count; + WORD stringOffset; + TT_NameRecord nameRecord[1]; +} TT_NAME_V0; + +enum OPENTYPE_PLATFORM_ID +{ + OPENTYPE_PLATFORM_UNICODE = 0, + OPENTYPE_PLATFORM_MAC, + OPENTYPE_PLATFORM_ISO, + OPENTYPE_PLATFORM_WIN, + OPENTYPE_PLATFORM_CUSTOM +}; + +enum TT_NAME_WINDOWS_ENCODING_ID +{ + TT_NAME_WINDOWS_ENCODING_SYMBOL = 0, + TT_NAME_WINDOWS_ENCODING_UCS2, + TT_NAME_WINDOWS_ENCODING_SJIS, + TT_NAME_WINDOWS_ENCODING_PRC, + TT_NAME_WINDOWS_ENCODING_BIG5, + TT_NAME_WINDOWS_ENCODING_WANSUNG, + TT_NAME_WINDOWS_ENCODING_JOHAB, + TT_NAME_WINDOWS_ENCODING_RESERVED1, + TT_NAME_WINDOWS_ENCODING_RESERVED2, + TT_NAME_WINDOWS_ENCODING_RESERVED3, + TT_NAME_WINDOWS_ENCODING_UCS4 +}; + +enum TT_NAME_MAC_ENCODING_ID +{ + TT_NAME_MAC_ENCODING_ROMAN = 0, + TT_NAME_MAC_ENCODING_JAPANESE, + TT_NAME_MAC_ENCODING_TRAD_CHINESE, + TT_NAME_MAC_ENCODING_KOREAN, + TT_NAME_MAC_ENCODING_ARABIC, + TT_NAME_MAC_ENCODING_HEBREW, + TT_NAME_MAC_ENCODING_GREEK, + TT_NAME_MAC_ENCODING_RUSSIAN, + TT_NAME_MAC_ENCODING_RSYMBOL, + TT_NAME_MAC_ENCODING_DEVANAGARI, + TT_NAME_MAC_ENCODING_GURMUKHI, + TT_NAME_MAC_ENCODING_GUJARATI, + TT_NAME_MAC_ENCODING_ORIYA, + TT_NAME_MAC_ENCODING_BENGALI, + TT_NAME_MAC_ENCODING_TAMIL, + TT_NAME_MAC_ENCODING_TELUGU, + TT_NAME_MAC_ENCODING_KANNADA, + TT_NAME_MAC_ENCODING_MALAYALAM, + TT_NAME_MAC_ENCODING_SINHALESE, + TT_NAME_MAC_ENCODING_BURMESE, + TT_NAME_MAC_ENCODING_KHMER, + TT_NAME_MAC_ENCODING_THAI, + TT_NAME_MAC_ENCODING_LAOTIAN, + TT_NAME_MAC_ENCODING_GEORGIAN, + TT_NAME_MAC_ENCODING_ARMENIAN, + TT_NAME_MAC_ENCODING_SIMPL_CHINESE, + TT_NAME_MAC_ENCODING_TIBETAN, + TT_NAME_MAC_ENCODING_MONGOLIAN, + TT_NAME_MAC_ENCODING_GEEZ, + TT_NAME_MAC_ENCODING_SLAVIC, + TT_NAME_MAC_ENCODING_VIETNAMESE, + TT_NAME_MAC_ENCODING_SINDHI, + TT_NAME_MAC_ENCODING_UNINTERPRETED +}; + +enum TT_NAME_MAC_LANGUAGE_ID +{ + TT_NAME_MAC_LANGID_ENGLISH = 0, + TT_NAME_MAC_LANGID_FRENCH, + TT_NAME_MAC_LANGID_GERMAN, + TT_NAME_MAC_LANGID_ITALIAN, + TT_NAME_MAC_LANGID_DUTCH, + TT_NAME_MAC_LANGID_SWEDISH, + TT_NAME_MAC_LANGID_SPANISH, + TT_NAME_MAC_LANGID_DANISH, + TT_NAME_MAC_LANGID_PORTUGUESE, + TT_NAME_MAC_LANGID_NORWEGIAN, + TT_NAME_MAC_LANGID_HEBREW, + TT_NAME_MAC_LANGID_JAPANESE, + TT_NAME_MAC_LANGID_ARABIC, + TT_NAME_MAC_LANGID_FINNISH, + TT_NAME_MAC_LANGID_GREEK, + TT_NAME_MAC_LANGID_ICELANDIC, + TT_NAME_MAC_LANGID_MALTESE, + TT_NAME_MAC_LANGID_TURKISH, + TT_NAME_MAC_LANGID_CROATIAN, + TT_NAME_MAC_LANGID_TRAD_CHINESE, + TT_NAME_MAC_LANGID_URDU, + TT_NAME_MAC_LANGID_HINDI, + TT_NAME_MAC_LANGID_THAI, + TT_NAME_MAC_LANGID_KOREAN, + TT_NAME_MAC_LANGID_LITHUANIAN, + TT_NAME_MAC_LANGID_POLISH, + TT_NAME_MAC_LANGID_HUNGARIAN, + TT_NAME_MAC_LANGID_ESTONIAN, + TT_NAME_MAC_LANGID_LATVIAN, + TT_NAME_MAC_LANGID_SAMI, + TT_NAME_MAC_LANGID_FAROESE, + TT_NAME_MAC_LANGID_FARSI, + TT_NAME_MAC_LANGID_RUSSIAN, + TT_NAME_MAC_LANGID_SIMPL_CHINESE, + TT_NAME_MAC_LANGID_FLEMISH, + TT_NAME_MAC_LANGID_GAELIC, + TT_NAME_MAC_LANGID_ALBANIAN, + TT_NAME_MAC_LANGID_ROMANIAN, + TT_NAME_MAC_LANGID_CZECH, + TT_NAME_MAC_LANGID_SLOVAK, + TT_NAME_MAC_LANGID_SLOVENIAN, + TT_NAME_MAC_LANGID_YIDDISH, + TT_NAME_MAC_LANGID_SERBIAN, + TT_NAME_MAC_LANGID_MACEDONIAN, + TT_NAME_MAC_LANGID_BULGARIAN, + TT_NAME_MAC_LANGID_UKRAINIAN, + TT_NAME_MAC_LANGID_BYELORUSSIAN, + TT_NAME_MAC_LANGID_UZBEK, + TT_NAME_MAC_LANGID_KAZAKH, + TT_NAME_MAC_LANGID_AZERB_CYR, + TT_NAME_MAC_LANGID_AZERB_ARABIC, + TT_NAME_MAC_LANGID_ARMENIAN, + TT_NAME_MAC_LANGID_GEORGIAN, + TT_NAME_MAC_LANGID_MOLDAVIAN, + TT_NAME_MAC_LANGID_KIRGHIZ, + TT_NAME_MAC_LANGID_TAJIKI, + TT_NAME_MAC_LANGID_TURKMEN, + TT_NAME_MAC_LANGID_MONGOLIAN, + TT_NAME_MAC_LANGID_MONGOLIAN_CYR, + TT_NAME_MAC_LANGID_PASHTO, + TT_NAME_MAC_LANGID_KURDISH, + TT_NAME_MAC_LANGID_KASHMIRI, + TT_NAME_MAC_LANGID_SINDHI, + TT_NAME_MAC_LANGID_TIBETAN, + TT_NAME_MAC_LANGID_NEPALI, + TT_NAME_MAC_LANGID_SANSKRIT, + TT_NAME_MAC_LANGID_MARATHI, + TT_NAME_MAC_LANGID_BENGALI, + TT_NAME_MAC_LANGID_ASSAMESE, + TT_NAME_MAC_LANGID_GUJARATI, + TT_NAME_MAC_LANGID_PUNJABI, + TT_NAME_MAC_LANGID_ORIYA, + TT_NAME_MAC_LANGID_MALAYALAM, + TT_NAME_MAC_LANGID_KANNADA, + TT_NAME_MAC_LANGID_TAMIL, + TT_NAME_MAC_LANGID_TELUGU, + TT_NAME_MAC_LANGID_SINHALESE, + TT_NAME_MAC_LANGID_BURMESE, + TT_NAME_MAC_LANGID_KHMER, + TT_NAME_MAC_LANGID_LAO, + TT_NAME_MAC_LANGID_VIETNAMESE, + TT_NAME_MAC_LANGID_INDONESIAN, + TT_NAME_MAC_LANGID_TAGALONG, + TT_NAME_MAC_LANGID_MALAY_ROMAN, + TT_NAME_MAC_LANGID_MALAY_ARABIC, + TT_NAME_MAC_LANGID_AMHARIC, + TT_NAME_MAC_LANGID_TIGRINYA, + TT_NAME_MAC_LANGID_GALLA, + TT_NAME_MAC_LANGID_SOMALI, + TT_NAME_MAC_LANGID_SWAHILI, + TT_NAME_MAC_LANGID_KINYARWANDA, + TT_NAME_MAC_LANGID_RUNDI, + TT_NAME_MAC_LANGID_NYANJA, + TT_NAME_MAC_LANGID_MALAGASY, + TT_NAME_MAC_LANGID_ESPERANTO, + TT_NAME_MAC_LANGID_WELSH, + TT_NAME_MAC_LANGID_BASQUE, + TT_NAME_MAC_LANGID_CATALAN, + TT_NAME_MAC_LANGID_LATIN, + TT_NAME_MAC_LANGID_QUENCHUA, + TT_NAME_MAC_LANGID_GUARANI, + TT_NAME_MAC_LANGID_AYMARA, + TT_NAME_MAC_LANGID_TATAR, + TT_NAME_MAC_LANGID_UIGHUR, + TT_NAME_MAC_LANGID_DZONGKHA, + TT_NAME_MAC_LANGID_JAVANESE, + TT_NAME_MAC_LANGID_SUNDANESE, + TT_NAME_MAC_LANGID_GALICIAN, + TT_NAME_MAC_LANGID_AFRIKAANS, + TT_NAME_MAC_LANGID_BRETON, + TT_NAME_MAC_LANGID_INUKTITUT, + TT_NAME_MAC_LANGID_SCOTTISH_GAELIC, + TT_NAME_MAC_LANGID_MANX_GAELIC, + TT_NAME_MAC_LANGID_IRISH_GAELIC, + TT_NAME_MAC_LANGID_TONGAN, + TT_NAME_MAC_LANGID_GREEK_POLYTONIC, + TT_NAME_MAC_LANGID_GREENLANDIC, + TT_NAME_MAC_LANGID_AZER_ROMAN +}; + +/* Names are indexed with TT_NAME_MAC_LANGUAGE_ID values */ +static const char name_mac_langid_to_locale[][10] = { + "en-US", + "fr-FR", + "de-DE", + "it-IT", + "nl-NL", + "sv-SE", + "es-ES", + "da-DA", + "pt-PT", + "no-NO", + "he-IL", + "ja-JP", + "ar-AR", + "fi-FI", + "el-GR", + "is-IS", + "mt-MT", + "tr-TR", + "hr-HR", + "zh-HK", + "ur-PK", + "hi-IN", + "th-TH", + "ko-KR", + "lt-LT", + "pl-PL", + "hu-HU", + "et-EE", + "lv-LV", + "se-NO", + "fo-FO", + "fa-IR", + "ru-RU", + "zh-CN", + "nl-BE", + "gd-GB", + "sq-AL", + "ro-RO", + "cs-CZ", + "sk-SK", + "sl-SI", + "", + "sr-Latn", + "mk-MK", + "bg-BG", + "uk-UA", + "be-BY", + "uz-Latn", + "kk-KZ", + "az-Cyrl-AZ", + "az-AZ", + "hy-AM", + "ka-GE", + "", + "", + "tg-TJ", + "tk-TM", + "mn-Mong", + "mn-MN", + "ps-AF", + "ku-Arab", + "", + "sd-Arab", + "bo-CN", + "ne-NP", + "sa-IN", + "mr-IN", + "bn-IN", + "as-IN", + "gu-IN", + "pa-Arab", + "or-IN", + "ml-IN", + "kn-IN", + "ta-LK", + "te-IN", + "si-LK", + "", + "km-KH", + "lo-LA", + "vi-VN", + "id-ID", + "", + "ms-MY", + "ms-Arab", + "am-ET", + "ti-ET", + "", + "", + "sw-KE", + "rw-RW", + "", + "", + "", + "", + "cy-GB", + "eu-ES", + "ca-ES", + "", + "", + "", + "", + "tt-RU", + "ug-CN", + "", + "", + "", + "gl-ES", + "af-ZA", + "br-FR", + "iu-Latn-CA", + "gd-GB", + "", + "ga-IE", + "", + "", + "kl-GL", + "az-Latn" +}; + +enum OPENTYPE_STRING_ID +{ + OPENTYPE_STRING_COPYRIGHT_NOTICE = 0, + OPENTYPE_STRING_FAMILY_NAME, + OPENTYPE_STRING_SUBFAMILY_NAME, + OPENTYPE_STRING_UNIQUE_IDENTIFIER, + OPENTYPE_STRING_FULL_FONTNAME, + OPENTYPE_STRING_VERSION_STRING, + OPENTYPE_STRING_POSTSCRIPT_FONTNAME, + OPENTYPE_STRING_TRADEMARK, + OPENTYPE_STRING_MANUFACTURER, + OPENTYPE_STRING_DESIGNER, + OPENTYPE_STRING_DESCRIPTION, + OPENTYPE_STRING_VENDOR_URL, + OPENTYPE_STRING_DESIGNER_URL, + OPENTYPE_STRING_LICENSE_DESCRIPTION, + OPENTYPE_STRING_LICENSE_INFO_URL, + OPENTYPE_STRING_RESERVED_ID15, + OPENTYPE_STRING_PREFERRED_FAMILY_NAME, + OPENTYPE_STRING_PREFERRED_SUBFAMILY_NAME, + OPENTYPE_STRING_COMPATIBLE_FULLNAME, + OPENTYPE_STRING_SAMPLE_TEXT, + OPENTYPE_STRING_POSTSCRIPT_CID_NAME, + OPENTYPE_STRING_WWS_FAMILY_NAME, + OPENTYPE_STRING_WWS_SUBFAMILY_NAME +}; + +static const UINT16 dwriteid_to_opentypeid[DWRITE_INFORMATIONAL_STRING_POSTSCRIPT_CID_NAME+1] = +{ + (UINT16)-1, /* DWRITE_INFORMATIONAL_STRING_NONE is not used */ + OPENTYPE_STRING_COPYRIGHT_NOTICE, + OPENTYPE_STRING_VERSION_STRING, + OPENTYPE_STRING_TRADEMARK, + OPENTYPE_STRING_MANUFACTURER, + OPENTYPE_STRING_DESIGNER, + OPENTYPE_STRING_DESIGNER_URL, + OPENTYPE_STRING_DESCRIPTION, + OPENTYPE_STRING_VENDOR_URL, + OPENTYPE_STRING_LICENSE_DESCRIPTION, + OPENTYPE_STRING_LICENSE_INFO_URL, + OPENTYPE_STRING_FAMILY_NAME, + OPENTYPE_STRING_SUBFAMILY_NAME, + OPENTYPE_STRING_PREFERRED_FAMILY_NAME, + OPENTYPE_STRING_PREFERRED_SUBFAMILY_NAME, + OPENTYPE_STRING_SAMPLE_TEXT, + OPENTYPE_STRING_FULL_FONTNAME, + OPENTYPE_STRING_POSTSCRIPT_FONTNAME, + OPENTYPE_STRING_POSTSCRIPT_CID_NAME +}; + +HRESULT opentype_analyze_font(IDWriteFontFileStream *stream, UINT32* font_count, DWRITE_FONT_FILE_TYPE *file_type, DWRITE_FONT_FACE_TYPE *face_type, BOOL *supported) { /* TODO: Do font validation */ - const char* tag = font_data; + const void *font_data; + const char* tag; + void *context; + HRESULT hr; + + hr = IDWriteFontFileStream_ReadFileFragment(stream, &font_data, 0, sizeof(TTC_Header_V1), &context); + if (FAILED(hr)) + return hr; + tag = font_data; *supported = FALSE; *file_type = DWRITE_FONT_FILE_TYPE_UNKNOWN; if (face_type) @@ -216,51 +596,41 @@ { *file_type = DWRITE_FONT_FILE_TYPE_CFF; } + + IDWriteFontFileStream_ReleaseFileFragment(stream, context); return S_OK; } -HRESULT find_font_table(IDWriteFontFileStream *stream, UINT32 font_index, UINT32 tag, const void** table_data, void** table_context, UINT32 *table_size, BOOL* found) +HRESULT opentype_get_font_table(IDWriteFontFileStream *stream, DWRITE_FONT_FACE_TYPE type, UINT32 font_index, UINT32 tag, + const void **table_data, void **table_context, UINT32 *table_size, BOOL *found) { - const CHAR *first_data; - void *first_context; HRESULT hr; TTC_SFNT_V1 *font_header = NULL; void *sfnt_context; TT_TableRecord *table_record = NULL; void *table_record_context; + int table_count, table_offset = 0; int i; - int table_count; - int table_offset = 0; - *found = FALSE; + if (found) *found = FALSE; + if (table_size) *table_size = 0; - hr = IDWriteFontFileStream_ReadFileFragment(stream, (const void**)&first_data, 0, 4, &first_context); - if (SUCCEEDED(hr)) - { - if (DWRITE_MAKE_OPENTYPE_TAG(first_data[0], first_data[1], first_data[2], first_data[3]) == MS_TTCF_TAG) - { - const TTC_Header_V1 *ttc_header; - void * ttc_context; - hr = IDWriteFontFileStream_ReadFileFragment(stream, (const void**)&ttc_header, 0, sizeof(*ttc_header), &ttc_context); - if (SUCCEEDED(hr)) - { - table_offset = GET_BE_DWORD(ttc_header->OffsetTable[0]); - if (font_index >= GET_BE_DWORD(ttc_header->numFonts)) - hr = E_INVALIDARG; - else - hr = IDWriteFontFileStream_ReadFileFragment(stream, (const void**)&font_header, table_offset, sizeof(*font_header), &sfnt_context); - IDWriteFontFileStream_ReleaseFileFragment(stream, ttc_context); - } - } - else - { - if (font_index > 0) + if (type == DWRITE_FONT_FACE_TYPE_TRUETYPE_COLLECTION) { + const TTC_Header_V1 *ttc_header; + void * ttc_context; + hr = IDWriteFontFileStream_ReadFileFragment(stream, (const void**)&ttc_header, 0, sizeof(*ttc_header), &ttc_context); + if (SUCCEEDED(hr)) { + table_offset = GET_BE_DWORD(ttc_header->OffsetTable[0]); + if (font_index >= GET_BE_DWORD(ttc_header->numFonts)) hr = E_INVALIDARG; else - hr = IDWriteFontFileStream_ReadFileFragment(stream, (const void**)&font_header, 0, sizeof(*font_header), &sfnt_context); + hr = IDWriteFontFileStream_ReadFileFragment(stream, (const void**)&font_header, table_offset, sizeof(*font_header), &sfnt_context); + IDWriteFontFileStream_ReleaseFileFragment(stream, ttc_context); } - IDWriteFontFileStream_ReleaseFileFragment(stream, first_context); } + else + hr = IDWriteFontFileStream_ReadFileFragment(stream, (const void**)&font_header, 0, sizeof(*font_header), &sfnt_context); + if (FAILED(hr)) return hr; @@ -284,8 +654,8 @@ int length = GET_BE_DWORD(table_record->length); IDWriteFontFileStream_ReleaseFileFragment(stream, table_record_context); - *found = TRUE; - *table_size = length; + if (found) *found = TRUE; + if (table_size) *table_size = length; hr = IDWriteFontFileStream_ReadFileFragment(stream, table_data, offset, length, table_context); } @@ -308,7 +678,7 @@ return 0; } -static void CMAP4_GetGlyphIndex(CMAP_SegmentMapping_0* format, DWORD utf32c, LPWORD pgi) +static void CMAP4_GetGlyphIndex(CMAP_SegmentMapping_0* format, UINT32 utf32c, UINT16 *pgi) { WORD *startCode; SHORT *idDelta; @@ -347,9 +717,9 @@ } } -static void CMAP12_GetGlyphIndex(CMAP_SegmentedCoverage* format, DWORD utf32c, LPWORD pgi) +static void CMAP12_GetGlyphIndex(CMAP_SegmentedCoverage* format, UINT32 utf32c, UINT16 *pgi) { - CMAP_SegmentedCoverage_group *group = NULL; + CMAP_SegmentedCoverage_group *group; group = bsearch(&utf32c, format->groups, GET_BE_DWORD(format->nGroups), sizeof(CMAP_SegmentedCoverage_group), compare_group); @@ -361,17 +731,12 @@ } } -VOID OpenType_CMAP_GetGlyphIndex(LPVOID data, DWORD utf32c, LPWORD pgi, DWORD flags) +void opentype_cmap_get_glyphindex(void *data, UINT32 utf32c, UINT16 *pgi) { + CMAP_Header *CMAP_Table = data; int i; - CMAP_Header *CMAP_Table = NULL; - if (flags & GGI_MARK_NONEXISTING_GLYPHS) - *pgi = 0xffff; - else - *pgi = 0; - - CMAP_Table = data; + *pgi = 0; for (i = 0; i < GET_BE_WORD(CMAP_Table->numTables); i++) { @@ -383,65 +748,376 @@ table = (WORD*)(((BYTE*)CMAP_Table) + GET_BE_DWORD(CMAP_Table->tables[i].offset)); type = GET_BE_WORD(*table); - TRACE("Type %i\n", type); - /* Break when we find a handled type */ - switch(type) + TRACE("table type %i\n", type); + + switch (type) { - case 4: + case OPENTYPE_CMAP_TABLE_SEGMENT_MAPPING: CMAP4_GetGlyphIndex((CMAP_SegmentMapping_0*) table, utf32c, pgi); break; - case 12: + case OPENTYPE_CMAP_TABLE_SEGMENTED_COVERAGE: CMAP12_GetGlyphIndex((CMAP_SegmentedCoverage*) table, utf32c, pgi); break; default: - TRACE("Type %i unhandled.\n", type); + TRACE("table type %i unhandled.\n", type); + } + + if (*pgi) return; + } +} + +static UINT32 opentype_cmap_get_unicode_ranges_count(const CMAP_Header *CMAP_Table) +{ + UINT32 count = 0; + int i; + + for (i = 0; i < GET_BE_WORD(CMAP_Table->numTables); i++) { + WORD type; + WORD *table; + + if (GET_BE_WORD(CMAP_Table->tables[i].platformID) != 3) + continue; + + table = (WORD*)(((BYTE*)CMAP_Table) + GET_BE_DWORD(CMAP_Table->tables[i].offset)); + type = GET_BE_WORD(*table); + TRACE("table type %i\n", type); + + switch (type) + { + case OPENTYPE_CMAP_TABLE_SEGMENT_MAPPING: + { + CMAP_SegmentMapping_0 *format = (CMAP_SegmentMapping_0*)table; + count += GET_BE_WORD(format->segCountX2)/2; + break; + } + case OPENTYPE_CMAP_TABLE_SEGMENTED_COVERAGE: + { + CMAP_SegmentedCoverage *format = (CMAP_SegmentedCoverage*)table; + count += GET_BE_DWORD(format->nGroups); + break; + } + default: + FIXME("table type %i unhandled.\n", type); + } + } + + return count; +} + +HRESULT opentype_cmap_get_unicode_ranges(void *data, UINT32 max_count, DWRITE_UNICODE_RANGE *ranges, UINT32 *count) +{ + CMAP_Header *CMAP_Table = data; + int i, k = 0; + + if (!CMAP_Table) + return E_FAIL; + + *count = opentype_cmap_get_unicode_ranges_count(CMAP_Table); + + for (i = 0; i < GET_BE_WORD(CMAP_Table->numTables) && k < max_count; i++) + { + WORD type; + WORD *table; + int j; + + if (GET_BE_WORD(CMAP_Table->tables[i].platformID) != 3) + continue; + + table = (WORD*)(((BYTE*)CMAP_Table) + GET_BE_DWORD(CMAP_Table->tables[i].offset)); + type = GET_BE_WORD(*table); + TRACE("table type %i\n", type); + + switch (type) + { + case OPENTYPE_CMAP_TABLE_SEGMENT_MAPPING: + { + CMAP_SegmentMapping_0 *format = (CMAP_SegmentMapping_0*)table; + UINT16 segment_count = GET_BE_WORD(format->segCountX2)/2; + UINT16 *startCode = (WORD*)((BYTE*)format + sizeof(CMAP_SegmentMapping_0) + (sizeof(WORD) * segment_count)); + + for (j = 0; j < segment_count && GET_BE_WORD(format->endCode[j]) < 0xffff && k < max_count; j++, k++) { + ranges[k].first = GET_BE_WORD(startCode[j]); + ranges[k].last = GET_BE_WORD(format->endCode[j]); + } + break; + } + case OPENTYPE_CMAP_TABLE_SEGMENTED_COVERAGE: + { + CMAP_SegmentedCoverage *format = (CMAP_SegmentedCoverage*)table; + for (j = 0; j < GET_BE_DWORD(format->nGroups) && k < max_count; j++, k++) { + ranges[k].first = GET_BE_DWORD(format->groups[j].startCharCode); + ranges[k].last = GET_BE_DWORD(format->groups[j].endCharCode); + } + break; + } + default: + FIXME("table type %i unhandled.\n", type); } } + + return *count > max_count ? E_NOT_SUFFICIENT_BUFFER : S_OK; } -VOID get_font_properties(LPCVOID os2, LPCVOID head, LPCVOID post, DWRITE_FONT_METRICS *metrics, DWRITE_FONT_STRETCH *stretch, DWRITE_FONT_WEIGHT *weight, DWRITE_FONT_STYLE *style) +void opentype_get_font_metrics(const void *os2, const void *head, const void *post, DWRITE_FONT_METRICS1 *metrics) { TT_OS2_V2 *tt_os2 = (TT_OS2_V2*)os2; TT_HEAD *tt_head = (TT_HEAD*)head; TT_POST *tt_post = (TT_POST*)post; + memset(metrics, 0, sizeof(*metrics)); + + if (tt_os2) { + metrics->ascent = GET_BE_WORD(tt_os2->sTypoAscender); + metrics->descent = GET_BE_WORD(tt_os2->sTypoDescender); + metrics->lineGap = GET_BE_WORD(tt_os2->sTypoLineGap); + metrics->capHeight = GET_BE_WORD(tt_os2->sCapHeight); + metrics->xHeight = GET_BE_WORD(tt_os2->sxHeight); + metrics->strikethroughPosition = GET_BE_WORD(tt_os2->yStrikeoutPosition); + metrics->strikethroughThickness = GET_BE_WORD(tt_os2->yStrikeoutSize); + metrics->subscriptPositionX = GET_BE_WORD(tt_os2->ySubscriptXOffset); + /* Y offset is stored as positive offset below baseline */ + metrics->subscriptPositionY = -GET_BE_WORD(tt_os2->ySubscriptYOffset); + metrics->subscriptSizeX = GET_BE_WORD(tt_os2->ySubscriptXSize); + metrics->subscriptSizeY = GET_BE_WORD(tt_os2->ySubscriptYSize); + metrics->superscriptPositionX = GET_BE_WORD(tt_os2->ySuperscriptXOffset); + metrics->superscriptPositionY = GET_BE_WORD(tt_os2->ySuperscriptYOffset); + metrics->superscriptSizeX = GET_BE_WORD(tt_os2->ySuperscriptXSize); + metrics->superscriptSizeY = GET_BE_WORD(tt_os2->ySuperscriptYSize); + } + + if (tt_head) { + metrics->designUnitsPerEm = GET_BE_WORD(tt_head->unitsPerEm); + metrics->glyphBoxLeft = GET_BE_WORD(tt_head->xMin); + metrics->glyphBoxTop = GET_BE_WORD(tt_head->yMax); + metrics->glyphBoxRight = GET_BE_WORD(tt_head->xMax); + metrics->glyphBoxBottom = GET_BE_WORD(tt_head->yMin); + } + + if (tt_post) { + metrics->underlinePosition = GET_BE_WORD(tt_post->underlinePosition); + metrics->underlineThickness = GET_BE_WORD(tt_post->underlineThickness); + } +} + +void opentype_get_font_properties(const void *os2, const void *head, DWRITE_FONT_STRETCH *stretch, DWRITE_FONT_WEIGHT *weight, DWRITE_FONT_STYLE *style) +{ + TT_OS2_V2 *tt_os2 = (TT_OS2_V2*)os2; + TT_HEAD *tt_head = (TT_HEAD*)head; + /* default stretch, weight and style to normal */ *stretch = DWRITE_FONT_STRETCH_NORMAL; *weight = DWRITE_FONT_WEIGHT_NORMAL; *style = DWRITE_FONT_STYLE_NORMAL; - memset(metrics, 0, sizeof(*metrics)); - /* DWRITE_FONT_STRETCH enumeration values directly match font data values */ - if (tt_os2) - { + if (tt_os2) { if (GET_BE_WORD(tt_os2->usWidthClass) <= DWRITE_FONT_STRETCH_ULTRA_EXPANDED) *stretch = GET_BE_WORD(tt_os2->usWidthClass); *weight = GET_BE_WORD(tt_os2->usWeightClass); TRACE("stretch=%d, weight=%d\n", *stretch, *weight); - - metrics->ascent = GET_BE_WORD(tt_os2->sTypoAscender); - metrics->descent = GET_BE_WORD(tt_os2->sTypoDescender); - metrics->lineGap = GET_BE_WORD(tt_os2->sTypoLineGap); - metrics->capHeight = GET_BE_WORD(tt_os2->sCapHeight); - metrics->xHeight = GET_BE_WORD(tt_os2->sxHeight); - metrics->strikethroughPosition = GET_BE_WORD(tt_os2->yStrikeoutPosition); - metrics->strikethroughThickness = GET_BE_WORD(tt_os2->yStrikeoutSize); } - if (tt_head) - { + if (tt_head) { USHORT macStyle = GET_BE_WORD(tt_head->macStyle); - metrics->designUnitsPerEm = GET_BE_WORD(tt_head->unitsPerEm); if (macStyle & 0x0002) *style = DWRITE_FONT_STYLE_ITALIC; + } +} +static UINT get_name_record_codepage(enum OPENTYPE_PLATFORM_ID platform, USHORT encoding) +{ + UINT codepage = 0; + + switch (platform) { + case OPENTYPE_PLATFORM_MAC: + switch (encoding) + { + case TT_NAME_MAC_ENCODING_ROMAN: + codepage = 10000; + break; + case TT_NAME_MAC_ENCODING_JAPANESE: + codepage = 10001; + break; + case TT_NAME_MAC_ENCODING_TRAD_CHINESE: + codepage = 10002; + break; + case TT_NAME_MAC_ENCODING_KOREAN: + codepage = 10003; + break; + case TT_NAME_MAC_ENCODING_ARABIC: + codepage = 10004; + break; + case TT_NAME_MAC_ENCODING_HEBREW: + codepage = 10005; + break; + case TT_NAME_MAC_ENCODING_GREEK: + codepage = 10006; + break; + case TT_NAME_MAC_ENCODING_RUSSIAN: + codepage = 10007; + break; + case TT_NAME_MAC_ENCODING_SIMPL_CHINESE: + codepage = 10008; + break; + case TT_NAME_MAC_ENCODING_THAI: + codepage = 10021; + break; + default: + FIXME("encoding %u not handled, platform %d.\n", encoding, platform); + break; + } + break; + case OPENTYPE_PLATFORM_WIN: + switch (encoding) + { + case TT_NAME_WINDOWS_ENCODING_SYMBOL: + case TT_NAME_WINDOWS_ENCODING_UCS2: + break; + case TT_NAME_WINDOWS_ENCODING_SJIS: + codepage = 932; + break; + case TT_NAME_WINDOWS_ENCODING_PRC: + codepage = 936; + break; + case TT_NAME_WINDOWS_ENCODING_BIG5: + codepage = 950; + break; + case TT_NAME_WINDOWS_ENCODING_WANSUNG: + codepage = 20949; + break; + case TT_NAME_WINDOWS_ENCODING_JOHAB: + codepage = 1361; + break; + default: + FIXME("encoding %u not handled, platform %d.\n", encoding, platform); + break; + } + break; + default: + FIXME("unknown platform %d\n", platform); } - if (tt_post) + return codepage; +} + +static void get_name_record_locale(enum OPENTYPE_PLATFORM_ID platform, USHORT lang_id, WCHAR *locale, USHORT locale_len) +{ + static const WCHAR enusW[] = {'e','n','-','U','S',0}; + + switch (platform) { + case OPENTYPE_PLATFORM_MAC: { - metrics->underlinePosition = GET_BE_WORD(tt_post->underlinePosition); - metrics->underlineThickness = GET_BE_WORD(tt_post->underlineThickness); + const char *locale_name = NULL; + + if (lang_id > TT_NAME_MAC_LANGID_AZER_ROMAN) + ERR("invalid mac lang id %d\n", lang_id); + else if (!name_mac_langid_to_locale[lang_id][0]) + FIXME("failed to map mac lang id %d to locale name\n", lang_id); + else + locale_name = name_mac_langid_to_locale[lang_id]; + + if (locale_name) + MultiByteToWideChar(CP_ACP, 0, name_mac_langid_to_locale[lang_id], -1, locale, locale_len); + else + strcpyW(locale, enusW); + break; + } + case OPENTYPE_PLATFORM_WIN: + if (!LCIDToLocaleName(MAKELCID(lang_id, SORT_DEFAULT), locale, locale_len, 0)) { + FIXME("failed to get locale name for lcid=0x%08x\n", MAKELCID(lang_id, SORT_DEFAULT)); + strcpyW(locale, enusW); + } + break; + default: + FIXME("unknown platform %d\n", platform); } } + +HRESULT opentype_get_font_strings_from_id(const void *table_data, DWRITE_INFORMATIONAL_STRING_ID id, IDWriteLocalizedStrings **strings) +{ + const TT_NAME_V0 *header; + BYTE *storage_area = 0; + USHORT count = 0; + UINT16 name_id; + BOOL exists; + HRESULT hr; + int i; + + if (!table_data) + return E_FAIL; + + hr = create_localizedstrings(strings); + if (FAILED(hr)) return hr; + + header = table_data; + storage_area = (LPBYTE)table_data + GET_BE_WORD(header->stringOffset); + count = GET_BE_WORD(header->count); + + name_id = dwriteid_to_opentypeid[id]; + + exists = FALSE; + for (i = 0; i < count; i++) { + const TT_NameRecord *record = &header->nameRecord[i]; + USHORT lang_id, length, offset, encoding, platform; + + if (GET_BE_WORD(record->nameID) != name_id) + continue; + + exists = TRUE; + + /* Right now only accept unicode and windows encoded fonts */ + platform = GET_BE_WORD(record->platformID); + if (platform != OPENTYPE_PLATFORM_UNICODE && + platform != OPENTYPE_PLATFORM_MAC && + platform != OPENTYPE_PLATFORM_WIN) + { + FIXME("platform %i not supported\n", platform); + continue; + } + + lang_id = GET_BE_WORD(record->languageID); + length = GET_BE_WORD(record->length); + offset = GET_BE_WORD(record->offset); + encoding = GET_BE_WORD(record->encodingID); + + if (lang_id < 0x8000) { + WCHAR locale[LOCALE_NAME_MAX_LENGTH]; + WCHAR *name_string; + UINT codepage; + + codepage = get_name_record_codepage(platform, encoding); + get_name_record_locale(platform, lang_id, locale, sizeof(locale)/sizeof(WCHAR)); + + if (codepage) { + DWORD len = MultiByteToWideChar(codepage, 0, (LPSTR)(storage_area + offset), length, NULL, 0); + name_string = heap_alloc(sizeof(WCHAR) * (len+1)); + MultiByteToWideChar(codepage, 0, (LPSTR)(storage_area + offset), length, name_string, len); + name_string[len] = 0; + } + else { + int i; + + length /= sizeof(WCHAR); + name_string = heap_strdupnW((LPWSTR)(storage_area + offset), length); + for (i = 0; i < length; i++) + name_string[i] = GET_BE_WORD(name_string[i]); + } + + TRACE("string %s for locale %s found\n", debugstr_w(name_string), debugstr_w(locale)); + add_localizedstring(*strings, locale, name_string); + heap_free(name_string); + } + else { + FIXME("handle NAME format 1"); + continue; + } + } + + if (!exists) { + IDWriteLocalizedStrings_Release(*strings); + *strings = NULL; + } + + return hr; +} diff -Nru wine1.7-1.7.28/dlls/dwrite/shape.c wine1.7-1.7.31/dlls/dwrite/shape.c --- wine1.7-1.7.28/dlls/dwrite/shape.c 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/shape.c 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,175 @@ +/* + * Glyph shaping support + * + * Copyright 2010 Aric Stewart for CodeWeavers + * Copyright 2014 Nikolay Sivov 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 + */ + +#define COBJMACROS + +#include "dwrite_private.h" + +WINE_DEFAULT_DEBUG_CHANNEL(dwrite); + +struct scriptshaping_cache +{ + IDWriteFontFace *fontface; +}; + +HRESULT create_scriptshaping_cache(IDWriteFontFace *fontface, struct scriptshaping_cache **cache) +{ + struct scriptshaping_cache *ret; + + ret = heap_alloc(sizeof(*ret)); + if (!ret) + return E_OUTOFMEMORY; + + ret->fontface = fontface; + IDWriteFontFace_AddRef(fontface); + + *cache = ret; + + return S_OK; +} + +void release_scriptshaping_cache(struct scriptshaping_cache *cache) +{ + if (!cache) + return; + IDWriteFontFace_Release(cache->fontface); + heap_free(cache); +} + +static void shape_update_clusters_from_glyphprop(UINT32 glyphcount, UINT32 text_len, UINT16 *clustermap, DWRITE_SHAPING_GLYPH_PROPERTIES *glyph_props) +{ + UINT32 i; + + for (i = 0; i < glyphcount; i++) { + if (!glyph_props[i].isClusterStart) { + UINT32 j; + + for (j = 0; j < text_len; j++) { + if (clustermap[j] == i) { + int k = j; + while (k >= 0 && k < text_len && !glyph_props[clustermap[k]].isClusterStart) + k--; + + if (k >= 0 && k < text_len && glyph_props[clustermap[k]].isClusterStart) + clustermap[j] = clustermap[k]; + } + } + } + } +} + +static int compare_clustersearch(const void *a, const void* b) +{ + UINT16 target = *(UINT16*)a; + UINT16 index = *(UINT16*)b; + int ret = 0; + + if (target > index) + ret = 1; + else if (target < index) + ret = -1; + + return ret; +} + +/* Maps given glyph position in glyph indices array to text index this glyph represents. + Lowest possible index is returned. + + clustermap [I] Text index to index in glyph indices array map + len [I] Clustermap size + target [I] Index in glyph indices array to map + */ +static INT32 map_glyph_to_text_pos(const UINT16 *clustermap, UINT32 len, UINT16 target) +{ + UINT16 *ptr; + INT32 k; + + ptr = bsearch(&target, clustermap, len, sizeof(UINT16), compare_clustersearch); + if (!ptr) + return -1; + + /* get to the beginning */ + for (k = (ptr - clustermap) - 1; k >= 0 && clustermap[k] == target; k--) + ; + k++; + + return k; +} + +static HRESULT default_set_text_glyphs_props(struct scriptshaping_context *context, UINT16 *clustermap, UINT16 *glyph_indices, + UINT32 glyphcount, DWRITE_SHAPING_TEXT_PROPERTIES *text_props, DWRITE_SHAPING_GLYPH_PROPERTIES *glyph_props) +{ + UINT32 i; + + for (i = 0; i < glyphcount; i++) { + UINT32 char_index[20]; + UINT32 char_count = 0; + INT32 k; + + k = map_glyph_to_text_pos(clustermap, context->length, i); + if (k >= 0) { + for (; k < context->length && clustermap[k] == i; k++) + char_index[char_count++] = k; + } + + if (char_count == 0) + continue; + + if (char_count == 1 && isspaceW(context->text[char_index[0]])) { + glyph_props[i].justification = SCRIPT_JUSTIFY_BLANK; + text_props[char_index[0]].isShapedAlone = context->text[char_index[0]] == ' '; + } + else + glyph_props[i].justification = SCRIPT_JUSTIFY_CHARACTER; + } + + /* FIXME: update properties using GDEF table */ + shape_update_clusters_from_glyphprop(glyphcount, context->length, clustermap, glyph_props); + + return S_OK; +} + +static HRESULT latn_set_text_glyphs_props(struct scriptshaping_context *context, UINT16 *clustermap, UINT16 *glyph_indices, + UINT32 glyphcount, DWRITE_SHAPING_TEXT_PROPERTIES *text_props, DWRITE_SHAPING_GLYPH_PROPERTIES *glyph_props) +{ + HRESULT hr; + UINT32 i; + + hr = default_set_text_glyphs_props(context, clustermap, glyph_indices, glyphcount, text_props, glyph_props); + + for (i = 0; i < glyphcount; i++) + if (glyph_props[i].isZeroWidthSpace) + glyph_props[i].justification = SCRIPT_JUSTIFY_NONE; + + return hr; +} + +const struct scriptshaping_ops latn_shaping_ops = +{ + NULL, + latn_set_text_glyphs_props +}; + +const struct scriptshaping_ops default_shaping_ops = +{ + NULL, + default_set_text_glyphs_props +}; diff -Nru wine1.7-1.7.28/dlls/dwrite/tests/analyzer.c wine1.7-1.7.31/dlls/dwrite/tests/analyzer.c --- wine1.7-1.7.28/dlls/dwrite/tests/analyzer.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/tests/analyzer.c 2014-11-14 13:28:17.000000000 +0000 @@ -392,6 +392,37 @@ static IDWriteTextAnalysisSource analysissource = { &analysissourcevtbl }; +static IDWriteFontFace *create_fontface(void) +{ + static const WCHAR tahomaW[] = {'T','a','h','o','m','a',0}; + IDWriteGdiInterop *interop; + IDWriteFontFace *fontface; + IDWriteFont *font; + LOGFONTW logfont; + HRESULT hr; + + hr = IDWriteFactory_GetGdiInterop(factory, &interop); + ok(hr == S_OK, "got 0x%08x\n", hr); + + memset(&logfont, 0, sizeof(logfont)); + logfont.lfHeight = 12; + logfont.lfWidth = 12; + logfont.lfWeight = FW_NORMAL; + logfont.lfItalic = 1; + lstrcpyW(logfont.lfFaceName, tahomaW); + + hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFont_CreateFontFace(font, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + + IDWriteFont_Release(font); + IDWriteGdiInterop_Release(interop); + + return fontface; +} + struct sa_test { const WCHAR string[50]; int item_count; @@ -966,15 +997,11 @@ static void test_GetTextComplexity(void) { - static const WCHAR tahomaW[] = {'T','a','h','o','m','a',0}; static const WCHAR textW[] = {'A','B','C',0}; IDWriteTextAnalyzer1 *analyzer1; IDWriteTextAnalyzer *analyzer; - IDWriteGdiInterop *interop; IDWriteFontFace *fontface; UINT16 indices[10]; - IDWriteFont *font; - LOGFONTW logfont; BOOL simple; HRESULT hr; UINT32 len; @@ -1014,22 +1041,7 @@ ok(simple == FALSE, "got %d\n", simple); ok(indices[0] == 1, "got %d\n", indices[0]); - /* so font face is required, create one */ - hr = IDWriteFactory_GetGdiInterop(factory, &interop); - ok(hr == S_OK, "got 0x%08x\n", hr); - - memset(&logfont, 0, sizeof(logfont)); - logfont.lfHeight = 12; - logfont.lfWidth = 12; - logfont.lfWeight = FW_NORMAL; - logfont.lfItalic = 1; - lstrcpyW(logfont.lfFaceName, tahomaW); - - hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); - ok(hr == S_OK, "got 0x%08x\n", hr); - - hr = IDWriteFont_CreateFontFace(font, &fontface); - ok(hr == S_OK, "got 0x%08x\n", hr); + fontface = create_fontface(); for (i = 0; i < sizeof(textcomplexity_tests)/sizeof(struct textcomplexity_test); i++) { const struct textcomplexity_test *ptr = &textcomplexity_tests[i]; @@ -1046,9 +1058,7 @@ ok(indices[0] == 0, "%d: got %d\n", i, indices[0]); } - IDWriteFont_Release(font); IDWriteFontFace_Release(fontface); - IDWriteGdiInterop_Release(interop); IDWriteTextAnalyzer1_Release(analyzer1); } @@ -1086,6 +1096,84 @@ IDWriteNumberSubstitution_Release(substitution); } +static void test_GetGlyphs(void) +{ + static const WCHAR test1W[] = {'<','B',' ','C',0}; + static const WCHAR test2W[] = {'<','B','\t','C',0}; + DWRITE_SHAPING_GLYPH_PROPERTIES shapingprops[20]; + DWRITE_SHAPING_TEXT_PROPERTIES props[20]; + UINT32 maxglyphcount, actual_count; + IDWriteTextAnalyzer *analyzer; + IDWriteFontFace *fontface; + DWRITE_SCRIPT_ANALYSIS sa; + UINT16 clustermap[10]; + UINT16 glyphs1[10]; + UINT16 glyphs2[10]; + HRESULT hr; + + hr = IDWriteFactory_CreateTextAnalyzer(factory, &analyzer); + ok(hr == S_OK, "got 0x%08x\n", hr); + + fontface = create_fontface(); + + maxglyphcount = 1; + sa.script = 0; + sa.shapes = DWRITE_SCRIPT_SHAPES_DEFAULT; + hr = IDWriteTextAnalyzer_GetGlyphs(analyzer, test1W, lstrlenW(test1W), fontface, FALSE, FALSE, &sa, NULL, + NULL, NULL, NULL, 0, maxglyphcount, clustermap, props, glyphs1, shapingprops, &actual_count); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "got 0x%08x\n", hr); + +if (0) { + /* NULL fontface - crashes on Windows */ + hr = IDWriteTextAnalyzer_GetGlyphs(analyzer, test1W, lstrlenW(test1W), NULL, FALSE, FALSE, &sa, NULL, + NULL, NULL, NULL, 0, maxglyphcount, clustermap, props, glyphs1, shapingprops, &actual_count); +} + + /* invalid script id */ + maxglyphcount = 10; + actual_count = 0; + sa.script = 999; + sa.shapes = DWRITE_SCRIPT_SHAPES_DEFAULT; + hr = IDWriteTextAnalyzer_GetGlyphs(analyzer, test1W, lstrlenW(test1W), fontface, FALSE, FALSE, &sa, NULL, + NULL, NULL, NULL, 0, maxglyphcount, clustermap, props, glyphs1, shapingprops, &actual_count); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(actual_count == 4, "got %d\n", actual_count); + ok(sa.script == 999, "got %u\n", sa.script); + + /* no '\t' -> ' ' replacement */ + maxglyphcount = 10; + actual_count = 0; + hr = IDWriteTextAnalyzer_GetGlyphs(analyzer, test1W, lstrlenW(test1W), fontface, FALSE, FALSE, &sa, NULL, + NULL, NULL, NULL, 0, maxglyphcount, clustermap, props, glyphs1, shapingprops, &actual_count); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(actual_count == 4, "got %d\n", actual_count); + + actual_count = 0; + hr = IDWriteTextAnalyzer_GetGlyphs(analyzer, test2W, lstrlenW(test2W), fontface, FALSE, FALSE, &sa, NULL, + NULL, NULL, NULL, 0, maxglyphcount, clustermap, props, glyphs2, shapingprops, &actual_count); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(actual_count == 4, "got %d\n", actual_count); + ok(glyphs1[2] != glyphs2[2], "got %d\n", glyphs1[2]); + + /* check that mirroring works */ + maxglyphcount = 10; + actual_count = 0; + hr = IDWriteTextAnalyzer_GetGlyphs(analyzer, test1W, lstrlenW(test1W), fontface, FALSE, FALSE, &sa, NULL, + NULL, NULL, NULL, 0, maxglyphcount, clustermap, props, glyphs1, shapingprops, &actual_count); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(actual_count == 4, "got %d\n", actual_count); + + actual_count = 0; + hr = IDWriteTextAnalyzer_GetGlyphs(analyzer, test1W, lstrlenW(test1W), fontface, FALSE, TRUE, &sa, NULL, + NULL, NULL, NULL, 0, maxglyphcount, clustermap, props, glyphs2, shapingprops, &actual_count); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(actual_count == 4, "got %d\n", actual_count); + ok(glyphs1[0] != glyphs2[0], "got %d\n", glyphs1[0]); + + IDWriteTextAnalyzer_Release(analyzer); + IDWriteFontFace_Release(fontface); +} + START_TEST(analyzer) { HRESULT hr; @@ -1105,6 +1193,7 @@ test_AnalyzeLineBreakpoints(); test_GetScriptProperties(); test_GetTextComplexity(); + test_GetGlyphs(); test_numbersubstitution(); IDWriteFactory_Release(factory); diff -Nru wine1.7-1.7.28/dlls/dwrite/tests/font.c wine1.7-1.7.31/dlls/dwrite/tests/font.c --- wine1.7-1.7.28/dlls/dwrite/tests/font.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/tests/font.c 2014-11-14 13:28:17.000000000 +0000 @@ -1,7 +1,8 @@ /* * Font related tests * - * Copyright 2012 Nikolay Sivov for CodeWeavers + * Copyright 2012, 2014 Nikolay Sivov for CodeWeavers + * Copyright 2014 Aric Stewart for CodeWeavers * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,26 +22,196 @@ #define COBJMACROS #include "windows.h" -#include "dwrite.h" +#include "dwrite_1.h" #include "wine/test.h" +#define MS_MAKE_TAG(ch0, ch1, ch2, ch3) \ + ((DWORD)(BYTE)(ch0) | ((DWORD)(BYTE)(ch1) << 8) | \ + ((DWORD)(BYTE)(ch2) << 16) | ((DWORD)(BYTE)(ch3) << 24)) + +#define MS_CMAP_TAG MS_MAKE_TAG('c','m','a','p') + #define EXPECT_HR(hr,hr_exp) \ ok(hr == hr_exp, "got 0x%08x, expected 0x%08x\n", hr, hr_exp) #define EXPECT_REF(obj,ref) _expect_ref((IUnknown*)obj, ref, __LINE__) static void _expect_ref(IUnknown* obj, ULONG ref, int line) { - ULONG rc = IUnknown_AddRef(obj); - IUnknown_Release(obj); - ok_(__FILE__,line)(rc-1 == ref, "expected refcount %d, got %d\n", ref, rc-1); + ULONG rc; + IUnknown_AddRef(obj); + rc = IUnknown_Release(obj); + ok_(__FILE__,line)(rc == ref, "expected refcount %d, got %d\n", ref, rc); +} + +static inline void *heap_alloc(size_t len) +{ + return HeapAlloc(GetProcessHeap(), 0, len); } -static IDWriteFactory *factory; +static inline BOOL heap_free(void *mem) +{ + return HeapFree(GetProcessHeap(), 0, mem); +} +static const WCHAR test_fontfile[] = {'w','i','n','e','_','t','e','s','t','_','f','o','n','t','.','t','t','f',0}; static const WCHAR tahomaW[] = {'T','a','h','o','m','a',0}; static const WCHAR blahW[] = {'B','l','a','h','!',0}; +static IDWriteFactory *create_factory(void) +{ + IDWriteFactory *factory; + HRESULT hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_ISOLATED, &IID_IDWriteFactory, (IUnknown**)&factory); + ok(hr == S_OK, "got 0x%08x\n", hr); + return factory; +} + +struct test_fontenumerator +{ + IDWriteFontFileEnumerator IDWriteFontFileEnumerator_iface; + LONG ref; + + DWORD index; + IDWriteFontFile *font_file; +}; + +static inline struct test_fontenumerator *impl_from_IDWriteFontFileEnumerator(IDWriteFontFileEnumerator* iface) +{ + return CONTAINING_RECORD(iface, struct test_fontenumerator, IDWriteFontFileEnumerator_iface); +} + +static HRESULT WINAPI singlefontfileenumerator_QueryInterface(IDWriteFontFileEnumerator *iface, REFIID riid, void **obj) +{ + if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IDWriteFontFileEnumerator)) + { + *obj = iface; + IDWriteFontFileEnumerator_AddRef(iface); + return S_OK; + } + return E_NOINTERFACE; +} + +static ULONG WINAPI singlefontfileenumerator_AddRef(IDWriteFontFileEnumerator *iface) +{ + struct test_fontenumerator *This = impl_from_IDWriteFontFileEnumerator(iface); + return InterlockedIncrement(&This->ref); +} + +static ULONG WINAPI singlefontfileenumerator_Release(IDWriteFontFileEnumerator *iface) +{ + struct test_fontenumerator *This = impl_from_IDWriteFontFileEnumerator(iface); + ULONG ref = InterlockedDecrement(&This->ref); + if (!ref) { + IDWriteFontFile_Release(This->font_file); + heap_free(This); + } + return ref; +} + +static HRESULT WINAPI singlefontfileenumerator_GetCurrentFontFile(IDWriteFontFileEnumerator *iface, IDWriteFontFile **font_file) +{ + struct test_fontenumerator *This = impl_from_IDWriteFontFileEnumerator(iface); + IDWriteFontFile_AddRef(This->font_file); + *font_file = This->font_file; + return S_OK; +} + +static HRESULT WINAPI singlefontfileenumerator_MoveNext(IDWriteFontFileEnumerator *iface, BOOL *current) +{ + struct test_fontenumerator *This = impl_from_IDWriteFontFileEnumerator(iface); + + if (This->index > 1) { + *current = FALSE; + return S_OK; + } + + This->index++; + *current = TRUE; + return S_OK; +} + +static const struct IDWriteFontFileEnumeratorVtbl singlefontfileenumeratorvtbl = +{ + singlefontfileenumerator_QueryInterface, + singlefontfileenumerator_AddRef, + singlefontfileenumerator_Release, + singlefontfileenumerator_MoveNext, + singlefontfileenumerator_GetCurrentFontFile +}; + +static HRESULT create_enumerator(IDWriteFontFile *font_file, IDWriteFontFileEnumerator **ret) +{ + struct test_fontenumerator *enumerator; + + enumerator = heap_alloc(sizeof(struct test_fontenumerator)); + if (!enumerator) + return E_OUTOFMEMORY; + + enumerator->IDWriteFontFileEnumerator_iface.lpVtbl = &singlefontfileenumeratorvtbl; + enumerator->ref = 1; + enumerator->index = 0; + enumerator->font_file = font_file; + IDWriteFontFile_AddRef(font_file); + + *ret = &enumerator->IDWriteFontFileEnumerator_iface; + return S_OK; +} + +struct test_fontcollectionloader +{ + IDWriteFontCollectionLoader IDWriteFontFileCollectionLoader_iface; + IDWriteFontFileLoader *loader; +}; + +static inline struct test_fontcollectionloader *impl_from_IDWriteFontFileCollectionLoader(IDWriteFontCollectionLoader* iface) +{ + return CONTAINING_RECORD(iface, struct test_fontcollectionloader, IDWriteFontFileCollectionLoader_iface); +} + +static HRESULT WINAPI resourcecollectionloader_QueryInterface(IDWriteFontCollectionLoader *iface, REFIID riid, void **obj) +{ + if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IDWriteFontCollectionLoader)) + { + *obj = iface; + IDWriteFontCollectionLoader_AddRef(iface); + return S_OK; + } + return E_NOINTERFACE; +} + +static ULONG WINAPI resourcecollectionloader_AddRef(IDWriteFontCollectionLoader *iface) +{ + return 2; +} + +static ULONG WINAPI resourcecollectionloader_Release(IDWriteFontCollectionLoader *iface) +{ + return 1; +} + +static HRESULT WINAPI resourcecollectionloader_CreateEnumeratorFromKey(IDWriteFontCollectionLoader *iface, IDWriteFactory *factory, + const void * collectionKey, UINT32 collectionKeySize, IDWriteFontFileEnumerator ** fontFileEnumerator) +{ + struct test_fontcollectionloader *This = impl_from_IDWriteFontFileCollectionLoader(iface); + IDWriteFontFile *font_file; + HRESULT hr; + + IDWriteFactory_CreateCustomFontFileReference(factory, collectionKey, collectionKeySize, This->loader, &font_file); + + hr = create_enumerator(font_file, fontFileEnumerator); + ok(hr == S_OK, "got 0x%08x\n", hr); + + IDWriteFontFile_Release(font_file); + return hr; +} + +static const struct IDWriteFontCollectionLoaderVtbl resourcecollectionloadervtbl = { + resourcecollectionloader_QueryInterface, + resourcecollectionloader_AddRef, + resourcecollectionloader_Release, + resourcecollectionloader_CreateEnumeratorFromKey +}; + /* Here is a functional custom font set of interfaces */ struct test_fontdatastream { @@ -188,6 +359,7 @@ resourcefontfileloader_CreateStreamFromKey }; +static IDWriteFontFileLoader rloader = { &resourcefontfileloadervtbl }; static void test_CreateFontFromLOGFONT(void) { @@ -213,13 +385,17 @@ {960, DWRITE_FONT_WEIGHT_BOLD}, }; OUTLINETEXTMETRICW otm; + IDWriteFactory *factory; HRESULT hr; BOOL ret; HDC hdc; HFONT hfont; + BOOL exists; int i; UINT r; + factory = create_factory(); + hr = IDWriteFactory_GetGdiInterop(factory, &interop); EXPECT_HR(hr, S_OK); @@ -250,6 +426,16 @@ DeleteDC(hdc); DeleteObject(hfont); + exists = TRUE; + hr = IDWriteFont_HasCharacter(font, 0xd800, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(exists == FALSE, "got %d\n", exists); + + exists = FALSE; + hr = IDWriteFont_HasCharacter(font, 0x20, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(exists == TRUE, "got %d\n", exists); + /* now check properties */ weight = IDWriteFont_GetWeight(font); ok(weight == DWRITE_FONT_WEIGHT_NORMAL, "got %d\n", weight); @@ -279,6 +465,7 @@ weight = IDWriteFont_GetWeight(font); ok(weight == weights[i][1], "%d: got %d, expected %d\n", i, weight, weights[i][1]); + IDWriteFont_Release(font); } @@ -289,8 +476,9 @@ logfont.lfWeight = 550; lstrcpyW(logfont.lfFaceName, tahomaW); + font = NULL; hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); - EXPECT_HR(hr, S_OK); + ok(hr == S_OK, "got 0x%08x\n", hr); weight = IDWriteFont_GetWeight(font); ok(weight == DWRITE_FONT_WEIGHT_NORMAL || broken(weight == DWRITE_FONT_WEIGHT_BOLD) /* win7 w/o SP */, @@ -306,12 +494,10 @@ font = (void*)0xdeadbeef; hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); -todo_wine { - EXPECT_HR(hr, DWRITE_E_NOFONT); + ok(hr == DWRITE_E_NOFONT, "got 0x%08x\n", hr); ok(font == NULL, "got %p\n", font); - if(font) IDWriteFont_Release(font); -} + /* Try with name 'Tahoma ' */ memset(&logfont, 0, sizeof(logfont)); logfont.lfHeight = 12; logfont.lfWidth = 12; @@ -320,12 +506,10 @@ font = (void*)0xdeadbeef; hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); -todo_wine { - EXPECT_HR(hr, DWRITE_E_NOFONT); + ok(hr == DWRITE_E_NOFONT, "got 0x%08x\n", hr); ok(font == NULL, "got %p\n", font); - if(font) IDWriteFont_Release(font); -} + /* empty string as a facename */ memset(&logfont, 0, sizeof(logfont)); logfont.lfHeight = 12; logfont.lfWidth = 12; @@ -333,27 +517,29 @@ font = (void*)0xdeadbeef; hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); -todo_wine { - EXPECT_HR(hr, DWRITE_E_NOFONT); + ok(hr == DWRITE_E_NOFONT, "got 0x%08x\n", hr); ok(font == NULL, "got %p\n", font); - if(font) IDWriteFont_Release(font); -} IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); } static void test_CreateBitmapRenderTarget(void) { IDWriteBitmapRenderTarget *target, *target2; IDWriteGdiInterop *interop; + IDWriteFactory *factory; HBITMAP hbm, hbm2; DWRITE_MATRIX m; DIBSECTION ds; HRESULT hr; + FLOAT pdip; SIZE size; HDC hdc; int ret; + factory = create_factory(); + hr = IDWriteFactory_GetGdiInterop(factory, &interop); EXPECT_HR(hr, S_OK); @@ -480,21 +666,46 @@ ok(m.m11 == 1.0 && m.m22 == 1.0 && m.m12 == 0.0 && m.m21 == 0.0, "got %.1f,%.1f,%.1f,%.1f\n", m.m11, m.m22, m.m12, m.m21); ok(m.dx == 0.0 && m.dy == 0.0, "got %.1f,%.1f\n", m.dx, m.dy); + /* pixels per dip */ + pdip = IDWriteBitmapRenderTarget_GetPixelsPerDip(target); + ok(pdip == 1.0, "got %.2f\n", pdip); + + hr = IDWriteBitmapRenderTarget_SetPixelsPerDip(target, 2.0); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteBitmapRenderTarget_SetPixelsPerDip(target, -1.0); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + hr = IDWriteBitmapRenderTarget_SetPixelsPerDip(target, 0.0); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + pdip = IDWriteBitmapRenderTarget_GetPixelsPerDip(target); + ok(pdip == 2.0, "got %.2f\n", pdip); + IDWriteBitmapRenderTarget_Release(target); IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); } static void test_GetFontFamily(void) { + IDWriteFontCollection *collection, *collection2; + IDWriteFontCollection *syscoll; IDWriteFontFamily *family, *family2; IDWriteGdiInterop *interop; - IDWriteFont *font; + IDWriteFont *font, *font2; + IDWriteFactory *factory; LOGFONTW logfont; HRESULT hr; + factory = create_factory(); + hr = IDWriteFactory_GetGdiInterop(factory, &interop); EXPECT_HR(hr, S_OK); + hr = IDWriteFactory_GetSystemFontCollection(factory, &syscoll, FALSE); + ok(hr == S_OK, "got 0x%08x\n", hr); + memset(&logfont, 0, sizeof(logfont)); logfont.lfHeight = 12; logfont.lfWidth = 12; @@ -503,7 +714,11 @@ lstrcpyW(logfont.lfFaceName, tahomaW); hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); - EXPECT_HR(hr, S_OK); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(font2 != font, "got %p, %p\n", font2, font); if (0) /* crashes on native */ hr = IDWriteFont_GetFontFamily(font, NULL); @@ -525,9 +740,29 @@ EXPECT_HR(hr, E_NOINTERFACE); ok(family2 == NULL, "got %p\n", family2); + hr = IDWriteFont_GetFontFamily(font2, &family2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(family2 != family, "got %p, %p\n", family2, family); + + collection = NULL; + hr = IDWriteFontFamily_GetFontCollection(family, &collection); + ok(hr == S_OK, "got 0x%08x\n", hr); + + collection2 = NULL; + hr = IDWriteFontFamily_GetFontCollection(family2, &collection2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(collection == collection2, "got %p, %p\n", collection, collection2); + ok(collection == syscoll, "got %p, %p\n", collection, syscoll); + + IDWriteFontCollection_Release(syscoll); + IDWriteFontCollection_Release(collection2); + IDWriteFontCollection_Release(collection); + IDWriteFontFamily_Release(family2); IDWriteFontFamily_Release(family); IDWriteFont_Release(font); + IDWriteFont_Release(font2); IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); } static void test_GetFamilyNames(void) @@ -535,12 +770,15 @@ IDWriteFontFamily *family; IDWriteLocalizedStrings *names, *names2; IDWriteGdiInterop *interop; + IDWriteFactory *factory; IDWriteFont *font; LOGFONTW logfont; WCHAR buffer[100]; HRESULT hr; UINT32 len; + factory = create_factory(); + hr = IDWriteFactory_GetGdiInterop(factory, &interop); EXPECT_HR(hr, S_OK); @@ -620,16 +858,22 @@ IDWriteFontFamily_Release(family); IDWriteFont_Release(font); IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); } static void test_CreateFontFace(void) { IDWriteFontFace *fontface, *fontface2; + IDWriteFontCollection *collection; IDWriteGdiInterop *interop; - IDWriteFont *font; + IDWriteFont *font, *font2; + IDWriteFontFamily *family; + IDWriteFactory *factory; LOGFONTW logfont; HRESULT hr; + factory = create_factory(); + hr = IDWriteFactory_GetGdiInterop(factory, &interop); EXPECT_HR(hr, S_OK); @@ -640,35 +884,90 @@ logfont.lfItalic = 1; lstrcpyW(logfont.lfFaceName, tahomaW); + font = NULL; hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); ok(hr == S_OK, "got 0x%08x\n", hr); + font2 = NULL; + hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(font != font2, "got %p, %p\n", font, font2); + hr = IDWriteFont_QueryInterface(font, &IID_IDWriteFontFace, (void**)&fontface); ok(hr == E_NOINTERFACE, "got 0x%08x\n", hr); if (0) /* crashes on native */ hr = IDWriteFont_CreateFontFace(font, NULL); + fontface = NULL; hr = IDWriteFont_CreateFontFace(font, &fontface); ok(hr == S_OK, "got 0x%08x\n", hr); + fontface2 = NULL; hr = IDWriteFont_CreateFontFace(font, &fontface2); ok(hr == S_OK, "got 0x%08x\n", hr); ok(fontface == fontface2, "got %p, was %p\n", fontface2, fontface); - /* the fontface refcount is increased here */ + IDWriteFontFace_Release(fontface2); + + fontface2 = NULL; + hr = IDWriteFont_CreateFontFace(font2, &fontface2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(fontface == fontface2, "got %p, was %p\n", fontface2, fontface); + IDWriteFontFace_Release(fontface2); + + IDWriteFont_Release(font2); + IDWriteFont_Release(font); + + hr = IDWriteFontFace_QueryInterface(fontface, &IID_IDWriteFont, (void**)&font); + ok(hr == E_NOINTERFACE || broken(hr == E_NOTIMPL), "got 0x%08x\n", hr); IDWriteFontFace_Release(fontface); + IDWriteGdiInterop_Release(interop); + + /* Create from system collection */ + hr = IDWriteFactory_GetSystemFontCollection(factory, &collection, FALSE); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontCollection_GetFontFamily(collection, 0, &family); + ok(hr == S_OK, "got 0x%08x\n", hr); + + font = NULL; + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_NORMAL, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + font2 = NULL; + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_NORMAL, &font2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(font != font2, "got %p, %p\n", font, font2); + + fontface = NULL; + hr = IDWriteFont_CreateFontFace(font, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + + fontface2 = NULL; + hr = IDWriteFont_CreateFontFace(font2, &fontface2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(fontface == fontface2, "got %p, was %p\n", fontface2, fontface); IDWriteFontFace_Release(fontface); + IDWriteFontFace_Release(fontface2); + IDWriteFont_Release(font2); IDWriteFont_Release(font); - IDWriteGdiInterop_Release(interop); + IDWriteFontFamily_Release(family); + IDWriteFontCollection_Release(collection); + IDWriteFactory_Release(factory); } static void test_GetMetrics(void) { IDWriteGdiInterop *interop; DWRITE_FONT_METRICS metrics; + IDWriteFontFace *fontface; + IDWriteFactory *factory; OUTLINETEXTMETRICW otm; + IDWriteFont1 *font1; IDWriteFont *font; LOGFONTW logfont; HRESULT hr; @@ -676,6 +975,8 @@ HFONT hfont; int ret; + factory = create_factory(); + hr = IDWriteFactory_GetGdiInterop(factory, &interop); EXPECT_HR(hr, S_OK); @@ -717,18 +1018,113 @@ ok(metrics.strikethroughPosition > 0, "strikethroughPosition %d\n", metrics.strikethroughPosition); ok(metrics.strikethroughThickness != 0, "strikethroughThickness %u\n", metrics.strikethroughThickness); + hr = IDWriteFont_CreateFontFace(font, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + + memset(&metrics, 0, sizeof(metrics)); + IDWriteFontFace_GetMetrics(fontface, &metrics); + + ok(metrics.designUnitsPerEm != 0, "designUnitsPerEm %u\n", metrics.designUnitsPerEm); + ok(metrics.ascent != 0, "ascent %u\n", metrics.ascent); + ok(metrics.descent != 0, "descent %u\n", metrics.descent); +todo_wine + ok(metrics.lineGap == 0, "lineGap %d\n", metrics.lineGap); + ok(metrics.capHeight, "capHeight %u\n", metrics.capHeight); + ok(metrics.xHeight != 0, "xHeight %u\n", metrics.xHeight); + ok(metrics.underlinePosition < 0, "underlinePosition %d\n", metrics.underlinePosition); + ok(metrics.underlineThickness != 0, "underlineThickness %u\n", metrics.underlineThickness); + ok(metrics.strikethroughPosition > 0, "strikethroughPosition %d\n", metrics.strikethroughPosition); + ok(metrics.strikethroughThickness != 0, "strikethroughThickness %u\n", metrics.strikethroughThickness); + + hr = IDWriteFont_QueryInterface(font, &IID_IDWriteFont1, (void**)&font1); + if (hr == S_OK) { + DWRITE_FONT_METRICS1 metrics1; + IDWriteFontFace1 *fontface1; + + memset(&metrics1, 0, sizeof(metrics1)); + IDWriteFont1_GetMetrics(font1, &metrics1); + + ok(metrics1.designUnitsPerEm != 0, "designUnitsPerEm %u\n", metrics1.designUnitsPerEm); + ok(metrics1.ascent != 0, "ascent %u\n", metrics1.ascent); + ok(metrics1.descent != 0, "descent %u\n", metrics1.descent); + todo_wine + ok(metrics1.lineGap == 0, "lineGap %d\n", metrics1.lineGap); + ok(metrics1.capHeight, "capHeight %u\n", metrics1.capHeight); + ok(metrics1.xHeight != 0, "xHeight %u\n", metrics1.xHeight); + ok(metrics1.underlinePosition < 0, "underlinePosition %d\n", metrics1.underlinePosition); + ok(metrics1.underlineThickness != 0, "underlineThickness %u\n", metrics1.underlineThickness); + ok(metrics1.strikethroughPosition > 0, "strikethroughPosition %d\n", metrics1.strikethroughPosition); + ok(metrics1.strikethroughThickness != 0, "strikethroughThickness %u\n", metrics1.strikethroughThickness); + ok(metrics1.glyphBoxLeft < 0, "glyphBoxLeft %d\n", metrics1.glyphBoxLeft); + ok(metrics1.glyphBoxTop > 0, "glyphBoxTop %d\n", metrics1.glyphBoxTop); + ok(metrics1.glyphBoxRight > 0, "glyphBoxRight %d\n", metrics1.glyphBoxRight); + ok(metrics1.glyphBoxBottom < 0, "glyphBoxBottom %d\n", metrics1.glyphBoxBottom); + ok(metrics1.subscriptPositionY < 0, "subscriptPositionY %d\n", metrics1.subscriptPositionY); + ok(metrics1.subscriptSizeX > 0, "subscriptSizeX %d\n", metrics1.subscriptSizeX); + ok(metrics1.subscriptSizeY > 0, "subscriptSizeY %d\n", metrics1.subscriptSizeY); + ok(metrics1.superscriptPositionY > 0, "superscriptPositionY %d\n", metrics1.superscriptPositionY); + ok(metrics1.superscriptSizeX > 0, "superscriptSizeX %d\n", metrics1.superscriptSizeX); + ok(metrics1.superscriptSizeY > 0, "superscriptSizeY %d\n", metrics1.superscriptSizeY); + ok(!metrics1.hasTypographicMetrics, "hasTypographicMetrics %d\n", metrics1.hasTypographicMetrics); + + hr = IDWriteFontFace_QueryInterface(fontface, &IID_IDWriteFontFace1, (void**)&fontface1); + ok(hr == S_OK, "got 0x%08x\n", hr); + + memset(&metrics1, 0, sizeof(metrics1)); + IDWriteFontFace1_GetMetrics(fontface1, &metrics1); + + ok(metrics1.designUnitsPerEm != 0, "designUnitsPerEm %u\n", metrics1.designUnitsPerEm); + ok(metrics1.ascent != 0, "ascent %u\n", metrics1.ascent); + ok(metrics1.descent != 0, "descent %u\n", metrics1.descent); + todo_wine + ok(metrics1.lineGap == 0, "lineGap %d\n", metrics1.lineGap); + ok(metrics1.capHeight, "capHeight %u\n", metrics1.capHeight); + ok(metrics1.xHeight != 0, "xHeight %u\n", metrics1.xHeight); + ok(metrics1.underlinePosition < 0, "underlinePosition %d\n", metrics1.underlinePosition); + ok(metrics1.underlineThickness != 0, "underlineThickness %u\n", metrics1.underlineThickness); + ok(metrics1.strikethroughPosition > 0, "strikethroughPosition %d\n", metrics1.strikethroughPosition); + ok(metrics1.strikethroughThickness != 0, "strikethroughThickness %u\n", metrics1.strikethroughThickness); + ok(metrics1.glyphBoxLeft < 0, "glyphBoxLeft %d\n", metrics1.glyphBoxLeft); + ok(metrics1.glyphBoxTop > 0, "glyphBoxTop %d\n", metrics1.glyphBoxTop); + ok(metrics1.glyphBoxRight > 0, "glyphBoxRight %d\n", metrics1.glyphBoxRight); + ok(metrics1.glyphBoxBottom < 0, "glyphBoxBottom %d\n", metrics1.glyphBoxBottom); + ok(metrics1.subscriptPositionY < 0, "subscriptPositionY %d\n", metrics1.subscriptPositionY); + ok(metrics1.subscriptSizeX > 0, "subscriptSizeX %d\n", metrics1.subscriptSizeX); + ok(metrics1.subscriptSizeY > 0, "subscriptSizeY %d\n", metrics1.subscriptSizeY); + ok(metrics1.superscriptPositionY > 0, "superscriptPositionY %d\n", metrics1.superscriptPositionY); + ok(metrics1.superscriptSizeX > 0, "superscriptSizeX %d\n", metrics1.superscriptSizeX); + ok(metrics1.superscriptSizeY > 0, "superscriptSizeY %d\n", metrics1.superscriptSizeY); + ok(!metrics1.hasTypographicMetrics, "hasTypographicMetrics %d\n", metrics1.hasTypographicMetrics); + + IDWriteFontFace1_Release(fontface1); + IDWriteFont1_Release(font1); + } + else + win_skip("DWRITE_FONT_METRICS1 is not supported.\n"); + + IDWriteFontFace_Release(fontface); + IDWriteFont_Release(font); IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); } static void test_system_fontcollection(void) { IDWriteFontCollection *collection, *coll2; + IDWriteLocalFontFileLoader *localloader; + IDWriteFactory *factory, *factory2; + IDWriteFontFileLoader *loader; IDWriteFontFamily *family; + IDWriteFontFace *fontface; + IDWriteFontFile *file; + IDWriteFont *font; HRESULT hr; UINT32 i; BOOL ret; + factory = create_factory(); + hr = IDWriteFactory_GetSystemFontCollection(factory, &collection, FALSE); ok(hr == S_OK, "got 0x%08x\n", hr); @@ -742,6 +1138,13 @@ ok(coll2 == collection, "got %p, was %p\n", coll2, collection); IDWriteFontCollection_Release(coll2); + factory2 = create_factory(); + hr = IDWriteFactory_GetSystemFontCollection(factory2, &coll2, FALSE); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(coll2 != collection, "got %p, was %p\n", coll2, collection); + IDWriteFontCollection_Release(coll2); + IDWriteFactory_Release(factory2); + i = IDWriteFontCollection_GetFontFamilyCount(collection); ok(i, "got %u\n", i); @@ -758,6 +1161,53 @@ ok(ret, "got %d\n", ret); ok(i != (UINT32)-1, "got %u\n", i); + /* get back local file loader */ + hr = IDWriteFontCollection_GetFontFamily(collection, i, &family); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_NORMAL, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteFontFamily_Release(family); + + hr = IDWriteFont_CreateFontFace(font, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteFont_Release(font); + + i = 1; + file = NULL; + hr = IDWriteFontFace_GetFiles(fontface, &i, &file); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(file != NULL, "got %p\n", file); + + hr = IDWriteFontFile_GetLoader(file, &loader); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteFontFile_Release(file); + + hr = IDWriteFontFileLoader_QueryInterface(loader, &IID_IDWriteLocalFontFileLoader, (void**)&localloader); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteLocalFontFileLoader_Release(localloader); + + /* local loader is not registered by default */ + hr = IDWriteFactory_RegisterFontFileLoader(factory, loader); + ok(hr == S_OK || broken(hr == DWRITE_E_ALREADYREGISTERED), "got 0x%08x\n", hr); + hr = IDWriteFactory_UnregisterFontFileLoader(factory, loader); + ok(hr == S_OK || broken(hr == E_INVALIDARG), "got 0x%08x\n", hr); + + /* try with a different factory */ + factory2 = create_factory(); + hr = IDWriteFactory_RegisterFontFileLoader(factory2, loader); + ok(hr == S_OK || broken(hr == DWRITE_E_ALREADYREGISTERED), "got 0x%08x\n", hr); + hr = IDWriteFactory_RegisterFontFileLoader(factory2, loader); + ok(hr == DWRITE_E_ALREADYREGISTERED, "got 0x%08x\n", hr); + hr = IDWriteFactory_UnregisterFontFileLoader(factory2, loader); + ok(hr == S_OK || broken(hr == E_INVALIDARG), "got 0x%08x\n", hr); + hr = IDWriteFactory_UnregisterFontFileLoader(factory2, loader); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + IDWriteFactory_Release(factory2); + + IDWriteFontFileLoader_Release(loader); + ret = TRUE; i = 0; hr = IDWriteFontCollection_FindFamilyName(collection, blahW, &i, &ret); @@ -766,16 +1216,21 @@ ok(i == (UINT32)-1, "got %u\n", i); IDWriteFontCollection_Release(collection); + IDWriteFactory_Release(factory); } static void test_ConvertFontFaceToLOGFONT(void) { + DWRITE_FONT_SIMULATIONS sim; IDWriteGdiInterop *interop; IDWriteFontFace *fontface; + IDWriteFactory *factory; IDWriteFont *font; LOGFONTW logfont; HRESULT hr; + factory = create_factory(); + hr = IDWriteFactory_GetGdiInterop(factory, &interop); ok(hr == S_OK, "got 0x%08x\n", hr); @@ -795,6 +1250,13 @@ hr = IDWriteFont_CreateFontFace(font, &fontface); ok(hr == S_OK, "got 0x%08x\n", hr); + + sim = IDWriteFont_GetSimulations(font); + ok(sim == DWRITE_FONT_SIMULATIONS_OBLIQUE, "sim %d\n", sim); + + sim = IDWriteFontFace_GetSimulations(fontface); + ok(sim == DWRITE_FONT_SIMULATIONS_OBLIQUE, "sim %d\n", sim); + IDWriteFont_Release(font); if (0) /* crashes on native */ @@ -815,46 +1277,115 @@ ok(logfont.lfItalic == 1, "got %d\n", logfont.lfItalic); ok(logfont.lfUnderline == 0, "got %d\n", logfont.lfUnderline); ok(logfont.lfStrikeOut == 0, "got %d\n", logfont.lfStrikeOut); +todo_wine ok(!lstrcmpW(logfont.lfFaceName, tahomaW), "got %s\n", wine_dbgstr_w(logfont.lfFaceName)); IDWriteGdiInterop_Release(interop); IDWriteFontFace_Release(fontface); + IDWriteFactory_Release(factory); } -static HRESULT WINAPI fontcollectionloader_QueryInterface(IDWriteFontCollectionLoader *iface, REFIID riid, void **obj) +static HRESULT WINAPI fontfileenumerator_QueryInterface(IDWriteFontFileEnumerator *iface, REFIID riid, void **obj) { - *obj = iface; - return S_OK; + if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_IDWriteFontFileEnumerator)) + { + *obj = iface; + IDWriteFontFileEnumerator_AddRef(iface); + return S_OK; + } + return E_NOINTERFACE; } -static ULONG WINAPI fontcollectionloader_AddRef(IDWriteFontCollectionLoader *iface) +static ULONG WINAPI fontfileenumerator_AddRef(IDWriteFontFileEnumerator *iface) { return 2; } -static ULONG WINAPI fontcollectionloader_Release(IDWriteFontCollectionLoader *iface) +static ULONG WINAPI fontfileenumerator_Release(IDWriteFontFileEnumerator *iface) { return 1; } -static HRESULT WINAPI fontcollectionloader_CreateEnumeratorFromKey(IDWriteFontCollectionLoader *iface, IDWriteFactory * factory, const void * collectionKey, UINT32 collectionKeySize, IDWriteFontFileEnumerator ** fontFileEnumerator) +static HRESULT WINAPI fontfileenumerator_GetCurrentFontFile(IDWriteFontFileEnumerator *iface, IDWriteFontFile **file) { + *file = NULL; + return E_FAIL; +} + +static HRESULT WINAPI fontfileenumerator_MoveNext(IDWriteFontFileEnumerator *iface, BOOL *current) +{ + *current = FALSE; return S_OK; } -static const struct IDWriteFontCollectionLoaderVtbl dwritefontcollectionloadervtbl = { - fontcollectionloader_QueryInterface, - fontcollectionloader_AddRef, - fontcollectionloader_Release, - fontcollectionloader_CreateEnumeratorFromKey +static const struct IDWriteFontFileEnumeratorVtbl dwritefontfileenumeratorvtbl = +{ + fontfileenumerator_QueryInterface, + fontfileenumerator_AddRef, + fontfileenumerator_Release, + fontfileenumerator_MoveNext, + fontfileenumerator_GetCurrentFontFile, }; -static void test_CustomFontCollection(void) +static HRESULT WINAPI fontcollectionloader_QueryInterface(IDWriteFontCollectionLoader *iface, REFIID riid, void **obj) { - IDWriteFontCollectionLoader collection = { &dwritefontcollectionloadervtbl }; - IDWriteFontCollectionLoader collection2 = { &dwritefontcollectionloadervtbl }; - HRESULT hr; - + *obj = iface; + return S_OK; +} + +static ULONG WINAPI fontcollectionloader_AddRef(IDWriteFontCollectionLoader *iface) +{ + return 2; +} + +static ULONG WINAPI fontcollectionloader_Release(IDWriteFontCollectionLoader *iface) +{ + return 1; +} + +static HRESULT WINAPI fontcollectionloader_CreateEnumeratorFromKey(IDWriteFontCollectionLoader *iface, IDWriteFactory *factory, const void *key, + UINT32 key_size, IDWriteFontFileEnumerator **ret) +{ + static IDWriteFontFileEnumerator enumerator = { &dwritefontfileenumeratorvtbl }; + *ret = &enumerator; + return S_OK; +} + +static const struct IDWriteFontCollectionLoaderVtbl dwritefontcollectionloadervtbl = { + fontcollectionloader_QueryInterface, + fontcollectionloader_AddRef, + fontcollectionloader_Release, + fontcollectionloader_CreateEnumeratorFromKey +}; + +static void test_CustomFontCollection(void) +{ + static const WCHAR fontnameW[] = {'w','i','n','e','_','t','e','s','t',0}; + IDWriteFontCollectionLoader collection = { &dwritefontcollectionloadervtbl }; + IDWriteFontCollectionLoader collection2 = { &dwritefontcollectionloadervtbl }; + IDWriteFontCollectionLoader collection3 = { &dwritefontcollectionloadervtbl }; + IDWriteFontCollection *font_collection = NULL; + static IDWriteFontFileLoader rloader = { &resourcefontfileloadervtbl }; + struct test_fontcollectionloader resource_collection = { { &resourcecollectionloadervtbl }, &rloader }; + IDWriteFontFamily *family, *family2, *family3; + IDWriteFontFace *idfontface, *idfontface2; + IDWriteFontFile *fontfile, *fontfile2; + IDWriteLocalizedStrings *string; + IDWriteFont *idfont, *idfont2; + IDWriteFactory *factory; + UINT32 index, count; + BOOL exists; + HRESULT hr; + HRSRC font; + + factory = create_factory(); + + hr = IDWriteFactory_RegisterFontCollectionLoader(factory, NULL); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + hr = IDWriteFactory_UnregisterFontCollectionLoader(factory, NULL); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + hr = IDWriteFactory_RegisterFontCollectionLoader(factory, &collection); ok(hr == S_OK, "got 0x%08x\n", hr); hr = IDWriteFactory_RegisterFontCollectionLoader(factory, &collection2); @@ -862,12 +1393,126 @@ hr = IDWriteFactory_RegisterFontCollectionLoader(factory, &collection); ok(hr == DWRITE_E_ALREADYREGISTERED, "got 0x%08x\n", hr); + hr = IDWriteFactory_RegisterFontFileLoader(factory, &rloader); + ok(hr == S_OK, "got 0x%08x\n", hr); + hr = IDWriteFactory_RegisterFontCollectionLoader(factory, &resource_collection.IDWriteFontFileCollectionLoader_iface); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFactory_CreateCustomFontCollection(factory, &collection3, "Billy", 6, &font_collection); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + hr = IDWriteFactory_CreateCustomFontCollection(factory, &collection, "Billy", 6, &font_collection); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteFontCollection_Release(font_collection); + + hr = IDWriteFactory_CreateCustomFontCollection(factory, &collection2, "Billy", 6, &font_collection); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteFontCollection_Release(font_collection); + + hr = IDWriteFactory_CreateCustomFontCollection(factory, (IDWriteFontCollectionLoader*)0xdeadbeef, "Billy", 6, &font_collection); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + font = FindResourceA(GetModuleHandleA(NULL), (LPCSTR)MAKEINTRESOURCE(1), (LPCSTR)RT_RCDATA); + ok(font != NULL, "Failed to find font resource\n"); + + hr = IDWriteFactory_CreateCustomFontCollection(factory, &resource_collection.IDWriteFontFileCollectionLoader_iface, + &font, sizeof(HRSRC), &font_collection); + ok(hr == S_OK, "got 0x%08x\n",hr); + + index = 1; + exists = FALSE; + hr = IDWriteFontCollection_FindFamilyName(font_collection, fontnameW, &index, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(index == 0, "got index %i\n", index); + ok(exists, "got exists %i\n", exists); + + count = IDWriteFontCollection_GetFontFamilyCount(font_collection); + ok(count == 1, "got %u\n", count); + + family = NULL; + hr = IDWriteFontCollection_GetFontFamily(font_collection, 0, &family); + ok(hr == S_OK, "got 0x%08x\n", hr); + EXPECT_REF(family, 1); + + family2 = NULL; + hr = IDWriteFontCollection_GetFontFamily(font_collection, 0, &family2); + ok(hr == S_OK, "got 0x%08x\n", hr); + EXPECT_REF(family2, 1); + ok(family != family2, "got %p, %p\n", family, family2); + + hr = IDWriteFontFamily_GetFont(family, 0, &idfont); + ok(hr == S_OK, "got 0x%08x\n", hr); + EXPECT_REF(idfont, 1); + EXPECT_REF(family, 2); + hr = IDWriteFontFamily_GetFont(family, 0, &idfont2); + ok(hr == S_OK, "got 0x%08x\n", hr); + EXPECT_REF(idfont2, 1); + EXPECT_REF(family, 3); + ok(idfont != idfont2, "got %p, %p\n", idfont, idfont2); + IDWriteFont_Release(idfont2); + + hr = IDWriteFont_GetInformationalStrings(idfont, DWRITE_INFORMATIONAL_STRING_COPYRIGHT_NOTICE, &string, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(exists, "got %d\n", exists); + EXPECT_REF(string, 1); + + family3 = NULL; + hr = IDWriteFont_GetFontFamily(idfont, &family3); + ok(hr == S_OK, "got 0x%08x\n", hr); + EXPECT_REF(family, 3); + ok(family == family3, "got %p, %p\n", family, family3); + IDWriteFontFamily_Release(family3); + + idfontface = NULL; + hr = IDWriteFont_CreateFontFace(idfont, &idfontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + EXPECT_REF(idfont, 1); + + idfont2 = NULL; + hr = IDWriteFontFamily_GetFont(family2, 0, &idfont2); + ok(hr == S_OK, "got 0x%08x\n", hr); + EXPECT_REF(idfont2, 1); + EXPECT_REF(idfont, 1); + ok(idfont2 != idfont, "Font instances shoudl not match\n"); + + idfontface2 = NULL; + hr = IDWriteFont_CreateFontFace(idfont2, &idfontface2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(idfontface2 == idfontface, "fontfaces should match\n"); + + index = 1; + fontfile = NULL; + hr = IDWriteFontFace_GetFiles(idfontface, &index, &fontfile); + ok(hr == S_OK, "got 0x%08x\n", hr); + + index = 1; + fontfile2 = NULL; + hr = IDWriteFontFace_GetFiles(idfontface2, &index, &fontfile2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(fontfile == fontfile2, "fontfiles should match\n"); + + IDWriteFont_Release(idfont); + IDWriteFont_Release(idfont2); + IDWriteFontFile_Release(fontfile); + IDWriteFontFile_Release(fontfile2); + IDWriteFontFace_Release(idfontface); + IDWriteFontFace_Release(idfontface2); + IDWriteFontFamily_Release(family2); + IDWriteFontFamily_Release(family); + IDWriteFontCollection_Release(font_collection); + hr = IDWriteFactory_UnregisterFontCollectionLoader(factory, &collection); ok(hr == S_OK, "got 0x%08x\n", hr); hr = IDWriteFactory_UnregisterFontCollectionLoader(factory, &collection); ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); hr = IDWriteFactory_UnregisterFontCollectionLoader(factory, &collection2); ok(hr == S_OK, "got 0x%08x\n", hr); + hr = IDWriteFactory_UnregisterFontCollectionLoader(factory, &resource_collection.IDWriteFontFileCollectionLoader_iface); + ok(hr == S_OK, "got 0x%08x\n", hr); + hr = IDWriteFactory_UnregisterFontFileLoader(factory, &rloader); + ok(hr == S_OK, "got 0x%08x\n", hr); + + IDWriteFactory_Release(factory); } static HRESULT WINAPI fontfileloader_QueryInterface(IDWriteFontFileLoader *iface, REFIID riid, void **obj) @@ -905,23 +1550,26 @@ fontfileloader_CreateStreamFromKey }; -static void test_FontLoader(void) +static void test_CreateCustomFontFileReference(void) { IDWriteFontFileLoader floader = { &dwritefontfileloadervtbl }; IDWriteFontFileLoader floader2 = { &dwritefontfileloadervtbl }; IDWriteFontFileLoader floader3 = { &dwritefontfileloadervtbl }; - IDWriteFontFileLoader rloader = { &resourcefontfileloadervtbl }; - IDWriteFontFile *ffile = NULL; - BOOL support = 1; - DWRITE_FONT_FILE_TYPE type = 1; - DWRITE_FONT_FACE_TYPE face = 1; - UINT32 count = 1; - IDWriteFontFace *fface = NULL; + IDWriteFactory *factory, *factory2; + IDWriteFontFile *file, *file2; + BOOL support; + DWRITE_FONT_FILE_TYPE file_type; + DWRITE_FONT_FACE_TYPE face_type; + UINT32 count; + IDWriteFontFace *face, *face2; HRESULT hr; - HRSRC font; + HRSRC fontrsrc; UINT32 codePoints[1] = {0xa8}; UINT16 indices[1]; + factory = create_factory(); + factory2 = create_factory(); + hr = IDWriteFactory_RegisterFontFileLoader(factory, NULL); ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); hr = IDWriteFactory_RegisterFontFileLoader(factory, &floader); @@ -933,56 +1581,91 @@ hr = IDWriteFactory_RegisterFontFileLoader(factory, &rloader); ok(hr == S_OK, "got 0x%08x\n", hr); - hr = IDWriteFactory_CreateCustomFontFileReference(factory, "test", 4, &floader, &ffile); + file = NULL; + hr = IDWriteFactory_CreateCustomFontFileReference(factory, "test", 4, &floader, &file); ok(hr == S_OK, "got 0x%08x\n", hr); - if (SUCCEEDED(hr)) - IDWriteFontFile_Release(ffile); + IDWriteFontFile_Release(file); - hr = IDWriteFactory_CreateCustomFontFileReference(factory, "test", 4, &floader3, &ffile); + hr = IDWriteFactory_CreateCustomFontFileReference(factory, "test", 4, &floader3, &file); ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); - if (SUCCEEDED(hr)) - IDWriteFontFile_Release(ffile); - hr = IDWriteFactory_CreateCustomFontFileReference(factory, "test", 4, NULL, &ffile); + hr = IDWriteFactory_CreateCustomFontFileReference(factory, "test", 4, NULL, &file); ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); - if (SUCCEEDED(hr)) - IDWriteFontFile_Release(ffile); - hr = IDWriteFactory_CreateCustomFontFileReference(factory, "test", 4, &floader, &ffile); + file = NULL; + hr = IDWriteFactory_CreateCustomFontFileReference(factory, "test", 4, &floader, &file); ok(hr == S_OK, "got 0x%08x\n", hr); - IDWriteFontFile_Analyze(ffile, &support, &type, &face, &count); + + file_type = DWRITE_FONT_FILE_TYPE_TRUETYPE; + face_type = DWRITE_FONT_FACE_TYPE_TRUETYPE; + support = TRUE; + count = 1; + IDWriteFontFile_Analyze(file, &support, &file_type, &face_type, &count); ok(hr == S_OK, "got 0x%08x\n", hr); ok(support == FALSE, "got %i\n", support); - ok(type == DWRITE_FONT_FILE_TYPE_UNKNOWN, "got %i\n", type); - ok(face == DWRITE_FONT_FACE_TYPE_UNKNOWN, "got %i\n", face); + ok(file_type == DWRITE_FONT_FILE_TYPE_UNKNOWN, "got %i\n", file_type); + ok(face_type == DWRITE_FONT_FACE_TYPE_UNKNOWN, "got %i\n", face_type); ok(count == 0, "got %i\n", count); - hr = IDWriteFactory_CreateFontFace(factory, DWRITE_FONT_FACE_TYPE_CFF, 1, &ffile, 0, 0, &fface); + hr = IDWriteFactory_CreateFontFace(factory, DWRITE_FONT_FACE_TYPE_CFF, 1, &file, 0, 0, &face); ok(hr == 0x8faecafe, "got 0x%08x\n", hr); - IDWriteFontFile_Release(ffile); + IDWriteFontFile_Release(file); - font = FindResourceA(GetModuleHandleA(NULL), (LPCSTR)MAKEINTRESOURCE(1), (LPCSTR)RT_RCDATA); - ok(font != NULL, "Failed to find font resource\n"); - if (font) - { - hr = IDWriteFactory_CreateCustomFontFileReference(factory, &font, sizeof(HRSRC), &rloader, &ffile); - ok(hr == S_OK, "got 0x%08x\n", hr); + fontrsrc = FindResourceA(GetModuleHandleA(NULL), (LPCSTR)MAKEINTRESOURCE(1), (LPCSTR)RT_RCDATA); + ok(fontrsrc != NULL, "Failed to find font resource\n"); - IDWriteFontFile_Analyze(ffile, &support, &type, &face, &count); - ok(hr == S_OK, "got 0x%08x\n", hr); - ok(support == TRUE, "got %i\n", support); - ok(type == DWRITE_FONT_FILE_TYPE_TRUETYPE, "got %i\n", type); - ok(face == DWRITE_FONT_FACE_TYPE_TRUETYPE, "got %i\n", face); - ok(count == 1, "got %i\n", count); - - hr = IDWriteFactory_CreateFontFace(factory, face, 1, &ffile, 0, 0, &fface); - ok(hr == S_OK, "got 0x%08x\n",hr); - hr = IDWriteFontFace_GetGlyphIndices(fface, codePoints, 1, indices); - ok(hr == S_OK, "got0x%08x\n",hr); - ok(indices[0] == 6, "got index %i\n",indices[0]); - IDWriteFontFace_Release(fface); - IDWriteFontFile_Release(ffile); - } + hr = IDWriteFactory_CreateCustomFontFileReference(factory, &fontrsrc, sizeof(HRSRC), &rloader, &file); + ok(hr == S_OK, "got 0x%08x\n", hr); + + file_type = DWRITE_FONT_FILE_TYPE_UNKNOWN; + face_type = DWRITE_FONT_FACE_TYPE_UNKNOWN; + support = FALSE; + count = 0; + hr = IDWriteFontFile_Analyze(file, &support, &file_type, &face_type, &count); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(support == TRUE, "got %i\n", support); + ok(file_type == DWRITE_FONT_FILE_TYPE_TRUETYPE, "got %i\n", file_type); + ok(face_type == DWRITE_FONT_FACE_TYPE_TRUETYPE, "got %i\n", face_type); + ok(count == 1, "got %i\n", count); + + /* invalid index */ + hr = IDWriteFactory_CreateFontFace(factory, face_type, 1, &file, 1, DWRITE_FONT_SIMULATIONS_NONE, &face); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + hr = IDWriteFactory_CreateFontFace(factory, face_type, 1, &file, 0, DWRITE_FONT_SIMULATIONS_NONE, &face); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFactory_CreateFontFace(factory, face_type, 1, &file, 0, DWRITE_FONT_SIMULATIONS_NONE, &face2); + ok(hr == S_OK, "got 0x%08x\n", hr); + /* fontface instances are reused starting with win7 */ + ok(face == face2 || broken(face != face2), "got %p, %p\n", face, face2); + IDWriteFontFace_Release(face2); + + /* file was created with different factory */ + face2 = NULL; + hr = IDWriteFactory_CreateFontFace(factory2, face_type, 1, &file, 0, DWRITE_FONT_SIMULATIONS_NONE, &face2); +todo_wine + ok(hr == S_OK, "got 0x%08x\n", hr); +if (face2) + IDWriteFontFace_Release(face2); + + file2 = NULL; + hr = IDWriteFactory_CreateCustomFontFileReference(factory, &fontrsrc, sizeof(HRSRC), &rloader, &file2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(file != file2, "got %p, %p\n", file, file2); + + hr = IDWriteFactory_CreateFontFace(factory, face_type, 1, &file2, 0, DWRITE_FONT_SIMULATIONS_NONE, &face2); + ok(hr == S_OK, "got 0x%08x\n", hr); + /* fontface instances are reused starting with win7 */ + ok(face == face2 || broken(face != face2), "got %p, %p\n", face, face2); + IDWriteFontFace_Release(face2); + IDWriteFontFile_Release(file2); + + hr = IDWriteFontFace_GetGlyphIndices(face, codePoints, 1, indices); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(indices[0] == 6, "got index %i\n", indices[0]); + IDWriteFontFace_Release(face); + IDWriteFontFile_Release(file); hr = IDWriteFactory_UnregisterFontFileLoader(factory, &floader); ok(hr == S_OK, "got 0x%08x\n", hr); @@ -992,26 +1675,19 @@ ok(hr == S_OK, "got 0x%08x\n", hr); hr = IDWriteFactory_UnregisterFontFileLoader(factory, &rloader); ok(hr == S_OK, "got 0x%08x\n", hr); + + IDWriteFactory_Release(factory2); + IDWriteFactory_Release(factory); } -static void test_CreateFontFileReference(void) +static void create_testfontfile(const WCHAR *filename) { DWORD written; HANDLE file; HRSRC res; void *ptr; - HRESULT hr; - WCHAR font_name[] = {'w','i','n','e','_','t','e','s','t','_','f','o','n','t','.','t','t','f',0}; - IDWriteFontFile *ffile = NULL; - BOOL support = 1; - DWRITE_FONT_FILE_TYPE type = 1; - DWRITE_FONT_FACE_TYPE face = 1; - UINT32 count = 1; - IDWriteFontFace *fface = NULL; - - file = CreateFileW(font_name, GENERIC_READ|GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, 0, 0 ); + file = CreateFileW(filename, GENERIC_READ|GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, 0, 0 ); ok( file != INVALID_HANDLE_VALUE, "file creation failed\n" ); - if (file == INVALID_HANDLE_VALUE) return; res = FindResourceA(GetModuleHandleA(NULL), (LPCSTR)MAKEINTRESOURCE(1), (LPCSTR)RT_RCDATA); ok( res != 0, "couldn't find resource\n" ); @@ -1019,34 +1695,636 @@ WriteFile( file, ptr, SizeofResource( GetModuleHandleA(NULL), res ), &written, NULL ); ok( written == SizeofResource( GetModuleHandleA(NULL), res ), "couldn't write resource\n" ); CloseHandle( file ); +} + +static void test_CreateFontFileReference(void) +{ + HRESULT hr; + IDWriteFontFile *ffile = NULL; + BOOL support; + DWRITE_FONT_FILE_TYPE type; + DWRITE_FONT_FACE_TYPE face; + UINT32 count; + IDWriteFontFace *fface = NULL; + IDWriteFactory *factory; + + create_testfontfile(test_fontfile); + factory = create_factory(); - hr = IDWriteFactory_CreateFontFileReference(factory, font_name, NULL, &ffile); + hr = IDWriteFactory_CreateFontFileReference(factory, test_fontfile, NULL, &ffile); ok(hr == S_OK, "got 0x%08x\n",hr); - IDWriteFontFile_Analyze(ffile, &support, &type, &face, &count); + support = FALSE; + type = DWRITE_FONT_FILE_TYPE_UNKNOWN; + face = DWRITE_FONT_FACE_TYPE_CFF; + count = 0; + hr = IDWriteFontFile_Analyze(ffile, &support, &type, &face, &count); ok(hr == S_OK, "got 0x%08x\n", hr); ok(support == TRUE, "got %i\n", support); ok(type == DWRITE_FONT_FILE_TYPE_TRUETYPE, "got %i\n", type); ok(face == DWRITE_FONT_FACE_TYPE_TRUETYPE, "got %i\n", face); ok(count == 1, "got %i\n", count); - hr = IDWriteFactory_CreateFontFace(factory, face, 1, &ffile, 0, 0, &fface); - ok(hr == S_OK, "got 0x%08x\n",hr); + hr = IDWriteFactory_CreateFontFace(factory, face, 1, &ffile, 0, DWRITE_FONT_SIMULATIONS_NONE, &fface); + ok(hr == S_OK, "got 0x%08x\n", hr); IDWriteFontFace_Release(fface); IDWriteFontFile_Release(ffile); + IDWriteFactory_Release(factory); - DeleteFileW(font_name); + DeleteFileW(test_fontfile); } -START_TEST(font) +static void test_shared_isolated(void) { + IDWriteFactory *isolated, *isolated2; + IDWriteFactory *shared, *shared2; HRESULT hr; - hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_ISOLATED, &IID_IDWriteFactory, (IUnknown**)&factory); + /* invalid type */ + shared = NULL; + hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_SHARED+1, &IID_IDWriteFactory, (IUnknown**)&shared); ok(hr == S_OK, "got 0x%08x\n", hr); - if (hr != S_OK) - { + ok(shared != NULL, "got %p\n", shared); + IDWriteFactory_Release(shared); + + hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_SHARED, &IID_IDWriteFactory, (IUnknown**)&shared); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_SHARED, &IID_IDWriteFactory, (IUnknown**)&shared2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(shared == shared2, "got %p, and %p\n", shared, shared2); + + IDWriteFactory_Release(shared); + IDWriteFactory_Release(shared2); + + /* we got 2 references, released 2 - still same pointer is returned */ + hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_SHARED, &IID_IDWriteFactory, (IUnknown**)&shared2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(shared == shared2, "got %p, and %p\n", shared, shared2); + IDWriteFactory_Release(shared2); + + hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_ISOLATED, &IID_IDWriteFactory, (IUnknown**)&isolated); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_ISOLATED, &IID_IDWriteFactory, (IUnknown**)&isolated2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(isolated != isolated2, "got %p, and %p\n", isolated, isolated2); + IDWriteFactory_Release(isolated2); + + hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_SHARED+1, &IID_IDWriteFactory, (IUnknown**)&isolated2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(shared != isolated2, "got %p, and %p\n", shared, isolated2); + + IDWriteFactory_Release(isolated); + IDWriteFactory_Release(isolated2); +} + +static void test_GetUnicodeRanges(void) +{ + DWRITE_UNICODE_RANGE *ranges, r; + IDWriteFontFile *ffile = NULL; + IDWriteFontFace1 *fontface1; + IDWriteFontFace *fontface; + IDWriteFactory *factory; + UINT32 count; + HRESULT hr; + HRSRC font; + + factory = create_factory(); + + hr = IDWriteFactory_RegisterFontFileLoader(factory, &rloader); + ok(hr == S_OK, "got 0x%08x\n", hr); + + font = FindResourceA(GetModuleHandleA(NULL), (LPCSTR)MAKEINTRESOURCE(1), (LPCSTR)RT_RCDATA); + ok(font != NULL, "Failed to find font resource\n"); + + hr = IDWriteFactory_CreateCustomFontFileReference(factory, &font, sizeof(HRSRC), &rloader, &ffile); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFactory_CreateFontFace(factory, DWRITE_FONT_FACE_TYPE_TRUETYPE, 1, &ffile, 0, DWRITE_FONT_SIMULATIONS_NONE, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteFontFile_Release(ffile); + + hr = IDWriteFontFace_QueryInterface(fontface, &IID_IDWriteFontFace1, (void**)&fontface1); + IDWriteFontFace_Release(fontface); + if (hr != S_OK) { + win_skip("GetUnicodeRanges() is not supported.\n"); + IDWriteFactory_Release(factory); + return; + } + + count = 0; + hr = IDWriteFontFace1_GetUnicodeRanges(fontface1, 0, NULL, &count); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "got 0x%08x\n", hr); + ok(count > 0, "got %u\n", count); + + count = 1; + hr = IDWriteFontFace1_GetUnicodeRanges(fontface1, 1, NULL, &count); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + ok(count == 0, "got %u\n", count); + + count = 0; + hr = IDWriteFontFace1_GetUnicodeRanges(fontface1, 1, &r, &count); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "got 0x%08x\n", hr); + ok(count > 1, "got %u\n", count); + + ranges = heap_alloc(count*sizeof(DWRITE_UNICODE_RANGE)); + hr = IDWriteFontFace1_GetUnicodeRanges(fontface1, count, ranges, &count); + ok(hr == S_OK, "got 0x%08x\n", hr); + + ranges[0].first = ranges[0].last = 0; + hr = IDWriteFontFace1_GetUnicodeRanges(fontface1, 1, ranges, &count); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "got 0x%08x\n", hr); + ok(ranges[0].first != 0 && ranges[0].last != 0, "got 0x%x-0x%0x\n", ranges[0].first, ranges[0].last); + + heap_free(ranges); + + hr = IDWriteFactory_UnregisterFontFileLoader(factory, &rloader); + ok(hr == S_OK, "got 0x%08x\n", hr); + + IDWriteFontFace1_Release(fontface1); + IDWriteFactory_Release(factory); +} + +static void test_GetFontFromFontFace(void) +{ + IDWriteFontFace *fontface, *fontface2; + IDWriteFontCollection *collection; + IDWriteFont *font, *font2, *font3; + IDWriteFontFamily *family; + IDWriteFactory *factory; + HRESULT hr; + + factory = create_factory(); + + hr = IDWriteFactory_GetSystemFontCollection(factory, &collection, FALSE); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontCollection_GetFontFamily(collection, 0, &family); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_NORMAL, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFont_CreateFontFace(font, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + + font2 = NULL; + hr = IDWriteFontCollection_GetFontFromFontFace(collection, fontface, &font2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(font2 != font, "got %p, %p\n", font2, font); + + font3 = NULL; + hr = IDWriteFontCollection_GetFontFromFontFace(collection, fontface, &font3); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(font3 != font && font3 != font2, "got %p, %p, %p\n", font3, font2, font); + + hr = IDWriteFont_CreateFontFace(font2, &fontface2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(fontface2 == fontface, "got %p, %p\n", fontface2, fontface); + IDWriteFontFace_Release(fontface2); + + hr = IDWriteFont_CreateFontFace(font3, &fontface2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(fontface2 == fontface, "got %p, %p\n", fontface2, fontface); + IDWriteFontFace_Release(fontface2); + + IDWriteFont_Release(font); + IDWriteFont_Release(font2); + IDWriteFont_Release(font3); + IDWriteFontFace_Release(fontface); + IDWriteFontFamily_Release(family); + IDWriteFontCollection_Release(collection); + IDWriteFactory_Release(factory); +} + +static void test_GetFirstMatchingFont(void) +{ + DWRITE_FONT_SIMULATIONS simulations; + IDWriteFontCollection *collection; + IDWriteFont *font, *font2; + IDWriteFontFamily *family; + IDWriteFactory *factory; + UINT32 index; + BOOL exists; + HRESULT hr; + + factory = create_factory(); + + hr = IDWriteFactory_GetSystemFontCollection(factory, &collection, FALSE); + ok(hr == S_OK, "got 0x%08x\n", hr); + + index = ~0; + exists = FALSE; + hr = IDWriteFontCollection_FindFamilyName(collection, tahomaW, &index, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(exists, "got %d\n", exists); + + hr = IDWriteFontCollection_GetFontFamily(collection, index, &family); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_NORMAL, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_NORMAL, &font2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(font != font2, "got %p, %p\n", font, font2); + IDWriteFont_Release(font); + + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_ITALIC, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + simulations = IDWriteFont_GetSimulations(font); + ok(simulations == DWRITE_FONT_SIMULATIONS_OBLIQUE, "%d\n", simulations); + + IDWriteFont_Release(font); + IDWriteFont_Release(font2); + IDWriteFontFamily_Release(family); + IDWriteFontCollection_Release(collection); + IDWriteFactory_Release(factory); +} + +static void test_GetInformationalStrings(void) +{ + IDWriteLocalizedStrings *strings, *strings2; + IDWriteFontCollection *collection; + IDWriteFontFamily *family; + IDWriteFactory *factory; + IDWriteFont *font; + BOOL exists; + HRESULT hr; + + factory = create_factory(); + + hr = IDWriteFactory_GetSystemFontCollection(factory, &collection, FALSE); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontCollection_GetFontFamily(collection, 0, &family); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_NORMAL, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + exists = TRUE; + strings = (void*)0xdeadbeef; + hr = IDWriteFont_GetInformationalStrings(font, DWRITE_INFORMATIONAL_STRING_POSTSCRIPT_CID_NAME+1, &strings, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(exists == FALSE, "got %d\n", exists); + ok(strings == NULL, "got %p\n", strings); + + exists = TRUE; + strings = NULL; + hr = IDWriteFont_GetInformationalStrings(font, DWRITE_INFORMATIONAL_STRING_NONE, &strings, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(exists == FALSE, "got %d\n", exists); + + exists = FALSE; + strings = NULL; + hr = IDWriteFont_GetInformationalStrings(font, DWRITE_INFORMATIONAL_STRING_WIN32_FAMILY_NAMES, &strings, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(exists == TRUE, "got %d\n", exists); + + /* strings instance is not reused */ + strings2 = NULL; + hr = IDWriteFont_GetInformationalStrings(font, DWRITE_INFORMATIONAL_STRING_WIN32_FAMILY_NAMES, &strings2, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(strings2 != strings, "got %p, %p\n", strings2, strings); + + IDWriteLocalizedStrings_Release(strings); + IDWriteLocalizedStrings_Release(strings2); + IDWriteFont_Release(font); + IDWriteFontFamily_Release(family); + IDWriteFontCollection_Release(collection); + IDWriteFactory_Release(factory); +} + +static void test_GetGdiInterop(void) +{ + IDWriteGdiInterop *interop, *interop2; + IDWriteFactory *factory, *factory2; + IDWriteFont *font; + LOGFONTW logfont; + HRESULT hr; + + factory = create_factory(); + + interop = NULL; + hr = IDWriteFactory_GetGdiInterop(factory, &interop); + ok(hr == S_OK, "got 0x%08x\n", hr); + + interop2 = NULL; + hr = IDWriteFactory_GetGdiInterop(factory, &interop2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(interop == interop2, "got %p, %p\n", interop, interop2); + IDWriteGdiInterop_Release(interop2); + + hr = DWriteCreateFactory(DWRITE_FACTORY_TYPE_ISOLATED, &IID_IDWriteFactory, (IUnknown**)&factory2); + ok(hr == S_OK, "got 0x%08x\n", hr); + + /* each factory gets its own interop */ + interop2 = NULL; + hr = IDWriteFactory_GetGdiInterop(factory2, &interop2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(interop != interop2, "got %p, %p\n", interop, interop2); + + /* release factory - interop still works */ + IDWriteFactory_Release(factory2); + + memset(&logfont, 0, sizeof(logfont)); + logfont.lfHeight = 12; + logfont.lfWidth = 12; + logfont.lfWeight = FW_NORMAL; + logfont.lfItalic = 1; + lstrcpyW(logfont.lfFaceName, tahomaW); + + hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop2, &logfont, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + IDWriteGdiInterop_Release(interop2); + IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); +} + +static void test_CreateFontFaceFromHdc(void) +{ + IDWriteGdiInterop *interop; + IDWriteFontFace *fontface; + IDWriteFactory *factory; + HFONT hfont, oldhfont; + LOGFONTW logfont; + HRESULT hr; + HDC hdc; + + factory = create_factory(); + + interop = NULL; + hr = IDWriteFactory_GetGdiInterop(factory, &interop); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteGdiInterop_CreateFontFaceFromHdc(interop, NULL, &fontface); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + memset(&logfont, 0, sizeof(logfont)); + logfont.lfHeight = 12; + logfont.lfWidth = 12; + logfont.lfWeight = FW_NORMAL; + logfont.lfItalic = 1; + lstrcpyW(logfont.lfFaceName, tahomaW); + + hfont = CreateFontIndirectW(&logfont); + hdc = CreateCompatibleDC(0); + oldhfont = SelectObject(hdc, hfont); + + fontface = NULL; + hr = IDWriteGdiInterop_CreateFontFaceFromHdc(interop, hdc, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteFontFace_Release(fontface); + DeleteObject(SelectObject(hdc, oldhfont)); + DeleteDC(hdc); + + IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); +} + +static void test_GetSimulations(void) +{ + DWRITE_FONT_SIMULATIONS simulations; + IDWriteGdiInterop *interop; + IDWriteFontFace *fontface; + IDWriteFactory *factory; + IDWriteFont *font; + LOGFONTW logfont; + HRESULT hr; + + factory = create_factory(); + + hr = IDWriteFactory_GetGdiInterop(factory, &interop); + ok(hr == S_OK, "got 0x%08x\n", hr); + + memset(&logfont, 0, sizeof(logfont)); + logfont.lfHeight = 12; + logfont.lfWidth = 12; + logfont.lfWeight = FW_NORMAL; + logfont.lfItalic = 1; + lstrcpyW(logfont.lfFaceName, tahomaW); + + hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + simulations = IDWriteFont_GetSimulations(font); + ok(simulations == DWRITE_FONT_SIMULATIONS_OBLIQUE, "got %d\n", simulations); + hr = IDWriteFont_CreateFontFace(font, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + simulations = IDWriteFontFace_GetSimulations(fontface); + ok(simulations == DWRITE_FONT_SIMULATIONS_OBLIQUE, "got %d\n", simulations); + IDWriteFontFace_Release(fontface); + IDWriteFont_Release(font); + + memset(&logfont, 0, sizeof(logfont)); + logfont.lfHeight = 12; + logfont.lfWidth = 12; + logfont.lfWeight = FW_NORMAL; + logfont.lfItalic = 0; + lstrcpyW(logfont.lfFaceName, tahomaW); + + hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + simulations = IDWriteFont_GetSimulations(font); + ok(simulations == DWRITE_FONT_SIMULATIONS_NONE, "got %d\n", simulations); + hr = IDWriteFont_CreateFontFace(font, &fontface); + ok(hr == S_OK, "got 0x%08x\n", hr); + simulations = IDWriteFontFace_GetSimulations(fontface); + ok(simulations == DWRITE_FONT_SIMULATIONS_NONE, "got %d\n", simulations); + IDWriteFontFace_Release(fontface); + IDWriteFont_Release(font); + + IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); +} + +static void test_GetFaceNames(void) +{ + static const WCHAR obliqueW[] = {'O','b','l','i','q','u','e',0}; + static const WCHAR enus2W[] = {'e','n','-','U','s',0}; + static const WCHAR enusW[] = {'e','n','-','u','s',0}; + IDWriteLocalizedStrings *strings, *strings2; + IDWriteGdiInterop *interop; + IDWriteFactory *factory; + UINT32 count, index; + IDWriteFont *font; + LOGFONTW logfont; + WCHAR buffW[255]; + BOOL exists; + HRESULT hr; + + factory = create_factory(); + + hr = IDWriteFactory_GetGdiInterop(factory, &interop); + ok(hr == S_OK, "got 0x%08x\n", hr); + + memset(&logfont, 0, sizeof(logfont)); + logfont.lfHeight = 12; + logfont.lfWidth = 12; + logfont.lfWeight = FW_NORMAL; + logfont.lfItalic = 1; + lstrcpyW(logfont.lfFaceName, tahomaW); + + hr = IDWriteGdiInterop_CreateFontFromLOGFONT(interop, &logfont, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFont_GetFaceNames(font, &strings); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFont_GetFaceNames(font, &strings2); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(strings != strings2, "got %p, %p\n", strings2, strings); + IDWriteLocalizedStrings_Release(strings2); + + count = IDWriteLocalizedStrings_GetCount(strings); + ok(count == 1, "got %d\n", count); + + index = 1; + exists = FALSE; + hr = IDWriteLocalizedStrings_FindLocaleName(strings, enus2W, &index, &exists); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(index == 0 && exists, "got %d, %d\n", index, exists); + + count = 0; + hr = IDWriteLocalizedStrings_GetLocaleNameLength(strings, 1, &count); + ok(hr == E_FAIL, "got 0x%08x\n", hr); + ok(count == ~0, "got %d\n", count); + + /* for simulated faces names are also simulated */ + buffW[0] = 0; + hr = IDWriteLocalizedStrings_GetLocaleName(strings, 0, buffW, sizeof(buffW)/sizeof(WCHAR)); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(!lstrcmpW(buffW, enusW), "got %s\n", wine_dbgstr_w(buffW)); + + buffW[0] = 0; + hr = IDWriteLocalizedStrings_GetString(strings, 0, buffW, sizeof(buffW)/sizeof(WCHAR)); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(!lstrcmpW(buffW, obliqueW), "got %s\n", wine_dbgstr_w(buffW)); + IDWriteLocalizedStrings_Release(strings); + + IDWriteFont_Release(font); + IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); +} + +static void test_TryGetFontTable(void) +{ + const void *table, *table2; + IDWriteFontFace *fontface; + void *context, *context2; + IDWriteFactory *factory; + IDWriteFontFile *file; + BOOL exists; + UINT32 size; + HRESULT hr; + + create_testfontfile(test_fontfile); + + factory = create_factory(); + + hr = IDWriteFactory_CreateFontFileReference(factory, test_fontfile, NULL, &file); + ok(hr == S_OK, "got 0x%08x\n",hr); + + hr = IDWriteFactory_CreateFontFace(factory, DWRITE_FONT_FACE_TYPE_TRUETYPE, 1, &file, 0, 0, &fontface); + ok(hr == S_OK, "got 0x%08x\n",hr); + + exists = FALSE; + context = (void*)0xdeadbeef; + table = NULL; + hr = IDWriteFontFace_TryGetFontTable(fontface, MS_CMAP_TAG, &table, &size, &context, &exists); + ok(hr == S_OK, "got 0x%08x\n",hr); + ok(exists == TRUE, "got %d\n", exists); +todo_wine + ok(context == NULL && table != NULL, "cmap: context %p, table %p\n", context, table); + + exists = FALSE; + context2 = (void*)0xdeadbeef; + table2 = NULL; + hr = IDWriteFontFace_TryGetFontTable(fontface, MS_CMAP_TAG, &table2, &size, &context2, &exists); + ok(hr == S_OK, "got 0x%08x\n",hr); + ok(exists == TRUE, "got %d\n", exists); +todo_wine + ok(context2 == context && table2 == table, "cmap: context2 %p, table2 %p\n", context2, table2); + + IDWriteFontFace_ReleaseFontTable(fontface, context2); + IDWriteFontFace_ReleaseFontTable(fontface, context); + + IDWriteFontFace_Release(fontface); + IDWriteFontFile_Release(file); + IDWriteFactory_Release(factory); + DeleteFileW(test_fontfile); +} + +static void test_ConvertFontToLOGFONT(void) +{ + IDWriteFactory *factory, *factory2; + IDWriteFontCollection *collection; + IDWriteGdiInterop *interop; + IDWriteFontFamily *family; + IDWriteFont *font; + LOGFONTW logfont; + BOOL system; + HRESULT hr; + + factory = create_factory(); + factory2 = create_factory(); + + interop = NULL; + hr = IDWriteFactory_GetGdiInterop(factory, &interop); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFactory_GetSystemFontCollection(factory2, &collection, FALSE); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontCollection_GetFontFamily(collection, 0, &family); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFontFamily_GetFirstMatchingFont(family, DWRITE_FONT_WEIGHT_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, DWRITE_FONT_STYLE_NORMAL, &font); + ok(hr == S_OK, "got 0x%08x\n", hr); + +if (0) { /* crashes on native */ + IDWriteGdiInterop_ConvertFontToLOGFONT(interop, NULL, NULL, NULL); + IDWriteGdiInterop_ConvertFontToLOGFONT(interop, NULL, &logfont, NULL); + IDWriteGdiInterop_ConvertFontToLOGFONT(interop, font, NULL, &system); +} + system = TRUE; + hr = IDWriteGdiInterop_ConvertFontToLOGFONT(interop, NULL, &logfont, &system); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + ok(!system, "got %d\n", system); + + system = FALSE; + memset(&logfont, 0, sizeof(logfont)); + hr = IDWriteGdiInterop_ConvertFontToLOGFONT(interop, font, &logfont, &system); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(system, "got %d\n", system); + ok(logfont.lfFaceName[0] != 0, "got face name %s\n", wine_dbgstr_w(logfont.lfFaceName)); + + IDWriteFactory_Release(factory2); + + IDWriteFontCollection_Release(collection); + IDWriteFontFamily_Release(family); + IDWriteFont_Release(font); + IDWriteGdiInterop_Release(interop); + IDWriteFactory_Release(factory); +} + +START_TEST(font) +{ + IDWriteFactory *factory; + + if (!(factory = create_factory())) { win_skip("failed to create factory\n"); return; } @@ -1060,8 +2338,19 @@ test_system_fontcollection(); test_ConvertFontFaceToLOGFONT(); test_CustomFontCollection(); - test_FontLoader(); + test_CreateCustomFontFileReference(); test_CreateFontFileReference(); + test_shared_isolated(); + test_GetUnicodeRanges(); + test_GetFontFromFontFace(); + test_GetFirstMatchingFont(); + test_GetInformationalStrings(); + test_GetGdiInterop(); + test_CreateFontFaceFromHdc(); + test_GetSimulations(); + test_GetFaceNames(); + test_TryGetFontTable(); + test_ConvertFontToLOGFONT(); IDWriteFactory_Release(factory); } diff -Nru wine1.7-1.7.28/dlls/dwrite/tests/layout.c wine1.7-1.7.31/dlls/dwrite/tests/layout.c --- wine1.7-1.7.28/dlls/dwrite/tests/layout.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/tests/layout.c 2014-11-14 13:28:17.000000000 +0000 @@ -1,7 +1,7 @@ /* * Text layout/format tests * - * Copyright 2012 Nikolay Sivov for CodeWeavers + * Copyright 2012, 2014 Nikolay Sivov for CodeWeavers * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -309,7 +309,9 @@ static void test_CreateTextLayout(void) { static const WCHAR strW[] = {'s','t','r','i','n','g',0}; + IDWriteTextLayout2 *layout2; IDWriteTextLayout *layout; + IDWriteTextFormat *format; HRESULT hr; hr = IDWriteFactory_CreateTextLayout(factory, NULL, 0, NULL, 0.0, 0.0, &layout); @@ -326,6 +328,42 @@ hr = IDWriteFactory_CreateTextLayout(factory, strW, 6, NULL, 1000.0, 1000.0, &layout); ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + hr = IDWriteFactory_CreateTextFormat(factory, tahomaW, NULL, DWRITE_FONT_WEIGHT_NORMAL, DWRITE_FONT_STYLE_NORMAL, + DWRITE_FONT_STRETCH_NORMAL, 10.0, enusW, &format); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteFactory_CreateTextLayout(factory, strW, 6, format, 1000.0, 1000.0, &layout); + ok(hr == S_OK, "got 0x%08x\n", hr); + + hr = IDWriteTextLayout_QueryInterface(layout, &IID_IDWriteTextLayout2, (void**)&layout2); + if (hr == S_OK) { + IDWriteTextLayout1 *layout1; + IDWriteTextFormat1 *format1; + + hr = IDWriteTextLayout2_QueryInterface(layout2, &IID_IDWriteTextLayout1, (void**)&layout1); + ok(hr == S_OK, "got 0x%08x\n", hr); + IDWriteTextLayout1_Release(layout1); + + hr = IDWriteTextLayout2_QueryInterface(layout2, &IID_IDWriteTextFormat1, (void**)&format1); +todo_wine + ok(hr == S_OK, "got 0x%08x\n", hr); +if (hr == S_OK) + IDWriteTextFormat1_Release(format1); + + hr = IDWriteTextLayout_QueryInterface(layout, &IID_IDWriteTextFormat1, (void**)&format1); +todo_wine + ok(hr == S_OK, "got 0x%08x\n", hr); +if (hr == S_OK) + IDWriteTextFormat1_Release(format1); + + IDWriteTextLayout2_Release(layout2); + } + else + win_skip("IDWriteTextLayout2 is not supported.\n"); + + IDWriteTextLayout_Release(layout); + IDWriteTextFormat_Release(format); } static void test_CreateGdiCompatibleTextLayout(void) @@ -478,7 +516,7 @@ static const WCHAR strW[] = {'s','t','r','i','n','g',0}; static const WCHAR ruW[] = {'r','u',0}; IDWriteTextLayout *layout; - IDWriteTextFormat *format; + IDWriteTextFormat *format, *format2; WCHAR buff[10]; UINT32 len; HRESULT hr; @@ -489,13 +527,17 @@ hr = IDWriteFactory_CreateGdiCompatibleTextLayout(factory, strW, 0, format, 100.0, 100.0, 1.0, NULL, FALSE, &layout); ok(hr == S_OK, "got 0x%08x\n", hr); - len = IDWriteTextLayout_GetLocaleNameLength(layout); + + hr = IDWriteTextLayout_QueryInterface(layout, &IID_IDWriteTextFormat, (void**)&format2); + ok(hr == S_OK, "got 0x%08x\n", hr); + + len = IDWriteTextFormat_GetLocaleNameLength(format2); ok(len == 2, "got %u\n", len); len = IDWriteTextFormat_GetLocaleNameLength(format); ok(len == 2, "got %u\n", len); - hr = IDWriteTextLayout_GetLocaleName(layout, buff, len); + hr = IDWriteTextFormat_GetLocaleName(format2, buff, len); ok(hr == E_NOT_SUFFICIENT_BUFFER, "got 0x%08x\n", hr); - hr = IDWriteTextLayout_GetLocaleName(layout, buff, len+1); + hr = IDWriteTextFormat_GetLocaleName(format2, buff, len+1); ok(hr == S_OK, "got 0x%08x\n", hr); ok(!lstrcmpW(buff, ruW), "got %s\n", wine_dbgstr_w(buff)); hr = IDWriteTextFormat_GetLocaleName(format, buff, len); @@ -506,6 +548,7 @@ IDWriteTextLayout_Release(layout); IDWriteTextFormat_Release(format); + IDWriteTextFormat_Release(format2); } static void test_CreateEllipsisTrimmingSign(void) @@ -545,6 +588,7 @@ IDWriteTextLayout *layout; DWRITE_FONT_WEIGHT weight; DWRITE_TEXT_RANGE range; + FLOAT size; HRESULT hr; hr = IDWriteFactory_CreateTextFormat(factory, tahomaW, NULL, DWRITE_FONT_WEIGHT_BOLD, DWRITE_FONT_STYLE_NORMAL, @@ -571,11 +615,53 @@ range.length = 0; weight = DWRITE_FONT_WEIGHT_BOLD; - hr = layout->lpVtbl->IDWriteTextLayout_GetFontWeight(layout, 0, &weight, &range); + hr = IDWriteTextLayout_GetFontWeight(layout, 0, &weight, &range); ok(hr == S_OK, "got 0x%08x\n", hr); ok(weight == DWRITE_FONT_WEIGHT_NORMAL, "got %d\n", weight); ok(range.length == 6, "got %d\n", range.length); + size = IDWriteTextLayout_GetMaxWidth(layout); + ok(size == 100.0, "got %.2f\n", size); + + hr = IDWriteTextLayout_SetMaxWidth(layout, 0.0); + ok(hr == S_OK, "got 0x%08x\n", hr); + + size = IDWriteTextLayout_GetMaxWidth(layout); + ok(size == 0.0, "got %.2f\n", size); + + hr = IDWriteTextLayout_SetMaxWidth(layout, -1.0); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + size = IDWriteTextLayout_GetMaxWidth(layout); + ok(size == 0.0, "got %.2f\n", size); + + hr = IDWriteTextLayout_SetMaxWidth(layout, 100.0); + ok(hr == S_OK, "got 0x%08x\n", hr); + + size = IDWriteTextLayout_GetMaxWidth(layout); + ok(size == 100.0, "got %.2f\n", size); + + size = IDWriteTextLayout_GetMaxHeight(layout); + ok(size == 100.0, "got %.2f\n", size); + + hr = IDWriteTextLayout_SetMaxHeight(layout, 0.0); + ok(hr == S_OK, "got 0x%08x\n", hr); + + size = IDWriteTextLayout_GetMaxHeight(layout); + ok(size == 0.0, "got %.2f\n", size); + + hr = IDWriteTextLayout_SetMaxHeight(layout, -1.0); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + size = IDWriteTextLayout_GetMaxHeight(layout); + ok(size == 0.0, "got %.2f\n", size); + + hr = IDWriteTextLayout_SetMaxHeight(layout, 100.0); + ok(hr == S_OK, "got 0x%08x\n", hr); + + size = IDWriteTextLayout_GetMaxHeight(layout); + ok(size == 100.0, "got %.2f\n", size); + IDWriteTextLayout_Release(layout); IDWriteTextFormat_Release(fmt2); IDWriteTextFormat_Release(format); diff -Nru wine1.7-1.7.28/dlls/dwrite/tests/Makefile.in wine1.7-1.7.31/dlls/dwrite/tests/Makefile.in --- wine1.7-1.7.28/dlls/dwrite/tests/Makefile.in 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/dwrite/tests/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -1,5 +1,5 @@ TESTDLL = dwrite.dll -IMPORTS = dwrite gdi32 +IMPORTS = dwrite gdi32 user32 C_SRCS = \ analyzer.c \ diff -Nru wine1.7-1.7.28/dlls/fusion/asmname.c wine1.7-1.7.31/dlls/fusion/asmname.c --- wine1.7-1.7.28/dlls/fusion/asmname.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/fusion/asmname.c 2014-11-14 13:28:17.000000000 +0000 @@ -497,7 +497,7 @@ if (*len <= buffer_size) lstrcpyW(buf, name->path); else - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; return S_OK; } diff -Nru wine1.7-1.7.28/dlls/fusion/fusion.c wine1.7-1.7.31/dlls/fusion/fusion.c --- wine1.7-1.7.28/dlls/fusion/fusion.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/fusion/fusion.c 2014-11-14 13:28:17.000000000 +0000 @@ -161,7 +161,7 @@ len++; if (*pcchPath <= len || !pwzCachePath) - hr = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + hr = E_NOT_SUFFICIENT_BUFFER; else if (pwzCachePath) strcpyW(pwzCachePath, path); diff -Nru wine1.7-1.7.28/dlls/fusion/tests/asmcache.c wine1.7-1.7.31/dlls/fusion/tests/asmcache.c --- wine1.7-1.7.28/dlls/fusion/tests/asmcache.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/fusion/tests/asmcache.c 2014-11-14 13:28:17.000000000 +0000 @@ -1235,8 +1235,7 @@ "Expected ASSEMBLYINFO_FLAG_INSTALLED, got %08x\n", info.dwAssemblyFlags); ok(info.uliAssemblySizeInKB.u.HighPart == 0, "Expected 0, got %d\n", info.uliAssemblySizeInKB.u.HighPart); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), - "Expected HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), got %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "Expected E_NOT_SUFFICIENT_BUFFER, got %08x\n", hr); todo_wine { ok((info.uliAssemblySizeInKB.u.LowPart == 4), @@ -1258,8 +1257,7 @@ "Expected 0, got %d\n", info.uliAssemblySizeInKB.u.HighPart); ok(!lstrcmpW(info.pszCurrentAssemblyPathBuf, empty), "Assembly path was changed\n"); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), - "Expected HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), got %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "Expected E_NOT_SUFFICIENT_BUFFER, got %08x\n", hr); todo_wine { ok((info.uliAssemblySizeInKB.u.LowPart == 4), @@ -1321,7 +1319,7 @@ lstrcatW(name, otherver); hr = IAssemblyCache_QueryAssemblyInfo(cache, QUERYASMINFO_FLAG_VALIDATE, name, &info); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), "got %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "got %08x\n", hr); ok(info.dwAssemblyFlags == ASSEMBLYINFO_FLAG_INSTALLED, "got %08x\n", info.dwAssemblyFlags); /* short buffer, QUERYASMINFO_FLAG_GETSIZE */ @@ -1331,7 +1329,7 @@ lstrcatW(name, otherver); hr = IAssemblyCache_QueryAssemblyInfo(cache, QUERYASMINFO_FLAG_GETSIZE, name, &info); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), "got %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "got %08x\n", hr); ok(info.dwAssemblyFlags == ASSEMBLYINFO_FLAG_INSTALLED, "got %08x\n", info.dwAssemblyFlags); /* display name is "wine, Version=1.0.0.00000" */ @@ -1525,8 +1523,7 @@ lstrcatW(name, commasep); lstrcatW(name, ver); hr = IAssemblyCache_QueryAssemblyInfo(cache, 0, name, &info); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), - "Expected HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), got %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "Expected E_NOT_SUFFICIENT_BUFFER, got %08x\n", hr); ok(info.cbAssemblyInfo == sizeof(ASSEMBLY_INFO), "Expected sizeof(ASSEMBLY_INFO), got %d\n", info.cbAssemblyInfo); ok(info.dwAssemblyFlags == ASSEMBLYINFO_FLAG_INSTALLED, diff -Nru wine1.7-1.7.28/dlls/fusion/tests/asmname.c wine1.7-1.7.31/dlls/fusion/tests/asmname.c --- wine1.7-1.7.28/dlls/fusion/tests/asmname.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/fusion/tests/asmname.c 2014-11-14 13:28:17.000000000 +0000 @@ -425,7 +425,7 @@ str[0] = '\0'; hr = IAssemblyName_GetName(name, &size, str); ok(hr == S_OK, "Expected S_OK, got %08x\n", hr); - ok(lstrlenW(str) == 0, "Expected empty name\n"); + ok(!str[0], "Expected empty name\n"); ok(size == 0, "Expected 0, got %d\n", size); hi = 0xbeefcace; @@ -461,7 +461,7 @@ str[0] = '\0'; hr = IAssemblyName_GetName(name, &size, str); ok(hr == S_OK, "Expected S_OK, got %08x\n", hr); - ok(lstrlenW(str) == 0, "Expected empty name\n"); + ok(!str[0], "Expected empty name\n"); ok(size == 1, "Expected 1, got %d\n", size); hi = 0xbeefcace; diff -Nru wine1.7-1.7.28/dlls/fusion/tests/fusion.c wine1.7-1.7.31/dlls/fusion/tests/fusion.c --- wine1.7-1.7.28/dlls/fusion/tests/fusion.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/fusion/tests/fusion.c 2014-11-14 13:28:17.000000000 +0000 @@ -98,16 +98,14 @@ /* NULL pwzCachePath, pcchPath is 0 */ size = 0; hr = pGetCachePath(ASM_CACHE_GAC, NULL, &size); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), - "Expected HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), got %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "Expected E_NOT_SUFFICIENT_BUFFER, got %08x\n", hr); ok(size == lstrlenW(cachepath) + 1, "Expected %d, got %d\n", lstrlenW(cachepath) + 1, size); /* NULL pwszCachePath, pcchPath is MAX_PATH */ size = MAX_PATH; hr = pGetCachePath(ASM_CACHE_GAC, NULL, &size); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), - "Expected HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), got %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "Expected E_NOT_SUFFICIENT_BUFFER, got %08x\n", hr); ok(size == lstrlenW(cachepath) + 1, "Expected %d, got %d\n", lstrlenW(cachepath) + 1, size); @@ -132,8 +130,7 @@ lstrcpyW(path, nochange); size = lstrlenW(cachepath); hr = pGetCachePath(ASM_CACHE_GAC, path, &size); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), - "Expected HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), got %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "Expected E_NOT_SUFFICIENT_BUFFER, got %08x\n", hr); ok( !lstrcmpW( nochange, path ), "Expected %s, got %s\n", wine_dbgstr_w(nochange), wine_dbgstr_w(path)); lstrcpyW(cachepath, windir); diff -Nru wine1.7-1.7.28/dlls/gameux/gameexplorer.c wine1.7-1.7.31/dlls/gameux/gameexplorer.c --- wine1.7-1.7.28/dlls/gameux/gameexplorer.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gameux/gameexplorer.c 2014-11-14 13:28:17.000000000 +0000 @@ -35,9 +35,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(gameux); -/* function from Shell32, not defined in header */ -extern BOOL WINAPI GUIDFromStringW(LPCWSTR psz, LPGUID pguid); - /******************************************************************************* * GameUX helper functions */ @@ -325,67 +322,58 @@ * GameData [O] structure where data loaded from * XML element will be stored in */ -static HRESULT GAMEUX_ParseGameDefinition( - IXMLDOMElement *gdElement, - struct GAMEUX_GAME_DATA *GameData) +static HRESULT GAMEUX_ParseGameDefinition(IXMLDOMElement *gamedef, struct GAMEUX_GAME_DATA *game_data) { - static const WCHAR sGameId[] = {'g','a','m','e','I','D',0}; - - HRESULT hr = S_OK; - BSTR bstrAttribute; - VARIANT variant; - IXMLDOMNodeList *childrenList; - IXMLDOMNode *nextNode; - IXMLDOMElement *nextElement; + static const WCHAR gameidW[] = {'g','a','m','e','I','D',0}; + IXMLDOMNodeList *props; + VARIANT var; + HRESULT hr; + BSTR attr; - TRACE("(%p, %p)\n", gdElement, GameData); + TRACE("(%p, %p)\n", gamedef, game_data); - bstrAttribute = SysAllocString(sGameId); - if(!bstrAttribute) - hr = E_OUTOFMEMORY; + attr = SysAllocString(gameidW); + if (!attr) + return E_OUTOFMEMORY; - hr = IXMLDOMElement_getAttribute(gdElement, bstrAttribute, &variant); + hr = IXMLDOMElement_getAttribute(gamedef, attr, &var); + SysFreeString(attr); - if(SUCCEEDED(hr)) + if (SUCCEEDED(hr)) { - hr = ( GUIDFromStringW(V_BSTR(&variant), &GameData->guidApplicationId)==TRUE ? S_OK : E_FAIL); - - SysFreeString(V_BSTR(&variant)); + hr = CLSIDFromString(V_BSTR(&var), &game_data->guidApplicationId); + VariantClear(&var); } - SysFreeString(bstrAttribute); + if (SUCCEEDED(hr)) + hr = IXMLDOMElement_get_childNodes(gamedef, &props); - /* browse subnodes */ - if(SUCCEEDED(hr)) - hr = IXMLDOMElement_get_childNodes(gdElement, &childrenList); + if (FAILED(hr)) + return hr; - if(SUCCEEDED(hr)) + do { - do + IXMLDOMNode *prop; + + hr = IXMLDOMNodeList_nextNode(props, &prop); + if (hr == S_OK) { - hr = IXMLDOMNodeList_nextNode(childrenList, &nextNode); + IXMLDOMElement *element; - if(hr == S_OK) + hr = IXMLDOMNode_QueryInterface(prop, &IID_IXMLDOMElement, (void**)&element); + if (hr == S_OK) { - hr = IXMLDOMNode_QueryInterface(nextNode, &IID_IXMLDOMElement, - (LPVOID*)&nextElement); - - if(SUCCEEDED(hr)) - { - hr = GAMEUX_ProcessGameDefinitionElement(nextElement, GameData); - IXMLDOMElement_Release(nextElement); - } - - IXMLDOMNode_Release(nextNode); + hr = GAMEUX_ProcessGameDefinitionElement(element, game_data); + IXMLDOMElement_Release(element); } - } - while(hr == S_OK); - hr = S_OK; - IXMLDOMNodeList_Release(childrenList); + IXMLDOMNode_Release(prop); + } } + while (hr == S_OK); + IXMLDOMNodeList_Release(props); - return hr; + return FAILED(hr) ? hr : S_OK; } struct parse_gdf_thread_param @@ -789,7 +777,7 @@ if(lstrcmpW(lpValue, sGDFBinaryPath)==0) { /* key found, let's copy instance id and exit */ - hr = (GUIDFromStringW(lpName, pInstanceId) ? S_OK : E_FAIL); + hr = CLSIDFromString(lpName, pInstanceId); found = TRUE; } HeapFree(GetProcessHeap(), 0, lpValue); diff -Nru wine1.7-1.7.28/dlls/gameux/gamestatistics.c wine1.7-1.7.31/dlls/gameux/gamestatistics.c --- wine1.7-1.7.28/dlls/gameux/gamestatistics.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gameux/gamestatistics.c 2014-11-14 13:28:17.000000000 +0000 @@ -180,7 +180,7 @@ { IXMLDOMElement *categoryElement = NULL; - if(lstrlenW(stats->categories[i].sName)==0) + if(!stats->categories[i].sName[0]) continue; V_VT(&vValue) = VT_INT; @@ -218,7 +218,7 @@ { for(j=0; jcategories[i].stats[j].sName)==0) + if(!stats->categories[i].stats[j].sName[0]) continue; V_VT(&vValue) = VT_INT; diff -Nru wine1.7-1.7.28/dlls/gameux/tests/gameexplorer.c wine1.7-1.7.31/dlls/gameux/tests/gameexplorer.c --- wine1.7-1.7.28/dlls/gameux/tests/gameexplorer.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gameux/tests/gameexplorer.c 2014-11-14 13:28:17.000000000 +0000 @@ -33,9 +33,6 @@ #include "wine/test.h" -/* function from Shell32, not defined in header */ -extern BOOL WINAPI GUIDFromStringW(LPCWSTR psz, LPGUID pguid); - /******************************************************************************* * Pointers used instead of direct calls. These procedures are not available on * older system, which causes problem while loading test binary. @@ -476,7 +473,7 @@ if(lstrcmpW(lpValue, sGDFBinaryPath)==0) { /* key found, let's copy instance id and exit */ - hr = (GUIDFromStringW(lpName, pInstanceId) ? S_OK : E_FAIL); + hr = CLSIDFromString(lpName, pInstanceId); ok(SUCCEEDED(hr), "cannot convert subkey to guid: %s\n", wine_dbgstr_w(lpName)); diff -Nru wine1.7-1.7.28/dlls/gdi32/dibdrv/objects.c wine1.7-1.7.31/dlls/gdi32/dibdrv/objects.c --- wine1.7-1.7.28/dlls/gdi32/dibdrv/objects.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gdi32/dibdrv/objects.c 2014-11-14 13:28:17.000000000 +0000 @@ -1815,6 +1815,8 @@ size -= 4; } + if (!rop_needs_and_mask( brush->rop )) brush->masks.and = NULL; /* ignore the and mask */ + return TRUE; } @@ -1861,6 +1863,9 @@ brush->dib.funcs->create_rop_masks( &brush->dib, hatches[brush->hatch], &fg_mask, &bg_mask, &brush->masks ); + + if (!fg_mask.and && !bg_mask.and) brush->masks.and = NULL; /* ignore the and mask */ + return TRUE; } @@ -1878,6 +1883,9 @@ rgb = make_rgb_colorref( pdev->dev.hdc, &pdev->dib, brush->colorref, &got_pixel, &pixel ); brush->dib.funcs->create_dither_masks( &brush->dib, brush->rop, rgb, &brush->masks ); + + if (!rop_needs_and_mask( brush->rop )) brush->masks.and = NULL; /* ignore the and mask */ + return TRUE; } @@ -2018,7 +2026,6 @@ ERR("Unexpected brush style %d\n", brush->style); return FALSE; } - if (!rop_needs_and_mask( brush->rop )) brush->masks.and = NULL; /* ignore the and mask */ } GetBrushOrgEx(pdev->dev.hdc, &origin); diff -Nru wine1.7-1.7.28/dlls/gdi32/enhmetafile.c wine1.7-1.7.31/dlls/gdi32/enhmetafile.c --- wine1.7-1.7.28/dlls/gdi32/enhmetafile.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gdi32/enhmetafile.c 2014-11-14 13:28:17.000000000 +0000 @@ -1416,7 +1416,7 @@ if ((info->state.mode != MM_ISOTROPIC) && (info->state.mode != MM_ANISOTROPIC)) break; if (!lpScaleWindowExtEx->xNum || !lpScaleWindowExtEx->xDenom || - !lpScaleWindowExtEx->xNum || !lpScaleWindowExtEx->yDenom) + !lpScaleWindowExtEx->yNum || !lpScaleWindowExtEx->yDenom) break; info->state.wndExtX = MulDiv(info->state.wndExtX, lpScaleWindowExtEx->xNum, lpScaleWindowExtEx->xDenom); diff -Nru wine1.7-1.7.28/dlls/gdi32/freetype.c wine1.7-1.7.31/dlls/gdi32/freetype.c --- wine1.7-1.7.28/dlls/gdi32/freetype.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gdi32/freetype.c 2014-11-14 13:28:17.000000000 +0000 @@ -6189,6 +6189,203 @@ return (orientation == 1 || orientation == 3); } +static unsigned int get_native_glyph_outline(FT_Outline *outline, unsigned int buflen, char *buf) +{ + TTPOLYGONHEADER *pph; + TTPOLYCURVE *ppc; + unsigned int needed = 0, point = 0, contour, first_pt; + unsigned int pph_start, cpfx; + DWORD type; + + for (contour = 0; contour < outline->n_contours; contour++) + { + /* Ignore contours containing one point */ + if (point == outline->contours[contour]) + { + point++; + continue; + } + + pph_start = needed; + pph = (TTPOLYGONHEADER *)(buf + needed); + first_pt = point; + if (buf) + { + pph->dwType = TT_POLYGON_TYPE; + FTVectorToPOINTFX(&outline->points[point], &pph->pfxStart); + } + needed += sizeof(*pph); + point++; + while (point <= outline->contours[contour]) + { + ppc = (TTPOLYCURVE *)(buf + needed); + type = outline->tags[point] & FT_Curve_Tag_On ? + TT_PRIM_LINE : TT_PRIM_QSPLINE; + cpfx = 0; + do + { + if (buf) + FTVectorToPOINTFX(&outline->points[point], &ppc->apfx[cpfx]); + cpfx++; + point++; + } while (point <= outline->contours[contour] && + (outline->tags[point] & FT_Curve_Tag_On) == + (outline->tags[point-1] & FT_Curve_Tag_On)); + /* At the end of a contour Windows adds the start point, but + only for Beziers */ + if (point > outline->contours[contour] && + !(outline->tags[point-1] & FT_Curve_Tag_On)) + { + if (buf) + FTVectorToPOINTFX(&outline->points[first_pt], &ppc->apfx[cpfx]); + cpfx++; + } + else if (point <= outline->contours[contour] && + outline->tags[point] & FT_Curve_Tag_On) + { + /* add closing pt for bezier */ + if (buf) + FTVectorToPOINTFX(&outline->points[point], &ppc->apfx[cpfx]); + cpfx++; + point++; + } + if (buf) + { + ppc->wType = type; + ppc->cpfx = cpfx; + } + needed += sizeof(*ppc) + (cpfx - 1) * sizeof(POINTFX); + } + if (buf) + pph->cb = needed - pph_start; + } + return needed; +} + +static unsigned int get_bezier_glyph_outline(FT_Outline *outline, unsigned int buflen, char *buf) +{ + /* Convert the quadratic Beziers to cubic Beziers. + The parametric eqn for a cubic Bezier is, from PLRM: + r(t) = at^3 + bt^2 + ct + r0 + with the control points: + r1 = r0 + c/3 + r2 = r1 + (c + b)/3 + r3 = r0 + c + b + a + + A quadratic Bezier has the form: + p(t) = (1-t)^2 p0 + 2(1-t)t p1 + t^2 p2 + + So equating powers of t leads to: + r1 = 2/3 p1 + 1/3 p0 + r2 = 2/3 p1 + 1/3 p2 + and of course r0 = p0, r3 = p2 + */ + int contour, point = 0, first_pt; + TTPOLYGONHEADER *pph; + TTPOLYCURVE *ppc; + DWORD pph_start, cpfx, type; + FT_Vector cubic_control[4]; + unsigned int needed = 0; + + for (contour = 0; contour < outline->n_contours; contour++) + { + pph_start = needed; + pph = (TTPOLYGONHEADER *)(buf + needed); + first_pt = point; + if (buf) + { + pph->dwType = TT_POLYGON_TYPE; + FTVectorToPOINTFX(&outline->points[point], &pph->pfxStart); + } + needed += sizeof(*pph); + point++; + while (point <= outline->contours[contour]) + { + ppc = (TTPOLYCURVE *)(buf + needed); + type = outline->tags[point] & FT_Curve_Tag_On ? + TT_PRIM_LINE : TT_PRIM_CSPLINE; + cpfx = 0; + do + { + if (type == TT_PRIM_LINE) + { + if (buf) + FTVectorToPOINTFX(&outline->points[point], &ppc->apfx[cpfx]); + cpfx++; + point++; + } + else + { + /* Unlike QSPLINEs, CSPLINEs always have their endpoint + so cpfx = 3n */ + + /* FIXME: Possible optimization in endpoint calculation + if there are two consecutive curves */ + cubic_control[0] = outline->points[point-1]; + if (!(outline->tags[point-1] & FT_Curve_Tag_On)) + { + cubic_control[0].x += outline->points[point].x + 1; + cubic_control[0].y += outline->points[point].y + 1; + cubic_control[0].x >>= 1; + cubic_control[0].y >>= 1; + } + if (point+1 > outline->contours[contour]) + cubic_control[3] = outline->points[first_pt]; + else + { + cubic_control[3] = outline->points[point+1]; + if (!(outline->tags[point+1] & FT_Curve_Tag_On)) + { + cubic_control[3].x += outline->points[point].x + 1; + cubic_control[3].y += outline->points[point].y + 1; + cubic_control[3].x >>= 1; + cubic_control[3].y >>= 1; + } + } + /* r1 = 1/3 p0 + 2/3 p1 + r2 = 1/3 p2 + 2/3 p1 */ + cubic_control[1].x = (2 * outline->points[point].x + 1) / 3; + cubic_control[1].y = (2 * outline->points[point].y + 1) / 3; + cubic_control[2] = cubic_control[1]; + cubic_control[1].x += (cubic_control[0].x + 1) / 3; + cubic_control[1].y += (cubic_control[0].y + 1) / 3; + cubic_control[2].x += (cubic_control[3].x + 1) / 3; + cubic_control[2].y += (cubic_control[3].y + 1) / 3; + if (buf) + { + FTVectorToPOINTFX(&cubic_control[1], &ppc->apfx[cpfx]); + FTVectorToPOINTFX(&cubic_control[2], &ppc->apfx[cpfx+1]); + FTVectorToPOINTFX(&cubic_control[3], &ppc->apfx[cpfx+2]); + } + cpfx += 3; + point++; + } + } while (point <= outline->contours[contour] && + (outline->tags[point] & FT_Curve_Tag_On) == + (outline->tags[point-1] & FT_Curve_Tag_On)); + /* At the end of a contour Windows adds the start point, + but only for Beziers and we've already done that. + */ + if (point <= outline->contours[contour] && + outline->tags[point] & FT_Curve_Tag_On) + { + /* This is the closing pt of a bezier, but we've already + added it, so just inc point and carry on */ + point++; + } + if (buf) + { + ppc->wType = type; + ppc->cpfx = cpfx; + } + needed += sizeof(*ppc) + (cpfx - 1) * sizeof(POINTFX); + } + if (buf) + pph->cb = needed - pph_start; + } + return needed; +} + static const BYTE masks[8] = {0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x01}; static DWORD get_glyph_outline(GdiFont *incoming_font, UINT glyph, UINT format, @@ -6583,6 +6780,8 @@ if(!buf || !buflen) break; if (!needed) return GDI_ERROR; /* empty glyph */ + if (needed > buflen) + return GDI_ERROR; switch(ft_face->glyph->format) { case ft_glyph_format_bitmap: @@ -6634,6 +6833,8 @@ if(!buf || !buflen) break; if (!needed) return GDI_ERROR; /* empty glyph */ + if (needed > buflen) + return GDI_ERROR; max_level = get_max_level( format ); @@ -6706,6 +6907,8 @@ if (!buf || !buflen) break; if (!needed) return GDI_ERROR; /* empty glyph */ + if (needed > buflen) + return GDI_ERROR; memset(buf, 0, buflen); dst = buf; @@ -6734,7 +6937,6 @@ INT x, src_pitch, src_width, src_height, rgb_interval, hmul, vmul; INT x_shift, y_shift; BOOL rgb; - FT_LcdFilter lcdfilter = FT_LCD_FILTER_DEFAULT; FT_Render_Mode render_mode = (format == WINE_GGO_HRGB_BITMAP || format == WINE_GGO_HBGR_BITMAP)? FT_RENDER_MODE_LCD: FT_RENDER_MODE_LCD_V; @@ -6745,20 +6947,17 @@ return GDI_ERROR; } - if ( lcdfilter == FT_LCD_FILTER_DEFAULT || lcdfilter == FT_LCD_FILTER_LIGHT ) + if ( render_mode == FT_RENDER_MODE_LCD) { - if ( render_mode == FT_RENDER_MODE_LCD) - { - gm.gmBlackBoxX += 2; - gm.gmptGlyphOrigin.x -= 1; - left -= (1 << 6); - } - else - { - gm.gmBlackBoxY += 2; - gm.gmptGlyphOrigin.y += 1; - top += (1 << 6); - } + gm.gmBlackBoxX += 2; + gm.gmptGlyphOrigin.x -= 1; + left -= (1 << 6); + } + else + { + gm.gmBlackBoxY += 2; + gm.gmptGlyphOrigin.y += 1; + top += (1 << 6); } width = gm.gmBlackBoxX; @@ -6767,6 +6966,8 @@ needed = pitch * height; if (!buf || !buflen) break; + if (needed > buflen) + return GDI_ERROR; memset(buf, 0, buflen); dst = buf; @@ -6776,7 +6977,7 @@ pFT_Outline_Transform (&ft_face->glyph->outline, &transMatTategaki); if ( pFT_Library_SetLcdFilter ) - pFT_Library_SetLcdFilter( library, lcdfilter ); + pFT_Library_SetLcdFilter( library, FT_LCD_FILTER_DEFAULT ); pFT_Render_Glyph (ft_face->glyph, render_mode); src = ft_face->glyph->bitmap.buffer; @@ -6863,188 +7064,40 @@ case GGO_NATIVE: { - int contour, point = 0, first_pt; - FT_Outline *outline = &ft_face->glyph->outline; - TTPOLYGONHEADER *pph; - TTPOLYCURVE *ppc; - DWORD pph_start, cpfx, type; + FT_Outline *outline = &ft_face->glyph->outline; - if(buflen == 0) buf = NULL; + if(buflen == 0) buf = NULL; - if (needsTransform && buf) { - pFT_Outline_Transform(outline, &transMatTategaki); - } + if (needsTransform && buf) + pFT_Outline_Transform(outline, &transMatTategaki); - for(contour = 0; contour < outline->n_contours; contour++) { - /* Ignore contours containing one point */ - if(point == outline->contours[contour]) { - point++; - continue; - } + needed = get_native_glyph_outline(outline, buflen, NULL); - pph_start = needed; - pph = (TTPOLYGONHEADER *)((char *)buf + needed); - first_pt = point; - if(buf) { - pph->dwType = TT_POLYGON_TYPE; - FTVectorToPOINTFX(&outline->points[point], &pph->pfxStart); - } - needed += sizeof(*pph); - point++; - while(point <= outline->contours[contour]) { - ppc = (TTPOLYCURVE *)((char *)buf + needed); - type = (outline->tags[point] & FT_Curve_Tag_On) ? - TT_PRIM_LINE : TT_PRIM_QSPLINE; - cpfx = 0; - do { - if(buf) - FTVectorToPOINTFX(&outline->points[point], &ppc->apfx[cpfx]); - cpfx++; - point++; - } while(point <= outline->contours[contour] && - (outline->tags[point] & FT_Curve_Tag_On) == - (outline->tags[point-1] & FT_Curve_Tag_On)); - /* At the end of a contour Windows adds the start point, but - only for Beziers */ - if(point > outline->contours[contour] && - !(outline->tags[point-1] & FT_Curve_Tag_On)) { - if(buf) - FTVectorToPOINTFX(&outline->points[first_pt], &ppc->apfx[cpfx]); - cpfx++; - } else if(point <= outline->contours[contour] && - outline->tags[point] & FT_Curve_Tag_On) { - /* add closing pt for bezier */ - if(buf) - FTVectorToPOINTFX(&outline->points[point], &ppc->apfx[cpfx]); - cpfx++; - point++; - } - if(buf) { - ppc->wType = type; - ppc->cpfx = cpfx; - } - needed += sizeof(*ppc) + (cpfx - 1) * sizeof(POINTFX); - } - if(buf) - pph->cb = needed - pph_start; - } - break; + if (!buf || !buflen) + break; + if (needed > buflen) + return GDI_ERROR; + + get_native_glyph_outline(outline, buflen, buf); + break; } case GGO_BEZIER: { - /* Convert the quadratic Beziers to cubic Beziers. - The parametric eqn for a cubic Bezier is, from PLRM: - r(t) = at^3 + bt^2 + ct + r0 - with the control points: - r1 = r0 + c/3 - r2 = r1 + (c + b)/3 - r3 = r0 + c + b + a - - A quadratic Bezier has the form: - p(t) = (1-t)^2 p0 + 2(1-t)t p1 + t^2 p2 - - So equating powers of t leads to: - r1 = 2/3 p1 + 1/3 p0 - r2 = 2/3 p1 + 1/3 p2 - and of course r0 = p0, r3 = p2 - */ - - int contour, point = 0, first_pt; - FT_Outline *outline = &ft_face->glyph->outline; - TTPOLYGONHEADER *pph; - TTPOLYCURVE *ppc; - DWORD pph_start, cpfx, type; - FT_Vector cubic_control[4]; - if(buflen == 0) buf = NULL; + FT_Outline *outline = &ft_face->glyph->outline; + if(buflen == 0) buf = NULL; - if (needsTransform && buf) { + if (needsTransform && buf) pFT_Outline_Transform(outline, &transMat); - } - for(contour = 0; contour < outline->n_contours; contour++) { - pph_start = needed; - pph = (TTPOLYGONHEADER *)((char *)buf + needed); - first_pt = point; - if(buf) { - pph->dwType = TT_POLYGON_TYPE; - FTVectorToPOINTFX(&outline->points[point], &pph->pfxStart); - } - needed += sizeof(*pph); - point++; - while(point <= outline->contours[contour]) { - ppc = (TTPOLYCURVE *)((char *)buf + needed); - type = (outline->tags[point] & FT_Curve_Tag_On) ? - TT_PRIM_LINE : TT_PRIM_CSPLINE; - cpfx = 0; - do { - if(type == TT_PRIM_LINE) { - if(buf) - FTVectorToPOINTFX(&outline->points[point], &ppc->apfx[cpfx]); - cpfx++; - point++; - } else { - /* Unlike QSPLINEs, CSPLINEs always have their endpoint - so cpfx = 3n */ - - /* FIXME: Possible optimization in endpoint calculation - if there are two consecutive curves */ - cubic_control[0] = outline->points[point-1]; - if(!(outline->tags[point-1] & FT_Curve_Tag_On)) { - cubic_control[0].x += outline->points[point].x + 1; - cubic_control[0].y += outline->points[point].y + 1; - cubic_control[0].x >>= 1; - cubic_control[0].y >>= 1; - } - if(point+1 > outline->contours[contour]) - cubic_control[3] = outline->points[first_pt]; - else { - cubic_control[3] = outline->points[point+1]; - if(!(outline->tags[point+1] & FT_Curve_Tag_On)) { - cubic_control[3].x += outline->points[point].x + 1; - cubic_control[3].y += outline->points[point].y + 1; - cubic_control[3].x >>= 1; - cubic_control[3].y >>= 1; - } - } - /* r1 = 1/3 p0 + 2/3 p1 - r2 = 1/3 p2 + 2/3 p1 */ - cubic_control[1].x = (2 * outline->points[point].x + 1) / 3; - cubic_control[1].y = (2 * outline->points[point].y + 1) / 3; - cubic_control[2] = cubic_control[1]; - cubic_control[1].x += (cubic_control[0].x + 1) / 3; - cubic_control[1].y += (cubic_control[0].y + 1) / 3; - cubic_control[2].x += (cubic_control[3].x + 1) / 3; - cubic_control[2].y += (cubic_control[3].y + 1) / 3; - if(buf) { - FTVectorToPOINTFX(&cubic_control[1], &ppc->apfx[cpfx]); - FTVectorToPOINTFX(&cubic_control[2], &ppc->apfx[cpfx+1]); - FTVectorToPOINTFX(&cubic_control[3], &ppc->apfx[cpfx+2]); - } - cpfx += 3; - point++; - } - } while(point <= outline->contours[contour] && - (outline->tags[point] & FT_Curve_Tag_On) == - (outline->tags[point-1] & FT_Curve_Tag_On)); - /* At the end of a contour Windows adds the start point, - but only for Beziers and we've already done that. - */ - if(point <= outline->contours[contour] && - outline->tags[point] & FT_Curve_Tag_On) { - /* This is the closing pt of a bezier, but we've already - added it, so just inc point and carry on */ - point++; - } - if(buf) { - ppc->wType = type; - ppc->cpfx = cpfx; - } - needed += sizeof(*ppc) + (cpfx - 1) * sizeof(POINTFX); - } - if(buf) - pph->cb = needed - pph_start; - } - break; + needed = get_bezier_glyph_outline(outline, buflen, NULL); + + if (!buf || !buflen) + break; + if (needed > buflen) + return GDI_ERROR; + + get_bezier_glyph_outline(outline, buflen, buf); + break; } default: diff -Nru wine1.7-1.7.28/dlls/gdi32/tests/clipping.c wine1.7-1.7.31/dlls/gdi32/tests/clipping.c --- wine1.7-1.7.28/dlls/gdi32/tests/clipping.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gdi32/tests/clipping.c 2014-11-14 13:28:17.000000000 +0000 @@ -184,11 +184,12 @@ { static const RECT empty_rect; static const RECT rc = { 111, 222, 333, 444 }; + static const RECT arc[2] = { {0, 0, 10, 10}, {10, 10, 20, 20}}; static const RECT rc_xformed = { 76, 151, 187, 262 }; union { RGNDATA data; - char buf[sizeof(RGNDATAHEADER) + sizeof(RECT)]; + char buf[sizeof(RGNDATAHEADER) + 2 * sizeof(RECT)]; } rgn; HRGN hrgn; XFORM xform; @@ -224,6 +225,20 @@ rgn.data.rdh.iType = RDH_RECTANGLES; rgn.data.rdh.dwSize = sizeof(rgn.data.rdh); + /* sizeof(RGNDATAHEADER) is large enough */ + SetLastError(0xdeadbeef); + hrgn = ExtCreateRegion(NULL, sizeof(RGNDATAHEADER), &rgn.data); + ok(hrgn != 0, "ExtCreateRegion error %u\n", GetLastError()); + verify_region(hrgn, &empty_rect); + DeleteObject(hrgn); + + /* Cannot be smaller than sizeof(RGNDATAHEADER) */ + SetLastError(0xdeadbeef); + hrgn = ExtCreateRegion(NULL, sizeof(RGNDATAHEADER) - 1, &rgn.data); + todo_wine + ok(!hrgn, "ExtCreateRegion should fail\n"); + ok(GetLastError() == 0xdeadbeef, "0xdeadbeef, got %u\n", GetLastError()); + SetLastError(0xdeadbeef); hrgn = ExtCreateRegion(NULL, sizeof(rgn), &rgn.data); ok(hrgn != 0, "ExtCreateRegion error %u\n", GetLastError()); @@ -234,6 +249,13 @@ SetRectEmpty(&rgn.data.rdh.rcBound); memcpy(rgn.data.Buffer, &rc, sizeof(rc)); + /* With a single rect this seems to work... */ + SetLastError(0xdeadbeef); + hrgn = ExtCreateRegion(NULL, sizeof(RGNDATAHEADER) + sizeof(RECT) - 1, &rgn.data); + ok(hrgn != 0, "ExtCreateRegion error %u\n", GetLastError()); + verify_region(hrgn, &rc); + DeleteObject(hrgn); + SetLastError(0xdeadbeef); hrgn = ExtCreateRegion(NULL, sizeof(rgn), &rgn.data); ok(hrgn != 0, "ExtCreateRegion error %u\n", GetLastError()); @@ -267,6 +289,18 @@ ok(hrgn != 0, "ExtCreateRegion error %u/%x\n", GetLastError(), GetLastError()); verify_region(hrgn, &rc_xformed); DeleteObject(hrgn); + + rgn.data.rdh.nCount = 2; + SetRectEmpty(&rgn.data.rdh.rcBound); + memcpy(rgn.data.Buffer, arc, sizeof(arc)); + + /* Buffer cannot be smaller than sizeof(RGNDATAHEADER) + 2 * sizeof(RECT) */ + SetLastError(0xdeadbeef); + hrgn = ExtCreateRegion(NULL, sizeof(RGNDATAHEADER) + 2 * sizeof(RECT) - 1, &rgn.data); + todo_wine + ok(!hrgn, "ExtCreateRegion should fail\n"); + ok(GetLastError() == 0xdeadbeef, "0xdeadbeef, got %u\n", GetLastError()); + } static void test_GetClipRgn(void) diff -Nru wine1.7-1.7.28/dlls/gdi32/tests/font.c wine1.7-1.7.31/dlls/gdi32/tests/font.c --- wine1.7-1.7.28/dlls/gdi32/tests/font.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gdi32/tests/font.c 2014-11-14 13:28:17.000000000 +0000 @@ -4365,7 +4365,11 @@ SetLastError(0xdeadbeef); ret = GetGlyphOutlineW(hdc, ' ', GGO_NATIVE, &gm, 0, NULL, &mat); if (GetLastError() != ERROR_CALL_NOT_IMPLEMENTED) + { ok(ret == 0, "GetGlyphOutlineW should return 0 buffer size for space char\n"); + ok(gm.gmBlackBoxX == 1, "Expected 1, got %u\n", gm.gmBlackBoxX); + ok(gm.gmBlackBoxY == 1, "Expected 1, got %u\n", gm.gmBlackBoxY); + } /* requesting buffer size for space char + error */ memset(&gm, 0, sizeof(gm)); @@ -4375,8 +4379,16 @@ { ok(ret == GDI_ERROR, "GetGlyphOutlineW should return GDI_ERROR\n"); ok(GetLastError() == 0xdeadbeef, "expected 0xdeadbeef, got %u\n", GetLastError()); + ok(gm.gmBlackBoxX == 0, "Expected 0, got %u\n", gm.gmBlackBoxX); + ok(gm.gmBlackBoxY == 0, "Expected 0, got %u\n", gm.gmBlackBoxY); } + /* test GetGlyphOutline with a buffer too small */ + SetLastError(0xdeadbeef); + ret = GetGlyphOutlineA(hdc, 'A', GGO_NATIVE, &gm, sizeof(i), &i, &mat); + if (GetLastError() != ERROR_CALL_NOT_IMPLEMENTED) + ok(ret == GDI_ERROR, "GetGlyphOutlineW should return an error when the buffer size is too small.\n"); + for (i = 0; i < sizeof(fmt) / sizeof(fmt[0]); ++i) { DWORD dummy; diff -Nru wine1.7-1.7.28/dlls/gdiplus/graphics.c wine1.7-1.7.31/dlls/gdiplus/graphics.c --- wine1.7-1.7.28/dlls/gdiplus/graphics.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gdiplus/graphics.c 2014-11-14 13:28:17.000000000 +0000 @@ -827,6 +827,10 @@ right = bitmap->width-1; if (bottom >= bitmap->height) bottom = bitmap->height-1; + if (bottom < top || right < left) + /* entirely outside image, just sample a pixel so we don't have to + * special-case this later */ + left = top = right = bottom = 0; } else { @@ -1779,7 +1783,7 @@ for(i = 1; i < count; i++){ if((types[i] & PathPointTypePathTypeMask) == PathPointTypeBezier){ if((i + 2 >= count) || !(types[i + 1] & PathPointTypeBezier) - || !(types[i + 1] & PathPointTypeBezier)){ + || !(types[i + 2] & PathPointTypeBezier)){ ERR("Bad bezier points\n"); goto end; } diff -Nru wine1.7-1.7.28/dlls/gdiplus/image.c wine1.7-1.7.31/dlls/gdiplus/image.c --- wine1.7-1.7.28/dlls/gdiplus/image.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gdiplus/image.c 2014-11-14 13:28:17.000000000 +0000 @@ -1483,6 +1483,18 @@ return stat; } +static inline DWORD blend_argb_no_bkgnd_alpha(DWORD src, DWORD bkgnd) +{ + BYTE b = (BYTE)src; + BYTE g = (BYTE)(src >> 8); + BYTE r = (BYTE)(src >> 16); + DWORD alpha = (BYTE)(src >> 24); + return ((b + ((BYTE)bkgnd * (255 - alpha) + 127) / 255) | + (g + ((BYTE)(bkgnd >> 8) * (255 - alpha) + 127) / 255) << 8 | + (r + ((BYTE)(bkgnd >> 16) * (255 - alpha) + 127) / 255) << 16 | + (alpha << 24)); +} + GpStatus WINGDIPAPI GdipCreateHBITMAPFromBitmap(GpBitmap* bitmap, HBITMAP* hbmReturn, ARGB background) { @@ -1523,6 +1535,17 @@ if (stat == Ok) stat = GdipBitmapUnlockBits(bitmap, &lockeddata); + + if (stat == Ok && (background & 0xffffff)) + { + DWORD *ptr; + UINT i; + for (ptr = (DWORD*)bits, i = 0; i < width * height; ptr++, i++) + { + if ((*ptr & 0xff000000) == 0xff000000) continue; + *ptr = blend_argb_no_bkgnd_alpha(*ptr, background); + } + } } else stat = GenericError; diff -Nru wine1.7-1.7.28/dlls/gdiplus/tests/image.c wine1.7-1.7.31/dlls/gdiplus/tests/image.c --- wine1.7-1.7.28/dlls/gdiplus/tests/image.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/gdiplus/tests/image.c 2014-11-14 13:28:17.000000000 +0000 @@ -1695,6 +1695,10 @@ stat = GdipDisposeImage((GpImage*)bitmap); expect(Ok, stat); + /* make (1,0) have no alpha and (2,0) a different blue value. */ + bits[7] = 0x00; + bits[8] = 0x40; + /* create alpha Bitmap */ stat = GdipCreateBitmapFromScan0(8, 20, 32, PixelFormat32bppARGB, bits, &bitmap); expect(Ok, stat); @@ -1720,21 +1724,106 @@ { DWORD val = *(DWORD*)bm.bmBits; ok(val == 0x682a2a2a, "got %x, expected 0x682a2a2a\n", val); + val = *((DWORD*)bm.bmBits + (bm.bmHeight-1) * bm.bmWidthBytes/4 + 1); + ok(val == 0x0, "got %x, expected 0x682a2a2a\n", val); } hdc = CreateCompatibleDC(NULL); oldhbitmap = SelectObject(hdc, hbitmap); pixel = GetPixel(hdc, 5, 5); + expect(0x2a2a2a, pixel); + pixel = GetPixel(hdc, 1, 0); + expect(0x0, pixel); + SelectObject(hdc, oldhbitmap); DeleteDC(hdc); - expect(0x2a2a2a, pixel); DeleteObject(hbitmap); } + /* create HBITMAP with bkgnd colour */ + stat = GdipCreateHBITMAPFromBitmap(bitmap, &hbitmap, 0xff00ff); + expect(Ok, stat); + + if (stat == Ok) + { + ret = GetObjectA(hbitmap, sizeof(BITMAP), &bm); + expect(sizeof(BITMAP), ret); + + expect(0, bm.bmType); + expect(8, bm.bmWidth); + expect(20, bm.bmHeight); + expect(32, bm.bmWidthBytes); + expect(1, bm.bmPlanes); + expect(32, bm.bmBitsPixel); + ok(bm.bmBits != NULL, "got DDB, expected DIB\n"); + + if (bm.bmBits) + { + DWORD val = *(DWORD*)bm.bmBits; + ok(val == 0x68c12ac1, "got %x, expected 0x682a2a2a\n", val); + val = *((DWORD*)bm.bmBits + (bm.bmHeight-1) * bm.bmWidthBytes/4 + 1); + ok(val == 0xff00ff, "got %x, expected 0x682a2a2a\n", val); + } + + hdc = CreateCompatibleDC(NULL); + + oldhbitmap = SelectObject(hdc, hbitmap); + pixel = GetPixel(hdc, 5, 5); + expect(0xc12ac1, pixel); + pixel = GetPixel(hdc, 1, 0); + expect(0xff00ff, pixel); + pixel = GetPixel(hdc, 2, 0); + expect(0xb12ac1, pixel); + + SelectObject(hdc, oldhbitmap); + DeleteDC(hdc); + DeleteObject(hbitmap); + } + + /* create HBITMAP with bkgnd colour with alpha and show it behaves with no alpha. */ + stat = GdipCreateHBITMAPFromBitmap(bitmap, &hbitmap, 0x80ff00ff); + expect(Ok, stat); + + if (stat == Ok) + { + ret = GetObjectA(hbitmap, sizeof(BITMAP), &bm); + expect(sizeof(BITMAP), ret); + + expect(0, bm.bmType); + expect(8, bm.bmWidth); + expect(20, bm.bmHeight); + expect(32, bm.bmWidthBytes); + expect(1, bm.bmPlanes); + expect(32, bm.bmBitsPixel); + ok(bm.bmBits != NULL, "got DDB, expected DIB\n"); + + if (bm.bmBits) + { + DWORD val = *(DWORD*)bm.bmBits; + ok(val == 0x68c12ac1, "got %x, expected 0x682a2a2a\n", val); + val = *((DWORD*)bm.bmBits + (bm.bmHeight-1) * bm.bmWidthBytes/4 + 1); + ok(val == 0xff00ff, "got %x, expected 0x682a2a2a\n", val); + } + + hdc = CreateCompatibleDC(NULL); + + oldhbitmap = SelectObject(hdc, hbitmap); + pixel = GetPixel(hdc, 5, 5); + expect(0xc12ac1, pixel); + pixel = GetPixel(hdc, 1, 0); + expect(0xff00ff, pixel); + pixel = GetPixel(hdc, 2, 0); + expect(0xb12ac1, pixel); + + SelectObject(hdc, oldhbitmap); + DeleteDC(hdc); + DeleteObject(hbitmap); + } + stat = GdipDisposeImage((GpImage*)bitmap); expect(Ok, stat); } diff -Nru wine1.7-1.7.28/dlls/ieframe/client.c wine1.7-1.7.31/dlls/ieframe/client.c --- wine1.7-1.7.28/dlls/ieframe/client.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ieframe/client.c 2014-11-14 13:28:17.000000000 +0000 @@ -297,7 +297,7 @@ TRACE("(%p)->(%p, %x)\n", This, pfNoRedraw, dwFlags); /* FIXME: Avoid redraw, when possible */ - pfNoRedraw = FALSE; + *pfNoRedraw = FALSE; if (dwFlags) { FIXME("dwFlags not supported (%x)\n", dwFlags); diff -Nru wine1.7-1.7.28/dlls/ieframe/oleobject.c wine1.7-1.7.31/dlls/ieframe/oleobject.c --- wine1.7-1.7.28/dlls/ieframe/oleobject.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ieframe/oleobject.c 2014-11-14 13:28:17.000000000 +0000 @@ -292,8 +292,8 @@ typedef struct { IEnumOLEVERB IEnumOLEVERB_iface; - LONG ref; + LONG iter; } EnumOLEVERB; static inline EnumOLEVERB *impl_from_IEnumOLEVERB(IEnumOLEVERB *iface) @@ -348,10 +348,20 @@ { EnumOLEVERB *This = impl_from_IEnumOLEVERB(iface); + static const OLEVERB verbs[] = + {{OLEIVERB_PRIMARY},{OLEIVERB_INPLACEACTIVATE},{OLEIVERB_UIACTIVATE},{OLEIVERB_SHOW},{OLEIVERB_HIDE}}; + TRACE("(%p)->(%u %p %p)\n", This, celt, rgelt, pceltFetched); + /* There are a few problems with this implementation, but that's how it seems to work in native. See tests. */ if(pceltFetched) *pceltFetched = 0; + + if(This->iter == sizeof(verbs)/sizeof(*verbs)) + return S_FALSE; + + if(celt) + *rgelt = verbs[This->iter++]; return S_OK; } @@ -365,7 +375,10 @@ static HRESULT WINAPI EnumOLEVERB_Reset(IEnumOLEVERB *iface) { EnumOLEVERB *This = impl_from_IEnumOLEVERB(iface); + TRACE("(%p)\n", This); + + This->iter = 0; return S_OK; } @@ -599,6 +612,7 @@ ret->IEnumOLEVERB_iface.lpVtbl = &EnumOLEVERBVtbl; ret->ref = 1; + ret->iter = 0; *ppEnumOleVerb = &ret->IEnumOLEVERB_iface; return S_OK; diff -Nru wine1.7-1.7.28/dlls/ieframe/tests/webbrowser.c wine1.7-1.7.31/dlls/ieframe/tests/webbrowser.c --- wine1.7-1.7.28/dlls/ieframe/tests/webbrowser.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ieframe/tests/webbrowser.c 2014-11-14 13:28:17.000000000 +0000 @@ -456,6 +456,8 @@ case 144: /* TODO */ case 178: /* IE11 */ case 179: /* IE11 */ + case 180: /* IE11 */ + case 181: /* IE11 */ return E_FAIL; default: ok(0, "unexpected nCmdID %d\n", nCmdID); @@ -1995,6 +1997,30 @@ IProvideClassInfo2_Release(class_info); } +#define expect_oleverb(a,b) _expect_oleverb(__LINE__,a,b) +static void _expect_oleverb(unsigned line, const OLEVERB *verb, LONG exverb) +{ + ok_(__FILE__,line)(verb->lVerb == exverb, "verb->lVerb = %d, expected %d\n", verb->lVerb, exverb); + ok_(__FILE__,line)(!verb->lpszVerbName, "verb->lpszVerbName = %s\n", wine_dbgstr_w(verb->lpszVerbName)); + ok_(__FILE__,line)(!verb->fuFlags, "verb->fuFlags = %x\n", verb->fuFlags); + ok_(__FILE__,line)(!verb->grfAttribs, "verb->grfAttribs = %x\n", verb->grfAttribs); +} + +#define test_next_oleverb(a,b) _test_next_oleverb(__LINE__,a,b) +static void _test_next_oleverb(unsigned line, IEnumOLEVERB *enum_verbs, LONG exverb) +{ + ULONG fetched = 0xdeadbeef; + OLEVERB verb; + HRESULT hres; + + fetched = 0xdeadbeef; + memset(&verb, 0xa, sizeof(verb)); + hres = IEnumOLEVERB_Next(enum_verbs, 1, &verb, &fetched); + ok_(__FILE__,line)(hres == S_OK, "Next failed: %08x\n", hres); + ok_(__FILE__,line)(!fetched, "fetched = %d\n", fetched); + _expect_oleverb(line, &verb, exverb); +} + static void test_EnumVerbs(IWebBrowser2 *wb) { IEnumOLEVERB *enum_verbs; @@ -2012,13 +2038,32 @@ ok(enum_verbs != NULL, "enum_verbs == NULL\n"); fetched = 0xdeadbeef; + memset(verbs, 0xa, sizeof(verbs)); + verbs[1].lVerb = 0xdeadbeef; hres = IEnumOLEVERB_Next(enum_verbs, sizeof(verbs)/sizeof(*verbs), verbs, &fetched); ok(hres == S_OK, "Next failed: %08x\n", hres); ok(!fetched, "fetched = %d\n", fetched); + /* Although fetched==0, an element is returned. */ + expect_oleverb(verbs, OLEIVERB_PRIMARY); + /* The first argument is ignorred and always one element is returned. */ + ok(verbs[1].lVerb == 0xdeadbeef, "verbs[1].lVerb = %x\n", verbs[1].lVerb); + + test_next_oleverb(enum_verbs, OLEIVERB_INPLACEACTIVATE); + test_next_oleverb(enum_verbs, OLEIVERB_UIACTIVATE); + test_next_oleverb(enum_verbs, OLEIVERB_SHOW); + test_next_oleverb(enum_verbs, OLEIVERB_HIDE); + /* There is anouther verb, returned correctly. */ fetched = 0xdeadbeef; - hres = IEnumOLEVERB_Next(enum_verbs, 1, verbs, &fetched); - ok(hres == S_OK, "Next failed: %08x\n", hres); + memset(verbs, 0xa, sizeof(verbs)); + verbs[0].lVerb = 0xdeadbeef; + hres = IEnumOLEVERB_Next(enum_verbs, sizeof(verbs)/sizeof(*verbs), verbs, &fetched); + todo_wine ok(hres == S_OK, "Next failed: %08x\n", hres); + todo_wine ok(fetched == 1, "fetched = %d\n", fetched); + todo_wine ok(verbs[0].lVerb != 0xdeadbeef, "verbs[0].lVerb = %x\n", verbs[0].lVerb); + + hres = IEnumOLEVERB_Next(enum_verbs, sizeof(verbs)/sizeof(*verbs), verbs, &fetched); + ok(hres == S_FALSE, "Next failed: %08x\n", hres); ok(!fetched, "fetched = %d\n", fetched); hres = IEnumOLEVERB_Reset(enum_verbs); @@ -2040,6 +2085,8 @@ ok(hres == S_OK, "Next failed: %08x\n", hres); ok(!fetched, "fetched = %d\n", fetched); + test_next_oleverb(enum_verbs, OLEIVERB_SHOW); + IEnumOLEVERB_Release(enum_verbs); } @@ -2274,6 +2321,10 @@ ok(sName!=NULL, "get_Name return a NULL string.\n"); SysFreeString(sName); + /* RegisterAsDropTarget */ + hres = IWebBrowser2_get_RegisterAsDropTarget(wb, NULL); + ok(hres == E_INVALIDARG, "get_RegisterAsDropTarget returned: %08x\n", hres); + /* Quit */ hres = IWebBrowser2_Quit(wb); diff -Nru wine1.7-1.7.28/dlls/ieframe/webbrowser.c wine1.7-1.7.31/dlls/ieframe/webbrowser.c --- wine1.7-1.7.28/dlls/ieframe/webbrowser.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ieframe/webbrowser.c 2014-11-14 13:28:17.000000000 +0000 @@ -943,7 +943,12 @@ VARIANT_BOOL *pbRegister) { WebBrowser *This = impl_from_IWebBrowser2(iface); + FIXME("(%p)->(%p)\n", This, pbRegister); + + if(!pbRegister) + return E_INVALIDARG; + *pbRegister=0; return S_OK; } diff -Nru wine1.7-1.7.28/dlls/imm32/imm32.spec wine1.7-1.7.31/dlls/imm32/imm32.spec --- wine1.7-1.7.28/dlls/imm32/imm32.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/imm32/imm32.spec 2014-11-14 13:28:17.000000000 +0000 @@ -110,3 +110,7 @@ @ stub ImmWINNLSEnableIME @ stub ImmWINNLSGetEnableStatus @ stub ImmWINNLSGetIMEHotkey + +################################################################ +# Wine internal extensions +@ stdcall __wine_get_ui_window(ptr) diff -Nru wine1.7-1.7.28/dlls/imm32/imm.c wine1.7-1.7.31/dlls/imm32/imm.c --- wine1.7-1.7.28/dlls/imm32/imm.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/imm32/imm.c 2014-11-14 13:28:17.000000000 +0000 @@ -37,6 +37,9 @@ WINE_DEFAULT_DEBUG_CHANNEL(imm); +#define IMM_INIT_MAGIC 0x19650412 +BOOL WINAPI User32InitializeImmEntryTable(DWORD); + #define MAKE_FUNCPTR(f) typeof(f) * p##f typedef struct _tagImmHkl{ struct list entry; @@ -93,15 +96,6 @@ static DWORD tlsIndex = 0; static struct list ImmHklList = LIST_INIT(ImmHklList); -/* MSIME messages */ -static UINT WM_MSIME_SERVICE; -static UINT WM_MSIME_RECONVERTOPTIONS; -static UINT WM_MSIME_MOUSE; -static UINT WM_MSIME_RECONVERTREQUEST; -static UINT WM_MSIME_RECONVERT; -static UINT WM_MSIME_QUERYPOSITION; -static UINT WM_MSIME_DOCUMENTFEED; - static const WCHAR szwWineIMCProperty[] = {'W','i','n','e','I','m','m','H','I','M','C','P','r','o','p','e','r','t','y',0}; static const WCHAR szImeFileW[] = {'I','m','e',' ','F','i','l','e',0}; @@ -110,9 +104,6 @@ static const WCHAR szwIME[] = {'I','M','E',0}; -static LRESULT WINAPI DefIME_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, - LPARAM lParam); - #define is_himc_ime_unicode(p) (p->immKbd->imeInfo.fdwProperty & IME_PROP_UNICODE) #define is_kbd_ime_unicode(p) (p->imeInfo.fdwProperty & IME_PROP_UNICODE) @@ -347,6 +338,12 @@ } #undef LOAD_FUNCPTR +HWND WINAPI __wine_get_ui_window(HKL hkl) +{ + ImmHkl *immHkl = IMM_GetImmHkl(hkl); + return immHkl->UIWnd; +} + static void IMM_FreeAllImmHkl(void) { ImmHkl *ptr,*cursor2; @@ -365,43 +362,20 @@ } } -static void IMM_RegisterMessages(void) -{ - WM_MSIME_SERVICE = RegisterWindowMessageA("MSIMEService"); - WM_MSIME_RECONVERTOPTIONS = RegisterWindowMessageA("MSIMEReconvertOptions"); - WM_MSIME_MOUSE = RegisterWindowMessageA("MSIMEMouseOperation"); - WM_MSIME_RECONVERTREQUEST = RegisterWindowMessageA("MSIMEReconvertRequest"); - WM_MSIME_RECONVERT = RegisterWindowMessageA("MSIMEReconvert"); - WM_MSIME_QUERYPOSITION = RegisterWindowMessageA("MSIMEQueryPosition"); - WM_MSIME_DOCUMENTFEED = RegisterWindowMessageA("MSIMEDocumentFeed"); -} - -static void IMM_RegisterIMEClass(void) -{ - WNDCLASSW wndClass; - - ZeroMemory(&wndClass, sizeof(WNDCLASSW)); - - wndClass.style = CS_GLOBALCLASS; - wndClass.lpfnWndProc = (WNDPROC) DefIME_WindowProc; - wndClass.cbWndExtra = 2 * sizeof(LONG_PTR); - wndClass.hCursor = LoadCursorW(NULL, (LPWSTR)IDC_ARROW); - wndClass.lpszClassName = szwIME; - - RegisterClassW(&wndClass); -} - BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpReserved) { TRACE("%p, %x, %p\n",hInstDLL,fdwReason,lpReserved); switch (fdwReason) { case DLL_PROCESS_ATTACH: - IMM_RegisterMessages(); tlsIndex = TlsAlloc(); if (tlsIndex == TLS_OUT_OF_INDEXES) return FALSE; - IMM_RegisterIMEClass(); + if (!User32InitializeImmEntryTable(IMM_INIT_MAGIC)) + { + TlsFree(tlsIndex); + return FALSE; + } break; case DLL_THREAD_ATTACH: break; @@ -413,7 +387,6 @@ IMM_FreeThreadData(); IMM_FreeAllImmHkl(); TlsFree(tlsIndex); - UnregisterClassW(szwIME, NULL); break; } return TRUE; @@ -1945,28 +1918,20 @@ BOOL WINAPI ImmIsUIMessageA( HWND hWndIME, UINT msg, WPARAM wParam, LPARAM lParam) { - BOOL rc = FALSE; - TRACE("(%p, %x, %ld, %ld)\n", hWndIME, msg, wParam, lParam); if ((msg >= WM_IME_STARTCOMPOSITION && msg <= WM_IME_KEYLAST) || (msg == WM_IME_SETCONTEXT) || (msg == WM_IME_NOTIFY) || (msg == WM_IME_COMPOSITIONFULL) || (msg == WM_IME_SELECT) || - (msg == 0x287 /* FIXME: WM_IME_SYSTEM */) || - (msg == WM_MSIME_RECONVERTOPTIONS) || - (msg == WM_MSIME_MOUSE) || - (msg == WM_MSIME_RECONVERTREQUEST) || - (msg == WM_MSIME_RECONVERT) || - (msg == WM_MSIME_QUERYPOSITION) || - (msg == WM_MSIME_DOCUMENTFEED)) + (msg == 0x287 /* FIXME: WM_IME_SYSTEM */)) { if (hWndIME) SendMessageA(hWndIME, msg, wParam, lParam); - rc = TRUE; + return TRUE; } - return rc; + return FALSE; } /*********************************************************************** @@ -1975,28 +1940,20 @@ BOOL WINAPI ImmIsUIMessageW( HWND hWndIME, UINT msg, WPARAM wParam, LPARAM lParam) { - BOOL rc = FALSE; - TRACE("(%p, %x, %ld, %ld)\n", hWndIME, msg, wParam, lParam); if ((msg >= WM_IME_STARTCOMPOSITION && msg <= WM_IME_KEYLAST) || (msg == WM_IME_SETCONTEXT) || (msg == WM_IME_NOTIFY) || (msg == WM_IME_COMPOSITIONFULL) || (msg == WM_IME_SELECT) || - (msg == 0x287 /* FIXME: WM_IME_SYSTEM */) || - (msg == WM_MSIME_RECONVERTOPTIONS) || - (msg == WM_MSIME_MOUSE) || - (msg == WM_MSIME_RECONVERTREQUEST) || - (msg == WM_MSIME_RECONVERT) || - (msg == WM_MSIME_QUERYPOSITION) || - (msg == WM_MSIME_DOCUMENTFEED)) + (msg == 0x287 /* FIXME: WM_IME_SYSTEM */)) { if (hWndIME) SendMessageW(hWndIME, msg, wParam, lParam); - rc = TRUE; + return TRUE; } - return rc; + return FALSE; } /*********************************************************************** @@ -2898,6 +2855,22 @@ else return FALSE; + /* Make sure we are inputting to the correct keyboard */ + if (data->immKbd->hkl != hKL) + { + ImmHkl *new_hkl = IMM_GetImmHkl(hKL); + if (new_hkl) + { + data->immKbd->pImeSelect(imc, FALSE); + data->immKbd->uSelected--; + data->immKbd = new_hkl; + data->immKbd->pImeSelect(imc, TRUE); + data->immKbd->uSelected++; + } + else + return FALSE; + } + if (!data->immKbd->hIME || !data->immKbd->pImeProcessKey) return FALSE; @@ -2940,53 +2913,3 @@ FIXME("%x, %p, %p, %p: stub\n", hotkey, modifiers, key, hkl); return FALSE; } - - -/* - * Window Proc for the Default IME window class - */ -static LRESULT WINAPI DefIME_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, - LPARAM lParam) -{ - switch (uMsg) - { - case WM_CREATE: - case WM_NCCREATE: - return TRUE; - case WM_IME_STARTCOMPOSITION: - case WM_IME_ENDCOMPOSITION: - case WM_IME_COMPOSITION: - case WM_IME_SETCONTEXT: - case WM_IME_NOTIFY: - case WM_IME_CONTROL: - case WM_IME_COMPOSITIONFULL: - case WM_IME_SELECT: - case WM_IME_CHAR: - case WM_IME_REQUEST: - case WM_IME_KEYDOWN: - case WM_IME_KEYUP: - { - ImmHkl *immHkl = IMM_GetImmHkl(GetKeyboardLayout(0)); - if (immHkl->UIWnd) - return SendMessageW(immHkl->UIWnd,uMsg,wParam,lParam); - else - return FALSE; - } - default: - if ((uMsg == WM_MSIME_RECONVERTOPTIONS) || - (uMsg == WM_MSIME_SERVICE) || - (uMsg == WM_MSIME_MOUSE) || - (uMsg == WM_MSIME_RECONVERTREQUEST) || - (uMsg == WM_MSIME_RECONVERT) || - (uMsg == WM_MSIME_QUERYPOSITION) || - (uMsg == WM_MSIME_DOCUMENTFEED)) - { - ImmHkl *immHkl = IMM_GetImmHkl(GetKeyboardLayout(0)); - if (immHkl->UIWnd) - return SendMessageW(immHkl->UIWnd,uMsg,wParam,lParam); - else - return FALSE; - } - return DefWindowProcW(hwnd, uMsg, wParam, lParam); - } -} diff -Nru wine1.7-1.7.28/dlls/imm32/tests/imm32.c wine1.7-1.7.31/dlls/imm32/tests/imm32.c --- wine1.7-1.7.28/dlls/imm32/tests/imm32.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/imm32/tests/imm32.c 2014-11-14 13:28:17.000000000 +0000 @@ -607,6 +607,14 @@ { 0, FALSE } /* mark the end */ }; + UINT WM_MSIME_SERVICE = RegisterWindowMessageA("MSIMEService"); + UINT WM_MSIME_RECONVERTOPTIONS = RegisterWindowMessageA("MSIMEReconvertOptions"); + UINT WM_MSIME_MOUSE = RegisterWindowMessageA("MSIMEMouseOperation"); + UINT WM_MSIME_RECONVERTREQUEST = RegisterWindowMessageA("MSIMEReconvertRequest"); + UINT WM_MSIME_RECONVERT = RegisterWindowMessageA("MSIMEReconvert"); + UINT WM_MSIME_QUERYPOSITION = RegisterWindowMessageA("MSIMEQueryPosition"); + UINT WM_MSIME_DOCUMENTFEED = RegisterWindowMessageA("MSIMEDocumentFeed"); + const struct test *test; BOOL ret; @@ -626,6 +634,21 @@ else ok(!msg_spy_find_msg(test->msg), "Windows does not send 0x%x\n", test->msg); } + + ret = pImmIsUIMessageA(NULL, WM_MSIME_SERVICE, 0, 0); + ok(!ret, "ImmIsUIMessageA returned TRUE for WM_MSIME_SERVICE\n"); + ret = pImmIsUIMessageA(NULL, WM_MSIME_RECONVERTOPTIONS, 0, 0); + ok(!ret, "ImmIsUIMessageA returned TRUE for WM_MSIME_RECONVERTOPTIONS\n"); + ret = pImmIsUIMessageA(NULL, WM_MSIME_MOUSE, 0, 0); + ok(!ret, "ImmIsUIMessageA returned TRUE for WM_MSIME_MOUSE\n"); + ret = pImmIsUIMessageA(NULL, WM_MSIME_RECONVERTREQUEST, 0, 0); + ok(!ret, "ImmIsUIMessageA returned TRUE for WM_MSIME_RECONVERTREQUEST\n"); + ret = pImmIsUIMessageA(NULL, WM_MSIME_RECONVERT, 0, 0); + ok(!ret, "ImmIsUIMessageA returned TRUE for WM_MSIME_RECONVERT\n"); + ret = pImmIsUIMessageA(NULL, WM_MSIME_QUERYPOSITION, 0, 0); + ok(!ret, "ImmIsUIMessageA returned TRUE for WM_MSIME_QUERYPOSITION\n"); + ret = pImmIsUIMessageA(NULL, WM_MSIME_DOCUMENTFEED, 0, 0); + ok(!ret, "ImmIsUIMessageA returned TRUE for WM_MSIME_DOCUMENTFEED\n"); } static void test_ImmGetContext(void) diff -Nru wine1.7-1.7.28/dlls/iphlpapi/iphlpapi_main.c wine1.7-1.7.31/dlls/iphlpapi/iphlpapi_main.c --- wine1.7-1.7.28/dlls/iphlpapi/iphlpapi_main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/iphlpapi/iphlpapi_main.c 2014-11-14 13:28:17.000000000 +0000 @@ -198,6 +198,15 @@ } +/****************************************************************** + * CancelMibChangeNotify2 (IPHLPAPI.@) + */ +DWORD WINAPI CancelMibChangeNotify2(HANDLE handle) +{ + FIXME("(handle %p): stub\n", handle); + return NO_ERROR; +} + /****************************************************************** * CreateIpForwardEntry (IPHLPAPI.@) @@ -983,6 +992,7 @@ struct WS_sockaddr_in6 *sa; const IN6_ADDR *addr, *mask; BOOL done = FALSE; + ULONG k; prefix->u.s.Length = sizeof(*prefix); prefix->u.s.Flags = 0; @@ -1000,11 +1010,11 @@ sa->sin6_scope_id = 0; prefix->PrefixLength = 0; - for (i = 0; i < 8 && !done; i++) + for (k = 0; k < 8 && !done; k++) { for (j = 0; j < sizeof(WORD) * 8 && !done; j++) { - if (mask->u.Word[i] & 1 << j) prefix->PrefixLength++; + if (mask->u.Word[k] & 1 << j) prefix->PrefixLength++; else done = TRUE; } } @@ -1250,7 +1260,7 @@ PIP_ADAPTER_ADDRESSES aa, PULONG buflen) { InterfaceIndexTable *table; - ULONG i, size, dns_server_size, dns_suffix_size, total_size, ret = ERROR_NO_DATA; + ULONG i, size, dns_server_size = 0, dns_suffix_size, total_size, ret = ERROR_NO_DATA; TRACE("(%d, %08x, %p, %p, %p)\n", family, flags, reserved, aa, buflen); @@ -1307,7 +1317,7 @@ size = bytes_left -= size; } } - if (!(flags & GAA_FLAG_SKIP_DNS_SERVER) && dns_server_size) + if (dns_server_size) { firstDns = (PIP_ADAPTER_DNS_SERVER_ADDRESS)((BYTE *)first_aa + total_size - dns_server_size - dns_suffix_size); get_dns_server_addresses(firstDns, &dns_server_size); @@ -2282,6 +2292,19 @@ } +/****************************************************************** + * NotifyIpInterfaceChange (IPHLPAPI.@) + */ +DWORD WINAPI NotifyIpInterfaceChange(ULONG family, PVOID callback, PVOID context, + BOOLEAN init_notify, PHANDLE handle) +{ + FIXME("(family %d, callback %p, context %p, init_notify %d, handle %p): stub\n", + family, callback, context, init_notify, handle); + if (handle) *handle = NULL; + return ERROR_NOT_SUPPORTED; +} + + /****************************************************************** * NotifyRouteChange (IPHLPAPI.@) * diff -Nru wine1.7-1.7.28/dlls/iphlpapi/iphlpapi.spec wine1.7-1.7.31/dlls/iphlpapi/iphlpapi.spec --- wine1.7-1.7.28/dlls/iphlpapi/iphlpapi.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/iphlpapi/iphlpapi.spec 2014-11-14 13:28:17.000000000 +0000 @@ -8,7 +8,7 @@ @ stdcall AllocateAndGetTcpTableFromStack( ptr long long long ) @ stdcall AllocateAndGetUdpTableFromStack( ptr long long long ) @ stdcall CancelIPChangeNotify( ptr ) -#@ stub CancelMibChangeNotify2 +@ stdcall CancelMibChangeNotify2( ptr ) #@ stub ConvertGuidToStringA #@ stub ConvertGuidToStringW #@ stub ConvertInterfaceAliasToLuid @@ -233,7 +233,7 @@ @ stub NhpAllocateAndGetInterfaceInfoFromStack @ stub NhpGetInterfaceIndexFromStack @ stdcall NotifyAddrChange( ptr ptr ) -#@ stub NotifyIpInterfaceChange +@ stdcall NotifyIpInterfaceChange( long ptr ptr long ptr ) @ stdcall NotifyRouteChange( ptr ptr ) #@ stub NotifyRouteChange2 @ stub NotifyRouteChangeEx diff -Nru wine1.7-1.7.28/dlls/jscript/global.c wine1.7-1.7.31/dlls/jscript/global.c --- wine1.7-1.7.28/dlls/jscript/global.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/jscript/global.c 2014-11-14 13:28:17.000000000 +0000 @@ -249,14 +249,6 @@ return constructor_call(ctx->regexp_constr, flags, argc, argv, r); } -static HRESULT JSGlobal_ActiveXObject(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, - jsval_t *r) -{ - TRACE("\n"); - - return constructor_call(ctx->activex_constr, flags, argc, argv, r); -} - static HRESULT JSGlobal_VBArray(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r) { @@ -1087,7 +1079,6 @@ } static const builtin_prop_t JSGlobal_props[] = { - {ActiveXObjectW, JSGlobal_ActiveXObject, PROPF_CONSTR|1}, {ArrayW, JSGlobal_Array, PROPF_CONSTR|1}, {BooleanW, JSGlobal_Boolean, PROPF_CONSTR|1}, {CollectGarbageW, JSGlobal_CollectGarbage, PROPF_METHOD}, @@ -1146,10 +1137,6 @@ if(FAILED(hres)) return hres; - hres = create_activex_constr(ctx, &ctx->activex_constr); - if(FAILED(hres)) - return hres; - hres = create_array_constr(ctx, object_prototype, &ctx->array_constr); if(FAILED(hres)) return hres; @@ -1187,7 +1174,7 @@ HRESULT init_global(script_ctx_t *ctx) { - jsdisp_t *math, *object_prototype; + jsdisp_t *math, *object_prototype, *constr; HRESULT hres; if(ctx->global) @@ -1215,6 +1202,15 @@ if(FAILED(hres)) return hres; + hres = create_activex_constr(ctx, &constr); + if(FAILED(hres)) + return hres; + + hres = jsdisp_propput_dontenum(ctx->global, ActiveXObjectW, jsval_obj(constr)); + jsdisp_release(constr); + if(FAILED(hres)) + return hres; + hres = jsdisp_propput_dontenum(ctx->global, undefinedW, jsval_undefined()); if(FAILED(hres)) return hres; diff -Nru wine1.7-1.7.28/dlls/jscript/jscript.h wine1.7-1.7.31/dlls/jscript/jscript.h --- wine1.7-1.7.28/dlls/jscript/jscript.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/jscript/jscript.h 2014-11-14 13:28:17.000000000 +0000 @@ -395,7 +395,6 @@ jsdisp_t *global; jsdisp_t *function_constr; - jsdisp_t *activex_constr; jsdisp_t *array_constr; jsdisp_t *bool_constr; jsdisp_t *date_constr; diff -Nru wine1.7-1.7.28/dlls/jscript/tests/lang.js wine1.7-1.7.31/dlls/jscript/tests/lang.js --- wine1.7-1.7.28/dlls/jscript/tests/lang.js 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/jscript/tests/lang.js 2014-11-14 13:28:17.000000000 +0000 @@ -1450,6 +1450,9 @@ ok(returnTest() === undefined, "returnTest = " + returnTest()); +ActiveXObject = 1; +ok(ActiveXObject === 1, "ActiveXObject = " + ActiveXObject); + /* Keep this test in the end of file */ undefined = 6; ok(undefined === 6, "undefined = " + undefined); diff -Nru wine1.7-1.7.28/dlls/kernel32/cpu.c wine1.7-1.7.31/dlls/kernel32/cpu.c --- wine1.7-1.7.28/dlls/kernel32/cpu.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/cpu.c 2014-11-14 13:28:17.000000000 +0000 @@ -216,12 +216,74 @@ */ BOOL WINAPI K32GetPerformanceInfo(PPERFORMANCE_INFORMATION info, DWORD size) { + union + { + SYSTEM_PERFORMANCE_INFORMATION performance; + SYSTEM_PROCESS_INFORMATION process; + SYSTEM_BASIC_INFORMATION basic; + } *sysinfo; + SYSTEM_PROCESS_INFORMATION *spi; + DWORD process_info_size; NTSTATUS status; TRACE( "(%p, %d)\n", info, size ); - status = NtQuerySystemInformation( SystemPerformanceInformation, info, size, NULL ); + if (size < sizeof(*info)) + { + SetLastError( ERROR_BAD_LENGTH ); + return FALSE; + } + + memset( info, 0, sizeof(*info) ); + info->cb = sizeof(*info); + + /* fields from SYSTEM_PROCESS_INFORMATION */ + NtQuerySystemInformation( SystemProcessInformation, NULL, 0, &process_info_size ); + for (;;) + { + sysinfo = HeapAlloc( GetProcessHeap(), 0, max(process_info_size, sizeof(*sysinfo)) ); + if (!sysinfo) + { + SetLastError( ERROR_OUTOFMEMORY ); + return FALSE; + } + status = NtQuerySystemInformation( SystemProcessInformation, &sysinfo->process, + process_info_size, &process_info_size ); + if (!status) break; + if (status != STATUS_INFO_LENGTH_MISMATCH) + goto err; + HeapFree( GetProcessHeap(), 0, sysinfo ); + } + for (spi = &sysinfo->process;; spi = (SYSTEM_PROCESS_INFORMATION *)(((PCHAR)spi) + spi->NextEntryOffset)) + { + info->ProcessCount++; + info->HandleCount += spi->HandleCount; + info->ThreadCount += spi->dwThreadCount; + if (spi->NextEntryOffset == 0) break; + } + + /* fields from SYSTEM_PERFORMANCE_INFORMATION */ + status = NtQuerySystemInformation( SystemPerformanceInformation, &sysinfo->performance, + sizeof(sysinfo->performance), NULL ); + if (status) goto err; + info->CommitTotal = sysinfo->performance.TotalCommittedPages; + info->CommitLimit = sysinfo->performance.TotalCommitLimit; + info->CommitPeak = sysinfo->performance.PeakCommitment; + info->PhysicalAvailable = sysinfo->performance.AvailablePages; + info->KernelTotal = sysinfo->performance.PagedPoolUsage + + sysinfo->performance.NonPagedPoolUsage; + info->KernelPaged = sysinfo->performance.PagedPoolUsage; + info->KernelNonpaged = sysinfo->performance.NonPagedPoolUsage; + + /* fields from SYSTEM_BASIC_INFORMATION */ + status = NtQuerySystemInformation( SystemBasicInformation, &sysinfo->basic, + sizeof(sysinfo->basic), NULL ); + if (status) goto err; + info->PhysicalTotal = sysinfo->basic.MmNumberOfPhysicalPages; + info->PageSize = sysinfo->basic.PageSize; +err: + HeapFree( GetProcessHeap(), 0, sysinfo ); if (status) { SetLastError( RtlNtStatusToDosError( status ) ); diff -Nru wine1.7-1.7.28/dlls/kernel32/file.c wine1.7-1.7.31/dlls/kernel32/file.c --- wine1.7-1.7.28/dlls/kernel32/file.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/file.c 2014-11-14 13:28:17.000000000 +0000 @@ -57,6 +57,7 @@ HANDLE handle; /* handle to directory */ CRITICAL_SECTION cs; /* crit section protecting this structure */ FINDEX_SEARCH_OPS search_op; /* Flags passed to FindFirst. */ + FINDEX_INFO_LEVELS level; /* Level passed to FindFirst */ UNICODE_STRING mask; /* file mask */ UNICODE_STRING path; /* NT path used to open the directory */ BOOL is_root; /* is directory the root of the drive? */ @@ -1872,11 +1873,13 @@ if (search_op != FindExSearchNameMatch && search_op != FindExSearchLimitToDirectories) { FIXME("search_op not implemented 0x%08x\n", search_op); + SetLastError( ERROR_INVALID_PARAMETER ); return INVALID_HANDLE_VALUE; } - if (level != FindExInfoStandard) + if (level != FindExInfoStandard && level != FindExInfoBasic) { FIXME("info level %d not implemented\n", level ); + SetLastError( ERROR_INVALID_PARAMETER ); return INVALID_HANDLE_VALUE; } @@ -1977,6 +1980,7 @@ info->data_size = 0; info->data = NULL; info->search_op = search_op; + info->level = level; if (device) { @@ -2139,8 +2143,14 @@ memcpy( data->cFileName, dir_info->FileName, dir_info->FileNameLength ); data->cFileName[dir_info->FileNameLength/sizeof(WCHAR)] = 0; - memcpy( data->cAlternateFileName, dir_info->ShortName, dir_info->ShortNameLength ); - data->cAlternateFileName[dir_info->ShortNameLength/sizeof(WCHAR)] = 0; + + if (info->level != FindExInfoBasic) + { + memcpy( data->cAlternateFileName, dir_info->ShortName, dir_info->ShortNameLength ); + data->cAlternateFileName[dir_info->ShortNameLength/sizeof(WCHAR)] = 0; + } + else + data->cAlternateFileName[0] = 0; TRACE("returning %s (%s)\n", debugstr_w(data->cFileName), debugstr_w(data->cAlternateFileName) ); diff -Nru wine1.7-1.7.28/dlls/kernel32/format_msg.c wine1.7-1.7.31/dlls/kernel32/format_msg.c --- wine1.7-1.7.28/dlls/kernel32/format_msg.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/format_msg.c 2014-11-14 13:28:17.000000000 +0000 @@ -68,8 +68,6 @@ * Yes, ANSI strings in win32 resources. Go figure. */ -static const WCHAR FMTWSTR[] = { '%','s',0 }; - /********************************************************************** * load_message (internal) */ @@ -104,6 +102,24 @@ return buffer; } +static LPWSTR search_message( DWORD flags, HMODULE module, UINT id, WORD lang ) +{ + LPWSTR from = NULL; + if (flags & FORMAT_MESSAGE_FROM_HMODULE) + from = load_message( module, id, lang ); + if (!from && (flags & FORMAT_MESSAGE_FROM_SYSTEM)) + { + /* Fold win32 hresult to its embedded error code. */ + if (HRESULT_SEVERITY(id) == SEVERITY_ERROR && + HRESULT_FACILITY(id) == FACILITY_WIN32) + { + id = HRESULT_CODE(id); + } + from = load_message( kernel32_handle, id, lang ); + } + return from; +} + /********************************************************************** * get_arg (internal) */ @@ -492,10 +508,7 @@ } else if (dwFlags & (FORMAT_MESSAGE_FROM_HMODULE | FORMAT_MESSAGE_FROM_SYSTEM)) { - if (dwFlags & FORMAT_MESSAGE_FROM_HMODULE) - from = load_message( (HMODULE)lpSource, dwMessageId, dwLanguageId ); - if (!from && (dwFlags & FORMAT_MESSAGE_FROM_SYSTEM)) - from = load_message( kernel32_handle, dwMessageId, dwLanguageId ); + from = search_message( dwFlags, (HMODULE)lpSource, dwMessageId, dwLanguageId ); if (!from) return 0; } else @@ -592,10 +605,7 @@ } else if (dwFlags & (FORMAT_MESSAGE_FROM_HMODULE | FORMAT_MESSAGE_FROM_SYSTEM)) { - if (dwFlags & FORMAT_MESSAGE_FROM_HMODULE) - from = load_message( (HMODULE)lpSource, dwMessageId, dwLanguageId ); - if (!from && (dwFlags & FORMAT_MESSAGE_FROM_SYSTEM)) - from = load_message( kernel32_handle, dwMessageId, dwLanguageId ); + from = search_message( dwFlags, (HMODULE)lpSource, dwMessageId, dwLanguageId ); if (!from) return 0; } else diff -Nru wine1.7-1.7.28/dlls/kernel32/heap.c wine1.7-1.7.31/dlls/kernel32/heap.c --- wine1.7-1.7.28/dlls/kernel32/heap.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/heap.c 2014-11-14 13:28:17.000000000 +0000 @@ -1447,3 +1447,17 @@ lpBuffer->dwAvailPhys, lpBuffer->dwTotalPageFile, lpBuffer->dwAvailPageFile, lpBuffer->dwTotalVirtual, lpBuffer->dwAvailVirtual ); } + +BOOL WINAPI GetSystemFileCacheSize(PSIZE_T mincache, PSIZE_T maxcache, PDWORD flags) +{ + FIXME("stub: %p %p %p\n", mincache, maxcache, flags); + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + +BOOL WINAPI SetSystemFileCacheSize(SIZE_T mincache, SIZE_T maxcache, DWORD flags) +{ + FIXME("stub: %ld %ld %d\n", mincache, maxcache, flags); + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} diff -Nru wine1.7-1.7.28/dlls/kernel32/kernel32.spec wine1.7-1.7.31/dlls/kernel32/kernel32.spec --- wine1.7-1.7.28/dlls/kernel32/kernel32.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/kernel32.spec 2014-11-14 13:28:17.000000000 +0000 @@ -143,6 +143,7 @@ # @ stub AddLocalAlternateComputerNameA # @ stub AddLocalAlternateComputerNameW @ stdcall AddRefActCtx(ptr) +@ stdcall AddVectoredContinueHandler(long ptr) ntdll.RtlAddVectoredContinueHandler @ stdcall AddVectoredExceptionHandler(long ptr) ntdll.RtlAddVectoredExceptionHandler @ stdcall AllocConsole() @ stub -i386 AllocLSCallback @@ -182,7 +183,7 @@ @ stub CancelDeviceWakeupRequest @ stdcall CancelIo(long) @ stdcall CancelIoEx(long ptr) -# @ stub CancelTimerQueueTimer +@ stdcall CancelTimerQueueTimer(ptr ptr) @ stdcall CancelWaitableTimer(long) @ stdcall ChangeTimerQueueTimer(ptr ptr long long) # @ stub CheckNameLegalDOS8Dot3A @@ -637,6 +638,7 @@ @ stdcall GetStringTypeExA(long long str long ptr) @ stdcall GetStringTypeExW(long long wstr long ptr) @ stdcall GetStringTypeW(long wstr long ptr) +@ stdcall GetSystemFileCacheSize(ptr ptr ptr) @ stdcall GetSystemDefaultLCID() @ stdcall GetSystemDefaultLangID() @ stdcall GetSystemDefaultLocaleName(ptr long) @@ -1025,6 +1027,7 @@ @ stdcall RemoveDirectoryW(wstr) # @ stub RemoveLocalAlternateComputerNameA # @ stub RemoveLocalAlternateComputerNameW +@ stdcall RemoveVectoredContinueHandler(ptr) ntdll.RtlRemoveVectoredContinueHandler @ stdcall RemoveVectoredExceptionHandler(ptr) ntdll.RtlRemoveVectoredExceptionHandler @ stdcall ReplaceFile(wstr wstr wstr long ptr ptr) ReplaceFileW @ stdcall ReplaceFileA(str str str long ptr ptr) @@ -1166,6 +1169,7 @@ @ stdcall SetProcessShutdownParameters(long long) @ stdcall SetProcessWorkingSetSize(long long long) @ stdcall SetStdHandle(long long) +@ stdcall SetSystemFileCacheSize(long long long) @ stdcall SetSystemPowerState(long long) @ stdcall SetSystemTime(ptr) @ stdcall SetSystemTimeAdjustment(long long) diff -Nru wine1.7-1.7.28/dlls/kernel32/locale.c wine1.7-1.7.31/dlls/kernel32/locale.c --- wine1.7-1.7.28/dlls/kernel32/locale.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/locale.c 2014-11-14 13:28:17.000000000 +0000 @@ -3456,17 +3456,6 @@ return bRet; } -/* Registry keys for NLS related information */ - -static const WCHAR szCountryListName[] = { - 'M','a','c','h','i','n','e','\\','S','o','f','t','w','a','r','e','\\', - 'M','i','c','r','o','s','o','f','t','\\','W','i','n','d','o','w','s','\\', - 'C','u','r','r','e','n','t','V','e','r','s','i','o','n','\\', - 'T','e','l','e','p','h','o','n','y','\\', - 'C','o','u','n','t','r','y',' ','L','i','s','t','\0' -}; - - /* Callback function ptrs for EnumSystemLanguageGroupsA/W */ typedef struct { diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/afk.nls wine1.7-1.7.31/dlls/kernel32/nls/afk.nls --- wine1.7-1.7.28/dlls/kernel32/nls/afk.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/afk.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Afrikaans (Suid Afrika)" LOCALE_SNATIVELANGNAME "Afrikaans" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "AFK " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy/MM/dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ara.nls wine1.7-1.7.31/dlls/kernel32/nls/ara.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ara.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ara.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ( )" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/arb.nls wine1.7-1.7.31/dlls/kernel32/nls/arb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/arb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/arb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/are.nls wine1.7-1.7.31/dlls/kernel32/nls/are.nls --- wine1.7-1.7.28/dlls/kernel32/nls/are.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/are.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/arg.nls wine1.7-1.7.31/dlls/kernel32/nls/arg.nls --- wine1.7-1.7.28/dlls/kernel32/nls/arg.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/arg.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/arh.nls wine1.7-1.7.31/dlls/kernel32/nls/arh.nls --- wine1.7-1.7.28/dlls/kernel32/nls/arh.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/arh.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ari.nls wine1.7-1.7.31/dlls/kernel32/nls/ari.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ari.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ari.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/arj.nls wine1.7-1.7.31/dlls/kernel32/nls/arj.nls --- wine1.7-1.7.28/dlls/kernel32/nls/arj.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/arj.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ark.nls wine1.7-1.7.31/dlls/kernel32/nls/ark.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ark.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ark.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/arl.nls wine1.7-1.7.31/dlls/kernel32/nls/arl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/arl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/arl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/arm.nls wine1.7-1.7.31/dlls/kernel32/nls/arm.nls --- wine1.7-1.7.28/dlls/kernel32/nls/arm.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/arm.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ( )" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/aro.nls wine1.7-1.7.31/dlls/kernel32/nls/aro.nls --- wine1.7-1.7.28/dlls/kernel32/nls/aro.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/aro.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/arq.nls wine1.7-1.7.31/dlls/kernel32/nls/arq.nls --- wine1.7-1.7.28/dlls/kernel32/nls/arq.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/arq.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ars.nls wine1.7-1.7.31/dlls/kernel32/nls/ars.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ars.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ars.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/art.nls wine1.7-1.7.31/dlls/kernel32/nls/art.nls --- wine1.7-1.7.28/dlls/kernel32/nls/art.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/art.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/aru.nls wine1.7-1.7.31/dlls/kernel32/nls/aru.nls --- wine1.7-1.7.28/dlls/kernel32/nls/aru.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/aru.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ( )" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ary.nls wine1.7-1.7.31/dlls/kernel32/nls/ary.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ary.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ary.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ARA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/aze.nls wine1.7-1.7.31/dlls/kernel32/nls/aze.nls --- wine1.7-1.7.28/dlls/kernel32/nls/aze.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/aze.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "" LOCALE_SNATIVELANGNAME L"\x0410\x0437\x04d9\x0440\x0431\x0430\x0458\x04b9\x0430\x043d" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "AZE " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/azl.nls wine1.7-1.7.31/dlls/kernel32/nls/azl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/azl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/azl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "" LOCALE_SNATIVELANGNAME L"Az\x0259rbaycan\x00ad\x0131l\x0131" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "AZE " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/bel.nls wine1.7-1.7.31/dlls/kernel32/nls/bel.nls --- wine1.7-1.7.28/dlls/kernel32/nls/bel.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/bel.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "BEL " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/bgr.nls wine1.7-1.7.31/dlls/kernel32/nls/bgr.nls --- wine1.7-1.7.28/dlls/kernel32/nls/bgr.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/bgr.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "BGR " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "dd.M.yyyy '.'" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/brf.nls wine1.7-1.7.31/dlls/kernel32/nls/brf.nls --- wine1.7-1.7.28/dlls/kernel32/nls/brf.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/brf.nls 2014-11-14 13:28:17.000000000 +0000 @@ -131,6 +131,7 @@ LOCALE_SNATIVEDISPLAYNAME "Brezhoneg (Bro-C'haill)" LOCALE_SNATIVELANGNAME "Brezhoneg" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "BRE " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/cat.nls wine1.7-1.7.31/dlls/kernel32/nls/cat.nls --- wine1.7-1.7.28/dlls/kernel32/nls/cat.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/cat.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "catal (Espanya)" LOCALE_SNATIVELANGNAME "catal" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "CAT " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/chs.nls wine1.7-1.7.31/dlls/kernel32/nls/chs.nls --- wine1.7-1.7.28/dlls/kernel32/nls/chs.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/chs.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "() (л񹲺͹)" LOCALE_SNATIVELANGNAME "()" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ZHS " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Hans;" LOCALE_SSHORTDATE "yyyy-M-d" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/cht.nls wine1.7-1.7.31/dlls/kernel32/nls/cht.nls --- wine1.7-1.7.28/dlls/kernel32/nls/cht.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/cht.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "(c) (xW)" LOCALE_SNATIVELANGNAME "(c)" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ZHT " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Hant;" LOCALE_SSHORTDATE "yyyy/M/d" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/cor.nls wine1.7-1.7.31/dlls/kernel32/nls/cor.nls --- wine1.7-1.7.28/dlls/kernel32/nls/cor.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/cor.nls 2014-11-14 13:28:17.000000000 +0000 @@ -131,6 +131,7 @@ LOCALE_SNATIVEDISPLAYNAME "Kernewek (Ruwvaneth Unys)" LOCALE_SNATIVELANGNAME "Kernewek" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/csy.nls wine1.7-1.7.31/dlls/kernel32/nls/csy.nls --- wine1.7-1.7.28/dlls/kernel32/nls/csy.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/csy.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "etina (eskrepublika)" LOCALE_SNATIVELANGNAME "etina" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "CSY " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d.M.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/cym.nls wine1.7-1.7.31/dlls/kernel32/nls/cym.nls --- wine1.7-1.7.28/dlls/kernel32/nls/cym.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/cym.nls 2014-11-14 13:28:17.000000000 +0000 @@ -131,6 +131,7 @@ LOCALE_SNATIVEDISPLAYNAME "Cymraeg (Cymru)" LOCALE_SNATIVELANGNAME "Cymraeg" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "WEL " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/dan.nls wine1.7-1.7.31/dlls/kernel32/nls/dan.nls --- wine1.7-1.7.28/dlls/kernel32/nls/dan.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/dan.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "dansk (Danmark)" LOCALE_SNATIVELANGNAME "dansk" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "DAN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/dea.nls wine1.7-1.7.31/dlls/kernel32/nls/dea.nls --- wine1.7-1.7.28/dlls/kernel32/nls/dea.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/dea.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Deutsch (sterreich)" LOCALE_SNATIVELANGNAME "Deutsch" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "DEU " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/dec.nls wine1.7-1.7.31/dlls/kernel32/nls/dec.nls --- wine1.7-1.7.28/dlls/kernel32/nls/dec.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/dec.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Deutsch (Liechtenstein)" LOCALE_SNATIVELANGNAME "Deutsch" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "DEU " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/del.nls wine1.7-1.7.31/dlls/kernel32/nls/del.nls --- wine1.7-1.7.28/dlls/kernel32/nls/del.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/del.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Deutsch (Luxemburg)" LOCALE_SNATIVELANGNAME "Deutsch" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "DEU " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/des.nls wine1.7-1.7.31/dlls/kernel32/nls/des.nls --- wine1.7-1.7.28/dlls/kernel32/nls/des.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/des.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Deutsch (Schweiz)" LOCALE_SNATIVELANGNAME "Deutsch" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "DEU " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/deu.nls wine1.7-1.7.31/dlls/kernel32/nls/deu.nls --- wine1.7-1.7.28/dlls/kernel32/nls/deu.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/deu.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Deutsch (Deutschland)" LOCALE_SNATIVELANGNAME "Deutsch" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "DEU " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/div.nls wine1.7-1.7.31/dlls/kernel32/nls/div.nls --- wine1.7-1.7.28/dlls/kernel32/nls/div.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/div.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "ދިވެހިބަސް (ދިވެހި ރާއްޖެ)" LOCALE_SNATIVELANGNAME "ދިވެހިބަސް" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "DIV " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Thaa;" LOCALE_SSHORTDATE "dd/MM/yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ell.nls wine1.7-1.7.31/dlls/kernel32/nls/ell.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ell.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ell.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ELL " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Grek;" LOCALE_SSHORTDATE "d/M/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ena.nls wine1.7-1.7.31/dlls/kernel32/nls/ena.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ena.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ena.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Australia)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/enb.nls wine1.7-1.7.31/dlls/kernel32/nls/enb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/enb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/enb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Caribbean)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "MM/dd/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/enc.nls wine1.7-1.7.31/dlls/kernel32/nls/enc.nls --- wine1.7-1.7.28/dlls/kernel32/nls/enc.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/enc.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Canada)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/eng.nls wine1.7-1.7.31/dlls/kernel32/nls/eng.nls --- wine1.7-1.7.28/dlls/kernel32/nls/eng.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/eng.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (United Kingdom)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/eni.nls wine1.7-1.7.31/dlls/kernel32/nls/eni.nls --- wine1.7-1.7.28/dlls/kernel32/nls/eni.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/eni.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Eire)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/enj.nls wine1.7-1.7.31/dlls/kernel32/nls/enj.nls --- wine1.7-1.7.28/dlls/kernel32/nls/enj.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/enj.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Jamaica)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/enl.nls wine1.7-1.7.31/dlls/kernel32/nls/enl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/enl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/enl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Belize)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/enp.nls wine1.7-1.7.31/dlls/kernel32/nls/enp.nls --- wine1.7-1.7.28/dlls/kernel32/nls/enp.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/enp.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Philippines)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "M/d/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ens.nls wine1.7-1.7.31/dlls/kernel32/nls/ens.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ens.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ens.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (South Africa)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy/MM/dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ent.nls wine1.7-1.7.31/dlls/kernel32/nls/ent.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ent.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ent.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Trinidad y Tobago)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/enu.nls wine1.7-1.7.31/dlls/kernel32/nls/enu.nls --- wine1.7-1.7.28/dlls/kernel32/nls/enu.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/enu.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (United States)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "M/d/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/enw.nls wine1.7-1.7.31/dlls/kernel32/nls/enw.nls --- wine1.7-1.7.28/dlls/kernel32/nls/enw.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/enw.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (Zimbabwe)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "M/d/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/enz.nls wine1.7-1.7.31/dlls/kernel32/nls/enz.nls --- wine1.7-1.7.28/dlls/kernel32/nls/enz.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/enz.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "English (New Zealand)" LOCALE_SNATIVELANGNAME "English" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ENG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/eox.nls wine1.7-1.7.31/dlls/kernel32/nls/eox.nls --- wine1.7-1.7.28/dlls/kernel32/nls/eox.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/eox.nls 2014-11-14 13:28:17.000000000 +0000 @@ -146,6 +146,7 @@ LOCALE_SNATIVEDISPLAYNAME "Esperanto" LOCALE_SNATIVELANGNAME "Esperanto" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "dflt" LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy-mm-dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esa.nls wine1.7-1.7.31/dlls/kernel32/nls/esa.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esa.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esa.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Panam)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "MM/dd/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esb.nls wine1.7-1.7.31/dlls/kernel32/nls/esb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Bolivia)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esc.nls wine1.7-1.7.31/dlls/kernel32/nls/esc.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esc.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esc.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Costa Rica)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esd.nls wine1.7-1.7.31/dlls/kernel32/nls/esd.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esd.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esd.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Repblica Dominicana)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ese.nls wine1.7-1.7.31/dlls/kernel32/nls/ese.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ese.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ese.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (El Salvador)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esf.nls wine1.7-1.7.31/dlls/kernel32/nls/esf.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esf.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esf.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Ecuador)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esg.nls wine1.7-1.7.31/dlls/kernel32/nls/esg.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esg.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esg.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Guatemala)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esh.nls wine1.7-1.7.31/dlls/kernel32/nls/esh.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esh.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esh.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Honduras)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esi.nls wine1.7-1.7.31/dlls/kernel32/nls/esi.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esi.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esi.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Nicaragua)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esl.nls wine1.7-1.7.31/dlls/kernel32/nls/esl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Chile)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esm.nls wine1.7-1.7.31/dlls/kernel32/nls/esm.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esm.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esm.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Mxico)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esn.nls wine1.7-1.7.31/dlls/kernel32/nls/esn.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esn.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esn.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "espaol (Espaa)" LOCALE_SNATIVELANGNAME "espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/eso.nls wine1.7-1.7.31/dlls/kernel32/nls/eso.nls --- wine1.7-1.7.28/dlls/kernel32/nls/eso.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/eso.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Colombia)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esp.nls wine1.7-1.7.31/dlls/kernel32/nls/esp.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esp.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esp.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "espaol (Espaa)" LOCALE_SNATIVELANGNAME "espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esr.nls wine1.7-1.7.31/dlls/kernel32/nls/esr.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esr.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esr.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Per)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ess.nls wine1.7-1.7.31/dlls/kernel32/nls/ess.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ess.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ess.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Argentina)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esu.nls wine1.7-1.7.31/dlls/kernel32/nls/esu.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esu.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esu.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Puerto Rico)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esv.nls wine1.7-1.7.31/dlls/kernel32/nls/esv.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esv.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esv.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Republica Bolivariana de Venezuela)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esy.nls wine1.7-1.7.31/dlls/kernel32/nls/esy.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esy.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esy.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Uruguay)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/esz.nls wine1.7-1.7.31/dlls/kernel32/nls/esz.nls --- wine1.7-1.7.28/dlls/kernel32/nls/esz.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/esz.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Espaol (Paraguay)" LOCALE_SNATIVELANGNAME "Espaol" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ESP " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/eti.nls wine1.7-1.7.31/dlls/kernel32/nls/eti.nls --- wine1.7-1.7.28/dlls/kernel32/nls/eti.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/eti.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "eesti (Eesti)" LOCALE_SNATIVELANGNAME "eesti" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ETI " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/euq.nls wine1.7-1.7.31/dlls/kernel32/nls/euq.nls --- wine1.7-1.7.28/dlls/kernel32/nls/euq.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/euq.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "euskara (Espainia)" LOCALE_SNATIVELANGNAME "euskara" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "EUQ " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy/MM/dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/far.nls wine1.7-1.7.31/dlls/kernel32/nls/far.nls --- wine1.7-1.7.28/dlls/kernel32/nls/far.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/far.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FAR " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "yyyy/MM/dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/fin.nls wine1.7-1.7.31/dlls/kernel32/nls/fin.nls --- wine1.7-1.7.28/dlls/kernel32/nls/fin.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/fin.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "suomi (Suomi)" LOCALE_SNATIVELANGNAME "suomi" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FIN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d.M.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/fos.nls wine1.7-1.7.31/dlls/kernel32/nls/fos.nls --- wine1.7-1.7.28/dlls/kernel32/nls/fos.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/fos.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "froyskt (Froyar)" LOCALE_SNATIVELANGNAME "froyskt" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FOS " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/fra.nls wine1.7-1.7.31/dlls/kernel32/nls/fra.nls --- wine1.7-1.7.28/dlls/kernel32/nls/fra.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/fra.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "franais (France)" LOCALE_SNATIVELANGNAME "franais" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FRA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/frb.nls wine1.7-1.7.31/dlls/kernel32/nls/frb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/frb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/frb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "franais (Belgique)" LOCALE_SNATIVELANGNAME "franais" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FRA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/frc.nls wine1.7-1.7.31/dlls/kernel32/nls/frc.nls --- wine1.7-1.7.28/dlls/kernel32/nls/frc.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/frc.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "franais (Canada)" LOCALE_SNATIVELANGNAME "franais" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FRA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy-MM-dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/frl.nls wine1.7-1.7.31/dlls/kernel32/nls/frl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/frl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/frl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "franais (Luxembourg)" LOCALE_SNATIVELANGNAME "franais" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FRA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/frm.nls wine1.7-1.7.31/dlls/kernel32/nls/frm.nls --- wine1.7-1.7.28/dlls/kernel32/nls/frm.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/frm.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "franais (Principaut de Monaco)" LOCALE_SNATIVELANGNAME "franais" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FRA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/frs.nls wine1.7-1.7.31/dlls/kernel32/nls/frs.nls --- wine1.7-1.7.28/dlls/kernel32/nls/frs.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/frs.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "franais (Suisse)" LOCALE_SNATIVELANGNAME "franais" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "FRA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/gae.nls wine1.7-1.7.31/dlls/kernel32/nls/gae.nls --- wine1.7-1.7.28/dlls/kernel32/nls/gae.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/gae.nls 2014-11-14 13:28:17.000000000 +0000 @@ -131,6 +131,7 @@ LOCALE_SNATIVEDISPLAYNAME "Gaeilge (ire)" LOCALE_SNATIVELANGNAME "Gaeilge" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "IRI " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d/M/yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/gdh.nls wine1.7-1.7.31/dlls/kernel32/nls/gdh.nls --- wine1.7-1.7.28/dlls/kernel32/nls/gdh.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/gdh.nls 2014-11-14 13:28:17.000000000 +0000 @@ -131,6 +131,7 @@ LOCALE_SNATIVEDISPLAYNAME "Gaidhlig (Breatainn Mhr)" LOCALE_SNATIVELANGNAME "Gaidhlig" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "GAE " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/gdv.nls wine1.7-1.7.31/dlls/kernel32/nls/gdv.nls --- wine1.7-1.7.28/dlls/kernel32/nls/gdv.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/gdv.nls 2014-11-14 13:28:17.000000000 +0000 @@ -131,6 +131,7 @@ LOCALE_SNATIVEDISPLAYNAME "Gaelg (Manninn)" LOCALE_SNATIVELANGNAME "Gaelg" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "GAE " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/glc.nls wine1.7-1.7.31/dlls/kernel32/nls/glc.nls --- wine1.7-1.7.28/dlls/kernel32/nls/glc.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/glc.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "galego (Espaa)" LOCALE_SNATIVELANGNAME "galego" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "GAL " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/guj.nls wine1.7-1.7.31/dlls/kernel32/nls/guj.nls --- wine1.7-1.7.28/dlls/kernel32/nls/guj.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/guj.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "ગુજરાતી (ભારત)" LOCALE_SNATIVELANGNAME "ગુજરાતી" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "GUJ " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Gujr;" LOCALE_SSHORTDATE "dd-MM-yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/heb.nls wine1.7-1.7.31/dlls/kernel32/nls/heb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/heb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/heb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -131,6 +131,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "IWR " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Hebr;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/hin.nls wine1.7-1.7.31/dlls/kernel32/nls/hin.nls --- wine1.7-1.7.28/dlls/kernel32/nls/hin.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/hin.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "हिंदी (भारत)" LOCALE_SNATIVELANGNAME "हिंदी" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "HIN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Deva;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/hrv.nls wine1.7-1.7.31/dlls/kernel32/nls/hrv.nls --- wine1.7-1.7.28/dlls/kernel32/nls/hrv.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/hrv.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "hrvatski (Hrvatska)" LOCALE_SNATIVELANGNAME "hrvatski" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "HRV " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d.M.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/hun.nls wine1.7-1.7.31/dlls/kernel32/nls/hun.nls --- wine1.7-1.7.28/dlls/kernel32/nls/hun.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/hun.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Magyar (Magyarorszg)" LOCALE_SNATIVELANGNAME "Magyar" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "HUN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy. MM. dd." diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/hye.nls wine1.7-1.7.31/dlls/kernel32/nls/hye.nls --- wine1.7-1.7.28/dlls/kernel32/nls/hye.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/hye.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Հայերեն (Հայաստան)" LOCALE_SNATIVELANGNAME "Հայերեն" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "HYE " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Armn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ind.nls wine1.7-1.7.31/dlls/kernel32/nls/ind.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ind.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ind.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Bahasa Indonesia (Indonesia)" LOCALE_SNATIVELANGNAME "Bahasa Indonesia" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "IND " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/isl.nls wine1.7-1.7.31/dlls/kernel32/nls/isl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/isl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/isl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "slenska (sland)" LOCALE_SNATIVELANGNAME "slenska" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ISL " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d.M.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ita.nls wine1.7-1.7.31/dlls/kernel32/nls/ita.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ita.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ita.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "italiano (Italia)" LOCALE_SNATIVELANGNAME "italiano" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ITA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/its.nls wine1.7-1.7.31/dlls/kernel32/nls/its.nls --- wine1.7-1.7.28/dlls/kernel32/nls/its.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/its.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "italiano (Svizzera)" LOCALE_SNATIVELANGNAME "italiano" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ITA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/jpn.nls wine1.7-1.7.31/dlls/kernel32/nls/jpn.nls --- wine1.7-1.7.28/dlls/kernel32/nls/jpn.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/jpn.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "{ ({)" LOCALE_SNATIVELANGNAME "{" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "JAN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Hani;Hira;Kana;" LOCALE_SSHORTDATE "yyyy/MM/dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/kan.nls wine1.7-1.7.31/dlls/kernel32/nls/kan.nls --- wine1.7-1.7.28/dlls/kernel32/nls/kan.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/kan.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "ಕನ್ನಡ (ಭಾರತ)" LOCALE_SNATIVELANGNAME "ಕನ್ನಡ" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "KAN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Knda;" LOCALE_SSHORTDATE "dd-MM-yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/kat.nls wine1.7-1.7.31/dlls/kernel32/nls/kat.nls --- wine1.7-1.7.28/dlls/kernel32/nls/kat.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/kat.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "ქართული (საქართველო)" LOCALE_SNATIVELANGNAME "ქართული" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "KAT " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Geor;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/kkz.nls wine1.7-1.7.31/dlls/kernel32/nls/kkz.nls --- wine1.7-1.7.28/dlls/kernel32/nls/kkz.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/kkz.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "" LOCALE_SNATIVELANGNAME L"\x049a\x0430\x0437\x0430\x049b" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "KAZ " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/knk.nls wine1.7-1.7.31/dlls/kernel32/nls/knk.nls --- wine1.7-1.7.28/dlls/kernel32/nls/knk.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/knk.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "कोंकणी (भारत)" LOCALE_SNATIVELANGNAME "कोंकणी" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "KOK " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Deva;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/kor.nls wine1.7-1.7.31/dlls/kernel32/nls/kor.nls --- wine1.7-1.7.28/dlls/kernel32/nls/kor.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/kor.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "ѱ (ѹα)" LOCALE_SNATIVELANGNAME "ѱ" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "KOR " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Hang;Hani;" LOCALE_SSHORTDATE "yyyy-MM-dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/kyr.nls wine1.7-1.7.31/dlls/kernel32/nls/kyr.nls --- wine1.7-1.7.28/dlls/kernel32/nls/kyr.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/kyr.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "KIR " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "dd.MM.yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/lth.nls wine1.7-1.7.31/dlls/kernel32/nls/lth.nls --- wine1.7-1.7.28/dlls/kernel32/nls/lth.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/lth.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "lietuvių (Lietuva)" LOCALE_SNATIVELANGNAME "lietuvių" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "LTH " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy.MM.dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/lvi.nls wine1.7-1.7.31/dlls/kernel32/nls/lvi.nls --- wine1.7-1.7.28/dlls/kernel32/nls/lvi.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/lvi.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "latvieu (Latvija)" LOCALE_SNATIVELANGNAME "latvieu" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "LVI " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy.MM.dd." diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/mar.nls wine1.7-1.7.31/dlls/kernel32/nls/mar.nls --- wine1.7-1.7.28/dlls/kernel32/nls/mar.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/mar.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "मराठी (भारत)" LOCALE_SNATIVELANGNAME "मराठी" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "MAR " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Mlym;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/mki.nls wine1.7-1.7.31/dlls/kernel32/nls/mki.nls --- wine1.7-1.7.28/dlls/kernel32/nls/mki.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/mki.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME " " LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "MKD " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/mon.nls wine1.7-1.7.31/dlls/kernel32/nls/mon.nls --- wine1.7-1.7.28/dlls/kernel32/nls/mon.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/mon.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "MNG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "yy.MM.dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/msb.nls wine1.7-1.7.31/dlls/kernel32/nls/msb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/msb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/msb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Bahasa Malaysia (Brunei Darussalam)" LOCALE_SNATIVELANGNAME "Bahasa Malaysia" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "MLY " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/msl.nls wine1.7-1.7.31/dlls/kernel32/nls/msl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/msl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/msl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Bahasa Malaysia (Malaysia)" LOCALE_SNATIVELANGNAME "Bahasa Malaysia" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "MLY " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/nlb.nls wine1.7-1.7.31/dlls/kernel32/nls/nlb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/nlb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/nlb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Nederlands (Belgi)" LOCALE_SNATIVELANGNAME "Nederlands" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "NLD " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/nld.nls wine1.7-1.7.31/dlls/kernel32/nls/nld.nls --- wine1.7-1.7.28/dlls/kernel32/nls/nld.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/nld.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Nederlands (Nederland)" LOCALE_SNATIVELANGNAME "Nederlands" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "NLD " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d-M-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/nls.nls wine1.7-1.7.31/dlls/kernel32/nls/nls.nls --- wine1.7-1.7.28/dlls/kernel32/nls/nls.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/nls.nls 2014-11-14 13:28:17.000000000 +0000 @@ -136,6 +136,7 @@ LOCALE_SNATIVEDISPLAYNAME "Nederlands (Suriname)" LOCALE_SNATIVELANGNAME "Nederlands" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "NLD " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d-M-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/non.nls wine1.7-1.7.31/dlls/kernel32/nls/non.nls --- wine1.7-1.7.28/dlls/kernel32/nls/non.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/non.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "norsk (nynorsk) (Noreg)" LOCALE_SNATIVELANGNAME "norsk (nynorsk)" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "NYN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/nor.nls wine1.7-1.7.31/dlls/kernel32/nls/nor.nls --- wine1.7-1.7.28/dlls/kernel32/nls/nor.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/nor.nls 2014-11-14 13:28:17.000000000 +0000 @@ -131,6 +131,7 @@ LOCALE_SNATIVEDISPLAYNAME "norsk (bokml)" LOCALE_SNATIVELANGNAME "norsk (bokml)" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "NOR " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/pan.nls wine1.7-1.7.31/dlls/kernel32/nls/pan.nls --- wine1.7-1.7.28/dlls/kernel32/nls/pan.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/pan.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "ਪੰਜਾਬੀ (ਭਾਰਤ)" LOCALE_SNATIVELANGNAME "ਪੰਜਾਬੀ" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "PAN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Guru;" LOCALE_SSHORTDATE "dd-MM-yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/plk.nls wine1.7-1.7.31/dlls/kernel32/nls/plk.nls --- wine1.7-1.7.28/dlls/kernel32/nls/plk.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/plk.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "polski (Polska)" LOCALE_SNATIVELANGNAME "polski" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "PLK " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy-MM-dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ptb.nls wine1.7-1.7.31/dlls/kernel32/nls/ptb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ptb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ptb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Portugus (Brasil)" LOCALE_SNATIVELANGNAME "Portugus" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "PTG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d/M/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ptg.nls wine1.7-1.7.31/dlls/kernel32/nls/ptg.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ptg.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ptg.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "portugus (Portugal)" LOCALE_SNATIVELANGNAME "portugus" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "PTG " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/rmc.nls wine1.7-1.7.31/dlls/kernel32/nls/rmc.nls --- wine1.7-1.7.28/dlls/kernel32/nls/rmc.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/rmc.nls 2014-11-14 13:28:17.000000000 +0000 @@ -141,6 +141,7 @@ LOCALE_SNATIVEDISPLAYNAME "Rumantsch (Svizra)" LOCALE_SNATIVELANGNAME "Rumantsch" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "RMS " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/rom.nls wine1.7-1.7.31/dlls/kernel32/nls/rom.nls --- wine1.7-1.7.28/dlls/kernel32/nls/rom.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/rom.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "română (România)" LOCALE_SNATIVELANGNAME "română" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ROM " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/rus.nls wine1.7-1.7.31/dlls/kernel32/nls/rus.nls --- wine1.7-1.7.28/dlls/kernel32/nls/rus.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/rus.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "русский (Россия)" LOCALE_SNATIVELANGNAME "русский" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "RUS " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/san.nls wine1.7-1.7.31/dlls/kernel32/nls/san.nls --- wine1.7-1.7.28/dlls/kernel32/nls/san.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/san.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "संस्कृत (भारतम्)" LOCALE_SNATIVELANGNAME "संस्कृत" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SAN " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Deva;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/sky.nls wine1.7-1.7.31/dlls/kernel32/nls/sky.nls --- wine1.7-1.7.28/dlls/kernel32/nls/sky.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/sky.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "slovenina (Slovensk republika)" LOCALE_SNATIVELANGNAME "slovenina" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SKY " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d. M. yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/slv.nls wine1.7-1.7.31/dlls/kernel32/nls/slv.nls --- wine1.7-1.7.28/dlls/kernel32/nls/slv.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/slv.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "slovenski (Slovenija)" LOCALE_SNATIVELANGNAME "slovenski" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SLV " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d.M.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/sqi.nls wine1.7-1.7.31/dlls/kernel32/nls/sqi.nls --- wine1.7-1.7.28/dlls/kernel32/nls/sqi.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/sqi.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "shqipe (Shqipria)" LOCALE_SNATIVELANGNAME "shqipe" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SQI " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy-MM-dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/srb.nls wine1.7-1.7.31/dlls/kernel32/nls/srb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/srb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/srb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SRB " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "d.M.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/srl.nls wine1.7-1.7.31/dlls/kernel32/nls/srl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/srl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/srl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "srpski (Srbija)" LOCALE_SNATIVELANGNAME "srpski" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SRB " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d.M.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/sve.nls wine1.7-1.7.31/dlls/kernel32/nls/sve.nls --- wine1.7-1.7.28/dlls/kernel32/nls/sve.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/sve.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "svenska (Sverige)" LOCALE_SNATIVELANGNAME "svenska" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SVE " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "yyyy-MM-dd" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/svf.nls wine1.7-1.7.31/dlls/kernel32/nls/svf.nls --- wine1.7-1.7.28/dlls/kernel32/nls/svf.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/svf.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "svenska (Finland)" LOCALE_SNATIVELANGNAME "svenska" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SVE " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "d.M.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/swk.nls wine1.7-1.7.31/dlls/kernel32/nls/swk.nls --- wine1.7-1.7.28/dlls/kernel32/nls/swk.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/swk.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Kiswahili (Kenya)" LOCALE_SNATIVELANGNAME "Kiswahili" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SWK " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "M/d/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/syr.nls wine1.7-1.7.31/dlls/kernel32/nls/syr.nls --- wine1.7-1.7.28/dlls/kernel32/nls/syr.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/syr.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "ܣܘܪܝܝܐ (سوريا)" LOCALE_SNATIVELANGNAME "ܣܘܪܝܝܐ" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "SYR " LOCALE_SPOSITIVESIGN "+" LOCALE_SSCRIPTS "Syrc;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/tam.nls wine1.7-1.7.31/dlls/kernel32/nls/tam.nls --- wine1.7-1.7.28/dlls/kernel32/nls/tam.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/tam.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "தமிழ் (இந்தியா)" LOCALE_SNATIVELANGNAME "தமிழ்" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "TAM " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Taml;" LOCALE_SSHORTDATE "dd-MM-yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/tel.nls wine1.7-1.7.31/dlls/kernel32/nls/tel.nls --- wine1.7-1.7.28/dlls/kernel32/nls/tel.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/tel.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "తెలుగు (భారత దేశం)" LOCALE_SNATIVELANGNAME "తెలుగు" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "TEL " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Telu;" LOCALE_SSHORTDATE "dd-MM-yy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/tha.nls wine1.7-1.7.31/dlls/kernel32/nls/tha.nls --- wine1.7-1.7.28/dlls/kernel32/nls/tha.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/tha.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "THA " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Thai;" LOCALE_SSHORTDATE "d/M/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/trk.nls wine1.7-1.7.31/dlls/kernel32/nls/trk.nls --- wine1.7-1.7.28/dlls/kernel32/nls/trk.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/trk.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Trke (Trkiye)" LOCALE_SNATIVELANGNAME "Trke" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "TRK " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ttt.nls wine1.7-1.7.31/dlls/kernel32/nls/ttt.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ttt.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ttt.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "TAT " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" /* FIXME? */ LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/ukr.nls wine1.7-1.7.31/dlls/kernel32/nls/ukr.nls --- wine1.7-1.7.28/dlls/kernel32/nls/ukr.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/ukr.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "UKR " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/urd.nls wine1.7-1.7.31/dlls/kernel32/nls/urd.nls --- wine1.7-1.7.28/dlls/kernel32/nls/urd.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/urd.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " (ǘ)" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "URD " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Arab;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/uzb.nls wine1.7-1.7.31/dlls/kernel32/nls/uzb.nls --- wine1.7-1.7.28/dlls/kernel32/nls/uzb.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/uzb.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME " ()" LOCALE_SNATIVELANGNAME "" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "UZB " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Cyrl;" LOCALE_SSHORTDATE "dd.MM.yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/uzl.nls wine1.7-1.7.31/dlls/kernel32/nls/uzl.nls --- wine1.7-1.7.28/dlls/kernel32/nls/uzl.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/uzl.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "U'zbek (U'zbekiston Respublikasi)" LOCALE_SNATIVELANGNAME "U'zbek" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "UZB " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/vit.nls wine1.7-1.7.31/dlls/kernel32/nls/vit.nls --- wine1.7-1.7.28/dlls/kernel32/nls/vit.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/vit.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Ting Vit Nam (Vit Nam)" LOCALE_SNATIVELANGNAME "Ting Vit Nam" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "VIT " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/wal.nls wine1.7-1.7.31/dlls/kernel32/nls/wal.nls --- wine1.7-1.7.28/dlls/kernel32/nls/wal.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/wal.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "Walon (Beldjike)" LOCALE_SNATIVELANGNAME "Walon" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "BEL " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Latn;" LOCALE_SSHORTDATE "dd/MM/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/zhh.nls wine1.7-1.7.31/dlls/kernel32/nls/zhh.nls --- wine1.7-1.7.28/dlls/kernel32/nls/zhh.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/zhh.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "(c)" LOCALE_SNATIVELANGNAME "(c)" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ZHH " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Hant;" LOCALE_SSHORTDATE "d/M/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/zhi.nls wine1.7-1.7.31/dlls/kernel32/nls/zhi.nls --- wine1.7-1.7.28/dlls/kernel32/nls/zhi.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/zhi.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "() (¼)" LOCALE_SNATIVELANGNAME "()" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ZHS " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Hans;" LOCALE_SSHORTDATE "d/M/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/nls/zhm.nls wine1.7-1.7.31/dlls/kernel32/nls/zhm.nls --- wine1.7-1.7.28/dlls/kernel32/nls/zhm.nls 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/nls/zhm.nls 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,7 @@ LOCALE_SNATIVEDISPLAYNAME "" LOCALE_SNATIVELANGNAME L"\x4e2d\x6587(\x7b80\x4f53)" LOCALE_SNEGATIVESIGN "-" + LOCALE_SOPENTYPELANGUAGETAG "ZHT " LOCALE_SPOSITIVESIGN "" LOCALE_SSCRIPTS "Hant;" LOCALE_SSHORTDATE "d/M/yyyy" diff -Nru wine1.7-1.7.28/dlls/kernel32/path.c wine1.7-1.7.31/dlls/kernel32/path.c --- wine1.7-1.7.28/dlls/kernel32/path.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/path.c 2014-11-14 13:28:17.000000000 +0000 @@ -251,12 +251,12 @@ LPSTR *lastpart ) { WCHAR *nameW; - WCHAR bufferW[MAX_PATH]; + WCHAR bufferW[MAX_PATH], *lastpartW = NULL; DWORD ret; if (!(nameW = FILE_name_AtoW( name, FALSE ))) return 0; - ret = GetFullPathNameW( nameW, MAX_PATH, bufferW, NULL); + ret = GetFullPathNameW( nameW, MAX_PATH, bufferW, &lastpartW); if (!ret) return 0; if (ret > MAX_PATH) @@ -267,14 +267,10 @@ ret = copy_filename_WtoA( bufferW, buffer, len ); if (ret < len && lastpart) { - LPSTR p = buffer + strlen(buffer) - 1; - - if (*p != '\\') - { - while ((p > buffer + 2) && (*p != '\\')) p--; - *lastpart = p + 1; - } - else *lastpart = NULL; + if (lastpartW) + *lastpart = buffer + FILE_name_WtoA( bufferW, lastpartW - bufferW, NULL, 0 ); + else + *lastpart = NULL; } return ret; } diff -Nru wine1.7-1.7.28/dlls/kernel32/process.c wine1.7-1.7.31/dlls/kernel32/process.c --- wine1.7-1.7.28/dlls/kernel32/process.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/process.c 2014-11-14 13:28:17.000000000 +0000 @@ -512,13 +512,20 @@ 'P','r','o','f','i','l','e','L','i','s','t',0}; static const WCHAR profiles_valueW[] = {'P','r','o','f','i','l','e','s','D','i','r','e','c','t','o','r','y',0}; static const WCHAR all_users_valueW[] = {'A','l','l','U','s','e','r','s','P','r','o','f','i','l','e','\0'}; + static const WCHAR computernameW[] = {'C','O','M','P','U','T','E','R','N','A','M','E',0}; static const WCHAR allusersW[] = {'A','L','L','U','S','E','R','S','P','R','O','F','I','L','E',0}; OBJECT_ATTRIBUTES attr; UNICODE_STRING nameW; WCHAR *profile_dir = NULL, *all_users_dir = NULL; + WCHAR buf[MAX_COMPUTERNAME_LENGTH]; HANDLE hkey; DWORD len; + /* ComputerName */ + len = sizeof(buf) / sizeof(WCHAR); + if (GetComputerNameW( buf, &len )) + SetEnvironmentVariableW( computernameW, buf ); + /* set the ALLUSERSPROFILE variables */ attr.Length = sizeof(attr); @@ -3942,9 +3949,31 @@ */ BOOL WINAPI GetProcessDEPPolicy(HANDLE process, LPDWORD flags, PBOOL permanent) { - FIXME("(%p %p %p): stub\n", process, flags, permanent); - SetLastError(ERROR_CALL_NOT_IMPLEMENTED); - return FALSE; + NTSTATUS status; + ULONG dep_flags; + + TRACE("(%p %p %p)\n", process, flags, permanent); + + status = NtQueryInformationProcess( GetCurrentProcess(), ProcessExecuteFlags, + &dep_flags, sizeof(dep_flags), NULL ); + if (!status) + { + + if (flags) + { + *flags = 0; + if (dep_flags & MEM_EXECUTE_OPTION_DISABLE) + *flags |= PROCESS_DEP_ENABLE; + if (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION) + *flags |= PROCESS_DEP_DISABLE_ATL_THUNK_EMULATION; + } + + if (permanent) + *permanent = (dep_flags & MEM_EXECUTE_OPTION_PERMANENT) != 0; + + } + if (status) SetLastError( RtlNtStatusToDosError(status) ); + return !status; } /********************************************************************** diff -Nru wine1.7-1.7.28/dlls/kernel32/sync.c wine1.7-1.7.31/dlls/kernel32/sync.c --- wine1.7-1.7.28/dlls/kernel32/sync.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/sync.c 2014-11-14 13:28:17.000000000 +0000 @@ -1300,6 +1300,15 @@ } /*********************************************************************** + * CancelTimerQueueTimer (KERNEL32.@) + */ +BOOL WINAPI CancelTimerQueueTimer(HANDLE queue, HANDLE timer) +{ + FIXME("stub: %p %p\n", queue, timer); + return FALSE; +} + +/*********************************************************************** * DeleteTimerQueueTimer (KERNEL32.@) * * Cancels a timer-queue timer. diff -Nru wine1.7-1.7.28/dlls/kernel32/tests/actctx.c wine1.7-1.7.31/dlls/kernel32/tests/actctx.c --- wine1.7-1.7.28/dlls/kernel32/tests/actctx.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/tests/actctx.c 2014-11-14 13:28:17.000000000 +0000 @@ -2055,7 +2055,6 @@ static void init_paths(void) { LPWSTR ptr; - WCHAR last; static const WCHAR dot_manifest[] = {'.','M','a','n','i','f','e','s','t',0}; static const WCHAR backslash[] = {'\\',0}; @@ -2067,8 +2066,8 @@ ptr[1] = 0; GetCurrentDirectoryW(MAX_PATH, work_dir); - last = work_dir[lstrlenW(work_dir) - 1]; - if (last != '\\' && last != '/') + ptr = work_dir + lstrlenW( work_dir ) - 1; + if (*ptr != '\\' && *ptr != '/') lstrcatW(work_dir, backslash); lstrcpyW(work_dir_subdir, work_dir); lstrcatW(work_dir_subdir, subdir); diff -Nru wine1.7-1.7.28/dlls/kernel32/tests/codepage.c wine1.7-1.7.31/dlls/kernel32/tests/codepage.c --- wine1.7-1.7.28/dlls/kernel32/tests/codepage.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/tests/codepage.c 2014-11-14 13:28:17.000000000 +0000 @@ -20,6 +20,7 @@ */ #include +#include #include #include "wine/test.h" @@ -412,6 +413,240 @@ ok(GetLastError() == 0xdeadbeef, "GetLastError() is %u\n", GetLastError()); } +static void test_utf7_encoding(void) +{ + WCHAR input[16]; + char output[16], expected[16]; + int i, len, expected_len; + + static const BOOL directly_encodable_table[] = + { + 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, /* 0x00 - 0x0F */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x10 - 0x1F */ + 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 1, 1, /* 0x20 - 0x2F */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, /* 0x30 - 0x3F */ + 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, /* 0x40 - 0x4F */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, /* 0x50 - 0x5F */ + 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, /* 0x60 - 0x6F */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0 /* 0x70 - 0x7F */ + }; + static const char base64_encoding_table[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; + + if (WideCharToMultiByte(CP_UTF7, 0, foobarW, -1, NULL, 0, NULL, NULL) == 0 && + GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) + { + skip("UTF-7 encoding not implemented\n"); + return; + } + + /* test which characters are encoded if surrounded by non-encoded characters */ + for (i = 0; i <= 0xFFFF; i++) + { + input[0] = ' '; + input[1] = i; + input[2] = ' '; + input[3] = 0; + + memset(output, '#', sizeof(output) - 1); + output[sizeof(output) - 1] = 0; + + len = WideCharToMultiByte(CP_UTF7, 0, input, 4, output, sizeof(output) - 1, NULL, NULL); + + if (i == '+') + { + /* '+' is a special case and is encoded as "+-" */ + expected_len = 5; + strcpy(expected, " +- "); + } + else if (i <= 0x7F && directly_encodable_table[i]) + { + /* encodes directly */ + expected_len = 4; + sprintf(expected, " %c ", i); + } + else + { + /* base64-encodes */ + expected_len = 8; + sprintf(expected, " +%c%c%c- ", + base64_encoding_table[(i & 0xFC00) >> 10], + base64_encoding_table[(i & 0x03F0) >> 4], + base64_encoding_table[(i & 0x000F) << 2]); + } + + ok(len == expected_len, "i=0x%04x: expected len=%i, got len=%i\n", i, expected_len, len); + ok(memcmp(output, expected, expected_len) == 0, + "i=0x%04x: expected output='%s', got output='%s'\n", i, expected, output); + ok(output[expected_len] == '#', "i=0x%04x: expected output[%i]='#', got output[%i]=%i\n", + i, expected_len, expected_len, output[expected_len]); + } + + /* test which one-byte characters are absorbed into surrounding base64 blocks + * (Windows always ends the base64 block when it encounters a directly encodable character) */ + for (i = 0; i <= 0xFFFF; i++) + { + input[0] = 0x2672; + input[1] = i; + input[2] = 0x2672; + input[3] = 0; + + memset(output, '#', sizeof(output) - 1); + output[sizeof(output) - 1] = 0; + + len = WideCharToMultiByte(CP_UTF7, 0, input, 4, output, sizeof(output) - 1, NULL, NULL); + + if (i == '+') + { + /* '+' is a special case and is encoded as "+-" */ + expected_len = 13; + strcpy(expected, "+JnI-+-+JnI-"); + } + else if (i <= 0x7F && directly_encodable_table[i]) + { + /* encodes directly */ + expected_len = 12; + sprintf(expected, "+JnI-%c+JnI-", i); + } + else + { + /* base64-encodes */ + expected_len = 11; + sprintf(expected, "+Jn%c%c%c%cZy-", + base64_encoding_table[8 | ((i & 0xC000) >> 14)], + base64_encoding_table[(i & 0x3F00) >> 8], + base64_encoding_table[(i & 0x00FC) >> 2], + base64_encoding_table[((i & 0x0003) << 4) | 2]); + } + + ok(len == expected_len, "i=0x%04x: expected len=%i, got len=%i\n", i, expected_len, len); + ok(memcmp(output, expected, expected_len) == 0, + "i=0x%04x: expected output='%s', got output='%s'\n", i, expected, output); + ok(output[expected_len] == '#', "i=0x%04x: expected output[%i]='#', got output[%i]=%i\n", + i, expected_len, expected_len, output[expected_len]); + } +} + +static void test_utf7_decoding(void) +{ + char input[32]; + WCHAR output[32], expected[32]; + int i, len, expected_len; + + static const signed char base64_decoding_table[] = + { + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /* 0x00-0x0F */ + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /* 0x10-0x1F */ + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 62, -1, -1, -1, 63, /* 0x20-0x2F */ + 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, -1, -1, -1, -1, -1, -1, /* 0x30-0x3F */ + -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, /* 0x40-0x4F */ + 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, -1, -1, -1, -1, -1, /* 0x50-0x5F */ + -1, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, /* 0x60-0x6F */ + 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, -1, -1, -1, -1, -1 /* 0x70-0x7F */ + }; + + if (MultiByteToWideChar(CP_UTF7, 0, "foobar", -1, NULL, 0) == 0 && + GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) + { + skip("UTF-7 decoding not implemented\n"); + return; + } + + /* test which one-byte characters remove stray + signs */ + for (i = 0; i < 256; i++) + { + sprintf(input, "+%c+AAA", i); + + memset(output, 0x23, sizeof(output) - sizeof(WCHAR)); + output[sizeof(output) / sizeof(WCHAR) - 1] = 0; + + len = MultiByteToWideChar(CP_UTF7, 0, input, 7, output, sizeof(output) / sizeof(WCHAR) - 1); + + if (i == '-') + { + /* removes the - sign */ + expected_len = 3; + expected[0] = 0x002B; + expected[1] = 0; + expected[2] = 0; + } + else if (i <= 0x7F && base64_decoding_table[i] != -1) + { + /* absorbs the character into the base64 sequence */ + expected_len = 2; + expected[0] = (base64_decoding_table[i] << 10) | 0x03E0; + expected[1] = 0; + } + else + { + /* removes the + sign */ + expected_len = 3; + expected[0] = i; + expected[1] = 0; + expected[2] = 0; + } + expected[expected_len] = 0x2323; + + ok(len == expected_len, "i=0x%02x: expected len=%i, got len=%i\n", i, expected_len, len); + ok(memcmp(output, expected, (expected_len + 1) * sizeof(WCHAR)) == 0, + "i=0x%02x: expected output=%s, got output=%s\n", + i, wine_dbgstr_wn(expected, expected_len + 1), wine_dbgstr_wn(output, expected_len + 1)); + } + + /* test which one-byte characters terminate a sequence + * also test whether the unfinished byte pair is discarded or not */ + for (i = 0; i < 256; i++) + { + sprintf(input, "+B%c+AAA", i); + + memset(output, 0x23, sizeof(output) - sizeof(WCHAR)); + output[sizeof(output) / sizeof(WCHAR) - 1] = 0; + + len = MultiByteToWideChar(CP_UTF7, 0, input, 8, output, sizeof(output) / sizeof(WCHAR) - 1); + + if (i == '-') + { + /* explicitly terminates */ + expected_len = 2; + expected[0] = 0; + expected[1] = 0; + } + else if (i <= 0x7F) + { + if (base64_decoding_table[i] != -1) + { + /* absorbs the character into the base64 sequence */ + expected_len = 3; + expected[0] = 0x0400 | (base64_decoding_table[i] << 4) | 0x000F; + expected[1] = 0x8000; + expected[2] = 0; + } + else + { + /* implicitly terminates and discards the unfinished byte pair */ + expected_len = 3; + expected[0] = i; + expected[1] = 0; + expected[2] = 0; + } + } + else + { + /* implicitly terminates but does not the discard unfinished byte pair */ + expected_len = 3; + expected[0] = i; + expected[1] = 0x0400; + expected[2] = 0; + } + expected[expected_len] = 0x2323; + + ok(len == expected_len, "i=0x%02x: expected len=%i, got len=%i\n", i, expected_len, len); + ok(memcmp(output, expected, (expected_len + 1) * sizeof(WCHAR)) == 0, + "i=0x%02x: expected output=%s, got output=%s\n", + i, wine_dbgstr_wn(expected, expected_len + 1), wine_dbgstr_wn(output, expected_len + 1)); + } +} + static void test_undefined_byte_char(void) { static const struct tag_testset { @@ -618,6 +853,9 @@ test_string_conversion(NULL); test_string_conversion(&bUsedDefaultChar); + test_utf7_encoding(); + test_utf7_decoding(); + test_undefined_byte_char(); test_threadcp(); } diff -Nru wine1.7-1.7.28/dlls/kernel32/tests/file.c wine1.7-1.7.31/dlls/kernel32/tests/file.c --- wine1.7-1.7.28/dlls/kernel32/tests/file.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/tests/file.c 2014-11-14 13:28:17.000000000 +0000 @@ -2562,7 +2562,7 @@ ok ( err == ERROR_NO_MORE_FILES, "GetLastError should return ERROR_NO_MORE_FILES\n"); } -static void test_FindFirstFileExA(FINDEX_SEARCH_OPS search_ops, DWORD flags) +static void test_FindFirstFileExA(FINDEX_INFO_LEVELS level, FINDEX_SEARCH_OPS search_ops, DWORD flags) { WIN32_FIND_DATAA search_results; HANDLE handle; @@ -2574,12 +2574,15 @@ return; } + trace("Running FindFirstFileExA tests with level=%d, search_ops=%d, flags=%u\n", + level, search_ops, flags); + CreateDirectoryA("test-dir", NULL); _lclose(_lcreat("test-dir\\file1", 0)); _lclose(_lcreat("test-dir\\file2", 0)); CreateDirectoryA("test-dir\\dir1", NULL); SetLastError(0xdeadbeef); - handle = pFindFirstFileExA("test-dir\\*", FindExInfoStandard, &search_results, search_ops, NULL, flags); + handle = pFindFirstFileExA("test-dir\\*", level, &search_results, search_ops, NULL, flags); if (handle == INVALID_HANDLE_VALUE && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) { win_skip("FindFirstFileExA is not implemented\n"); @@ -2590,16 +2593,26 @@ win_skip("FindFirstFileExA flag FIND_FIRST_EX_LARGE_FETCH not supported, skipping test\n"); goto cleanup; } - ok(handle != INVALID_HANDLE_VALUE, "FindFirstFile failed (err=%u)\n", GetLastError()); - ok(strcmp(search_results.cFileName, ".") == 0, "First entry should be '.', is %s\n", search_results.cFileName); + if ((level == FindExInfoBasic) && handle == INVALID_HANDLE_VALUE && GetLastError() == ERROR_INVALID_PARAMETER) + { + win_skip("FindFirstFileExA level FindExInfoBasic not supported, skipping test\n"); + goto cleanup; + } #define CHECK_NAME(fn) (strcmp((fn), "file1") == 0 || strcmp((fn), "file2") == 0 || strcmp((fn), "dir1") == 0) +#define CHECK_LEVEL(fn) (level != FindExInfoBasic || !(fn)[0]) + + ok(handle != INVALID_HANDLE_VALUE, "FindFirstFile failed (err=%u)\n", GetLastError()); + ok(strcmp(search_results.cFileName, ".") == 0, "First entry should be '.', is %s\n", search_results.cFileName); + ok(CHECK_LEVEL(search_results.cAlternateFileName), "FindFirstFile unexpectedly returned an alternate filename\n"); ok(FindNextFileA(handle, &search_results), "Fetching second file failed\n"); ok(strcmp(search_results.cFileName, "..") == 0, "Second entry should be '..' is %s\n", search_results.cFileName); + ok(CHECK_LEVEL(search_results.cAlternateFileName), "FindFirstFile unexpectedly returned an alternate filename\n"); ok(FindNextFileA(handle, &search_results), "Fetching third file failed\n"); ok(CHECK_NAME(search_results.cFileName), "Invalid third entry - %s\n", search_results.cFileName); + ok(CHECK_LEVEL(search_results.cAlternateFileName), "FindFirstFile unexpectedly returned an alternate filename\n"); SetLastError(0xdeadbeef); ret = FindNextFileA(handle, &search_results); @@ -2608,26 +2621,31 @@ skip("File system supports directory filtering\n"); /* Results from the previous call are not cleared */ ok(strcmp(search_results.cFileName, "dir1") == 0, "Third entry should be 'dir1' is %s\n", search_results.cFileName); + ok(CHECK_LEVEL(search_results.cAlternateFileName), "FindFirstFile unexpectedly returned an alternate filename\n"); + } else { ok(ret, "Fetching fourth file failed\n"); ok(CHECK_NAME(search_results.cFileName), "Invalid fourth entry - %s\n", search_results.cFileName); + ok(CHECK_LEVEL(search_results.cAlternateFileName), "FindFirstFile unexpectedly returned an alternate filename\n"); ok(FindNextFileA(handle, &search_results), "Fetching fifth file failed\n"); ok(CHECK_NAME(search_results.cFileName), "Invalid fifth entry - %s\n", search_results.cFileName); + ok(CHECK_LEVEL(search_results.cAlternateFileName), "FindFirstFile unexpectedly returned an alternate filename\n"); ok(FindNextFileA(handle, &search_results) == FALSE, "Fetching sixth file should fail\n"); } #undef CHECK_NAME +#undef CHECK_LEVEL FindClose( handle ); /* Most Windows systems seem to ignore the FIND_FIRST_EX_CASE_SENSITIVE flag. Unofficial documentation * suggests that there are registry keys and that it might depend on the used filesystem. */ SetLastError(0xdeadbeef); - handle = pFindFirstFileExA("TEST-DIR\\*", FindExInfoStandard, &search_results, search_ops, NULL, flags); + handle = pFindFirstFileExA("TEST-DIR\\*", level, &search_results, search_ops, NULL, flags); if (flags & FIND_FIRST_EX_CASE_SENSITIVE) { ok(handle != INVALID_HANDLE_VALUE || GetLastError() == ERROR_PATH_NOT_FOUND, @@ -4192,13 +4210,15 @@ test_MoveFileW(); test_FindFirstFileA(); test_FindNextFileA(); - test_FindFirstFileExA(0, 0); - test_FindFirstFileExA(0, FIND_FIRST_EX_CASE_SENSITIVE); - test_FindFirstFileExA(0, FIND_FIRST_EX_LARGE_FETCH); + test_FindFirstFileExA(FindExInfoStandard, 0, 0); + test_FindFirstFileExA(FindExInfoStandard, 0, FIND_FIRST_EX_CASE_SENSITIVE); + test_FindFirstFileExA(FindExInfoStandard, 0, FIND_FIRST_EX_LARGE_FETCH); + test_FindFirstFileExA(FindExInfoBasic, 0, 0); /* FindExLimitToDirectories is ignored if the file system doesn't support directory filtering */ - test_FindFirstFileExA(FindExSearchLimitToDirectories, 0); - test_FindFirstFileExA(FindExSearchLimitToDirectories, FIND_FIRST_EX_CASE_SENSITIVE); - test_FindFirstFileExA(FindExSearchLimitToDirectories, FIND_FIRST_EX_LARGE_FETCH); + test_FindFirstFileExA(FindExInfoStandard, FindExSearchLimitToDirectories, 0); + test_FindFirstFileExA(FindExInfoStandard, FindExSearchLimitToDirectories, FIND_FIRST_EX_CASE_SENSITIVE); + test_FindFirstFileExA(FindExInfoStandard, FindExSearchLimitToDirectories, FIND_FIRST_EX_LARGE_FETCH); + test_FindFirstFileExA(FindExInfoBasic, FindExSearchLimitToDirectories, 0); test_LockFile(); test_file_sharing(); test_offset_in_overlapped_structure(); diff -Nru wine1.7-1.7.28/dlls/kernel32/tests/format_msg.c wine1.7-1.7.31/dlls/kernel32/tests/format_msg.c --- wine1.7-1.7.28/dlls/kernel32/tests/format_msg.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/tests/format_msg.c 2014-11-14 13:28:17.000000000 +0000 @@ -1552,6 +1552,11 @@ MAKELANGID(LANG_NEUTRAL, SUBLANG_NEUTRAL), out, sizeof(out)/sizeof(CHAR), NULL); ok(ret != 0, "FormatMessageA returned 0\n"); + /* Test HRESULT. It's not documented but in practice _com_error::ErrorMessage relies on this. */ + ret = FormatMessageA(FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_FROM_HMODULE, h, 0x80070005 /* E_ACCESSDENIED */, + MAKELANGID(LANG_NEUTRAL, SUBLANG_NEUTRAL), out, sizeof(out)/sizeof(CHAR), NULL); + ok(ret != 0, "FormatMessageA returned 0\n"); + /* Test a message string with an insertion without passing any variadic arguments. */ ret = FormatMessageA(FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_FROM_HMODULE, h, 193 /* ERROR_BAD_EXE_FORMAT */, MAKELANGID(LANG_NEUTRAL, SUBLANG_NEUTRAL), out, sizeof(out)/sizeof(CHAR), NULL); diff -Nru wine1.7-1.7.28/dlls/kernel32/tests/module.c wine1.7-1.7.31/dlls/kernel32/tests/module.c --- wine1.7-1.7.28/dlls/kernel32/tests/module.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/tests/module.c 2014-11-14 13:28:17.000000000 +0000 @@ -20,12 +20,15 @@ #include "wine/test.h" #include +#include static DWORD (WINAPI *pGetDllDirectoryA)(DWORD,LPSTR); static DWORD (WINAPI *pGetDllDirectoryW)(DWORD,LPWSTR); static BOOL (WINAPI *pSetDllDirectoryA)(LPCSTR); static BOOL (WINAPI *pGetModuleHandleExA)(DWORD,LPCSTR,HMODULE*); static BOOL (WINAPI *pGetModuleHandleExW)(DWORD,LPCWSTR,HMODULE*); +static BOOL (WINAPI *pK32GetModuleInformation)(HANDLE process, HMODULE module, + MODULEINFO *modinfo, DWORD cb); static BOOL is_unicode_enabled = TRUE; @@ -514,7 +517,20 @@ MAKEFUNC(SetDllDirectoryA); MAKEFUNC(GetModuleHandleExA); MAKEFUNC(GetModuleHandleExW); + MAKEFUNC(K32GetModuleInformation); #undef MAKEFUNC + + /* not all Windows versions export this in kernel32 */ + if (!pK32GetModuleInformation) + { + HMODULE hPsapi = LoadLibraryA("psapi.dll"); + if (hPsapi) + { + pK32GetModuleInformation = (void *)GetProcAddress(hPsapi, "GetModuleInformation"); + if (!pK32GetModuleInformation) FreeLibrary(hPsapi); + } + } + } static void testGetModuleHandleEx(void) @@ -696,6 +712,33 @@ FreeLibrary( mod_kernel32 ); } +static void testK32GetModuleInformation(void) +{ + MODULEINFO info; + HMODULE mod; + BOOL ret; + + if (!pK32GetModuleInformation) + { + win_skip("K32GetModuleInformation not available\n"); + return; + } + + mod = GetModuleHandleA(NULL); + memset(&info, 0xAA, sizeof(info)); + ret = pK32GetModuleInformation(GetCurrentProcess(), mod, &info, sizeof(info)); + ok(ret, "K32GetModuleInformation failed for main module\n"); + ok(info.lpBaseOfDll == mod, "Wrong info.lpBaseOfDll = %p, expected %p\n", info.lpBaseOfDll, mod); + ok(info.EntryPoint != NULL, "Expected nonzero entrypoint\n"); + + mod = GetModuleHandleA("kernel32.dll"); + memset(&info, 0xAA, sizeof(info)); + ret = pK32GetModuleInformation(GetCurrentProcess(), mod, &info, sizeof(info)); + ok(ret, "K32GetModuleInformation failed for kernel32 module\n"); + ok(info.lpBaseOfDll == mod, "Wrong info.lpBaseOfDll = %p, expected %p\n", info.lpBaseOfDll, mod); + ok(info.EntryPoint != NULL, "Expected nonzero entrypoint\n"); +} + START_TEST(module) { WCHAR filenameW[MAX_PATH]; @@ -724,4 +767,5 @@ testGetProcAddress_Wrong(); testLoadLibraryEx(); testGetModuleHandleEx(); + testK32GetModuleInformation(); } diff -Nru wine1.7-1.7.28/dlls/kernel32/tests/path.c wine1.7-1.7.31/dlls/kernel32/tests/path.c --- wine1.7-1.7.28/dlls/kernel32/tests/path.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/tests/path.c 2014-11-14 13:28:17.000000000 +0000 @@ -1828,6 +1828,7 @@ char output[MAX_PATH], *filepart; DWORD ret; int i; + UINT acp; const struct { @@ -1864,6 +1865,27 @@ "[%d] Expected GetLastError() to return 0xdeadbeef, got %u\n", i, GetLastError()); } + + acp = GetACP(); + if (acp != 932) + skip("Skipping DBCS(Japanese) GetFullPathNameA test in this codepage (%d)\n", acp); + else { + const struct dbcs_case { + const char *input; + const char *expected; + } testset[] = { + { "c:\\a\\\x95\x5c\x97\xa0.txt", "\x95\x5c\x97\xa0.txt" }, + { "c:\\\x83\x8f\x83\x43\x83\x93\\wine.c", "wine.c" }, + { "c:\\demo\\\x97\xa0\x95\x5c", "\x97\xa0\x95\x5c" } + }; + for (i = 0; i < sizeof(testset)/sizeof(testset[0]); i++) { + ret = GetFullPathNameA(testset[i].input, sizeof(output), + output, &filepart); + ok(ret, "[%d] GetFullPathName error %u\n", i, GetLastError()); + ok(!lstrcmpA(filepart, testset[i].expected), + "[%d] expected %s got %s\n", i, testset[i].expected, filepart); + } + } } static void test_GetFullPathNameW(void) diff -Nru wine1.7-1.7.28/dlls/kernel32/tests/version.c wine1.7-1.7.31/dlls/kernel32/tests/version.c --- wine1.7-1.7.28/dlls/kernel32/tests/version.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/tests/version.c 2014-11-14 13:28:17.000000000 +0000 @@ -23,23 +23,29 @@ #include "wine/test.h" #include "winbase.h" +#include "winternl.h" static BOOL (WINAPI * pGetProductInfo)(DWORD, DWORD, DWORD, DWORD, DWORD *); static BOOL (WINAPI * pVerifyVersionInfoA)(LPOSVERSIONINFOEXA, DWORD, DWORDLONG); static ULONGLONG (WINAPI * pVerSetConditionMask)(ULONGLONG, DWORD, BYTE); +static NTSTATUS (WINAPI * pRtlGetVersion)(RTL_OSVERSIONINFOEXW *); -#define KERNEL32_GET_PROC(func) \ - p##func = (void *)GetProcAddress(hKernel32, #func); +#define GET_PROC(func) \ + p##func = (void *)GetProcAddress(hmod, #func); static void init_function_pointers(void) { - HMODULE hKernel32; + HMODULE hmod; - hKernel32 = GetModuleHandleA("kernel32.dll"); + hmod = GetModuleHandleA("kernel32.dll"); - KERNEL32_GET_PROC(GetProductInfo); - KERNEL32_GET_PROC(VerifyVersionInfoA); - KERNEL32_GET_PROC(VerSetConditionMask); + GET_PROC(GetProductInfo); + GET_PROC(VerifyVersionInfoA); + GET_PROC(VerSetConditionMask); + + hmod = GetModuleHandleA("ntdll.dll"); + + GET_PROC(RtlGetVersion); } static void test_GetProductInfo(void) @@ -170,6 +176,21 @@ info.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEXA); GetVersionExA((OSVERSIONINFOA *)&info); servicepack = info.wServicePackMajor; + + /* Win8.1+ returns Win8 version in GetVersionEx when there's no app manifest targeting 8.1 */ + if (info.dwMajorVersion == 6 && info.dwMinorVersion == 2) + { + RTL_OSVERSIONINFOEXW rtlinfo; + rtlinfo.dwOSVersionInfoSize = sizeof(RTL_OSVERSIONINFOEXW); + ok(SUCCEEDED(pRtlGetVersion(&rtlinfo)), "RtlGetVersion failed\n"); + + if (rtlinfo.dwMajorVersion != 6 || rtlinfo.dwMinorVersion != 2) + { + win_skip("GetVersionEx and VerifyVersionInfo are faking values\n"); + return; + } + } + memset(&info, 0, sizeof(info)); ret = pVerifyVersionInfoA(&info, VER_MAJORVERSION | VER_MINORVERSION, diff -Nru wine1.7-1.7.28/dlls/kernel32/tests/virtual.c wine1.7-1.7.31/dlls/kernel32/tests/virtual.c --- wine1.7-1.7.28/dlls/kernel32/tests/virtual.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/kernel32/tests/virtual.c 2014-11-14 13:28:17.000000000 +0000 @@ -25,14 +25,17 @@ #define WIN32_NO_STATUS #include "windef.h" #include "winbase.h" +#include "winnt.h" #include "winternl.h" #include "winerror.h" +#include "winuser.h" +#include "excpt.h" #include "wine/test.h" #define NUM_THREADS 4 #define MAPPING_SIZE 0x100000 -static HINSTANCE hkernel32; +static HINSTANCE hkernel32, hntdll; static LPVOID (WINAPI *pVirtualAllocEx)(HANDLE, LPVOID, SIZE_T, DWORD, DWORD); static BOOL (WINAPI *pVirtualFreeEx)(HANDLE, LPVOID, SIZE_T, DWORD); static UINT (WINAPI *pGetWriteWatch)(DWORD,LPVOID,SIZE_T,LPVOID*,ULONG_PTR*,ULONG*); @@ -40,6 +43,10 @@ static NTSTATUS (WINAPI *pNtAreMappedFilesTheSame)(PVOID,PVOID); static NTSTATUS (WINAPI *pNtMapViewOfSection)(HANDLE, HANDLE, PVOID *, ULONG, SIZE_T, const LARGE_INTEGER *, SIZE_T *, ULONG, ULONG, ULONG); static DWORD (WINAPI *pNtUnmapViewOfSection)(HANDLE, PVOID); +static struct _TEB * (WINAPI *pNtCurrentTeb)(void); +static PVOID (WINAPI *pRtlAddVectoredExceptionHandler)(ULONG, PVECTORED_EXCEPTION_HANDLER); +static ULONG (WINAPI *pRtlRemoveVectoredExceptionHandler)(PVOID); +static BOOL (WINAPI *pGetProcessDEPPolicy)(HANDLE, LPDWORD, PBOOL); /* ############################### */ @@ -1543,6 +1550,890 @@ VirtualFree( base, 0, MEM_FREE ); } +#ifdef __i386__ + +static DWORD num_guard_page_calls; + +static DWORD guard_page_handler( EXCEPTION_RECORD *rec, EXCEPTION_REGISTRATION_RECORD *frame, + CONTEXT *context, EXCEPTION_REGISTRATION_RECORD **dispatcher ) +{ + trace( "exception: %08x flags:%x addr:%p\n", + rec->ExceptionCode, rec->ExceptionFlags, rec->ExceptionAddress ); + + ok( rec->NumberParameters == 2, "NumberParameters is %d instead of 2\n", rec->NumberParameters ); + ok( rec->ExceptionCode == STATUS_GUARD_PAGE_VIOLATION, "ExceptionCode is %08x instead of %08x\n", + rec->ExceptionCode, STATUS_GUARD_PAGE_VIOLATION ); + + num_guard_page_calls++; + *(int *)rec->ExceptionInformation[1] += 0x100; + + return ExceptionContinueExecution; +} + +static void test_guard_page(void) +{ + EXCEPTION_REGISTRATION_RECORD frame; + MEMORY_BASIC_INFORMATION info; + DWORD ret, size, old_prot; + int *value, old_value; + void *results[64]; + ULONG_PTR count; + ULONG pagesize; + BOOL success; + char *base; + + if (!pNtCurrentTeb) + { + win_skip( "NtCurrentTeb not supported\n" ); + return; + } + + size = 0x1000; + base = VirtualAlloc( 0, size, MEM_RESERVE | MEM_COMMIT, PAGE_READWRITE | PAGE_GUARD ); + ok( base != NULL, "VirtualAlloc failed %u\n", GetLastError() ); + value = (int *)base; + + /* verify info structure */ + ret = VirtualQuery( base, &info, sizeof(info) ); + ok( ret, "VirtualQuery failed %u\n", GetLastError()); + ok( info.BaseAddress == base, "BaseAddress %p instead of %p\n", info.BaseAddress, base ); + ok( info.AllocationProtect == (PAGE_READWRITE | PAGE_GUARD), "wrong AllocationProtect %x\n", info.AllocationProtect ); + ok( info.RegionSize == size, "wrong RegionSize 0x%lx\n", info.RegionSize ); + ok( info.State == MEM_COMMIT, "wrong State 0x%x\n", info.State ); + ok( info.Protect == (PAGE_READWRITE | PAGE_GUARD), "wrong Protect 0x%x\n", info.Protect ); + ok( info.Type == MEM_PRIVATE, "wrong Type 0x%x\n", info.Type ); + + /* put some initial value into the memory */ + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + ok( old_prot == (PAGE_READWRITE | PAGE_GUARD), "wrong old prot %x\n", old_prot ); + + *value = 1; + *(value + 1) = 2; + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + ok( old_prot == PAGE_READWRITE, "wrong old prot %x\n", old_prot ); + + /* test behaviour of VirtualLock - first attempt should fail */ + SetLastError( 0xdeadbeef ); + success = VirtualLock( base, size ); + ok( !success, "VirtualLock unexpectedly succeded\n" ); + todo_wine + ok( GetLastError() == STATUS_GUARD_PAGE_VIOLATION, "wrong error %u\n", GetLastError() ); + + success = VirtualLock( base, size ); + todo_wine + ok( success, "VirtualLock failed %u\n", GetLastError() ); + if (success) + { + ok( *value == 1, "memory block contains wrong value, expected 1, got 0x%x\n", *value ); + success = VirtualUnlock( base, size ); + ok( success, "VirtualUnlock failed %u\n", GetLastError() ); + } + + /* check info structure again, PAGE_GUARD should be removed now */ + ret = VirtualQuery( base, &info, sizeof(info) ); + ok( ret, "VirtualQuery failed %u\n", GetLastError()); + ok( info.BaseAddress == base, "BaseAddress %p instead of %p\n", info.BaseAddress, base ); + ok( info.AllocationProtect == (PAGE_READWRITE | PAGE_GUARD), "wrong AllocationProtect %x\n", info.AllocationProtect ); + ok( info.RegionSize == size, "wrong RegionSize 0x%lx\n", info.RegionSize ); + ok( info.State == MEM_COMMIT, "wrong State 0x%x\n", info.State ); + todo_wine + ok( info.Protect == PAGE_READWRITE, "wrong Protect 0x%x\n", info.Protect ); + ok( info.Type == MEM_PRIVATE, "wrong Type 0x%x\n", info.Type ); + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + todo_wine + ok( old_prot == PAGE_READWRITE, "wrong old prot %x\n", old_prot ); + + /* test directly accessing the memory - we need to setup an exception handler first */ + frame.Handler = guard_page_handler; + frame.Prev = pNtCurrentTeb()->Tib.ExceptionList; + pNtCurrentTeb()->Tib.ExceptionList = &frame; + + num_guard_page_calls = 0; + old_value = *value; /* exception handler increments value by 0x100 */ + *value = 2; + ok( old_value == 0x101, "memory block contains wrong value, expected 0x101, got 0x%x\n", old_value ); + ok( num_guard_page_calls == 1, "expected one callback of guard page handler, got %d calls\n", num_guard_page_calls ); + + pNtCurrentTeb()->Tib.ExceptionList = frame.Prev; + + /* check info structure again, PAGE_GUARD should be removed now */ + ret = VirtualQuery( base, &info, sizeof(info) ); + ok( ret, "VirtualQuery failed %u\n", GetLastError()); + ok( info.Protect == PAGE_READWRITE, "wrong Protect 0x%x\n", info.Protect ); + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + ok( old_prot == PAGE_READWRITE, "wrong old prot %x\n", old_prot ); + + /* test accessing second integer in memory */ + frame.Handler = guard_page_handler; + frame.Prev = pNtCurrentTeb()->Tib.ExceptionList; + pNtCurrentTeb()->Tib.ExceptionList = &frame; + + num_guard_page_calls = 0; + old_value = *(value + 1); + ok( old_value == 0x102, "memory block contains wrong value, expected 0x102, got 0x%x\n", old_value ); + ok( *value == 2, "memory block contains wrong value, expected 2, got 0x%x\n", *value ); + ok( num_guard_page_calls == 1, "expected one callback of guard page handler, got %d calls\n", num_guard_page_calls ); + + pNtCurrentTeb()->Tib.ExceptionList = frame.Prev; + + success = VirtualLock( base, size ); + ok( success, "VirtualLock failed %u\n", GetLastError() ); + if (success) + { + ok( *value == 2, "memory block contains wrong value, expected 2, got 0x%x\n", *value ); + success = VirtualUnlock( base, size ); + ok( success, "VirtualUnlock failed %u\n", GetLastError() ); + } + + VirtualFree( base, 0, MEM_FREE ); + + /* combined guard page / write watch tests */ + if (!pGetWriteWatch || !pResetWriteWatch) + { + win_skip( "GetWriteWatch not supported, skipping combined guard page / write watch tests\n" ); + return; + } + + base = VirtualAlloc( 0, size, MEM_RESERVE | MEM_COMMIT | MEM_WRITE_WATCH, PAGE_READWRITE | PAGE_GUARD ); + if (!base && (GetLastError() == ERROR_INVALID_PARAMETER || GetLastError() == ERROR_NOT_SUPPORTED)) + { + win_skip( "MEM_WRITE_WATCH not supported\n" ); + return; + } + ok( base != NULL, "VirtualAlloc failed %u\n", GetLastError() ); + value = (int *)base; + + ret = VirtualQuery( base, &info, sizeof(info) ); + ok( ret, "VirtualQuery failed %u\n", GetLastError() ); + ok( info.BaseAddress == base, "BaseAddress %p instead of %p\n", info.BaseAddress, base ); + ok( info.AllocationProtect == (PAGE_READWRITE | PAGE_GUARD), "wrong AllocationProtect %x\n", info.AllocationProtect ); + ok( info.RegionSize == size, "wrong RegionSize 0x%lx\n", info.RegionSize ); + ok( info.State == MEM_COMMIT, "wrong State 0x%x\n", info.State ); + ok( info.Protect == (PAGE_READWRITE | PAGE_GUARD), "wrong Protect 0x%x\n", info.Protect ); + ok( info.Type == MEM_PRIVATE, "wrong Type 0x%x\n", info.Type ); + + count = 64; + ret = pGetWriteWatch( 0, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 0, "wrong count %lu\n", count ); + + /* writing to a page should trigger should trigger guard page, even if write watch is set */ + frame.Handler = guard_page_handler; + frame.Prev = pNtCurrentTeb()->Tib.ExceptionList; + pNtCurrentTeb()->Tib.ExceptionList = &frame; + + num_guard_page_calls = 0; + *value = 1; + *(value + 1) = 2; + ok( num_guard_page_calls == 1, "expected one callback of guard page handler, got %d calls\n", num_guard_page_calls ); + + pNtCurrentTeb()->Tib.ExceptionList = frame.Prev; + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 1, "wrong count %lu\n", count ); + ok( results[0] == base, "wrong result %p\n", results[0] ); + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + /* write watch is triggered from inside of the guard page handler */ + frame.Handler = guard_page_handler; + frame.Prev = pNtCurrentTeb()->Tib.ExceptionList; + pNtCurrentTeb()->Tib.ExceptionList = &frame; + + num_guard_page_calls = 0; + old_value = *(value + 1); /* doesn't trigger write watch */ + ok( old_value == 0x102, "memory block contains wrong value, expected 0x102, got 0x%x\n", old_value ); + ok( *value == 1, "memory block contains wrong value, expected 1, got 0x%x\n", *value ); + ok( num_guard_page_calls == 1, "expected one callback of guard page handler, got %d calls\n", num_guard_page_calls ); + + pNtCurrentTeb()->Tib.ExceptionList = frame.Prev; + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 1, "wrong count %lu\n", count ); + ok( results[0] == base, "wrong result %p\n", results[0] ); + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + /* test behaviour of VirtualLock - first attempt should fail without triggering write watches */ + SetLastError( 0xdeadbeef ); + success = VirtualLock( base, size ); + ok( !success, "VirtualLock unexpectedly succeded\n" ); + todo_wine + ok( GetLastError() == STATUS_GUARD_PAGE_VIOLATION, "wrong error %u\n", GetLastError() ); + + count = 64; + ret = pGetWriteWatch( 0, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 0, "wrong count %lu\n", count ); + + success = VirtualLock( base, size ); + todo_wine + ok( success, "VirtualLock failed %u\n", GetLastError() ); + if (success) + { + ok( *value == 1, "memory block contains wrong value, expected 1, got 0x%x\n", *value ); + success = VirtualUnlock( base, size ); + ok( success, "VirtualUnlock failed %u\n", GetLastError() ); + } + + count = 64; + results[0] = (void *)0xdeadbeef; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + todo_wine + ok( count == 1 || broken(count == 0) /* Windows 8 */, "wrong count %lu\n", count ); + todo_wine + ok( results[0] == base || broken(results[0] == (void *)0xdeadbeef) /* Windows 8 */, "wrong result %p\n", results[0] ); + + VirtualFree( base, 0, MEM_FREE ); +} + +DWORD num_execute_fault_calls; + +static DWORD execute_fault_seh_handler( EXCEPTION_RECORD *rec, EXCEPTION_REGISTRATION_RECORD *frame, + CONTEXT *context, EXCEPTION_REGISTRATION_RECORD **dispatcher ) +{ + ULONG flags = MEM_EXECUTE_OPTION_ENABLE; + DWORD err; + + trace( "exception: %08x flags:%x addr:%p info[0]:%ld info[1]:%p\n", + rec->ExceptionCode, rec->ExceptionFlags, rec->ExceptionAddress, + rec->ExceptionInformation[0], (void *)rec->ExceptionInformation[1] ); + + ok( rec->NumberParameters == 2, "NumberParameters is %d instead of 2\n", rec->NumberParameters ); + ok( rec->ExceptionCode == STATUS_ACCESS_VIOLATION || rec->ExceptionCode == STATUS_GUARD_PAGE_VIOLATION, + "ExceptionCode is %08x instead of STATUS_ACCESS_VIOLATION or STATUS_GUARD_PAGE_VIOLATION\n", rec->ExceptionCode ); + + NtQueryInformationProcess( GetCurrentProcess(), ProcessExecuteFlags, &flags, sizeof(flags), NULL ); + + if (rec->ExceptionCode == STATUS_GUARD_PAGE_VIOLATION) + { + + err = IsProcessorFeaturePresent( PF_NX_ENABLED ) ? EXCEPTION_EXECUTE_FAULT : EXCEPTION_READ_FAULT; + ok( rec->ExceptionInformation[0] == err, "ExceptionInformation[0] is %d instead of %d\n", + (DWORD)rec->ExceptionInformation[0], err ); + + num_guard_page_calls++; + } + else if (rec->ExceptionCode == STATUS_ACCESS_VIOLATION) + { + DWORD old_prot; + BOOL success; + + err = (flags & MEM_EXECUTE_OPTION_DISABLE) ? EXCEPTION_EXECUTE_FAULT : EXCEPTION_READ_FAULT; + ok( rec->ExceptionInformation[0] == err, "ExceptionInformation[0] is %d instead of %d\n", + (DWORD)rec->ExceptionInformation[0], err ); + + success = VirtualProtect( (void *)rec->ExceptionInformation[1], 16, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + ok( old_prot == PAGE_READWRITE, "wrong old prot %x\n", old_prot ); + + num_execute_fault_calls++; + } + + return ExceptionContinueExecution; +} + +static LONG CALLBACK execute_fault_vec_handler( EXCEPTION_POINTERS *ExceptionInfo ) +{ + PEXCEPTION_RECORD rec = ExceptionInfo->ExceptionRecord; + DWORD old_prot; + BOOL success; + + trace( "exception: %08x flags:%x addr:%p info[0]:%ld info[1]:%p\n", + rec->ExceptionCode, rec->ExceptionFlags, rec->ExceptionAddress, + rec->ExceptionInformation[0], (void *)rec->ExceptionInformation[1] ); + + ok( rec->NumberParameters == 2, "NumberParameters is %d instead of 2\n", rec->NumberParameters ); + ok( rec->ExceptionCode == STATUS_ACCESS_VIOLATION, + "ExceptionCode is %08x instead of STATUS_ACCESS_VIOLATION\n", rec->ExceptionCode ); + + if (rec->ExceptionCode == STATUS_ACCESS_VIOLATION) + num_execute_fault_calls++; + + if (rec->ExceptionInformation[0] == EXCEPTION_READ_FAULT) + return EXCEPTION_CONTINUE_SEARCH; + + success = VirtualProtect( (void *)rec->ExceptionInformation[1], 16, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + ok( old_prot == PAGE_NOACCESS, "wrong old prot %x\n", old_prot ); + + return EXCEPTION_CONTINUE_EXECUTION; +} + +static inline DWORD send_message_excpt( HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam ) +{ + EXCEPTION_REGISTRATION_RECORD frame; + DWORD ret; + + frame.Handler = execute_fault_seh_handler; + frame.Prev = pNtCurrentTeb()->Tib.ExceptionList; + pNtCurrentTeb()->Tib.ExceptionList = &frame; + + num_guard_page_calls = num_execute_fault_calls = 0; + ret = SendMessageA( hWnd, uMsg, wParam, lParam ); + + pNtCurrentTeb()->Tib.ExceptionList = frame.Prev; + + return ret; +} + +static inline DWORD call_proc_excpt( DWORD (CALLBACK *code)(void *), void *arg ) +{ + EXCEPTION_REGISTRATION_RECORD frame; + DWORD ret; + + frame.Handler = execute_fault_seh_handler; + frame.Prev = pNtCurrentTeb()->Tib.ExceptionList; + pNtCurrentTeb()->Tib.ExceptionList = &frame; + + num_guard_page_calls = num_execute_fault_calls = 0; + ret = code( arg ); + + pNtCurrentTeb()->Tib.ExceptionList = frame.Prev; + + return ret; +} + +static LRESULT CALLBACK jmp_test_func( HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam ) +{ + if (uMsg == WM_USER) + return 42; + + return DefWindowProcA( hWnd, uMsg, wParam, lParam ); +} + +static LRESULT CALLBACK atl_test_func( HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam ) +{ + DWORD arg = (DWORD)hWnd; + if (uMsg == WM_USER) + ok( arg == 0x11223344, "arg is 0x%08x instead of 0x11223344\n", arg ); + else + ok( arg != 0x11223344, "arg is unexpectedly 0x11223344\n" ); + return 43; +} + +static DWORD CALLBACK atl5_test_func( void ) +{ + return 44; +} + +static void test_atl_thunk_emulation( ULONG dep_flags ) +{ + static const char code_jmp[] = {0xE9, 0x00, 0x00, 0x00, 0x00}; + static const char code_atl1[] = {0xC7, 0x44, 0x24, 0x04, 0x44, 0x33, 0x22, 0x11, 0xE9, 0x00, 0x00, 0x00, 0x00}; + static const char code_atl2[] = {0xB9, 0x44, 0x33, 0x22, 0x11, 0xE9, 0x00, 0x00, 0x00, 0x00}; + static const char code_atl3[] = {0xBA, 0x44, 0x33, 0x22, 0x11, 0xB9, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xE1}; + static const char code_atl4[] = {0xB9, 0x44, 0x33, 0x22, 0x11, 0xB8, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xE0}; + static const char code_atl5[] = {0x59, 0x58, 0x51, 0xFF, 0x60, 0x04}; + static const char cls_name[] = "atl_thunk_class"; + DWORD ret, size, old_prot; + ULONG old_flags = MEM_EXECUTE_OPTION_ENABLE; + BOOL success, restore_flags = FALSE; + void *results[64]; + ULONG_PTR count; + ULONG pagesize; + WNDCLASSEXA wc; + char *base; + HWND hWnd; + + if (!pNtCurrentTeb) + { + win_skip( "NtCurrentTeb not supported\n" ); + return; + } + + trace( "Running DEP tests with ProcessExecuteFlags = %d\n", dep_flags ); + + NtQueryInformationProcess( GetCurrentProcess(), ProcessExecuteFlags, &old_flags, sizeof(old_flags), NULL ); + if (old_flags != dep_flags) + { + ret = NtSetInformationProcess( GetCurrentProcess(), ProcessExecuteFlags, &dep_flags, sizeof(dep_flags) ); + if (ret == STATUS_INVALID_INFO_CLASS) /* Windows 2000 */ + { + win_skip( "Skipping DEP tests with ProcessExecuteFlags = %d\n", dep_flags ); + return; + } + ok( !ret, "NtSetInformationProcess failed with status %08x\n", ret ); + restore_flags = TRUE; + } + + size = 0x1000; + base = VirtualAlloc( 0, size, MEM_RESERVE | MEM_COMMIT, PAGE_READWRITE ); + ok( base != NULL, "VirtualAlloc failed %u\n", GetLastError() ); + + /* Check result of GetProcessDEPPolicy */ + if (!pGetProcessDEPPolicy) + win_skip( "GetProcessDEPPolicy not supported\n" ); + else + { + BOOL (WINAPI *get_dep_policy)(HANDLE, LPDWORD, PBOOL) = (void *)base; + BOOL policy_permanent = 0xdeadbeef; + DWORD policy_flags = 0xdeadbeef; + + /* GetProcessDEPPolicy crashes on Windows when a NULL pointer is passed. + * Moreover this function has a bug on Windows 8, which has the effect that + * policy_permanent is set to the content of the CL register instead of 0, + * when the policy is not permanent. To detect that we use an assembler + * wrapper to call the function. */ + + memcpy( base, code_atl2, sizeof(code_atl2) ); + *(DWORD *)(base + 6) = (DWORD_PTR)pGetProcessDEPPolicy - (DWORD_PTR)(base + 10); + + success = VirtualProtect( base, size, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + success = get_dep_policy( GetCurrentProcess(), &policy_flags, &policy_permanent ); + ok( success, "GetProcessDEPPolicy failed %u\n", GetLastError() ); + + ret = 0; + if (dep_flags & MEM_EXECUTE_OPTION_DISABLE) + ret |= PROCESS_DEP_ENABLE; + if (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION) + ret |= PROCESS_DEP_DISABLE_ATL_THUNK_EMULATION; + + ok( policy_flags == ret, "expected policy flags %d, got %d\n", ret, policy_flags ); + ok( !policy_permanent || broken(policy_permanent == 0x44), + "expected policy permanent FALSE, got %d\n", policy_permanent ); + } + + memcpy( base, code_jmp, sizeof(code_jmp) ); + *(DWORD *)(base + 1) = (DWORD_PTR)jmp_test_func - (DWORD_PTR)(base + 5); + + /* On Windows, the ATL Thunk emulation is only enabled while running WndProc functions, + * whereas in Wine such a limitation doesn't exist yet. We want to test in a scenario + * where it is active, so that application which depend on that still work properly. + * We have no exception handler enabled yet, so give proper EXECUTE permissions to + * prevent crashes while creating the window. */ + + success = VirtualProtect( base, size, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + memset( &wc, 0, sizeof(wc) ); + wc.cbSize = sizeof(wc); + wc.style = CS_VREDRAW | CS_HREDRAW; + wc.hInstance = GetModuleHandleA( 0 ); + wc.hCursor = LoadCursorA( NULL, (LPCSTR)IDC_ARROW ); + wc.hbrBackground = NULL; + wc.lpszClassName = cls_name; + wc.lpfnWndProc = (WNDPROC)base; + success = RegisterClassExA(&wc) != 0; + ok( success, "RegisterClassExA failed %u\n", GetLastError() ); + + hWnd = CreateWindowExA(0, cls_name, "Test", WS_TILEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); + ok( hWnd != 0, "CreateWindowExA failed %u\n", GetLastError() ); + + ret = SendMessageA(hWnd, WM_USER, 0, 0); + ok( ret == 42, "SendMessage returned unexpected result %d\n", ret ); + + /* At first try with an instruction which is not recognized as proper ATL thunk + * by the Windows ATL Thunk Emulator. Removing execute permissions will lead to + * STATUS_ACCESS_VIOLATION exceptions when DEP is enabled. */ + + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 42, "call returned wrong result, expected 42, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && !IsProcessorFeaturePresent( PF_NX_ENABLED )) + { + trace( "DEP hardware support is not available\n" ); + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + dep_flags = MEM_EXECUTE_OPTION_ENABLE; + } + else if (dep_flags & MEM_EXECUTE_OPTION_DISABLE) + { + trace( "DEP hardware support is available\n" ); + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + } + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + /* Now a bit more complicated, the page containing the code is protected with + * PAGE_GUARD memory protection. */ + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 42, "call returned wrong result, expected 42, got %d\n", ret ); + ok( num_guard_page_calls == 1, "expected one STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if (dep_flags & MEM_EXECUTE_OPTION_DISABLE) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 42, "call returned wrong result, expected 42, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + /* Now test with a proper ATL thunk instruction. */ + + memcpy( base, code_atl1, sizeof(code_atl1) ); + *(DWORD *)(base + 9) = (DWORD_PTR)atl_test_func - (DWORD_PTR)(base + 13); + + success = VirtualProtect( base, size, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = SendMessageA(hWnd, WM_USER, 0, 0); + ok( ret == 43, "SendMessage returned unexpected result %d\n", ret ); + + /* Try executing with PAGE_READWRITE protection. */ + + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + /* Now a bit more complicated, the page containing the code is protected with + * PAGE_GUARD memory protection. */ + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + /* the same, but with PAGE_GUARD set */ + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 1, "expected one STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + /* The following test shows that on Windows, even a vectored exception handler + * cannot intercept internal exceptions thrown by the ATL thunk emulation layer. */ + + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && !(dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + { + if (pRtlAddVectoredExceptionHandler && pRtlRemoveVectoredExceptionHandler) + { + PVOID vectored_handler; + + success = VirtualProtect( base, size, PAGE_NOACCESS, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + vectored_handler = pRtlAddVectoredExceptionHandler( TRUE, &execute_fault_vec_handler ); + ok( vectored_handler != 0, "RtlAddVectoredExceptionHandler failed\n" ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + + pRtlRemoveVectoredExceptionHandler( vectored_handler ); + + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + } + else + win_skip( "RtlAddVectoredExceptionHandler or RtlRemoveVectoredExceptionHandler not found\n" ); + } + + /* Test alternative ATL thunk instructions. */ + + memcpy( base, code_atl2, sizeof(code_atl2) ); + *(DWORD *)(base + 6) = (DWORD_PTR)atl_test_func - (DWORD_PTR)(base + 10); + + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER + 1, 0, 0 ); + /* FIXME: we don't check the content of the register ECX yet */ + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + memcpy( base, code_atl3, sizeof(code_atl3) ); + *(DWORD *)(base + 6) = (DWORD_PTR)atl_test_func; + + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER + 1, 0, 0 ); + /* FIXME: we don't check the content of the registers ECX/EDX yet */ + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + memcpy( base, code_atl4, sizeof(code_atl4) ); + *(DWORD *)(base + 6) = (DWORD_PTR)atl_test_func; + + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER + 1, 0, 0 ); + /* FIXME: We don't check the content of the registers EAX/ECX yet */ + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else if (dep_flags & MEM_EXECUTE_OPTION_DISABLE) + ok( num_execute_fault_calls == 0 || broken(num_execute_fault_calls == 1) /* Windows XP */, + "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + memcpy( base, code_atl5, sizeof(code_atl5) ); + + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = (DWORD_PTR)atl5_test_func; + ret = call_proc_excpt( (void *)base, &ret - 1 ); + /* FIXME: We don't check the content of the registers EAX/ECX yet */ + ok( ret == 44, "call returned wrong result, expected 44, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else if (dep_flags & MEM_EXECUTE_OPTION_DISABLE) + ok( num_execute_fault_calls == 0 || broken(num_execute_fault_calls == 1) /* Windows XP */, + "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + /* Restore the JMP instruction, set to executable, and then destroy the Window */ + + memcpy( base, code_jmp, sizeof(code_jmp) ); + *(DWORD *)(base + 1) = (DWORD_PTR)jmp_test_func - (DWORD_PTR)(base + 5); + + success = VirtualProtect( base, size, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + DestroyWindow( hWnd ); + + success = UnregisterClassA( cls_name, GetModuleHandleA(0) ); + ok( success, "UnregisterClass failed %u\n", GetLastError() ); + + VirtualFree( base, 0, MEM_FREE ); + + /* Repeat the tests from above with MEM_WRITE_WATCH protected memory. */ + + base = VirtualAlloc( 0, size, MEM_RESERVE | MEM_COMMIT | MEM_WRITE_WATCH, PAGE_READWRITE ); + if (!base && (GetLastError() == ERROR_INVALID_PARAMETER || GetLastError() == ERROR_NOT_SUPPORTED)) + { + win_skip( "MEM_WRITE_WATCH not supported\n" ); + goto out; + } + ok( base != NULL, "VirtualAlloc failed %u\n", GetLastError() ); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 0, "wrong count %lu\n", count ); + + memcpy( base, code_jmp, sizeof(code_jmp) ); + *(DWORD *)(base + 1) = (DWORD_PTR)jmp_test_func - (DWORD_PTR)(base + 5); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 1, "wrong count %lu\n", count ); + ok( results[0] == base, "wrong result %p\n", results[0] ); + + /* Create a new window class and associcated Window (see above) */ + + success = VirtualProtect( base, size, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + memset( &wc, 0, sizeof(wc) ); + wc.cbSize = sizeof(wc); + wc.style = CS_VREDRAW | CS_HREDRAW; + wc.hInstance = GetModuleHandleA( 0 ); + wc.hCursor = LoadCursorA( NULL, (LPCSTR)IDC_ARROW ); + wc.hbrBackground = NULL; + wc.lpszClassName = cls_name; + wc.lpfnWndProc = (WNDPROC)base; + success = RegisterClassExA(&wc) != 0; + ok( success, "RegisterClassExA failed %u\n", GetLastError() ); + + hWnd = CreateWindowExA(0, cls_name, "Test", WS_TILEDWINDOW, 0, 0, 640, 480, 0, 0, 0, 0); + ok( hWnd != 0, "CreateWindowExA failed %u\n", GetLastError() ); + + ret = SendMessageA(hWnd, WM_USER, 0, 0); + ok( ret == 42, "SendMessage returned unexpected result %d\n", ret ); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 0, "wrong count %lu\n", count ); + + /* At first try with an instruction which is not recognized as proper ATL thunk + * by the Windows ATL Thunk Emulator. Removing execute permissions will lead to + * STATUS_ACCESS_VIOLATION exceptions when DEP is enabled. */ + + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 42, "call returned wrong result, expected 42, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if (dep_flags & MEM_EXECUTE_OPTION_DISABLE) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 0, "wrong count %lu\n", count ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 42, "call returned wrong result, expected 42, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + /* Now a bit more complicated, the page containing the code is protected with + * PAGE_GUARD memory protection. */ + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 42, "call returned wrong result, expected 42, got %d\n", ret ); + ok( num_guard_page_calls == 1, "expected one STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if (dep_flags & MEM_EXECUTE_OPTION_DISABLE) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 42, "call returned wrong result, expected 42, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 0 || broken(count == 1) /* Windows 8 */, "wrong count %lu\n", count ); + + /* Now test with a proper ATL thunk instruction. */ + + memcpy( base, code_atl1, sizeof(code_atl1) ); + *(DWORD *)(base + 9) = (DWORD_PTR)atl_test_func - (DWORD_PTR)(base + 13); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 1, "wrong count %lu\n", count ); + ok( results[0] == base, "wrong result %p\n", results[0] ); + + success = VirtualProtect( base, size, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = SendMessageA(hWnd, WM_USER, 0, 0); + ok( ret == 43, "SendMessage returned unexpected result %d\n", ret ); + + /* Try executing with PAGE_READWRITE protection. */ + + success = VirtualProtect( base, size, PAGE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 0, "wrong count %lu\n", count ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + /* Now a bit more complicated, the page containing the code is protected with + * PAGE_GUARD memory protection. */ + + success = VirtualProtect( base, size, PAGE_READWRITE | PAGE_GUARD, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + /* the same, but with PAGE_GUARD set */ + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 1, "expected one STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + if ((dep_flags & MEM_EXECUTE_OPTION_DISABLE) && (dep_flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION)) + ok( num_execute_fault_calls == 1, "expected one STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + else + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + ret = send_message_excpt( hWnd, WM_USER, 0, 0 ); + ok( ret == 43, "call returned wrong result, expected 43, got %d\n", ret ); + ok( num_guard_page_calls == 0, "expected no STATUS_GUARD_PAGE_VIOLATION exception, got %d exceptions\n", num_guard_page_calls ); + ok( num_execute_fault_calls == 0, "expected no STATUS_ACCESS_VIOLATION exception, got %d exceptions\n", num_execute_fault_calls ); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 0 || broken(count == 1) /* Windows 8 */, "wrong count %lu\n", count ); + + /* Restore the JMP instruction, set to executable, and then destroy the Window */ + + memcpy( base, code_jmp, sizeof(code_jmp) ); + *(DWORD *)(base + 1) = (DWORD_PTR)jmp_test_func - (DWORD_PTR)(base + 5); + + count = 64; + ret = pGetWriteWatch( WRITE_WATCH_FLAG_RESET, base, size, results, &count, &pagesize ); + ok( !ret, "GetWriteWatch failed %u\n", GetLastError() ); + ok( count == 1, "wrong count %lu\n", count ); + ok( results[0] == base, "wrong result %p\n", results[0] ); + + success = VirtualProtect( base, size, PAGE_EXECUTE_READWRITE, &old_prot ); + ok( success, "VirtualProtect failed %u\n", GetLastError() ); + + DestroyWindow( hWnd ); + + success = UnregisterClassA( cls_name, GetModuleHandleA(0) ); + ok( success, "UnregisterClass failed %u\n", GetLastError() ); + + VirtualFree( base, 0, MEM_FREE ); + +out: + if (restore_flags) + { + ret = NtSetInformationProcess( GetCurrentProcess(), ProcessExecuteFlags, &old_flags, sizeof(old_flags) ); + ok( !ret, "NtSetInformationProcess failed with status %08x\n", ret ); + } +} + +#endif /* __i386__ */ + static void test_VirtualProtect(void) { static const struct test_data @@ -2573,14 +3464,19 @@ } hkernel32 = GetModuleHandleA("kernel32.dll"); + hntdll = GetModuleHandleA("ntdll.dll"); + pVirtualAllocEx = (void *) GetProcAddress(hkernel32, "VirtualAllocEx"); pVirtualFreeEx = (void *) GetProcAddress(hkernel32, "VirtualFreeEx"); pGetWriteWatch = (void *) GetProcAddress(hkernel32, "GetWriteWatch"); pResetWriteWatch = (void *) GetProcAddress(hkernel32, "ResetWriteWatch"); - pNtAreMappedFilesTheSame = (void *)GetProcAddress( GetModuleHandleA("ntdll.dll"), - "NtAreMappedFilesTheSame" ); - pNtMapViewOfSection = (void *)GetProcAddress(GetModuleHandleA("ntdll.dll"), "NtMapViewOfSection"); - pNtUnmapViewOfSection = (void *)GetProcAddress(GetModuleHandleA("ntdll.dll"), "NtUnmapViewOfSection"); + pGetProcessDEPPolicy = (void *)GetProcAddress( hkernel32, "GetProcessDEPPolicy" ); + pNtAreMappedFilesTheSame = (void *)GetProcAddress( hntdll, "NtAreMappedFilesTheSame" ); + pNtMapViewOfSection = (void *)GetProcAddress( hntdll, "NtMapViewOfSection" ); + pNtUnmapViewOfSection = (void *)GetProcAddress( hntdll, "NtUnmapViewOfSection" ); + pNtCurrentTeb = (void *)GetProcAddress( hntdll, "NtCurrentTeb" ); + pRtlAddVectoredExceptionHandler = (void *)GetProcAddress( hntdll, "RtlAddVectoredExceptionHandler" ); + pRtlRemoveVectoredExceptionHandler = (void *)GetProcAddress( hntdll, "RtlRemoveVectoredExceptionHandler" ); test_shared_memory(FALSE); test_shared_memory_ro(FALSE, FILE_MAP_READ|FILE_MAP_WRITE); @@ -2600,4 +3496,12 @@ test_IsBadWritePtr(); test_IsBadCodePtr(); test_write_watch(); +#ifdef __i386__ + test_guard_page(); + /* The following tests should be executed as a last step, and in exactly this + * order, since ATL thunk emulation cannot be enabled anymore on Windows. */ + test_atl_thunk_emulation( MEM_EXECUTE_OPTION_ENABLE ); + test_atl_thunk_emulation( MEM_EXECUTE_OPTION_DISABLE ); + test_atl_thunk_emulation( MEM_EXECUTE_OPTION_DISABLE | MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION ); +#endif } diff -Nru wine1.7-1.7.28/dlls/krnl386.exe16/instr.c wine1.7-1.7.31/dlls/krnl386.exe16/instr.c --- wine1.7-1.7.28/dlls/krnl386.exe16/instr.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/krnl386.exe16/instr.c 2014-11-14 13:28:17.000000000 +0000 @@ -194,7 +194,7 @@ GET_VAL( &sib, BYTE ); rm = sib & 7; ss = sib >> 6; - switch(sib >> 3) + switch((sib >> 3) & 7) { case 0: index = context->Eax; break; case 1: index = context->Ecx; break; diff -Nru wine1.7-1.7.28/dlls/ksuser/ksuser.spec wine1.7-1.7.31/dlls/ksuser/ksuser.spec --- wine1.7-1.7.28/dlls/ksuser/ksuser.spec 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/ksuser/ksuser.spec 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,4 @@ +@ stub KsCreateAllocator +@ stub KsCreateClock +@ stub KsCreatePin +@ stub KsCreateTopologyNode diff -Nru wine1.7-1.7.28/dlls/ksuser/main.c wine1.7-1.7.31/dlls/ksuser/main.c --- wine1.7-1.7.28/dlls/ksuser/main.c 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/ksuser/main.c 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,38 @@ +/* + * Copyright 2014 Stefan Leichter + * + * 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 +#include "windef.h" +#include "winbase.h" + +static HINSTANCE instance; + +BOOL WINAPI DllMain( HINSTANCE hinst, DWORD reason, LPVOID reserved ) +{ + switch (reason) + { + case DLL_WINE_PREATTACH: + return FALSE; /* prefer native version */ + case DLL_PROCESS_ATTACH: + instance = hinst; + DisableThreadLibraryCalls( hinst ); + break; + } + return TRUE; +} diff -Nru wine1.7-1.7.28/dlls/ksuser/Makefile.in wine1.7-1.7.31/dlls/ksuser/Makefile.in --- wine1.7-1.7.28/dlls/ksuser/Makefile.in 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/ksuser/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,4 @@ +MODULE = ksuser.dll + +C_SRCS = \ + main.c diff -Nru wine1.7-1.7.28/dlls/mciavi32/info.c wine1.7-1.7.31/dlls/mciavi32/info.c --- wine1.7-1.7.28/dlls/mciavi32/info.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mciavi32/info.c 2014-11-14 13:28:17.000000000 +0000 @@ -74,7 +74,7 @@ DWORD MCIAVI_mciGetDevCaps(UINT wDevID, DWORD dwFlags, LPMCI_GETDEVCAPS_PARMS lpParms) { WINE_MCIAVI* wma = MCIAVI_mciGetOpenDev(wDevID); - DWORD ret; + DWORD ret = MCIERR_UNSUPPORTED_FUNCTION; TRACE("(%04x, %08X, %p)\n", wDevID, dwFlags, lpParms); @@ -175,7 +175,6 @@ /* w2k does not know MAX_WINDOWS or MAX/MINIMUM_RATE */ default: FIXME("Unknown capability (%08x) !\n", lpParms->dwItem); - ret = MCIERR_UNSUPPORTED_FUNCTION; break; } } diff -Nru wine1.7-1.7.28/dlls/mciwave/mciwave.c wine1.7-1.7.31/dlls/mciwave/mciwave.c --- wine1.7-1.7.28/dlls/mciwave/mciwave.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mciwave/mciwave.c 2014-11-14 13:28:17.000000000 +0000 @@ -444,7 +444,7 @@ TRACE("%s!\n", debugstr_w(*pszTmpFileName)); - if (*pszTmpFileName && (strlenW(*pszTmpFileName) > 0)) { + if (*pszTmpFileName && (*pszTmpFileName)[0]) { *hFile = mmioOpenW(*pszTmpFileName, NULL, MMIO_ALLOCBUF | MMIO_READWRITE | MMIO_CREATE); @@ -470,7 +470,7 @@ HeapFree(GetProcessHeap(), 0, wmw->lpFileName); wmw->lpFileName = fn; - if (strlenW(filename) > 0) { + if (filename[0]) { /* FIXME : what should be done if wmw->hFile is already != 0, or the driver is playin' */ TRACE("MCI_OPEN_ELEMENT %s!\n", debugstr_w(filename)); diff -Nru wine1.7-1.7.28/dlls/mlang/mlang.c wine1.7-1.7.31/dlls/mlang/mlang.c --- wine1.7-1.7.28/dlls/mlang/mlang.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mlang/mlang.c 2014-11-14 13:28:17.000000000 +0000 @@ -65,6 +65,7 @@ const char *web_charset; const char *header_charset; const char *body_charset; + const WCHAR *alias; } MIME_CP_INFO; /* These data are based on the codepage info in libs/unicode/cpmap.pl */ @@ -122,7 +123,13 @@ MIMECONTF_IMPORT | MIMECONTF_SAVABLE_MAILNEWS | MIMECONTF_SAVABLE_BROWSER | MIMECONTF_EXPORT | MIMECONTF_VALID_NLS | MIMECONTF_MIME_IE4 | MIMECONTF_MIME_LATEST, - "gb2312", "gb2312", "gb2312" } + "gb2312", "gb2312", "gb2312" }, + { "Chinese Simplified (GBK)", + 936, MIMECONTF_MAILNEWS | MIMECONTF_BROWSER | MIMECONTF_MINIMAL | + MIMECONTF_IMPORT | MIMECONTF_SAVABLE_MAILNEWS | + MIMECONTF_SAVABLE_BROWSER | MIMECONTF_EXPORT | MIMECONTF_VALID_NLS | + MIMECONTF_MIME_IE4 | MIMECONTF_MIME_LATEST, + "gbk", "gbk", "gbk" } }; static const MIME_CP_INFO chinese_traditional_cp[] = { @@ -357,6 +364,9 @@ MIMECONTF_MIME_LATEST, "windows-1258", "windows-1258", "windows-1258" } }; + +static const WCHAR asciiW[] = {'a','s','c','i','i',0}; + static const MIME_CP_INFO western_cp[] = { { "IBM EBCDIC (US-Canada)", @@ -409,7 +419,7 @@ 20127, MIMECONTF_MAILNEWS | MIMECONTF_IMPORT | MIMECONTF_EXPORT | MIMECONTF_SAVABLE_MAILNEWS | MIMECONTF_VALID | MIMECONTF_VALID_NLS | MIMECONTF_MIME_LATEST, - "us-ascii", "us-ascii", "us-ascii" }, + "us-ascii", "us-ascii", "us-ascii", asciiW }, { "Western European (ISO)", 28591, MIMECONTF_MAILNEWS | MIMECONTF_BROWSER | MIMECONTF_IMPORT | MIMECONTF_SAVABLE_MAILNEWS | MIMECONTF_SAVABLE_BROWSER | @@ -953,7 +963,7 @@ *pcDstSize = MultiByteToWideChar(dwEncoding, 0, pSrcStr, *pcSrcSize, NULL, 0); break; } - + if (!*pcDstSize) return E_FAIL; @@ -1344,7 +1354,7 @@ IClassFactoryImpl *This = impl_from_IClassFactory(iface); HRESULT hres; LPUNKNOWN punk; - + TRACE("(%p)->(%p,%s,%p)\n",This,pOuter,debugstr_guid(riid),ppobj); *ppobj = NULL; @@ -2263,7 +2273,7 @@ info->wszLocaleName[0] = 0; GetLocaleInfoW(info->lcid, LOCALE_SLANGUAGE, info->wszLocaleName, MAX_LOCALE_NAME); TRACE("ISO639: %s SLANGUAGE: %s\n", wine_dbgstr_w(info->wszRfc1766), wine_dbgstr_w(info->wszLocaleName)); - + data->total++; return TRUE; @@ -2594,6 +2604,13 @@ strcpyW(pCharsetInfo->wszCharset, csetW); return S_OK; } + if (mlang_data[i].mime_cp_info[n].alias && !lstrcmpiW(Charset, mlang_data[i].mime_cp_info[n].alias)) + { + pCharsetInfo->uiCodePage = mlang_data[i].family_codepage; + pCharsetInfo->uiInternetEncoding = mlang_data[i].mime_cp_info[n].cp; + strcpyW(pCharsetInfo->wszCharset, mlang_data[i].mime_cp_info[n].alias); + return S_OK; + } } } @@ -2869,7 +2886,7 @@ * * PARAMS * see ConvertStringToUnicode - * dwFlag + * dwFlag * lpFallBack if dwFlag contains MLCONVCHARF_USEDEFCHAR, lpFallBack string used * instead unconvertible characters. * diff -Nru wine1.7-1.7.28/dlls/mlang/tests/mlang.c wine1.7-1.7.31/dlls/mlang/tests/mlang.c --- wine1.7-1.7.28/dlls/mlang/tests/mlang.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mlang/tests/mlang.c 2014-11-14 13:28:17.000000000 +0000 @@ -696,6 +696,17 @@ IEnumCodePage_Release(iEnumCP); } +static void test_GetCharsetInfo_alias(IMultiLanguage *ml) +{ + WCHAR asciiW[] = {'a','s','c','i','i',0}; + MIMECSETINFO info; + HRESULT hr; + + hr = IMultiLanguage_GetCharsetInfo(ml, asciiW, &info); + ok(hr == S_OK, "got %08x\n", hr); + ok(!lstrcmpW(info.wszCharset, asciiW), "got %s\n", wine_dbgstr_w(info.wszCharset)); +} + static void scriptinfo_cmp(SCRIPTINFO *sinfo1, SCRIPTINFO *sinfo2) { ok(sinfo1->ScriptId == sinfo2->ScriptId, "ScriptId mismatch: %d != %d\n", sinfo1->ScriptId, sinfo2->ScriptId); @@ -2000,6 +2011,7 @@ test_GetNumberOfCodePageInfo((IMultiLanguage2 *)iML); test_IMLangConvertCharset(iML); + test_GetCharsetInfo_alias(iML); IMultiLanguage_Release(iML); diff -Nru wine1.7-1.7.28/dlls/mscoree/corruntimehost.c wine1.7-1.7.31/dlls/mscoree/corruntimehost.c --- wine1.7-1.7.28/dlls/mscoree/corruntimehost.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mscoree/corruntimehost.c 2014-11-14 13:28:17.000000000 +0000 @@ -1124,7 +1124,7 @@ if (domain) { mono_thread_manage(); - mono_jit_cleanup(domain); + mono_runtime_quit(); } return exit_code; diff -Nru wine1.7-1.7.28/dlls/mscoree/metahost.c wine1.7-1.7.31/dlls/mscoree/metahost.c --- wine1.7-1.7.28/dlls/mscoree/metahost.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mscoree/metahost.c 2014-11-14 13:28:17.000000000 +0000 @@ -88,7 +88,6 @@ static MonoImage* (CDECL *mono_image_open)(const char *fname, MonoImageOpenStatus *status); MonoImage* (CDECL *mono_image_open_from_module_handle)(HMODULE module_handle, char* fname, UINT has_entry_point, MonoImageOpenStatus* status); static void (CDECL *mono_install_assembly_preload_hook)(MonoAssemblyPreLoadFunc func, void *user_data); -void (CDECL *mono_jit_cleanup)(MonoDomain *domain); int (CDECL *mono_jit_exec)(MonoDomain *domain, MonoAssembly *assembly, int argc, char *argv[]); MonoDomain* (CDECL *mono_jit_init)(const char *file); static int (CDECL *mono_jit_set_trace_options)(const char* options); @@ -100,6 +99,7 @@ MonoType* (CDECL *mono_reflection_type_from_name)(char *name, MonoImage *image); MonoObject* (CDECL *mono_runtime_invoke)(MonoMethod *method, void *obj, void **params, MonoObject **exc); void (CDECL *mono_runtime_object_init)(MonoObject *this_obj); +void (CDECL *mono_runtime_quit)(void); static void (CDECL *mono_set_dirs)(const char *assembly_dir, const char *config_dir); static void (CDECL *mono_set_verbose_level)(DWORD level); MonoString* (CDECL *mono_string_new)(MonoDomain *domain, const char *str); @@ -197,7 +197,6 @@ LOAD_MONO_FUNCTION(mono_free); LOAD_MONO_FUNCTION(mono_image_open); LOAD_MONO_FUNCTION(mono_install_assembly_preload_hook); - LOAD_MONO_FUNCTION(mono_jit_cleanup); LOAD_MONO_FUNCTION(mono_jit_exec); LOAD_MONO_FUNCTION(mono_jit_init); LOAD_MONO_FUNCTION(mono_jit_set_trace_options); @@ -209,6 +208,7 @@ LOAD_MONO_FUNCTION(mono_reflection_type_from_name); LOAD_MONO_FUNCTION(mono_runtime_invoke); LOAD_MONO_FUNCTION(mono_runtime_object_init); + LOAD_MONO_FUNCTION(mono_runtime_quit); LOAD_MONO_FUNCTION(mono_set_dirs); LOAD_MONO_FUNCTION(mono_set_verbose_level); LOAD_MONO_FUNCTION(mono_stringify_assembly_name); @@ -360,7 +360,7 @@ if (buffer_size >= *pcchBuffer) MultiByteToWideChar(CP_UTF8, 0, version, -1, pwzBuffer, buffer_size); else - hr = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + hr = E_NOT_SUFFICIENT_BUFFER; } return hr; @@ -421,7 +421,7 @@ if (buffer_size >= size) strcpyW(pwzBuffer, system_dir); else - hr = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + hr = E_NOT_SUFFICIENT_BUFFER; } return hr; @@ -1051,7 +1051,7 @@ if (buffer_size >= *pcchBuffer) MultiByteToWideChar(CP_UTF8, 0, version, -1, pwzBuffer, buffer_size); else - hr = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + hr = E_NOT_SUFFICIENT_BUFFER; } } diff -Nru wine1.7-1.7.28/dlls/mscoree/mscoree_private.h wine1.7-1.7.31/dlls/mscoree/mscoree_private.h --- wine1.7-1.7.28/dlls/mscoree/mscoree_private.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mscoree/mscoree_private.h 2014-11-14 13:28:17.000000000 +0000 @@ -145,7 +145,6 @@ extern MonoClass* (CDECL *mono_class_from_name)(MonoImage *image, const char* name_space, const char *name); extern MonoMethod* (CDECL *mono_class_get_method_from_name)(MonoClass *klass, const char *name, int param_count); extern MonoAssembly* (CDECL *mono_domain_assembly_open)(MonoDomain *domain, const char *name); -extern void (CDECL *mono_jit_cleanup)(MonoDomain *domain); extern int (CDECL *mono_jit_exec)(MonoDomain *domain, MonoAssembly *assembly, int argc, char *argv[]); extern MonoDomain* (CDECL *mono_jit_init)(const char *file); extern MonoImage* (CDECL *mono_image_open_from_module_handle)(HMODULE module_handle, char* fname, UINT has_entry_point, MonoImageOpenStatus* status); @@ -156,6 +155,7 @@ extern MonoType* (CDECL *mono_reflection_type_from_name)(char *name, MonoImage *image); extern MonoObject* (CDECL *mono_runtime_invoke)(MonoMethod *method, void *obj, void **params, MonoObject **exc); extern void (CDECL *mono_runtime_object_init)(MonoObject *this_obj); +extern void (CDECL *mono_runtime_quit)(void); extern MonoString* (CDECL *mono_string_new)(MonoDomain *domain, const char *str); extern MonoThread* (CDECL *mono_thread_attach)(MonoDomain *domain); extern void (CDECL *mono_thread_manage)(void); diff -Nru wine1.7-1.7.28/dlls/mscoree/tests/metahost.c wine1.7-1.7.31/dlls/mscoree/tests/metahost.c --- wine1.7-1.7.28/dlls/mscoree/tests/metahost.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mscoree/tests/metahost.c 2014-11-14 13:28:17.000000000 +0000 @@ -122,7 +122,7 @@ count = 1; hr = ICLRRuntimeInfo_GetVersionString(runtime_info, buf, &count); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), "GetVersionString returned %x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "GetVersionString returned %x\n", hr); ok(count > 1, "GetVersionString returned count %u\n", count); count = 0xdeadbeef; diff -Nru wine1.7-1.7.28/dlls/mscoree/tests/mscoree.c wine1.7-1.7.31/dlls/mscoree/tests/mscoree.c --- wine1.7-1.7.28/dlls/mscoree/tests/mscoree.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mscoree/tests/mscoree.c 2014-11-14 13:28:17.000000000 +0000 @@ -92,7 +92,7 @@ return; } - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER),"GetCORVersion returned %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "GetCORVersion returned %08x\n", hr); hr = pGetCORVersion(version, MAX_PATH, &size); ok(hr == S_OK,"GetCORVersion returned %08x\n", hr); @@ -107,12 +107,12 @@ path_len = size; hr = pGetCORSystemDirectory(path, path_len-1 , &size); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), "GetCORSystemDirectory returned %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "GetCORSystemDirectory returned %08x\n", hr); if (0) /* crashes on <= w2k3 */ { hr = pGetCORSystemDirectory(NULL, MAX_PATH , &size); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), "GetCORSystemDirectory returned %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "GetCORSystemDirectory returned %08x\n", hr); } hr = pGetCORSystemDirectory(path, MAX_PATH , NULL); @@ -140,7 +140,7 @@ ok(hr == S_OK, "GetRequestedRuntimeInfo returned %08x\n", hr); hr = pGetRequestedRuntimeInfo( NULL, v2_0, NULL, 0, 0, path, 1, &path_len, version, MAX_PATH, &size); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), "GetRequestedRuntimeInfo returned %08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "GetRequestedRuntimeInfo returned %08x\n", hr); /* if one of the buffers is NULL, the other one is still happily filled */ memset(version, 0, sizeof(version)); diff -Nru wine1.7-1.7.28/dlls/msdmo/dmoreg.c wine1.7-1.7.31/dlls/msdmo/dmoreg.c --- wine1.7-1.7.28/dlls/msdmo/dmoreg.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msdmo/dmoreg.c 2014-11-14 13:28:17.000000000 +0000 @@ -352,119 +352,122 @@ /************************************************************************** * IEnumDMO_Constructor */ -static IEnumDMO * IEnumDMO_Constructor( +static HRESULT IEnumDMO_Constructor( REFGUID guidCategory, DWORD dwFlags, DWORD cInTypes, const DMO_PARTIAL_MEDIATYPE *pInTypes, DWORD cOutTypes, - const DMO_PARTIAL_MEDIATYPE *pOutTypes) + const DMO_PARTIAL_MEDIATYPE *pOutTypes, + IEnumDMO **obj) { - UINT size; IEnumDMOImpl* lpedmo; - BOOL ret = FALSE; + HRESULT hr = S_OK; + UINT size; + + *obj = NULL; lpedmo = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IEnumDMOImpl)); + if (!lpedmo) + return E_OUTOFMEMORY; - if (lpedmo) - { - lpedmo->ref = 1; - lpedmo->IEnumDMO_iface.lpVtbl = &edmovt; - lpedmo->index = -1; - lpedmo->guidCategory = guidCategory; - lpedmo->dwFlags = dwFlags; + lpedmo->IEnumDMO_iface.lpVtbl = &edmovt; + lpedmo->ref = 1; + lpedmo->index = -1; + lpedmo->guidCategory = guidCategory; + lpedmo->dwFlags = dwFlags; - if (cInTypes > 0) + if (cInTypes > 0) + { + size = cInTypes * sizeof(DMO_PARTIAL_MEDIATYPE); + lpedmo->pInTypes = HeapAlloc(GetProcessHeap(), 0, size); + if (!lpedmo->pInTypes) { - size = cInTypes * sizeof(DMO_PARTIAL_MEDIATYPE); - lpedmo->pInTypes = HeapAlloc(GetProcessHeap(), 0, size); - if (!lpedmo->pInTypes) - goto lerr; - memcpy(lpedmo->pInTypes, pInTypes, size); - lpedmo->cInTypes = cInTypes; + hr = E_OUTOFMEMORY; + goto lerr; } + memcpy(lpedmo->pInTypes, pInTypes, size); + lpedmo->cInTypes = cInTypes; + } - if (cOutTypes > 0) + if (cOutTypes > 0) + { + size = cOutTypes * sizeof(DMO_PARTIAL_MEDIATYPE); + lpedmo->pOutTypes = HeapAlloc(GetProcessHeap(), 0, size); + if (!lpedmo->pOutTypes) { - size = cOutTypes * sizeof(DMO_PARTIAL_MEDIATYPE); - lpedmo->pOutTypes = HeapAlloc(GetProcessHeap(), 0, size); - if (!lpedmo->pOutTypes) - goto lerr; - memcpy(lpedmo->pOutTypes, pOutTypes, size); - lpedmo->cOutTypes = cOutTypes; + hr = E_OUTOFMEMORY; + goto lerr; } + memcpy(lpedmo->pOutTypes, pOutTypes, size); + lpedmo->cOutTypes = cOutTypes; + } - /* If not filtering by category enum from media objects root */ - if (IsEqualGUID(guidCategory, &GUID_NULL)) - { - if (ERROR_SUCCESS == RegOpenKeyExW(HKEY_CLASSES_ROOT, szDMORootKey, - 0, KEY_READ, &lpedmo->hkey)) - ret = TRUE; - } - else - { - WCHAR szguid[64]; - WCHAR szKey[MAX_PATH]; + /* If not filtering by category enum from media objects root */ + if (IsEqualGUID(guidCategory, &GUID_NULL)) + { + if (!RegOpenKeyExW(HKEY_CLASSES_ROOT, szDMORootKey, 0, KEY_READ, &lpedmo->hkey)) + hr = E_FAIL; + } + else + { + WCHAR szguid[64]; + WCHAR szKey[MAX_PATH]; - wsprintfW(szKey, szCat3Fmt, szDMORootKey, szDMOCategories, - GUIDToString(szguid, guidCategory)); - if (ERROR_SUCCESS == RegOpenKeyExW(HKEY_CLASSES_ROOT, szKey, - 0, KEY_READ, &lpedmo->hkey)) - ret = TRUE; - } + wsprintfW(szKey, szCat3Fmt, szDMORootKey, szDMOCategories, + GUIDToString(szguid, guidCategory)); + if (!RegOpenKeyExW(HKEY_CLASSES_ROOT, szKey, 0, KEY_READ, &lpedmo->hkey)) + hr = E_FAIL; + } lerr: - if(!ret) - { - IEnumDMOImpl_Destructor(lpedmo); - HeapFree(GetProcessHeap(),0,lpedmo); - lpedmo = NULL; - } - } - TRACE("returning %p\n", lpedmo); + if (FAILED(hr)) + { + IEnumDMOImpl_Destructor(lpedmo); + HeapFree(GetProcessHeap(), 0, lpedmo); + } + else + { + TRACE("returning %p\n", lpedmo); + *obj = &lpedmo->IEnumDMO_iface; + } - return (IEnumDMO*)lpedmo; + return hr; } - /****************************************************************************** * IEnumDMO_fnAddRef */ static ULONG WINAPI IEnumDMO_fnAddRef(IEnumDMO * iface) { IEnumDMOImpl *This = impl_from_IEnumDMO(iface); - return InterlockedIncrement(&This->ref); + ULONG refCount = InterlockedIncrement(&This->ref); + TRACE("(%p)->(%d)\n", This, refCount); + return refCount; } - /************************************************************************** * EnumDMO_QueryInterface */ -static HRESULT WINAPI IEnumDMO_fnQueryInterface( - IEnumDMO* iface, - REFIID riid, - LPVOID *ppvObj) +static HRESULT WINAPI IEnumDMO_fnQueryInterface(IEnumDMO* iface, REFIID riid, void **ppvObj) { IEnumDMOImpl *This = impl_from_IEnumDMO(iface); - *ppvObj = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppvObj); - if(IsEqualIID(riid, &IID_IUnknown)) - *ppvObj = This; - else if(IsEqualIID(riid, &IID_IEnumDMO)) - *ppvObj = This; + *ppvObj = NULL; - if(*ppvObj) + if (IsEqualIID(riid, &IID_IEnumDMO) || + IsEqualIID(riid, &IID_IUnknown)) { - IEnumDMO_fnAddRef(*ppvObj); - return S_OK; + *ppvObj = iface; + IEnumDMO_fnAddRef(iface); } - return E_NOINTERFACE; + return *ppvObj ? S_OK : E_NOINTERFACE; } - /****************************************************************************** * IEnumDMO_fnRelease */ @@ -473,6 +476,8 @@ IEnumDMOImpl *This = impl_from_IEnumDMO(iface); ULONG refCount = InterlockedDecrement(&This->ref); + TRACE("(%p)->(%d)\n", This, refCount); + if (!refCount) { IEnumDMOImpl_Destructor(This); @@ -504,7 +509,7 @@ IEnumDMOImpl *This = impl_from_IEnumDMO(iface); - TRACE("--> (%p) %d %p %p %p\n", iface, cItemsToFetch, pCLSID, Names, pcItemsFetched); + TRACE("(%p)->(%d %p %p %p)\n", This, cItemsToFetch, pCLSID, Names, pcItemsFetched); if (!pCLSID || !Names || !pcItemsFetched) return E_POINTER; @@ -643,6 +648,7 @@ { IEnumDMOImpl *This = impl_from_IEnumDMO(iface); + TRACE("(%p)->(%d)\n", This, cItemsToSkip); This->index += cItemsToSkip; return S_OK; @@ -656,6 +662,7 @@ { IEnumDMOImpl *This = impl_from_IEnumDMO(iface); + TRACE("(%p)\n", This); This->index = -1; return S_OK; @@ -665,13 +672,12 @@ /****************************************************************************** * IEnumDMO_fnClone */ -static HRESULT WINAPI IEnumDMO_fnClone(IEnumDMO * iface, IEnumDMO **ppEnum) +static HRESULT WINAPI IEnumDMO_fnClone(IEnumDMO *iface, IEnumDMO **ppEnum) { IEnumDMOImpl *This = impl_from_IEnumDMO(iface); - - FIXME("(%p)->() to (%p)->() E_NOTIMPL\n", This, ppEnum); - - return E_NOTIMPL; + TRACE("(%p)->(%p)\n", This, ppEnum); + return IEnumDMO_Constructor(This->guidCategory, This->dwFlags, This->cInTypes, This->pInTypes, + This->cOutTypes, This->pOutTypes, ppEnum); } @@ -689,17 +695,11 @@ const DMO_PARTIAL_MEDIATYPE *pOutTypes, IEnumDMO **ppEnum) { - HRESULT hres = E_FAIL; - TRACE("guidCategory=%p dwFlags=0x%08x cInTypes=%d cOutTypes=%d\n", guidCategory, dwFlags, cInTypes, cOutTypes); - *ppEnum = IEnumDMO_Constructor(guidCategory, dwFlags, cInTypes, - pInTypes, cOutTypes, pOutTypes); - if (*ppEnum) - hres = S_OK; - - return hres; + return IEnumDMO_Constructor(guidCategory, dwFlags, cInTypes, + pInTypes, cOutTypes, pOutTypes, ppEnum); } diff -Nru wine1.7-1.7.28/dlls/mshtml/binding.h wine1.7-1.7.31/dlls/mshtml/binding.h --- wine1.7-1.7.28/dlls/mshtml/binding.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/binding.h 2014-11-14 13:28:17.000000000 +0000 @@ -25,6 +25,12 @@ METHOD_POST } REQUEST_METHOD; +typedef enum { + BOM_NONE, + BOM_UTF8, + BOM_UTF16 +} binding_bom_t; + typedef struct { nsIHttpChannel nsIHttpChannel_iface; nsIUploadChannel nsIUploadChannel_iface; @@ -38,6 +44,7 @@ nsILoadGroup *load_group; nsIInterfaceRequestor *notif_callback; nsISupports *owner; + nsILoadInfo *load_info; nsLoadFlags load_flags; nsIURI *original_uri; nsIURI *referrer; @@ -71,7 +78,7 @@ ULONG readed; DWORD bindf; BOOL bindinfo_ready; - int bom; + binding_bom_t bom; IMoniker *mon; IBinding *binding; @@ -96,6 +103,17 @@ nsProtocolStream *nsstream; }; +struct BSCallbackVtbl { + void (*destroy)(BSCallback*); + HRESULT (*init_bindinfo)(BSCallback*); + HRESULT (*start_binding)(BSCallback*); + HRESULT (*stop_binding)(BSCallback*,HRESULT); + HRESULT (*read_data)(BSCallback*,IStream*); + HRESULT (*on_progress)(BSCallback*,ULONG,LPCWSTR); + HRESULT (*on_response)(BSCallback*,DWORD,LPCWSTR); + HRESULT (*beginning_transaction)(BSCallback*,WCHAR**); +}; + typedef struct { struct list entry; WCHAR *header; @@ -124,16 +142,17 @@ HRESULT navigate_url(HTMLOuterWindow*,const WCHAR*,IUri*,DWORD) DECLSPEC_HIDDEN; HRESULT submit_form(HTMLOuterWindow*,IUri*,nsIInputStream*) DECLSPEC_HIDDEN; +void init_bscallback(BSCallback*,const BSCallbackVtbl*,IMoniker*,DWORD) DECLSPEC_HIDDEN; HRESULT create_channelbsc(IMoniker*,const WCHAR*,BYTE*,DWORD,BOOL,nsChannelBSC**) DECLSPEC_HIDDEN; HRESULT channelbsc_load_stream(HTMLInnerWindow*,IMoniker*,IStream*) DECLSPEC_HIDDEN; void channelbsc_set_channel(nsChannelBSC*,nsChannel*,nsIStreamListener*,nsISupports*) DECLSPEC_HIDDEN; IUri *nsuri_get_uri(nsWineURI*) DECLSPEC_HIDDEN; +HRESULT read_stream(BSCallback*,IStream*,void*,DWORD,DWORD*) DECLSPEC_HIDDEN; + HRESULT create_relative_uri(HTMLOuterWindow*,const WCHAR*,IUri**) DECLSPEC_HIDDEN; HRESULT create_uri(const WCHAR*,DWORD,IUri**) DECLSPEC_HIDDEN; IUri *get_uri_nofrag(IUri*) DECLSPEC_HIDDEN; void set_current_mon(HTMLOuterWindow*,IMoniker*,DWORD) DECLSPEC_HIDDEN; void set_current_uri(HTMLOuterWindow*,IUri*) DECLSPEC_HIDDEN; - -HRESULT bind_mon_to_wstr(HTMLInnerWindow*,IMoniker*,WCHAR**) DECLSPEC_HIDDEN; diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlanchor.c wine1.7-1.7.31/dlls/mshtml/htmlanchor.c --- wine1.7-1.7.28/dlls/mshtml/htmlanchor.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlanchor.c 2014-11-14 13:28:17.000000000 +0000 @@ -724,7 +724,7 @@ if(eid == EVENTID_CLICK) { nsIDOMMouseEvent *mouse_event; - UINT16 button; + INT16 button; nsresult nsres; TRACE("CLICK\n"); diff -Nru wine1.7-1.7.28/dlls/mshtml/htmldoc.c wine1.7-1.7.31/dlls/mshtml/htmldoc.c --- wine1.7-1.7.28/dlls/mshtml/htmldoc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmldoc.c 2014-11-14 13:28:17.000000000 +0000 @@ -592,27 +592,13 @@ { HTMLDocument *This = impl_from_IHTMLDocument2(iface); - static const WCHAR wszUninitialized[] = {'u','n','i','n','i','t','i','a','l','i','z','e','d',0}; - static const WCHAR wszLoading[] = {'l','o','a','d','i','n','g',0}; - static const WCHAR wszLoaded[] = {'l','o','a','d','e','d',0}; - static const WCHAR wszInteractive[] = {'i','n','t','e','r','a','c','t','i','v','e',0}; - static const WCHAR wszComplete[] = {'c','o','m','p','l','e','t','e',0}; - - static const LPCWSTR readystate_str[] = { - wszUninitialized, - wszLoading, - wszLoaded, - wszInteractive, - wszComplete - }; TRACE("(%p)->(%p)\n", iface, p); if(!p) return E_POINTER; - *p = SysAllocString(readystate_str[This->window->readystate]); - return S_OK; + return get_readystate_string(This->window->readystate, p); } static HRESULT WINAPI HTMLDocument_get_frames(IHTMLDocument2 *iface, IHTMLFramesCollection2 **p) @@ -1834,8 +1820,11 @@ static HRESULT WINAPI HTMLDocument3_recalc(IHTMLDocument3 *iface, VARIANT_BOOL fForce) { HTMLDocument *This = impl_from_IHTMLDocument3(iface); - FIXME("(%p)->(%x)\n", This, fForce); - return E_NOTIMPL; + + WARN("(%p)->(%x)\n", This, fForce); + + /* Doing nothing here should be fine for us. */ + return S_OK; } static HRESULT WINAPI HTMLDocument3_createTextNode(IHTMLDocument3 *iface, BSTR text, @@ -2222,7 +2211,7 @@ * types and search should be case insensitive. Those are currently not supported properly. */ nsAString_InitDepend(&selector_str, selector); - nsres = nsIDOMNodeSelector_QuerySelectorAll(This->doc_node->nsnode_selector, &selector_str, &node_list); + nsres = nsIDOMHTMLDocument_QuerySelectorAll(This->doc_node->nsdoc, &selector_str, &node_list); nsAString_Finish(&selector_str); heap_free(selector); if(NS_FAILED(nsres)) { @@ -4351,11 +4340,6 @@ while(!list_empty(&This->plugin_hosts)) detach_plugin_host(LIST_ENTRY(list_head(&This->plugin_hosts), PluginHost, entry)); - if(This->nsnode_selector) { - nsIDOMNodeSelector_Release(This->nsnode_selector); - This->nsnode_selector = NULL; - } - if(!This->nsdoc && This->window) { /* document fragments own reference to inner window */ IHTMLWindow2_Release(&This->window->base.IHTMLWindow2_iface); @@ -4377,8 +4361,6 @@ { HTMLDocumentNode *This = impl_from_HTMLDOMNode(iface); - if(This->nsnode_selector) - note_cc_edge((nsISupports*)This->nsnode_selector, "This->nsnode_selector", cb); if(This->nsdoc) note_cc_edge((nsISupports*)This->nsdoc, "This->nsdoc", cb); } @@ -4387,11 +4369,6 @@ { HTMLDocumentNode *This = impl_from_HTMLDOMNode(iface); - if(This->nsnode_selector) { - nsIDOMNodeSelector_Release(This->nsnode_selector); - This->nsnode_selector = NULL; - } - if(This->nsdoc) { nsIDOMHTMLDocument *nsdoc = This->nsdoc; @@ -4545,7 +4522,6 @@ HRESULT create_doc_from_nsdoc(nsIDOMHTMLDocument *nsdoc, HTMLDocumentObj *doc_obj, HTMLInnerWindow *window, HTMLDocumentNode **ret) { HTMLDocumentNode *doc; - nsresult nsres; doc = alloc_doc_node(doc_obj, window); if(!doc) @@ -4559,9 +4535,6 @@ nsIDOMHTMLDocument_AddRef(nsdoc); doc->nsdoc = nsdoc; - nsres = nsIDOMHTMLDocument_QueryInterface(nsdoc, &IID_nsIDOMNodeSelector, (void**)&doc->nsnode_selector); - assert(nsres == NS_OK); - init_document_mutation(doc); doc_init_events(doc); diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlelem2.c wine1.7-1.7.31/dlls/mshtml/htmlelem2.c --- wine1.7-1.7.28/dlls/mshtml/htmlelem2.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlelem2.c 1970-01-01 00:00:00.000000000 +0000 @@ -1,1387 +0,0 @@ -/* - * Copyright 2006-2010 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 -#include -#include - -#define COBJMACROS - -#include "windef.h" -#include "winbase.h" -#include "winuser.h" -#include "ole2.h" - -#include "wine/debug.h" - -#include "mshtml_private.h" -#include "htmlevent.h" -#include "htmlstyle.h" - -WINE_DEFAULT_DEBUG_CHANNEL(mshtml); - -typedef struct { - DispatchEx dispex; - IHTMLRect IHTMLRect_iface; - - LONG ref; - - nsIDOMClientRect *nsrect; -} HTMLRect; - -static inline HTMLRect *impl_from_IHTMLRect(IHTMLRect *iface) -{ - return CONTAINING_RECORD(iface, HTMLRect, IHTMLRect_iface); -} - -static HRESULT WINAPI HTMLRect_QueryInterface(IHTMLRect *iface, REFIID riid, void **ppv) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - - TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); - - if(IsEqualGUID(&IID_IUnknown, riid)) { - *ppv = &This->IHTMLRect_iface; - }else if(IsEqualGUID(&IID_IHTMLRect, riid)) { - *ppv = &This->IHTMLRect_iface; - }else if(dispex_query_interface(&This->dispex, riid, ppv)) { - return *ppv ? S_OK : E_NOINTERFACE; - }else { - FIXME("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); - *ppv = NULL; - return E_NOINTERFACE; - } - - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; -} - -static ULONG WINAPI HTMLRect_AddRef(IHTMLRect *iface) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - LONG ref = InterlockedIncrement(&This->ref); - - TRACE("(%p) ref=%d\n", This, ref); - - return ref; -} - -static ULONG WINAPI HTMLRect_Release(IHTMLRect *iface) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - LONG ref = InterlockedDecrement(&This->ref); - - TRACE("(%p) ref=%d\n", This, ref); - - if(!ref) { - if(This->nsrect) - nsIDOMClientRect_Release(This->nsrect); - heap_free(This); - } - - return ref; -} - -static HRESULT WINAPI HTMLRect_GetTypeInfoCount(IHTMLRect *iface, UINT *pctinfo) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - FIXME("(%p)->(%p)\n", This, pctinfo); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLRect_GetTypeInfo(IHTMLRect *iface, UINT iTInfo, - LCID lcid, ITypeInfo **ppTInfo) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - - return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); -} - -static HRESULT WINAPI HTMLRect_GetIDsOfNames(IHTMLRect *iface, REFIID riid, - LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - - return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, cNames, - lcid, rgDispId); -} - -static HRESULT WINAPI HTMLRect_Invoke(IHTMLRect *iface, DISPID dispIdMember, - REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, - VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - - return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, lcid, wFlags, - pDispParams, pVarResult, pExcepInfo, puArgErr); -} - -static HRESULT WINAPI HTMLRect_put_left(IHTMLRect *iface, LONG v) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - FIXME("(%p)->(%d)\n", This, v); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLRect_get_left(IHTMLRect *iface, LONG *p) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - float left; - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMClientRect_GetLeft(This->nsrect, &left); - if(NS_FAILED(nsres)) { - ERR("GetLeft failed: %08x\n", nsres); - return E_FAIL; - } - - *p = floor(left+0.5); - return S_OK; -} - -static HRESULT WINAPI HTMLRect_put_top(IHTMLRect *iface, LONG v) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - FIXME("(%p)->(%d)\n", This, v); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLRect_get_top(IHTMLRect *iface, LONG *p) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - float top; - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMClientRect_GetTop(This->nsrect, &top); - if(NS_FAILED(nsres)) { - ERR("GetTop failed: %08x\n", nsres); - return E_FAIL; - } - - *p = floor(top+0.5); - return S_OK; -} - -static HRESULT WINAPI HTMLRect_put_right(IHTMLRect *iface, LONG v) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - FIXME("(%p)->(%d)\n", This, v); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLRect_get_right(IHTMLRect *iface, LONG *p) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - float right; - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMClientRect_GetRight(This->nsrect, &right); - if(NS_FAILED(nsres)) { - ERR("GetRight failed: %08x\n", nsres); - return E_FAIL; - } - - *p = floor(right+0.5); - return S_OK; -} - -static HRESULT WINAPI HTMLRect_put_bottom(IHTMLRect *iface, LONG v) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - FIXME("(%p)->(%d)\n", This, v); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLRect_get_bottom(IHTMLRect *iface, LONG *p) -{ - HTMLRect *This = impl_from_IHTMLRect(iface); - float bottom; - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMClientRect_GetBottom(This->nsrect, &bottom); - if(NS_FAILED(nsres)) { - ERR("GetBottom failed: %08x\n", nsres); - return E_FAIL; - } - - *p = floor(bottom+0.5); - return S_OK; -} - -static const IHTMLRectVtbl HTMLRectVtbl = { - HTMLRect_QueryInterface, - HTMLRect_AddRef, - HTMLRect_Release, - HTMLRect_GetTypeInfoCount, - HTMLRect_GetTypeInfo, - HTMLRect_GetIDsOfNames, - HTMLRect_Invoke, - HTMLRect_put_left, - HTMLRect_get_left, - HTMLRect_put_top, - HTMLRect_get_top, - HTMLRect_put_right, - HTMLRect_get_right, - HTMLRect_put_bottom, - HTMLRect_get_bottom -}; - -static const tid_t HTMLRect_iface_tids[] = { - IHTMLRect_tid, - 0 -}; -static dispex_static_data_t HTMLRect_dispex = { - NULL, - IHTMLRect_tid, - NULL, - HTMLRect_iface_tids -}; - -static HRESULT create_html_rect(nsIDOMClientRect *nsrect, IHTMLRect **ret) -{ - HTMLRect *rect; - - rect = heap_alloc_zero(sizeof(HTMLRect)); - if(!rect) - return E_OUTOFMEMORY; - - rect->IHTMLRect_iface.lpVtbl = &HTMLRectVtbl; - rect->ref = 1; - - init_dispex(&rect->dispex, (IUnknown*)&rect->IHTMLRect_iface, &HTMLRect_dispex); - - nsIDOMClientRect_AddRef(nsrect); - rect->nsrect = nsrect; - - *ret = &rect->IHTMLRect_iface; - return S_OK; -} - -static inline HTMLElement *impl_from_IHTMLElement2(IHTMLElement2 *iface) -{ - return CONTAINING_RECORD(iface, HTMLElement, IHTMLElement2_iface); -} - -static HRESULT WINAPI HTMLElement2_QueryInterface(IHTMLElement2 *iface, - REFIID riid, void **ppv) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - return IHTMLElement_QueryInterface(&This->IHTMLElement_iface, riid, ppv); -} - -static ULONG WINAPI HTMLElement2_AddRef(IHTMLElement2 *iface) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - return IHTMLElement_AddRef(&This->IHTMLElement_iface); -} - -static ULONG WINAPI HTMLElement2_Release(IHTMLElement2 *iface) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - return IHTMLElement_Release(&This->IHTMLElement_iface); -} - -static HRESULT WINAPI HTMLElement2_GetTypeInfoCount(IHTMLElement2 *iface, UINT *pctinfo) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - return IDispatchEx_GetTypeInfoCount(&This->node.dispex.IDispatchEx_iface, pctinfo); -} - -static HRESULT WINAPI HTMLElement2_GetTypeInfo(IHTMLElement2 *iface, UINT iTInfo, - LCID lcid, ITypeInfo **ppTInfo) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - return IDispatchEx_GetTypeInfo(&This->node.dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); -} - -static HRESULT WINAPI HTMLElement2_GetIDsOfNames(IHTMLElement2 *iface, REFIID riid, - LPOLESTR *rgszNames, UINT cNames, - LCID lcid, DISPID *rgDispId) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - return IDispatchEx_GetIDsOfNames(&This->node.dispex.IDispatchEx_iface, riid, rgszNames, cNames, - lcid, rgDispId); -} - -static HRESULT WINAPI HTMLElement2_Invoke(IHTMLElement2 *iface, DISPID dispIdMember, - REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, - VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - return IDispatchEx_Invoke(&This->node.dispex.IDispatchEx_iface, dispIdMember, riid, lcid, - wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); -} - -static HRESULT WINAPI HTMLElement2_get_scopeName(IHTMLElement2 *iface, BSTR *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_setCapture(IHTMLElement2 *iface, VARIANT_BOOL containerCapture) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%x)\n", This, containerCapture); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_releaseCapture(IHTMLElement2 *iface) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_onlosecapture(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onlosecapture(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_componentFromPoint(IHTMLElement2 *iface, - LONG x, LONG y, BSTR *component) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%d %d %p)\n", This, x, y, component); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_doScroll(IHTMLElement2 *iface, VARIANT component) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%s)\n", This, debugstr_variant(&component)); - - if(!This->node.doc->content_ready - || !This->node.doc->basedoc.doc_obj->in_place_active) - return E_PENDING; - - WARN("stub\n"); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_put_onscroll(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onscroll(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_ondrag(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); - - return set_node_event(&This->node, EVENTID_DRAG, &v); -} - -static HRESULT WINAPI HTMLElement2_get_ondrag(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%p)\n", This, p); - - return get_node_event(&This->node, EVENTID_DRAG, p); -} - -static HRESULT WINAPI HTMLElement2_put_ondragend(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_ondragend(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_ondragenter(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_ondragenter(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_ondragover(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_ondragover(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_ondragleave(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_ondragleave(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_ondrop(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_ondrop(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_onbeforecut(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onbeforecut(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_oncut(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_oncut(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_onbeforecopy(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onbeforecopy(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_oncopy(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_oncopy(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_onbeforepaste(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onbeforepaste(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_onpaste(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); - - return set_node_event(&This->node, EVENTID_PASTE, &v); -} - -static HRESULT WINAPI HTMLElement2_get_onpaste(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%p)\n", This, p); - - return get_node_event(&This->node, EVENTID_PASTE, p); -} - -static HRESULT WINAPI HTMLElement2_get_currentStyle(IHTMLElement2 *iface, IHTMLCurrentStyle **p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%p)\n", This, p); - - return HTMLCurrentStyle_Create(This, p); -} - -static HRESULT WINAPI HTMLElement2_put_onpropertychange(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onpropertychange(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_getClientRects(IHTMLElement2 *iface, IHTMLRectCollection **pRectCol) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, pRectCol); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_getBoundingClientRect(IHTMLElement2 *iface, IHTMLRect **pRect) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsIDOMClientRect *nsrect; - nsresult nsres; - HRESULT hres; - - TRACE("(%p)->(%p)\n", This, pRect); - - nsres = nsIDOMHTMLElement_GetBoundingClientRect(This->nselem, &nsrect); - if(NS_FAILED(nsres) || !nsrect) { - ERR("GetBoindingClientRect failed: %08x\n", nsres); - return E_FAIL; - } - - hres = create_html_rect(nsrect, pRect); - - nsIDOMClientRect_Release(nsrect); - return hres; -} - -static HRESULT WINAPI HTMLElement2_setExpression(IHTMLElement2 *iface, BSTR propname, - BSTR expression, BSTR language) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%s %s %s)\n", This, debugstr_w(propname), debugstr_w(expression), - debugstr_w(language)); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_getExpression(IHTMLElement2 *iface, BSTR propname, - VARIANT *expression) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%s %p)\n", This, debugstr_w(propname), expression); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_removeExpression(IHTMLElement2 *iface, BSTR propname, - VARIANT_BOOL *pfSuccess) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%s %p)\n", This, debugstr_w(propname), pfSuccess); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_tabIndex(IHTMLElement2 *iface, short v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%d)\n", This, v); - - nsres = nsIDOMHTMLElement_SetTabIndex(This->nselem, v); - if(NS_FAILED(nsres)) - ERR("GetTabIndex failed: %08x\n", nsres); - - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_get_tabIndex(IHTMLElement2 *iface, short *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - LONG index; - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMHTMLElement_GetTabIndex(This->nselem, &index); - if(NS_FAILED(nsres)) { - ERR("GetTabIndex failed: %08x\n", nsres); - return E_FAIL; - } - - *p = index; - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_focus(IHTMLElement2 *iface) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)\n", This); - - nsres = nsIDOMHTMLElement_Focus(This->nselem); - if(NS_FAILED(nsres)) - ERR("Focus failed: %08x\n", nsres); - - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_put_accessKey(IHTMLElement2 *iface, BSTR v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - VARIANT var; - - static WCHAR accessKeyW[] = {'a','c','c','e','s','s','K','e','y',0}; - - TRACE("(%p)->(%s)\n", This, debugstr_w(v)); - - V_VT(&var) = VT_BSTR; - V_BSTR(&var) = v; - return IHTMLElement_setAttribute(&This->IHTMLElement_iface, accessKeyW, var, 0); -} - -static HRESULT WINAPI HTMLElement2_get_accessKey(IHTMLElement2 *iface, BSTR *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_onblur(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); - - return set_node_event(&This->node, EVENTID_BLUR, &v); -} - -static HRESULT WINAPI HTMLElement2_get_onblur(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%p)\n", This, p); - - return get_node_event(&This->node, EVENTID_BLUR, p); -} - -static HRESULT WINAPI HTMLElement2_put_onfocus(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); - - return set_node_event(&This->node, EVENTID_FOCUS, &v); -} - -static HRESULT WINAPI HTMLElement2_get_onfocus(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%p)\n", This, p); - - return get_node_event(&This->node, EVENTID_FOCUS, p); -} - -static HRESULT WINAPI HTMLElement2_put_onresize(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onresize(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_blur(IHTMLElement2 *iface) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)\n", This); - - nsres = nsIDOMHTMLElement_Blur(This->nselem); - if(NS_FAILED(nsres)) { - ERR("Blur failed: %08x\n", nsres); - return E_FAIL; - } - - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_addFilter(IHTMLElement2 *iface, IUnknown *pUnk) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, pUnk); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_removeFilter(IHTMLElement2 *iface, IUnknown *pUnk) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, pUnk); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_clientHeight(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMHTMLElement_GetClientHeight(This->nselem, p); - assert(nsres == NS_OK); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_get_clientWidth(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMHTMLElement_GetClientWidth(This->nselem, p); - assert(nsres == NS_OK); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_get_clientTop(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMHTMLElement_GetClientTop(This->nselem, p); - assert(nsres == NS_OK); - - TRACE("*p = %d\n", *p); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_get_clientLeft(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMHTMLElement_GetClientLeft(This->nselem, p); - assert(nsres == NS_OK); - - TRACE("*p = %d\n", *p); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_attachEvent(IHTMLElement2 *iface, BSTR event, - IDispatch *pDisp, VARIANT_BOOL *pfResult) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%s %p %p)\n", This, debugstr_w(event), pDisp, pfResult); - - return attach_event(get_node_event_target(&This->node), &This->node.doc->basedoc, event, pDisp, pfResult); -} - -static HRESULT WINAPI HTMLElement2_detachEvent(IHTMLElement2 *iface, BSTR event, IDispatch *pDisp) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%s %p)\n", This, debugstr_w(event), pDisp); - - return detach_event(*get_node_event_target(&This->node), &This->node.doc->basedoc, event, pDisp); -} - -static HRESULT WINAPI HTMLElement2_get_readyState(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - BSTR str; - - TRACE("(%p)->(%p)\n", This, p); - - if(This->node.vtbl->get_readystate) { - HRESULT hres; - - hres = This->node.vtbl->get_readystate(&This->node, &str); - if(FAILED(hres)) - return hres; - }else { - static const WCHAR completeW[] = {'c','o','m','p','l','e','t','e',0}; - - str = SysAllocString(completeW); - if(!str) - return E_OUTOFMEMORY; - } - - V_VT(p) = VT_BSTR; - V_BSTR(p) = str; - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_put_onreadystatechange(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); - - return set_node_event(&This->node, EVENTID_READYSTATECHANGE, &v); -} - -static HRESULT WINAPI HTMLElement2_get_onreadystatechange(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%p)\n", This, p); - - return get_node_event(&This->node, EVENTID_READYSTATECHANGE, p); -} - -static HRESULT WINAPI HTMLElement2_put_onrowsdelete(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onrowsdelete(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_onrowsinserted(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onrowsinserted(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_oncellchange(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_oncellchange(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_dir(IHTMLElement2 *iface, BSTR v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_dir(IHTMLElement2 *iface, BSTR *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsAString dir_str; - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - if(!This->nselem) { - *p = NULL; - return S_OK; - } - - nsAString_Init(&dir_str, NULL); - nsres = nsIDOMHTMLElement_GetDir(This->nselem, &dir_str); - return return_nsstr(nsres, &dir_str, p); -} - -static HRESULT WINAPI HTMLElement2_createControlRange(IHTMLElement2 *iface, IDispatch **range) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, range); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_scrollHeight(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMHTMLElement_GetScrollHeight(This->nselem, p); - assert(nsres == NS_OK); - - TRACE("*p = %d\n", *p); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_get_scrollWidth(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMHTMLElement_GetScrollWidth(This->nselem, p); - assert(nsres == NS_OK); - - TRACE("*p = %d\n", *p); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_put_scrollTop(IHTMLElement2 *iface, LONG v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%d)\n", This, v); - - if(!This->nselem) { - FIXME("NULL nselem\n"); - return E_NOTIMPL; - } - - nsIDOMHTMLElement_SetScrollTop(This->nselem, v); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_get_scrollTop(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - nsres = nsIDOMHTMLElement_GetScrollTop(This->nselem, p); - assert(nsres == NS_OK); - - TRACE("*p = %d\n", *p); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_put_scrollLeft(IHTMLElement2 *iface, LONG v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - TRACE("(%p)->(%d)\n", This, v); - - if(!This->nselem) { - FIXME("NULL nselem\n"); - return E_NOTIMPL; - } - - nsIDOMHTMLElement_SetScrollLeft(This->nselem, v); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_get_scrollLeft(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsresult nsres; - - TRACE("(%p)->(%p)\n", This, p); - - if(!p) - return E_INVALIDARG; - - if(!This->nselem) - { - FIXME("NULL nselem\n"); - return E_NOTIMPL; - } - - nsres = nsIDOMHTMLElement_GetScrollLeft(This->nselem, p); - assert(nsres == NS_OK); - - TRACE("*p = %d\n", *p); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_clearAttributes(IHTMLElement2 *iface) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_mergeAttributes(IHTMLElement2 *iface, IHTMLElement *mergeThis) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, mergeThis); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_oncontextmenu(IHTMLElement2 *iface, VARIANT v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_oncontextmenu(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_insertAdjacentElement(IHTMLElement2 *iface, BSTR where, - IHTMLElement *insertedElement, IHTMLElement **inserted) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - HTMLDOMNode *ret_node; - HTMLElement *elem; - HRESULT hres; - - TRACE("(%p)->(%s %p %p)\n", This, debugstr_w(where), insertedElement, inserted); - - elem = unsafe_impl_from_IHTMLElement(insertedElement); - if(!elem) - return E_INVALIDARG; - - hres = insert_adjacent_node(This, where, elem->node.nsnode, &ret_node); - if(FAILED(hres)) - return hres; - - hres = IHTMLDOMNode_QueryInterface(&ret_node->IHTMLDOMNode_iface, &IID_IHTMLElement, (void**)inserted); - IHTMLDOMNode_Release(&ret_node->IHTMLDOMNode_iface); - return hres; -} - -static HRESULT WINAPI HTMLElement2_applyElement(IHTMLElement2 *iface, IHTMLElement *apply, - BSTR where, IHTMLElement **applied) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p %s %p)\n", This, apply, debugstr_w(where), applied); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_getAdjacentText(IHTMLElement2 *iface, BSTR where, BSTR *text) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%s %p)\n", This, debugstr_w(where), text); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_replaceAdjacentText(IHTMLElement2 *iface, BSTR where, - BSTR newText, BSTR *oldText) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%s %s %p)\n", This, debugstr_w(where), debugstr_w(newText), oldText); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_canHandleChildren(IHTMLElement2 *iface, VARIANT_BOOL *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_addBehavior(IHTMLElement2 *iface, BSTR bstrUrl, - VARIANT *pvarFactory, LONG *pCookie) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%s %p %p)\n", This, debugstr_w(bstrUrl), pvarFactory, pCookie); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_removeBehavior(IHTMLElement2 *iface, LONG cookie, - VARIANT_BOOL *pfResult) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%d %p)\n", This, cookie, pfResult); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_runtimeStyle(IHTMLElement2 *iface, IHTMLStyle **p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - - FIXME("(%p)->(%p): hack\n", This, p); - - /* We can't implement correct behavior on top of Gecko (although we could - try a bit harder). Making runtimeStyle behave like regular style is - enough for most use cases. */ - if(!This->runtime_style) { - HRESULT hres; - - hres = HTMLStyle_Create(This, &This->runtime_style); - if(FAILED(hres)) - return hres; - } - - *p = &This->runtime_style->IHTMLStyle_iface; - IHTMLStyle_AddRef(*p); - return S_OK; -} - -static HRESULT WINAPI HTMLElement2_get_behaviorUrns(IHTMLElement2 *iface, IDispatch **p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_tagUrn(IHTMLElement2 *iface, BSTR v) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_tagUrn(IHTMLElement2 *iface, BSTR *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_put_onbeforeeditfocus(IHTMLElement2 *iface, VARIANT vv) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->()\n", This); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_onbeforeeditfocus(IHTMLElement2 *iface, VARIANT *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_get_readyStateValue(IHTMLElement2 *iface, LONG *p) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; -} - -static HRESULT WINAPI HTMLElement2_getElementsByTagName(IHTMLElement2 *iface, BSTR v, - IHTMLElementCollection **pelColl) -{ - HTMLElement *This = impl_from_IHTMLElement2(iface); - nsIDOMHTMLCollection *nscol; - nsAString tag_str; - nsresult nsres; - - TRACE("(%p)->(%s %p)\n", This, debugstr_w(v), pelColl); - - nsAString_InitDepend(&tag_str, v); - nsres = nsIDOMHTMLElement_GetElementsByTagName(This->nselem, &tag_str, &nscol); - nsAString_Finish(&tag_str); - if(NS_FAILED(nsres)) { - ERR("GetElementByTagName failed: %08x\n", nsres); - return E_FAIL; - } - - *pelColl = create_collection_from_htmlcol(This->node.doc, nscol); - nsIDOMHTMLCollection_Release(nscol); - return S_OK; -} - -static const IHTMLElement2Vtbl HTMLElement2Vtbl = { - HTMLElement2_QueryInterface, - HTMLElement2_AddRef, - HTMLElement2_Release, - HTMLElement2_GetTypeInfoCount, - HTMLElement2_GetTypeInfo, - HTMLElement2_GetIDsOfNames, - HTMLElement2_Invoke, - HTMLElement2_get_scopeName, - HTMLElement2_setCapture, - HTMLElement2_releaseCapture, - HTMLElement2_put_onlosecapture, - HTMLElement2_get_onlosecapture, - HTMLElement2_componentFromPoint, - HTMLElement2_doScroll, - HTMLElement2_put_onscroll, - HTMLElement2_get_onscroll, - HTMLElement2_put_ondrag, - HTMLElement2_get_ondrag, - HTMLElement2_put_ondragend, - HTMLElement2_get_ondragend, - HTMLElement2_put_ondragenter, - HTMLElement2_get_ondragenter, - HTMLElement2_put_ondragover, - HTMLElement2_get_ondragover, - HTMLElement2_put_ondragleave, - HTMLElement2_get_ondragleave, - HTMLElement2_put_ondrop, - HTMLElement2_get_ondrop, - HTMLElement2_put_onbeforecut, - HTMLElement2_get_onbeforecut, - HTMLElement2_put_oncut, - HTMLElement2_get_oncut, - HTMLElement2_put_onbeforecopy, - HTMLElement2_get_onbeforecopy, - HTMLElement2_put_oncopy, - HTMLElement2_get_oncopy, - HTMLElement2_put_onbeforepaste, - HTMLElement2_get_onbeforepaste, - HTMLElement2_put_onpaste, - HTMLElement2_get_onpaste, - HTMLElement2_get_currentStyle, - HTMLElement2_put_onpropertychange, - HTMLElement2_get_onpropertychange, - HTMLElement2_getClientRects, - HTMLElement2_getBoundingClientRect, - HTMLElement2_setExpression, - HTMLElement2_getExpression, - HTMLElement2_removeExpression, - HTMLElement2_put_tabIndex, - HTMLElement2_get_tabIndex, - HTMLElement2_focus, - HTMLElement2_put_accessKey, - HTMLElement2_get_accessKey, - HTMLElement2_put_onblur, - HTMLElement2_get_onblur, - HTMLElement2_put_onfocus, - HTMLElement2_get_onfocus, - HTMLElement2_put_onresize, - HTMLElement2_get_onresize, - HTMLElement2_blur, - HTMLElement2_addFilter, - HTMLElement2_removeFilter, - HTMLElement2_get_clientHeight, - HTMLElement2_get_clientWidth, - HTMLElement2_get_clientTop, - HTMLElement2_get_clientLeft, - HTMLElement2_attachEvent, - HTMLElement2_detachEvent, - HTMLElement2_get_readyState, - HTMLElement2_put_onreadystatechange, - HTMLElement2_get_onreadystatechange, - HTMLElement2_put_onrowsdelete, - HTMLElement2_get_onrowsdelete, - HTMLElement2_put_onrowsinserted, - HTMLElement2_get_onrowsinserted, - HTMLElement2_put_oncellchange, - HTMLElement2_get_oncellchange, - HTMLElement2_put_dir, - HTMLElement2_get_dir, - HTMLElement2_createControlRange, - HTMLElement2_get_scrollHeight, - HTMLElement2_get_scrollWidth, - HTMLElement2_put_scrollTop, - HTMLElement2_get_scrollTop, - HTMLElement2_put_scrollLeft, - HTMLElement2_get_scrollLeft, - HTMLElement2_clearAttributes, - HTMLElement2_mergeAttributes, - HTMLElement2_put_oncontextmenu, - HTMLElement2_get_oncontextmenu, - HTMLElement2_insertAdjacentElement, - HTMLElement2_applyElement, - HTMLElement2_getAdjacentText, - HTMLElement2_replaceAdjacentText, - HTMLElement2_get_canHandleChildren, - HTMLElement2_addBehavior, - HTMLElement2_removeBehavior, - HTMLElement2_get_runtimeStyle, - HTMLElement2_get_behaviorUrns, - HTMLElement2_put_tagUrn, - HTMLElement2_get_tagUrn, - HTMLElement2_put_onbeforeeditfocus, - HTMLElement2_get_onbeforeeditfocus, - HTMLElement2_get_readyStateValue, - HTMLElement2_getElementsByTagName, -}; - -void HTMLElement2_Init(HTMLElement *This) -{ - This->IHTMLElement2_iface.lpVtbl = &HTMLElement2Vtbl; -} diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlelem.c wine1.7-1.7.31/dlls/mshtml/htmlelem.c --- wine1.7-1.7.28/dlls/mshtml/htmlelem.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlelem.c 2014-11-14 13:28:17.000000000 +0000 @@ -1,5 +1,5 @@ /* - * Copyright 2006 Jacek Caban for CodeWeavers + * Copyright 2006-2010 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 @@ -18,6 +18,7 @@ #include #include +#include #define COBJMACROS @@ -218,6 +219,27 @@ return S_OK; } +HRESULT get_readystate_string(READYSTATE readystate, BSTR *p) +{ + static const WCHAR uninitializedW[] = {'u','n','i','n','i','t','i','a','l','i','z','e','d',0}; + static const WCHAR loadingW[] = {'l','o','a','d','i','n','g',0}; + static const WCHAR loadedW[] = {'l','o','a','d','e','d',0}; + static const WCHAR interactiveW[] = {'i','n','t','e','r','a','c','t','i','v','e',0}; + static const WCHAR completeW[] = {'c','o','m','p','l','e','t','e',0}; + + static const LPCWSTR readystate_strs[] = { + uninitializedW, + loadingW, + loadedW, + interactiveW, + completeW + }; + + assert(readystate <= READYSTATE_COMPLETE); + *p = SysAllocString(readystate_strs[readystate]); + return *p ? S_OK : E_OUTOFMEMORY; +} + typedef struct { DispatchEx dispex; @@ -285,6 +307,251 @@ return hres; } +typedef struct { + DispatchEx dispex; + IHTMLRect IHTMLRect_iface; + + LONG ref; + + nsIDOMClientRect *nsrect; +} HTMLRect; + +static inline HTMLRect *impl_from_IHTMLRect(IHTMLRect *iface) +{ + return CONTAINING_RECORD(iface, HTMLRect, IHTMLRect_iface); +} + +static HRESULT WINAPI HTMLRect_QueryInterface(IHTMLRect *iface, REFIID riid, void **ppv) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + + if(IsEqualGUID(&IID_IUnknown, riid)) { + *ppv = &This->IHTMLRect_iface; + }else if(IsEqualGUID(&IID_IHTMLRect, riid)) { + *ppv = &This->IHTMLRect_iface; + }else if(dispex_query_interface(&This->dispex, riid, ppv)) { + return *ppv ? S_OK : E_NOINTERFACE; + }else { + FIXME("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); + *ppv = NULL; + return E_NOINTERFACE; + } + + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; +} + +static ULONG WINAPI HTMLRect_AddRef(IHTMLRect *iface) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + LONG ref = InterlockedIncrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + return ref; +} + +static ULONG WINAPI HTMLRect_Release(IHTMLRect *iface) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + LONG ref = InterlockedDecrement(&This->ref); + + TRACE("(%p) ref=%d\n", This, ref); + + if(!ref) { + if(This->nsrect) + nsIDOMClientRect_Release(This->nsrect); + heap_free(This); + } + + return ref; +} + +static HRESULT WINAPI HTMLRect_GetTypeInfoCount(IHTMLRect *iface, UINT *pctinfo) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + FIXME("(%p)->(%p)\n", This, pctinfo); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLRect_GetTypeInfo(IHTMLRect *iface, UINT iTInfo, + LCID lcid, ITypeInfo **ppTInfo) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + + return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); +} + +static HRESULT WINAPI HTMLRect_GetIDsOfNames(IHTMLRect *iface, REFIID riid, + LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + + return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, cNames, + lcid, rgDispId); +} + +static HRESULT WINAPI HTMLRect_Invoke(IHTMLRect *iface, DISPID dispIdMember, + REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, + VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + + return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, lcid, wFlags, + pDispParams, pVarResult, pExcepInfo, puArgErr); +} + +static HRESULT WINAPI HTMLRect_put_left(IHTMLRect *iface, LONG v) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + FIXME("(%p)->(%d)\n", This, v); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLRect_get_left(IHTMLRect *iface, LONG *p) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + float left; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMClientRect_GetLeft(This->nsrect, &left); + if(NS_FAILED(nsres)) { + ERR("GetLeft failed: %08x\n", nsres); + return E_FAIL; + } + + *p = floor(left+0.5); + return S_OK; +} + +static HRESULT WINAPI HTMLRect_put_top(IHTMLRect *iface, LONG v) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + FIXME("(%p)->(%d)\n", This, v); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLRect_get_top(IHTMLRect *iface, LONG *p) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + float top; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMClientRect_GetTop(This->nsrect, &top); + if(NS_FAILED(nsres)) { + ERR("GetTop failed: %08x\n", nsres); + return E_FAIL; + } + + *p = floor(top+0.5); + return S_OK; +} + +static HRESULT WINAPI HTMLRect_put_right(IHTMLRect *iface, LONG v) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + FIXME("(%p)->(%d)\n", This, v); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLRect_get_right(IHTMLRect *iface, LONG *p) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + float right; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMClientRect_GetRight(This->nsrect, &right); + if(NS_FAILED(nsres)) { + ERR("GetRight failed: %08x\n", nsres); + return E_FAIL; + } + + *p = floor(right+0.5); + return S_OK; +} + +static HRESULT WINAPI HTMLRect_put_bottom(IHTMLRect *iface, LONG v) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + FIXME("(%p)->(%d)\n", This, v); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLRect_get_bottom(IHTMLRect *iface, LONG *p) +{ + HTMLRect *This = impl_from_IHTMLRect(iface); + float bottom; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMClientRect_GetBottom(This->nsrect, &bottom); + if(NS_FAILED(nsres)) { + ERR("GetBottom failed: %08x\n", nsres); + return E_FAIL; + } + + *p = floor(bottom+0.5); + return S_OK; +} + +static const IHTMLRectVtbl HTMLRectVtbl = { + HTMLRect_QueryInterface, + HTMLRect_AddRef, + HTMLRect_Release, + HTMLRect_GetTypeInfoCount, + HTMLRect_GetTypeInfo, + HTMLRect_GetIDsOfNames, + HTMLRect_Invoke, + HTMLRect_put_left, + HTMLRect_get_left, + HTMLRect_put_top, + HTMLRect_get_top, + HTMLRect_put_right, + HTMLRect_get_right, + HTMLRect_put_bottom, + HTMLRect_get_bottom +}; + +static const tid_t HTMLRect_iface_tids[] = { + IHTMLRect_tid, + 0 +}; +static dispex_static_data_t HTMLRect_dispex = { + NULL, + IHTMLRect_tid, + NULL, + HTMLRect_iface_tids +}; + +static HRESULT create_html_rect(nsIDOMClientRect *nsrect, IHTMLRect **ret) +{ + HTMLRect *rect; + + rect = heap_alloc_zero(sizeof(HTMLRect)); + if(!rect) + return E_OUTOFMEMORY; + + rect->IHTMLRect_iface.lpVtbl = &HTMLRectVtbl; + rect->ref = 1; + + init_dispex(&rect->dispex, (IUnknown*)&rect->IHTMLRect_iface, &HTMLRect_dispex); + + nsIDOMClientRect_AddRef(nsrect); + rect->nsrect = nsrect; + + *ret = &rect->IHTMLRect_iface; + return S_OK; +} + static HRESULT WINAPI HTMLElement_QueryInterface(IHTMLElement *iface, REFIID riid, void **ppv) { @@ -816,18 +1083,24 @@ return return_nsstr(nsres, &title_str, p); } +static const WCHAR languageW[] = {'l','a','n','g','u','a','g','e',0}; + static HRESULT WINAPI HTMLElement_put_language(IHTMLElement *iface, BSTR v) { HTMLElement *This = impl_from_IHTMLElement(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + return elem_string_attr_setter(This, languageW, v); } static HRESULT WINAPI HTMLElement_get_language(IHTMLElement *iface, BSTR *p) { HTMLElement *This = impl_from_IHTMLElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return elem_string_attr_getter(This, languageW, TRUE, p); } static HRESULT WINAPI HTMLElement_put_onselectstart(IHTMLElement *iface, VARIANT v) @@ -1643,6 +1916,1124 @@ return iface->lpVtbl == &HTMLElementVtbl ? impl_from_IHTMLElement(iface) : NULL; } +static inline HTMLElement *impl_from_IHTMLElement2(IHTMLElement2 *iface) +{ + return CONTAINING_RECORD(iface, HTMLElement, IHTMLElement2_iface); +} + +static HRESULT WINAPI HTMLElement2_QueryInterface(IHTMLElement2 *iface, + REFIID riid, void **ppv) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + return IHTMLElement_QueryInterface(&This->IHTMLElement_iface, riid, ppv); +} + +static ULONG WINAPI HTMLElement2_AddRef(IHTMLElement2 *iface) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + return IHTMLElement_AddRef(&This->IHTMLElement_iface); +} + +static ULONG WINAPI HTMLElement2_Release(IHTMLElement2 *iface) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + return IHTMLElement_Release(&This->IHTMLElement_iface); +} + +static HRESULT WINAPI HTMLElement2_GetTypeInfoCount(IHTMLElement2 *iface, UINT *pctinfo) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + return IDispatchEx_GetTypeInfoCount(&This->node.dispex.IDispatchEx_iface, pctinfo); +} + +static HRESULT WINAPI HTMLElement2_GetTypeInfo(IHTMLElement2 *iface, UINT iTInfo, + LCID lcid, ITypeInfo **ppTInfo) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + return IDispatchEx_GetTypeInfo(&This->node.dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); +} + +static HRESULT WINAPI HTMLElement2_GetIDsOfNames(IHTMLElement2 *iface, REFIID riid, + LPOLESTR *rgszNames, UINT cNames, + LCID lcid, DISPID *rgDispId) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + return IDispatchEx_GetIDsOfNames(&This->node.dispex.IDispatchEx_iface, riid, rgszNames, cNames, + lcid, rgDispId); +} + +static HRESULT WINAPI HTMLElement2_Invoke(IHTMLElement2 *iface, DISPID dispIdMember, + REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, + VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + return IDispatchEx_Invoke(&This->node.dispex.IDispatchEx_iface, dispIdMember, riid, lcid, + wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); +} + +static HRESULT WINAPI HTMLElement2_get_scopeName(IHTMLElement2 *iface, BSTR *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_setCapture(IHTMLElement2 *iface, VARIANT_BOOL containerCapture) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%x)\n", This, containerCapture); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_releaseCapture(IHTMLElement2 *iface) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_onlosecapture(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onlosecapture(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_componentFromPoint(IHTMLElement2 *iface, + LONG x, LONG y, BSTR *component) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%d %d %p)\n", This, x, y, component); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_doScroll(IHTMLElement2 *iface, VARIANT component) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&component)); + + if(!This->node.doc->content_ready + || !This->node.doc->basedoc.doc_obj->in_place_active) + return E_PENDING; + + WARN("stub\n"); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_put_onscroll(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onscroll(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_ondrag(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_node_event(&This->node, EVENTID_DRAG, &v); +} + +static HRESULT WINAPI HTMLElement2_get_ondrag(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%p)\n", This, p); + + return get_node_event(&This->node, EVENTID_DRAG, p); +} + +static HRESULT WINAPI HTMLElement2_put_ondragend(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_ondragend(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_ondragenter(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_ondragenter(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_ondragover(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_ondragover(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_ondragleave(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_ondragleave(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_ondrop(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_ondrop(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_onbeforecut(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onbeforecut(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_oncut(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_oncut(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_onbeforecopy(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onbeforecopy(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_oncopy(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_oncopy(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_onbeforepaste(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onbeforepaste(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_onpaste(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_node_event(&This->node, EVENTID_PASTE, &v); +} + +static HRESULT WINAPI HTMLElement2_get_onpaste(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%p)\n", This, p); + + return get_node_event(&This->node, EVENTID_PASTE, p); +} + +static HRESULT WINAPI HTMLElement2_get_currentStyle(IHTMLElement2 *iface, IHTMLCurrentStyle **p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%p)\n", This, p); + + return HTMLCurrentStyle_Create(This, p); +} + +static HRESULT WINAPI HTMLElement2_put_onpropertychange(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onpropertychange(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_getClientRects(IHTMLElement2 *iface, IHTMLRectCollection **pRectCol) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, pRectCol); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_getBoundingClientRect(IHTMLElement2 *iface, IHTMLRect **pRect) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsIDOMClientRect *nsrect; + nsresult nsres; + HRESULT hres; + + TRACE("(%p)->(%p)\n", This, pRect); + + nsres = nsIDOMHTMLElement_GetBoundingClientRect(This->nselem, &nsrect); + if(NS_FAILED(nsres) || !nsrect) { + ERR("GetBoindingClientRect failed: %08x\n", nsres); + return E_FAIL; + } + + hres = create_html_rect(nsrect, pRect); + + nsIDOMClientRect_Release(nsrect); + return hres; +} + +static HRESULT WINAPI HTMLElement2_setExpression(IHTMLElement2 *iface, BSTR propname, + BSTR expression, BSTR language) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%s %s %s)\n", This, debugstr_w(propname), debugstr_w(expression), + debugstr_w(language)); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_getExpression(IHTMLElement2 *iface, BSTR propname, + VARIANT *expression) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_w(propname), expression); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_removeExpression(IHTMLElement2 *iface, BSTR propname, + VARIANT_BOOL *pfSuccess) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_w(propname), pfSuccess); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_tabIndex(IHTMLElement2 *iface, short v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%d)\n", This, v); + + nsres = nsIDOMHTMLElement_SetTabIndex(This->nselem, v); + if(NS_FAILED(nsres)) + ERR("GetTabIndex failed: %08x\n", nsres); + + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_tabIndex(IHTMLElement2 *iface, short *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + LONG index; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLElement_GetTabIndex(This->nselem, &index); + if(NS_FAILED(nsres)) { + ERR("GetTabIndex failed: %08x\n", nsres); + return E_FAIL; + } + + *p = index; + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_focus(IHTMLElement2 *iface) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)\n", This); + + nsres = nsIDOMHTMLElement_Focus(This->nselem); + if(NS_FAILED(nsres)) + ERR("Focus failed: %08x\n", nsres); + + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_put_accessKey(IHTMLElement2 *iface, BSTR v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + VARIANT var; + + static WCHAR accessKeyW[] = {'a','c','c','e','s','s','K','e','y',0}; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + V_VT(&var) = VT_BSTR; + V_BSTR(&var) = v; + return IHTMLElement_setAttribute(&This->IHTMLElement_iface, accessKeyW, var, 0); +} + +static HRESULT WINAPI HTMLElement2_get_accessKey(IHTMLElement2 *iface, BSTR *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_onblur(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_node_event(&This->node, EVENTID_BLUR, &v); +} + +static HRESULT WINAPI HTMLElement2_get_onblur(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%p)\n", This, p); + + return get_node_event(&This->node, EVENTID_BLUR, p); +} + +static HRESULT WINAPI HTMLElement2_put_onfocus(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_node_event(&This->node, EVENTID_FOCUS, &v); +} + +static HRESULT WINAPI HTMLElement2_get_onfocus(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%p)\n", This, p); + + return get_node_event(&This->node, EVENTID_FOCUS, p); +} + +static HRESULT WINAPI HTMLElement2_put_onresize(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onresize(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_blur(IHTMLElement2 *iface) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)\n", This); + + nsres = nsIDOMHTMLElement_Blur(This->nselem); + if(NS_FAILED(nsres)) { + ERR("Blur failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_addFilter(IHTMLElement2 *iface, IUnknown *pUnk) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, pUnk); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_removeFilter(IHTMLElement2 *iface, IUnknown *pUnk) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, pUnk); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_clientHeight(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLElement_GetClientHeight(This->nselem, p); + assert(nsres == NS_OK); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_clientWidth(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLElement_GetClientWidth(This->nselem, p); + assert(nsres == NS_OK); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_clientTop(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLElement_GetClientTop(This->nselem, p); + assert(nsres == NS_OK); + + TRACE("*p = %d\n", *p); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_clientLeft(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLElement_GetClientLeft(This->nselem, p); + assert(nsres == NS_OK); + + TRACE("*p = %d\n", *p); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_attachEvent(IHTMLElement2 *iface, BSTR event, + IDispatch *pDisp, VARIANT_BOOL *pfResult) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%s %p %p)\n", This, debugstr_w(event), pDisp, pfResult); + + return attach_event(get_node_event_target(&This->node), &This->node.doc->basedoc, event, pDisp, pfResult); +} + +static HRESULT WINAPI HTMLElement2_detachEvent(IHTMLElement2 *iface, BSTR event, IDispatch *pDisp) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%s %p)\n", This, debugstr_w(event), pDisp); + + return detach_event(*get_node_event_target(&This->node), &This->node.doc->basedoc, event, pDisp); +} + +static HRESULT WINAPI HTMLElement2_get_readyState(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + BSTR str; + + TRACE("(%p)->(%p)\n", This, p); + + if(This->node.vtbl->get_readystate) { + HRESULT hres; + + hres = This->node.vtbl->get_readystate(&This->node, &str); + if(FAILED(hres)) + return hres; + }else { + static const WCHAR completeW[] = {'c','o','m','p','l','e','t','e',0}; + + str = SysAllocString(completeW); + if(!str) + return E_OUTOFMEMORY; + } + + V_VT(p) = VT_BSTR; + V_BSTR(p) = str; + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_put_onreadystatechange(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_node_event(&This->node, EVENTID_READYSTATECHANGE, &v); +} + +static HRESULT WINAPI HTMLElement2_get_onreadystatechange(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%p)\n", This, p); + + return get_node_event(&This->node, EVENTID_READYSTATECHANGE, p); +} + +static HRESULT WINAPI HTMLElement2_put_onrowsdelete(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onrowsdelete(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_onrowsinserted(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onrowsinserted(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_oncellchange(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_oncellchange(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_dir(IHTMLElement2 *iface, BSTR v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsAString nsstr; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_w(v)); + + if(!This->nselem) { + FIXME("Unsupported for comment nodes.\n"); + return S_OK; + } + + nsAString_InitDepend(&nsstr, v); + nsres = nsIDOMHTMLElement_SetDir(This->nselem, &nsstr); + nsAString_Finish(&nsstr); + if(NS_FAILED(nsres)) { + ERR("SetDir failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_dir(IHTMLElement2 *iface, BSTR *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsAString dir_str; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + if(!This->nselem) { + *p = NULL; + return S_OK; + } + + nsAString_Init(&dir_str, NULL); + nsres = nsIDOMHTMLElement_GetDir(This->nselem, &dir_str); + return return_nsstr(nsres, &dir_str, p); +} + +static HRESULT WINAPI HTMLElement2_createControlRange(IHTMLElement2 *iface, IDispatch **range) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, range); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_scrollHeight(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLElement_GetScrollHeight(This->nselem, p); + assert(nsres == NS_OK); + + TRACE("*p = %d\n", *p); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_scrollWidth(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLElement_GetScrollWidth(This->nselem, p); + assert(nsres == NS_OK); + + TRACE("*p = %d\n", *p); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_put_scrollTop(IHTMLElement2 *iface, LONG v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%d)\n", This, v); + + if(!This->nselem) { + FIXME("NULL nselem\n"); + return E_NOTIMPL; + } + + nsIDOMHTMLElement_SetScrollTop(This->nselem, v); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_scrollTop(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLElement_GetScrollTop(This->nselem, p); + assert(nsres == NS_OK); + + TRACE("*p = %d\n", *p); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_put_scrollLeft(IHTMLElement2 *iface, LONG v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + TRACE("(%p)->(%d)\n", This, v); + + if(!This->nselem) { + FIXME("NULL nselem\n"); + return E_NOTIMPL; + } + + nsIDOMHTMLElement_SetScrollLeft(This->nselem, v); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_scrollLeft(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + if(!p) + return E_INVALIDARG; + + if(!This->nselem) + { + FIXME("NULL nselem\n"); + return E_NOTIMPL; + } + + nsres = nsIDOMHTMLElement_GetScrollLeft(This->nselem, p); + assert(nsres == NS_OK); + + TRACE("*p = %d\n", *p); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_clearAttributes(IHTMLElement2 *iface) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_mergeAttributes(IHTMLElement2 *iface, IHTMLElement *mergeThis) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, mergeThis); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_oncontextmenu(IHTMLElement2 *iface, VARIANT v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_oncontextmenu(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_insertAdjacentElement(IHTMLElement2 *iface, BSTR where, + IHTMLElement *insertedElement, IHTMLElement **inserted) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + HTMLDOMNode *ret_node; + HTMLElement *elem; + HRESULT hres; + + TRACE("(%p)->(%s %p %p)\n", This, debugstr_w(where), insertedElement, inserted); + + elem = unsafe_impl_from_IHTMLElement(insertedElement); + if(!elem) + return E_INVALIDARG; + + hres = insert_adjacent_node(This, where, elem->node.nsnode, &ret_node); + if(FAILED(hres)) + return hres; + + hres = IHTMLDOMNode_QueryInterface(&ret_node->IHTMLDOMNode_iface, &IID_IHTMLElement, (void**)inserted); + IHTMLDOMNode_Release(&ret_node->IHTMLDOMNode_iface); + return hres; +} + +static HRESULT WINAPI HTMLElement2_applyElement(IHTMLElement2 *iface, IHTMLElement *apply, + BSTR where, IHTMLElement **applied) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p %s %p)\n", This, apply, debugstr_w(where), applied); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_getAdjacentText(IHTMLElement2 *iface, BSTR where, BSTR *text) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%s %p)\n", This, debugstr_w(where), text); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_replaceAdjacentText(IHTMLElement2 *iface, BSTR where, + BSTR newText, BSTR *oldText) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%s %s %p)\n", This, debugstr_w(where), debugstr_w(newText), oldText); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_canHandleChildren(IHTMLElement2 *iface, VARIANT_BOOL *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_addBehavior(IHTMLElement2 *iface, BSTR bstrUrl, + VARIANT *pvarFactory, LONG *pCookie) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%s %p %p)\n", This, debugstr_w(bstrUrl), pvarFactory, pCookie); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_removeBehavior(IHTMLElement2 *iface, LONG cookie, + VARIANT_BOOL *pfResult) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%d %p)\n", This, cookie, pfResult); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_runtimeStyle(IHTMLElement2 *iface, IHTMLStyle **p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + + FIXME("(%p)->(%p): hack\n", This, p); + + /* We can't implement correct behavior on top of Gecko (although we could + try a bit harder). Making runtimeStyle behave like regular style is + enough for most use cases. */ + if(!This->runtime_style) { + HRESULT hres; + + hres = HTMLStyle_Create(This, &This->runtime_style); + if(FAILED(hres)) + return hres; + } + + *p = &This->runtime_style->IHTMLStyle_iface; + IHTMLStyle_AddRef(*p); + return S_OK; +} + +static HRESULT WINAPI HTMLElement2_get_behaviorUrns(IHTMLElement2 *iface, IDispatch **p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_tagUrn(IHTMLElement2 *iface, BSTR v) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%s)\n", This, debugstr_w(v)); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_tagUrn(IHTMLElement2 *iface, BSTR *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_put_onbeforeeditfocus(IHTMLElement2 *iface, VARIANT vv) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->()\n", This); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_onbeforeeditfocus(IHTMLElement2 *iface, VARIANT *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_get_readyStateValue(IHTMLElement2 *iface, LONG *p) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + FIXME("(%p)->(%p)\n", This, p); + return E_NOTIMPL; +} + +static HRESULT WINAPI HTMLElement2_getElementsByTagName(IHTMLElement2 *iface, BSTR v, + IHTMLElementCollection **pelColl) +{ + HTMLElement *This = impl_from_IHTMLElement2(iface); + nsIDOMHTMLCollection *nscol; + nsAString tag_str; + nsresult nsres; + + TRACE("(%p)->(%s %p)\n", This, debugstr_w(v), pelColl); + + nsAString_InitDepend(&tag_str, v); + nsres = nsIDOMHTMLElement_GetElementsByTagName(This->nselem, &tag_str, &nscol); + nsAString_Finish(&tag_str); + if(NS_FAILED(nsres)) { + ERR("GetElementByTagName failed: %08x\n", nsres); + return E_FAIL; + } + + *pelColl = create_collection_from_htmlcol(This->node.doc, nscol); + nsIDOMHTMLCollection_Release(nscol); + return S_OK; +} + +static const IHTMLElement2Vtbl HTMLElement2Vtbl = { + HTMLElement2_QueryInterface, + HTMLElement2_AddRef, + HTMLElement2_Release, + HTMLElement2_GetTypeInfoCount, + HTMLElement2_GetTypeInfo, + HTMLElement2_GetIDsOfNames, + HTMLElement2_Invoke, + HTMLElement2_get_scopeName, + HTMLElement2_setCapture, + HTMLElement2_releaseCapture, + HTMLElement2_put_onlosecapture, + HTMLElement2_get_onlosecapture, + HTMLElement2_componentFromPoint, + HTMLElement2_doScroll, + HTMLElement2_put_onscroll, + HTMLElement2_get_onscroll, + HTMLElement2_put_ondrag, + HTMLElement2_get_ondrag, + HTMLElement2_put_ondragend, + HTMLElement2_get_ondragend, + HTMLElement2_put_ondragenter, + HTMLElement2_get_ondragenter, + HTMLElement2_put_ondragover, + HTMLElement2_get_ondragover, + HTMLElement2_put_ondragleave, + HTMLElement2_get_ondragleave, + HTMLElement2_put_ondrop, + HTMLElement2_get_ondrop, + HTMLElement2_put_onbeforecut, + HTMLElement2_get_onbeforecut, + HTMLElement2_put_oncut, + HTMLElement2_get_oncut, + HTMLElement2_put_onbeforecopy, + HTMLElement2_get_onbeforecopy, + HTMLElement2_put_oncopy, + HTMLElement2_get_oncopy, + HTMLElement2_put_onbeforepaste, + HTMLElement2_get_onbeforepaste, + HTMLElement2_put_onpaste, + HTMLElement2_get_onpaste, + HTMLElement2_get_currentStyle, + HTMLElement2_put_onpropertychange, + HTMLElement2_get_onpropertychange, + HTMLElement2_getClientRects, + HTMLElement2_getBoundingClientRect, + HTMLElement2_setExpression, + HTMLElement2_getExpression, + HTMLElement2_removeExpression, + HTMLElement2_put_tabIndex, + HTMLElement2_get_tabIndex, + HTMLElement2_focus, + HTMLElement2_put_accessKey, + HTMLElement2_get_accessKey, + HTMLElement2_put_onblur, + HTMLElement2_get_onblur, + HTMLElement2_put_onfocus, + HTMLElement2_get_onfocus, + HTMLElement2_put_onresize, + HTMLElement2_get_onresize, + HTMLElement2_blur, + HTMLElement2_addFilter, + HTMLElement2_removeFilter, + HTMLElement2_get_clientHeight, + HTMLElement2_get_clientWidth, + HTMLElement2_get_clientTop, + HTMLElement2_get_clientLeft, + HTMLElement2_attachEvent, + HTMLElement2_detachEvent, + HTMLElement2_get_readyState, + HTMLElement2_put_onreadystatechange, + HTMLElement2_get_onreadystatechange, + HTMLElement2_put_onrowsdelete, + HTMLElement2_get_onrowsdelete, + HTMLElement2_put_onrowsinserted, + HTMLElement2_get_onrowsinserted, + HTMLElement2_put_oncellchange, + HTMLElement2_get_oncellchange, + HTMLElement2_put_dir, + HTMLElement2_get_dir, + HTMLElement2_createControlRange, + HTMLElement2_get_scrollHeight, + HTMLElement2_get_scrollWidth, + HTMLElement2_put_scrollTop, + HTMLElement2_get_scrollTop, + HTMLElement2_put_scrollLeft, + HTMLElement2_get_scrollLeft, + HTMLElement2_clearAttributes, + HTMLElement2_mergeAttributes, + HTMLElement2_put_oncontextmenu, + HTMLElement2_get_oncontextmenu, + HTMLElement2_insertAdjacentElement, + HTMLElement2_applyElement, + HTMLElement2_getAdjacentText, + HTMLElement2_replaceAdjacentText, + HTMLElement2_get_canHandleChildren, + HTMLElement2_addBehavior, + HTMLElement2_removeBehavior, + HTMLElement2_get_runtimeStyle, + HTMLElement2_get_behaviorUrns, + HTMLElement2_put_tagUrn, + HTMLElement2_get_tagUrn, + HTMLElement2_put_onbeforeeditfocus, + HTMLElement2_get_onbeforeeditfocus, + HTMLElement2_get_readyStateValue, + HTMLElement2_getElementsByTagName, +}; + static inline HTMLElement *impl_from_HTMLDOMNode(HTMLDOMNode *iface) { return CONTAINING_RECORD(iface, HTMLElement, node); @@ -1905,8 +3296,8 @@ void HTMLElement_Init(HTMLElement *This, HTMLDocumentNode *doc, nsIDOMHTMLElement *nselem, dispex_static_data_t *dispex_data) { This->IHTMLElement_iface.lpVtbl = &HTMLElementVtbl; + This->IHTMLElement2_iface.lpVtbl = &HTMLElement2Vtbl; - HTMLElement2_Init(This); HTMLElement3_Init(This); if(dispex_data && !dispex_data->vtbl) diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlevent.c wine1.7-1.7.31/dlls/mshtml/htmlevent.c --- wine1.7-1.7.28/dlls/mshtml/htmlevent.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlevent.c 2014-11-14 13:28:17.000000000 +0000 @@ -551,7 +551,7 @@ static HRESULT WINAPI HTMLEventObj_get_button(IHTMLEventObj *iface, LONG *p) { HTMLEventObj *This = impl_from_IHTMLEventObj(iface); - UINT16 button = 0; + INT16 button = 0; TRACE("(%p)->(%p)\n", This, p); diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlform.c wine1.7-1.7.31/dlls/mshtml/htmlform.c --- wine1.7-1.7.28/dlls/mshtml/htmlform.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlform.c 2014-11-14 13:28:17.000000000 +0000 @@ -582,6 +582,9 @@ }else if(IsEqualGUID(&IID_IHTMLFormElement, riid)) { TRACE("(%p)->(IID_IHTMLFormElement %p)\n", This, ppv); *ppv = &This->IHTMLFormElement_iface; + }else if(IsEqualGUID(&DIID_DispHTMLFormElement, riid)) { + TRACE("(%p)->(DIID_DispHTMLFormElement %p)\n", This, ppv); + *ppv = &This->IHTMLFormElement_iface; } if(*ppv) { diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlnode.c wine1.7-1.7.31/dlls/mshtml/htmlnode.c --- wine1.7-1.7.28/dlls/mshtml/htmlnode.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlnode.c 2014-11-14 13:28:17.000000000 +0000 @@ -36,6 +36,8 @@ static HTMLDOMNode *get_node_obj(IHTMLDOMNode*); static HRESULT create_node(HTMLDocumentNode*,nsIDOMNode*,HTMLDOMNode**); +static ExternalCycleCollectionParticipant node_ccp; + typedef struct { DispatchEx dispex; IHTMLDOMChildrenCollection IHTMLDOMChildrenCollection_iface; @@ -477,7 +479,9 @@ static ULONG WINAPI HTMLDOMNode_AddRef(IHTMLDOMNode *iface) { HTMLDOMNode *This = impl_from_IHTMLDOMNode(iface); - LONG ref = ccref_incr(&This->ccref, (nsISupports*)&This->IHTMLDOMNode_iface); + LONG ref; + + ref = ccref_incr(&This->ccref, (nsISupports*)&This->IHTMLDOMNode_iface); TRACE("(%p) ref=%d\n", This, ref); @@ -487,18 +491,10 @@ static ULONG WINAPI HTMLDOMNode_Release(IHTMLDOMNode *iface) { HTMLDOMNode *This = impl_from_IHTMLDOMNode(iface); - LONG ref = ccref_decr(&This->ccref, (nsISupports*)&This->IHTMLDOMNode_iface); + LONG ref = ccref_decr(&This->ccref, (nsISupports*)&This->IHTMLDOMNode_iface, /*&node_ccp*/ NULL); TRACE("(%p) ref=%d\n", This, ref); - if(!ref) { - if(This->vtbl->unlink) - This->vtbl->unlink(This); - This->vtbl->destructor(This); - release_dispex(&This->dispex); - heap_free(This); - } - return ref; } @@ -1158,8 +1154,6 @@ HTMLDOMNode2_get_ownerDocument }; -static nsXPCOMCycleCollectionParticipant node_ccp; - HRESULT HTMLDOMNode_QI(HTMLDOMNode *This, REFIID riid, void **ppv) { TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); @@ -1287,12 +1281,6 @@ return S_OK; } -static void NSAPI HTMLDOMNode_unmark_if_purple(void *p) -{ - HTMLDOMNode *This = impl_from_IHTMLDOMNode(p); - ccref_unmark_if_purple(&This->ccref); -} - static nsresult NSAPI HTMLDOMNode_traverse(void *ccp, void *p, nsCycleCollectionTraversalCallback *cb) { HTMLDOMNode *This = impl_from_IHTMLDOMNode(p); @@ -1341,12 +1329,25 @@ return NS_OK; } +static void NSAPI HTMLDOMNode_delete_cycle_collectable(void *p) +{ + HTMLDOMNode *This = impl_from_IHTMLDOMNode(p); + + TRACE("(%p)\n", This); + + if(This->vtbl->unlink) + This->vtbl->unlink(This); + This->vtbl->destructor(This); + release_dispex(&This->dispex); + heap_free(This); +} + void init_node_cc(void) { static const CCObjCallback node_ccp_callback = { - HTMLDOMNode_unmark_if_purple, HTMLDOMNode_traverse, - HTMLDOMNode_unlink + HTMLDOMNode_unlink, + HTMLDOMNode_delete_cycle_collectable }; ccp_init(&node_ccp, &node_ccp_callback); diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlscript.c wine1.7-1.7.31/dlls/mshtml/htmlscript.c --- wine1.7-1.7.28/dlls/mshtml/htmlscript.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlscript.c 2014-11-14 13:28:17.000000000 +0000 @@ -29,6 +29,7 @@ #include "wine/debug.h" #include "mshtml_private.h" +#include "htmlevent.h" #include "htmlscript.h" WINE_DEFAULT_DEBUG_CHANNEL(mshtml); @@ -281,22 +282,28 @@ static HRESULT WINAPI HTMLScriptElement_get_readyState(IHTMLScriptElement *iface, BSTR *p) { HTMLScriptElement *This = impl_from_IHTMLScriptElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_readystate_string(This->readystate, p); } static HRESULT WINAPI HTMLScriptElement_put_onerror(IHTMLScriptElement *iface, VARIANT v) { HTMLScriptElement *This = impl_from_IHTMLScriptElement(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + + FIXME("(%p)->(%s) semi-stub\n", This, debugstr_variant(&v)); + + return set_node_event(&This->element.node, EVENTID_ERROR, &v); } static HRESULT WINAPI HTMLScriptElement_get_onerror(IHTMLScriptElement *iface, VARIANT *p) { HTMLScriptElement *This = impl_from_IHTMLScriptElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_node_event(&This->element.node, EVENTID_ERROR, p); } static HRESULT WINAPI HTMLScriptElement_put_type(IHTMLScriptElement *iface, BSTR v) diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlscript.h wine1.7-1.7.31/dlls/mshtml/htmlscript.h --- wine1.7-1.7.28/dlls/mshtml/htmlscript.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlscript.h 2014-11-14 13:28:17.000000000 +0000 @@ -24,6 +24,7 @@ nsIDOMHTMLScriptElement *nsscript; BOOL parsed; BOOL parse_on_bind; + READYSTATE readystate; } HTMLScriptElement; typedef struct { diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlstyle3.c wine1.7-1.7.31/dlls/mshtml/htmlstyle3.c --- wine1.7-1.7.28/dlls/mshtml/htmlstyle3.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlstyle3.c 2014-11-14 13:28:17.000000000 +0000 @@ -530,15 +530,19 @@ static HRESULT WINAPI HTMLStyle5_put_maxHeight(IHTMLStyle5 *iface, VARIANT v) { HTMLStyle *This = impl_from_IHTMLStyle5(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_nsstyle_attr_var(This->nsstyle, STYLEID_MAX_HEIGHT, &v, ATTR_FIX_PX); } static HRESULT WINAPI HTMLStyle5_get_maxHeight(IHTMLStyle5 *iface, VARIANT *p) { HTMLStyle *This = impl_from_IHTMLStyle5(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, debugstr_variant(p)); + + return get_nsstyle_attr_var(This->nsstyle, STYLEID_MAX_HEIGHT, p, 0); } static HRESULT WINAPI HTMLStyle5_put_minWidth(IHTMLStyle5 *iface, VARIANT v) @@ -562,15 +566,19 @@ static HRESULT WINAPI HTMLStyle5_put_maxWidth(IHTMLStyle5 *iface, VARIANT v) { HTMLStyle *This = impl_from_IHTMLStyle5(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + return set_nsstyle_attr_var(This->nsstyle, STYLEID_MAX_WIDTH, &v, ATTR_FIX_PX); } static HRESULT WINAPI HTMLStyle5_get_maxWidth(IHTMLStyle5 *iface, VARIANT *p) { HTMLStyle *This = impl_from_IHTMLStyle5(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, p); + + return get_nsstyle_attr_var(This->nsstyle, STYLEID_MAX_WIDTH, p, 0); } static const IHTMLStyle5Vtbl HTMLStyle5Vtbl = { diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlstyle.c wine1.7-1.7.31/dlls/mshtml/htmlstyle.c --- wine1.7-1.7.28/dlls/mshtml/htmlstyle.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlstyle.c 2014-11-14 13:28:17.000000000 +0000 @@ -144,6 +144,10 @@ {'m','a','r','g','i','n','-','r','i','g','h','t',0}; static const WCHAR attrMarginTop[] = {'m','a','r','g','i','n','-','t','o','p',0}; +static const WCHAR attrMaxHeight[] = + {'m','a','x','-','h','e','i','g','h','t',0}; +static const WCHAR attrMaxWidth[] = + {'m','a','x','-','w','i','d','t','h',0}; static const WCHAR attrMinHeight[] = {'m','i','n','-','h','e','i','g','h','t',0}; static const WCHAR attrMinWidth[] = @@ -264,6 +268,8 @@ {attrMarginLeft, DISPID_IHTMLSTYLE_MARGINLEFT}, {attrMarginRight, DISPID_IHTMLSTYLE_MARGINRIGHT}, {attrMarginTop, DISPID_IHTMLSTYLE_MARGINTOP}, + {attrMaxHeight, DISPID_IHTMLSTYLE5_MAXHEIGHT}, + {attrMaxWidth, DISPID_IHTMLSTYLE5_MAXWIDTH}, {attrMinHeight, DISPID_IHTMLSTYLE4_MINHEIGHT}, {attrMinWidth, DISPID_IHTMLSTYLE5_MINWIDTH}, {attrOutline, DISPID_IHTMLSTYLE6_OUTLINE}, diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlstyle.h wine1.7-1.7.31/dlls/mshtml/htmlstyle.h --- wine1.7-1.7.28/dlls/mshtml/htmlstyle.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlstyle.h 2014-11-14 13:28:17.000000000 +0000 @@ -87,6 +87,8 @@ STYLEID_MARGIN_LEFT, STYLEID_MARGIN_RIGHT, STYLEID_MARGIN_TOP, + STYLEID_MAX_HEIGHT, + STYLEID_MAX_WIDTH, STYLEID_MIN_HEIGHT, STYLEID_MIN_WIDTH, STYLEID_OUTLINE, diff -Nru wine1.7-1.7.28/dlls/mshtml/htmlstylesheet.c wine1.7-1.7.31/dlls/mshtml/htmlstylesheet.c --- wine1.7-1.7.28/dlls/mshtml/htmlstylesheet.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmlstylesheet.c 2014-11-14 13:28:17.000000000 +0000 @@ -649,11 +649,11 @@ TRACE("(%p)->(%p)\n", This, p); - /* Gecko has buggy security checks and GetCssRules will fail. We have a correct - * implementation and it will work when the bug will be fixed in Gecko. */ nsres = nsIDOMCSSStyleSheet_GetCssRules(This->nsstylesheet, &nslist); - if(NS_FAILED(nsres)) - WARN("GetCssRules failed: %08x\n", nsres); + if(NS_FAILED(nsres)) { + ERR("GetCssRules failed: %08x\n", nsres); + return E_FAIL; + } *p = HTMLStyleSheetRulesCollection_Create(nslist); return S_OK; diff -Nru wine1.7-1.7.28/dlls/mshtml/htmltable.c wine1.7-1.7.31/dlls/mshtml/htmltable.c --- wine1.7-1.7.28/dlls/mshtml/htmltable.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmltable.c 2014-11-14 13:28:17.000000000 +0000 @@ -288,15 +288,37 @@ static HRESULT WINAPI HTMLTable_put_cellPadding(IHTMLTable *iface, VARIANT v) { HTMLTable *This = impl_from_IHTMLTable(iface); - FIXME("(%p)->(%s)\n", This, debugstr_variant(&v)); - return E_NOTIMPL; + nsAString val; + HRESULT hres; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); + + hres = var2str(&v, &val); + if(FAILED(hres)) + return hres; + + nsres = nsIDOMHTMLTableElement_SetCellPadding(This->nstable, &val); + nsAString_Finish(&val); + if(NS_FAILED(nsres)) { + ERR("Set Width(%s) failed, err = %08x\n", debugstr_variant(&v), nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLTable_get_cellPadding(IHTMLTable *iface, VARIANT *p) { HTMLTable *This = impl_from_IHTMLTable(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsAString val; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, p); + + nsAString_Init(&val, NULL); + nsres = nsIDOMHTMLTableElement_GetCellPadding(This->nstable, &val); + return return_nsstr_variant(nsres, &val, p); } static HRESULT WINAPI HTMLTable_put_background(IHTMLTable *iface, BSTR v) diff -Nru wine1.7-1.7.28/dlls/mshtml/htmltextarea.c wine1.7-1.7.31/dlls/mshtml/htmltextarea.c --- wine1.7-1.7.28/dlls/mshtml/htmltextarea.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/htmltextarea.c 2014-11-14 13:28:17.000000000 +0000 @@ -196,8 +196,34 @@ static HRESULT WINAPI HTMLTextAreaElement_get_form(IHTMLTextAreaElement *iface, IHTMLFormElement **p) { HTMLTextAreaElement *This = impl_from_IHTMLTextAreaElement(iface); - FIXME("(%p)->(%p)\n", This, p); - return E_NOTIMPL; + nsIDOMHTMLFormElement *nsform; + nsIDOMNode *nsnode; + HTMLDOMNode *node; + nsresult nsres; + HRESULT hres; + + TRACE("(%p)->(%p)\n", This, p); + + nsres = nsIDOMHTMLTextAreaElement_GetForm(This->nstextarea, &nsform); + assert(nsres == NS_OK); + + if(!nsform) { + *p = NULL; + return S_OK; + } + + nsres = nsIDOMHTMLFormElement_QueryInterface(nsform, &IID_nsIDOMNode, (void**)&nsnode); + nsIDOMHTMLFormElement_Release(nsform); + assert(nsres == NS_OK); + + hres = get_node(This->element.node.doc, nsnode, TRUE, &node); + nsIDOMNode_Release(nsnode); + if(FAILED(hres)) + return hres; + + hres = IHTMLDOMNode_QueryInterface(&node->IHTMLDOMNode_iface, &IID_IHTMLFormElement, (void**)p); + IHTMLDOMNode_Release(&node->IHTMLDOMNode_iface); + return hres; } static HRESULT WINAPI HTMLTextAreaElement_put_defaultValue(IHTMLTextAreaElement *iface, BSTR v) diff -Nru wine1.7-1.7.28/dlls/mshtml/main.c wine1.7-1.7.31/dlls/mshtml/main.c --- wine1.7-1.7.28/dlls/mshtml/main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/main.c 2014-11-14 13:28:17.000000000 +0000 @@ -35,6 +35,7 @@ #include "optary.h" #include "rpcproxy.h" #include "shlguid.h" +#include "mlang.h" #include "wine/debug.h" @@ -50,6 +51,35 @@ static HINSTANCE shdoclc = NULL; static HDC display_dc; static WCHAR *status_strings[IDS_STATUS_LAST-IDS_STATUS_FIRST+1]; +static IMultiLanguage2 *mlang; + +UINT cp_from_charset_string(BSTR charset) +{ + MIMECSETINFO info; + HRESULT hres; + + if(!mlang) { + IMultiLanguage2 *new_mlang; + + hres = CoCreateInstance(&CLSID_CMultiLanguage, NULL, CLSCTX_INPROC_SERVER, + &IID_IMultiLanguage2, (void**)&new_mlang); + if(FAILED(hres)) { + ERR("Could not create CMultiLanguage instance\n"); + return CP_UTF8; + } + + if(InterlockedCompareExchangePointer((void**)&mlang, new_mlang, NULL)) + IMultiLanguage2_Release(new_mlang); + } + + hres = IMultiLanguage2_GetCharsetInfo(mlang, charset, &info); + if(FAILED(hres)) { + FIXME("GetCharsetInfo failed: %08x\n", hres); + return CP_UTF8; + } + + return info.uiInternetEncoding; +} static void thread_detach(void) { @@ -83,6 +113,8 @@ TlsFree(mshtml_tls); if(display_dc) DeleteObject(display_dc); + if(mlang) + IMultiLanguage2_Release(mlang); free_strings(); } diff -Nru wine1.7-1.7.28/dlls/mshtml/Makefile.in wine1.7-1.7.31/dlls/mshtml/Makefile.in --- wine1.7-1.7.28/dlls/mshtml/Makefile.in 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -15,7 +15,6 @@ htmlcurstyle.c \ htmldoc.c \ htmlelem.c \ - htmlelem2.c \ htmlelem3.c \ htmlelemcol.c \ htmlembed.c \ diff -Nru wine1.7-1.7.28/dlls/mshtml/mshtml_private.h wine1.7-1.7.31/dlls/mshtml/mshtml_private.h --- wine1.7-1.7.28/dlls/mshtml/mshtml_private.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/mshtml_private.h 2014-11-14 13:28:17.000000000 +0000 @@ -174,6 +174,7 @@ XIID(IHTMLScreen) \ XIID(IHTMLScriptElement) \ XIID(IHTMLSelectElement) \ + XIID(IHTMLSelectionObject) \ XIID(IHTMLStorage) \ XIID(IHTMLStyle) \ XIID(IHTMLStyle2) \ @@ -193,6 +194,7 @@ XIID(IHTMLTextAreaElement) \ XIID(IHTMLTextContainer) \ XIID(IHTMLTitleElement) \ + XIID(IHTMLTxtRange) \ XIID(IHTMLUniqueName) \ XIID(IHTMLWindow2) \ XIID(IHTMLWindow3) \ @@ -244,28 +246,29 @@ }; typedef struct { - void *x; + UINT_PTR x; } nsCycleCollectingAutoRefCnt; typedef struct { - void *x[9]; -} nsXPCOMCycleCollectionParticipant; + void *vtbl; + int ref_flags; + void *callbacks; +} ExternalCycleCollectionParticipant; typedef struct nsCycleCollectionTraversalCallback nsCycleCollectionTraversalCallback; typedef struct { - void (NSAPI *unmark_if_purple)(void*); nsresult (NSAPI *traverse)(void*,void*,nsCycleCollectionTraversalCallback*); nsresult (NSAPI *unlink)(void*); + void (NSAPI *delete_cycle_collectable)(void*); } CCObjCallback; DEFINE_GUID(IID_nsXPCOMCycleCollectionParticipant, 0x9674489b,0x1f6f,0x4550,0xa7,0x30, 0xcc,0xae,0xdd,0x10,0x4c,0xf9); nsrefcnt (__cdecl *ccref_incr)(nsCycleCollectingAutoRefCnt*,nsISupports*); -nsrefcnt (__cdecl *ccref_decr)(nsCycleCollectingAutoRefCnt*,nsISupports*); +nsrefcnt (__cdecl *ccref_decr)(nsCycleCollectingAutoRefCnt*,nsISupports*,ExternalCycleCollectionParticipant*); void (__cdecl *ccref_init)(nsCycleCollectingAutoRefCnt*,nsrefcnt); -void (__cdecl *ccref_unmark_if_purple)(nsCycleCollectingAutoRefCnt*); -void (__cdecl *ccp_init)(nsXPCOMCycleCollectionParticipant*,const CCObjCallback*); +void (__cdecl *ccp_init)(ExternalCycleCollectionParticipant*,const CCObjCallback*); void (__cdecl *describe_cc_node)(nsCycleCollectingAutoRefCnt*,const char*,nsCycleCollectionTraversalCallback*); void (__cdecl *note_cc_edge)(nsISupports*,const char*,nsCycleCollectionTraversalCallback*); @@ -729,7 +732,6 @@ HTMLInnerWindow *window; nsIDOMHTMLDocument *nsdoc; - nsIDOMNodeSelector *nsnode_selector; BOOL content_ready; event_target_t *body_event_target; @@ -833,8 +835,15 @@ void nsAString_InitDepend(nsAString*,const PRUnichar*) DECLSPEC_HIDDEN; UINT32 nsAString_GetData(const nsAString*,const PRUnichar**) DECLSPEC_HIDDEN; void nsAString_Finish(nsAString*) DECLSPEC_HIDDEN; + HRESULT return_nsstr(nsresult,nsAString*,BSTR*) DECLSPEC_HIDDEN; +static inline HRESULT return_nsstr_variant(nsresult nsres, nsAString *nsstr, VARIANT *p) +{ + V_VT(p) = VT_BSTR; + return return_nsstr(nsres, nsstr, &V_BSTR(p)); +} + nsICommandParams *create_nscommand_params(void) DECLSPEC_HIDDEN; HRESULT nsnode_to_nsstring(nsIDOMNode*,nsAString*) DECLSPEC_HIDDEN; void get_editor_controller(NSContainer*) DECLSPEC_HIDDEN; @@ -851,6 +860,7 @@ void call_docview_84(HTMLDocumentObj*) DECLSPEC_HIDDEN; void set_ready_state(HTMLOuterWindow*,READYSTATE) DECLSPEC_HIDDEN; +HRESULT get_readystate_string(READYSTATE,BSTR*) DECLSPEC_HIDDEN; HRESULT HTMLSelectionObject_Create(HTMLDocumentNode*,nsISelection*,IHTMLSelectionObject**) DECLSPEC_HIDDEN; HRESULT HTMLTxtRange_Create(HTMLDocumentNode*,nsIDOMRange*,IHTMLTxtRange**) DECLSPEC_HIDDEN; @@ -929,7 +939,6 @@ void HTMLDOMNode_Init(HTMLDocumentNode*,HTMLDOMNode*,nsIDOMNode*) DECLSPEC_HIDDEN; void HTMLElement_Init(HTMLElement*,HTMLDocumentNode*,nsIDOMHTMLElement*,dispex_static_data_t*) DECLSPEC_HIDDEN; -void HTMLElement2_Init(HTMLElement*) DECLSPEC_HIDDEN; void HTMLElement3_Init(HTMLElement*) DECLSPEC_HIDDEN; void HTMLTextContainer_Init(HTMLTextContainer*,HTMLDocumentNode*,nsIDOMHTMLElement*,dispex_static_data_t*) DECLSPEC_HIDDEN; void HTMLFrameBase_Init(HTMLFrameBase*,HTMLDocumentNode*,nsIDOMHTMLElement*,dispex_static_data_t*) DECLSPEC_HIDDEN; @@ -1194,6 +1203,7 @@ heap_free(ref); } +UINT cp_from_charset_string(BSTR) DECLSPEC_HIDDEN; HDC get_display_dc(void) DECLSPEC_HIDDEN; HINSTANCE get_shdoclc(void) DECLSPEC_HIDDEN; void set_statustext(HTMLDocumentObj*,INT,LPCWSTR) DECLSPEC_HIDDEN; diff -Nru wine1.7-1.7.28/dlls/mshtml/mutation.c wine1.7-1.7.31/dlls/mshtml/mutation.c --- wine1.7-1.7.28/dlls/mshtml/mutation.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/mutation.c 2014-11-14 13:28:17.000000000 +0000 @@ -592,12 +592,12 @@ } static void NSAPI nsDocumentObserver_ContentStatesChanged(nsIDocumentObserver *iface, nsIDocument *aDocument, - nsIContent *aContent, nsEventStates *aStateMask) + nsIContent *aContent, EventStates aStateMask) { } static void NSAPI nsDocumentObserver_DocumentStatesChanged(nsIDocumentObserver *iface, nsIDocument *aDocument, - nsEventStates *aStateMask) + EventStates aStateMask) { } diff -Nru wine1.7-1.7.28/dlls/mshtml/navigate.c wine1.7-1.7.31/dlls/mshtml/navigate.c --- wine1.7-1.7.28/dlls/mshtml/navigate.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/navigate.c 2014-11-14 13:28:17.000000000 +0000 @@ -52,12 +52,6 @@ static const WCHAR emptyW[] = {0}; static const WCHAR text_htmlW[] = {'t','e','x','t','/','h','t','m','l',0}; -enum { - BOM_NONE, - BOM_UTF8, - BOM_UTF16 -}; - struct nsProtocolStream { nsIInputStream nsIInputStream_iface; @@ -67,17 +61,6 @@ DWORD buf_size; }; -struct BSCallbackVtbl { - void (*destroy)(BSCallback*); - HRESULT (*init_bindinfo)(BSCallback*); - HRESULT (*start_binding)(BSCallback*); - HRESULT (*stop_binding)(BSCallback*,HRESULT); - HRESULT (*read_data)(BSCallback*,IStream*); - HRESULT (*on_progress)(BSCallback*,ULONG,LPCWSTR); - HRESULT (*on_response)(BSCallback*,DWORD,LPCWSTR); - HRESULT (*beginning_transaction)(BSCallback*,WCHAR**); -}; - static inline nsProtocolStream *impl_from_nsIInputStream(nsIInputStream *iface) { return CONTAINING_RECORD(iface, nsProtocolStream, nsIInputStream_iface); @@ -620,7 +603,7 @@ BSCServiceProvider_QueryService }; -static void init_bscallback(BSCallback *This, const BSCallbackVtbl *vtbl, IMoniker *mon, DWORD bindf) +void init_bscallback(BSCallback *This, const BSCallbackVtbl *vtbl, IMoniker *mon, DWORD bindf) { This->IBindStatusCallback_iface.lpVtbl = &BindStatusCallbackVtbl; This->IServiceProvider_iface.lpVtbl = &ServiceProviderVtbl; @@ -638,7 +621,7 @@ This->mon = mon; } -static HRESULT read_stream(BSCallback *This, IStream *stream, void *buf, DWORD size, DWORD *ret_size) +HRESULT read_stream(BSCallback *This, IStream *stream, void *buf, DWORD size, DWORD *ret_size) { DWORD read_size = 0, skip=0; BYTE *data = buf; @@ -818,7 +801,7 @@ } if(FAILED(hres)) { - bscallback->vtbl->stop_binding(bscallback, hres); + bscallback->window = NULL; return hres; } @@ -826,7 +809,7 @@ IBindCtx_Release(bctx); if(FAILED(hres)) { WARN("BindToStorage failed: %08x\n", hres); - bscallback->vtbl->stop_binding(bscallback, hres); + bscallback->window = NULL; return hres; } @@ -836,173 +819,6 @@ return S_OK; } -typedef struct { - BSCallback bsc; - - DWORD size; - char *buf; - HRESULT hres; -} BufferBSC; - -static inline BufferBSC *BufferBSC_from_BSCallback(BSCallback *iface) -{ - return CONTAINING_RECORD(iface, BufferBSC, bsc); -} - -static void BufferBSC_destroy(BSCallback *bsc) -{ - BufferBSC *This = BufferBSC_from_BSCallback(bsc); - - heap_free(This->buf); - heap_free(This); -} - -static HRESULT BufferBSC_init_bindinfo(BSCallback *bsc) -{ - return S_OK; -} - -static HRESULT BufferBSC_start_binding(BSCallback *bsc) -{ - return S_OK; -} - -static HRESULT BufferBSC_stop_binding(BSCallback *bsc, HRESULT result) -{ - BufferBSC *This = BufferBSC_from_BSCallback(bsc); - - This->hres = result; - - if(FAILED(result)) { - heap_free(This->buf); - This->buf = NULL; - This->size = 0; - } - - return S_OK; -} - -static HRESULT BufferBSC_read_data(BSCallback *bsc, IStream *stream) -{ - BufferBSC *This = BufferBSC_from_BSCallback(bsc); - DWORD readed; - HRESULT hres; - - if(!This->buf) { - This->buf = heap_alloc(128); - if(!This->buf) - return E_OUTOFMEMORY; - This->size = 128; - } - - do { - if(This->bsc.readed >= This->size) { - This->size <<= 1; - This->buf = heap_realloc(This->buf, This->size); - } - - hres = read_stream(&This->bsc, stream, This->buf+This->bsc.readed, This->size-This->bsc.readed, &readed); - }while(hres == S_OK); - - return S_OK; -} - -static HRESULT BufferBSC_on_progress(BSCallback *bsc, ULONG status_code, LPCWSTR status_text) -{ - return S_OK; -} - -static HRESULT BufferBSC_on_response(BSCallback *bsc, DWORD response_code, - LPCWSTR response_headers) -{ - return S_OK; -} - -static HRESULT BufferBSC_beginning_transaction(BSCallback *bsc, WCHAR **additional_headers) -{ - return S_FALSE; -} - -static const BSCallbackVtbl BufferBSCVtbl = { - BufferBSC_destroy, - BufferBSC_init_bindinfo, - BufferBSC_start_binding, - BufferBSC_stop_binding, - BufferBSC_read_data, - BufferBSC_on_progress, - BufferBSC_on_response, - BufferBSC_beginning_transaction -}; - - -HRESULT bind_mon_to_wstr(HTMLInnerWindow *window, IMoniker *mon, WCHAR **ret) -{ - BufferBSC *bsc; - WCHAR *text; - HRESULT hres; - - bsc = heap_alloc_zero(sizeof(*bsc)); - if(!bsc) - return E_OUTOFMEMORY; - - init_bscallback(&bsc->bsc, &BufferBSCVtbl, mon, 0); - bsc->hres = E_FAIL; - - hres = start_binding(window, &bsc->bsc, NULL); - if(SUCCEEDED(hres)) - hres = bsc->hres; - if(FAILED(hres)) { - IBindStatusCallback_Release(&bsc->bsc.IBindStatusCallback_iface); - return hres; - } - - if(!bsc->bsc.readed) { - *ret = NULL; - return S_OK; - } - - switch(bsc->bsc.bom) { - case BOM_UTF16: - if(bsc->bsc.readed % sizeof(WCHAR)) { - FIXME("The buffer is not a valid utf16 string\n"); - hres = E_FAIL; - break; - } - - text = heap_alloc(bsc->bsc.readed+sizeof(WCHAR)); - if(!text) { - hres = E_OUTOFMEMORY; - break; - } - - memcpy(text, bsc->buf, bsc->bsc.readed); - text[bsc->bsc.readed/sizeof(WCHAR)] = 0; - break; - - case BOM_UTF8: - default: { - DWORD len; - - len = MultiByteToWideChar(CP_UTF8, 0, bsc->buf, bsc->bsc.readed, NULL, 0); - text = heap_alloc((len+1)*sizeof(WCHAR)); - if(!text) { - hres = E_OUTOFMEMORY; - break; - } - - MultiByteToWideChar(CP_UTF8, 0, bsc->buf, bsc->bsc.readed, text, len); - text[len] = 0; - } - } - - IBindStatusCallback_Release(&bsc->bsc.IBindStatusCallback_iface); - if(FAILED(hres)) - return hres; - - *ret = text; - return S_OK; -} - static HRESULT read_post_data_stream(nsIInputStream *stream, BOOL contains_headers, struct list *headers_list, request_data_t *request_data) { @@ -1203,6 +1019,8 @@ break; case BOM_UTF16: This->nschannel->charset = heap_strdupA(UTF16_STR); + case BOM_NONE: + /* FIXME: Get charset from HTTP headers */; } if(!This->nschannel->content_type) { @@ -2146,7 +1964,7 @@ sprintfW(selector, selector_formatW, frag); nsAString_InitDepend(&selector_str, selector); /* NOTE: Gecko doesn't set result to NULL if there is no match, so nselem must be initialized */ - nsres = nsIDOMNodeSelector_QuerySelector(window->base.inner_window->doc->nsnode_selector, &selector_str, &nselem); + nsres = nsIDOMHTMLDocument_QuerySelector(window->base.inner_window->doc->nsdoc, &selector_str, &nselem); nsAString_Finish(&selector_str); heap_free(selector); if(NS_SUCCEEDED(nsres) && nselem) { diff -Nru wine1.7-1.7.28/dlls/mshtml/nsembed.c wine1.7-1.7.31/dlls/mshtml/nsembed.c --- wine1.7-1.7.28/dlls/mshtml/nsembed.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/nsembed.c 2014-11-14 13:28:17.000000000 +0000 @@ -527,7 +527,6 @@ NS_DLSYM(ccref_incr); NS_DLSYM(ccref_decr); NS_DLSYM(ccref_init); - NS_DLSYM(ccref_unmark_if_purple); NS_DLSYM(ccp_init); NS_DLSYM(describe_cc_node); NS_DLSYM(note_cc_edge); diff -Nru wine1.7-1.7.28/dlls/mshtml/nsiface.idl wine1.7-1.7.31/dlls/mshtml/nsiface.idl --- wine1.7-1.7.28/dlls/mshtml/nsiface.idl 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/nsiface.idl 2014-11-14 13:28:17.000000000 +0000 @@ -23,7 +23,7 @@ * compatible with XPCOM, usable in C code. */ -cpp_quote("#define GECKO_VERSION \"2.24\"") +cpp_quote("#define GECKO_VERSION \"2.34\"") cpp_quote("#define GECKO_VERSION_STRING \"Wine Gecko \" GECKO_VERSION") import "wtypes.idl"; @@ -31,6 +31,7 @@ cpp_quote("#ifdef WINE_NO_UNICODE_MACROS") cpp_quote("#undef GetForm") cpp_quote("#undef SetPort") +cpp_quote("#undef GetClassName") cpp_quote("#endif") typedef HRESULT nsresult; @@ -107,6 +108,7 @@ interface nsISelection; interface nsIDOMHTMLSelectElement; interface nsIFile; +interface nsIDocShell; interface IMoniker; @@ -151,7 +153,6 @@ typedef nsISupports nsIDocShellLoadInfo; typedef nsISupports nsISHEntry; typedef nsISupports nsIPresShell; -typedef nsISupports nsIContentViewer; typedef nsISupports nsIDocumentCharsetInfo; typedef nsISupports nsILayoutHistoryState; typedef nsISupports nsISecureBrowserUI; @@ -172,12 +173,8 @@ typedef nsISupports nsIDOMNodeIterator; typedef nsISupports nsIDOMTreeWalker; typedef nsISupports nsIHttpUpgradeListener; -typedef nsISupports nsIDOMDOMStringMap; -typedef nsISupports nsIDOMDOMStringList; typedef nsISupports nsIDOMOfflineResourceList; -typedef nsISupports nsIDOMHistory; typedef nsISupports nsIDOMNavigator; -typedef nsISupports nsIDOMMediaQueryList; typedef nsISupports nsIDOMScreen; typedef nsISupports nsIAnimationFrameListener; typedef nsISupports nsIDOMStorageList; @@ -196,6 +193,8 @@ typedef nsISupports nsIDOMCrypto; typedef nsISupports nsIDOMPkcs11; typedef nsISupports nsIDocShellTreeOwner; +typedef nsISupports nsIArray; +typedef nsISupports nsILoadInfo; typedef void *JSContext; typedef void *JSObject; @@ -523,7 +522,7 @@ [ object, - uuid(19501006-46e3-4634-b97d-26eff894b4d3), + uuid(afb57ac2-bce5-4ee3-bb34-385089a9ba5c), local ] interface nsILoadGroup : nsIRequest @@ -539,11 +538,13 @@ nsresult GetNotificationCallbacks(nsIInterfaceRequestor **aNotificationCallbacks); nsresult SetNotificationCallbacks(nsIInterfaceRequestor *aNotificationCallbacks); nsresult GetConnectionInfo(nsILoadGroupConnectionInfo **aConnectionInfo); + nsresult GetDefaultLoadFlags(nsLoadFlags *aDefaultLoadFlags); + nsresult SetDefaultLoadFlags(nsLoadFlags aDefaultLoadFlags); } [ object, - uuid(2a8a7237-c1e2-4de7-b669-2002af29e42d), + uuid(1bc48693-c45d-45f4-8ab1-46e323037fe1), local ] interface nsIChannel : nsIRequest @@ -555,7 +556,7 @@ const UINT LOAD_TARGETED = 1 << 20; const UINT LOAD_CALL_CONTENT_SNIFFERS = 1 << 21; const UINT LOAD_CLASSIFY_URI = 1 << 22; - const UINT LOAD_TREAT_APPLICATION_OCTET_STREAM_AS_UNKNOWN = 1 << 23; + const UINT LOAD_MEDIA_SNIFFER_OVERRIDES_CONTENT_TYPE = 1 << 23; const UINT LOAD_EXPLICIT_CREDENTIALS = 1 << 24; nsresult GetOriginalURI(nsIURI **aOriginalURI); @@ -579,6 +580,8 @@ nsresult GetContentDispositionFilename(nsAString *aContentDispositionFilename); nsresult SetContentDispositionFilename(const nsAString *aContentDispositionFilename); nsresult GetContentDispositionHeader(nsACString *aContentDispositionHeader); + nsresult GetLoadInfo(nsILoadInfo **aLoadInfo); + nsresult SetLoadInfo(nsILoadInfo *aLoadInfo); } [ @@ -593,7 +596,7 @@ [ object, - uuid(a01362a0-5c45-11e2-bcfd-0800200c9a66), + uuid(1bc753ad-5b88-454d-b4c0-4fd34cce6d96), local ] interface nsIHttpChannel : nsIChannel @@ -607,6 +610,8 @@ nsresult VisitRequestHeaders(nsIHttpHeaderVisitor *aVisitor); nsresult GetAllowPipelining(bool *aAllowPipelining); nsresult SetAllowPipelining(bool aAllowPipelining); + nsresult GetAllowSTS(bool *aAllowSTS); + nsresult SetAllowSTS(bool aAllowSTS); nsresult GetRedirectionLimit(uint32_t *aRedirectionLimit); nsresult SetRedirectionLimit(uint32_t aRedirectionLimit); nsresult GetResponseStatus(uint32_t *aResponseStatus); @@ -622,7 +627,7 @@ [ object, - uuid(2cd7f6a6-63f3-4bd6-a0f5-6e3d6dcff81b), + uuid(a4bf4fc5-b5a9-4098-bd20-409d71bf18e6), local ] interface nsIHttpChannelInternal : nsISupports @@ -631,6 +636,7 @@ nsresult SetDocumentURI(nsIURI *aDocumentURI); nsresult GetRequestVersion(uint32_t *major, uint32_t *minor); nsresult GetResponseVersion(uint32_t *major, uint32_t *minor); + nsresult TakeAllSecurityMessages(void /*securityMessagesArray*/ *aMessages); nsresult SetCookie(const char *aCookieHeader); nsresult SetupFallbackChannel(const char *aFallbackKey); nsresult GetForceAllowThirdPartyCookie(bool *aForceAllowThirdPartyCookie); @@ -650,6 +656,11 @@ nsresult SetLoadAsBlocking(bool aLoadAsBlocking); nsresult GetLoadUnblocked(bool *aLoadUnblocked); nsresult SetLoadUnblocked(bool aLoadUnblocked); + nsresult GetResponseTimeoutEnabled(bool *aResponseTimeoutEnabled); + nsresult SetResponseTimeoutEnabled(bool aResponseTimeoutEnabled); + nsresult GetApiRedirectToURI(nsIURI * *aApiRedirectToURI); + nsresult AddRedirect(nsIPrincipal *aPrincipal); + nsresult GetLastModifiedTime(PRTime *aLastModifiedTime); } [ @@ -722,7 +733,7 @@ [ object, - uuid(2938307a-9d70-4b63-8afc-0197e82318ad), + uuid(4d6b3bad-f53c-4585-82f6-62982e27ede8), local ] interface nsIDOMCSSRule : nsISupports @@ -732,6 +743,7 @@ nsresult SetCssText(const nsAString *aCssText); nsresult GetParentStyleSheet(nsIDOMCSSStyleSheet **aParentStyleSheet); nsresult GetParentRule(nsIDOMCSSRule **aParentRule); + int /* thiscall mozilla::css::Rule */ GetCSSRule(); } [ @@ -797,7 +809,7 @@ [ object, - uuid(a6cf9081-15b3-11d2-932e-00805f8add32), + uuid(0e424250-ac2a-4fe2-bccd-a45824af090e), local ] interface nsIDOMStyleSheetList : nsISupports @@ -948,12 +960,16 @@ [ object, - uuid(43d985da-b7ee-4d1f-a26f-348ccd9506f3), + uuid(d7de6065-1776-4f52-a776-4bbeabacbdaf), local ] interface nsIDOMElement : nsIDOMNode { nsresult GetTagName(nsAString *aTagName); + nsresult GetId(nsAString *aId); + nsresult SetId(const nsAString *aId); + nsresult GetClassName(nsAString *aClassName); + nsresult SetClassName(const nsAString *aClassName) ; nsresult GetClassList(nsISupports **aClassList); nsresult GetAttributes(nsIDOMMozNamedAttrMap **aAttributes); nsresult GetAttribute(const nsAString *name, nsAString *_retval); @@ -979,10 +995,6 @@ nsresult GetNextElementSibling(nsIDOMElement **aNextElementSibling); nsresult GetChildElementCount(uint32_t *aChildElementCount); nsresult Remove(); - nsresult GetOnmouseenter(JSContext *cx, jsval *aOnmouseenter); - nsresult SetOnmouseenter(JSContext *cx, const jsval *aOnmouseenter); - nsresult GetOnmouseleave(JSContext *cx, jsval *aOnmouseleave); - nsresult SetOnmouseleave(JSContext *cx, const jsval *aOnmouseleave); nsresult GetClientRects(nsIDOMClientRectList **_retval); nsresult GetBoundingClientRect(nsIDOMClientRect **_retval); nsresult GetScrollTop(int32_t *aScrollTop); @@ -1002,6 +1014,8 @@ nsresult ReleaseCapture(); nsresult MozRequestFullScreen(); nsresult MozRequestPointerLock(); + nsresult QuerySelector(const nsAString *selectors, nsIDOMElement **_retval); + nsresult QuerySelectorAll(const nsAString *selectors, nsIDOMNodeList **_retval); } [ @@ -1014,25 +1028,19 @@ nsresult GetStyle(nsIDOMCSSStyleDeclaration **aStyle); } -cpp_quote("#undef GetClassName") - [ object, - uuid(e29ddc73-ac40-40fe-8bbd-14bf2d52c53a), + uuid(db3352cf-04f3-4e7e-baa0-cd2f81b46328), local ] interface nsIDOMHTMLElement : nsIDOMElement { - nsresult GetId(nsAString *aId); - nsresult SetId(const nsAString *aId); nsresult GetTitle(nsAString *aTitle); nsresult SetTitle(const nsAString *aTitle); nsresult GetLang(nsAString *aLang); nsresult SetLang(const nsAString *aLang); nsresult GetDir(nsAString *aDir); nsresult SetDir(const nsAString *aDir); - nsresult GetClassName(nsAString *aClassName); - nsresult SetClassName(const nsAString *aClassName); nsresult GetDataset(nsISupports **aDataset); nsresult GetItemScope(bool *aItemScope); nsresult SetItemScope(bool aItemScope); @@ -1080,10 +1088,10 @@ [ object, - uuid(889602bb-4681-4b01-8582-4fad1fbb8325), + uuid(59b80014-00f5-412d-846f-725494122d42), local ] -interface nsIDOMHTMLHeadElement : nsIDOMHTMLElement +interface nsIDOMHTMLHeadElement : nsISupports { } @@ -1127,16 +1135,18 @@ [ object, - uuid(33127aed-9d6a-4b0d-95aa-0529f51bcb9c), + uuid(75a237af-133e-40f0-8196-2a172867c41a), local ] interface nsIDOMDocumentFragment : nsIDOMNode { + nsresult QuerySelector(const nsAString *selectors, nsIDOMElement **_retval); + nsresult QuerySelectorAll(const nsAString *selectors, nsIDOMNodeList **_retval); } [ object, - uuid(75996de6-6b0f-43e5-ae79-c98fa669da9a), + uuid(d24d1118-a527-4d5a-9c4e-fb07dfc2fc27), local ] interface nsIDOMDocument : nsIDOMNode @@ -1186,7 +1196,7 @@ nsresult GetSelectedStyleSheetSet(nsAString *aSelectedStyleSheetSet); nsresult SetSelectedStyleSheetSet(const nsAString *aSelectedStyleSheetSet); nsresult GetLastStyleSheetSet(nsAString *aLastStyleSheetSet); - nsresult GetStyleSheetSets(nsIDOMDOMStringList **aStyleSheetSets); + nsresult GetStyleSheetSets(nsISupports **aStyleSheetSets); nsresult EnableStyleSheetsForSet(const nsAString *name); nsresult ElementFromPoint(float x, float y, nsIDOMElement **_retval); nsresult GetContentType(nsAString *aContentType); @@ -1201,22 +1211,18 @@ nsresult GetMozPointerLockElement(nsIDOMElement **aMozPointerLockElement); nsresult CaretPositionFromPoint(float x, float y, nsISupports **_retval); nsresult MozExitPointerLock(); - nsresult GetOnreadystatechange(JSContext* cx, jsval aOnreadystatechange); - nsresult SetOnreadystatechange(JSContext* cx, const jsval *aOnreadystatechange); - nsresult GetOnmouseenter(JSContext* cx, jsval *aOnmouseenter); - nsresult SetOnmouseenter(JSContext* cx, const jsval *aOnmouseenter); - nsresult GetOnmouseleave(JSContext* cx, jsval *aOnmouseleave) = 0; - nsresult SetOnmouseleave(JSContext* cx, const jsval *aOnmouseleave); nsresult GetHidden(bool *aHidden); nsresult GetMozHidden(bool *aMozHidden); nsresult GetVisibilityState(nsAString *aVisibilityState); nsresult GetMozVisibilityState(nsAString *aMozVisibilityState); nsresult GetCompatMode(nsAString *aCompatMode); + nsresult QuerySelector(const nsAString *selectors, nsIDOMElement **_retval); + nsresult QuerySelectorAll(const nsAString *selectors, nsIDOMNodeList **_retval); } [ object, - uuid(fd76e045-8d97-4a97-ad75-eac5ae2f3ea4), + uuid(b73be9dd-bcc8-44df-8b01-3389e277427f), local ] interface nsIDOMHTMLDocument : nsIDOMDocument @@ -1263,9 +1269,8 @@ nsresult GetApplets(nsIDOMHTMLCollection **aApplets); nsresult Clear(); nsresult GetSelection(nsISelection **_retval); - nsresult CaptureEvents(int32_t eventFlags); - nsresult ReleaseEvents(int32_t eventFlags); - nsresult RouteEvent(nsIDOMEvent *evt); + nsresult CaptureEvents(); + nsresult ReleaseEvents(); } [ @@ -1316,7 +1321,7 @@ [ object, - uuid(12cf5a4d-fffb-4f2f-9cec-c65195661d76), + uuid(e0a4d4b3-f34e-44bd-b1f2-4e3bde9b6915), local ] interface nsISelection : nsISupports @@ -1341,7 +1346,6 @@ nsresult RemoveRange(nsIDOMRange *range); nsresult RemoveAllRanges(); nsresult DeleteFromDocument(); - nsresult SelectionLanguageChange(bool langRTL); nsresult ToString(nsAString *_retval); nsresult Modify(const nsAString *alter, const nsAString *direction, const nsAString *granularity); } @@ -1360,7 +1364,7 @@ [ object, - uuid(be62660a-e3f6-409c-a4a9-378364a9526f), + uuid(ed7cc4e4-cf5b-42af-9c2e-8df074a01470), local ] interface nsIDOMWindow : nsISupports @@ -1371,7 +1375,7 @@ nsresult GetName(nsAString *aName); nsresult SetName(const nsAString *aName); nsresult GetLocation(nsIDOMLocation **aLocation); - nsresult GetHistory(nsIDOMHistory **aHistory); + nsresult GetHistory(nsISupports **aHistory); nsresult GetLocationbar(nsISupports **aLocationbar); nsresult GetMenubar(nsISupports **aMenubar); nsresult GetPersonalbar(nsISupports **aPersonalbar); @@ -1389,8 +1393,10 @@ nsresult GetRealTop(nsIDOMWindow **aTop); nsresult GetScriptableParent(nsIDOMWindow **aParent); nsresult GetRealParent(nsIDOMWindow **aParent); - nsresult GetOpener(nsIDOMWindow **aOpener); - nsresult SetOpener(nsIDOMWindow *aOpener); + nsresult GetScriptableOpener(JSContext* cx, int /* JS::MutableHandleValue */ aOpener); + nsresult SetScriptableOpener(JSContext* cx, int /* JS::HandleValue */ aOpener); + nsresult GetOpener(nsIDOMWindow **aOpenerWindow); + nsresult SetOpener(nsIDOMWindow *aOpenerWindow); nsresult GetScriptableFrameElement(nsIDOMElement **aFrameElement); nsresult GetRealFrameElement(nsIDOMElement **aFrameElement); nsresult GetNavigator(nsIDOMNavigator **aNavigator); @@ -1403,10 +1409,12 @@ nsresult PostMessageMoz(const long /*jsval*/ *message, const nsAString *targetOrigin, const /*JS::Value*/ void *transfer, JSContext *cx); nsresult Atob(const nsAString *aAsciiString, nsAString *_retval); nsresult Btoa(const nsAString *aBase64Data, nsAString *_retval); - nsresult GetSessionStorage(nsIDOMStorage **aSessionStorage); - nsresult GetLocalStorage(nsIDOMStorage **aLocalStorage); + nsresult GetSessionStorage(nsISupports **aSessionStorage); + nsresult GetLocalStorage(nsISupports **aLocalStorage); + nsresult GetIndexedDB(nsISupports **aIndexedDB); + nsresult GetMozIndexedDB(nsISupports **aMozIndexedDB); nsresult GetSelection(nsISelection **_retval); - nsresult MatchMedia(const nsAString *media_query_list, nsIDOMMediaQueryList **_retval); + nsresult MatchMedia(const nsAString *media_query_list, nsISupports **_retval); nsresult GetScreen(nsIDOMScreen **aScreen); nsresult GetInnerWidth(int32_t *aInnerWidth); nsresult SetInnerWidth(int32_t aInnerWidth); @@ -1440,7 +1448,6 @@ nsresult GetPrompter(nsIPrompt **aPrompter); nsresult GetClosed(bool *aClosed); nsresult GetCrypto(nsIDOMCrypto **aCrypto); - nsresult GetPkcs11(nsIDOMPkcs11 **aPkcs11); nsresult GetControllers(nsIControllers **aControllers); nsresult GetMozInnerScreenX(float *aMozInnerScreenX); nsresult GetMozInnerScreenY(float *aMozInnerScreenY); @@ -1459,7 +1466,7 @@ nsresult Open(const nsAString *url, const nsAString *name, const nsAString *options, nsIDOMWindow **_retval); nsresult OpenDialog(const nsAString *url, const nsAString *name, const nsAString *options, nsISupports *aExtraArgument, nsIDOMWindow **_retval); - nsresult UpdateCommands(const nsAString *action); + nsresult UpdateCommands(const nsAString *action, nsISelection *sel, int16_t reason); nsresult Find(const nsAString *str, bool caseSensitive, bool backwards, bool wrapAround, bool wholeWord, bool searchInFrames, bool showDialog, bool *_retval); nsresult GetMozPaintCount(uint64_t *aMozPaintCount); @@ -1477,6 +1484,8 @@ nsresult SetOnbeforeunload(JSContext *cx, const jsval *aOnbeforeunload); nsresult GetOnhashchange(JSContext *cx, jsval *aOnhashchange); nsresult SetOnhashchange(JSContext *cx, const jsval *aOnhashchange); + nsresult GetOnlanguagechange(JSContext *cx, jsval *aOnlanguagechange); + nsresult SetOnlanguagechange(JSContext *cx, const jsval *aOnlanguagechange); nsresult GetOnmessage(JSContext *cx, jsval *aOnmessage); nsresult SetOnmessage(JSContext *cx, const jsval *aOnmessage); nsresult GetOnoffline(JSContext *cx, jsval *aOnoffline); @@ -1507,14 +1516,16 @@ nsresult SetOnmouseenter(JSContext* cx, const jsval *aOnmouseenter); nsresult GetOnmouseleave(JSContext* cx, jsval *aOnmouseleave); nsresult SetOnmouseleave(JSContext* cx, const jsval *aOnmouseleave); + nsresult GetConsole(JSContext *cx, jsval *aConsole); + nsresult SetConsole(JSContext *cx, const jsval *aConsole); } [ object, - uuid(8b29a62f-b448-49f3-9242-241d5cf94ea9), + uuid(068630db-2c00-43dd-b167-495757a88236), local ] -interface nsIDOMHTMLBodyElement : nsIDOMHTMLElement +interface nsIDOMHTMLBodyElement : nsISupports { nsresult GetALink(nsAString *aALink); nsresult SetALink(const nsAString *aALink); @@ -1528,38 +1539,14 @@ nsresult SetText(const nsAString *aText); nsresult GetVLink(nsAString *aVLink); nsresult SetVLink(const nsAString *aVLink); - nsresult GetOnafterprint(JSContext *cx, jsval *aOnafterprint); - nsresult SetOnafterprint(JSContext *cx, const jsval *aOnafterprint); - nsresult GetOnbeforeprint(JSContext *cx, jsval *aOnbeforeprint); - nsresult SetOnbeforeprint(JSContext *cx, const jsval *aOnbeforeprint); - nsresult GetOnbeforeunload(JSContext *cx, jsval *aOnbeforeunload); - nsresult SetOnbeforeunload(JSContext *cx, const jsval *aOnbeforeunload); - nsresult GetOnhashchange(JSContext *cx, jsval *aOnhashchange); - nsresult SetOnhashchange(JSContext *cx, const jsval *aOnhashchange); - nsresult GetOnmessage(JSContext *cx, jsval *aOnmessage); - nsresult SetOnmessage(JSContext *cx, const jsval *aOnmessage); - nsresult GetOnoffline(JSContext *cx, jsval *aOnoffline); - nsresult SetOnoffline(JSContext *cx, const jsval *aOnoffline); - nsresult GetOnonline(JSContext *cx, jsval *aOnonline); - nsresult SetOnonline(JSContext *cx, const jsval *aOnonline); - nsresult GetOnpagehide(JSContext *cx, jsval *aOnpagehide); - nsresult SetOnpagehide(JSContext *cx, const jsval *aOnpagehide); - nsresult GetOnpageshow(JSContext *cx, jsval *aOnpageshow); - nsresult SetOnpageshow(JSContext *cx, const jsval *aOnpageshow); - nsresult GetOnpopstate(JSContext *cx, jsval *aOnpopstate); - nsresult SetOnpopstate(JSContext *cx, const jsval *aOnpopstate); - nsresult GetOnresize(JSContext *cx, jsval *aOnresize); - nsresult SetOnresize(JSContext *cx, const jsval *aOnresize); - nsresult GetOnunload(JSContext *cx, jsval *aOnunload); - nsresult SetOnunload(JSContext *cx, const jsval *aOnunload); } [ object, - uuid(5e49bff8-fb61-41e3-b6a9-2017865a6d74), + uuid(ad9b2ad0-9d29-43f6-b1a2-a1fd24627e6b), local ] -interface nsIDOMHTMLFormElement : nsIDOMHTMLElement +interface nsIDOMHTMLFormElement : nsISupports { nsresult GetAcceptCharset(nsAString *aAcceptCharset); nsresult SetAcceptCharset(const nsAString *aAcceptCharset); @@ -1589,10 +1576,10 @@ [ object, - uuid(d57537ed-39d0-46ea-8516-0ce0a5bfb805), + uuid(64aeda0b-e9b5-4868-a4f9-e4776e32e733), local ] -interface nsIDOMHTMLInputElement : nsIDOMHTMLElement +interface nsIDOMHTMLInputElement : nsISupports { nsresult GetAccept(nsAString *aAccept); nsresult SetAccept(const nsAString *aAccept); @@ -1689,10 +1676,10 @@ [ object, - uuid(09017cf4-0004-4c27-a340-7f5d2fe282e3), + uuid(c2b3e9ff-6b36-4158-ace3-05a9c5b8e1c1), local ] -interface nsIDOMHTMLOptionElement : nsIDOMHTMLElement +interface nsIDOMHTMLOptionElement : nsISupports { nsresult GetDisabled(bool *aDisabled); nsresult SetDisabled(bool aDisabled); @@ -1712,10 +1699,10 @@ [ object, - uuid(5564816e-2ab5-46ee-95a4-8f4688bdb449), + uuid(44b7a468-7dba-4f0c-9b4e-ee46dc0f26c7), local ] -interface nsIDOMHTMLButtonElement : nsIDOMHTMLElement +interface nsIDOMHTMLButtonElement : nsISupports { nsresult GetAutofocus(bool *aAutofocus); nsresult SetAutofocus(bool aAutofocus); @@ -1768,10 +1755,10 @@ [ object, - uuid(8af2123f-c83a-430a-a739-d103a8eaba52), + uuid(d8914a2d-3556-4b66-911c-a84c4394e7fa), local ] -interface nsIDOMHTMLSelectElement : nsIDOMHTMLElement +interface nsIDOMHTMLSelectElement : nsISupports { nsresult GetAutofocus(bool *aAutofocus); nsresult SetAutofocus(bool aAutofocus); @@ -1792,6 +1779,7 @@ nsresult NamedItem(const nsAString *name, nsIDOMNode **_retval); nsresult Add(nsIDOMHTMLElement *element, nsIVariant *before); nsresult select_Remove(int32_t index); + nsresult GetSelectedOptions(nsIDOMHTMLCollection **aSelectedOptions); nsresult GetSelectedIndex(int32_t *aSelectedIndex); nsresult SetSelectedIndex(int32_t aSelectedIndex); nsresult GetValue(nsAString *aValue); @@ -1807,10 +1795,10 @@ [ object, - uuid(b7e1b86f-c98e-4658-81ce-ac29962f854a), + uuid(7a4aeb2e-fcf3-443e-b002-ca1c8ea322e9), local ] -interface nsIDOMHTMLTextAreaElement : nsIDOMHTMLElement +interface nsIDOMHTMLTextAreaElement : nsISupports { nsresult GetAutofocus(bool *aAutofocus); nsresult SetAutofocus(bool aAutofocus); @@ -1857,10 +1845,10 @@ [ object, - uuid(8783371a-6185-4176-9ed9-f781c75bf48a), + uuid(4627336e-3070-4e73-8f67-3851b54cc0eb), local ] -interface nsIDOMHTMLScriptElement : nsIDOMHTMLElement +interface nsIDOMHTMLScriptElement : nsISupports { nsresult GetSrc(nsAString *aSrc); nsresult SetSrc(const nsAString *aSrc); @@ -1884,15 +1872,19 @@ [ object, - uuid(98c38ca0-5e3a-4c71-90a4-69d12a3c8d16), + uuid(e83e726a-0aef-4292-938b-253fec691e2f), local ] -interface nsIDOMHTMLImageElement : nsIDOMHTMLElement +interface nsIDOMHTMLImageElement : nsISupports { nsresult GetAlt(nsAString *aAlt); nsresult SetAlt(const nsAString *aAlt); nsresult GetSrc(nsAString *aSrc); nsresult SetSrc(const nsAString *aSrc); + nsresult GetSrcset(nsAString *aSrcset); + nsresult SetSrcset(const nsAString *aSrcset) ; + nsresult GetSizes(nsAString *aSizes); + nsresult SetSizes(const nsAString *aSizes); nsresult GetCrossOrigin(nsAString *aCrossOrigin); nsresult SetCrossOrigin(const nsAString *aCrossOrigin); nsresult GetUseMap(nsAString *aUseMap); @@ -1920,16 +1912,17 @@ nsresult SetVspace(int32_t aVspace); nsresult GetLowsrc(nsAString *aLowsrc); nsresult SetLowsrc(const nsAString *aLowsrc); + nsresult GetCurrentSrc(nsAString *aCurrentSrc); nsresult GetX(int32_t *aX); nsresult GetY(int32_t *aY); } [ object, - uuid(76ec122a-db6d-4b3f-8a24-15faf117f695), + uuid(339c01c8-2d41-4626-b231-eec63f0241b6), local ] -interface nsIDOMHTMLAnchorElement : nsIDOMHTMLElement +interface nsIDOMHTMLAnchorElement : nsISupports { nsresult GetHref(nsAString *aHref); nsresult SetHref(const nsAString *aHref); @@ -1976,10 +1969,10 @@ [ object, - uuid(ad43cb9b-3253-446d-8ba9-50ee50ff017e), + uuid(95d6ec66-2754-45bd-a068-49ac1fb45004), local ] -interface nsIDOMHTMLLinkElement : nsIDOMHTMLElement +interface nsIDOMHTMLLinkElement : nsISupports { nsresult GetDisabled(bool *aDisabled); nsresult SetDisabled(bool aDisabled); @@ -2005,17 +1998,17 @@ [ object, - uuid(1a7bf1f1-5d6c-4200-9ceb-455874322315), + uuid(135a30ee-0374-4ee7-9d36-91736bff5fb1), local ] -interface nsIDOMHTMLTableElement : nsIDOMHTMLElement +interface nsIDOMHTMLTableElement : nsISupports { nsresult GetCaption(nsIDOMHTMLTableCaptionElement **aCaption); nsresult SetCaption(nsIDOMHTMLTableCaptionElement *aCaption); - nsresult GetTHead(nsIDOMHTMLTableSectionElement **aTHead); - nsresult SetTHead(nsIDOMHTMLTableSectionElement *aTHead); - nsresult GetTFoot(nsIDOMHTMLTableSectionElement **aTFoot); - nsresult SetTFoot(nsIDOMHTMLTableSectionElement *aTFoot); + nsresult GetTHead(nsIDOMHTMLElement **aTHead); + nsresult SetTHead(nsIDOMHTMLElement *aTHead); + nsresult GetTFoot(nsIDOMHTMLElement **aTFoot); + nsresult SetTFoot(nsIDOMHTMLElement *aTFoot); nsresult GetRows(nsIDOMHTMLCollection **aRows); nsresult GetTBodies(nsIDOMHTMLCollection **aTBodies); nsresult GetAlign(nsAString *aAlign); @@ -2037,11 +2030,11 @@ nsresult GetWidth(nsAString *aWidth); nsresult SetWidth(const nsAString *aWidth); nsresult CreateTHead(nsIDOMHTMLElement **_retval); - nsresult DeleteTHead(); + nsresult xpidlDeleteTHead(); nsresult CreateTFoot(nsIDOMHTMLElement **_retval); - nsresult DeleteTFoot(); + nsresult xpidlDeleteTFoot(); nsresult CreateCaption(nsIDOMHTMLElement **_retval); - nsresult DeleteCaption(); + nsresult xpidlDeleteCaption(); nsresult InsertRow(int32_t index, nsIDOMHTMLElement **_retval); nsresult DeleteRow(int32_t index); } @@ -2051,7 +2044,7 @@ uuid(02094366-0d3d-47e3-949c-89113a9bcc15), local ] -interface nsIDOMHTMLTableRowElement : nsIDOMHTMLElement +interface nsIDOMHTMLTableRowElement : nsISupports { nsresult GetRowIndex(int32_t *aRowIndex); nsresult GetSectionRowIndex(int32_t *aSectionRowIndex); @@ -2066,16 +2059,16 @@ nsresult SetChOff(const nsAString *aChOff); nsresult GetVAlign(nsAString *aVAlign); nsresult SetVAlign(const nsAString *aVAlign); - nsresult InsertCell(int32_t index, nsIDOMHTMLElement **_retval); + nsresult InsertCell(int32_t index, nsIDOMHTMLElement * *_retval); nsresult DeleteCell(int32_t index); } [ object, - uuid(1fb22137-c231-4eae-9ca4-557bb0852d89), + uuid(3203c36f-33fd-4628-8c88-77e82d38df1e), local ] -interface nsIDOMHTMLTableCellElement : nsIDOMHTMLElement +interface nsIDOMHTMLTableCellElement : nsISupports { nsresult GetCellIndex(int32_t *aCellIndex); nsresult GetAbbr(nsAString *aAbbr); @@ -2110,10 +2103,10 @@ [ object, - uuid(21ffbe98-51f5-499e-8d6f-612ae798c1e1), + uuid(9fd7b656-1055-4cb2-b8b1-ed13efe24457), local ] -interface nsIDOMHTMLIFrameElement : nsIDOMHTMLElement +interface nsIDOMHTMLIFrameElement : nsISupports { nsresult GetAlign(nsAString *aAlign); nsresult SetAlign(const nsAString *aAlign); @@ -2133,22 +2126,22 @@ nsresult SetScrolling(const nsAString *aScrolling); nsresult GetSrc(nsAString *aSrc); nsresult SetSrc(const nsAString *aSrc); + nsresult GetSrcdoc(nsAString *aSrcdoc); + nsresult SetSrcdoc(const nsAString *aSrcdoc); nsresult GetWidth(nsAString *aWidth); nsresult SetWidth(const nsAString *aWidth); nsresult GetContentDocument(nsIDOMDocument **aContentDocument); nsresult GetContentWindow(nsIDOMWindow **aContentWindow); - nsresult GetSandbox(nsAString *aSandbox); - nsresult SetSandbox(const nsAString *aSandbox); nsresult GetAllowFullscreen(bool *aAllowFullscreen); nsresult SetAllowFullscreen(bool aAllowFullscreen); } [ object, - uuid(1a79af54-dbbb-4532-be48-944f3995e7e9), + uuid(60ab25b9-3246-4f50-b0d4-21e73ba88cd6), local ] -interface nsIDOMHTMLFrameElement : nsIDOMHTMLElement +interface nsIDOMHTMLFrameElement : nsISupports { nsresult GetFrameBorder(nsAString *aFrameBorder); nsresult SetFrameBorder(const nsAString *aFrameBorder); @@ -2172,10 +2165,10 @@ [ object, - uuid(bed8f222-c4dd-41ba-9ec6-dfae0ec8def8), + uuid(baf443d2-da5d-40c9-be3c-c65a69a25250), local ] -interface nsIDOMHTMLObjectElement : nsIDOMHTMLElement +interface nsIDOMHTMLObjectElement : nsISupports { nsresult GetForm(nsIDOMHTMLFormElement **aForm); nsresult GetCode(nsAString *aCode); @@ -2220,10 +2213,10 @@ [ object, - uuid(e81273e1-d440-4dd3-9073-8199f7a9525e), + uuid(fa326d22-8739-4eef-a80e-6449bde605d2), local ] -interface nsIDOMHTMLStyleElement : nsIDOMHTMLElement +interface nsIDOMHTMLStyleElement : nsISupports { nsresult GetDisabled(bool *aDisabled); nsresult SetDisabled(bool aDisabled); @@ -2238,17 +2231,6 @@ [ object, - uuid(7cebc153-168a-416c-ba5a-56a8c2ddb2ec), - local -] -interface nsIDOMNodeSelector : nsISupports -{ - nsresult QuerySelector(const nsAString *selectors, nsIDOMElement **_retval); - nsresult QuerySelectorAll(const nsAString *selectors, nsIDOMNodeList **_retval); -} - -[ - object, uuid(94928ab3-8b63-11d3-989d-001083010e9b), local ] @@ -2347,7 +2329,7 @@ [ object, - uuid(28404f7e-0f17-4dc3-a21a-2074d8659b02), + uuid(b7568a50-4c50-442c-a6be-3a340a48d89a), local ] interface nsIWebNavigation : nsISupports @@ -2369,7 +2351,6 @@ const UINT LOAD_FLAGS_BYPASS_CLASSIFIER = 0x10000; const UINT LOAD_FLAGS_FORCE_ALLOW_COOKIES = 0x20000; const UINT LOAD_FLAGS_DISALLOW_INHERIT_OWNER = 0x40000; - const UINT LOAD_FLAGS_URI_IS_UTF8 = 0x80000; nsresult GetCanGoBack(bool *aCanGoBack); nsresult GetCanGoForward(bool *aCanGoForward); @@ -2378,6 +2359,8 @@ nsresult GotoIndex(int32_t index); nsresult LoadURI(const PRUnichar *aURI, uint32_t aLoadFlags, nsIURI *aReferrer, nsIInputStream *aPostData, nsIInputStream *aHeaders); + nsresult LoadURIWithBase(const PRUnichar *aURI, uint32_t aLoadFlags, nsIURI *aReferrer, + nsIInputStream *aPostData, nsIInputStream *aHeaders, nsIURI *aBaseURI); nsresult Reload(uint32_t aReloadFlags); nsresult Stop(uint32_t aStopFlags); nsresult GetDocument(nsIDOMDocument **aDocument); @@ -2389,7 +2372,7 @@ [ object, - uuid(1c3437b0-9e2c-11e2-9e96-0800200c9a66), + uuid(bd0efb3b-1c81-4fb0-b16d-576a2be48a95), local ] interface nsIWebProgress : nsISupports @@ -2400,6 +2383,7 @@ nsresult GetDOMWindowID(uint64_t *aDOMWindowID); nsresult GetIsTopLevel(bool *aIsTopLevel); nsresult GetIsLoadingDocument(bool *aIsLoadingDocument); + nsresult GetLoadType(uint32_t *aLoadType); } [ @@ -2542,7 +2526,7 @@ nsresult SetupSilentPrinting(); nsresult SetUnwriteableMarginInTwips(nsIntMargin *aEdge); nsresult GetUnwriteableMarginInTwips(nsIntMargin *aEdge); - nsresult GetPageRanges(void * /*nsTArray&*/ aPages); + nsresult GetPageRanges(void * /*nsTArray*/ aPages); } [ @@ -2573,7 +2557,7 @@ [ object, - uuid(919e792a-6490-40b8-bba5-f9e9ad5640c8), + uuid(3507fc93-313e-4a4c-8ca8-4d0ea0f97315), local ] interface nsIScrollable : nsISupports @@ -2589,21 +2573,14 @@ Scrollbar_Always = 3 }; - nsresult GetCurScrollPos(int32_t scrollOrientation, int32_t *curPos); - nsresult SetCurScrollPos(int32_t scrollOrientation, int32_t curPos); - nsresult SetCurScrollPosEx(int32_t curHorizontalPos, int32_t curVerticalPos); - nsresult GetScrollRange(int32_t scrollOrientation, int32_t *minPos, int32_t *maxPos); - nsresult SetScrollRange(int32_t scrollOrientation, int32_t minPos, int32_t maxPos); - nsresult SetScrollRangeEx(int32_t minHorizontalPos, int32_t maxHorizontalPos, - int32_t minVerticalPos, int32_t maxVerticalPos); - nsresult GetDefaultScrollbarPreferences(int32_t scrollOrientation, int32_t *scrollbarPref); + nsresult GetDefaultScrollbarPreferences(int32_t scrollOrientation, int32_t *_retval); nsresult SetDefaultScrollbarPreferences(int32_t scrollOrientation, int32_t scrollbarPref); nsresult GetScrollbarVisibility(bool *verticalVisible, bool *horizontalVisible); } [ object, - uuid(272a5020-64f5-485c-a8c4-44b2882ae0a2), + uuid(dfb5a307-7ecf-41dd-aee2-f1d623459c44), local ] interface nsIFile : nsISupports @@ -2628,6 +2605,7 @@ nsresult CopyToFollowingLinksNative(nsIFile *newParentDir, const nsAString *newName); nsresult MoveTo(nsIFile *newParentDir, const nsAString *newName); nsresult MoveToNative(nsIFile *newParentDir, const nsAString *newName); + nsresult RenameTo(nsIFile *newParentDir, const nsAString *newName); nsresult Remove(bool recursive); nsresult GetPermissions(uint32_t *aPermissions); nsresult SetPermissions(uint32_t pPermissions); @@ -2656,7 +2634,7 @@ nsresult CreateUnique(uint32_t type, uint32_t permission); nsresult Clone(nsIFile **_retval); nsresult Equals(nsIFile *inFile, bool *_retval); - nsresult Contains(nsIFile *inFile, bool recir, bool *_retval); + nsresult Contains(nsIFile *inFile, bool *_retval); nsresult GetParent(nsIFile **aParent); nsresult GetDirectoryEntries(nsISimpleEnumerator **aDirectoryEntries); nsresult InitWithPath(const nsAString *filePath); @@ -2680,7 +2658,7 @@ [ object, - uuid(1d940426-5fe5-42c3-84ae-a300f2d9ebd5), + uuid(d604ffc3-1ba3-4f6c-b65f-1ed4199364c3), local ] interface nsIComponentManager : nsISupports @@ -2693,6 +2671,7 @@ nsIIDRef aIID, void **result); nsresult AddBootstrappedManifestLocation(nsIFile *aLocation); nsresult RemoveBootstrappedManifestLocation(nsIFile *aLocation); + nsresult GetManifestLocations(nsIArray **_retval); } [ @@ -2860,7 +2839,7 @@ [ object, - uuid(31e92e56-4d23-4a4a-9cfe-a6d12cf434bc), + uuid(9a78ac3c-9507-4d00-b2d6-10b508d2ec31), local ] interface nsIDOMEventTarget : nsISupports @@ -2910,7 +2889,7 @@ [ object, - uuid(cbe333d7-5b2c-4a9b-b99b-e6e388afa62b), + uuid(11911980-607c-4efd-aacc-de3b9005c058), local ] interface nsIDOMWindowUtils : nsISupports @@ -2923,21 +2902,38 @@ nsresult Redraw(uint32_t aCount, uint32_t *_retval); nsresult SetCSSViewport(float aWidthPx, float aHeightPx); nsresult GetViewportInfo(uint32_t aDisplayWidth, uint32_t aDisplayHeight, double *aDefaultZoom, bool *aAllowZoom, - double *aMinZoom, double *aMaxZoom, uint32_t *aWidth, uint32_t *aHeight, bool *aAutoSize); - nsresult SetDisplayPortForElement(float aXPx, float aYPx, float aWidthPx, float aHeightPx, nsIDOMElement *aElement); + double *aMinZoom, double *aMaxZoom, uint32_t *aWidth, uint32_t *aHeight, bool *aAutoSize); + nsresult SetDisplayPortForElement(float aXPx, float aYPx, float aWidthPx, float aHeightPx, + nsIDOMElement *aElement, uint32_t aPriority); + nsresult SetDisplayPortMarginsForElement(float aLeftMargin, float aTopMargin, float aRightMargin, float aBottomMargin, + uint32_t aAlignmentX, uint32_t aAlignmentY, nsIDOMElement *aElement, uint32_t aPriority); + nsresult SetDisplayPortBaseForElement(int32_t aX, int32_t aY, int32_t aWidth, int32_t aHeight, nsIDOMElement *aElement); nsresult SetCriticalDisplayPortForElement(float aXPx, float aYPx, float aWidthPx, float aHeightPx, nsIDOMElement *aElement); nsresult SetResolution(float aXResolution, float aYResolution); nsresult GetResolution(float *aXResolution, float *aYResolution); + nsresult GetIsResolutionSet(bool *aIsResolutionSet); nsresult GetIsFirstPaint(bool *aIsFirstPaint); nsresult SetIsFirstPaint(bool aIsFirstPaint); nsresult GetPresShellId(uint32_t *aPresShellId); nsresult SendMouseEvent(const nsAString *aType, float aX, float aY, int32_t aButton, int32_t aClickCount, - int32_t aModifiers, bool aIgnoreRootScrollFrame, float aPressure, uint16_t aInputSourceArg, bool *_retval); + int32_t aModifiers, bool aIgnoreRootScrollFrame, float aPressure, uint16_t aInputSourceArg, bool aIsSynthesized, + uint8_t _argc, bool *_retval); + nsresult SendPointerEvent(const nsAString *aType, float aX, float aY, int32_t aButton, int32_t aClickCount, + int32_t aModifiers, bool aIgnoreRootScrollFrame, float aPressure, uint16_t aInputSourceArg, int32_t aPointerId, + int32_t aWidth, int32_t aHeight, int32_t tiltX, int32_t tiltY, bool aIsPrimary, bool aIsSynthesized, + uint8_t _argc, bool *_retval); nsresult SendTouchEvent(const nsAString *aType, uint32_t *aIdentifiers, int32_t *aXs, int32_t *aYs, - uint32_t *aRxs, uint32_t *aRys, float *aRotationAngles, float *aForces, uint32_t count, int32_t aModifiers, - bool aIgnoreRootScrollFrame, bool *_retval); + uint32_t *aRxs, uint32_t *aRys, float *aRotationAngles, float *aForces, uint32_t count, int32_t aModifiers, + bool aIgnoreRootScrollFrame, bool *_retval); nsresult SendMouseEventToWindow(const nsAString *aType, float aX, float aY, int32_t aButton, int32_t aClickCount, - int32_t aModifiers, bool aIgnoreRootScrollFrame, float aPressure, uint16_t aInputSourceArg); + int32_t aModifiers, bool aIgnoreRootScrollFrame, float aPressure, uint16_t aInputSourceArg, bool aIsSynthesized, + uint8_t _argc); + nsresult SendPointerEventToWindow(const nsAString *aType, float aX, float aY, int32_t aButton, int32_t aClickCount, + int32_t aModifiers, bool aIgnoreRootScrollFrame, float aPressure, uint16_t aInputSourceArg, int32_t aPointerId, + int32_t aWidth, int32_t aHeight, int32_t aTiltX, int32_t aTiltY, bool aIsPrimary, bool aIsSynthesized, uint8_t _argc); + nsresult SendTouchEventToWindow(const nsAString *aType, uint32_t *aIdentifiers, int32_t *aXs, int32_t *aYs, uint32_t *aRxs, + uint32_t *aRys, float *aRotationAngles, float *aForces, uint32_t count, int32_t aModifiers, + bool aIgnoreRootScrollFrame, bool *_retval); nsresult SendWheelEvent(float aX, float aY, double aDeltaX, double aDeltaY, double aDeltaZ, uint32_t aDeltaMode, int32_t aModifiers, int32_t aLineOrPageDeltaX, int32_t aLineOrPageDeltaY, uint32_t aOptions); nsresult SendKeyEvent(const nsAString *aType, int32_t aKeyCode, int32_t aCharCode, int32_t aModifiers, @@ -2948,16 +2944,22 @@ nsIDOMElement *aElement); nsresult SendNativeMouseScrollEvent(int32_t aScreenX, int32_t aScreenY, uint32_t aNativeMessage, double aDeltaX, double aDeltaY, double aDeltaZ, uint32_t aModifierFlags, uint32_t aAdditionalFlags, nsIDOMElement *aElement); + nsresult SendNativeTouchPoint(uint32_t aPointerId, uint32_t aTouchState, int32_t aScreenX, int32_t aScreenY, + double aPressure, uint32_t aOrientation); + nsresult SendNativeTouchTap(int32_t aScreenX, int32_t aScreenY, bool aLongTap); + nsresult ClearNativeTouchSequence(); nsresult ActivateNativeMenuItemAt(const nsAString *indexString); nsresult ForceUpdateNativeMenuAt(const nsAString *indexString); nsresult Focus(nsIDOMElement *aElement); nsresult GarbageCollect(nsICycleCollectorListener *aListener, int32_t aExtraForgetSkippableCalls); nsresult CycleCollect(nsICycleCollectorListener *aListener, int32_t aExtraForgetSkippableCalls); + nsresult RunNextCollectorTimer(); nsresult SendSimpleGestureEvent(const nsAString *aType, float aX, float aY, uint32_t aDirection, double aDelta, int32_t aModifiers, uint32_t aClickCount); nsresult ElementFromPoint(float aX, float aY, bool aIgnoreRootScrollFrame, bool aFlushLayout, nsIDOMElement **_retval); nsresult NodesFromRect(float aX, float aY, float aTopSize, float aRightSize, float aBottomSize, float aLeftSize, bool aIgnoreRootScrollFrame, bool aFlushLayout, nsIDOMNodeList **_retval); + nsresult GetTranslationNodes(nsIDOMNode *aRoot, int /*nsITranslationNodeList*/ **_retval); nsresult CompareCanvases(nsIDOMHTMLCanvasElement *aCanvas1, nsIDOMHTMLCanvasElement *aCanvas2, uint32_t *aMaxDifference, uint32_t *_retval); nsresult GetIsMozAfterPaintPending(bool *aIsMozAfterPaintPending); @@ -2965,6 +2967,7 @@ nsresult ClearMozAfterPaintEvents(); nsresult DisableNonTestMouseEvents(bool aDisable); nsresult GetScrollXY(bool aFlushLayout, int32_t *aScrollX, int32_t *aScrollY); + nsresult GetScrollXYFloat(bool aFlushLayout, float *aScrollX, float *aScrollY); nsresult GetScrollbarSize(bool aFlushLayout, int32_t *aWidth, int32_t *aHeight); nsresult GetBoundsWithoutFlushing(nsIDOMElement *aElement, nsIDOMClientRect **_retval); nsresult GetRootBounds(nsIDOMClientRect **_retval); @@ -2977,15 +2980,13 @@ nsresult GetClassName(const /*JS::Value*/ void *aObject, JSContext *cx, char **_retval); nsresult SendContentCommandEvent(const nsAString *aType, nsITransferable *aTransferable); nsresult SendCompositionEvent(const nsAString *aType, const nsAString *aData, const nsAString *aLocale); - nsresult SendTextEvent(const nsAString *aCompositionString, int32_t aFirstClauseLength, uint32_t aFirstClauseAttr, - int32_t aSecondClauseLength, uint32_t aSecondClauseAttr, int32_t aThirdClauseLength, uint32_t aThirdClauseAttr, - int32_t aCaretStart, int32_t aCaretLength); + nsresult CreateCompositionStringSynthesizer(int /*nsICompositionStringSynthesizer*/ **_retval); nsresult SendQueryContentEvent(uint32_t aType, uint32_t aOffset, uint32_t aLength, int32_t aX, int32_t aY, - nsIQueryContentEventResult **_retval); + uint32_t aAdditionalFlags, nsIQueryContentEventResult **_retval); nsresult RemoteFrameFullscreenChanged(nsIDOMElement *aFrameElement, const nsAString *aNewOrigin); nsresult RemoteFrameFullscreenReverted(); nsresult ExitFullscreen(); - nsresult SendSelectionSetEvent(uint32_t aOffset, uint32_t aLength, bool aReverse, bool *_retval); + nsresult SendSelectionSetEvent(uint32_t aOffset, uint32_t aLength, uint32_t aAdditionalFlags, bool *_retval); nsresult SelectAtPoint(float aX, float aY, uint32_t aSelectBehavior, bool *_retval); nsresult GetVisitedDependentComputedStyle(nsIDOMElement *aElement, const nsAString *aPseudoElement, const nsAString *aPropertyName, nsAString *_retval); @@ -2994,38 +2995,35 @@ nsresult GetCurrentInnerWindowID(uint64_t *aCurrentInnerWindowID); nsresult EnterModalState(); nsresult LeaveModalState(); - nsresult EnterModalStateWithWindow(nsIDOMWindow **_retval); - nsresult LeaveModalStateWithWindow(nsIDOMWindow *aWindow); nsresult IsInModalState(bool *_retval); nsresult SuspendTimeouts(); nsresult ResumeTimeouts(); nsresult GetLayerManagerType(nsAString *aLayerManagerType); nsresult GetLayerManagerRemote(bool *aLayerManagerRemote); nsresult StartFrameTimeRecording(uint32_t *startIndex); - nsresult StopFrameTimeRecording(uint32_t startIndex, float **paintTimes, uint32_t *frameCount, float **frameIntervals); + nsresult StopFrameTimeRecording(uint32_t startIndex, uint32_t *frameCount, float **frameIntervals); nsresult BeginTabSwitch(); nsresult GetDisplayDPI(float *aDisplayDPI); nsresult GetOuterWindowWithId(uint64_t aOuterWindowID, nsIDOMWindow **_retval); + nsresult GetContainerElement(nsIDOMElement **aContainerElement); nsresult RenderDocument(const void /*nsRect*/ *aRect, uint32_t aFlags, int /*nscolor*/ aBackgroundColor, void /*gfxContext*/ *aThebesContext); nsresult AdvanceTimeAndRefresh(int64_t aMilliseconds); nsresult RestoreNormalRefresh(); nsresult GetIsTestControllingRefreshes(bool *aIsTestControllingRefreshes); + nsresult SetAsyncScrollOffset(nsIDOMNode *aNode, int32_t aX, int32_t aY); nsresult ComputeAnimationDistance(nsIDOMElement *element, const nsAString *property, const nsAString *value1, const nsAString *value2, double *_retval); nsresult WrapDOMFile(nsIFile *aFile, nsIDOMFile **_retval); nsresult GetFocusedInputType(char **aFocusedInputType); nsresult FindElementWithViewId(long /*nsViewID*/ aId, nsIDOMElement **_retval); + nsresult GetViewId(nsIDOMElement *aElement, long /*nsViewID*/ *_retval); nsresult LeafLayersPartitionWindow(bool *_retval); nsresult GetMayHaveTouchEventListeners(bool *aMayHaveTouchEventListeners); nsresult CheckAndClearPaintedState(nsIDOMElement *aElement, bool *_retval); - nsresult GetFile(const nsAString *aName, const /*JS::Value*/ void *aBlobParts, const /*JS::Value*/ void *aParameters, - JSContext* cx, uint8_t _argc, nsIDOMFile **_retval); - nsresult GetBlob(const /*JS::Value*/ void *aBlobParts, const /*JS::Value*/ void *aParameters, JSContext *cx, - uint8_t _argc, nsIDOMBlob * _retval); nsresult GetFileId(const /*JS::Value*/ void *aFile, JSContext *cx, int64_t *_retval); - nsresult GetFileReferences(const nsAString *aDatabaseName, int64_t aId, int32_t *aRefCnt, int32_t *aDBRefCnt, - int32_t *aSliceRefCnt, bool *_retval); + nsresult GetFileReferences(const nsAString *aDatabaseName, int64_t aId, void /*JS::HandleValue*/ *aOptions, + int32_t *aRefCnt, int32_t *aDBRefCnt, int32_t *aSliceRefCnt, JSContext* cx, bool *_retval); nsresult IsIncrementalGCEnabled(JSContext *cx, bool *_retval); nsresult StartPCCountProfiling(JSContext *cx); nsresult StopPCCountProfiling(JSContext *cx); @@ -3037,8 +3035,11 @@ nsresult GetPlugins(JSContext *cx, /*JS::Value*/ void *aPlugins); nsresult SetScrollPositionClampingScrollPortSize(float aWidth, float aHeight); nsresult SetContentDocumentFixedPositionMargins(float aTop, float aRight, float aBottom, float aLeft); - nsresult PreventFurtherDialogs(); + nsresult DisableDialogs(); + nsresult EnableDialogs(); + nsresult AreDialogsEnabled(bool *_retval); nsresult LoadSheet(nsIURI *sheetURI, uint32_t type); + nsresult AddSheet(nsIDOMStyleSheet *sheet, uint32_t type); nsresult RemoveSheet(nsIURI *sheetURI, uint32_t type); nsresult GetIsHandlingUserInput(bool *aIsHandlingUserInput); nsresult AllowScriptsToClose(); @@ -3048,7 +3049,16 @@ nsresult SetPaintFlashing(bool aPaintFlashing); nsresult RunInStableState(nsIRunnable *runnable); nsresult RunBeforeNextEvent(nsIRunnable *runnable); - nsresult GetOMTAOrComputedStyle(nsIDOMNode *aNode, const nsAString *aProperty, nsAString *_retval); + nsresult GetOMTAStyle(nsIDOMElement *aElement, const nsAString *aProperty, nsAString *_retval); + nsresult SetHandlingUserInput(bool aHandlingInput, void /*nsIJSRAIIHelper*/ **_retval); + nsresult GetContentAPZTestData(JSContext *cx, int /*JS::MutableHandleValue*/ _retval); + nsresult GetCompositorAPZTestData(JSContext *cx, void /*JS::MutableHandleValue*/ *_retval); + nsresult GetAudioMuted(bool *aAudioMuted) ; + nsresult SetAudioMuted(bool aAudioMuted); + nsresult GetAudioVolume(float *aAudioVolume); + nsresult SetAudioVolume(float aAudioVolume); + nsresult XpconnectArgument(nsIDOMWindowUtils *aThis); + nsresult AskPermission(void /*nsIContentPermissionRequest*/ *aRequest); } cpp_quote("#define CONTEXT_NONE 0x00") @@ -3094,7 +3104,7 @@ [ object, - uuid(afb2e57b-2822-4969-b2a9-0cada6859534), + uuid(df068636-9a5b-11e3-b71f-2c27d728e7f9), local ] interface nsIDOMMouseEvent : nsIDOMUIEvent @@ -3109,7 +3119,7 @@ nsresult GetShiftKey(bool *aShiftKey); nsresult GetAltKey(bool *aAltKey); nsresult GetMetaKey(bool *aMetaKey); - nsresult GetButton(uint16_t *aButton); + nsresult GetButton(int16_t *aButton); nsresult GetButtons(uint16_t *aButtons); nsresult GetRelatedTarget(nsIDOMEventTarget **aRelatedTarget); nsresult InitMouseEvent(const nsAString *typeArg, bool canBubbleArg, bool cancelableArg, @@ -3129,7 +3139,7 @@ [ object, - uuid(91a3d7f2-223b-4e09-a566-634e7ee0a31d), + uuid(d2b3e35f-8627-4732-a92d-cda54c8f8054), local ] interface nsIDOMKeyEvent : nsIDOMUIEvent @@ -3146,6 +3156,7 @@ uint32_t charCodeArg); nsresult GetModifierState(const nsAString *keyArg, bool *_retval); nsresult GetLocation(uint32_t *aLocation); + nsresult GetRepeat(bool *aRepeat); nsresult GetKey(nsAString *aKey); } @@ -3259,7 +3270,7 @@ [ object, - uuid(83f892cf-7ed3-490e-967a-62640f3158e1), + uuid(b1fdf3c4-74e3-4f7d-a14d-2b76bcf53482), local ] interface nsICommandParams : nsISupports @@ -3278,9 +3289,6 @@ nsresult SetCStringValue(const char *name, const char *value); nsresult SetISupportsValue(const char *name, nsISupports *value); nsresult RemoveValue(const char *name); - nsresult HasMoreElements(bool *_retval); - nsresult First(); - nsresult GetNext(char **_retval); } [ @@ -3342,7 +3350,7 @@ [ object, - uuid(8a8b4b1d-72d8-428e-9575-f918baf69ea1), + uuid(697a2fe1-5549-48e7-9a1a-c29dab14e239), local ] interface nsIContent : nsISupports @@ -3352,7 +3360,7 @@ [ object, - uuid(62cca591-a030-4117-9b80-dcd366bbb509), + uuid(613ea294-0288-48b4-9e7b-0fe93f8cf895), local ] interface nsIDocument : nsISupports @@ -3386,15 +3394,13 @@ [ object, - uuid(753b38d1-ee03-4e58-a650-1076ccccdb7f), + uuid(04714a01-e02f-4ef5-a388-612451d0db16), local ] interface nsIEditor : nsISupports { - typedef void *nsIContentPtr; - nsresult GetSelection([out] nsISelection *_retval); - nsresult Init([in] nsIDOMDocument *doc, [in] nsIContentPtr aRoot, [in] nsISelectionController *aSelCon, [in] uint32_t aFlags); + nsresult Init([in] nsIDOMDocument *doc, nsIContent *aRoot, nsISelectionController *aSelCon, uint32_t aFlags, nsAString *initialValue); nsresult SetAttributeOrEquivalent([in] nsIDOMElement *element, [in] const nsAString *sourceAttrName, [in] const nsAString *sourceAttrValue, [in] bool aSuppressTransaction); nsresult RemoveAttributeOrEquivalent([in] nsIDOMElement *element, [in] const nsAString *sourceAttrName, [in] bool aSuppressTransaction); nsresult PostCreate(); @@ -3461,7 +3467,7 @@ nsresult SwitchTextDirection(); nsresult OutputToString([in] nsAString formatType, [in] uint32_t flags, [out] nsAString *_retval); nsresult OutputToStream([in] nsIOutputStream *aStream, [in] nsAString *formatType, [in] nsACString *charsetOverride, [in] uint32_t flags); - nsresult SetEditorObserver(nsIEditorObserver *observer); + nsresult AddEditorObserver(nsIEditorObserver *observer); nsresult RemoveEditorObserver(nsIEditorObserver *observer); nsresult AddEditActionListener([in] nsIEditActionListener *listener); nsresult RemoveEditActionListener([in] nsIEditActionListener *listener); @@ -3471,13 +3477,14 @@ nsresult DebugDumpContent(); nsresult DebugUnitTests([out] int32_t *outNumTests, [out] int32_t *outNumTestsFailed); bool IsModifiableNode(nsIDOMNode *aNode); - nsresult GetLastKeypressEventTrusted(bool *aLastKeypressEventTrusted); + nsresult GetSuppressDispatchingInputEvent(bool *aSuppressDispatchingInputEvent); nsresult SetSuppressDispatchingInputEvent(bool aSuppressDispatchingInputEvent); + nsresult GetIsInEditAction(bool *aIsInEditAction); } [ object, - uuid(833f30de-94c7-4630-a852-2300ef329d7b), + uuid(393a364f-e8e2-48a1-a271-a0067b6bac9b), local ] interface nsIHTMLEditor : nsISupports @@ -3539,47 +3546,110 @@ void /*Element*/ *GetActiveEditingHost(); } -interface nsIDocShellTreeItem; - [ object, - uuid(37f1ab73-f224-44b1-82f0-d2834ab1cec0), + uuid(edb99640-8378-4106-8673-e701a086eb1c), local ] -interface nsIDocShellTreeNode : nsISupports +interface nsIDocShellTreeItem : nsISupports { + nsresult GetName(nsAString *aName); + nsresult SetName(const nsAString *aName); + nsresult NameEquals(const PRUnichar *name, bool *_retval); + nsresult GetItemType(int32_t *aItemType); + nsresult SetItemType(int32_t aItemType); + int32_t ItemType(); + nsresult GetParent(nsIDocShellTreeItem **aParent); + nsresult GetSameTypeParent(nsIDocShellTreeItem **aSameTypeParent); + nsresult GetRootTreeItem(nsIDocShellTreeItem **aRootTreeItem); + nsresult GetSameTypeRootTreeItem(nsIDocShellTreeItem **aSameTypeRootTreeItem); + nsresult FindItemWithName(const PRUnichar *name, nsISupports *aRequestor, nsIDocShellTreeItem *aOriginalRequestor, + nsIDocShellTreeItem **_retval); + nsresult GetTreeOwner(nsIDocShellTreeOwner **aTreeOwner); + nsresult SetTreeOwner(nsIDocShellTreeOwner *treeOwner); nsresult GetChildCount(int32_t *aChildCount); nsresult AddChild(nsIDocShellTreeItem *child); nsresult RemoveChild(nsIDocShellTreeItem *child); nsresult GetChildAt(int32_t index, nsIDocShellTreeItem **_retval); nsresult FindChildWithName(const PRUnichar *aName, bool aRecurse, bool aSameType, nsIDocShellTreeItem *aRequestor, nsIDocShellTreeItem *aOriginalRequestor, nsIDocShellTreeItem **_retval); + nsIDocument /* thiscall */ *GetDocument(); + void /* thiscall nsPIDOMWindow */ *GetWindow(); } [ object, - uuid(e35bbb39-985b-4d62-81da-73c330222e5f), + uuid(702e0a92-7d63-490e-b5ee-d247e6bd4588), local ] -interface nsIDocShellTreeItem : nsIDocShellTreeNode +interface nsIContentViewer : nsISupports { - nsresult GetName(nsAString *aName); - nsresult SetName(const nsAString *aName); - nsresult NameEquals(const PRUnichar *name, bool *_retval); - nsresult GetItemType(int32_t *aItemType); - nsresult SetItemType(int32_t aItemType); - nsresult GetParent(nsIDocShellTreeItem **aParent); - nsresult GetSameTypeParent(nsIDocShellTreeItem **aSameTypeParent); - nsresult GetRootTreeItem(nsIDocShellTreeItem **aRootTreeItem); - nsresult GetSameTypeRootTreeItem(nsIDocShellTreeItem **aSameTypeRootTreeItem); - nsresult FindItemWithName(const PRUnichar *name, nsISupports *aRequestor, nsIDocShellTreeItem *aOriginalRequestor, nsIDocShellTreeItem **_retval); - nsresult GetTreeOwner(nsIDocShellTreeOwner **aTreeOwner); - nsresult SetTreeOwner(nsIDocShellTreeOwner *treeOwner); + nsresult Init(nsIWidget *aParentWidget, const void /*nsIntRect*/ *aBounds); + nsresult GetContainer(nsIDocShell **aContainer); + nsresult SetContainer(nsIDocShell *aContainer); + void /* thiscall */ LoadStart(nsIDocument *aDoc); + nsresult LoadComplete(nsresult aStatus); + nsresult PermitUnload(bool aCallerClosesWindow, bool *_retval); + nsresult GetInPermitUnload(bool *aInPermitUnload); + nsresult /* thiscall */ PermitUnloadInternal(bool aCallerClosesWindow, bool *aShouldPrompt, bool *_retval); + nsresult GetBeforeUnloadFiring(bool *aBeforeUnloadFiring); + nsresult ResetCloseWindow(); + nsresult PageHide(bool isUnload); + nsresult Close(nsISHEntry *historyEntry); + nsresult Destroy(); + nsresult Stop(); + nsresult GetDOMDocument(nsIDOMDocument **aDOMDocument); + nsresult SetDOMDocument(nsIDOMDocument *aDOMDocument); + void /* thiscall nsresult_(nsIDocument *) */ GetDocument(); + nsresult GetBounds(void /*nsIntRect*/ *aBounds); + nsresult SetBounds(const void /*nsIntRect*/ *aBounds); + nsresult GetPreviousViewer(nsIContentViewer **aPreviousViewer); + nsresult SetPreviousViewer(nsIContentViewer *aPreviousViewer); + nsresult Move(int32_t aX, int32_t aY); + nsresult Show(); + nsresult Hide(); + nsresult GetSticky(bool *aSticky); + nsresult SetSticky(bool aSticky); + nsresult RequestWindowClose(bool *_retval); + nsresult Open(nsISupports *aState, nsISHEntry *aSHEntry); + nsresult ClearHistoryEntry(); + nsresult SetPageMode(bool aPageMode, nsIPrintSettings *aPrintSettings); + nsresult GetHistoryEntry(nsISHEntry **aHistoryEntry); + nsresult GetIsTabModalPromptAllowed(bool *aIsTabModalPromptAllowed); + nsresult GetIsHidden(bool *aIsHidden); + nsresult SetIsHidden(bool aIsHidden); + nsresult GetPresShell(nsIPresShell **aPresShell); + nsresult GetPresContext(void /*nsPresContext*/ **aPresContext); + nsresult SetDocumentInternal(nsIDocument *aDocument, bool aForceReuseInnerWindow); + void /* thiscall nsView */ *FindContainerView(void); + void /* thiscall */ SetNavigationTiming(void /*nsDOMNavigationTiming*/ *aTiming); + nsresult ScrollToNode(nsIDOMNode *node); + nsresult GetTextZoom(float *aTextZoom); + nsresult SetTextZoom(float aTextZoom); + nsresult GetFullZoom(float *aFullZoom); + nsresult SetFullZoom(float aFullZoom); + nsresult GetAuthorStyleDisabled(bool *aAuthorStyleDisabled); + nsresult SetAuthorStyleDisabled(bool aAuthorStyleDisabled); + nsresult GetForceCharacterSet(nsACString *aForceCharacterSet); + nsresult SetForceCharacterSet(const nsACString *aForceCharacterSet); + nsresult GetHintCharacterSet(nsACString *aHintCharacterSet); + nsresult SetHintCharacterSet(const nsACString *aHintCharacterSet); + nsresult GetHintCharacterSetSource(int32_t *aHintCharacterSetSource); + nsresult SetHintCharacterSetSource(int32_t aHintCharacterSetSource); + nsresult GetContentSize(int32_t *width, int32_t *height); + nsresult GetMinFontSize(int32_t *aMinFontSize); + nsresult SetMinFontSize(int32_t aMinFontSize); + nsresult AppendSubtree(void /*nsTArray >*/ *array); + nsresult ChangeMaxLineBoxWidth(int32_t maxLineBoxWidth); + nsresult PausePainting(); + nsresult ResumePainting(); + nsresult EmulateMedium(const nsAString *aMediaType); + nsresult StopEmulatingMedium(); } [ object, - uuid(f453d2ee-bac7-46f9-a553-df918f0cc0d0), + uuid(3646c915-df79-4500-8b57-c65ab9c3b39f), local ] interface nsIDocShell : nsIDocShellTreeItem @@ -3589,8 +3659,9 @@ const nsACString *aContentCharset, nsIDocShellLoadInfo *aLoadInfo); nsresult InternalLoad(nsIURI *aURI, nsIURI *aReferrer, nsISupports *aOwner, uint32_t aFlags, const PRUnichar *aWindowTarget, const char *aTypeHint, nsACString *aFileName, nsIInputStream *aPostDataStream, nsIInputStream *aHeadersStream, - uint32_t aLoadFlags, nsISHEntry *aSHEntry, bool firstParty, nsIDocShell **aDocShell, nsIRequest **aRequest); - nsresult AddState(nsIVariant *aData, const nsAString *aTitle, const nsAString *aURL, bool aReplace, JSContext *cx); + uint32_t aLoadFlags, nsISHEntry *aSHEntry, bool firstParty, const nsAString *aSrcdoc, nsIDocShell *aSourceDocShell, + nsIURI *aBaseURI, nsIDocShell **aDocShell, nsIRequest **aRequest); + nsresult AddState(jsval *aData, const nsAString *aTitle, const nsAString *aURL, bool aReplace, JSContext *cx); nsresult CreateLoadInfo(nsIDocShellLoadInfo **loadInfo); nsresult PrepareForNewContentModel(); nsresult SetCurrentURI(nsIURI *aURI); @@ -3619,6 +3690,8 @@ nsresult SetAllowDNSPrefetch(bool aAllowDNSPrefetch); nsresult GetAllowWindowControl(bool *aAllowWindowControl); nsresult SetAllowWindowControl(bool aAllowWindowControl); + nsresult GetAllowContentRetargeting(bool *aAllowContentRetargeting); + nsresult SetAllowContentRetargeting(bool aAllowContentRetargeting); nsresult GetDocShellEnumerator(int32_t aItemType, int32_t aDirection, nsISimpleEnumerator **_retval); nsresult GetAppType(uint32_t *aAppType); nsresult SetAppType(uint32_t aAppType); @@ -3634,6 +3707,8 @@ nsresult GetBusyFlags(uint32_t *aBusyFlags); nsresult GetLoadType(uint32_t *aLoadType); nsresult SetLoadType(uint32_t aLoadType); + nsresult GetDefaultLoadFlags(nsLoadFlags *aDefaultLoadFlags); + nsresult SetDefaultLoadFlags(nsLoadFlags aDefaultLoadFlags); nsresult IsBeingDestroyed(bool *_retval); nsresult GetIsExecutingOnLoadHandler(bool *aIsExecutingOnLoadHandler); nsresult GetLayoutHistoryState(nsILayoutHistoryState **aLayoutHistoryState); @@ -3648,6 +3723,8 @@ nsresult GetRestoringDocument(bool *aRestoringDocument); nsresult GetUseErrorPages(bool *aUseErrorPages); nsresult SetUseErrorPages(bool aUseErrorPages); + nsresult DisplayLoadError(nsresult aError, nsIURI *aURI, const PRUnichar *aURL, nsIChannel *aFailedChannel); + nsresult GetFailedChannel(nsIChannel **aFailedChannel); nsresult GetPreviousTransIndex(int32_t *aPreviousTransIndex); nsresult GetLoadedTransIndex(int32_t *aLoadedTransIndex); nsresult HistoryPurged(int32_t numEntries); @@ -3662,6 +3739,8 @@ nsresult GetHasMixedActiveContentBlocked(bool *aHasMixedActiveContentBlocked); nsresult GetHasMixedDisplayContentLoaded(bool *aHasMixedDisplayContentLoaded); nsresult GetHasMixedDisplayContentBlocked(bool *aHasMixedDisplayContentBlocked); + nsresult GetHasTrackingContentBlocked(bool *aHasTrackingContentBlocked); + nsresult GetHasTrackingContentLoaded(bool *aHasTrackingContentLoaded); void DetachEditorFromWindow(); nsresult GetIsOffScreenBrowser(bool *aIsOffScreenBrowser); nsresult SetIsOffScreenBrowser(bool aIsOffScreenBrowser); @@ -3673,19 +3752,22 @@ nsresult GetIsAppTab(bool *aIsAppTab); nsresult SetIsAppTab(bool aIsAppTab); nsresult CreateAboutBlankContentViewer(nsIPrincipal *aPrincipal); - nsresult GetCharset(char **aCharset); - nsresult SetCharset(const char * aCharset); + nsresult GetCharset(nsACString *aCharset); + nsresult SetCharset(nsACString *aCharset); nsresult GatherCharsetMenuTelemetry(); nsresult GetForcedCharset(nsIAtom **aForcedCharset); nsresult SetForcedCharset(nsIAtom *aForcedCharset); - nsresult GetParentCharset(nsIAtom **aParentCharset); - nsresult SetParentCharset(nsIAtom *aParentCharset); + void SetParentCharset(const nsACString *parentCharset, int32_t parentCharsetSource, nsIPrincipal *parentCharsetPrincipal); + void GetParentCharset(nsACString *parentCharset, int32_t *parentCharsetSource, nsIPrincipal **parentCharsetPrincipal); nsresult GetParentCharsetSource(int32_t *aParentCharsetSource); nsresult SetParentCharsetSource(int32_t aParentCharsetSource); nsresult AddWeakPrivacyTransitionObserver(nsIPrivacyTransitionObserver *obs); nsresult AddWeakReflowObserver(nsISupports /*nsIReflowObserver*/ *obs); nsresult RemoveWeakReflowObserver(nsISupports /*nsIReflowObserver*/ *obs); nsresult NotifyReflowObservers(bool interruptible, int /*DOMHighResTimeStamp*/ start, int /*DOMHighResTimeStamp*/ end); + nsresult AddWeakScrollObserver(void /*nsIScrollObserver*/ *obs); + nsresult RemoveWeakScrollObserver(void /*nsIScrollObserver*/ *obs); + nsresult NotifyScrollObservers(); nsresult GetIsBrowserElement(bool *aIsBrowserElement); nsresult GetIsApp(bool *aIsApp); nsresult GetIsBrowserOrApp(bool *aIsBrowserOrApp); @@ -3694,10 +3776,14 @@ nsresult SetIsApp(uint32_t ownAppId); nsresult SetIsBrowserInsideApp(uint32_t containingAppId); nsresult GetAppId(uint32_t *aAppId); + nsresult GetAppManifestURL(nsAString *aAppManifestURL); nsresult GetSameTypeParentIgnoreBrowserAndAppBoundaries(nsIDocShell **_retval); nsresult GetAsyncPanZoomEnabled(bool *aAsyncPanZoomEnabled); nsresult GetSandboxFlags(uint32_t *aSandboxFlags); nsresult SetSandboxFlags(uint32_t aSandboxFlags); + nsresult GetOnePermittedSandboxedNavigator(nsIDocShell **aOnePermittedSandboxedNavigator); + nsresult SetOnePermittedSandboxedNavigator(nsIDocShell *aOnePermittedSandboxedNavigator); + bool IsSandboxedFrom(nsIDocShell *aTargetDocShell); nsresult GetMixedContentChannel(nsIChannel **aMixedContentChannel); nsresult SetMixedContentChannel(nsIChannel *aMixedContentChannel); nsresult GetAllowMixedContentAndConnectionData(bool *rootHasSecureConnection, bool *allowMixedContent, bool *isRootDocShell); @@ -3720,47 +3806,18 @@ nsresult GetCreatedDynamically(bool *aCreatedDynamically); nsresult SetCreatedDynamically(bool aCreatedDynamically); nsresult GetCurrentSHEntry(nsISHEntry **aEntry, bool *_retval); -} - -[ - object, - uuid(02d37b31-e654-4b74-9bc3-14dfe0020bb3), - local -] -interface nsIMarkupDocumentViewer : nsISupports -{ - nsresult ScrollToNode(nsIDOMNode *node); - nsresult GetTextZoom(float *aTextZoom); - nsresult SetTextZoom(float aTextZoom); - nsresult GetFullZoom(float *aFullZoom); - nsresult SetFullZoom(float aFullZoom); - nsresult GetAuthorStyleDisabled(bool *aAuthorStyleDisabled); - nsresult SetAuthorStyleDisabled(bool aAuthorStyleDisabled); - nsresult GetDefaultCharacterSet(nsACString *aDefaultCharacterSet); - nsresult SetDefaultCharacterSet(const nsACString *aDefaultCharacterSet); - nsresult GetForceCharacterSet(nsACString *aForceCharacterSet); - nsresult SetForceCharacterSet(const nsACString *aForceCharacterSet); - nsresult GetHintCharacterSet(nsACString *aHintCharacterSet); - nsresult SetHintCharacterSet(const nsACString *aHintCharacterSet); - nsresult GetHintCharacterSetSource(int32_t *aHintCharacterSetSource); - nsresult SetHintCharacterSetSource(int32_t aHintCharacterSetSource); - nsresult GetPrevDocCharacterSet(nsACString *aPrevDocCharacterSet); - nsresult SetPrevDocCharacterSet(const nsACString *aPrevDocCharacterSet); - nsresult GetContentSize(int32_t *width, int32_t *height); - nsresult GetBidiTextDirection(uint8_t *aBidiTextDirection); - nsresult SetBidiTextDirection(uint8_t aBidiTextDirection); - nsresult GetBidiTextType(uint8_t *aBidiTextType); - nsresult SetBidiTextType(uint8_t aBidiTextType); - nsresult GetBidiNumeral(uint8_t *aBidiNumeral); - nsresult SetBidiNumeral(uint8_t aBidiNumeral); - nsresult GetBidiSupport(uint8_t *aBidiSupport); - nsresult SetBidiSupport(uint8_t aBidiSupport); - nsresult GetBidiOptions(uint32_t *aBidiOptions); - nsresult SetBidiOptions(uint32_t aBidiOptions); - nsresult GetMinFontSize(int32_t *aMinFontSize); - nsresult SetMinFontSize(int32_t aMinFontSize); - nsresult AppendSubtree(void /* nsTArray> */ *array); - nsresult ChangeMaxLineBoxWidth(int32_t maxLineBoxWidth); + nsresult IsCommandEnabled(const char *command, bool *_retval); + nsresult DoCommand(const char *command); + bool IsInvisible(); + void SetInvisible(bool aIsInvisibleDochsell); + void /*nsIScriptGlobalObject*/ *GetScriptGlobalObject(); + nsresult GetDeviceSizeIsPageSize(bool *aDeviceSizeIsPageSize); + nsresult SetDeviceSizeIsPageSize(bool aDeviceSizeIsPageSize); + void /* thiscall */ SetOpener(void /*nsITabParent*/ *aOpener); + void /* thiscall nsITabParent */ *GetOpener(void) = 0; + void /* thiscall */ SetOpenedRemote(void /*nsITabParent*/ *aOpenedRemote); + void /* thiscall nsITabParent */ *GetOpenedRemote(); + void /*mozilla::dom::URLSearchParams */ *GetURLSearchParams(void) = 0; } [ @@ -3811,12 +3868,14 @@ void SetCommand(eParserCommands aParserCommand); void SetDocumentCharset(const nsACString *aCharset, int32_t aSource); void GetDocumentCharset(nsACString *oCharset, int32_t *oSource); + /* nsresult GetChannel(nsIChannel **aChannel); in nsParserBase */ nsresult GetDTD(nsIDTD **aDTD); nsIStreamListener *GetStreamListener(); nsresult ContinueInterruptedParsing(); void BlockParser(); void UnblockParser(); void ContinueInterruptedParsingAsync(); + /* bool IsParserEnabled(); in nsParserBase */ bool IsComplete(); nsresult Parse(nsIURI *aURL, nsIRequestObserver *aListener, void *aKey, nsDTDMode aMode); nsresult Terminate(); @@ -3842,14 +3901,14 @@ typedef struct { uint64_t mStates; - } nsEventStates; + } EventStates; void BeginUpdate(nsIDocument *aDocument, nsUpdateType aUpdateType); void EndUpdate(nsIDocument *aDocument, nsUpdateType aUpdateType); void BeginLoad(nsIDocument *aDocument); void EndLoad(nsIDocument *aDocument); - void ContentStatesChanged(nsIDocument *aDocument, nsIContent *aContent, nsEventStates *aStateMask); - void DocumentStatesChanged(nsIDocument *aDocument, nsEventStates *aStateMask); + void ContentStatesChanged(nsIDocument *aDocument, nsIContent *aContent, EventStates aStateMask); + void DocumentStatesChanged(nsIDocument *aDocument, EventStates aStateMask); void StyleSheetAdded(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet, bool aDocumentSheet); void StyleSheetRemoved(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet, bool aDocumentSheet); void StyleSheetApplicableStateChanged(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet, diff -Nru wine1.7-1.7.28/dlls/mshtml/nsio.c wine1.7-1.7.31/dlls/mshtml/nsio.c --- wine1.7-1.7.28/dlls/mshtml/nsio.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/nsio.c 2014-11-14 13:28:17.000000000 +0000 @@ -1179,6 +1179,32 @@ return NS_ERROR_NOT_IMPLEMENTED; } +static nsresult NSAPI nsChannel_GetLoadInfo(nsIHttpChannel *iface, nsILoadInfo **aLoadInfo) +{ + nsChannel *This = impl_from_nsIHttpChannel(iface); + + TRACE("(%p)->(%p)\n", This, aLoadInfo); + + if(This->load_info) + nsISupports_AddRef(This->load_info); + *aLoadInfo = This->load_info; + return NS_OK; +} + +static nsresult NSAPI nsChannel_SetLoadInfo(nsIHttpChannel *iface, nsILoadInfo *aLoadInfo) +{ + nsChannel *This = impl_from_nsIHttpChannel(iface); + + TRACE("(%p)->(%p)\n", This, aLoadInfo); + + if(This->load_info) + nsISupports_Release(This->load_info); + This->load_info = aLoadInfo; + if(This->load_info) + nsISupports_AddRef(This->load_info); + return NS_OK; +} + static nsresult NSAPI nsChannel_GetRequestMethod(nsIHttpChannel *iface, nsACString *aRequestMethod) { nsChannel *This = impl_from_nsIHttpChannel(iface); @@ -1287,6 +1313,20 @@ return NS_ERROR_NOT_IMPLEMENTED; } +static nsresult NSAPI nsChannel_GetAllowTLS(nsIHttpChannel *iface, cpp_bool *aAllowTLS) +{ + nsChannel *This = impl_from_nsIHttpChannel(iface); + FIXME("(%p)->(%p)\n", This, aAllowTLS); + return NS_ERROR_NOT_IMPLEMENTED; +} + +static nsresult NSAPI nsChannel_SetAllowTLS(nsIHttpChannel *iface, cpp_bool aAllowTLS) +{ + nsChannel *This = impl_from_nsIHttpChannel(iface); + FIXME("(%p)->(%x)\n", This, aAllowTLS); + return NS_ERROR_NOT_IMPLEMENTED; +} + static nsresult NSAPI nsChannel_GetRedirectionLimit(nsIHttpChannel *iface, UINT32 *aRedirectionLimit) { nsChannel *This = impl_from_nsIHttpChannel(iface); @@ -1443,6 +1483,8 @@ nsChannel_GetContentDispositionFilename, nsChannel_SetContentDispositionFilename, nsChannel_GetContentDispositionHeader, + nsChannel_GetLoadInfo, + nsChannel_SetLoadInfo, nsChannel_GetRequestMethod, nsChannel_SetRequestMethod, nsChannel_GetReferrer, @@ -1452,6 +1494,8 @@ nsChannel_VisitRequestHeaders, nsChannel_GetAllowPipelining, nsChannel_SetAllowPipelining, + nsChannel_GetAllowTLS, + nsChannel_SetAllowTLS, nsChannel_GetRedirectionLimit, nsChannel_SetRedirectionLimit, nsChannel_GetResponseStatus, @@ -1613,6 +1657,15 @@ return NS_ERROR_NOT_IMPLEMENTED; } +static nsresult NSAPI nsHttpChannelInternal_TakeAllSecurityMessages(nsIHttpChannelInternal *iface, void *aMessages) +{ + nsChannel *This = impl_from_nsIHttpChannelInternal(iface); + + FIXME("(%p)->()\n", This); + + return NS_ERROR_NOT_IMPLEMENTED; +} + static nsresult NSAPI nsHttpChannelInternal_SetCookie(nsIHttpChannelInternal *iface, const char *aCookieHeader) { nsChannel *This = impl_from_nsIHttpChannelInternal(iface); @@ -1779,6 +1832,7 @@ nsHttpChannelInternal_SetDocumentURI, nsHttpChannelInternal_GetRequestVersion, nsHttpChannelInternal_GetResponseVersion, + nsHttpChannelInternal_TakeAllSecurityMessages, nsHttpChannelInternal_SetCookie, nsHttpChannelInternal_SetupFallbackChannel, nsHttpChannelInternal_GetForceAllowThirdPartyCookie, @@ -3317,6 +3371,7 @@ WCHAR new_spec[INTERNET_MAX_URL_LENGTH]; HTMLOuterWindow *window = NULL; const char *spec = NULL; + UINT cp = CP_UTF8; IUri *urlmon_uri; nsresult nsres; HRESULT hres; @@ -3343,10 +3398,22 @@ } } - if(aOriginCharset && strcasecmp(aOriginCharset, "utf-8")) - FIXME("Unsupported charset %s\n", debugstr_a(aOriginCharset)); + if(aOriginCharset && *aOriginCharset && strncasecmp(aOriginCharset, "utf", 3)) { + BSTR charset; + int len; + + len = MultiByteToWideChar(CP_UTF8, 0, aOriginCharset, -1, NULL, 0); + charset = SysAllocStringLen(NULL, len-1); + if(!charset) + return NS_ERROR_OUT_OF_MEMORY; + MultiByteToWideChar(CP_UTF8, 0, aOriginCharset, -1, charset, len); + + cp = cp_from_charset_string(charset); + + SysFreeString(charset); + } - MultiByteToWideChar(CP_UTF8, 0, spec, -1, new_spec, sizeof(new_spec)/sizeof(WCHAR)); + MultiByteToWideChar(cp, 0, spec, -1, new_spec, sizeof(new_spec)/sizeof(WCHAR)); if(base_wine_uri) { hres = combine_url(base_wine_uri->uri, new_spec, &urlmon_uri); diff -Nru wine1.7-1.7.28/dlls/mshtml/oleobj.c wine1.7-1.7.31/dlls/mshtml/oleobj.c --- wine1.7-1.7.28/dlls/mshtml/oleobj.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/oleobj.c 2014-11-14 13:28:17.000000000 +0000 @@ -229,7 +229,6 @@ static void load_settings(HTMLDocumentObj *doc) { - nsIMarkupDocumentViewer *markup_document_viewer; nsIContentViewer *content_viewer; nsIDocShell *doc_shell; HKEY settings_key; @@ -261,16 +260,13 @@ nsres = nsIDocShell_GetContentViewer(doc_shell, &content_viewer); assert(nsres == NS_OK && content_viewer); + nsIDocShell_Release(doc_shell); - nsres = nsISupports_QueryInterface(content_viewer, &IID_nsIMarkupDocumentViewer, (void**)&markup_document_viewer); - nsISupports_Release(content_viewer); - assert(nsres == NS_OK); - - nsres = nsIMarkupDocumentViewer_SetFullZoom(markup_document_viewer, (float)val/100000); + nsres = nsIContentViewer_SetFullZoom(content_viewer, (float)val/100000); if(NS_FAILED(nsres)) ERR("SetFullZoom failed: %08x\n", nsres); - nsIDocShell_Release(doc_shell); + nsIContentViewer_Release(content_viewer); } static HRESULT WINAPI OleObject_SetClientSite(IOleObject *iface, IOleClientSite *pClientSite) diff -Nru wine1.7-1.7.28/dlls/mshtml/protocol.c wine1.7-1.7.31/dlls/mshtml/protocol.c --- wine1.7-1.7.28/dlls/mshtml/protocol.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/protocol.c 2014-11-14 13:28:17.000000000 +0000 @@ -594,9 +594,9 @@ DWORD grfPI, HANDLE_PTR dwReserved) { ResProtocol *This = ResProtocol_from_IInternetProtocol(iface); + WCHAR *url_dll, *url_file, *url, *mime, *res_type = (LPWSTR)RT_HTML, *ptr; DWORD grfBINDF = 0, len; BINDINFO bindinfo; - LPWSTR url_dll, url_file, url, mime, res_type = (LPWSTR)RT_HTML; HMODULE hdll; HRSRC src; HRESULT hres; @@ -646,6 +646,12 @@ res_type = MAKEINTRESOURCEW(RT_HTML); } + /* Ignore query and hash parts. */ + if((ptr = strchrW(url_file, '?'))) + *ptr = 0; + if((ptr = strchrW(url_file, '#'))) + *ptr = 0; + hdll = LoadLibraryExW(url_dll, NULL, LOAD_LIBRARY_AS_DATAFILE); if(!hdll) { WARN("Could not open dll: %s\n", debugstr_w(url_dll)); diff -Nru wine1.7-1.7.28/dlls/mshtml/script.c wine1.7-1.7.31/dlls/mshtml/script.c --- wine1.7-1.7.28/dlls/mshtml/script.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/script.c 2014-11-14 13:28:17.000000000 +0000 @@ -29,6 +29,7 @@ #include "ole2.h" #include "activscp.h" #include "activdbg.h" +#include "shlwapi.h" #include "wine/debug.h" @@ -701,7 +702,15 @@ return ret; } -static void parse_text(ScriptHost *script_host, LPCWSTR text) +static void set_script_elem_readystate(HTMLScriptElement *script_elem, READYSTATE readystate) +{ + script_elem->readystate = readystate; + + if(readystate != READYSTATE_INTERACTIVE) + fire_event(script_elem->element.node.doc, EVENTID_READYSTATECHANGE, FALSE, script_elem->element.node.nsnode, NULL, NULL); +} + +static void parse_elem_text(ScriptHost *script_host, HTMLScriptElement *script_elem, LPCWSTR text) { EXCEPINFO excepinfo; VARIANT var; @@ -709,6 +718,8 @@ TRACE("%s\n", debugstr_w(text)); + set_script_elem_readystate(script_elem, READYSTATE_INTERACTIVE); + VariantInit(&var); memset(&excepinfo, 0, sizeof(excepinfo)); TRACE(">>>\n"); @@ -722,27 +733,233 @@ } -static void parse_extern_script(ScriptHost *script_host, LPCWSTR src) +typedef struct { + BSCallback bsc; + + HTMLScriptElement *script_elem; + DWORD scheme; + + DWORD size; + char *buf; + HRESULT hres; +} ScriptBSC; + +static inline ScriptBSC *impl_from_BSCallback(BSCallback *iface) +{ + return CONTAINING_RECORD(iface, ScriptBSC, bsc); +} + +static void ScriptBSC_destroy(BSCallback *bsc) +{ + ScriptBSC *This = impl_from_BSCallback(bsc); + + if(This->script_elem) { + IHTMLScriptElement_Release(&This->script_elem->IHTMLScriptElement_iface); + This->script_elem = NULL; + } + + heap_free(This->buf); + heap_free(This); +} + +static HRESULT ScriptBSC_init_bindinfo(BSCallback *bsc) +{ + return S_OK; +} + +static HRESULT ScriptBSC_start_binding(BSCallback *bsc) +{ + ScriptBSC *This = impl_from_BSCallback(bsc); + + /* FIXME: We should find a better to decide if 'loading' state is supposed to be used by the protocol. */ + if(This->scheme == URL_SCHEME_HTTPS || This->scheme == URL_SCHEME_HTTP) + set_script_elem_readystate(This->script_elem, READYSTATE_LOADING); + + return S_OK; +} + +static HRESULT ScriptBSC_stop_binding(BSCallback *bsc, HRESULT result) +{ + ScriptBSC *This = impl_from_BSCallback(bsc); + + This->hres = result; + + if(SUCCEEDED(result)) { + if(This->script_elem->readystate == READYSTATE_LOADING) + set_script_elem_readystate(This->script_elem, READYSTATE_LOADED); + }else { + FIXME("binding failed %08x\n", result); + heap_free(This->buf); + This->buf = NULL; + This->size = 0; + } + + IHTMLScriptElement_Release(&This->script_elem->IHTMLScriptElement_iface); + This->script_elem = NULL; + return S_OK; +} + +static HRESULT ScriptBSC_read_data(BSCallback *bsc, IStream *stream) +{ + ScriptBSC *This = impl_from_BSCallback(bsc); + DWORD readed; + HRESULT hres; + + if(!This->buf) { + This->buf = heap_alloc(128); + if(!This->buf) + return E_OUTOFMEMORY; + This->size = 128; + } + + do { + if(This->bsc.readed >= This->size) { + void *new_buf; + new_buf = heap_realloc(This->buf, This->size << 1); + if(!new_buf) + return E_OUTOFMEMORY; + This->size <<= 1; + This->buf = new_buf; + } + + hres = read_stream(&This->bsc, stream, This->buf+This->bsc.readed, This->size-This->bsc.readed, &readed); + }while(hres == S_OK); + + return S_OK; +} + +static HRESULT ScriptBSC_on_progress(BSCallback *bsc, ULONG status_code, LPCWSTR status_text) +{ + return S_OK; +} + +static HRESULT ScriptBSC_on_response(BSCallback *bsc, DWORD response_code, + LPCWSTR response_headers) { + return S_OK; +} + +static HRESULT ScriptBSC_beginning_transaction(BSCallback *bsc, WCHAR **additional_headers) +{ + return S_FALSE; +} + +static const BSCallbackVtbl ScriptBSCVtbl = { + ScriptBSC_destroy, + ScriptBSC_init_bindinfo, + ScriptBSC_start_binding, + ScriptBSC_stop_binding, + ScriptBSC_read_data, + ScriptBSC_on_progress, + ScriptBSC_on_response, + ScriptBSC_beginning_transaction +}; + + +static HRESULT bind_script_to_text(HTMLInnerWindow *window, IUri *uri, HTMLScriptElement *script_elem, WCHAR **ret) +{ + ScriptBSC *bsc; IMoniker *mon; WCHAR *text; HRESULT hres; + hres = CreateURLMonikerEx2(NULL, uri, &mon, URL_MK_UNIFORM); + if(FAILED(hres)) + return hres; + + bsc = heap_alloc_zero(sizeof(*bsc)); + if(!bsc) { + IMoniker_Release(mon); + return E_OUTOFMEMORY; + } + + init_bscallback(&bsc->bsc, &ScriptBSCVtbl, mon, 0); + IMoniker_Release(mon); + bsc->hres = E_FAIL; + + hres = IUri_GetScheme(uri, &bsc->scheme); + if(FAILED(hres)) + bsc->scheme = URL_SCHEME_UNKNOWN; + + IHTMLScriptElement_AddRef(&script_elem->IHTMLScriptElement_iface); + bsc->script_elem = script_elem; + + hres = start_binding(window, &bsc->bsc, NULL); + if(SUCCEEDED(hres)) + hres = bsc->hres; + if(FAILED(hres)) { + IBindStatusCallback_Release(&bsc->bsc.IBindStatusCallback_iface); + return hres; + } + + if(!bsc->bsc.readed) { + *ret = NULL; + return S_OK; + } + + switch(bsc->bsc.bom) { + case BOM_UTF16: + if(bsc->bsc.readed % sizeof(WCHAR)) { + FIXME("The buffer is not a valid utf16 string\n"); + hres = E_FAIL; + break; + } + + text = heap_alloc(bsc->bsc.readed+sizeof(WCHAR)); + if(!text) { + hres = E_OUTOFMEMORY; + break; + } + + memcpy(text, bsc->buf, bsc->bsc.readed); + text[bsc->bsc.readed/sizeof(WCHAR)] = 0; + break; + + case BOM_UTF8: + default: { + DWORD len; + + len = MultiByteToWideChar(CP_UTF8, 0, bsc->buf, bsc->bsc.readed, NULL, 0); + text = heap_alloc((len+1)*sizeof(WCHAR)); + if(!text) { + hres = E_OUTOFMEMORY; + break; + } + + MultiByteToWideChar(CP_UTF8, 0, bsc->buf, bsc->bsc.readed, text, len); + text[len] = 0; + } + } + + IBindStatusCallback_Release(&bsc->bsc.IBindStatusCallback_iface); + if(FAILED(hres)) + return hres; + + *ret = text; + return S_OK; +} + +static void parse_extern_script(ScriptHost *script_host, HTMLScriptElement *script_elem, LPCWSTR src) +{ + WCHAR *text; + IUri *uri; + HRESULT hres; + static const WCHAR wine_schemaW[] = {'w','i','n','e',':'}; if(strlenW(src) > sizeof(wine_schemaW)/sizeof(WCHAR) && !memcmp(src, wine_schemaW, sizeof(wine_schemaW))) src += sizeof(wine_schemaW)/sizeof(WCHAR); - hres = CreateURLMoniker(NULL, src, &mon); + hres = create_uri(src, 0, &uri); if(FAILED(hres)) return; - hres = bind_mon_to_wstr(script_host->window, mon, &text); - IMoniker_Release(mon); + hres = bind_script_to_text(script_host->window, uri, script_elem, &text); + IUri_Release(uri); if(FAILED(hres) || !text) return; - parse_text(script_host, text); + parse_elem_text(script_host, script_elem, text); heap_free(text); } @@ -760,7 +977,7 @@ if(NS_FAILED(nsres)) { ERR("GetText failed: %08x\n", nsres); }else if(*text) { - parse_text(script_host, text); + parse_elem_text(script_host, script_elem, text); } nsAString_Finish(&text_str); @@ -796,12 +1013,14 @@ ERR("GetSrc failed: %08x\n", nsres); }else if(*src) { script_elem->parsed = TRUE; - parse_extern_script(script_host, src); + parse_extern_script(script_host, script_elem, src); }else { parse_inline_script(script_host, script_elem); } nsAString_Finish(&src_str); + + set_script_elem_readystate(script_elem, READYSTATE_COMPLETE); } static GUID get_default_script_guid(HTMLInnerWindow *window) @@ -1197,7 +1416,7 @@ return; nsAString_InitDepend(&selector_str, selectorW); - nsres = nsIDOMNodeSelector_QuerySelectorAll(doc->nsnode_selector, &selector_str, &node_list); + nsres = nsIDOMHTMLDocument_QuerySelectorAll(doc->nsdoc, &selector_str, &node_list); nsAString_Finish(&selector_str); if(NS_FAILED(nsres)) { ERR("QuerySelectorAll failed: %08x\n", nsres); diff -Nru wine1.7-1.7.28/dlls/mshtml/selection.c wine1.7-1.7.31/dlls/mshtml/selection.c --- wine1.7-1.7.28/dlls/mshtml/selection.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/selection.c 2014-11-14 13:28:17.000000000 +0000 @@ -32,6 +32,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(mshtml); typedef struct { + DispatchEx dispex; IHTMLSelectionObject IHTMLSelectionObject_iface; LONG ref; @@ -52,26 +53,24 @@ { HTMLSelectionObject *This = impl_from_IHTMLSelectionObject(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLSelectionObject_iface; }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLSelectionObject_iface; }else if(IsEqualGUID(&IID_IHTMLSelectionObject, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); *ppv = &This->IHTMLSelectionObject_iface; + }else if(dispex_query_interface(&This->dispex, riid, ppv)) { + return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLSelectionObject_AddRef(IHTMLSelectionObject *iface) @@ -96,6 +95,7 @@ nsISelection_Release(This->nsselection); if(This->doc) list_remove(&This->entry); + release_dispex(&This->dispex); heap_free(This); } @@ -105,16 +105,16 @@ static HRESULT WINAPI HTMLSelectionObject_GetTypeInfoCount(IHTMLSelectionObject *iface, UINT *pctinfo) { HTMLSelectionObject *This = impl_from_IHTMLSelectionObject(iface); - FIXME("(%p)->(%p)\n", This, pctinfo); - return E_NOTIMPL; + + return IDispatchEx_GetTypeInfoCount(&This->dispex.IDispatchEx_iface, pctinfo); } static HRESULT WINAPI HTMLSelectionObject_GetTypeInfo(IHTMLSelectionObject *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) { HTMLSelectionObject *This = impl_from_IHTMLSelectionObject(iface); - FIXME("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo); - return E_NOTIMPL; + + return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); } static HRESULT WINAPI HTMLSelectionObject_GetIDsOfNames(IHTMLSelectionObject *iface, REFIID riid, @@ -122,9 +122,9 @@ LCID lcid, DISPID *rgDispId) { HTMLSelectionObject *This = impl_from_IHTMLSelectionObject(iface); - FIXME("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, - lcid, rgDispId); - return E_NOTIMPL; + + return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, + cNames, lcid, rgDispId); } static HRESULT WINAPI HTMLSelectionObject_Invoke(IHTMLSelectionObject *iface, DISPID dispIdMember, @@ -132,9 +132,10 @@ VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) { HTMLSelectionObject *This = impl_from_IHTMLSelectionObject(iface); - FIXME("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid), - lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); - return E_NOTIMPL; + + + return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, + lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); } static HRESULT WINAPI HTMLSelectionObject_createRange(IHTMLSelectionObject *iface, IDispatch **range) @@ -233,6 +234,17 @@ HTMLSelectionObject_get_type }; +static const tid_t HTMLSelectionObject_iface_tids[] = { + IHTMLSelectionObject_tid, + 0 +}; +static dispex_static_data_t HTMLSelectionObject_dispex = { + NULL, + IHTMLSelectionObject_tid, + NULL, + HTMLSelectionObject_iface_tids +}; + HRESULT HTMLSelectionObject_Create(HTMLDocumentNode *doc, nsISelection *nsselection, IHTMLSelectionObject **ret) { HTMLSelectionObject *selection; @@ -241,6 +253,8 @@ if(!selection) return E_OUTOFMEMORY; + init_dispex(&selection->dispex, (IUnknown*)&selection->IHTMLSelectionObject_iface, &HTMLSelectionObject_dispex); + selection->IHTMLSelectionObject_iface.lpVtbl = &HTMLSelectionObjectVtbl; selection->ref = 1; selection->nsselection = nsselection; /* We shouldn't call AddRef here */ diff -Nru wine1.7-1.7.28/dlls/mshtml/tests/dom.c wine1.7-1.7.31/dlls/mshtml/tests/dom.c --- wine1.7-1.7.28/dlls/mshtml/tests/dom.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/tests/dom.c 2014-11-14 13:28:17.000000000 +0000 @@ -381,6 +381,7 @@ ELEM_IFACES, &IID_IHTMLFormElement, &IID_IConnectionPointContainer, + &DIID_DispHTMLFormElement, NULL }; @@ -1671,6 +1672,20 @@ SysFreeString(type); } +#define get_textarea_form(t) _get_textarea_form(__LINE__,t) +static IHTMLFormElement *_get_textarea_form(unsigned line, IUnknown *unk) +{ + IHTMLTextAreaElement *textarea = _get_textarea_iface(line, unk); + IHTMLFormElement *form; + HRESULT hres; + + hres = IHTMLTextAreaElement_get_form(textarea, &form); + IHTMLTextAreaElement_Release(textarea); + ok_(__FILE__,line)(hres == S_OK, "get_type failed: %08x\n", hres); + + return form; +} + #define test_comment_text(c,t) _test_comment_text(__LINE__,c,t) static void _test_comment_text(unsigned line, IUnknown *unk, const char *extext) { @@ -2133,6 +2148,17 @@ } } +#define test_range_paste_html(a,b) _test_range_paste_html(__LINE__,a,b) +static void _test_range_paste_html(unsigned line, IHTMLTxtRange *range, const char *html) +{ + BSTR str = a2bstr(html); + HRESULT hres; + + hres = IHTMLTxtRange_pasteHTML(range, str); + ok_(__FILE__,line)(hres == S_OK, "pasteHTML failed: %08x\n", hres); + SysFreeString(str); +} + #define test_range_parent(r,t) _test_range_parent(__LINE__,r,t) static void _test_range_parent(unsigned line, IHTMLTxtRange *range, elem_type_t type) { @@ -2680,6 +2706,39 @@ _test_select_get_disabled(line, select, b); } +#define test_elem_dir(u,n) _test_elem_dir(__LINE__,u,n) +static void _test_elem_dir(unsigned line, IUnknown *unk, const char *exdir) +{ + IHTMLElement2 *elem = _get_elem2_iface(line, unk); + BSTR dir; + HRESULT hres; + + hres = IHTMLElement2_get_dir(elem, &dir); + IHTMLElement2_Release(elem); + ok_(__FILE__, line) (hres == S_OK, "get_dir failed: %08x\n", hres); + if(exdir) + ok_(__FILE__, line) (!strcmp_wa(dir, exdir), "got dir: %s, expected %s\n", wine_dbgstr_w(dir), exdir); + else + ok_(__FILE__, line) (!dir, "got dir: %s, expected NULL\n", wine_dbgstr_w(dir)); + + SysFreeString(dir); +} + +#define set_elem_dir(u,n) _set_elem_dir(__LINE__,u,n) +static void _set_elem_dir(unsigned line, IUnknown *unk, const char *dira) +{ + IHTMLElement2 *elem = _get_elem2_iface(line, unk); + BSTR dir = a2bstr(dira); + HRESULT hres; + + hres = IHTMLElement2_put_dir(elem, dir); + IHTMLElement2_Release(elem); + ok_(__FILE__, line) (hres == S_OK, "put_dir failed: %08x\n", hres); + SysFreeString(dir); + + _test_elem_dir(line, unk, dira); +} + #define elem_get_scroll_height(u) _elem_get_scroll_height(__LINE__,u) static LONG _elem_get_scroll_height(unsigned line, IUnknown *unk) { @@ -3138,6 +3197,36 @@ SysFreeString(id); } +#define test_elem_language(e,i) _test_elem_language(__LINE__,e,i) +static void _test_elem_language(unsigned line, IHTMLElement *elem, const char *exlang) +{ + BSTR lang = (void*)0xdeadbeef; + HRESULT hres; + + hres = IHTMLElement_get_language(elem, &lang); + ok_(__FILE__,line) (hres == S_OK, "get_language failed: %08x\n", hres); + + if(exlang) + ok_(__FILE__,line) (!strcmp_wa(lang, exlang), "unexpected language %s\n", wine_dbgstr_w(lang)); + else + ok_(__FILE__,line) (!lang, "language=%s\n", wine_dbgstr_w(lang)); + + SysFreeString(lang); +} + +#define set_elem_language(e,i) _set_elem_language(__LINE__,e,i) +static void _set_elem_language(unsigned line, IHTMLElement *elem, const char *lang) +{ + BSTR str = a2bstr(lang); + HRESULT hres; + + hres = IHTMLElement_put_language(elem, str); + ok_(__FILE__,line) (hres == S_OK, "get_language failed: %08x\n", hres); + SysFreeString(str); + + _test_elem_language(line, elem, lang); +} + #define test_elem_put_id(u,i) _test_elem_put_id(__LINE__,u,i) static void _test_elem_put_id(unsigned line, IUnknown *unk, const char *new_id) { @@ -4778,10 +4867,13 @@ IHTMLTxtRange *body_range, *range, *range2; IHTMLSelectionObject *selection; IDispatch *disp_range; + IHTMLElement *body; HRESULT hres; body_range = test_create_body_range(doc); + test_disp((IUnknown*)body_range, &IID_IHTMLTxtRange, "[object]"); + test_range_text(body_range, "test abc 123\r\nit's text"); hres = IHTMLTxtRange_duplicate(body_range, &range); @@ -4928,6 +5020,8 @@ hres = IHTMLDocument2_get_selection(doc, &selection); ok(hres == S_OK, "IHTMLDocument2_get_selection failed: %08x\n", hres); + test_disp((IUnknown*)selection, &IID_IHTMLSelectionObject, "[object]"); + hres = IHTMLSelectionObject_createRange(selection, &disp_range); ok(hres == S_OK, "IHTMLSelectionObject_createRange failed: %08x\n", hres); IHTMLSelectionObject_Release(selection); @@ -4959,6 +5053,32 @@ test_range_moveend(range, characterW, 2, 2); test_range_text(range, "ab"); + body = doc_get_body(doc); + + hres = IHTMLTxtRange_moveToElementText(range, body); + ok(hres == S_OK, "moveToElementText failed: %08x\n", hres); + + test_range_text(range, "abc xyz abc 123\r\nit's text"); + test_range_parent(range, ET_BODY); + + test_range_move(range, wordW, 1, 1); + test_range_moveend(range, characterW, 12, 12); + test_range_text(range, "xyz abc 123"); + + test_range_collapse(range, VARIANT_TRUE); + test_range_paste_html(range, "
paste
"); + test_range_text(range, NULL); + + test_range_moveend(range, characterW, 3, 3); + test_range_text(range, "xyz"); + + hres = IHTMLTxtRange_moveToElementText(range, body); + ok(hres == S_OK, "moveToElementText failed: %08x\n", hres); + + test_range_text(range, "abc \r\npaste\r\nxyz abc 123\r\nit's text"); + + IHTMLElement_Release(body); + IHTMLTxtRange_Release(range); } @@ -5580,6 +5700,9 @@ ok(!l, "scrollTop = %d\n", l); elem_get_scroll_left((IUnknown*)body); + test_elem_dir((IUnknown*)body, NULL); + set_elem_dir((IUnknown*)body, "ltr"); + /* get_text tests */ hres = IHTMLBodyElement_get_text(body, &v); ok(hres == S_OK, "expect S_OK got 0x%08d\n", hres); @@ -6290,6 +6413,23 @@ VariantClear(&v); } +#define test_table_cell_padding(a,b) _test_table_cell_padding(__LINE__,a,b) +static void _test_table_cell_padding(unsigned line, IHTMLTable *table, const char *exstr) +{ + VARIANT v; + HRESULT hres; + + V_VT(&v) = VT_ERROR; + hres = IHTMLTable_get_cellPadding(table, &v); + ok_(__FILE__,line)(hres == S_OK, "get_cellPadding failed: %08x\n", hres); + ok_(__FILE__,line)(V_VT(&v) == VT_BSTR, "V_VT(v) = %d\n", V_VT(&v)); + if(exstr) + ok_(__FILE__,line)(!strcmp_wa(V_BSTR(&v), exstr), "cellPadding = %s, expected %s\n", wine_dbgstr_w(V_BSTR(&v)), exstr); + else + ok_(__FILE__,line)(!V_BSTR(&v), "cellPadding = %s, expected NULL\n", wine_dbgstr_w(V_BSTR(&v))); + VariantClear(&v); +} + static void test_table_modify(IHTMLTable *table) { IDispatch *disp; @@ -6392,6 +6532,27 @@ test_table_cell_spacing(table, "11"); VariantClear(&v); + test_table_cell_padding(table, NULL); + + V_VT(&v) = VT_I4; + V_I4(&v) = 10; + hres = IHTMLTable_put_cellPadding(table, v); + ok(hres == S_OK, "put_cellPadding = %08x\n", hres); + test_table_cell_padding(table, "10"); + + V_VT(&v) = VT_BSTR; + V_BSTR(&v) = a2bstr("11"); + hres = IHTMLTable_put_cellPadding(table, v); + ok(hres == S_OK, "put_cellPadding = %08x\n", hres); + test_table_cell_padding(table, "11"); + VariantClear(&v); + + V_VT(&v) = VT_R8; + V_R8(&v) = 5; + hres = IHTMLTable_put_cellPadding(table, v); + ok(hres == S_OK, "put_cellPadding = %08x\n", hres); + test_table_cell_padding(table, "5"); + bstr = a2bstr("left"); hres = IHTMLTable_put_align(table, bstr); ok(hres == S_OK, "set_align failed: %08x\n", hres); @@ -6486,7 +6647,6 @@ ok(!strcmp_wa(V_BSTR(&v), "11"), "Expected 11, got %s\n", wine_dbgstr_w(V_BSTR(&v))); VariantClear(&v); - bstr = a2bstr("box"); hres = IHTMLTable_put_frame(table, bstr); ok(hres == S_OK, "put_frame = %08x\n", hres); @@ -7135,6 +7295,8 @@ hres = IHTMLElement_QueryInterface(elem, &IID_IHTMLScriptElement, (void**)&script); ok(hres == S_OK, "Could not get IHTMLScriptElement interface: %08x\n", hres); + test_elem_language(elem, NULL); + if(hres == S_OK) { VARIANT_BOOL vb; @@ -7174,6 +7336,9 @@ } IHTMLScriptElement_Release(script); + + set_elem_language(elem, "vbscript"); + set_elem_language(elem, "xxx"); } elem = get_elem_by_id(doc, "in", TRUE); @@ -7563,6 +7728,9 @@ IHTMLElement_Release(elem2); IHTMLElement_Release(elem); + hres = IHTMLDocument3_recalc(doc3, VARIANT_TRUE); + ok(hres == S_OK, "recalc failed: %08x\n", hres); + IHTMLDocument3_Release(doc3); elem = get_elem_by_id(doc, "s", TRUE); @@ -7771,12 +7939,35 @@ test_elem_set_innerhtml((IUnknown*)div, ""); elem = get_elem_by_id(doc, "ta", TRUE); if(elem) { + IHTMLFormElement *form; + test_textarea_value((IUnknown*)elem, NULL); test_textarea_put_value((IUnknown*)elem, "test"); test_textarea_readonly((IUnknown*)elem, VARIANT_FALSE); test_textarea_put_readonly((IUnknown*)elem, VARIANT_TRUE); test_textarea_put_readonly((IUnknown*)elem, VARIANT_FALSE); test_textarea_type((IUnknown*)elem); + + form = get_textarea_form((IUnknown*)elem); + ok(!form, "form = %p\n", form); + + IHTMLElement_Release(elem); + } + + test_elem_set_innerhtml((IUnknown*)div, "
"); + elem = get_elem_by_id(doc, "ta", TRUE); + if(elem) { + IHTMLFormElement *form; + + elem2 = get_elem_by_id(doc, "fid", TRUE); + ok(elem2 != NULL, "elem2 == NULL\n"); + + form = get_textarea_form((IUnknown*)elem); + ok(form != NULL, "form = NULL\n"); + ok(iface_cmp((IUnknown*)form, (IUnknown*)elem2), "form != elem2\n"); + + IHTMLFormElement_Release(form); + IHTMLElement_Release(elem2); IHTMLElement_Release(elem); } diff -Nru wine1.7-1.7.28/dlls/mshtml/tests/jstest.html wine1.7-1.7.31/dlls/mshtml/tests/jstest.html --- wine1.7-1.7.28/dlls/mshtml/tests/jstest.html 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/tests/jstest.html 2014-11-14 13:28:17.000000000 +0000 @@ -215,6 +215,14 @@ "t.rows[0].cells[0].childNodes.length = " + t.rows[0].cells[0].childNodes.length); } +function test_language_attribute() { + document.body.innerHTML = '
'; + var elem = document.getElementById("did"); + ok(elem.language === "test", "elem.language = " + elem.language); + elem.language = 1; + ok(elem.language === "1", "elem.language = " + elem.language); +} + var globalVar = false; function runTests() { @@ -238,6 +246,7 @@ test_forin(); test_customtag(); test_whitespace_nodes(); + test_language_attribute(); var r = window.execScript("globalVar = true;"); ok(r === undefined, "execScript returned " + r); diff -Nru wine1.7-1.7.28/dlls/mshtml/tests/nav_test.html wine1.7-1.7.31/dlls/mshtml/tests/nav_test.html --- wine1.7-1.7.28/dlls/mshtml/tests/nav_test.html 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/tests/nav_test.html 2014-11-14 13:28:17.000000000 +0000 @@ -34,7 +34,7 @@ var iframe = document.getElementById("testframe"); iframe.onload = function() { - iframe.onlod = null; + iframe.onload = null; var href = iframe.contentWindow.location.href; ok(href === "about:blank", "Unexpected href " + href); next_test(); diff -Nru wine1.7-1.7.28/dlls/mshtml/tests/protocol.c wine1.7-1.7.31/dlls/mshtml/tests/protocol.c --- wine1.7-1.7.28/dlls/mshtml/tests/protocol.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/tests/protocol.c 2014-11-14 13:28:17.000000000 +0000 @@ -137,13 +137,16 @@ { CHECK_EXPECT(ReportResult); - if(expect_hr_win32err) + if(expect_hr_win32err) { ok((hrResult&0xffff0000) == ((FACILITY_WIN32 << 16)|0x80000000) || expect_hrResult, "expected win32 err or %08x got: %08x\n", expect_hrResult, hrResult); - else - ok(hrResult == expect_hrResult || ((expect_hrResult == E_INVALIDARG || - expect_hrResult == HRESULT_FROM_WIN32(ERROR_RESOURCE_TYPE_NOT_FOUND)) && - hrResult == MK_E_SYNTAX), "expected: %08x got: %08x\n", expect_hrResult, hrResult); + }else { + ok(hrResult == expect_hrResult || (expect_hrResult == E_INVALIDARG && hrResult == MK_E_SYNTAX) + || (expect_hrResult == HRESULT_FROM_WIN32(ERROR_RESOURCE_TYPE_NOT_FOUND) && + (hrResult == MK_E_SYNTAX || hrResult == HRESULT_FROM_WIN32(ERROR_DLL_NOT_FOUND))), + "expected: %08x got: %08x\n", expect_hrResult, hrResult); + expect_hrResult = hrResult; + } ok(dwError == 0, "dwError = %d\n", dwError); ok(!szResult, "szResult != NULL\n"); @@ -232,9 +235,7 @@ ok((hres&0xffff0000) == ((FACILITY_WIN32 << 16)|0x80000000) || hres == expect_hrResult, "expected win32 err or %08x got: %08x\n", expected_hres, hres); else - ok(hres == expected_hres || ((expected_hres == E_INVALIDARG || - expected_hres == HRESULT_FROM_WIN32(ERROR_RESOURCE_TYPE_NOT_FOUND)) && hres == MK_E_SYNTAX), - "expected: %08x got: %08x\n", expected_hres, hres); + ok(hres == expect_hrResult, "expected: %08x got: %08x\n", expect_hrResult, hres); CHECK_CALLED(GetBindInfo); CHECK_CALLED(ReportResult); @@ -601,6 +602,13 @@ test_res_url("/jstest.html"); test_res_url("/Test/res.html"); test_res_url("/test/dir/dir2/res.html"); + + if(GetProcAddress(LoadLibraryA("urlmon.dll"), "CreateUri")) { + test_res_url("/test/dir/dir2/res.html?query_part"); + test_res_url("/test/dir/dir2/res.html#hash_part"); + }else { + win_skip("IUri not supported\n"); + } } static void do_test_about_protocol(IClassFactory *factory, DWORD bf) diff -Nru wine1.7-1.7.28/dlls/mshtml/tests/style.c wine1.7-1.7.31/dlls/mshtml/tests/style.c --- wine1.7-1.7.28/dlls/mshtml/tests/style.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/tests/style.c 2014-11-14 13:28:17.000000000 +0000 @@ -548,6 +548,82 @@ hres = IHTMLStyle5_put_minWidth(style5, vdefault); ok(hres == S_OK, "put_minWidth failed: %08x\n", hres); VariantClear(&vdefault); + + /* maxWidth */ + hres = IHTMLStyle5_get_maxWidth(style5, &vdefault); + ok(hres == S_OK, "get_maxWidth failed: %08x\n", hres); + + V_VT(&v) = VT_BSTR; + V_BSTR(&v) = a2bstr("200px"); + hres = IHTMLStyle5_put_maxWidth(style5, v); + ok(hres == S_OK, "put_maxWidth failed: %08x\n", hres); + VariantClear(&v); + + hres = IHTMLStyle5_get_maxWidth(style5, &v); + ok(hres == S_OK, "get_maxWidth failed: %08x\n", hres); + ok(V_VT(&v) == VT_BSTR, "V_VT(v) = %d\n",V_VT(&v)); + ok(!strcmp_wa(V_BSTR(&v), "200px"), "expect 200px got (%s)\n", wine_dbgstr_w(V_BSTR(&v))); + VariantClear(&v); + + V_VT(&v) = VT_BSTR; + V_BSTR(&v) = a2bstr("70%"); + hres = IHTMLStyle5_put_maxWidth(style5, v); + ok(hres == S_OK, "put_maxWidth failed: %08x\n", hres); + VariantClear(&v); + + hres = IHTMLStyle5_get_maxWidth(style5, &v); + ok(hres == S_OK, "get maxWidth failed: %08x\n", hres); + ok(V_VT(&v) == VT_BSTR, "V_VT(v) = %d\n", V_VT(&v)); + ok(!strcmp_wa(V_BSTR(&v), "70%"), "expect 70%% got (%s)\n", wine_dbgstr_w(V_BSTR(&v))); + VariantClear(&v); + + hres = IHTMLStyle5_put_maxWidth(style5,vdefault); + ok(hres == S_OK, "put_maxWidth failed: %08x\n", hres); + VariantClear(&vdefault); + + /* maxHeight */ + hres = IHTMLStyle5_get_maxHeight(style5, &vdefault); + ok(hres == S_OK, "get maxHeight failed: %08x\n", hres); + + V_VT(&v) = VT_BSTR; + V_BSTR(&v) = a2bstr("200px"); + hres = IHTMLStyle5_put_maxHeight(style5, v); + ok(hres == S_OK, "put maxHeight failed: %08x\n", hres); + VariantClear(&v); + + hres = IHTMLStyle5_get_maxHeight(style5, &v); + ok(hres == S_OK, "get maxHeight failed: %08x\n", hres); + ok(V_VT(&v) == VT_BSTR, "V_VT(v) = %d\n", V_VT(&v)); + ok(!strcmp_wa(V_BSTR(&v), "200px"), "expect 200px got (%s)\n", wine_dbgstr_w(V_BSTR(&v))); + VariantClear(&v); + + V_VT(&v) = VT_BSTR; + V_BSTR(&v) = a2bstr("70%"); + hres = IHTMLStyle5_put_maxHeight(style5, v); + ok(hres == S_OK, "put maxHeight failed: %08x\n", hres); + VariantClear(&v); + + hres = IHTMLStyle5_get_maxHeight(style5, &v); + ok(hres == S_OK, "get_maxHeight failed: %08x\n", hres); + ok(V_VT(&v) == VT_BSTR, "V_VT(v) = %d\n", V_VT(&v)); + ok(!strcmp_wa(V_BSTR(&v), "70%"), "expect 70%% got (%s)\n", wine_dbgstr_w(V_BSTR(&v))); + VariantClear(&v); + + V_VT(&v) = VT_BSTR; + V_BSTR(&v) = a2bstr("100"); + hres = IHTMLStyle5_put_maxHeight(style5, v); + ok(hres == S_OK, "put maxHeight failed: %08x\n", hres); + VariantClear(&v); + + hres = IHTMLStyle5_get_maxHeight(style5, &v); + ok(hres == S_OK, "get_maxHeight failed: %08x\n", hres); + ok(V_VT(&v) == VT_BSTR, "V_VT(v) = %d\n", V_VT(&v)); + ok(!strcmp_wa(V_BSTR(&v), "100px"), "expect 100 got (%s)\n", wine_dbgstr_w(V_BSTR(&v))); + VariantClear(&v); + + hres = IHTMLStyle5_put_maxHeight(style5, vdefault); + ok(hres == S_OK, "put maxHeight failed:%08x\n", hres); + VariantClear(&vdefault); } static void test_style6(IHTMLStyle6 *style) diff -Nru wine1.7-1.7.28/dlls/mshtml/txtrange.c wine1.7-1.7.31/dlls/mshtml/txtrange.c --- wine1.7-1.7.28/dlls/mshtml/txtrange.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/mshtml/txtrange.c 2014-11-14 13:28:17.000000000 +0000 @@ -17,6 +17,7 @@ */ #include +#include #define COBJMACROS @@ -36,6 +37,7 @@ static const WCHAR hrW[] = {'h','r',0}; typedef struct { + DispatchEx dispex; IHTMLTxtRange IHTMLTxtRange_iface; IOleCommandTarget IOleCommandTarget_iface; @@ -1004,29 +1006,24 @@ { HTMLTxtRange *This = impl_from_IHTMLTxtRange(iface); - *ppv = NULL; + TRACE("(%p)->(%s %p)\n", This, debugstr_mshtml_guid(riid), ppv); if(IsEqualGUID(&IID_IUnknown, riid)) { - TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv); - *ppv = &This->IHTMLTxtRange_iface; - }else if(IsEqualGUID(&IID_IDispatch, riid)) { - TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv); *ppv = &This->IHTMLTxtRange_iface; }else if(IsEqualGUID(&IID_IHTMLTxtRange, riid)) { - TRACE("(%p)->(IID_IHTMLTxtRange %p)\n", This, ppv); *ppv = &This->IHTMLTxtRange_iface; }else if(IsEqualGUID(&IID_IOleCommandTarget, riid)) { - TRACE("(%p)->(IID_IOleCommandTarget %p)\n", This, ppv); *ppv = &This->IOleCommandTarget_iface; + }else if(dispex_query_interface(&This->dispex, riid, ppv)) { + return *ppv ? S_OK : E_NOINTERFACE; + }else { + *ppv = NULL; + WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); + return E_NOINTERFACE; } - if(*ppv) { - IUnknown_AddRef((IUnknown*)*ppv); - return S_OK; - } - - WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv); - return E_NOINTERFACE; + IUnknown_AddRef((IUnknown*)*ppv); + return S_OK; } static ULONG WINAPI HTMLTxtRange_AddRef(IHTMLTxtRange *iface) @@ -1051,6 +1048,7 @@ nsIDOMRange_Release(This->nsrange); if(This->doc) list_remove(&This->entry); + release_dispex(&This->dispex); heap_free(This); } @@ -1060,16 +1058,16 @@ static HRESULT WINAPI HTMLTxtRange_GetTypeInfoCount(IHTMLTxtRange *iface, UINT *pctinfo) { HTMLTxtRange *This = impl_from_IHTMLTxtRange(iface); - FIXME("(%p)->(%p)\n", This, pctinfo); - return E_NOTIMPL; + + return IDispatchEx_GetTypeInfoCount(&This->dispex.IDispatchEx_iface, pctinfo); } static HRESULT WINAPI HTMLTxtRange_GetTypeInfo(IHTMLTxtRange *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) { HTMLTxtRange *This = impl_from_IHTMLTxtRange(iface); - FIXME("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo); - return E_NOTIMPL; + + return IDispatchEx_GetTypeInfo(&This->dispex.IDispatchEx_iface, iTInfo, lcid, ppTInfo); } static HRESULT WINAPI HTMLTxtRange_GetIDsOfNames(IHTMLTxtRange *iface, REFIID riid, @@ -1077,9 +1075,9 @@ LCID lcid, DISPID *rgDispId) { HTMLTxtRange *This = impl_from_IHTMLTxtRange(iface); - FIXME("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, - lcid, rgDispId); - return E_NOTIMPL; + + return IDispatchEx_GetIDsOfNames(&This->dispex.IDispatchEx_iface, riid, rgszNames, + cNames, lcid, rgDispId); } static HRESULT WINAPI HTMLTxtRange_Invoke(IHTMLTxtRange *iface, DISPID dispIdMember, @@ -1087,9 +1085,9 @@ VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) { HTMLTxtRange *This = impl_from_IHTMLTxtRange(iface); - FIXME("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid), - lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); - return E_NOTIMPL; + + return IDispatchEx_Invoke(&This->dispex.IDispatchEx_iface, dispIdMember, riid, + lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); } static HRESULT WINAPI HTMLTxtRange_get_htmlText(IHTMLTxtRange *iface, BSTR *p) @@ -1575,15 +1573,54 @@ static HRESULT WINAPI HTMLTxtRange_pasteHTML(IHTMLTxtRange *iface, BSTR html) { HTMLTxtRange *This = impl_from_IHTMLTxtRange(iface); - FIXME("(%p)->(%s)\n", This, debugstr_w(html)); - return E_NOTIMPL; + nsIDOMDocumentFragment *doc_frag; + nsAString nsstr; + nsresult nsres; + + TRACE("(%p)->(%s)\n", This, debugstr_w(html)); + + nsres = nsIDOMRange_Collapse(This->nsrange, TRUE); + assert(nsres == NS_OK); + + nsAString_InitDepend(&nsstr, html); + nsres = nsIDOMRange_CreateContextualFragment(This->nsrange, &nsstr, &doc_frag); + nsAString_Finish(&nsstr); + if(NS_FAILED(nsres)) { + ERR("CreateContextualFragment failed: %08x\n", nsres); + return E_FAIL; + } + + nsres = nsIDOMRange_InsertNode(This->nsrange, (nsIDOMNode*)doc_frag); + nsIDOMDocumentFragment_Release(doc_frag); + if(NS_FAILED(nsres)) { + ERR("InsertNode failed: %08x\n", nsres); + return E_FAIL; + } + + nsres = nsIDOMRange_Collapse(This->nsrange, FALSE); + assert(nsres == NS_OK); + return S_OK; } static HRESULT WINAPI HTMLTxtRange_moveToElementText(IHTMLTxtRange *iface, IHTMLElement *element) { HTMLTxtRange *This = impl_from_IHTMLTxtRange(iface); - FIXME("(%p)->(%p)\n", This, element); - return E_NOTIMPL; + HTMLElement *elem; + nsresult nsres; + + TRACE("(%p)->(%p)\n", This, element); + + elem = unsafe_impl_from_IHTMLElement(element); + if(!elem) + return E_INVALIDARG; + + nsres = nsIDOMRange_SelectNodeContents(This->nsrange, elem->node.nsnode); + if(NS_FAILED(nsres)) { + ERR("SelectNodeContents failed: %08x\n", nsres); + return E_FAIL; + } + + return S_OK; } static HRESULT WINAPI HTMLTxtRange_setEndPoint(IHTMLTxtRange *iface, BSTR how, @@ -1850,6 +1887,17 @@ RangeCommandTarget_Exec }; +static const tid_t HTMLTxtRange_iface_tids[] = { + IHTMLTxtRange_tid, + 0 +}; +static dispex_static_data_t HTMLTxtRange_dispex = { + NULL, + IHTMLTxtRange_tid, + NULL, + HTMLTxtRange_iface_tids +}; + HRESULT HTMLTxtRange_Create(HTMLDocumentNode *doc, nsIDOMRange *nsrange, IHTMLTxtRange **p) { HTMLTxtRange *ret; @@ -1858,6 +1906,8 @@ if(!ret) return E_OUTOFMEMORY; + init_dispex(&ret->dispex, (IUnknown*)&ret->IHTMLTxtRange_iface, &HTMLTxtRange_dispex); + ret->IHTMLTxtRange_iface.lpVtbl = &HTMLTxtRangeVtbl; ret->IOleCommandTarget_iface.lpVtbl = &OleCommandTargetVtbl; ret->ref = 1; diff -Nru wine1.7-1.7.28/dlls/msi/action.c wine1.7-1.7.31/dlls/msi/action.c --- wine1.7-1.7.28/dlls/msi/action.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/action.c 2014-11-14 13:28:17.000000000 +0000 @@ -2438,9 +2438,9 @@ return MSI_SetFeatureStates(package); } -static BYTE *parse_value( MSIPACKAGE *package, const WCHAR *value, DWORD *type, DWORD *size ) +static BYTE *parse_value( MSIPACKAGE *package, const WCHAR *value, DWORD len, DWORD *type, DWORD *size ) { - BYTE *data = NULL; + BYTE *data; if (!value) { @@ -2529,19 +2529,18 @@ else { const WCHAR *ptr = value; - DWORD len; *type = REG_SZ; if (value[0] == '#') { - ptr++; + ptr++; len--; if (value[1] == '%') { - ptr++; + ptr++; len--; *type = REG_EXPAND_SZ; } } - len = deformat_string( package, ptr, (WCHAR **)&data ); + data = (BYTE *)msi_strdupW( ptr, len ); if (len > strlenW( (const WCHAR *)data )) *type = REG_MULTI_SZ; *size = (len + 1) * sizeof(WCHAR); } @@ -2872,14 +2871,11 @@ msi_free(keypath); return ERROR_FUNCTION_FAILED; } - str = msi_record_get_string( row, 5, &len ); - if (str && len > strlenW( str )) - { - type = REG_MULTI_SZ; - new_size = (len + 1) * sizeof(WCHAR); - new_value = (BYTE *)msi_strdupW( str, len ); - } - else new_value = parse_value( package, str, &type, &new_size ); + str = msi_record_get_string( row, 5, NULL ); + len = deformat_string( package, str, &deformated ); + new_value = parse_value( package, deformated, len, &type, &new_size ); + + msi_free( deformated ); deformat_string(package, name, &deformated); if (!is_special_entry( name )) @@ -5316,7 +5312,7 @@ WCHAR *remove; /* first do the same as an InstallExecute */ - rc = ACTION_InstallExecute(package); + rc = execute_script(package, SCRIPT_INSTALL); if (rc != ERROR_SUCCESS) return rc; @@ -7817,10 +7813,7 @@ package->full_reinstall = 1; } - /* properties may have been added by a transform */ - msi_clone_properties( package ); msi_set_original_database_property( package->db, szPackagePath ); - msi_parse_command_line( package, szCommandLine, FALSE ); msi_adjust_privilege_properties( package ); msi_set_context( package ); diff -Nru wine1.7-1.7.28/dlls/msi/assembly.c wine1.7-1.7.31/dlls/msi/assembly.c --- wine1.7-1.7.28/dlls/msi/assembly.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/assembly.c 2014-11-14 13:28:17.000000000 +0000 @@ -251,7 +251,7 @@ memset( &info, 0, sizeof(info) ); info.cbAssemblyInfo = sizeof(info); hr = IAssemblyCache_QueryAssemblyInfo( cache, 0, display_name, &info ); - if (hr == S_OK /* sxs version */ || hr == HRESULT_FROM_WIN32( ERROR_INSUFFICIENT_BUFFER )) + if (hr == S_OK /* sxs version */ || hr == E_NOT_SUFFICIENT_BUFFER) { return (info.dwAssemblyFlags == ASSEMBLYINFO_FLAG_INSTALLED); } @@ -357,7 +357,7 @@ if (!pGetFileVersion) return CLR_VERSION_V10; hr = pGetFileVersion( filename, NULL, 0, &len ); - if (hr != HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER)) return CLR_VERSION_V11; + if (hr != E_NOT_SUFFICIENT_BUFFER) return CLR_VERSION_V11; if ((strW = msi_alloc( len * sizeof(WCHAR) ))) { hr = pGetFileVersion( filename, strW, len, &len ); diff -Nru wine1.7-1.7.28/dlls/msi/dialog.c wine1.7-1.7.31/dlls/msi/dialog.c --- wine1.7-1.7.28/dlls/msi/dialog.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/dialog.c 2014-11-14 13:28:17.000000000 +0000 @@ -155,7 +155,6 @@ static const WCHAR szVolumeSelectCombo[] = { 'V','o','l','u','m','e','S','e','l','e','c','t','C','o','m','b','o',0 }; static const WCHAR szSelectionDescription[] = {'S','e','l','e','c','t','i','o','n','D','e','s','c','r','i','p','t','i','o','n',0}; static const WCHAR szSelectionPath[] = {'S','e','l','e','c','t','i','o','n','P','a','t','h',0}; -static const WCHAR szProperty[] = {'P','r','o','p','e','r','t','y',0}; static const WCHAR szHyperLink[] = {'H','y','p','e','r','L','i','n','k',0}; /* dialog sequencing */ @@ -2172,7 +2171,7 @@ /* FIXME: test when this should fail */ static BOOL msi_dialog_verify_path( LPWSTR path ) { - if ( !lstrlenW( path ) ) + if ( !path[0] ) return FALSE; if ( PathIsRelativeW( path ) ) diff -Nru wine1.7-1.7.28/dlls/msi/media.c wine1.7-1.7.31/dlls/msi/media.c --- wine1.7-1.7.28/dlls/msi/media.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/media.c 2014-11-14 13:28:17.000000000 +0000 @@ -298,9 +298,6 @@ mi->cabinet = strdupW(MSI_RecordGetString(row, 4)); mi->volume_label = strdupW(MSI_RecordGetString(row, 5)); - if (!mi->first_volume) - mi->first_volume = strdupW(mi->volume_label); - msiobj_release(&row->hdr); return ERROR_SUCCESS; } @@ -673,7 +670,6 @@ msi_free(mi->disk_prompt); msi_free(mi->cabinet); msi_free(mi->volume_label); - msi_free(mi->first_volume); msi_free(mi); } @@ -719,9 +715,6 @@ mi->volume_label = strdupW(MSI_RecordGetString(row, 5)); msiobj_release(&row->hdr); - if (!mi->first_volume) - mi->first_volume = strdupW(mi->volume_label); - msi_set_sourcedir_props(package, FALSE); source_dir = msi_dup_property(package->db, szSourceDir); lstrcpyW(mi->sourcedir, source_dir); @@ -891,7 +884,7 @@ } } /* check volume matches, change media if not */ - if (mi->volume_label && mi->disk_id > 1 && strcmpW( mi->first_volume, mi->volume_label )) + if (mi->volume_label && mi->disk_id > 1) { WCHAR *source = msi_dup_property( package->db, szSourceDir ); BOOL match = source_matches_volume( mi, source ); diff -Nru wine1.7-1.7.28/dlls/msi/msi.c wine1.7-1.7.31/dlls/msi/msi.c --- wine1.7-1.7.28/dlls/msi/msi.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/msi.c 2014-11-14 13:28:17.000000000 +0000 @@ -1762,10 +1762,6 @@ datakey = patch; szProperty = szInstalled; } - else if (!strcmpW( szProperty, INSTALLPROPERTY_LOCALPACKAGEW )) - { - datakey = udpatch; - } else if (!strcmpW( szProperty, INSTALLPROPERTY_UNINSTALLABLEW ) || !strcmpW( szProperty, INSTALLPROPERTY_PATCHSTATEW ) || !strcmpW( szProperty, INSTALLPROPERTY_DISPLAYNAMEW ) || @@ -4248,3 +4244,21 @@ FIXME("%p,%p,%p,%08x\n", a, b, c, d); return ERROR_SUCCESS; } + +/*********************************************************************** + * MsiRemovePatchesA [MSI.@] + */ +UINT WINAPI MsiRemovePatchesA(LPCSTR patchlist, LPCSTR product, INSTALLTYPE type, LPCSTR propertylist) +{ + FIXME("(%s %s %d %s\n", debugstr_a(patchlist), debugstr_a(product), type, debugstr_a(propertylist)); + return ERROR_SUCCESS; +} + +/*********************************************************************** + * MsiRemovePatchesW [MSI.@] + */ +UINT WINAPI MsiRemovePatchesW(LPCWSTR patchlist, LPCWSTR product, INSTALLTYPE type, LPCWSTR propertylist) +{ + FIXME("(%s %s %d %s\n", debugstr_w(patchlist), debugstr_w(product), type, debugstr_w(propertylist)); + return ERROR_SUCCESS; +} diff -Nru wine1.7-1.7.28/dlls/msi/msipriv.h wine1.7-1.7.31/dlls/msi/msipriv.h --- wine1.7-1.7.28/dlls/msi/msipriv.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/msipriv.h 2014-11-14 13:28:17.000000000 +0000 @@ -154,7 +154,6 @@ UINT last_sequence; LPWSTR disk_prompt; LPWSTR cabinet; - LPWSTR first_volume; LPWSTR volume_label; BOOL is_continuous; BOOL is_extracted; @@ -865,7 +864,7 @@ extern UINT msi_download_file( LPCWSTR szUrl, LPWSTR filename ) DECLSPEC_HIDDEN; extern UINT msi_package_add_info(MSIPACKAGE *, DWORD, DWORD, LPCWSTR, LPWSTR) DECLSPEC_HIDDEN; extern UINT msi_package_add_media_disk(MSIPACKAGE *, DWORD, DWORD, DWORD, LPWSTR, LPWSTR) DECLSPEC_HIDDEN; -extern UINT msi_clone_properties(MSIPACKAGE *) DECLSPEC_HIDDEN; +extern UINT msi_clone_properties(MSIDATABASE *) DECLSPEC_HIDDEN; extern UINT msi_set_context(MSIPACKAGE *) DECLSPEC_HIDDEN; extern void msi_adjust_privilege_properties(MSIPACKAGE *) DECLSPEC_HIDDEN; extern UINT MSI_GetFeatureCost(MSIPACKAGE *, MSIFEATURE *, MSICOSTTREE, INSTALLSTATE, LPINT) DECLSPEC_HIDDEN; @@ -941,6 +940,7 @@ extern INT msi_suminfo_get_int32( MSISUMMARYINFO *si, UINT uiProperty ) DECLSPEC_HIDDEN; extern LPWSTR msi_get_suminfo_product( IStorage *stg ) DECLSPEC_HIDDEN; extern UINT msi_add_suminfo( MSIDATABASE *db, LPWSTR **records, int num_records, int num_columns ) DECLSPEC_HIDDEN; +extern enum platform parse_platform( const WCHAR *str ) DECLSPEC_HIDDEN; /* undocumented functions */ UINT WINAPI MsiCreateAndVerifyInstallerDirectory( DWORD ); @@ -1180,6 +1180,7 @@ static const WCHAR szData[] = {'D','a','t','a',0}; static const WCHAR szLangResource[] = {'\\','V','a','r','F','i','l','e','I','n','f','o','\\','T','r','a','n','s','l','a','t','i','o','n',0}; static const WCHAR szInstallLocation[] = {'I','n','s','t','a','l','l','L','o','c','a','t','i','o','n',0}; +static const WCHAR szProperty[] = {'P','r','o','p','e','r','t','y',0}; /* memory allocation macro functions */ static void *msi_alloc( size_t len ) __WINE_ALLOC_SIZE(1); diff -Nru wine1.7-1.7.28/dlls/msi/msi.spec wine1.7-1.7.31/dlls/msi/msi.spec --- wine1.7-1.7.28/dlls/msi/msi.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/msi.spec 2014-11-14 13:28:17.000000000 +0000 @@ -230,8 +230,8 @@ 234 stub MsiDeleteUserDataW 235 stub Migrate10CachedPackagesA 236 stdcall Migrate10CachedPackagesW(ptr ptr ptr long) -237 stub MsiRemovePatchesA -238 stub MsiRemovePatchesW +237 stdcall MsiRemovePatchesA(str str long str) +238 stdcall MsiRemovePatchesW(wstr wstr long wstr) 239 stdcall MsiApplyMultiplePatchesA(str str str) 240 stdcall MsiApplyMultiplePatchesW(wstr wstr wstr) 241 stub MsiExtractPatchXMLDataA diff -Nru wine1.7-1.7.28/dlls/msi/package.c wine1.7-1.7.31/dlls/msi/package.c --- wine1.7-1.7.28/dlls/msi/package.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/package.c 2014-11-14 13:28:17.000000000 +0000 @@ -386,7 +386,7 @@ return rc; } -UINT msi_clone_properties(MSIPACKAGE *package) +UINT msi_clone_properties( MSIDATABASE *db ) { static const WCHAR query_select[] = { 'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ', @@ -403,7 +403,7 @@ MSIQUERY *view_select; UINT rc; - rc = MSI_DatabaseOpenViewW( package->db, query_select, &view_select ); + rc = MSI_DatabaseOpenViewW( db, query_select, &view_select ); if (rc != ERROR_SUCCESS) return rc; @@ -424,7 +424,7 @@ if (rc != ERROR_SUCCESS) break; - rc = MSI_DatabaseOpenViewW( package->db, query_insert, &view_insert ); + rc = MSI_DatabaseOpenViewW( db, query_insert, &view_insert ); if (rc != ERROR_SUCCESS) { msiobj_release( &rec_select->hdr ); @@ -440,7 +440,7 @@ TRACE("insert failed, trying update\n"); - rc = MSI_DatabaseOpenViewW( package->db, query_update, &view_update ); + rc = MSI_DatabaseOpenViewW( db, query_update, &view_update ); if (rc != ERROR_SUCCESS) { WARN("open view failed %u\n", rc); @@ -1175,7 +1175,7 @@ package->BaseURL = strdupW( base_url ); create_temp_property_table( package ); - msi_clone_properties( package ); + msi_clone_properties( package->db ); msi_adjust_privilege_properties( package ); package->ProductCode = msi_dup_property( package->db, szProductCode ); @@ -1271,7 +1271,7 @@ return ERROR_SUCCESS; } -static enum platform parse_platform( WCHAR *str ) +enum platform parse_platform( const WCHAR *str ) { if (!str[0] || !strcmpW( str, szIntel )) return PLATFORM_INTEL; else if (!strcmpW( str, szIntel64 )) return PLATFORM_INTEL64; @@ -1677,11 +1677,8 @@ } index++; } - if (index) - { - msi_clone_properties( package ); - msi_adjust_privilege_properties( package ); - } + if (index) msi_adjust_privilege_properties( package ); + r = msi_set_original_database_property( package->db, szPackage ); if (r != ERROR_SUCCESS) { diff -Nru wine1.7-1.7.28/dlls/msi/patch.c wine1.7-1.7.31/dlls/msi/patch.c --- wine1.7-1.7.28/dlls/msi/patch.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/patch.c 2014-11-14 13:28:17.000000000 +0000 @@ -44,57 +44,220 @@ return FALSE; } +struct transform_desc +{ + WCHAR *product_code_from; + WCHAR *product_code_to; + WCHAR *version_from; + WCHAR *version_to; + WCHAR *upgrade_code; +}; + +static void free_transform_desc( struct transform_desc *desc ) +{ + msi_free( desc->product_code_from ); + msi_free( desc->product_code_to ); + msi_free( desc->version_from ); + msi_free( desc->version_to ); + msi_free( desc->upgrade_code ); + msi_free( desc ); +} + +static struct transform_desc *parse_transform_desc( const WCHAR *str ) +{ + struct transform_desc *ret; + const WCHAR *p = str, *q; + UINT len; + + if (!(ret = msi_alloc_zero( sizeof(*ret) ))) return NULL; + + q = strchrW( p, '}' ); + if (*p != '{' || !q) goto error; + + len = q - p + 1; + if (!(ret->product_code_from = msi_alloc( (len + 1) * sizeof(WCHAR) ))) goto error; + memcpy( ret->product_code_from, p, len * sizeof(WCHAR) ); + ret->product_code_from[len] = 0; + + p = q + 1; + if (!(q = strchrW( p, ';' ))) goto error; + len = q - p; + if (!(ret->version_from = msi_alloc( (len + 1) * sizeof(WCHAR) ))) goto error; + memcpy( ret->version_from, p, len * sizeof(WCHAR) ); + ret->version_from[len] = 0; + + p = q + 1; + q = strchrW( p, '}' ); + if (*p != '{' || !q) goto error; + + len = q - p + 1; + if (!(ret->product_code_to = msi_alloc( (len + 1) * sizeof(WCHAR) ))) goto error; + memcpy( ret->product_code_to, p, len * sizeof(WCHAR) ); + ret->product_code_to[len] = 0; + + p = q + 1; + if (!(q = strchrW( p, ';' ))) goto error; + len = q - p; + if (!(ret->version_to = msi_alloc( (len + 1) * sizeof(WCHAR) ))) goto error; + memcpy( ret->version_to, p, len * sizeof(WCHAR) ); + ret->version_to[len] = 0; + + p = q + 1; + q = strchrW( p, '}' ); + if (*p != '{' || !q) goto error; + + len = q - p + 1; + if (!(ret->upgrade_code = msi_alloc( (len + 1) * sizeof(WCHAR) ))) goto error; + memcpy( ret->upgrade_code, p, len * sizeof(WCHAR) ); + ret->upgrade_code[len] = 0; + + return ret; + +error: + free_transform_desc( ret ); + return NULL; +} + static UINT check_transform_applicable( MSIPACKAGE *package, IStorage *transform ) { + static const UINT supported_flags = + MSITRANSFORM_VALIDATE_PRODUCT | MSITRANSFORM_VALIDATE_LANGUAGE | + MSITRANSFORM_VALIDATE_PLATFORM | MSITRANSFORM_VALIDATE_MAJORVERSION | + MSITRANSFORM_VALIDATE_MINORVERSION | MSITRANSFORM_VALIDATE_UPGRADECODE; MSISUMMARYINFO *si = MSI_GetSummaryInformationW( transform, 0 ); UINT valid_flags = 0, wanted_flags = 0; + WCHAR *template, *product, *p; + struct transform_desc *desc; - if (si) wanted_flags = msi_suminfo_get_int32( si, PID_CHARCOUNT ); - TRACE("validation flags %x\n", wanted_flags); + if (!si) + { + WARN("no summary information!\n"); + return ERROR_FUNCTION_FAILED; + } + wanted_flags = msi_suminfo_get_int32( si, PID_CHARCOUNT ); + wanted_flags &= 0xffff; /* mask off error condition flags */ + TRACE("validation flags 0x%04x\n", wanted_flags); - if (wanted_flags & ~(MSITRANSFORM_VALIDATE_PRODUCT|MSITRANSFORM_VALIDATE_LANGUAGE)) - FIXME("unsupported validation flags %x\n", wanted_flags); + if (wanted_flags & ~supported_flags) + { + FIXME("unsupported validation flags 0x%04x\n", wanted_flags); + msiobj_release( &si->hdr ); + return ERROR_FUNCTION_FAILED; + } + if (!(template = msi_suminfo_dup_string( si, PID_TEMPLATE ))) + { + WARN("no template property!\n"); + msiobj_release( &si->hdr ); + return ERROR_FUNCTION_FAILED; + } + TRACE("template property: %s\n", debugstr_w(template)); + if (!(product = msi_get_suminfo_product( transform ))) + { + WARN("no product property!\n"); + msi_free( template ); + msiobj_release( &si->hdr ); + return ERROR_FUNCTION_FAILED; + } + TRACE("product property: %s\n", debugstr_w(product)); + if (!(desc = parse_transform_desc( product ))) + { + msi_free( template ); + msiobj_release( &si->hdr ); + return ERROR_FUNCTION_FAILED; + } + msi_free( product ); + if (wanted_flags & MSITRANSFORM_VALIDATE_LANGUAGE) + { + if (!template[0] || ((p = strchrW( template, ';' )) && match_language( package, atoiW( p + 1 ) ))) + { + valid_flags |= MSITRANSFORM_VALIDATE_LANGUAGE; + } + } if (wanted_flags & MSITRANSFORM_VALIDATE_PRODUCT) { - WCHAR *package_product = msi_dup_property( package->db, szProductCode ); - WCHAR *transform_product = msi_get_suminfo_product( transform ); + WCHAR *product_code_installed = msi_dup_property( package->db, szProductCode ); - TRACE("package = %s transform = %s\n", debugstr_w(package_product), debugstr_w(transform_product)); - - if (!transform_product || strstrW( transform_product, package_product )) + if (!product_code_installed) + { + msi_free( template ); + free_transform_desc( desc ); + msiobj_release( &si->hdr ); + return ERROR_INSTALL_PACKAGE_INVALID; + } + if (!strcmpW( desc->product_code_from, product_code_installed )) { valid_flags |= MSITRANSFORM_VALIDATE_PRODUCT; } - msi_free( transform_product ); - msi_free( package_product ); + msi_free( product_code_installed ); } - if (wanted_flags & MSITRANSFORM_VALIDATE_LANGUAGE) + if (wanted_flags & MSITRANSFORM_VALIDATE_PLATFORM) + { + if ((p = strchrW( template, ';' ))) + { + *p = 0; + if (package->platform == parse_platform( template )) + valid_flags |= MSITRANSFORM_VALIDATE_PLATFORM; + } + } + msi_free( template ); + if (wanted_flags & MSITRANSFORM_VALIDATE_MAJORVERSION) { - WCHAR *template; - const WCHAR *p; + WCHAR *product_version_installed = msi_dup_property( package->db, szProductVersion ); + DWORD major_installed, minor_installed, major, minor; + + if (!product_version_installed) + { + free_transform_desc( desc ); + msiobj_release( &si->hdr ); + return ERROR_INSTALL_PACKAGE_INVALID; + } + msi_parse_version_string( product_version_installed, &major_installed, &minor_installed ); + msi_parse_version_string( desc->version_from, &major, &minor ); - if (!si) + if (major_installed == major) { - ERR("no summary information!\n"); - goto end; + valid_flags |= MSITRANSFORM_VALIDATE_MAJORVERSION; + wanted_flags &= ~MSITRANSFORM_VALIDATE_MINORVERSION; } - if (!(template = msi_suminfo_dup_string( si, PID_TEMPLATE ))) + msi_free( product_version_installed ); + } + else if (wanted_flags & MSITRANSFORM_VALIDATE_MINORVERSION) + { + WCHAR *product_version_installed = msi_dup_property( package->db, szProductVersion ); + DWORD major_installed, minor_installed, major, minor; + + if (!product_version_installed) { - ERR("no template property!\n"); - goto end; + free_transform_desc( desc ); + msiobj_release( &si->hdr ); + return ERROR_INSTALL_PACKAGE_INVALID; } - TRACE("template: %s\n", debugstr_w(template)); - if (!template[0] || ((p = strchrW( template, ';' )) && match_language( package, atoiW( p + 1 ) ))) + msi_parse_version_string( product_version_installed, &major_installed, &minor_installed ); + msi_parse_version_string( desc->version_from, &major, &minor ); + + if (major_installed == major && minor_installed == minor) + valid_flags |= MSITRANSFORM_VALIDATE_MINORVERSION; + msi_free( product_version_installed ); + } + if (wanted_flags & MSITRANSFORM_VALIDATE_UPGRADECODE) + { + WCHAR *upgrade_code_installed = msi_dup_property( package->db, szUpgradeCode ); + + if (!upgrade_code_installed) { - valid_flags |= MSITRANSFORM_VALIDATE_LANGUAGE; + free_transform_desc( desc ); + msiobj_release( &si->hdr ); + return ERROR_INSTALL_PACKAGE_INVALID; } - msi_free( template ); + if (!strcmpW( desc->upgrade_code, upgrade_code_installed )) + valid_flags |= MSITRANSFORM_VALIDATE_UPGRADECODE; + msi_free( upgrade_code_installed ); } -end: + free_transform_desc( desc ); msiobj_release( &si->hdr ); - if (valid_flags & ~wanted_flags) return ERROR_FUNCTION_FAILED; + if ((valid_flags & wanted_flags) != wanted_flags) return ERROR_FUNCTION_FAILED; TRACE("applicable transform\n"); return ERROR_SUCCESS; } diff -Nru wine1.7-1.7.28/dlls/msi/script.c wine1.7-1.7.31/dlls/msi/script.c --- wine1.7-1.7.28/dlls/msi/script.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/script.c 2014-11-14 13:28:17.000000000 +0000 @@ -356,7 +356,7 @@ if (FAILED(hr)) goto done; /* Call a function if necessary through the IDispatch interface */ - if (function != NULL && strlenW(function) > 0) { + if (function && function[0]) { TRACE("Calling function %s\n", debugstr_w(function)); hr = IActiveScript_GetScriptDispatch(pActiveScript, NULL, &pDispatch); diff -Nru wine1.7-1.7.28/dlls/msi/table.c wine1.7-1.7.31/dlls/msi/table.c --- wine1.7-1.7.28/dlls/msi/table.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/table.c 2014-11-14 13:28:17.000000000 +0000 @@ -2716,6 +2716,7 @@ string_table *strings; UINT ret = ERROR_FUNCTION_FAILED; UINT bytes_per_strref; + BOOL property_update = FALSE; TRACE("%p %p\n", db, stg ); @@ -2760,6 +2761,8 @@ tables = transform; else if (!strcmpW( transform->name, szColumns ) ) columns = transform; + else if (!strcmpW( transform->name, szProperty )) + property_update = TRUE; TRACE("transform contains stream %s\n", debugstr_w(name)); @@ -2809,7 +2812,10 @@ } if ( ret == ERROR_SUCCESS ) + { append_storage_to_db( db, stg ); + if (property_update) msi_clone_properties( db ); + } end: if ( stgenum ) diff -Nru wine1.7-1.7.28/dlls/msi/tests/action.c wine1.7-1.7.31/dlls/msi/tests/action.c --- wine1.7-1.7.28/dlls/msi/tests/action.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/tests/action.c 2014-11-14 13:28:17.000000000 +0000 @@ -186,7 +186,8 @@ "SERVNAME2\tTestService2\n" "SERVDISP\tTestServiceDisp\n" "SERVDISP2\tTestServiceDisp2\n" - "MSIFASTINSTALL\t1\n"; + "MSIFASTINSTALL\t1\n" + "regdata15\t#x01\n"; static const char environment_dat[] = "Environment\tName\tValue\tComponent_\n" @@ -514,7 +515,11 @@ "regdata8\t2\tSOFTWARE\\Wine\\msitest\tValue4\tone[~]two\taugustus\n" "regdata9\t2\tSOFTWARE\\Wine\\msitest\tValue5\t[~]one[~]two[~]three\taugustus\n" "regdata10\t2\tSOFTWARE\\Wine\\msitest\tValue6\t[~]\taugustus\n" - "regdata11\t2\tSOFTWARE\\Wine\\msitest\tValue7\t[~]two\taugustus\n"; + "regdata11\t2\tSOFTWARE\\Wine\\msitest\tValue7\t[~]two\taugustus\n" + "regdata12\t2\tSOFTWARE\\Wine\\msitest\tValue8\t#1\taugustus\n" + "regdata13\t2\tSOFTWARE\\Wine\\msitest\tValue9\t#x1\taugustus\n" + "regdata14\t2\tSOFTWARE\\Wine\\msitest\tValue10\t#x01\taugustus\n" + "regdata15\t2\tSOFTWARE\\Wine\\msitest\tValue11\t[regdata15]\taugustus\n"; static const char cf_directory_dat[] = "Directory\tDirectory_Parent\tDefaultDir\n" @@ -2710,7 +2715,7 @@ } if (!expected) - ok_(__FILE__, line)(lstrlenA(val) == 0, "Expected empty string, got %s\n", val); + ok_(__FILE__, line)(!val[0], "Expected empty string, got %s\n", val); else { if (bcase) @@ -4923,6 +4928,7 @@ HKEY hkey; DWORD type, size; CHAR path[MAX_PATH]; + BYTE buf[8]; if (is_process_limited()) { @@ -5055,6 +5061,42 @@ ok(size == 5, "Expected 5, got %d\n", size); ok(type == REG_MULTI_SZ, "Expected REG_MULTI_SZ, got %d\n", type); + size = sizeof(buf); + type = 0xdeadbeef; + memset(buf, 0, size); + res = RegQueryValueExA(hkey, "Value8", NULL, &type, buf, &size); + ok(res == ERROR_SUCCESS, "got %u\n", res); + ok(*(DWORD *)buf == 1, "got %u\n", *(DWORD *)buf); + ok(size == 4, "got %u\n", size); + ok(type == REG_DWORD, "got %u\n", type); + + size = sizeof(buf); + type = 0xdeadbeef; + memset(buf, 0, size); + res = RegQueryValueExA(hkey, "Value9", NULL, &type, buf, &size); + ok(res == ERROR_SUCCESS, "got %u\n", res); + ok(buf[0] == 1, "got %u\n", buf[0]); + ok(size == 1, "got %u\n", size); + ok(type == REG_BINARY, "got %u\n", type); + + size = sizeof(buf); + type = 0xdeadbeef; + memset(buf, 0, size); + res = RegQueryValueExA(hkey, "Value10", NULL, &type, buf, &size); + ok(res == ERROR_SUCCESS, "got %u\n", res); + ok(buf[0] == 1, "got %u\n", buf[0]); + ok(size == 1, "got %u\n", size); + ok(type == REG_BINARY, "got %u\n", type); + + size = sizeof(buf); + type = 0xdeadbeef; + memset(buf, 0, size); + res = RegQueryValueExA(hkey, "Value11", NULL, &type, buf, &size); + ok(res == ERROR_SUCCESS, "got %u\n", res); + ok(buf[0] == 1, "got %u\n", buf[0]); + ok(size == 1, "got %u\n", size); + ok(type == REG_BINARY, "got %u\n", type); + RegDeleteValueA(hkey, "Value"); RegDeleteValueA(hkey, "Value1"); RegDeleteValueA(hkey, "Value2"); @@ -5063,6 +5105,10 @@ RegDeleteValueA(hkey, "Value5"); RegDeleteValueA(hkey, "Value6"); RegDeleteValueA(hkey, "Value7"); + RegDeleteValueA(hkey, "Value8"); + RegDeleteValueA(hkey, "Value9"); + RegDeleteValueA(hkey, "Value10"); + RegDeleteValueA(hkey, "Value11"); RegCloseKey(hkey); RegDeleteKeyA(HKEY_LOCAL_MACHINE, "SOFTWARE\\Wine\\msitest"); diff -Nru wine1.7-1.7.28/dlls/msi/tests/db.c wine1.7-1.7.31/dlls/msi/tests/db.c --- wine1.7-1.7.28/dlls/msi/tests/db.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/tests/db.c 2014-11-14 13:28:17.000000000 +0000 @@ -4534,7 +4534,7 @@ size = MAX_PATH; r = MsiRecordGetStringA(rec, 1, result, &size); ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrlenA(result), "Expected an empty string, got %s\n", result); + ok(!result[0], "Expected an empty string, got %s\n", result); MsiCloseHandle(rec); @@ -4580,7 +4580,7 @@ size = MAX_PATH; r = MsiRecordGetStringA(rec, 1, result, &size); ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(!lstrlenA(result), "Expected an empty string, got %s\n", result); + ok(!result[0], "Expected an empty string, got %s\n", result); MsiCloseHandle(rec); diff -Nru wine1.7-1.7.28/dlls/msi/tests/package.c wine1.7-1.7.31/dlls/msi/tests/package.c --- wine1.7-1.7.28/dlls/msi/tests/package.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/tests/package.c 2014-11-14 13:28:17.000000000 +0000 @@ -2194,7 +2194,7 @@ sz = 6; r = MsiGetPropertyA(hpkg, "property", buffer, &sz); ok( r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok( !strlen(buffer), "Expected empty string, got %s\n", buffer); + ok(!buffer[0], "Expected empty string, got %s\n", buffer); MsiCloseHandle( hpkg ); DeleteFileA(msifile); @@ -2347,7 +2347,7 @@ lstrcpyA(buffer, "aaa"); r = MsiGetPropertyA(hpkg, "dantes", buffer, &sz); ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); - ok(lstrlenA(buffer) == 0, "Expected empty string, got %s\n", buffer); + ok(!buffer[0], "Expected empty string, got %s\n", buffer); r = MsiSetPropertyA(hpkg, "dantes", "mercedes"); ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", r); diff -Nru wine1.7-1.7.28/dlls/msi/tests/source.c wine1.7-1.7.31/dlls/msi/tests/source.c --- wine1.7-1.7.28/dlls/msi/tests/source.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msi/tests/source.c 2014-11-14 13:28:17.000000000 +0000 @@ -176,7 +176,7 @@ } if (!expected) - ok_(__FILE__, line)(lstrlenA(val) == 0, "Expected empty string, got %s\n", val); + ok_(__FILE__, line)(!val[0], "Expected empty string, got %s\n", val); else { if (bcase) diff -Nru wine1.7-1.7.28/dlls/msvcp100/msvcp100.spec wine1.7-1.7.31/dlls/msvcp100/msvcp100.spec --- wine1.7-1.7.28/dlls/msvcp100/msvcp100.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp100/msvcp100.spec 2014-11-14 13:28:17.000000000 +0000 @@ -2045,8 +2045,8 @@ # extern ?intl@?$moneypunct@G$0A@@std@@2_NB # extern ?intl@?$moneypunct@_W$00@std@@2_NB # extern ?intl@?$moneypunct@_W$0A@@std@@2_NB -@ stub -arch=win32 ?iostream_category@std@@YAABVerror_category@1@XZ -@ stub -arch=win64 ?iostream_category@std@@YAAEBVerror_category@1@XZ +@ cdecl -arch=win32 ?iostream_category@std@@YAABVerror_category@1@XZ() std_iostream_category +@ cdecl -arch=win64 ?iostream_category@std@@YAAEBVerror_category@1@XZ() std_iostream_category @ thiscall -arch=win32 ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z(ptr long) basic_istream_char_ipfx @ cdecl -arch=win64 ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z(ptr long) basic_istream_char_ipfx @ thiscall -arch=win32 ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z(ptr long) basic_istream_wchar_ipfx diff -Nru wine1.7-1.7.28/dlls/msvcp110/msvcp110.spec wine1.7-1.7.31/dlls/msvcp110/msvcp110.spec --- wine1.7-1.7.28/dlls/msvcp110/msvcp110.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp110/msvcp110.spec 2014-11-14 13:28:17.000000000 +0000 @@ -2120,15 +2120,15 @@ @ cdecl -arch=arm ?do_is@?$ctype@_W@std@@MBA_NF_W@Z(ptr long long) ctype_wchar_do_is_ch @ thiscall -arch=i386 ?do_is@?$ctype@_W@std@@MBE_NF_W@Z(ptr long long) ctype_wchar_do_is_ch @ cdecl -arch=win64 ?do_is@?$ctype@_W@std@@MEBA_NF_W@Z(ptr long long) ctype_wchar_do_is_ch -@ stub -arch=arm ?do_length@?$codecvt@DDH@std@@MBAHAAHPBD1I@Z -@ stub -arch=i386 ?do_length@?$codecvt@DDH@std@@MBEHAAHPBD1I@Z -@ stub -arch=win64 ?do_length@?$codecvt@DDH@std@@MEBAHAEAHPEBD1_K@Z -@ stub -arch=arm ?do_length@?$codecvt@GDH@std@@MBAHAAHPBD1I@Z -@ stub -arch=i386 ?do_length@?$codecvt@GDH@std@@MBEHAAHPBD1I@Z -@ stub -arch=win64 ?do_length@?$codecvt@GDH@std@@MEBAHAEAHPEBD1_K@Z -@ stub -arch=arm ?do_length@?$codecvt@_WDH@std@@MBAHAAHPBD1I@Z -@ stub -arch=i386 ?do_length@?$codecvt@_WDH@std@@MBEHAAHPBD1I@Z -@ stub -arch=win64 ?do_length@?$codecvt@_WDH@std@@MEBAHAEAHPEBD1_K@Z +@ cdecl -arch=arm ?do_length@?$codecvt@DDH@std@@MBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_do_length +@ thiscall -arch=i386 ?do_length@?$codecvt@DDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@DDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_char_do_length +@ cdecl -arch=arm ?do_length@?$codecvt@GDH@std@@MBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ thiscall -arch=i386 ?do_length@?$codecvt@GDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@GDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_do_length +@ cdecl -arch=arm ?do_length@?$codecvt@_WDH@std@@MBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ thiscall -arch=i386 ?do_length@?$codecvt@_WDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@_WDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_do_length @ cdecl -arch=arm ?do_max_length@?$codecvt@GDH@std@@MBAHXZ(ptr) codecvt_wchar_do_max_length @ thiscall -arch=i386 ?do_max_length@?$codecvt@GDH@std@@MBEHXZ(ptr) codecvt_wchar_do_max_length @ cdecl -arch=win64 ?do_max_length@?$codecvt@GDH@std@@MEBAHXZ(ptr) codecvt_wchar_do_max_length @@ -2846,15 +2846,15 @@ @ cdecl -arch=arm ?iword@ios_base@std@@QAAAAJH@Z(ptr long) ios_base_iword @ thiscall -arch=i386 ?iword@ios_base@std@@QAEAAJH@Z(ptr long) ios_base_iword @ cdecl -arch=win64 ?iword@ios_base@std@@QEAAAEAJH@Z(ptr long) ios_base_iword -@ stub -arch=arm ?length@?$codecvt@DDH@std@@QBAHAAHPBD1I@Z -@ stub -arch=i386 ?length@?$codecvt@DDH@std@@QBEHAAHPBD1I@Z -@ stub -arch=win64 ?length@?$codecvt@DDH@std@@QEBAHAEAHPEBD1_K@Z -@ stub -arch=arm ?length@?$codecvt@GDH@std@@QBAHAAHPBD1I@Z -@ stub -arch=i386 ?length@?$codecvt@GDH@std@@QBEHAAHPBD1I@Z -@ stub -arch=win64 ?length@?$codecvt@GDH@std@@QEBAHAEAHPEBD1_K@Z -@ stub -arch=arm ?length@?$codecvt@_WDH@std@@QBAHAAHPBD1I@Z -@ stub -arch=i386 ?length@?$codecvt@_WDH@std@@QBEHAAHPBD1I@Z -@ stub -arch=win64 ?length@?$codecvt@_WDH@std@@QEBAHAEAHPEBD1_K@Z +@ cdecl -arch=arm ?length@?$codecvt@DDH@std@@QBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_length +@ thiscall -arch=i386 ?length@?$codecvt@DDH@std@@QBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_length +@ cdecl -arch=win64 ?length@?$codecvt@DDH@std@@QEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_char_length +@ cdecl -arch=arm ?length@?$codecvt@GDH@std@@QBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_length +@ thiscall -arch=i386 ?length@?$codecvt@GDH@std@@QBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_length +@ cdecl -arch=win64 ?length@?$codecvt@GDH@std@@QEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_length +@ cdecl -arch=arm ?length@?$codecvt@_WDH@std@@QBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_length +@ thiscall -arch=i386 ?length@?$codecvt@_WDH@std@@QBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_length +@ cdecl -arch=win64 ?length@?$codecvt@_WDH@std@@QEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_length @ cdecl -arch=arm ?max_length@codecvt_base@std@@QBAHXZ(ptr) codecvt_base_max_length @ thiscall -arch=i386 ?max_length@codecvt_base@std@@QBEHXZ(ptr) codecvt_base_max_length @ cdecl -arch=win64 ?max_length@codecvt_base@std@@QEBAHXZ(ptr) codecvt_base_max_length diff -Nru wine1.7-1.7.28/dlls/msvcp120/Makefile.in wine1.7-1.7.31/dlls/msvcp120/Makefile.in --- wine1.7-1.7.28/dlls/msvcp120/Makefile.in 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp120/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,14 @@ +MODULE = msvcp120.dll +IMPORTS = msvcr120 +EXTRADEFS = -D_MSVCP_VER=120 +PARENTSRC = ../msvcp90 + +C_SRCS = \ + exception.c \ + ios.c \ + locale.c \ + math.c \ + memory.c \ + misc.c \ + msvcp_main.c \ + string.c diff -Nru wine1.7-1.7.28/dlls/msvcp120/msvcp120.spec wine1.7-1.7.31/dlls/msvcp120/msvcp120.spec --- wine1.7-1.7.28/dlls/msvcp120/msvcp120.spec 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp120/msvcp120.spec 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,3846 @@ +@ stub -arch=arm ??$_Getvals@_W@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAAX_WABV_Locinfo@1@@Z +@ stub -arch=i386 ??$_Getvals@_W@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAEX_WABV_Locinfo@1@@Z +@ stub -arch=win64 ??$_Getvals@_W@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IEAAX_WAEBV_Locinfo@1@@Z +@ stub -arch=arm ??$_Getvals@_W@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAAX_WABV_Locinfo@1@@Z +@ stub -arch=i386 ??$_Getvals@_W@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAEX_WABV_Locinfo@1@@Z +@ stub -arch=win64 ??$_Getvals@_W@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEAAX_WAEBV_Locinfo@1@@Z +@ stub -arch=arm ??$_Getvals@_W@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAAX_WABV_Locinfo@1@@Z +@ stub -arch=i386 ??$_Getvals@_W@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAEX_WABV_Locinfo@1@@Z +@ stub -arch=win64 ??$_Getvals@_W@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEAAX_WAEBV_Locinfo@1@@Z +@ cdecl -arch=arm ??0?$_Yarn@D@std@@QAA@ABV01@@Z(ptr ptr) _Yarn_char_copy_ctor +@ thiscall -arch=i386 ??0?$_Yarn@D@std@@QAE@ABV01@@Z(ptr ptr) _Yarn_char_copy_ctor +@ cdecl -arch=win64 ??0?$_Yarn@D@std@@QEAA@AEBV01@@Z(ptr ptr) _Yarn_char_copy_ctor +@ cdecl -arch=arm ??0?$_Yarn@D@std@@QAA@PBD@Z(ptr str) _Yarn_char_ctor_cstr +@ thiscall -arch=i386 ??0?$_Yarn@D@std@@QAE@PBD@Z(ptr str) _Yarn_char_ctor_cstr +@ cdecl -arch=win64 ??0?$_Yarn@D@std@@QEAA@PEBD@Z(ptr str) _Yarn_char_ctor_cstr +@ cdecl -arch=arm ??0?$_Yarn@D@std@@QAA@XZ(ptr) _Yarn_char_ctor +@ thiscall -arch=i386 ??0?$_Yarn@D@std@@QAE@XZ(ptr) _Yarn_char_ctor +@ cdecl -arch=win64 ??0?$_Yarn@D@std@@QEAA@XZ(ptr) _Yarn_char_ctor +@ stub -arch=arm ??0?$_Yarn@_W@std@@QAA@XZ +@ stub -arch=i386 ??0?$_Yarn@_W@std@@QAE@XZ +@ stub -arch=win64 ??0?$_Yarn@_W@std@@QEAA@XZ +@ cdecl -arch=arm ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IAA@XZ(ptr) basic_ios_char_ctor +@ thiscall -arch=i386 ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IAE@XZ(ptr) basic_ios_char_ctor +@ cdecl -arch=win64 ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IEAA@XZ(ptr) basic_ios_char_ctor +@ cdecl -arch=arm ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QAA@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_ios_char_ctor_streambuf +@ thiscall -arch=i386 ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_ios_char_ctor_streambuf +@ cdecl -arch=win64 ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_ios_char_ctor_streambuf +@ cdecl -arch=arm ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IAA@XZ(ptr) basic_ios_short_ctor +@ thiscall -arch=i386 ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IAE@XZ(ptr) basic_ios_short_ctor +@ cdecl -arch=win64 ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IEAA@XZ(ptr) basic_ios_short_ctor +@ cdecl -arch=arm ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QAA@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_ios_short_ctor_streambuf +@ thiscall -arch=i386 ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_ios_short_ctor_streambuf +@ cdecl -arch=win64 ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_ios_short_ctor_streambuf +@ cdecl -arch=arm ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAA@XZ(ptr) basic_ios_wchar_ctor +@ thiscall -arch=i386 ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAE@XZ(ptr) basic_ios_wchar_ctor +@ cdecl -arch=win64 ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IEAA@XZ(ptr) basic_ios_wchar_ctor +@ cdecl -arch=arm ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAA@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_ios_wchar_ctor_streambuf +@ thiscall -arch=i386 ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_ios_wchar_ctor_streambuf +@ cdecl -arch=win64 ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_ios_wchar_ctor_streambuf +@ stub -arch=arm ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QAA@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr long) basic_iostream_char_ctor +@ thiscall -arch=i386 ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr long) basic_iostream_char_ctor +@ cdecl -arch=win64 ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr long) basic_iostream_char_ctor +@ stub -arch=arm ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QAA@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr long) basic_iostream_short_ctor +@ thiscall -arch=i386 ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr long) basic_iostream_short_ctor +@ cdecl -arch=win64 ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr long) basic_iostream_short_ctor +@ stub -arch=arm ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAA@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr long) basic_iostream_wchar_ctor +@ thiscall -arch=i386 ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr long) basic_iostream_wchar_ctor +@ cdecl -arch=win64 ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr long) basic_iostream_wchar_ctor +@ stub -arch=arm ??0?$basic_istream@DU?$char_traits@D@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_istream@DU?$char_traits@D@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_istream@DU?$char_traits@D@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAA@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_char_ctor_init +@ thiscall -arch=i386 ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_char_ctor_init +@ cdecl -arch=win64 ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_char_ctor_init +@ cdecl -arch=arm ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAA@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z(ptr ptr long long) basic_istream_char_ctor +@ thiscall -arch=i386 ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z(ptr ptr long long) basic_istream_char_ctor +@ cdecl -arch=win64 ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z(ptr ptr long long) basic_istream_char_ctor +@ cdecl -arch=arm ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAA@W4_Uninitialized@1@@Z(ptr long long) basic_istream_char_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@@Z(ptr long long) basic_istream_char_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@@Z(ptr long long) basic_istream_char_ctor_uninitialized +@ stub -arch=arm ??0?$basic_istream@GU?$char_traits@G@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_istream@GU?$char_traits@G@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_istream@GU?$char_traits@G@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAA@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_short_ctor_init +@ thiscall -arch=i386 ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_short_ctor_init +@ cdecl -arch=win64 ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_short_ctor_init +@ cdecl -arch=arm ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAA@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z(ptr ptr long long) basic_istream_short_ctor +@ thiscall -arch=i386 ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z(ptr ptr long long) basic_istream_short_ctor +@ cdecl -arch=win64 ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z(ptr ptr long long) basic_istream_short_ctor +@ cdecl -arch=arm ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAA@W4_Uninitialized@1@@Z(ptr long long) basic_istream_short_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@@Z(ptr long long) basic_istream_short_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@@Z(ptr long long) basic_istream_short_ctor_uninitialized +@ stub -arch=arm ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAA@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_wchar_ctor_init +@ thiscall -arch=i386 ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_wchar_ctor_init +@ cdecl -arch=win64 ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z(ptr ptr long long long) basic_istream_wchar_ctor_init +@ cdecl -arch=arm ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAA@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z(ptr ptr long long) basic_istream_wchar_ctor +@ thiscall -arch=i386 ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z(ptr ptr long long) basic_istream_wchar_ctor +@ cdecl -arch=win64 ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z(ptr ptr long long) basic_istream_wchar_ctor +@ cdecl -arch=arm ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAA@W4_Uninitialized@1@@Z(ptr long long) basic_istream_wchar_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@@Z(ptr long long) basic_istream_wchar_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@@Z(ptr long long) basic_istream_wchar_ctor_uninitialized +@ stub -arch=arm ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAA@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z(ptr ptr long long) basic_ostream_char_ctor +@ thiscall -arch=i386 ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z(ptr ptr long long) basic_ostream_char_ctor +@ cdecl -arch=win64 ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z(ptr ptr long long) basic_ostream_char_ctor +@ cdecl -arch=arm ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAA@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_char_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_char_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_char_ctor_uninitialized +@ stub -arch=arm ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAA@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z(ptr ptr long long) basic_ostream_short_ctor +@ thiscall -arch=i386 ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z(ptr ptr long long) basic_ostream_short_ctor +@ cdecl -arch=win64 ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z(ptr ptr long long) basic_ostream_short_ctor +@ cdecl -arch=arm ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAA@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_short_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_short_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_short_ctor_uninitialized +@ stub -arch=arm ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IAA@$$QAV01@@Z +@ stub -arch=i386 ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IAE@$$QAV01@@Z +@ stub -arch=win64 ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IEAA@$$QEAV01@@Z +@ cdecl -arch=arm ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAA@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z(ptr ptr long long) basic_ostream_wchar_ctor +@ thiscall -arch=i386 ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z(ptr ptr long long) basic_ostream_wchar_ctor +@ cdecl -arch=win64 ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z(ptr ptr long long) basic_ostream_wchar_ctor +@ cdecl -arch=arm ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAA@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_wchar_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_wchar_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z(ptr long long long) basic_ostream_wchar_ctor_uninitialized +@ stub -arch=arm ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAA@ABV01@@Z +@ stub -arch=i386 ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@ABV01@@Z +@ stub -arch=win64 ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@AEBV01@@Z +@ cdecl -arch=arm ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAA@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_char_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_char_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_char_ctor_uninitialized +@ cdecl -arch=arm ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAA@XZ(ptr) basic_streambuf_char_ctor +@ thiscall -arch=i386 ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@XZ(ptr) basic_streambuf_char_ctor +@ cdecl -arch=win64 ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@XZ(ptr) basic_streambuf_char_ctor +@ stub -arch=arm ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAA@ABV01@@Z +@ stub -arch=i386 ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@ABV01@@Z +@ stub -arch=win64 ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@AEBV01@@Z +@ cdecl -arch=arm ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAA@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_short_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_short_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_short_ctor_uninitialized +@ cdecl -arch=arm ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAA@XZ(ptr) basic_streambuf_short_ctor +@ thiscall -arch=i386 ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@XZ(ptr) basic_streambuf_short_ctor +@ cdecl -arch=win64 ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@XZ(ptr) basic_streambuf_short_ctor +@ stub -arch=arm ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAA@ABV01@@Z +@ stub -arch=i386 ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@ABV01@@Z +@ stub -arch=win64 ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@AEBV01@@Z +@ cdecl -arch=arm ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAA@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_wchar_ctor_uninitialized +@ thiscall -arch=i386 ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_wchar_ctor_uninitialized +@ cdecl -arch=win64 ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@W4_Uninitialized@1@@Z(ptr long) basic_streambuf_wchar_ctor_uninitialized +@ cdecl -arch=arm ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAA@XZ(ptr) basic_streambuf_wchar_ctor +@ thiscall -arch=i386 ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@XZ(ptr) basic_streambuf_wchar_ctor +@ cdecl -arch=win64 ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@XZ(ptr) basic_streambuf_wchar_ctor +@ cdecl -arch=arm ??0?$codecvt@DDH@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) codecvt_char_ctor_locinfo +@ thiscall -arch=i386 ??0?$codecvt@DDH@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) codecvt_char_ctor_locinfo +@ cdecl -arch=win64 ??0?$codecvt@DDH@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) codecvt_char_ctor_locinfo +@ cdecl -arch=arm ??0?$codecvt@DDH@std@@QAA@I@Z(ptr long) codecvt_char_ctor_refs +@ thiscall -arch=i386 ??0?$codecvt@DDH@std@@QAE@I@Z(ptr long) codecvt_char_ctor_refs +@ cdecl -arch=win64 ??0?$codecvt@DDH@std@@QEAA@_K@Z(ptr long) codecvt_char_ctor_refs +@ cdecl -arch=arm ??0?$codecvt@GDH@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) codecvt_short_ctor_locinfo +@ thiscall -arch=i386 ??0?$codecvt@GDH@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) codecvt_short_ctor_locinfo +@ cdecl -arch=win64 ??0?$codecvt@GDH@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) codecvt_short_ctor_locinfo +@ cdecl -arch=arm ??0?$codecvt@GDH@std@@QAA@I@Z(ptr long) codecvt_short_ctor_refs +@ thiscall -arch=i386 ??0?$codecvt@GDH@std@@QAE@I@Z(ptr long) codecvt_short_ctor_refs +@ cdecl -arch=win64 ??0?$codecvt@GDH@std@@QEAA@_K@Z(ptr long) codecvt_short_ctor_refs +@ cdecl -arch=arm ??0?$codecvt@_WDH@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) codecvt_wchar_ctor_locinfo +@ thiscall -arch=i386 ??0?$codecvt@_WDH@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) codecvt_wchar_ctor_locinfo +@ cdecl -arch=win64 ??0?$codecvt@_WDH@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) codecvt_wchar_ctor_locinfo +@ cdecl -arch=arm ??0?$codecvt@_WDH@std@@QAA@I@Z(ptr long) codecvt_wchar_ctor_refs +@ thiscall -arch=i386 ??0?$codecvt@_WDH@std@@QAE@I@Z(ptr long) codecvt_wchar_ctor_refs +@ cdecl -arch=win64 ??0?$codecvt@_WDH@std@@QEAA@_K@Z(ptr long) codecvt_wchar_ctor_refs +@ cdecl -arch=arm ??0?$ctype@D@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) ctype_char_ctor_locinfo +@ thiscall -arch=i386 ??0?$ctype@D@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) ctype_char_ctor_locinfo +@ cdecl -arch=win64 ??0?$ctype@D@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) ctype_char_ctor_locinfo +@ cdecl -arch=arm ??0?$ctype@D@std@@QAA@PBF_NI@Z(ptr ptr long long) ctype_char_ctor_table +@ thiscall -arch=i386 ??0?$ctype@D@std@@QAE@PBF_NI@Z(ptr ptr long long) ctype_char_ctor_table +@ cdecl -arch=win64 ??0?$ctype@D@std@@QEAA@PEBF_N_K@Z(ptr ptr long long) ctype_char_ctor_table +@ cdecl -arch=arm ??0?$ctype@G@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) ctype_short_ctor_locinfo +@ thiscall -arch=i386 ??0?$ctype@G@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) ctype_short_ctor_locinfo +@ cdecl -arch=win64 ??0?$ctype@G@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) ctype_short_ctor_locinfo +@ cdecl -arch=arm ??0?$ctype@G@std@@QAA@I@Z(ptr long) ctype_short_ctor_refs +@ thiscall -arch=i386 ??0?$ctype@G@std@@QAE@I@Z(ptr long) ctype_short_ctor_refs +@ cdecl -arch=win64 ??0?$ctype@G@std@@QEAA@_K@Z(ptr long) ctype_short_ctor_refs +@ cdecl -arch=arm ??0?$ctype@_W@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) ctype_wchar_ctor_locinfo +@ thiscall -arch=i386 ??0?$ctype@_W@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) ctype_wchar_ctor_locinfo +@ cdecl -arch=win64 ??0?$ctype@_W@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) ctype_wchar_ctor_locinfo +@ cdecl -arch=arm ??0?$ctype@_W@std@@QAA@I@Z(ptr long) ctype_wchar_ctor_refs +@ thiscall -arch=i386 ??0?$ctype@_W@std@@QAE@I@Z(ptr long) ctype_wchar_ctor_refs +@ cdecl -arch=win64 ??0?$ctype@_W@std@@QEAA@_K@Z(ptr long) ctype_wchar_ctor_refs +@ cdecl -arch=arm ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) num_get_char_ctor_locinfo +@ thiscall -arch=i386 ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) num_get_char_ctor_locinfo +@ cdecl -arch=win64 ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) num_get_char_ctor_locinfo +@ cdecl -arch=arm ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAA@I@Z(ptr long) num_get_char_ctor_refs +@ thiscall -arch=i386 ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@I@Z(ptr long) num_get_char_ctor_refs +@ cdecl -arch=win64 ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@_K@Z(ptr long) num_get_char_ctor_refs +@ cdecl -arch=arm ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) num_get_short_ctor_locinfo +@ thiscall -arch=i386 ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) num_get_short_ctor_locinfo +@ cdecl -arch=win64 ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) num_get_short_ctor_locinfo +@ cdecl -arch=arm ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAA@I@Z(ptr long) num_get_short_ctor_refs +@ thiscall -arch=i386 ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@I@Z(ptr long) num_get_short_ctor_refs +@ cdecl -arch=win64 ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@_K@Z(ptr long) num_get_short_ctor_refs +@ cdecl -arch=arm ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) num_get_wchar_ctor_locinfo +@ thiscall -arch=i386 ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) num_get_wchar_ctor_locinfo +@ cdecl -arch=win64 ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) num_get_wchar_ctor_locinfo +@ cdecl -arch=arm ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAA@I@Z(ptr long) num_get_wchar_ctor_refs +@ thiscall -arch=i386 ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@I@Z(ptr long) num_get_wchar_ctor_refs +@ cdecl -arch=win64 ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@_K@Z(ptr long) num_get_wchar_ctor_refs +@ cdecl -arch=arm ??0?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) num_put_char_ctor_locinfo +@ thiscall -arch=i386 ??0?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) num_put_char_ctor_locinfo +@ cdecl -arch=win64 ??0?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) num_put_char_ctor_locinfo +@ cdecl -arch=arm ??0?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAA@I@Z(ptr long) num_put_char_ctor_refs +@ thiscall -arch=i386 ??0?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@I@Z(ptr long) num_put_char_ctor_refs +@ cdecl -arch=win64 ??0?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@_K@Z(ptr long) num_put_char_ctor_refs +@ cdecl -arch=arm ??0?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) num_put_short_ctor_locinfo +@ thiscall -arch=i386 ??0?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) num_put_short_ctor_locinfo +@ cdecl -arch=win64 ??0?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) num_put_short_ctor_locinfo +@ cdecl -arch=arm ??0?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAA@I@Z(ptr long) num_put_short_ctor_refs +@ thiscall -arch=i386 ??0?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@I@Z(ptr long) num_put_short_ctor_refs +@ cdecl -arch=win64 ??0?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@_K@Z(ptr long) num_put_short_ctor_refs +@ cdecl -arch=arm ??0?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) num_put_wchar_ctor_locinfo +@ thiscall -arch=i386 ??0?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) num_put_wchar_ctor_locinfo +@ cdecl -arch=win64 ??0?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) num_put_wchar_ctor_locinfo +@ cdecl -arch=arm ??0?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAA@I@Z(ptr long) num_put_wchar_ctor_refs +@ thiscall -arch=i386 ??0?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@I@Z(ptr long) num_put_wchar_ctor_refs +@ cdecl -arch=win64 ??0?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@_K@Z(ptr long) num_put_wchar_ctor_refs +@ stub -arch=arm ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAA@PBDI@Z +@ stub -arch=i386 ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAE@PBDI@Z +@ stub -arch=win64 ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IEAA@PEBD_K@Z +@ stub -arch=arm ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z +@ stub -arch=i386 ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z +@ stub -arch=win64 ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z +@ stub -arch=arm ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAA@I@Z +@ stub -arch=i386 ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@I@Z +@ stub -arch=win64 ??0?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@_K@Z +@ stub -arch=arm ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAA@PBDI@Z +@ stub -arch=i386 ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAE@PBDI@Z +@ stub -arch=win64 ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEAA@PEBD_K@Z +@ stub -arch=arm ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z +@ stub -arch=i386 ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z +@ stub -arch=win64 ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z +@ stub -arch=arm ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAA@I@Z +@ stub -arch=i386 ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@I@Z +@ stub -arch=win64 ??0?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@_K@Z +@ stub -arch=arm ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAA@PBDI@Z +@ stub -arch=i386 ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAE@PBDI@Z +@ stub -arch=win64 ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEAA@PEBD_K@Z +@ stub -arch=arm ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z +@ stub -arch=i386 ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z +@ stub -arch=win64 ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z +@ stub -arch=arm ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAA@I@Z +@ stub -arch=i386 ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@I@Z +@ stub -arch=win64 ??0?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@_K@Z +@ cdecl -arch=arm ??0?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) time_put_char_ctor_locinfo +@ thiscall -arch=i386 ??0?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) time_put_char_ctor_locinfo +@ cdecl -arch=win64 ??0?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) time_put_char_ctor_locinfo +@ cdecl -arch=arm ??0?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAA@I@Z(ptr long) time_put_char_ctor_refs +@ thiscall -arch=i386 ??0?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@I@Z(ptr long) time_put_char_ctor_refs +@ cdecl -arch=win64 ??0?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@_K@Z(ptr long) time_put_char_ctor_refs +@ cdecl -arch=arm ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAA@PBDI@Z(ptr str long) time_put_short_ctor_name +@ thiscall -arch=i386 ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAE@PBDI@Z(ptr str long) time_put_short_ctor_name +@ cdecl -arch=win64 ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEAA@PEBD_K@Z(ptr str long) time_put_short_ctor_name +@ cdecl -arch=arm ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) time_put_short_ctor_locinfo +@ thiscall -arch=i386 ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) time_put_short_ctor_locinfo +@ cdecl -arch=win64 ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) time_put_short_ctor_locinfo +@ cdecl -arch=arm ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAA@I@Z(ptr long) time_put_short_ctor_refs +@ thiscall -arch=i386 ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@I@Z(ptr long) time_put_short_ctor_refs +@ cdecl -arch=win64 ??0?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@_K@Z(ptr long) time_put_short_ctor_refs +@ cdecl -arch=arm ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAA@PBDI@Z(ptr str long) time_put_wchar_ctor_name +@ thiscall -arch=i386 ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAE@PBDI@Z(ptr str long) time_put_wchar_ctor_name +@ cdecl -arch=win64 ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEAA@PEBD_K@Z(ptr str long) time_put_wchar_ctor_name +@ cdecl -arch=arm ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAA@ABV_Locinfo@1@I@Z(ptr ptr long) time_put_wchar_ctor_locinfo +@ thiscall -arch=i386 ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z(ptr ptr long) time_put_wchar_ctor_locinfo +@ cdecl -arch=win64 ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z(ptr ptr long) time_put_wchar_ctor_locinfo +@ cdecl -arch=arm ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAA@I@Z(ptr long) time_put_wchar_ctor_refs +@ thiscall -arch=i386 ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@I@Z(ptr long) time_put_wchar_ctor_refs +@ cdecl -arch=win64 ??0?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@_K@Z(ptr long) time_put_wchar_ctor_refs +@ cdecl -arch=arm ??0Init@ios_base@std@@QAA@XZ(ptr) ios_base_Init_ctor +@ thiscall -arch=i386 ??0Init@ios_base@std@@QAE@XZ(ptr) ios_base_Init_ctor +@ cdecl -arch=win64 ??0Init@ios_base@std@@QEAA@XZ(ptr) ios_base_Init_ctor +@ stub -arch=arm ??0_Concurrent_queue_base_v4@details@Concurrency@@IAA@I@Z +@ stub -arch=i386 ??0_Concurrent_queue_base_v4@details@Concurrency@@IAE@I@Z +@ stub -arch=win64 ??0_Concurrent_queue_base_v4@details@Concurrency@@IEAA@_K@Z +@ stub -arch=arm ??0_Concurrent_queue_iterator_base_v4@details@Concurrency@@IAA@ABV_Concurrent_queue_base_v4@12@@Z +@ stub -arch=i386 ??0_Concurrent_queue_iterator_base_v4@details@Concurrency@@IAE@ABV_Concurrent_queue_base_v4@12@@Z +@ stub -arch=win64 ??0_Concurrent_queue_iterator_base_v4@details@Concurrency@@IEAA@AEBV_Concurrent_queue_base_v4@12@@Z +@ cdecl -arch=arm ??0_Container_base12@std@@QAA@ABU01@@Z(ptr ptr) _Container_base12_copy_ctor +@ thiscall -arch=i386 ??0_Container_base12@std@@QAE@ABU01@@Z(ptr ptr) _Container_base12_copy_ctor +@ cdecl -arch=win64 ??0_Container_base12@std@@QEAA@AEBU01@@Z(ptr ptr) _Container_base12_copy_ctor +@ cdecl -arch=arm ??0_Container_base12@std@@QAA@XZ(ptr) _Container_base12_ctor +@ thiscall -arch=i386 ??0_Container_base12@std@@QAE@XZ(ptr) _Container_base12_ctor +@ cdecl -arch=win64 ??0_Container_base12@std@@QEAA@XZ(ptr) _Container_base12_ctor +@ stub -arch=arm ??0_Facet_base@std@@QAA@ABV01@@Z +@ stub -arch=i386 ??0_Facet_base@std@@QAE@ABV01@@Z +@ stub -arch=win64 ??0_Facet_base@std@@QEAA@AEBV01@@Z +@ stub -arch=arm ??0_Facet_base@std@@QAA@XZ +@ stub -arch=i386 ??0_Facet_base@std@@QAE@XZ +@ stub -arch=win64 ??0_Facet_base@std@@QEAA@XZ +@ stub -arch=arm ??0_Init_locks@std@@QAA@XZ +@ stub -arch=i386 ??0_Init_locks@std@@QAE@XZ +@ stub -arch=win64 ??0_Init_locks@std@@QEAA@XZ +@ cdecl -arch=arm ??0_Locimp@locale@std@@AAA@ABV012@@Z(ptr ptr) locale__Locimp_copy_ctor +@ thiscall -arch=i386 ??0_Locimp@locale@std@@AAE@ABV012@@Z(ptr ptr) locale__Locimp_copy_ctor +@ cdecl -arch=win64 ??0_Locimp@locale@std@@AEAA@AEBV012@@Z(ptr ptr) locale__Locimp_copy_ctor +@ cdecl -arch=arm ??0_Locimp@locale@std@@AAA@_N@Z(ptr long) locale__Locimp_ctor_transparent +@ thiscall -arch=i386 ??0_Locimp@locale@std@@AAE@_N@Z(ptr long) locale__Locimp_ctor_transparent +@ cdecl -arch=win64 ??0_Locimp@locale@std@@AEAA@_N@Z(ptr long) locale__Locimp_ctor_transparent +@ cdecl -arch=arm ??0_Locinfo@std@@QAA@HPBD@Z(ptr long str) _Locinfo_ctor_cat_cstr +@ thiscall -arch=i386 ??0_Locinfo@std@@QAE@HPBD@Z(ptr long str) _Locinfo_ctor_cat_cstr +@ cdecl -arch=win64 ??0_Locinfo@std@@QEAA@HPEBD@Z(ptr long str) _Locinfo_ctor_cat_cstr +@ cdecl -arch=arm ??0_Locinfo@std@@QAA@PBD@Z(ptr str) _Locinfo_ctor_cstr +@ thiscall -arch=i386 ??0_Locinfo@std@@QAE@PBD@Z(ptr str) _Locinfo_ctor_cstr +@ cdecl -arch=win64 ??0_Locinfo@std@@QEAA@PEBD@Z(ptr str) _Locinfo_ctor_cstr +@ cdecl -arch=arm ??0_Lockit@std@@QAA@H@Z(ptr long) _Lockit_ctor_locktype +@ thiscall -arch=i386 ??0_Lockit@std@@QAE@H@Z(ptr long) _Lockit_ctor_locktype +@ cdecl -arch=win64 ??0_Lockit@std@@QEAA@H@Z(ptr long) _Lockit_ctor_locktype +@ cdecl -arch=arm ??0_Lockit@std@@QAA@XZ(ptr) _Lockit_ctor +@ thiscall -arch=i386 ??0_Lockit@std@@QAE@XZ(ptr) _Lockit_ctor +@ cdecl -arch=win64 ??0_Lockit@std@@QEAA@XZ(ptr) _Lockit_ctor +@ stub -arch=arm ??0_Pad@std@@QAA@ABV01@@Z +@ stub -arch=i386 ??0_Pad@std@@QAE@ABV01@@Z +@ stub -arch=win64 ??0_Pad@std@@QEAA@AEBV01@@Z +@ stub -arch=arm ??0_Pad@std@@QAA@XZ +@ stub -arch=i386 ??0_Pad@std@@QAE@XZ +@ stub -arch=win64 ??0_Pad@std@@QEAA@XZ +@ stub -arch=arm ??0_Runtime_object@details@Concurrency@@QAA@H@Z +@ stub -arch=i386 ??0_Runtime_object@details@Concurrency@@QAE@H@Z +@ stub -arch=win64 ??0_Runtime_object@details@Concurrency@@QEAA@H@Z +@ stub -arch=arm ??0_Runtime_object@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_Runtime_object@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_Runtime_object@details@Concurrency@@QEAA@XZ +@ cdecl -arch=arm ??0_Timevec@std@@QAA@ABV01@@Z(ptr ptr) _Timevec_copy_ctor +@ thiscall -arch=i386 ??0_Timevec@std@@QAE@ABV01@@Z(ptr ptr) _Timevec_copy_ctor +@ cdecl -arch=win64 ??0_Timevec@std@@QEAA@AEBV01@@Z(ptr ptr) _Timevec_copy_ctor +@ cdecl -arch=arm ??0_Timevec@std@@QAA@PAX@Z(ptr ptr) _Timevec_ctor_timeptr +@ thiscall -arch=i386 ??0_Timevec@std@@QAE@PAX@Z(ptr ptr) _Timevec_ctor_timeptr +@ cdecl -arch=win64 ??0_Timevec@std@@QEAA@PEAX@Z(ptr ptr) _Timevec_ctor_timeptr +@ stub -arch=arm ??0_UShinit@std@@QAA@XZ +@ stub -arch=i386 ??0_UShinit@std@@QAE@XZ +@ stub -arch=win64 ??0_UShinit@std@@QEAA@XZ +@ cdecl -arch=arm ??0_Winit@std@@QAA@XZ(ptr) _Winit_ctor +@ thiscall -arch=i386 ??0_Winit@std@@QAE@XZ(ptr) _Winit_ctor +@ cdecl -arch=win64 ??0_Winit@std@@QEAA@XZ(ptr) _Winit_ctor +@ stub -arch=arm ??0agent@Concurrency@@QAA@AAVScheduleGroup@1@@Z +@ stub -arch=i386 ??0agent@Concurrency@@QAE@AAVScheduleGroup@1@@Z +@ stub -arch=win64 ??0agent@Concurrency@@QEAA@AEAVScheduleGroup@1@@Z +@ stub -arch=arm ??0agent@Concurrency@@QAA@AAVScheduler@1@@Z +@ stub -arch=i386 ??0agent@Concurrency@@QAE@AAVScheduler@1@@Z +@ stub -arch=win64 ??0agent@Concurrency@@QEAA@AEAVScheduler@1@@Z +@ stub -arch=arm ??0agent@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0agent@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0agent@Concurrency@@QEAA@XZ +@ cdecl -arch=arm ??0codecvt_base@std@@QAA@I@Z(ptr long) codecvt_base_ctor_refs +@ thiscall -arch=i386 ??0codecvt_base@std@@QAE@I@Z(ptr long) codecvt_base_ctor_refs +@ cdecl -arch=win64 ??0codecvt_base@std@@QEAA@_K@Z(ptr long) codecvt_base_ctor_refs +@ cdecl -arch=arm ??0ctype_base@std@@QAA@I@Z(ptr long) ctype_base_ctor_refs +@ thiscall -arch=i386 ??0ctype_base@std@@QAE@I@Z(ptr long) ctype_base_ctor_refs +@ cdecl -arch=win64 ??0ctype_base@std@@QEAA@_K@Z(ptr long) ctype_base_ctor_refs +@ cdecl -arch=arm ??0facet@locale@std@@IAA@I@Z(ptr long) locale_facet_ctor_refs +@ thiscall -arch=i386 ??0facet@locale@std@@IAE@I@Z(ptr long) locale_facet_ctor_refs +@ cdecl -arch=win64 ??0facet@locale@std@@IEAA@_K@Z(ptr long) locale_facet_ctor_refs +@ cdecl -arch=arm ??0id@locale@std@@QAA@I@Z(ptr long) locale_id_ctor_id +@ thiscall -arch=i386 ??0id@locale@std@@QAE@I@Z(ptr long) locale_id_ctor_id +@ cdecl -arch=win64 ??0id@locale@std@@QEAA@_K@Z(ptr long) locale_id_ctor_id +@ cdecl -arch=arm ??0ios_base@std@@IAA@XZ(ptr) ios_base_ctor +@ thiscall -arch=i386 ??0ios_base@std@@IAE@XZ(ptr) ios_base_ctor +@ cdecl -arch=win64 ??0ios_base@std@@IEAA@XZ(ptr) ios_base_ctor +@ stub -arch=arm ??0time_base@std@@QAA@I@Z +@ stub -arch=i386 ??0time_base@std@@QAE@I@Z +@ stub -arch=win64 ??0time_base@std@@QEAA@_K@Z +@ cdecl -arch=arm ??1?$_Yarn@D@std@@QAA@XZ(ptr) _Yarn_char_dtor +@ thiscall -arch=i386 ??1?$_Yarn@D@std@@QAE@XZ(ptr) _Yarn_char_dtor +@ cdecl -arch=win64 ??1?$_Yarn@D@std@@QEAA@XZ(ptr) _Yarn_char_dtor +@ stub -arch=arm ??1?$_Yarn@_W@std@@QAA@XZ +@ stub -arch=i386 ??1?$_Yarn@_W@std@@QAE@XZ +@ stub -arch=win64 ??1?$_Yarn@_W@std@@QEAA@XZ +@ cdecl -arch=arm ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UAA@XZ(ptr) basic_ios_char_dtor +@ thiscall -arch=i386 ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UAE@XZ(ptr) basic_ios_char_dtor +@ cdecl -arch=win64 ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UEAA@XZ(ptr) basic_ios_char_dtor +@ cdecl -arch=arm ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UAA@XZ(ptr) basic_ios_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UAE@XZ(ptr) basic_ios_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UEAA@XZ(ptr) basic_ios_wchar_dtor +@ cdecl -arch=arm ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UAA@XZ(ptr) basic_ios_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UAE@XZ(ptr) basic_ios_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UEAA@XZ(ptr) basic_ios_wchar_dtor +@ cdecl -arch=arm ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UAA@XZ(ptr) basic_iostream_char_dtor +@ thiscall -arch=i386 ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UAE@XZ(ptr) basic_iostream_char_dtor +@ cdecl -arch=win64 ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UEAA@XZ(ptr) basic_iostream_char_dtor +@ cdecl -arch=arm ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UAA@XZ(ptr) basic_iostream_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UAE@XZ(ptr) basic_iostream_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UEAA@XZ(ptr) basic_iostream_wchar_dtor +@ cdecl -arch=arm ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UAA@XZ(ptr) basic_iostream_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UAE@XZ(ptr) basic_iostream_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ(ptr) basic_iostream_wchar_dtor +@ cdecl -arch=arm ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UAA@XZ(ptr) basic_istream_char_dtor +@ thiscall -arch=i386 ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UAE@XZ(ptr) basic_istream_char_dtor +@ cdecl -arch=win64 ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UEAA@XZ(ptr) basic_istream_char_dtor +@ cdecl -arch=arm ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UAA@XZ(ptr) basic_istream_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UAE@XZ(ptr) basic_istream_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UEAA@XZ(ptr) basic_istream_wchar_dtor +@ cdecl -arch=arm ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UAA@XZ(ptr) basic_istream_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UAE@XZ(ptr) basic_istream_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ(ptr) basic_istream_wchar_dtor +@ cdecl -arch=arm ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UAA@XZ(ptr) basic_ostream_char_dtor +@ thiscall -arch=i386 ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UAE@XZ(ptr) basic_ostream_char_dtor +@ cdecl -arch=win64 ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UEAA@XZ(ptr) basic_ostream_char_dtor +@ cdecl -arch=arm ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UAA@XZ(ptr) basic_ostream_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UAE@XZ(ptr) basic_ostream_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UEAA@XZ(ptr) basic_ostream_wchar_dtor +@ cdecl -arch=arm ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UAA@XZ(ptr) basic_ostream_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UAE@XZ(ptr) basic_ostream_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ(ptr) basic_ostream_wchar_dtor +@ cdecl -arch=arm ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAA@XZ(ptr) basic_streambuf_char_dtor +@ thiscall -arch=i386 ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAE@XZ(ptr) basic_streambuf_char_dtor +@ cdecl -arch=win64 ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UEAA@XZ(ptr) basic_streambuf_char_dtor +@ cdecl -arch=arm ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAA@XZ(ptr) basic_streambuf_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAE@XZ(ptr) basic_streambuf_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UEAA@XZ(ptr) basic_streambuf_wchar_dtor +@ cdecl -arch=arm ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAA@XZ(ptr) basic_streambuf_wchar_dtor +@ thiscall -arch=i386 ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAE@XZ(ptr) basic_streambuf_wchar_dtor +@ cdecl -arch=win64 ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UEAA@XZ(ptr) basic_streambuf_wchar_dtor +@ cdecl -arch=arm ??1?$codecvt@DDH@std@@MAA@XZ(ptr) codecvt_char_dtor +@ thiscall -arch=i386 ??1?$codecvt@DDH@std@@MAE@XZ(ptr) codecvt_char_dtor +@ cdecl -arch=win64 ??1?$codecvt@DDH@std@@MEAA@XZ(ptr) codecvt_char_dtor +@ cdecl -arch=arm ??1?$codecvt@GDH@std@@MAA@XZ(ptr) codecvt_wchar_dtor +@ thiscall -arch=i386 ??1?$codecvt@GDH@std@@MAE@XZ(ptr) codecvt_wchar_dtor +@ cdecl -arch=win64 ??1?$codecvt@GDH@std@@MEAA@XZ(ptr) codecvt_wchar_dtor +@ cdecl -arch=arm ??1?$codecvt@_WDH@std@@MAA@XZ(ptr) codecvt_wchar_dtor +@ thiscall -arch=i386 ??1?$codecvt@_WDH@std@@MAE@XZ(ptr) codecvt_wchar_dtor +@ cdecl -arch=win64 ??1?$codecvt@_WDH@std@@MEAA@XZ(ptr) codecvt_wchar_dtor +@ cdecl -arch=arm ??1?$ctype@D@std@@MAA@XZ(ptr) ctype_char_dtor +@ thiscall -arch=i386 ??1?$ctype@D@std@@MAE@XZ(ptr) ctype_char_dtor +@ cdecl -arch=win64 ??1?$ctype@D@std@@MEAA@XZ(ptr) ctype_char_dtor +@ cdecl -arch=arm ??1?$ctype@G@std@@MAA@XZ(ptr) ctype_wchar_dtor +@ thiscall -arch=i386 ??1?$ctype@G@std@@MAE@XZ(ptr) ctype_wchar_dtor +@ cdecl -arch=win64 ??1?$ctype@G@std@@MEAA@XZ(ptr) ctype_wchar_dtor +@ cdecl -arch=arm ??1?$ctype@_W@std@@MAA@XZ(ptr) ctype_wchar_dtor +@ thiscall -arch=i386 ??1?$ctype@_W@std@@MAE@XZ(ptr) ctype_wchar_dtor +@ cdecl -arch=win64 ??1?$ctype@_W@std@@MEAA@XZ(ptr) ctype_wchar_dtor +@ cdecl -arch=arm ??1?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAA@XZ(ptr) num_get_char_dtor +@ thiscall -arch=i386 ??1?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAE@XZ(ptr) num_get_char_dtor +@ cdecl -arch=win64 ??1?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEAA@XZ(ptr) num_get_char_dtor +@ cdecl -arch=arm ??1?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAA@XZ(ptr) num_get_wchar_dtor +@ thiscall -arch=i386 ??1?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAE@XZ(ptr) num_get_wchar_dtor +@ cdecl -arch=win64 ??1?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEAA@XZ(ptr) num_get_wchar_dtor +@ cdecl -arch=arm ??1?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAA@XZ(ptr) num_get_wchar_dtor +@ thiscall -arch=i386 ??1?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAE@XZ(ptr) num_get_wchar_dtor +@ cdecl -arch=win64 ??1?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEAA@XZ(ptr) num_get_wchar_dtor +@ cdecl -arch=arm ??1?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAA@XZ(ptr) num_put_char_dtor +@ thiscall -arch=i386 ??1?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAE@XZ(ptr) num_put_char_dtor +@ cdecl -arch=win64 ??1?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEAA@XZ(ptr) num_put_char_dtor +@ cdecl -arch=arm ??1?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAA@XZ(ptr) num_put_wchar_dtor +@ thiscall -arch=i386 ??1?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAE@XZ(ptr) num_put_wchar_dtor +@ cdecl -arch=win64 ??1?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEAA@XZ(ptr) num_put_wchar_dtor +@ cdecl -arch=arm ??1?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAA@XZ(ptr) num_put_wchar_dtor +@ thiscall -arch=i386 ??1?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAE@XZ(ptr) num_put_wchar_dtor +@ cdecl -arch=win64 ??1?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEAA@XZ(ptr) num_put_wchar_dtor +@ stub -arch=arm ??1?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAA@XZ +@ stub -arch=i386 ??1?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAE@XZ +@ stub -arch=win64 ??1?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEAA@XZ +@ stub -arch=arm ??1?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAA@XZ +@ stub -arch=i386 ??1?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAE@XZ +@ stub -arch=win64 ??1?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEAA@XZ +@ stub -arch=arm ??1?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAA@XZ +@ stub -arch=i386 ??1?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAE@XZ +@ stub -arch=win64 ??1?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEAA@XZ +@ cdecl -arch=arm ??1?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAA@XZ(ptr) time_put_char_dtor +@ thiscall -arch=i386 ??1?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAE@XZ(ptr) time_put_char_dtor +@ cdecl -arch=win64 ??1?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEAA@XZ(ptr) time_put_char_dtor +@ cdecl -arch=arm ??1?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAA@XZ(ptr) time_put_wchar_dtor +@ thiscall -arch=i386 ??1?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAE@XZ(ptr) time_put_wchar_dtor +@ cdecl -arch=win64 ??1?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEAA@XZ(ptr) time_put_wchar_dtor +@ cdecl -arch=arm ??1?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAA@XZ(ptr) time_put_wchar_dtor +@ thiscall -arch=i386 ??1?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAE@XZ(ptr) time_put_wchar_dtor +@ cdecl -arch=win64 ??1?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEAA@XZ(ptr) time_put_wchar_dtor +@ cdecl -arch=arm ??1Init@ios_base@std@@QAA@XZ(ptr) ios_base_Init_dtor +@ thiscall -arch=i386 ??1Init@ios_base@std@@QAE@XZ(ptr) ios_base_Init_dtor +@ cdecl -arch=win64 ??1Init@ios_base@std@@QEAA@XZ(ptr) ios_base_Init_dtor +@ stub -arch=arm ??1_Concurrent_queue_base_v4@details@Concurrency@@MAA@XZ +@ stub -arch=i386 ??1_Concurrent_queue_base_v4@details@Concurrency@@MAE@XZ +@ stub -arch=win64 ??1_Concurrent_queue_base_v4@details@Concurrency@@MEAA@XZ +@ stub -arch=arm ??1_Concurrent_queue_iterator_base_v4@details@Concurrency@@IAA@XZ +@ stub -arch=i386 ??1_Concurrent_queue_iterator_base_v4@details@Concurrency@@IAE@XZ +@ stub -arch=win64 ??1_Concurrent_queue_iterator_base_v4@details@Concurrency@@IEAA@XZ +@ stub -arch=arm ??1_Concurrent_vector_base_v4@details@Concurrency@@IAA@XZ +@ stub -arch=i386 ??1_Concurrent_vector_base_v4@details@Concurrency@@IAE@XZ +@ stub -arch=win64 ??1_Concurrent_vector_base_v4@details@Concurrency@@IEAA@XZ +@ cdecl -arch=arm ??1_Container_base12@std@@QAA@XZ(ptr) _Container_base12_dtor +@ thiscall -arch=i386 ??1_Container_base12@std@@QAE@XZ(ptr) _Container_base12_dtor +@ cdecl -arch=win64 ??1_Container_base12@std@@QEAA@XZ(ptr) _Container_base12_dtor +@ stub -arch=arm ??1_Facet_base@std@@UAA@XZ +@ stub -arch=i386 ??1_Facet_base@std@@UAE@XZ +@ stub -arch=win64 ??1_Facet_base@std@@UEAA@XZ +@ stub -arch=arm ??1_Init_locks@std@@QAA@XZ +@ stub -arch=i386 ??1_Init_locks@std@@QAE@XZ +@ stub -arch=win64 ??1_Init_locks@std@@QEAA@XZ +@ cdecl -arch=arm ??1_Locimp@locale@std@@MAA@XZ(ptr) locale__Locimp_dtor +@ thiscall -arch=i386 ??1_Locimp@locale@std@@MAE@XZ(ptr) locale__Locimp_dtor +@ cdecl -arch=win64 ??1_Locimp@locale@std@@MEAA@XZ(ptr) locale__Locimp_dtor +@ cdecl -arch=arm ??1_Locinfo@std@@QAA@XZ(ptr) _Locinfo_dtor +@ thiscall -arch=i386 ??1_Locinfo@std@@QAE@XZ(ptr) _Locinfo_dtor +@ cdecl -arch=win64 ??1_Locinfo@std@@QEAA@XZ(ptr) _Locinfo_dtor +@ cdecl -arch=arm ??1_Lockit@std@@QAA@XZ(ptr) _Lockit_dtor +@ thiscall -arch=i386 ??1_Lockit@std@@QAE@XZ(ptr) _Lockit_dtor +@ cdecl -arch=win64 ??1_Lockit@std@@QEAA@XZ(ptr) _Lockit_dtor +@ stub -arch=arm ??1_Pad@std@@QAA@XZ +@ stub -arch=i386 ??1_Pad@std@@QAE@XZ +@ stub -arch=win64 ??1_Pad@std@@QEAA@XZ +@ cdecl -arch=arm ??1_Timevec@std@@QAA@XZ(ptr) _Timevec_dtor +@ thiscall -arch=i386 ??1_Timevec@std@@QAE@XZ(ptr) _Timevec_dtor +@ cdecl -arch=win64 ??1_Timevec@std@@QEAA@XZ(ptr) _Timevec_dtor +@ stub -arch=arm ??1_UShinit@std@@QAA@XZ +@ stub -arch=i386 ??1_UShinit@std@@QAE@XZ +@ stub -arch=win64 ??1_UShinit@std@@QEAA@XZ +@ cdecl -arch=arm ??1_Winit@std@@QAA@XZ(ptr) _Winit_dtor +@ thiscall -arch=i386 ??1_Winit@std@@QAE@XZ(ptr) _Winit_dtor +@ cdecl -arch=win64 ??1_Winit@std@@QEAA@XZ(ptr) _Winit_dtor +@ stub -arch=arm ??1agent@Concurrency@@UAA@XZ +@ stub -arch=i386 ??1agent@Concurrency@@UAE@XZ +@ stub -arch=win64 ??1agent@Concurrency@@UEAA@XZ +@ cdecl -arch=arm ??1codecvt_base@std@@UAA@XZ(ptr) codecvt_base_dtor +@ thiscall -arch=i386 ??1codecvt_base@std@@UAE@XZ(ptr) codecvt_base_dtor +@ cdecl -arch=win64 ??1codecvt_base@std@@UEAA@XZ(ptr) codecvt_base_dtor +@ cdecl -arch=arm ??1ctype_base@std@@UAA@XZ(ptr) ctype_base_dtor +@ thiscall -arch=i386 ??1ctype_base@std@@UAE@XZ(ptr) ctype_base_dtor +@ cdecl -arch=win64 ??1ctype_base@std@@UEAA@XZ(ptr) ctype_base_dtor +@ stub -arch=arm ??1facet@locale@std@@MAA@XZ +@ stub -arch=i386 ??1facet@locale@std@@MAE@XZ +@ stub -arch=win64 ??1facet@locale@std@@MEAA@XZ +@ cdecl -arch=arm ??1ios_base@std@@UAA@XZ(ptr) ios_base_dtor +@ thiscall -arch=i386 ??1ios_base@std@@UAE@XZ(ptr) ios_base_dtor +@ cdecl -arch=win64 ??1ios_base@std@@UEAA@XZ(ptr) ios_base_dtor +@ stub -arch=arm ??1time_base@std@@UAA@XZ +@ stub -arch=i386 ??1time_base@std@@UAE@XZ +@ stub -arch=win64 ??1time_base@std@@UEAA@XZ +@ stub -arch=arm ??4?$_Iosb@H@std@@QAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4?$_Iosb@H@std@@QAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4?$_Iosb@H@std@@QEAAAEAV01@AEBV01@@Z +@ cdecl -arch=arm ??4?$_Yarn@D@std@@QAAAAV01@ABV01@@Z(ptr ptr) _Yarn_char_op_assign +@ thiscall -arch=i386 ??4?$_Yarn@D@std@@QAEAAV01@ABV01@@Z(ptr ptr) _Yarn_char_op_assign +@ cdecl -arch=win64 ??4?$_Yarn@D@std@@QEAAAEAV01@AEBV01@@Z(ptr ptr) _Yarn_char_op_assign +@ cdecl -arch=arm ??4?$_Yarn@D@std@@QAAAAV01@PBD@Z(ptr str) _Yarn_char_op_assign_cstr +@ thiscall -arch=i386 ??4?$_Yarn@D@std@@QAEAAV01@PBD@Z(ptr str) _Yarn_char_op_assign_cstr +@ cdecl -arch=win64 ??4?$_Yarn@D@std@@QEAAAEAV01@PEBD@Z(ptr str) _Yarn_char_op_assign_cstr +@ stub -arch=arm ??4?$_Yarn@_W@std@@QAAAAV01@PB_W@Z +@ stub -arch=i386 ??4?$_Yarn@_W@std@@QAEAAV01@PB_W@Z +@ stub -arch=win64 ??4?$_Yarn@_W@std@@QEAAAEAV01@PEB_W@Z +@ stub -arch=arm ??4?$basic_iostream@DU?$char_traits@D@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_iostream@DU?$char_traits@D@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_iostream@DU?$char_traits@D@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_iostream@GU?$char_traits@G@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_iostream@GU?$char_traits@G@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_iostream@GU?$char_traits@G@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_istream@DU?$char_traits@D@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_istream@DU?$char_traits@D@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_istream@DU?$char_traits@D@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_istream@GU?$char_traits@G@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_istream@GU?$char_traits@G@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_istream@GU?$char_traits@G@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_istream@_WU?$char_traits@_W@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_istream@_WU?$char_traits@_W@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_istream@_WU?$char_traits@_W@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_ostream@DU?$char_traits@D@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_ostream@DU?$char_traits@D@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_ostream@DU?$char_traits@D@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_ostream@GU?$char_traits@G@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_ostream@GU?$char_traits@G@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_ostream@GU?$char_traits@G@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IAAAAV01@$$QAV01@@Z +@ stub -arch=i386 ??4?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IAEAAV01@$$QAV01@@Z +@ stub -arch=win64 ??4?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IEAAAEAV01@$$QEAV01@@Z +@ stub -arch=arm ??4?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAAEAV01@AEBV01@@Z +@ stub -arch=arm ??4?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAAEAV01@AEBV01@@Z +@ stub -arch=arm ??4?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAAEAV01@AEBV01@@Z +@ cdecl -arch=arm ??4Init@ios_base@std@@QAAAAV012@ABV012@@Z(ptr ptr) ios_base_Init_op_assign +@ thiscall -arch=i386 ??4Init@ios_base@std@@QAEAAV012@ABV012@@Z(ptr ptr) ios_base_Init_op_assign +@ cdecl -arch=win64 ??4Init@ios_base@std@@QEAAAEAV012@AEBV012@@Z(ptr ptr) ios_base_Init_op_assign +@ cdecl -arch=arm ??4_Container_base0@std@@QAAAAU01@ABU01@@Z(ptr ptr) Container_base0_op_assign +@ thiscall -arch=i386 ??4_Container_base0@std@@QAEAAU01@ABU01@@Z(ptr ptr) Container_base0_op_assign +@ cdecl -arch=win64 ??4_Container_base0@std@@QEAAAEAU01@AEBU01@@Z(ptr ptr) Container_base0_op_assign +@ cdecl -arch=arm ??4_Container_base12@std@@QAAAAU01@ABU01@@Z(ptr ptr) _Container_base12_op_assign +@ thiscall -arch=i386 ??4_Container_base12@std@@QAEAAU01@ABU01@@Z(ptr ptr) _Container_base12_op_assign +@ cdecl -arch=win64 ??4_Container_base12@std@@QEAAAEAU01@AEBU01@@Z(ptr ptr) _Container_base12_op_assign +@ stub -arch=arm ??4_Facet_base@std@@QAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4_Facet_base@std@@QAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4_Facet_base@std@@QEAAAEAV01@AEBV01@@Z +@ stub -arch=arm ??4_Init_locks@std@@QAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4_Init_locks@std@@QAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4_Init_locks@std@@QEAAAEAV01@AEBV01@@Z +@ stub -arch=arm ??4_Pad@std@@QAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4_Pad@std@@QAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4_Pad@std@@QEAAAEAV01@AEBV01@@Z +@ cdecl -arch=arm ??4_Timevec@std@@QAAAAV01@ABV01@@Z(ptr ptr) _Timevec_op_assign +@ thiscall -arch=i386 ??4_Timevec@std@@QAEAAV01@ABV01@@Z(ptr ptr) _Timevec_op_assign +@ cdecl -arch=win64 ??4_Timevec@std@@QEAAAEAV01@AEBV01@@Z(ptr ptr) _Timevec_op_assign +@ stub -arch=arm ??4_UShinit@std@@QAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4_UShinit@std@@QAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4_UShinit@std@@QEAAAEAV01@AEBV01@@Z +@ cdecl -arch=arm ??4_Winit@std@@QAAAAV01@ABV01@@Z(ptr ptr) _Winit_op_assign +@ thiscall -arch=i386 ??4_Winit@std@@QAEAAV01@ABV01@@Z(ptr ptr) _Winit_op_assign +@ cdecl -arch=win64 ??4_Winit@std@@QEAAAEAV01@AEBV01@@Z(ptr ptr) _Winit_op_assign +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAF@Z(ptr ptr) basic_istream_char_read_short +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAF@Z(ptr ptr) basic_istream_char_read_short +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAF@Z(ptr ptr) basic_istream_char_read_short +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAG@Z(ptr ptr) basic_istream_char_read_ushort +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAG@Z(ptr ptr) basic_istream_char_read_ushort +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAG@Z(ptr ptr) basic_istream_char_read_ushort +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAH@Z(ptr ptr) basic_istream_char_read_int +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAH@Z(ptr ptr) basic_istream_char_read_int +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAH@Z(ptr ptr) basic_istream_char_read_int +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAI@Z(ptr ptr) basic_istream_char_read_uint +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAI@Z(ptr ptr) basic_istream_char_read_uint +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAI@Z(ptr ptr) basic_istream_char_read_uint +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAJ@Z(ptr ptr) basic_istream_char_read_long +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAJ@Z(ptr ptr) basic_istream_char_read_long +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAJ@Z(ptr ptr) basic_istream_char_read_long +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAK@Z(ptr ptr) basic_istream_char_read_ulong +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAK@Z(ptr ptr) basic_istream_char_read_ulong +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAK@Z(ptr ptr) basic_istream_char_read_ulong +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAM@Z(ptr ptr) basic_istream_char_read_float +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAM@Z(ptr ptr) basic_istream_char_read_float +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAM@Z(ptr ptr) basic_istream_char_read_float +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAN@Z(ptr ptr) basic_istream_char_read_double +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAN@Z(ptr ptr) basic_istream_char_read_double +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAN@Z(ptr ptr) basic_istream_char_read_double +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAO@Z(ptr ptr) basic_istream_char_read_ldouble +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAO@Z(ptr ptr) basic_istream_char_read_ldouble +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAO@Z(ptr ptr) basic_istream_char_read_ldouble +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAPAX@Z(ptr ptr) basic_istream_char_read_ptr +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAPAX@Z(ptr ptr) basic_istream_char_read_ptr +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAPEAX@Z(ptr ptr) basic_istream_char_read_ptr +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AA_J@Z(ptr ptr) basic_istream_char_read_int64 +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_J@Z(ptr ptr) basic_istream_char_read_int64 +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_J@Z(ptr ptr) basic_istream_char_read_int64 +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AA_K@Z(ptr ptr) basic_istream_char_read_uint64 +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_K@Z(ptr ptr) basic_istream_char_read_uint64 +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_K@Z(ptr ptr) basic_istream_char_read_uint64 +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AA_N@Z(ptr ptr) basic_istream_char_read_bool +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_N@Z(ptr ptr) basic_istream_char_read_bool +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_N@Z(ptr ptr) basic_istream_char_read_bool +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_istream_char_read_func +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_istream_char_read_func +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z(ptr ptr) basic_istream_char_read_func +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z(ptr ptr) basic_istream_char_read_func_basic_ios +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z(ptr ptr) basic_istream_char_read_func_basic_ios +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@DU?$char_traits@D@std@@@1@AEAV21@@Z@Z(ptr ptr) basic_istream_char_read_func_basic_ios +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_istream_char_read_func_ios_base +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_istream_char_read_func_ios_base +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z(ptr ptr) basic_istream_char_read_func_ios_base +@ cdecl -arch=arm ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_istream_char_read_streambuf +@ thiscall -arch=i386 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_istream_char_read_streambuf +@ cdecl -arch=win64 ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_istream_char_read_streambuf +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAF@Z(ptr ptr) basic_istream_short_read_short +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAF@Z(ptr ptr) basic_istream_short_read_short +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAF@Z(ptr ptr) basic_istream_short_read_short +@ stub -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAG@Z +@ stub -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAG@Z +@ stub -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAG@Z +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAH@Z(ptr ptr) basic_istream_short_read_int +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAH@Z(ptr ptr) basic_istream_short_read_int +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAH@Z(ptr ptr) basic_istream_short_read_int +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAI@Z(ptr ptr) basic_istream_short_read_uint +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAI@Z(ptr ptr) basic_istream_short_read_uint +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAI@Z(ptr ptr) basic_istream_short_read_uint +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAJ@Z(ptr ptr) basic_istream_short_read_long +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAJ@Z(ptr ptr) basic_istream_short_read_long +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAJ@Z(ptr ptr) basic_istream_short_read_long +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAK@Z(ptr ptr) basic_istream_short_read_ulong +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAK@Z(ptr ptr) basic_istream_short_read_ulong +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAK@Z(ptr ptr) basic_istream_short_read_ulong +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAM@Z(ptr ptr) basic_istream_short_read_float +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAM@Z(ptr ptr) basic_istream_short_read_float +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAM@Z(ptr ptr) basic_istream_short_read_float +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAN@Z(ptr ptr) basic_istream_short_read_double +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAN@Z(ptr ptr) basic_istream_short_read_double +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAN@Z(ptr ptr) basic_istream_short_read_double +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAO@Z(ptr ptr) basic_istream_short_read_ldouble +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAO@Z(ptr ptr) basic_istream_short_read_ldouble +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAO@Z(ptr ptr) basic_istream_short_read_ldouble +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AAPAX@Z(ptr ptr) basic_istream_short_read_ptr +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAPAX@Z(ptr ptr) basic_istream_short_read_ptr +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAPEAX@Z(ptr ptr) basic_istream_short_read_ptr +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AA_J@Z(ptr ptr) basic_istream_short_read_int64 +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_J@Z(ptr ptr) basic_istream_short_read_int64 +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_J@Z(ptr ptr) basic_istream_short_read_int64 +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AA_K@Z(ptr ptr) basic_istream_short_read_uint64 +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_K@Z(ptr ptr) basic_istream_short_read_uint64 +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_K@Z(ptr ptr) basic_istream_short_read_uint64 +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@AA_N@Z(ptr ptr) basic_istream_short_read_bool +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_N@Z(ptr ptr) basic_istream_short_read_bool +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_N@Z(ptr ptr) basic_istream_short_read_bool +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_istream_wchar_read_func +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_istream_wchar_read_func +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z(ptr ptr) basic_istream_wchar_read_func +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_basic_ios +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_basic_ios +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@GU?$char_traits@G@std@@@1@AEAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_basic_ios +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_ios_base +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_ios_base +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_ios_base +@ cdecl -arch=arm ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_istream_wchar_read_streambuf +@ thiscall -arch=i386 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_istream_wchar_read_streambuf +@ cdecl -arch=win64 ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_istream_wchar_read_streambuf +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAF@Z(ptr ptr) basic_istream_wchar_read_short +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAF@Z(ptr ptr) basic_istream_wchar_read_short +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAF@Z(ptr ptr) basic_istream_wchar_read_short +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAG@Z(ptr ptr) basic_istream_wchar_read_ushort +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAG@Z(ptr ptr) basic_istream_wchar_read_ushort +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAG@Z(ptr ptr) basic_istream_wchar_read_ushort +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAH@Z(ptr ptr) basic_istream_wchar_read_int +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAH@Z(ptr ptr) basic_istream_wchar_read_int +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAH@Z(ptr ptr) basic_istream_wchar_read_int +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAI@Z(ptr ptr) basic_istream_wchar_read_uint +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAI@Z(ptr ptr) basic_istream_wchar_read_uint +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAI@Z(ptr ptr) basic_istream_wchar_read_uint +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAJ@Z(ptr ptr) basic_istream_wchar_read_long +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAJ@Z(ptr ptr) basic_istream_wchar_read_long +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAJ@Z(ptr ptr) basic_istream_wchar_read_long +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAK@Z(ptr ptr) basic_istream_wchar_read_ulong +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAK@Z(ptr ptr) basic_istream_wchar_read_ulong +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAK@Z(ptr ptr) basic_istream_wchar_read_ulong +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAM@Z(ptr ptr) basic_istream_wchar_read_float +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAM@Z(ptr ptr) basic_istream_wchar_read_float +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAM@Z(ptr ptr) basic_istream_wchar_read_float +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAN@Z(ptr ptr) basic_istream_wchar_read_double +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAN@Z(ptr ptr) basic_istream_wchar_read_double +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAN@Z(ptr ptr) basic_istream_wchar_read_double +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAO@Z(ptr ptr) basic_istream_wchar_read_ldouble +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAO@Z(ptr ptr) basic_istream_wchar_read_ldouble +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAO@Z(ptr ptr) basic_istream_wchar_read_ldouble +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AAPAX@Z(ptr ptr) basic_istream_wchar_read_ptr +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAPAX@Z(ptr ptr) basic_istream_wchar_read_ptr +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAPEAX@Z(ptr ptr) basic_istream_wchar_read_ptr +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AA_J@Z(ptr ptr) basic_istream_wchar_read_int64 +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_J@Z(ptr ptr) basic_istream_wchar_read_int64 +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_J@Z(ptr ptr) basic_istream_wchar_read_int64 +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AA_K@Z(ptr ptr) basic_istream_wchar_read_uint64 +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_K@Z(ptr ptr) basic_istream_wchar_read_uint64 +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_K@Z(ptr ptr) basic_istream_wchar_read_uint64 +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@AA_N@Z(ptr ptr) basic_istream_wchar_read_bool +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_N@Z(ptr ptr) basic_istream_wchar_read_bool +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_N@Z(ptr ptr) basic_istream_wchar_read_bool +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_istream_wchar_read_func +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_istream_wchar_read_func +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z(ptr ptr) basic_istream_wchar_read_func +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_basic_ios +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_basic_ios +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AEAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_basic_ios +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_ios_base +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_ios_base +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z(ptr ptr) basic_istream_wchar_read_func_ios_base +@ cdecl -arch=arm ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_istream_wchar_read_streambuf +@ thiscall -arch=i386 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_istream_wchar_read_streambuf +@ cdecl -arch=win64 ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_istream_wchar_read_streambuf +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@F@Z(ptr long) basic_ostream_char_print_short +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@F@Z(ptr long) basic_ostream_char_print_short +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@F@Z(ptr long) basic_ostream_char_print_short +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@G@Z(ptr long) basic_ostream_char_print_ushort +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@G@Z(ptr long) basic_ostream_char_print_ushort +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@G@Z(ptr long) basic_ostream_char_print_ushort +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@H@Z(ptr long) basic_ostream_char_print_int +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@H@Z(ptr long) basic_ostream_char_print_int +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@H@Z(ptr long) basic_ostream_char_print_int +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@I@Z(ptr long) basic_ostream_char_print_uint +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@I@Z(ptr long) basic_ostream_char_print_uint +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@I@Z(ptr long) basic_ostream_char_print_uint +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@J@Z(ptr long) basic_ostream_char_print_int +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@J@Z(ptr long) basic_ostream_char_print_int +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@J@Z(ptr long) basic_ostream_char_print_int +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@K@Z(ptr long) basic_ostream_char_print_uint +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@K@Z(ptr long) basic_ostream_char_print_uint +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@K@Z(ptr long) basic_ostream_char_print_uint +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@M@Z(ptr float) basic_ostream_char_print_float +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@M@Z(ptr float) basic_ostream_char_print_float +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@M@Z(ptr float) basic_ostream_char_print_float +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@N@Z(ptr double) basic_ostream_char_print_double +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@N@Z(ptr double) basic_ostream_char_print_double +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@N@Z(ptr double) basic_ostream_char_print_double +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@O@Z(ptr double) basic_ostream_char_print_ldouble +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@O@Z(ptr double) basic_ostream_char_print_ldouble +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@O@Z(ptr double) basic_ostream_char_print_ldouble +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_ostream_char_print_func +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_ostream_char_print_func +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z(ptr ptr) basic_ostream_char_print_func +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z(ptr ptr) basic_ostream_char_print_func_basic_ios +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z(ptr ptr) basic_ostream_char_print_func_basic_ios +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@DU?$char_traits@D@std@@@1@AEAV21@@Z@Z(ptr ptr) basic_ostream_char_print_func_basic_ios +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_ostream_char_print_func_ios_base +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_ostream_char_print_func_ios_base +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z(ptr ptr) basic_ostream_char_print_func_ios_base +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_ostream_char_print_streambuf +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_ostream_char_print_streambuf +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z(ptr ptr) basic_ostream_char_print_streambuf +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@PBX@Z(ptr ptr) basic_ostream_char_print_ptr +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@PBX@Z(ptr ptr) basic_ostream_char_print_ptr +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEBX@Z(ptr ptr) basic_ostream_char_print_ptr +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@_J@Z(ptr int64) basic_ostream_char_print_int64 +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_J@Z(ptr int64) basic_ostream_char_print_int64 +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_J@Z(ptr int64) basic_ostream_char_print_int64 +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@_K@Z(ptr int64) basic_ostream_char_print_uint64 +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_K@Z(ptr int64) basic_ostream_char_print_uint64 +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_K@Z(ptr int64) basic_ostream_char_print_uint64 +@ cdecl -arch=arm ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@_N@Z(ptr long) basic_ostream_char_print_bool +@ thiscall -arch=i386 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_N@Z(ptr long) basic_ostream_char_print_bool +@ cdecl -arch=win64 ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_N@Z(ptr long) basic_ostream_char_print_bool +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@F@Z(ptr long) basic_ostream_short_print_short +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@F@Z(ptr long) basic_ostream_short_print_short +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@F@Z(ptr long) basic_ostream_short_print_short +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@G@Z(ptr long) basic_ostream_short_print_ushort +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@G@Z(ptr long) basic_ostream_short_print_ushort +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@G@Z(ptr long) basic_ostream_short_print_ushort +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@H@Z(ptr long) basic_ostream_short_print_int +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@H@Z(ptr long) basic_ostream_short_print_int +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@H@Z(ptr long) basic_ostream_short_print_int +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@I@Z(ptr long) basic_ostream_short_print_uint +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@I@Z(ptr long) basic_ostream_short_print_uint +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@I@Z(ptr long) basic_ostream_short_print_uint +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@J@Z(ptr long) basic_ostream_short_print_int +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@J@Z(ptr long) basic_ostream_short_print_int +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@J@Z(ptr long) basic_ostream_short_print_int +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@K@Z(ptr long) basic_ostream_short_print_uint +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@K@Z(ptr long) basic_ostream_short_print_uint +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@K@Z(ptr long) basic_ostream_short_print_uint +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@M@Z(ptr float) basic_ostream_short_print_float +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@M@Z(ptr float) basic_ostream_short_print_float +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@M@Z(ptr float) basic_ostream_short_print_float +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@N@Z(ptr double) basic_ostream_short_print_double +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@N@Z(ptr double) basic_ostream_short_print_double +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@N@Z(ptr double) basic_ostream_short_print_double +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@O@Z(ptr double) basic_ostream_short_print_ldouble +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@O@Z(ptr double) basic_ostream_short_print_ldouble +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@O@Z(ptr double) basic_ostream_short_print_ldouble +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_ostream_wchar_print_func +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_ostream_wchar_print_func +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z(ptr ptr) basic_ostream_wchar_print_func +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_basic_ios +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_basic_ios +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@GU?$char_traits@G@std@@@1@AEAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_basic_ios +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_ios_base +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_ios_base +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_ios_base +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_ostream_wchar_print_streambuf +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_ostream_wchar_print_streambuf +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z(ptr ptr) basic_ostream_wchar_print_streambuf +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@PBX@Z(ptr ptr) basic_ostream_short_print_ptr +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@PBX@Z(ptr ptr) basic_ostream_short_print_ptr +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEBX@Z(ptr ptr) basic_ostream_short_print_ptr +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@_J@Z(ptr int64) basic_ostream_short_print_int64 +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_J@Z(ptr int64) basic_ostream_short_print_int64 +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_J@Z(ptr int64) basic_ostream_short_print_int64 +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@_K@Z(ptr int64) basic_ostream_short_print_uint64 +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_K@Z(ptr int64) basic_ostream_short_print_uint64 +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_K@Z(ptr int64) basic_ostream_short_print_uint64 +@ cdecl -arch=arm ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@_N@Z(ptr long) basic_ostream_short_print_bool +@ thiscall -arch=i386 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_N@Z(ptr long) basic_ostream_short_print_bool +@ cdecl -arch=win64 ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_N@Z(ptr long) basic_ostream_short_print_bool +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@F@Z(ptr long) basic_ostream_wchar_print_short +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@F@Z(ptr long) basic_ostream_wchar_print_short +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@F@Z(ptr long) basic_ostream_wchar_print_short +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@G@Z(ptr long) basic_ostream_wchar_print_ushort +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@G@Z(ptr long) basic_ostream_wchar_print_ushort +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@G@Z(ptr long) basic_ostream_wchar_print_ushort +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@H@Z(ptr long) basic_ostream_wchar_print_int +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@H@Z(ptr long) basic_ostream_wchar_print_int +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@H@Z(ptr long) basic_ostream_wchar_print_int +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@I@Z(ptr long) basic_ostream_wchar_print_uint +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@I@Z(ptr long) basic_ostream_wchar_print_uint +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@I@Z(ptr long) basic_ostream_wchar_print_uint +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@J@Z(ptr long) basic_ostream_wchar_print_int +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@J@Z(ptr long) basic_ostream_wchar_print_int +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@J@Z(ptr long) basic_ostream_wchar_print_int +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@K@Z(ptr long) basic_ostream_wchar_print_uint +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@K@Z(ptr long) basic_ostream_wchar_print_uint +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@K@Z(ptr long) basic_ostream_wchar_print_uint +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@M@Z(ptr float) basic_ostream_wchar_print_float +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@M@Z(ptr float) basic_ostream_wchar_print_float +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@M@Z(ptr float) basic_ostream_wchar_print_float +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@N@Z(ptr double) basic_ostream_wchar_print_double +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@N@Z(ptr double) basic_ostream_wchar_print_double +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@N@Z(ptr double) basic_ostream_wchar_print_double +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@O@Z(ptr double) basic_ostream_wchar_print_ldouble +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@O@Z(ptr double) basic_ostream_wchar_print_ldouble +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@O@Z(ptr double) basic_ostream_wchar_print_ldouble +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_ostream_wchar_print_func +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z(ptr ptr) basic_ostream_wchar_print_func +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z(ptr ptr) basic_ostream_wchar_print_func +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_basic_ios +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_basic_ios +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AEAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_basic_ios +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_ios_base +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_ios_base +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z(ptr ptr) basic_ostream_wchar_print_func_ios_base +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_ostream_wchar_print_streambuf +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_ostream_wchar_print_streambuf +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z(ptr ptr) basic_ostream_wchar_print_streambuf +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@PBX@Z(ptr ptr) basic_ostream_wchar_print_ptr +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PBX@Z(ptr ptr) basic_ostream_wchar_print_ptr +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEBX@Z(ptr ptr) basic_ostream_wchar_print_ptr +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@_J@Z(ptr int64) basic_ostream_wchar_print_int64 +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_J@Z(ptr int64) basic_ostream_wchar_print_int64 +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_J@Z(ptr int64) basic_ostream_wchar_print_int64 +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@_K@Z(ptr int64) basic_ostream_wchar_print_uint64 +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_K@Z(ptr int64) basic_ostream_wchar_print_uint64 +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_K@Z(ptr int64) basic_ostream_wchar_print_uint64 +@ cdecl -arch=arm ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV01@_N@Z(ptr long) basic_ostream_wchar_print_bool +@ thiscall -arch=i386 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_N@Z(ptr long) basic_ostream_wchar_print_bool +@ cdecl -arch=win64 ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_N@Z(ptr long) basic_ostream_wchar_print_bool +@ cdecl -arch=arm ??7ios_base@std@@QBA_NXZ(ptr) ios_base_op_succ +@ thiscall -arch=i386 ??7ios_base@std@@QBE_NXZ(ptr) ios_base_op_succ +@ cdecl -arch=win64 ??7ios_base@std@@QEBA_NXZ(ptr) ios_base_op_succ +@ cdecl -arch=arm ??Bid@locale@std@@QAAIXZ(ptr) locale_id_operator_size_t +@ thiscall -arch=i386 ??Bid@locale@std@@QAEIXZ(ptr) locale_id_operator_size_t +@ cdecl -arch=win64 ??Bid@locale@std@@QEAA_KXZ(ptr) locale_id_operator_size_t +@ stub -arch=arm ??Bios_base@std@@QBA_NXZ +@ stub -arch=win32 ??Bios_base@std@@QBE_NXZ +@ stub -arch=win64 ??Bios_base@std@@QEBA_NXZ +@ extern ??_7?$basic_ios@DU?$char_traits@D@std@@@std@@6B@ MSVCP_basic_ios_char_vtable +@ extern ??_7?$basic_ios@GU?$char_traits@G@std@@@std@@6B@ MSVCP_basic_ios_short_vtable +@ extern ??_7?$basic_ios@_WU?$char_traits@_W@std@@@std@@6B@ MSVCP_basic_ios_wchar_vtable +@ extern ??_7?$basic_iostream@DU?$char_traits@D@std@@@std@@6B@ MSVCP_basic_iostream_char_vtable +@ extern ??_7?$basic_iostream@GU?$char_traits@G@std@@@std@@6B@ MSVCP_basic_iostream_short_vtable +@ extern ??_7?$basic_iostream@_WU?$char_traits@_W@std@@@std@@6B@ MSVCP_basic_iostream_wchar_vtable +@ extern ??_7?$basic_istream@DU?$char_traits@D@std@@@std@@6B@ MSVCP_basic_istream_char_vtable +@ extern ??_7?$basic_istream@GU?$char_traits@G@std@@@std@@6B@ MSVCP_basic_istream_short_vtable +@ extern ??_7?$basic_istream@_WU?$char_traits@_W@std@@@std@@6B@ MSVCP_basic_istream_wchar_vtable +@ extern ??_7?$basic_ostream@DU?$char_traits@D@std@@@std@@6B@ MSVCP_basic_ostream_char_vtable +@ extern ??_7?$basic_ostream@GU?$char_traits@G@std@@@std@@6B@ MSVCP_basic_ostream_short_vtable +@ extern ??_7?$basic_ostream@_WU?$char_traits@_W@std@@@std@@6B@ MSVCP_basic_ostream_wchar_vtable +@ extern ??_7?$basic_streambuf@DU?$char_traits@D@std@@@std@@6B@ MSVCP_basic_streambuf_char_vtable +@ extern ??_7?$basic_streambuf@GU?$char_traits@G@std@@@std@@6B@ MSVCP_basic_streambuf_short_vtable +@ extern ??_7?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@6B@ MSVCP_basic_streambuf_wchar_vtable +@ extern ??_7?$codecvt@DDH@std@@6B@ MSVCP_codecvt_char_vtable +@ extern ??_7?$codecvt@GDH@std@@6B@ MSVCP_codecvt_short_vtable +@ extern ??_7?$codecvt@_WDH@std@@6B@ MSVCP_codecvt_wchar_vtable +@ extern ??_7?$ctype@D@std@@6B@ MSVCP_ctype_char_vtable +@ extern ??_7?$ctype@G@std@@6B@ MSVCP_ctype_short_vtable +@ extern ??_7?$ctype@_W@std@@6B@ MSVCP_ctype_wchar_vtable +@ extern ??_7?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@6B@ MSVCP_num_get_char_vtable +@ extern ??_7?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@6B@ MSVCP_num_get_short_vtable +@ extern ??_7?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@6B@ MSVCP_num_get_wchar_vtable +@ extern ??_7?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@6B@ MSVCP_num_put_char_vtable +@ extern ??_7?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@6B@ MSVCP_num_put_short_vtable +@ extern ??_7?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@6B@ MSVCP_num_put_wchar_vtable +# extern ??_7?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@6B@ +# extern ??_7?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@6B@ +# extern ??_7?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@6B@ +@ extern ??_7?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@6B@ MSVCP_time_put_char_vtable +@ extern ??_7?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@6B@ MSVCP_time_put_short_vtable +@ extern ??_7?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@6B@ MSVCP_time_put_wchar_vtable +@ stub ??_7_Facet_base@std@@6B@ +@ extern ??_7_Locimp@locale@std@@6B@ MSVCP_locale__Locimp_vtable +@ stub ??_7_Pad@std@@6B@ +@ extern ??_7codecvt_base@std@@6B@ MSVCP_codecvt_base_vtable +@ extern ??_7ctype_base@std@@6B@ MSVCP_ctype_base_vtable +@ extern ??_7facet@locale@std@@6B@ MSVCP_locale_facet_vtable +@ extern ??_7ios_base@std@@6B@ MSVCP_ios_base_vtable +# extern ??_7time_base@std@@6B@ +@ extern ??_8?$basic_iostream@DU?$char_traits@D@std@@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ basic_iostream_char_vbtable1 +@ extern ??_8?$basic_iostream@DU?$char_traits@D@std@@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ basic_iostream_char_vbtable2 +@ extern ??_8?$basic_iostream@GU?$char_traits@G@std@@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ basic_iostream_wchar_vbtable1 +@ extern ??_8?$basic_iostream@GU?$char_traits@G@std@@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ basic_iostream_wchar_vbtable2 +@ extern ??_8?$basic_iostream@_WU?$char_traits@_W@std@@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ basic_iostream_wchar_vbtable1 +@ extern ??_8?$basic_iostream@_WU?$char_traits@_W@std@@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ basic_iostream_wchar_vbtable2 +@ extern ??_8?$basic_istream@DU?$char_traits@D@std@@@std@@7B@ basic_istream_char_vbtable +@ extern ??_8?$basic_istream@GU?$char_traits@G@std@@@std@@7B@ basic_istream_short_vbtable +@ extern ??_8?$basic_istream@_WU?$char_traits@_W@std@@@std@@7B@ basic_istream_wchar_vbtable +@ extern ??_8?$basic_ostream@DU?$char_traits@D@std@@@std@@7B@ basic_ostream_char_vbtable +@ extern ??_8?$basic_ostream@GU?$char_traits@G@std@@@std@@7B@ basic_ostream_short_vbtable +@ extern ??_8?$basic_ostream@_WU?$char_traits@_W@std@@@std@@7B@ basic_ostream_wchar_vbtable +@ cdecl -arch=arm ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QAAXXZ(ptr) basic_iostream_char_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QAEXXZ(ptr) basic_iostream_char_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAAXXZ(ptr) basic_iostream_char_vbase_dtor +@ cdecl -arch=arm ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QAAXXZ(ptr) basic_iostream_wchar_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QAEXXZ(ptr) basic_iostream_wchar_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAAXXZ(ptr) basic_iostream_wchar_vbase_dtor +@ cdecl -arch=arm ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAAXXZ(ptr) basic_iostream_wchar_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ(ptr) basic_iostream_wchar_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ(ptr) basic_iostream_wchar_vbase_dtor +@ cdecl -arch=arm ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QAAXXZ(ptr) basic_istream_char_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXXZ(ptr) basic_istream_char_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXXZ(ptr) basic_istream_char_vbase_dtor +@ cdecl -arch=arm ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QAAXXZ(ptr) basic_istream_wchar_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXXZ(ptr) basic_istream_wchar_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXXZ(ptr) basic_istream_wchar_vbase_dtor +@ cdecl -arch=arm ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAXXZ(ptr) basic_istream_wchar_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXXZ(ptr) basic_istream_wchar_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ(ptr) basic_istream_wchar_vbase_dtor +@ cdecl -arch=arm ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAXXZ(ptr) basic_ostream_char_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ(ptr) basic_ostream_char_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ(ptr) basic_ostream_char_vbase_dtor +@ cdecl -arch=arm ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAXXZ(ptr) basic_ostream_wchar_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ(ptr) basic_ostream_wchar_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ(ptr) basic_ostream_wchar_vbase_dtor +@ cdecl -arch=arm ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAXXZ(ptr) basic_ostream_wchar_vbase_dtor +@ thiscall -arch=i386 ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ(ptr) basic_ostream_wchar_vbase_dtor +@ cdecl -arch=win64 ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ(ptr) basic_ostream_wchar_vbase_dtor +@ cdecl -arch=arm ??_F?$codecvt@DDH@std@@QAAXXZ(ptr) codecvt_char_ctor +@ thiscall -arch=i386 ??_F?$codecvt@DDH@std@@QAEXXZ(ptr) codecvt_char_ctor +@ cdecl -arch=win64 ??_F?$codecvt@DDH@std@@QEAAXXZ(ptr) codecvt_char_ctor +@ cdecl -arch=arm ??_F?$codecvt@GDH@std@@QAAXXZ(ptr) codecvt_short_ctor +@ thiscall -arch=i386 ??_F?$codecvt@GDH@std@@QAEXXZ(ptr) codecvt_short_ctor +@ cdecl -arch=win64 ??_F?$codecvt@GDH@std@@QEAAXXZ(ptr) codecvt_short_ctor +@ cdecl -arch=arm ??_F?$codecvt@_WDH@std@@QAAXXZ(ptr) codecvt_wchar_ctor +@ thiscall -arch=i386 ??_F?$codecvt@_WDH@std@@QAEXXZ(ptr) codecvt_wchar_ctor +@ cdecl -arch=win64 ??_F?$codecvt@_WDH@std@@QEAAXXZ(ptr) codecvt_wchar_ctor +@ cdecl -arch=arm ??_F?$ctype@D@std@@QAAXXZ(ptr) ctype_char_ctor +@ thiscall -arch=i386 ??_F?$ctype@D@std@@QAEXXZ(ptr) ctype_char_ctor +@ cdecl -arch=win64 ??_F?$ctype@D@std@@QEAAXXZ(ptr) ctype_char_ctor +@ cdecl -arch=arm ??_F?$ctype@G@std@@QAAXXZ(ptr) ctype_short_ctor +@ thiscall -arch=i386 ??_F?$ctype@G@std@@QAEXXZ(ptr) ctype_short_ctor +@ cdecl -arch=win64 ??_F?$ctype@G@std@@QEAAXXZ(ptr) ctype_short_ctor +@ cdecl -arch=arm ??_F?$ctype@_W@std@@QAAXXZ(ptr) ctype_wchar_ctor +@ thiscall -arch=i386 ??_F?$ctype@_W@std@@QAEXXZ(ptr) ctype_wchar_ctor +@ cdecl -arch=win64 ??_F?$ctype@_W@std@@QEAAXXZ(ptr) ctype_wchar_ctor +@ cdecl -arch=arm ??_F?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAAXXZ(ptr) num_get_char_ctor +@ thiscall -arch=i386 ??_F?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAEXXZ(ptr) num_get_char_ctor +@ cdecl -arch=win64 ??_F?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAAXXZ(ptr) num_get_char_ctor +@ cdecl -arch=arm ??_F?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAAXXZ(ptr) num_get_short_ctor +@ thiscall -arch=i386 ??_F?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAEXXZ(ptr) num_get_short_ctor +@ cdecl -arch=win64 ??_F?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAAXXZ(ptr) num_get_short_ctor +@ cdecl -arch=arm ??_F?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAAXXZ(ptr) num_get_wchar_ctor +@ thiscall -arch=i386 ??_F?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAEXXZ(ptr) num_get_wchar_ctor +@ cdecl -arch=win64 ??_F?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAAXXZ(ptr) num_get_wchar_ctor +@ cdecl -arch=arm ??_F?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAAXXZ(ptr) num_put_char_ctor +@ thiscall -arch=i386 ??_F?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAEXXZ(ptr) num_put_char_ctor +@ cdecl -arch=win64 ??_F?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAAXXZ(ptr) num_put_char_ctor +@ cdecl -arch=arm ??_F?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAAXXZ(ptr) num_put_short_ctor +@ thiscall -arch=i386 ??_F?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAEXXZ(ptr) num_put_short_ctor +@ cdecl -arch=win64 ??_F?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAAXXZ(ptr) num_put_short_ctor +@ cdecl -arch=arm ??_F?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAAXXZ(ptr) num_put_wchar_ctor +@ thiscall -arch=i386 ??_F?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAEXXZ(ptr) num_put_wchar_ctor +@ cdecl -arch=win64 ??_F?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAAXXZ(ptr) num_put_wchar_ctor +@ stub -arch=arm ??_F?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAAXXZ +@ stub -arch=i386 ??_F?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAEXXZ +@ stub -arch=win64 ??_F?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAAXXZ +@ stub -arch=arm ??_F?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAAXXZ +@ stub -arch=i386 ??_F?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAEXXZ +@ stub -arch=win64 ??_F?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAAXXZ +@ stub -arch=arm ??_F?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAAXXZ +@ stub -arch=i386 ??_F?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAEXXZ +@ stub -arch=win64 ??_F?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAAXXZ +@ cdecl -arch=arm ??_F?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAAXXZ(ptr) time_put_char_ctor +@ thiscall -arch=i386 ??_F?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAEXXZ(ptr) time_put_char_ctor +@ cdecl -arch=win64 ??_F?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAAXXZ(ptr) time_put_char_ctor +@ cdecl -arch=arm ??_F?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAAXXZ(ptr) time_put_short_ctor +@ thiscall -arch=i386 ??_F?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAEXXZ(ptr) time_put_short_ctor +@ cdecl -arch=win64 ??_F?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAAXXZ(ptr) time_put_short_ctor +@ cdecl -arch=arm ??_F?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAAXXZ(ptr) time_put_wchar_ctor +@ thiscall -arch=i386 ??_F?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAEXXZ(ptr) time_put_wchar_ctor +@ cdecl -arch=win64 ??_F?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAAXXZ(ptr) time_put_wchar_ctor +@ cdecl -arch=arm ??_F_Locinfo@std@@QAAXXZ(ptr) _Locinfo_ctor +@ thiscall -arch=i386 ??_F_Locinfo@std@@QAEXXZ(ptr) _Locinfo_ctor +@ cdecl -arch=win64 ??_F_Locinfo@std@@QEAAXXZ(ptr) _Locinfo_ctor +@ cdecl -arch=arm ??_F_Timevec@std@@QAAXXZ(ptr) _Timevec_ctor +@ thiscall -arch=i386 ??_F_Timevec@std@@QAEXXZ(ptr) _Timevec_ctor +@ cdecl -arch=win64 ??_F_Timevec@std@@QEAAXXZ(ptr) _Timevec_ctor +@ cdecl -arch=arm ??_Fcodecvt_base@std@@QAAXXZ(ptr) codecvt_base_ctor +@ thiscall -arch=i386 ??_Fcodecvt_base@std@@QAEXXZ(ptr) codecvt_base_ctor +@ cdecl -arch=win64 ??_Fcodecvt_base@std@@QEAAXXZ(ptr) codecvt_base_ctor +@ cdecl -arch=arm ??_Fctype_base@std@@QAAXXZ(ptr) ctype_base_ctor +@ thiscall -arch=i386 ??_Fctype_base@std@@QAEXXZ(ptr) ctype_base_ctor +@ cdecl -arch=win64 ??_Fctype_base@std@@QEAAXXZ(ptr) ctype_base_ctor +@ cdecl -arch=arm ??_Ffacet@locale@std@@QAAXXZ(ptr) locale_facet_ctor +@ thiscall -arch=i386 ??_Ffacet@locale@std@@QAEXXZ(ptr) locale_facet_ctor +@ cdecl -arch=win64 ??_Ffacet@locale@std@@QEAAXXZ(ptr) locale_facet_ctor +@ cdecl -arch=arm ??_Fid@locale@std@@QAAXXZ(ptr) locale_id_ctor +@ thiscall -arch=i386 ??_Fid@locale@std@@QAEXXZ(ptr) locale_id_ctor +@ cdecl -arch=win64 ??_Fid@locale@std@@QEAAXXZ(ptr) locale_id_ctor +@ stub -arch=arm ??_Ftime_base@std@@QAAXXZ +@ stub -arch=i386 ??_Ftime_base@std@@QAEXXZ +@ stub -arch=win64 ??_Ftime_base@std@@QEAAXXZ +@ stub ?GetNextAsyncId@platform@details@Concurrency@@YAIXZ +@ stub -arch=win32 ?NFS_Allocate@details@Concurrency@@YAPAXIIPAX@Z +@ stub -arch=win64 ?NFS_Allocate@details@Concurrency@@YAPEAX_K0PEAX@Z +@ stub -arch=win32 ?NFS_Free@details@Concurrency@@YAXPAX@Z +@ stub -arch=win64 ?NFS_Free@details@Concurrency@@YAXPEAX@Z +@ stub -arch=win32 ?NFS_GetLineSize@details@Concurrency@@YAIXZ +@ stub -arch=win64 ?NFS_GetLineSize@details@Concurrency@@YA_KXZ +@ stub ?_10@placeholders@std@@3V?$_Ph@$09@2@A +@ stub ?_11@placeholders@std@@3V?$_Ph@$0L@@2@A +@ stub ?_12@placeholders@std@@3V?$_Ph@$0M@@2@A +@ stub ?_13@placeholders@std@@3V?$_Ph@$0N@@2@A +@ stub ?_14@placeholders@std@@3V?$_Ph@$0O@@2@A +@ stub ?_15@placeholders@std@@3V?$_Ph@$0P@@2@A +@ stub ?_16@placeholders@std@@3V?$_Ph@$0BA@@2@A +@ stub ?_17@placeholders@std@@3V?$_Ph@$0BB@@2@A +@ stub ?_18@placeholders@std@@3V?$_Ph@$0BC@@2@A +@ stub ?_19@placeholders@std@@3V?$_Ph@$0BD@@2@A +@ stub ?_1@placeholders@std@@3V?$_Ph@$00@2@A +@ stub ?_20@placeholders@std@@3V?$_Ph@$0BE@@2@A +@ stub ?_2@placeholders@std@@3V?$_Ph@$01@2@A +@ stub ?_3@placeholders@std@@3V?$_Ph@$02@2@A +@ stub ?_4@placeholders@std@@3V?$_Ph@$03@2@A +@ stub ?_5@placeholders@std@@3V?$_Ph@$04@2@A +@ stub ?_6@placeholders@std@@3V?$_Ph@$05@2@A +@ stub ?_7@placeholders@std@@3V?$_Ph@$06@2@A +@ stub ?_8@placeholders@std@@3V?$_Ph@$07@2@A +@ stub ?_9@placeholders@std@@3V?$_Ph@$08@2@A +@ cdecl -arch=arm ?_Addcats@_Locinfo@std@@QAAAAV12@HPBD@Z(ptr long str) _Locinfo__Addcats +@ thiscall -arch=i386 ?_Addcats@_Locinfo@std@@QAEAAV12@HPBD@Z(ptr long str) _Locinfo__Addcats +@ cdecl -arch=win64 ?_Addcats@_Locinfo@std@@QEAAAEAV12@HPEBD@Z(ptr long str) _Locinfo__Addcats +@ cdecl -arch=arm ?_Addfac@_Locimp@locale@std@@AAAXPAVfacet@23@I@Z(ptr ptr long) locale__Locimp__Addfac +@ thiscall -arch=i386 ?_Addfac@_Locimp@locale@std@@AAEXPAVfacet@23@I@Z(ptr ptr long) locale__Locimp__Addfac +@ cdecl -arch=win64 ?_Addfac@_Locimp@locale@std@@AEAAXPEAVfacet@23@_K@Z(ptr ptr long) locale__Locimp__Addfac +@ cdecl -arch=win32 ?_Addstd@ios_base@std@@SAXPAV12@@Z(ptr) ios_base_Addstd +@ cdecl -arch=win64 ?_Addstd@ios_base@std@@SAXPEAV12@@Z(ptr) ios_base_Addstd +@ stub -arch=arm ?_Advance@_Concurrent_queue_iterator_base_v4@details@Concurrency@@IAAXXZ +@ stub -arch=i386 ?_Advance@_Concurrent_queue_iterator_base_v4@details@Concurrency@@IAEXXZ +@ stub -arch=win64 ?_Advance@_Concurrent_queue_iterator_base_v4@details@Concurrency@@IEAAXXZ +@ stub -arch=arm ?_Assign@_Concurrent_queue_iterator_base_v4@details@Concurrency@@IAAXABV123@@Z +@ stub -arch=i386 ?_Assign@_Concurrent_queue_iterator_base_v4@details@Concurrency@@IAEXABV123@@Z +@ stub -arch=win64 ?_Assign@_Concurrent_queue_iterator_base_v4@details@Concurrency@@IEAAXAEBV123@@Z +@ stub ?_Atexit@@YAXP6AXXZ@Z +@ extern ?_BADOFF@std@@3_JB std_BADOFF +@ stub ?_Byte_reverse_table@details@Concurrency@@3QBEB +@ cdecl -arch=arm ?_C_str@?$_Yarn@D@std@@QBAPBDXZ(ptr) _Yarn_char_c_str +@ thiscall -arch=i386 ?_C_str@?$_Yarn@D@std@@QBEPBDXZ(ptr) _Yarn_char_c_str +@ cdecl -arch=win64 ?_C_str@?$_Yarn@D@std@@QEBAPEBDXZ(ptr) _Yarn_char_c_str +@ stub -arch=arm ?_C_str@?$_Yarn@_W@std@@QBAPB_WXZ +@ stub -arch=i386 ?_C_str@?$_Yarn@_W@std@@QBEPB_WXZ +@ stub -arch=win64 ?_C_str@?$_Yarn@_W@std@@QEBAPEB_WXZ +@ cdecl -arch=arm ?_Callfns@ios_base@std@@AAAXW4event@12@@Z(ptr long) ios_base_Callfns +@ thiscall -arch=i386 ?_Callfns@ios_base@std@@AAEXW4event@12@@Z(ptr long) ios_base_Callfns +@ cdecl -arch=win64 ?_Callfns@ios_base@std@@AEAAXW4event@12@@Z(ptr long) ios_base_Callfns +@ extern -arch=win32 ?_Clocptr@_Locimp@locale@std@@0PAV123@A locale__Locimp__Clocptr +@ extern -arch=win64 ?_Clocptr@_Locimp@locale@std@@0PEAV123@EA locale__Locimp__Clocptr +@ stub -arch=win32 ?_Close_dir@sys@tr2@std@@YAXPAX@Z +@ stub -arch=win64 ?_Close_dir@sys@tr2@std@@YAXPEAX@Z +@ stub -arch=win32 ?_Copy_file@sys@tr2@std@@YAHPBD0_N@Z +@ stub -arch=win64 ?_Copy_file@sys@tr2@std@@YAHPEBD0_N@Z +@ stub -arch=win32 ?_Copy_file@sys@tr2@std@@YAHPB_W0_N@Z +@ stub -arch=win64 ?_Copy_file@sys@tr2@std@@YAHPEB_W0_N@Z +@ stub -arch=win32 ?_Current_get@sys@tr2@std@@YAPADAAY0BAE@D@Z +@ stub -arch=win64 ?_Current_get@sys@tr2@std@@YAPEADAEAY0BAE@D@Z +@ stub -arch=win32 ?_Current_get@sys@tr2@std@@YAPA_WAAY0BAE@_W@Z +@ stub -arch=win64 ?_Current_get@sys@tr2@std@@YAPEA_WAEAY0BAE@_W@Z +@ stub -arch=win32 ?_Current_set@sys@tr2@std@@YA_NPBD@Z +@ stub -arch=win64 ?_Current_set@sys@tr2@std@@YA_NPEBD@Z +@ stub -arch=win32 ?_Current_set@sys@tr2@std@@YA_NPB_W@Z +@ stub -arch=win64 ?_Current_set@sys@tr2@std@@YA_NPEB_W@Z +@ cdecl -arch=arm ?_Decref@facet@locale@std@@UAAPAV_Facet_base@3@XZ(ptr) locale_facet__Decref +@ thiscall -arch=i386 ?_Decref@facet@locale@std@@UAEPAV_Facet_base@3@XZ(ptr) locale_facet__Decref +@ cdecl -arch=win64 ?_Decref@facet@locale@std@@UEAAPEAV_Facet_base@3@XZ(ptr) locale_facet__Decref +@ cdecl -arch=arm ?_Donarrow@?$ctype@G@std@@IBADGD@Z(ptr long long) ctype_wchar__Donarrow +@ thiscall -arch=i386 ?_Donarrow@?$ctype@G@std@@IBEDGD@Z(ptr long long) ctype_wchar__Donarrow +@ cdecl -arch=win64 ?_Donarrow@?$ctype@G@std@@IEBADGD@Z(ptr long long) ctype_wchar__Donarrow +@ cdecl -arch=arm ?_Donarrow@?$ctype@_W@std@@IBAD_WD@Z(ptr long long) ctype_wchar__Donarrow +@ thiscall -arch=i386 ?_Donarrow@?$ctype@_W@std@@IBED_WD@Z(ptr long long) ctype_wchar__Donarrow +@ cdecl -arch=win64 ?_Donarrow@?$ctype@_W@std@@IEBAD_WD@Z(ptr long long) ctype_wchar__Donarrow +@ cdecl -arch=arm ?_Dowiden@?$ctype@G@std@@IBAGD@Z(ptr long) ctype_wchar__Dowiden +@ thiscall -arch=i386 ?_Dowiden@?$ctype@G@std@@IBEGD@Z(ptr long) ctype_wchar__Dowiden +@ cdecl -arch=win64 ?_Dowiden@?$ctype@G@std@@IEBAGD@Z(ptr long) ctype_wchar__Dowiden +@ cdecl -arch=arm ?_Dowiden@?$ctype@_W@std@@IBA_WD@Z(ptr long) ctype_wchar__Dowiden +@ thiscall -arch=i386 ?_Dowiden@?$ctype@_W@std@@IBE_WD@Z(ptr long) ctype_wchar__Dowiden +@ cdecl -arch=win64 ?_Dowiden@?$ctype@_W@std@@IEBA_WD@Z(ptr long) ctype_wchar__Dowiden +@ cdecl -arch=arm ?_Empty@?$_Yarn@D@std@@QBA_NXZ(ptr) _Yarn_char_empty +@ thiscall -arch=i386 ?_Empty@?$_Yarn@D@std@@QBE_NXZ(ptr) _Yarn_char_empty +@ cdecl -arch=win64 ?_Empty@?$_Yarn@D@std@@QEBA_NXZ(ptr) _Yarn_char_empty +@ stub -arch=arm ?_Empty@?$_Yarn@_W@std@@QBA_NXZ +@ stub -arch=i386 ?_Empty@?$_Yarn@_W@std@@QBE_NXZ +@ stub -arch=win64 ?_Empty@?$_Yarn@_W@std@@QEBA_NXZ +@ stub -arch=win32 ?_Equivalent@sys@tr2@std@@YAHPBD0@Z +@ stub -arch=win64 ?_Equivalent@sys@tr2@std@@YAHPEBD0@Z +@ stub -arch=win32 ?_Equivalent@sys@tr2@std@@YAHPB_W0@Z +@ stub -arch=win64 ?_Equivalent@sys@tr2@std@@YAHPEB_W0@Z +@ cdecl -arch=win32 ?_Ffmt@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAPADPADDH@Z(ptr ptr long long) num_put_char__Ffmt +@ cdecl -arch=win64 ?_Ffmt@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAPEADPEADDH@Z(ptr ptr long long) num_put_char__Ffmt +@ cdecl -arch=win32 ?_Ffmt@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAPADPADDH@Z(ptr ptr long long) num_put_wchar__Ffmt +@ cdecl -arch=win64 ?_Ffmt@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAPEADPEADDH@Z(ptr ptr long long) num_put_wchar__Ffmt +@ cdecl -arch=win32 ?_Ffmt@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAPADPADDH@Z(ptr ptr long long) num_put_wchar__Ffmt +@ cdecl -arch=win64 ?_Ffmt@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAPEADPEADDH@Z(ptr ptr long long) num_put_wchar__Ffmt +@ stub -arch=win32 ?_File_size@sys@tr2@std@@YA_KPBD@Z +@ stub -arch=win64 ?_File_size@sys@tr2@std@@YA_KPEBD@Z +@ stub -arch=win32 ?_File_size@sys@tr2@std@@YA_KPB_W@Z +@ stub -arch=win64 ?_File_size@sys@tr2@std@@YA_KPEB_W@Z +@ cdecl -arch=arm ?_Findarr@ios_base@std@@AAAAAU_Iosarray@12@H@Z(ptr long) ios_base_Findarr +@ thiscall -arch=i386 ?_Findarr@ios_base@std@@AAEAAU_Iosarray@12@H@Z(ptr long) ios_base_Findarr +@ cdecl -arch=win64 ?_Findarr@ios_base@std@@AEAAAEAU_Iosarray@12@H@Z(ptr long) ios_base_Findarr +@ cdecl -arch=win32 ?_Fiopen@std@@YAPAU_iobuf@@PBDHH@Z(str long long) _Fiopen +@ cdecl -arch=win64 ?_Fiopen@std@@YAPEAU_iobuf@@PEBDHH@Z(str long long) _Fiopen +@ cdecl -arch=win32 ?_Fiopen@std@@YAPAU_iobuf@@PBGHH@Z(wstr long long) _Fiopen_wchar +@ cdecl -arch=win64 ?_Fiopen@std@@YAPEAU_iobuf@@PEBGHH@Z(wstr long long) _Fiopen_wchar +@ cdecl -arch=win32 ?_Fiopen@std@@YAPAU_iobuf@@PB_WHH@Z(wstr long long) _Fiopen_wchar +@ cdecl -arch=win64 ?_Fiopen@std@@YAPEAU_iobuf@@PEB_WHH@Z(wstr long long) _Fiopen_wchar +@ cdecl -arch=win32 ?_Fput@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBDIIII@Z(ptr ptr long ptr ptr long str long long long long) num_put_char__Fput +@ cdecl -arch=win64 ?_Fput@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DPEBD_K333@Z(ptr ptr ptr ptr long str long long long long) num_put_char__Fput +@ cdecl -arch=win32 ?_Fput@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBDIIII@Z(ptr ptr long ptr ptr long str long long long long) num_put_short__Fput +@ cdecl -arch=win64 ?_Fput@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GPEBD_K333@Z(ptr ptr ptr ptr long str long long long long) num_put_short__Fput +@ cdecl -arch=win32 ?_Fput@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBDIIII@Z(ptr ptr long ptr ptr long str long long long long) num_put_wchar__Fput +@ cdecl -arch=win64 ?_Fput@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WPEBD_K444@Z(ptr ptr ptr ptr long str long long long long) num_put_wchar__Fput +@ stub -arch=win32 ?_Future_error_map@std@@YAPBDH@Z +@ stub -arch=win64 ?_Future_error_map@std@@YAPEBDH@Z +@ stub -arch=win32 ?_GetCombinableSize@details@Concurrency@@YAIXZ +@ stub -arch=win64 ?_GetCombinableSize@details@Concurrency@@YA_KXZ +@ cdecl -arch=win32 ?_Getcat@?$codecvt@DDH@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) codecvt_char__Getcat +@ cdecl -arch=win64 ?_Getcat@?$codecvt@DDH@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) codecvt_char__Getcat +@ cdecl -arch=win32 ?_Getcat@?$codecvt@GDH@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) codecvt_short__Getcat +@ cdecl -arch=win64 ?_Getcat@?$codecvt@GDH@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) codecvt_short__Getcat +@ cdecl -arch=win32 ?_Getcat@?$codecvt@_WDH@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) codecvt_wchar__Getcat +@ cdecl -arch=win64 ?_Getcat@?$codecvt@_WDH@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) codecvt_wchar__Getcat +@ cdecl -arch=win32 ?_Getcat@?$ctype@D@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) ctype_char__Getcat +@ cdecl -arch=win64 ?_Getcat@?$ctype@D@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) ctype_char__Getcat +@ cdecl -arch=win32 ?_Getcat@?$ctype@G@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) ctype_short__Getcat +@ cdecl -arch=win64 ?_Getcat@?$ctype@G@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) ctype_short__Getcat +@ cdecl -arch=win32 ?_Getcat@?$ctype@_W@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) ctype_wchar__Getcat +@ cdecl -arch=win64 ?_Getcat@?$ctype@_W@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) ctype_wchar__Getcat +@ cdecl -arch=win32 ?_Getcat@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) num_get_char__Getcat +@ cdecl -arch=win64 ?_Getcat@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) num_get_char__Getcat +@ cdecl -arch=win32 ?_Getcat@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) num_get_short__Getcat +@ cdecl -arch=win64 ?_Getcat@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) num_get_short__Getcat +@ cdecl -arch=win32 ?_Getcat@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) num_get_wchar__Getcat +@ cdecl -arch=win64 ?_Getcat@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) num_get_wchar__Getcat +@ cdecl -arch=win32 ?_Getcat@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) num_put_char__Getcat +@ cdecl -arch=win64 ?_Getcat@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) num_put_char__Getcat +@ cdecl -arch=win32 ?_Getcat@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) num_put_short__Getcat +@ cdecl -arch=win64 ?_Getcat@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) num_put_short__Getcat +@ cdecl -arch=win32 ?_Getcat@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) num_put_wchar__Getcat +@ cdecl -arch=win64 ?_Getcat@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) num_put_wchar__Getcat +@ stub -arch=win32 ?_Getcat@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z +@ stub -arch=win64 ?_Getcat@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z +@ stub -arch=win32 ?_Getcat@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z +@ stub -arch=win64 ?_Getcat@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z +@ stub -arch=win32 ?_Getcat@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z +@ stub -arch=win64 ?_Getcat@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z +@ cdecl -arch=win32 ?_Getcat@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) time_put_char__Getcat +@ cdecl -arch=win64 ?_Getcat@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) time_put_char__Getcat +@ cdecl -arch=win32 ?_Getcat@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) time_put_short__Getcat +@ cdecl -arch=win64 ?_Getcat@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) time_put_short__Getcat +@ cdecl -arch=win32 ?_Getcat@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z(ptr ptr) time_put_wchar__Getcat +@ cdecl -arch=win64 ?_Getcat@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z(ptr ptr) time_put_wchar__Getcat +@ cdecl -arch=win32 ?_Getcat@facet@locale@std@@SAIPAPBV123@PBV23@@Z(ptr ptr) locale_facet__Getcat +@ cdecl -arch=win64 ?_Getcat@facet@locale@std@@SA_KPEAPEBV123@PEBV23@@Z(ptr ptr) locale_facet__Getcat +@ cdecl -arch=arm ?_Getcoll@_Locinfo@std@@QBA?AU_Collvec@@XZ(ptr ptr) _Locinfo__Getcoll +@ thiscall -arch=i386 ?_Getcoll@_Locinfo@std@@QBE?AU_Collvec@@XZ(ptr ptr) _Locinfo__Getcoll +@ cdecl -arch=win64 ?_Getcoll@_Locinfo@std@@QEBA?AU_Collvec@@XZ(ptr ptr) _Locinfo__Getcoll +@ cdecl -arch=arm ?_Getctype@_Locinfo@std@@QBA?AU_Ctypevec@@XZ(ptr ptr) _Locinfo__Getctype +@ thiscall -arch=i386 ?_Getctype@_Locinfo@std@@QBE?AU_Ctypevec@@XZ(ptr ptr) _Locinfo__Getctype +@ cdecl -arch=win64 ?_Getctype@_Locinfo@std@@QEBA?AU_Ctypevec@@XZ(ptr ptr) _Locinfo__Getctype +@ cdecl -arch=arm ?_Getcvt@_Locinfo@std@@QBA?AU_Cvtvec@@XZ(ptr ptr) _Locinfo__Getcvt +@ thiscall -arch=i386 ?_Getcvt@_Locinfo@std@@QBE?AU_Cvtvec@@XZ(ptr ptr) _Locinfo__Getcvt +@ cdecl -arch=win64 ?_Getcvt@_Locinfo@std@@QEBA?AU_Cvtvec@@XZ(ptr ptr) _Locinfo__Getcvt +@ cdecl -arch=arm ?_Getdateorder@_Locinfo@std@@QBAHXZ(ptr) _Locinfo__Getdateorder +@ thiscall -arch=i386 ?_Getdateorder@_Locinfo@std@@QBEHXZ(ptr) _Locinfo__Getdateorder +@ cdecl -arch=win64 ?_Getdateorder@_Locinfo@std@@QEBAHXZ(ptr) _Locinfo__Getdateorder +@ cdecl -arch=arm ?_Getdays@_Locinfo@std@@QBAPBDXZ(ptr) _Locinfo__Getdays +@ thiscall -arch=i386 ?_Getdays@_Locinfo@std@@QBEPBDXZ(ptr) _Locinfo__Getdays +@ cdecl -arch=win64 ?_Getdays@_Locinfo@std@@QEBAPEBDXZ(ptr) _Locinfo__Getdays +@ cdecl -arch=arm ?_Getfalse@_Locinfo@std@@QBAPBDXZ(ptr) _Locinfo__Getfalse +@ thiscall -arch=i386 ?_Getfalse@_Locinfo@std@@QBEPBDXZ(ptr) _Locinfo__Getfalse +@ cdecl -arch=win64 ?_Getfalse@_Locinfo@std@@QEBAPEBDXZ(ptr) _Locinfo__Getfalse +@ stub -arch=win32 ?_Getffld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1AAVios_base@2@PAH@Z +@ stub -arch=win64 ?_Getffld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1AEAVios_base@2@PEAH@Z +@ stub -arch=win32 ?_Getffld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1AAVios_base@2@PAH@Z +@ stub -arch=win64 ?_Getffld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1AEAVios_base@2@PEAH@Z +@ stub -arch=win32 ?_Getffld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1AAVios_base@2@PAH@Z +@ stub -arch=win64 ?_Getffld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1AEAVios_base@2@PEAH@Z +@ cdecl -arch=win32 ?_Getffldx@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1AAVios_base@2@PAH@Z(ptr str ptr ptr ptr ptr) num_get_char__Getffldx +@ cdecl -arch=win64 ?_Getffldx@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1AEAVios_base@2@PEAH@Z(ptr str ptr ptr ptr ptr) num_get_char__Getffldx +@ cdecl -arch=win32 ?_Getffldx@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1AAVios_base@2@PAH@Z(ptr str ptr ptr ptr ptr) num_get_wchar__Getffldx +@ cdecl -arch=win64 ?_Getffldx@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1AEAVios_base@2@PEAH@Z(ptr str ptr ptr ptr ptr) num_get_wchar__Getffldx +@ cdecl -arch=win32 ?_Getffldx@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1AAVios_base@2@PAH@Z(ptr str ptr ptr ptr ptr) num_get_wchar__Getffldx +@ cdecl -arch=win64 ?_Getffldx@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1AEAVios_base@2@PEAH@Z(ptr str ptr ptr ptr ptr) num_get_wchar__Getffldx +@ stub -arch=arm ?_Getfmt@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBD@Z +@ stub -arch=i386 ?_Getfmt@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBD@Z +@ stub -arch=win64 ?_Getfmt@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@PEBD@Z +@ stub -arch=arm ?_Getfmt@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBD@Z +@ stub -arch=i386 ?_Getfmt@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBD@Z +@ stub -arch=win64 ?_Getfmt@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@PEBD@Z +@ stub -arch=arm ?_Getfmt@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBD@Z +@ stub -arch=i386 ?_Getfmt@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBD@Z +@ stub -arch=win64 ?_Getfmt@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@PEBD@Z +@ cdecl -arch=win32 ?_Getgloballocale@locale@std@@CAPAV_Locimp@12@XZ() locale__Getgloballocale +@ cdecl -arch=win64 ?_Getgloballocale@locale@std@@CAPEAV_Locimp@12@XZ() locale__Getgloballocale +@ cdecl -arch=win32 ?_Getifld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1HABVlocale@2@@Z(ptr str ptr ptr long ptr) num_get_char__Getifld +@ cdecl -arch=win64 ?_Getifld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1HAEBVlocale@2@@Z(ptr str ptr ptr long ptr) num_get_char__Getifld +@ cdecl -arch=win32 ?_Getifld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1HABVlocale@2@@Z(ptr str ptr ptr long ptr) num_get_short__Getifld +@ cdecl -arch=win64 ?_Getifld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1HAEBVlocale@2@@Z(ptr str ptr ptr long ptr) num_get_short__Getifld +@ cdecl -arch=win32 ?_Getifld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1HABVlocale@2@@Z(ptr str ptr ptr long ptr) num_get_wchar__Getifld +@ cdecl -arch=win64 ?_Getifld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1HAEBVlocale@2@@Z(ptr str ptr ptr long ptr) num_get_wchar__Getifld +@ stub -arch=win32 ?_Getint@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@0HHAAHABV?$ctype@D@2@@Z +@ stub -arch=win64 ?_Getint@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@0HHAEAHAEBV?$ctype@D@2@@Z +@ stub -arch=win32 ?_Getint@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@0HHAAHABV?$ctype@G@2@@Z +@ stub -arch=win64 ?_Getint@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@0HHAEAHAEBV?$ctype@G@2@@Z +@ stub -arch=win32 ?_Getint@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@0HHAAHABV?$ctype@_W@2@@Z +@ stub -arch=win64 ?_Getint@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@0HHAEAHAEBV?$ctype@_W@2@@Z +@ cdecl -arch=arm ?_Getlconv@_Locinfo@std@@QBAPBUlconv@@XZ(ptr) _Locinfo__Getlconv +@ thiscall -arch=i386 ?_Getlconv@_Locinfo@std@@QBEPBUlconv@@XZ(ptr) _Locinfo__Getlconv +@ cdecl -arch=win64 ?_Getlconv@_Locinfo@std@@QEBAPEBUlconv@@XZ(ptr) _Locinfo__Getlconv +@ cdecl -arch=arm ?_Getmonths@_Locinfo@std@@QBAPBDXZ(ptr) _Locinfo__Getmonths +@ thiscall -arch=i386 ?_Getmonths@_Locinfo@std@@QBEPBDXZ(ptr) _Locinfo__Getmonths +@ cdecl -arch=win64 ?_Getmonths@_Locinfo@std@@QEBAPEBDXZ(ptr) _Locinfo__Getmonths +@ stub -arch=arm ?_Getname@_Locinfo@std@@QBAPBDXZ +@ thiscall -arch=win32 ?_Getname@_Locinfo@std@@QBEPBDXZ(ptr) _Locinfo__Getname +@ cdecl -arch=win64 ?_Getname@_Locinfo@std@@QEBAPEBDXZ(ptr) _Locinfo__Getname +@ cdecl -arch=arm ?_Getpfirst@_Container_base12@std@@QBAPAPAU_Iterator_base12@2@XZ(ptr) _Container_base12__Getpfirst +@ thiscall -arch=i386 ?_Getpfirst@_Container_base12@std@@QBEPAPAU_Iterator_base12@2@XZ(ptr) _Container_base12__Getpfirst +@ cdecl -arch=win64 ?_Getpfirst@_Container_base12@std@@QEBAPEAPEAU_Iterator_base12@2@XZ(ptr) _Container_base12__Getpfirst +@ cdecl -arch=arm ?_Getptr@_Timevec@std@@QBAPAXXZ(ptr) _Timevec__Getptr +@ thiscall -arch=i386 ?_Getptr@_Timevec@std@@QBEPAXXZ(ptr) _Timevec__Getptr +@ cdecl -arch=win64 ?_Getptr@_Timevec@std@@QEBAPEAXXZ(ptr) _Timevec__Getptr +@ cdecl -arch=arm ?_Gettnames@_Locinfo@std@@QBA?AV_Timevec@2@XZ(ptr ptr) _Locinfo__Gettnames +@ thiscall -arch=i386 ?_Gettnames@_Locinfo@std@@QBE?AV_Timevec@2@XZ(ptr ptr) _Locinfo__Gettnames +@ cdecl -arch=win64 ?_Gettnames@_Locinfo@std@@QEBA?AV_Timevec@2@XZ(ptr ptr) _Locinfo__Gettnames +@ cdecl -arch=arm ?_Gettrue@_Locinfo@std@@QBAPBDXZ(ptr) _Locinfo__Gettrue +@ thiscall -arch=i386 ?_Gettrue@_Locinfo@std@@QBEPBDXZ(ptr) _Locinfo__Gettrue +@ cdecl -arch=win64 ?_Gettrue@_Locinfo@std@@QEBAPEBDXZ(ptr) _Locinfo__Gettrue +@ cdecl -ret64 -arch=arm ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBA_JXZ(ptr) basic_streambuf_char__Gnavail +@ thiscall -ret64 -arch=i386 ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBE_JXZ(ptr) basic_streambuf_char__Gnavail +@ cdecl -arch=win64 ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBA_JXZ(ptr) basic_streambuf_char__Gnavail +@ cdecl -ret64 -arch=arm ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBA_JXZ(ptr) basic_streambuf_wchar__Gnavail +@ thiscall -ret64 -arch=i386 ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBE_JXZ(ptr) basic_streambuf_wchar__Gnavail +@ cdecl -arch=win64 ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBA_JXZ(ptr) basic_streambuf_wchar__Gnavail +@ cdecl -ret64 -arch=arm ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBA_JXZ(ptr) basic_streambuf_wchar__Gnavail +@ thiscall -ret64 -arch=i386 ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBE_JXZ(ptr) basic_streambuf_wchar__Gnavail +@ cdecl -arch=win64 ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBA_JXZ(ptr) basic_streambuf_wchar__Gnavail +@ cdecl -arch=arm ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAPADXZ(ptr) basic_streambuf_char__Gndec +@ thiscall -arch=i386 ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ(ptr) basic_streambuf_char__Gndec +@ cdecl -arch=win64 ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ(ptr) basic_streambuf_char__Gndec +@ cdecl -arch=arm ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAPAGXZ(ptr) basic_streambuf_wchar__Gndec +@ thiscall -arch=i386 ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ(ptr) basic_streambuf_wchar__Gndec +@ cdecl -arch=win64 ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ(ptr) basic_streambuf_wchar__Gndec +@ cdecl -arch=arm ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAPA_WXZ(ptr) basic_streambuf_wchar__Gndec +@ thiscall -arch=i386 ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ(ptr) basic_streambuf_wchar__Gndec +@ cdecl -arch=win64 ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ(ptr) basic_streambuf_wchar__Gndec +@ cdecl -arch=arm ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAPADXZ(ptr) basic_streambuf_char__Gninc +@ thiscall -arch=i386 ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ(ptr) basic_streambuf_char__Gninc +@ cdecl -arch=win64 ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ(ptr) basic_streambuf_char__Gninc +@ cdecl -arch=arm ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAPAGXZ(ptr) basic_streambuf_wchar__Gninc +@ thiscall -arch=i386 ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ(ptr) basic_streambuf_wchar__Gninc +@ cdecl -arch=win64 ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ(ptr) basic_streambuf_wchar__Gninc +@ cdecl -arch=arm ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAPA_WXZ(ptr) basic_streambuf_wchar__Gninc +@ thiscall -arch=i386 ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ(ptr) basic_streambuf_wchar__Gninc +@ cdecl -arch=win64 ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ(ptr) basic_streambuf_wchar__Gninc +@ cdecl -arch=arm ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAPADXZ(ptr) basic_streambuf_char__Gnpreinc +@ thiscall -arch=i386 ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ(ptr) basic_streambuf_char__Gnpreinc +@ cdecl -arch=win64 ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ(ptr) basic_streambuf_char__Gnpreinc +@ cdecl -arch=arm ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAPAGXZ(ptr) basic_streambuf_wchar__Gnpreinc +@ thiscall -arch=i386 ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ(ptr) basic_streambuf_wchar__Gnpreinc +@ cdecl -arch=win64 ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ(ptr) basic_streambuf_wchar__Gnpreinc +@ cdecl -arch=arm ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAPA_WXZ(ptr) basic_streambuf_wchar__Gnpreinc +@ thiscall -arch=i386 ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ(ptr) basic_streambuf_wchar__Gnpreinc +@ cdecl -arch=win64 ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ(ptr) basic_streambuf_wchar__Gnpreinc +@ extern ?_Id_cnt@id@locale@std@@0HA locale_id__Id_cnt +@ cdecl -arch=win32 ?_Ifmt@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAPADPADPBDH@Z(ptr ptr str long) num_put_char__Ifmt +@ cdecl -arch=win64 ?_Ifmt@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAPEADPEADPEBDH@Z(ptr ptr str long) num_put_char__Ifmt +@ cdecl -arch=win32 ?_Ifmt@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAPADPADPBDH@Z(ptr ptr str long) num_put_wchar__Ifmt +@ cdecl -arch=win64 ?_Ifmt@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAPEADPEADPEBDH@Z(ptr ptr str long) num_put_wchar__Ifmt +@ cdecl -arch=win32 ?_Ifmt@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAPADPADPBDH@Z(ptr ptr str long) num_put_wchar__Ifmt +@ cdecl -arch=win64 ?_Ifmt@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAPEADPEADPEBDH@Z(ptr ptr str long) num_put_wchar__Ifmt +@ cdecl -arch=arm ?_Incref@facet@locale@std@@UAAXXZ(ptr) locale_facet__Incref +@ thiscall -arch=i386 ?_Incref@facet@locale@std@@UAEXXZ(ptr) locale_facet__Incref +@ cdecl -arch=win64 ?_Incref@facet@locale@std@@UEAAXXZ(ptr) locale_facet__Incref +@ extern ?_Index@ios_base@std@@0HA ios_base_Index +@ cdecl -arch=arm ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAXPAPAD0PAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_char__Init +@ thiscall -arch=i386 ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAPAD0PAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_char__Init +@ cdecl -arch=win64 ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAPEAD0PEAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_char__Init +@ cdecl -arch=arm ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAXXZ(ptr) basic_streambuf_char__Init_empty +@ thiscall -arch=i386 ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXXZ(ptr) basic_streambuf_char__Init_empty +@ cdecl -arch=win64 ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXXZ(ptr) basic_streambuf_char__Init_empty +@ cdecl -arch=arm ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAXPAPAG0PAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_wchar__Init +@ thiscall -arch=i386 ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAPAG0PAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_wchar__Init +@ cdecl -arch=win64 ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAPEAG0PEAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_wchar__Init +@ cdecl -arch=arm ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAXXZ(ptr) basic_streambuf_wchar__Init_empty +@ thiscall -arch=i386 ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXXZ(ptr) basic_streambuf_wchar__Init_empty +@ cdecl -arch=win64 ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXXZ(ptr) basic_streambuf_wchar__Init_empty +@ cdecl -arch=arm ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAXPAPA_W0PAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_wchar__Init +@ thiscall -arch=i386 ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPAPA_W0PAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_wchar__Init +@ cdecl -arch=win64 ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAPEA_W0PEAH001@Z(ptr ptr ptr ptr ptr ptr ptr) basic_streambuf_wchar__Init +@ cdecl -arch=arm ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAXXZ(ptr) basic_streambuf_wchar__Init_empty +@ thiscall -arch=i386 ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXXZ(ptr) basic_streambuf_wchar__Init_empty +@ cdecl -arch=win64 ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXXZ(ptr) basic_streambuf_wchar__Init_empty +@ cdecl -arch=arm ?_Init@?$codecvt@DDH@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) codecvt_char__Init +@ thiscall -arch=i386 ?_Init@?$codecvt@DDH@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) codecvt_char__Init +@ cdecl -arch=win64 ?_Init@?$codecvt@DDH@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) codecvt_char__Init +@ cdecl -arch=arm ?_Init@?$codecvt@GDH@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) codecvt_wchar__Init +@ thiscall -arch=i386 ?_Init@?$codecvt@GDH@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) codecvt_wchar__Init +@ cdecl -arch=win64 ?_Init@?$codecvt@GDH@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) codecvt_wchar__Init +@ cdecl -arch=arm ?_Init@?$codecvt@_WDH@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) codecvt_wchar__Init +@ thiscall -arch=i386 ?_Init@?$codecvt@_WDH@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) codecvt_wchar__Init +@ cdecl -arch=win64 ?_Init@?$codecvt@_WDH@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) codecvt_wchar__Init +@ cdecl -arch=arm ?_Init@?$ctype@D@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) ctype_char__Init +@ thiscall -arch=i386 ?_Init@?$ctype@D@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) ctype_char__Init +@ cdecl -arch=win64 ?_Init@?$ctype@D@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) ctype_char__Init +@ cdecl -arch=arm ?_Init@?$ctype@G@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) ctype_wchar__Init +@ thiscall -arch=i386 ?_Init@?$ctype@G@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) ctype_wchar__Init +@ cdecl -arch=win64 ?_Init@?$ctype@G@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) ctype_wchar__Init +@ cdecl -arch=arm ?_Init@?$ctype@_W@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) ctype_wchar__Init +@ thiscall -arch=i386 ?_Init@?$ctype@_W@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) ctype_wchar__Init +@ cdecl -arch=win64 ?_Init@?$ctype@_W@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) ctype_wchar__Init +@ cdecl -arch=arm ?_Init@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) num_get_char__Init +@ thiscall -arch=i386 ?_Init@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) num_get_char__Init +@ cdecl -arch=win64 ?_Init@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) num_get_char__Init +@ cdecl -arch=arm ?_Init@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) num_get_wchar__Init +@ thiscall -arch=i386 ?_Init@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) num_get_wchar__Init +@ cdecl -arch=win64 ?_Init@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) num_get_wchar__Init +@ cdecl -arch=arm ?_Init@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) num_get_wchar__Init +@ thiscall -arch=i386 ?_Init@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) num_get_wchar__Init +@ cdecl -arch=win64 ?_Init@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) num_get_wchar__Init +@ cdecl -arch=arm ?_Init@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) num_put_char__Init +@ thiscall -arch=i386 ?_Init@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) num_put_char__Init +@ cdecl -arch=win64 ?_Init@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) num_put_char__Init +@ cdecl -arch=arm ?_Init@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) num_put_wchar__Init +@ thiscall -arch=i386 ?_Init@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) num_put_wchar__Init +@ cdecl -arch=win64 ?_Init@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) num_put_wchar__Init +@ cdecl -arch=arm ?_Init@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) num_put_wchar__Init +@ thiscall -arch=i386 ?_Init@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) num_put_wchar__Init +@ cdecl -arch=win64 ?_Init@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) num_put_wchar__Init +@ stub -arch=arm ?_Init@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z +@ stub -arch=i386 ?_Init@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z +@ stub -arch=win64 ?_Init@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z +@ stub -arch=arm ?_Init@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z +@ stub -arch=i386 ?_Init@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z +@ stub -arch=win64 ?_Init@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z +@ stub -arch=arm ?_Init@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z +@ stub -arch=i386 ?_Init@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z +@ stub -arch=win64 ?_Init@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z +@ cdecl -arch=arm ?_Init@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) time_put_char__Init +@ thiscall -arch=i386 ?_Init@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) time_put_char__Init +@ cdecl -arch=win64 ?_Init@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) time_put_char__Init +@ cdecl -arch=arm ?_Init@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) time_put_wchar__Init +@ thiscall -arch=i386 ?_Init@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) time_put_wchar__Init +@ cdecl -arch=win64 ?_Init@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) time_put_wchar__Init +@ cdecl -arch=arm ?_Init@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAAXABV_Locinfo@2@@Z(ptr ptr) time_put_wchar__Init +@ thiscall -arch=i386 ?_Init@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z(ptr ptr) time_put_wchar__Init +@ cdecl -arch=win64 ?_Init@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z(ptr ptr) time_put_wchar__Init +@ cdecl -arch=arm ?_Init@ios_base@std@@IAAXXZ(ptr) ios_base__Init +@ thiscall -arch=i386 ?_Init@ios_base@std@@IAEXXZ(ptr) ios_base__Init +@ cdecl -arch=win64 ?_Init@ios_base@std@@IEAAXXZ(ptr) ios_base__Init +@ cdecl -arch=win32 ?_Init@locale@std@@CAPAV_Locimp@12@_N@Z(long) locale__Init_ref +@ cdecl -arch=win64 ?_Init@locale@std@@CAPEAV_Locimp@12@_N@Z(long) locale__Init_ref +@ extern ?_Init_cnt@Init@ios_base@std@@0HA ios_base_Init__Init_cnt +# extern ?_Init_cnt@_UShinit@std@@0HA +@ extern ?_Init_cnt@_Winit@std@@0HA _Winit__Init_cnt +@ cdecl -arch=win32 ?_Init_cnt_func@Init@ios_base@std@@CAAAHXZ() ios_base_Init__Init_cnt_func +@ cdecl -arch=win64 ?_Init_cnt_func@Init@ios_base@std@@CAAEAHXZ() ios_base_Init__Init_cnt_func +@ cdecl -arch=win32 ?_Init_ctor@Init@ios_base@std@@CAXPAV123@@Z(ptr) ios_base_Init__Init_ctor +@ cdecl -arch=win64 ?_Init_ctor@Init@ios_base@std@@CAXPEAV123@@Z(ptr) ios_base_Init__Init_ctor +@ cdecl -arch=win32 ?_Init_dtor@Init@ios_base@std@@CAXPAV123@@Z(ptr) ios_base_Init__Init_dtor +@ cdecl -arch=win64 ?_Init_dtor@Init@ios_base@std@@CAXPEAV123@@Z(ptr) ios_base_Init__Init_dtor +@ stub -arch=win32 ?_Init_locks_ctor@_Init_locks@std@@CAXPAV12@@Z +@ stub -arch=win64 ?_Init_locks_ctor@_Init_locks@std@@CAXPEAV12@@Z +@ stub -arch=win32 ?_Init_locks_dtor@_Init_locks@std@@CAXPAV12@@Z +@ stub -arch=win64 ?_Init_locks_dtor@_Init_locks@std@@CAXPEAV12@@Z +@ stub -arch=arm ?_Internal_assign@_Concurrent_vector_base_v4@details@Concurrency@@IAAXABV123@IP6AXPAXI@ZP6AX1PBXI@Z4@Z +@ stub -arch=i386 ?_Internal_assign@_Concurrent_vector_base_v4@details@Concurrency@@IAEXABV123@IP6AXPAXI@ZP6AX1PBXI@Z4@Z +@ stub -arch=win64 ?_Internal_assign@_Concurrent_vector_base_v4@details@Concurrency@@IEAAXAEBV123@_KP6AXPEAX1@ZP6AX2PEBX1@Z5@Z +@ stub -arch=arm ?_Internal_capacity@_Concurrent_vector_base_v4@details@Concurrency@@IBAIXZ +@ stub -arch=i386 ?_Internal_capacity@_Concurrent_vector_base_v4@details@Concurrency@@IBEIXZ +@ stub -arch=win64 ?_Internal_capacity@_Concurrent_vector_base_v4@details@Concurrency@@IEBA_KXZ +@ stub -arch=arm ?_Internal_clear@_Concurrent_vector_base_v4@details@Concurrency@@IAAIP6AXPAXI@Z@Z +@ stub -arch=i386 ?_Internal_clear@_Concurrent_vector_base_v4@details@Concurrency@@IAEIP6AXPAXI@Z@Z +@ stub -arch=win64 ?_Internal_clear@_Concurrent_vector_base_v4@details@Concurrency@@IEAA_KP6AXPEAX_K@Z@Z +@ stub -arch=arm ?_Internal_compact@_Concurrent_vector_base_v4@details@Concurrency@@IAAPAXIPAXP6AX0I@ZP6AX0PBXI@Z@Z +@ stub -arch=i386 ?_Internal_compact@_Concurrent_vector_base_v4@details@Concurrency@@IAEPAXIPAXP6AX0I@ZP6AX0PBXI@Z@Z +@ stub -arch=win64 ?_Internal_compact@_Concurrent_vector_base_v4@details@Concurrency@@IEAAPEAX_KPEAXP6AX10@ZP6AX1PEBX0@Z@Z +@ stub -arch=arm ?_Internal_copy@_Concurrent_vector_base_v4@details@Concurrency@@IAAXABV123@IP6AXPAXPBXI@Z@Z +@ stub -arch=i386 ?_Internal_copy@_Concurrent_vector_base_v4@details@Concurrency@@IAEXABV123@IP6AXPAXPBXI@Z@Z +@ stub -arch=win64 ?_Internal_copy@_Concurrent_vector_base_v4@details@Concurrency@@IEAAXAEBV123@_KP6AXPEAXPEBX1@Z@Z +@ stub -arch=arm ?_Internal_empty@_Concurrent_queue_base_v4@details@Concurrency@@IBA_NXZ +@ stub -arch=i386 ?_Internal_empty@_Concurrent_queue_base_v4@details@Concurrency@@IBE_NXZ +@ stub -arch=win64 ?_Internal_empty@_Concurrent_queue_base_v4@details@Concurrency@@IEBA_NXZ +@ stub -arch=arm ?_Internal_finish_clear@_Concurrent_queue_base_v4@details@Concurrency@@IAAXXZ +@ stub -arch=i386 ?_Internal_finish_clear@_Concurrent_queue_base_v4@details@Concurrency@@IAEXXZ +@ stub -arch=win64 ?_Internal_finish_clear@_Concurrent_queue_base_v4@details@Concurrency@@IEAAXXZ +@ stub -arch=arm ?_Internal_grow_by@_Concurrent_vector_base_v4@details@Concurrency@@IAAIIIP6AXPAXPBXI@Z1@Z +@ stub -arch=i386 ?_Internal_grow_by@_Concurrent_vector_base_v4@details@Concurrency@@IAEIIIP6AXPAXPBXI@Z1@Z +@ stub -arch=win64 ?_Internal_grow_by@_Concurrent_vector_base_v4@details@Concurrency@@IEAA_K_K0P6AXPEAXPEBX0@Z2@Z +@ stub -arch=arm ?_Internal_grow_to_at_least_with_result@_Concurrent_vector_base_v4@details@Concurrency@@IAAIIIP6AXPAXPBXI@Z1@Z +@ stub -arch=i386 ?_Internal_grow_to_at_least_with_result@_Concurrent_vector_base_v4@details@Concurrency@@IAEIIIP6AXPAXPBXI@Z1@Z +@ stub -arch=win64 ?_Internal_grow_to_at_least_with_result@_Concurrent_vector_base_v4@details@Concurrency@@IEAA_K_K0P6AXPEAXPEBX0@Z2@Z +@ stub -arch=arm ?_Internal_move_push@_Concurrent_queue_base_v4@details@Concurrency@@IAAXPAX@Z +@ stub -arch=i386 ?_Internal_move_push@_Concurrent_queue_base_v4@details@Concurrency@@IAEXPAX@Z +@ stub -arch=win64 ?_Internal_move_push@_Concurrent_queue_base_v4@details@Concurrency@@IEAAXPEAX@Z +@ stub -arch=arm ?_Internal_pop_if_present@_Concurrent_queue_base_v4@details@Concurrency@@IAA_NPAX@Z +@ stub -arch=i386 ?_Internal_pop_if_present@_Concurrent_queue_base_v4@details@Concurrency@@IAE_NPAX@Z +@ stub -arch=win64 ?_Internal_pop_if_present@_Concurrent_queue_base_v4@details@Concurrency@@IEAA_NPEAX@Z +@ stub -arch=arm ?_Internal_push@_Concurrent_queue_base_v4@details@Concurrency@@IAAXPBX@Z +@ stub -arch=i386 ?_Internal_push@_Concurrent_queue_base_v4@details@Concurrency@@IAEXPBX@Z +@ stub -arch=win64 ?_Internal_push@_Concurrent_queue_base_v4@details@Concurrency@@IEAAXPEBX@Z +@ stub -arch=arm ?_Internal_push_back@_Concurrent_vector_base_v4@details@Concurrency@@IAAPAXIAAI@Z +@ stub -arch=i386 ?_Internal_push_back@_Concurrent_vector_base_v4@details@Concurrency@@IAEPAXIAAI@Z +@ stub -arch=win64 ?_Internal_push_back@_Concurrent_vector_base_v4@details@Concurrency@@IEAAPEAX_KAEA_K@Z +@ stub -arch=arm ?_Internal_reserve@_Concurrent_vector_base_v4@details@Concurrency@@IAAXIII@Z +@ stub -arch=i386 ?_Internal_reserve@_Concurrent_vector_base_v4@details@Concurrency@@IAEXIII@Z +@ stub -arch=win64 ?_Internal_reserve@_Concurrent_vector_base_v4@details@Concurrency@@IEAAX_K00@Z +@ stub -arch=arm ?_Internal_resize@_Concurrent_vector_base_v4@details@Concurrency@@IAAXIIIP6AXPAXI@ZP6AX0PBXI@Z2@Z +@ stub -arch=i386 ?_Internal_resize@_Concurrent_vector_base_v4@details@Concurrency@@IAEXIIIP6AXPAXI@ZP6AX0PBXI@Z2@Z +@ stub -arch=win64 ?_Internal_resize@_Concurrent_vector_base_v4@details@Concurrency@@IEAAX_K00P6AXPEAX0@ZP6AX1PEBX0@Z3@Z +@ stub -arch=arm ?_Internal_size@_Concurrent_queue_base_v4@details@Concurrency@@IBAIXZ +@ stub -arch=i386 ?_Internal_size@_Concurrent_queue_base_v4@details@Concurrency@@IBEIXZ +@ stub -arch=win64 ?_Internal_size@_Concurrent_queue_base_v4@details@Concurrency@@IEBA_KXZ +@ stub -arch=arm ?_Internal_swap@_Concurrent_queue_base_v4@details@Concurrency@@IAAXAAV123@@Z +@ stub -arch=i386 ?_Internal_swap@_Concurrent_queue_base_v4@details@Concurrency@@IAEXAAV123@@Z +@ stub -arch=win64 ?_Internal_swap@_Concurrent_queue_base_v4@details@Concurrency@@IEAAXAEAV123@@Z +@ stub -arch=arm ?_Internal_swap@_Concurrent_vector_base_v4@details@Concurrency@@IAAXAAV123@@Z +@ stub -arch=i386 ?_Internal_swap@_Concurrent_vector_base_v4@details@Concurrency@@IAEXAAV123@@Z +@ stub -arch=win64 ?_Internal_swap@_Concurrent_vector_base_v4@details@Concurrency@@IEAAXAEAV123@@Z +@ stub -arch=arm ?_Internal_throw_exception@_Concurrent_queue_base_v4@details@Concurrency@@IBAXXZ +@ stub -arch=i386 ?_Internal_throw_exception@_Concurrent_queue_base_v4@details@Concurrency@@IBEXXZ +@ stub -arch=win64 ?_Internal_throw_exception@_Concurrent_queue_base_v4@details@Concurrency@@IEBAXXZ +@ stub -arch=arm ?_Internal_throw_exception@_Concurrent_vector_base_v4@details@Concurrency@@IBAXI@Z +@ stub -arch=i386 ?_Internal_throw_exception@_Concurrent_vector_base_v4@details@Concurrency@@IBEXI@Z +@ stub -arch=win64 ?_Internal_throw_exception@_Concurrent_vector_base_v4@details@Concurrency@@IEBAX_K@Z +@ cdecl -arch=win32 ?_Ios_base_dtor@ios_base@std@@CAXPAV12@@Z(ptr) ios_base_Ios_base_dtor +@ cdecl -arch=win64 ?_Ios_base_dtor@ios_base@std@@CAXPEAV12@@Z(ptr) ios_base_Ios_base_dtor +@ cdecl -arch=arm ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAA_N_N@Z(ptr long) basic_istream_char__Ipfx +@ thiscall -arch=i386 ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z(ptr long) basic_istream_char__Ipfx +@ cdecl -arch=win64 ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z(ptr long) basic_istream_char__Ipfx +@ cdecl -arch=arm ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAA_N_N@Z(ptr long) basic_istream_wchar__Ipfx +@ thiscall -arch=i386 ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z(ptr long) basic_istream_wchar__Ipfx +@ cdecl -arch=win64 ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_N_N@Z(ptr long) basic_istream_wchar__Ipfx +@ cdecl -arch=arm ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAA_N_N@Z(ptr long) basic_istream_wchar__Ipfx +@ thiscall -arch=i386 ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_N_N@Z(ptr long) basic_istream_wchar__Ipfx +@ cdecl -arch=win64 ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_N_N@Z(ptr long) basic_istream_wchar__Ipfx +@ cdecl -arch=win32 ?_Iput@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPADI@Z(ptr ptr long ptr ptr long ptr long) num_put_char__Iput +@ cdecl -arch=win64 ?_Iput@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DPEAD_K@Z(ptr ptr ptr ptr long ptr long) num_put_char__Iput +@ cdecl -arch=win32 ?_Iput@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPADI@Z(ptr ptr long ptr ptr long ptr long) num_put_short__Iput +@ cdecl -arch=win64 ?_Iput@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GPEAD_K@Z(ptr ptr ptr ptr long ptr long) num_put_short__Iput +@ cdecl -arch=win32 ?_Iput@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPADI@Z(ptr ptr long ptr ptr long ptr long) num_put_wchar__Iput +@ cdecl -arch=win64 ?_Iput@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WPEAD_K@Z(ptr ptr ptr ptr long ptr long) num_put_wchar__Iput +@ stub -arch=win32 ?_Last_write_time@sys@tr2@std@@YAXPBD_J@Z +@ stub -arch=win64 ?_Last_write_time@sys@tr2@std@@YAXPEBD_J@Z +@ stub -arch=win32 ?_Last_write_time@sys@tr2@std@@YAXPB_W_J@Z +@ stub -arch=win64 ?_Last_write_time@sys@tr2@std@@YAXPEB_W_J@Z +@ stub -arch=win32 ?_Last_write_time@sys@tr2@std@@YA_JPBD@Z +@ stub -arch=win64 ?_Last_write_time@sys@tr2@std@@YA_JPEBD@Z +@ stub -arch=win32 ?_Last_write_time@sys@tr2@std@@YA_JPB_W@Z +@ stub -arch=win64 ?_Last_write_time@sys@tr2@std@@YA_JPEB_W@Z +@ stub -arch=arm ?_Launch@_Pad@std@@QAAXPAU_Thrd_imp_t@@@Z +@ stub -arch=i386 ?_Launch@_Pad@std@@QAEXPAU_Thrd_imp_t@@@Z +@ stub -arch=win64 ?_Launch@_Pad@std@@QEAAXPEAU_Thrd_imp_t@@@Z +@ stub -arch=win32 ?_Link@sys@tr2@std@@YAHPBD0@Z +@ stub -arch=win64 ?_Link@sys@tr2@std@@YAHPEBD0@Z +@ stub -arch=win32 ?_Link@sys@tr2@std@@YAHPB_W0@Z +@ stub -arch=win64 ?_Link@sys@tr2@std@@YAHPEB_W0@Z +@ cdecl -arch=win32 ?_Locimp_Addfac@_Locimp@locale@std@@CAXPAV123@PAVfacet@23@I@Z(ptr ptr long) locale__Locimp__Locimp_Addfac +@ cdecl -arch=win64 ?_Locimp_Addfac@_Locimp@locale@std@@CAXPEAV123@PEAVfacet@23@_K@Z(ptr ptr long) locale__Locimp__Locimp_Addfac +@ cdecl -arch=win32 ?_Locimp_ctor@_Locimp@locale@std@@CAXPAV123@ABV123@@Z(ptr ptr) locale__Locimp__Locimp_ctor +@ cdecl -arch=win64 ?_Locimp_ctor@_Locimp@locale@std@@CAXPEAV123@AEBV123@@Z(ptr ptr) locale__Locimp__Locimp_ctor +@ cdecl -arch=win32 ?_Locimp_dtor@_Locimp@locale@std@@CAXPAV123@@Z(ptr) locale__Locimp__Locimp_dtor +@ cdecl -arch=win64 ?_Locimp_dtor@_Locimp@locale@std@@CAXPEAV123@@Z(ptr) locale__Locimp__Locimp_dtor +@ cdecl -arch=win32 ?_Locinfo_Addcats@_Locinfo@std@@SAAAV12@PAV12@HPBD@Z(ptr long str) _Locinfo__Locinfo_Addcats +@ cdecl -arch=win64 ?_Locinfo_Addcats@_Locinfo@std@@SAAEAV12@PEAV12@HPEBD@Z(ptr long str) _Locinfo__Locinfo_Addcats +@ cdecl -arch=win32 ?_Locinfo_ctor@_Locinfo@std@@SAXPAV12@HPBD@Z(ptr long str) _Locinfo__Locinfo_ctor_cat_cstr +@ cdecl -arch=win64 ?_Locinfo_ctor@_Locinfo@std@@SAXPEAV12@HPEBD@Z(ptr long str) _Locinfo__Locinfo_ctor_cat_cstr +@ cdecl -arch=win32 ?_Locinfo_ctor@_Locinfo@std@@SAXPAV12@PBD@Z(ptr str) _Locinfo__Locinfo_ctor_cstr +@ cdecl -arch=win64 ?_Locinfo_ctor@_Locinfo@std@@SAXPEAV12@PEBD@Z(ptr str) _Locinfo__Locinfo_ctor_cstr +@ cdecl -arch=win32 ?_Locinfo_dtor@_Locinfo@std@@SAXPAV12@@Z(ptr) _Locinfo__Locinfo_dtor +@ cdecl -arch=win64 ?_Locinfo_dtor@_Locinfo@std@@SAXPEAV12@@Z(ptr) _Locinfo__Locinfo_dtor +@ cdecl -arch=arm ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAAXXZ(ptr) basic_streambuf_char__Lock +@ thiscall -arch=i386 ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAEXXZ(ptr) basic_streambuf_char__Lock +@ cdecl -arch=win64 ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@UEAAXXZ(ptr) basic_streambuf_char__Lock +@ cdecl -arch=arm ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAAXXZ(ptr) basic_streambuf_wchar__Lock +@ thiscall -arch=i386 ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAEXXZ(ptr) basic_streambuf_wchar__Lock +@ cdecl -arch=win64 ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@UEAAXXZ(ptr) basic_streambuf_wchar__Lock +@ cdecl -arch=arm ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAAXXZ(ptr) basic_streambuf_wchar__Lock +@ thiscall -arch=i386 ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAEXXZ(ptr) basic_streambuf_wchar__Lock +@ cdecl -arch=win64 ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UEAAXXZ(ptr) basic_streambuf_wchar__Lock +@ cdecl -arch=win32 ?_Lockit_ctor@_Lockit@std@@CAXPAV12@@Z(ptr) _Lockit__Lockit_ctor +@ cdecl -arch=win64 ?_Lockit_ctor@_Lockit@std@@CAXPEAV12@@Z(ptr) _Lockit__Lockit_ctor +@ cdecl -arch=win32 ?_Lockit_ctor@_Lockit@std@@CAXPAV12@H@Z(ptr long) _Lockit__Lockit_ctor_locktype +@ cdecl -arch=win64 ?_Lockit_ctor@_Lockit@std@@CAXPEAV12@H@Z(ptr long) _Lockit__Lockit_ctor_locktype +@ cdecl ?_Lockit_ctor@_Lockit@std@@SAXH@Z(long) _Lockit_init +@ cdecl -arch=win32 ?_Lockit_dtor@_Lockit@std@@CAXPAV12@@Z(ptr) _Lockit__Lockit_dtor +@ cdecl -arch=win64 ?_Lockit_dtor@_Lockit@std@@CAXPEAV12@@Z(ptr) _Lockit__Lockit_dtor +@ cdecl ?_Lockit_dtor@_Lockit@std@@SAXH@Z(long) _Lockit_free +@ stub -arch=win32 ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PBDAAH@Z +@ stub -arch=win64 ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PEBDAEAH@Z +@ stub -arch=win32 ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PB_WAAH@Z +@ stub -arch=win64 ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PEB_WAEAH@Z +@ stub -arch=win32 ?_MP_Add@std@@YAXQA_K_K@Z +@ stub -arch=win64 ?_MP_Add@std@@YAXQEA_K_K@Z +@ stub -arch=win32 ?_MP_Get@std@@YA_KQA_K@Z +@ stub -arch=win64 ?_MP_Get@std@@YA_KQEA_K@Z +@ stub -arch=win32 ?_MP_Mul@std@@YAXQA_K_K1@Z +@ stub -arch=win64 ?_MP_Mul@std@@YAXQEA_K_K1@Z +@ stub -arch=win32 ?_MP_Rem@std@@YAXQA_K_K@Z +@ stub -arch=win64 ?_MP_Rem@std@@YAXQEA_K_K@Z +@ stub -arch=win32 ?_Make_dir@sys@tr2@std@@YAHPBD@Z +@ stub -arch=win64 ?_Make_dir@sys@tr2@std@@YAHPEBD@Z +@ stub -arch=win32 ?_Make_dir@sys@tr2@std@@YAHPB_W@Z +@ stub -arch=win64 ?_Make_dir@sys@tr2@std@@YAHPEB_W@Z +@ cdecl -arch=win32 ?_Makeloc@_Locimp@locale@std@@CAPAV123@ABV_Locinfo@3@HPAV123@PBV23@@Z(ptr long ptr ptr) locale__Locimp__Makeloc +@ cdecl -arch=win64 ?_Makeloc@_Locimp@locale@std@@CAPEAV123@AEBV_Locinfo@3@HPEAV123@PEBV23@@Z(ptr long ptr ptr) locale__Locimp__Makeloc +@ cdecl -arch=win32 ?_Makeushloc@_Locimp@locale@std@@CAXABV_Locinfo@3@HPAV123@PBV23@@Z(ptr long ptr ptr) locale__Locimp__Makeushloc +@ cdecl -arch=win64 ?_Makeushloc@_Locimp@locale@std@@CAXAEBV_Locinfo@3@HPEAV123@PEBV23@@Z(ptr long ptr ptr) locale__Locimp__Makeushloc +@ cdecl -arch=win32 ?_Makewloc@_Locimp@locale@std@@CAXABV_Locinfo@3@HPAV123@PBV23@@Z(ptr long ptr ptr) locale__Locimp__Makewloc +@ cdecl -arch=win64 ?_Makewloc@_Locimp@locale@std@@CAXAEBV_Locinfo@3@HPEAV123@PEBV23@@Z(ptr long ptr ptr) locale__Locimp__Makewloc +@ cdecl -arch=win32 ?_Makexloc@_Locimp@locale@std@@CAXABV_Locinfo@3@HPAV123@PBV23@@Z(ptr long ptr ptr) locale__Locimp__Makexloc +@ cdecl -arch=win64 ?_Makexloc@_Locimp@locale@std@@CAXAEBV_Locinfo@3@HPEAV123@PEBV23@@Z(ptr long ptr ptr) locale__Locimp__Makexloc +@ stub -arch=win32 ?_Mtx_delete@threads@stdext@@YAXPAX@Z +@ stub -arch=win64 ?_Mtx_delete@threads@stdext@@YAXPEAX@Z +@ stub -arch=win32 ?_Mtx_lock@threads@stdext@@YAXPAX@Z +@ stub -arch=win64 ?_Mtx_lock@threads@stdext@@YAXPEAX@Z +@ stub -arch=win32 ?_Mtx_new@threads@stdext@@YAXAAPAX@Z +@ stub -arch=win64 ?_Mtx_new@threads@stdext@@YAXAEAPEAX@Z +@ stub -arch=win32 ?_Mtx_unlock@threads@stdext@@YAXPAX@Z +@ stub -arch=win64 ?_Mtx_unlock@threads@stdext@@YAXPEAX@Z +@ cdecl -arch=win32 ?_New_Locimp@_Locimp@locale@std@@CAPAV123@ABV123@@Z(ptr) locale__Locimp__New_Locimp +@ cdecl -arch=win64 ?_New_Locimp@_Locimp@locale@std@@CAPEAV123@AEBV123@@Z(ptr) locale__Locimp__New_Locimp +@ cdecl -arch=win32 ?_New_Locimp@_Locimp@locale@std@@CAPAV123@_N@Z(long) locale__Locimp__New_Locimp_transparent +@ cdecl -arch=win64 ?_New_Locimp@_Locimp@locale@std@@CAPEAV123@_N@Z(long) locale__Locimp__New_Locimp_transparent +@ stub -arch=win32 ?_Open_dir@sys@tr2@std@@YAPAXAAY0BAE@DPBDAAHAAW4file_type@123@@Z +@ stub -arch=win64 ?_Open_dir@sys@tr2@std@@YAPEAXAEAY0BAE@DPEBDAEAHAEAW4file_type@123@@Z +@ stub -arch=win32 ?_Open_dir@sys@tr2@std@@YAPAXAAY0BAE@_WPB_WAAHAAW4file_type@123@@Z +@ stub -arch=win64 ?_Open_dir@sys@tr2@std@@YAPEAXAEAY0BAE@_WPEB_WAEAHAEAW4file_type@123@@Z +@ cdecl -arch=arm ?_Orphan_all@_Container_base0@std@@QAAXXZ(ptr) Container_base0_Orphan_all +@ thiscall -arch=i386 ?_Orphan_all@_Container_base0@std@@QAEXXZ(ptr) Container_base0_Orphan_all +@ cdecl -arch=win64 ?_Orphan_all@_Container_base0@std@@QEAAXXZ(ptr) Container_base0_Orphan_all +@ cdecl -arch=arm ?_Orphan_all@_Container_base12@std@@QAAXXZ(ptr) _Container_base12__Orphan_all +@ thiscall -arch=i386 ?_Orphan_all@_Container_base12@std@@QAEXXZ(ptr) _Container_base12__Orphan_all +@ cdecl -arch=win64 ?_Orphan_all@_Container_base12@std@@QEAAXXZ(ptr) _Container_base12__Orphan_all +@ cdecl -arch=arm ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAXXZ(ptr) basic_ostream_char__Osfx +@ thiscall -arch=i386 ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ(ptr) basic_ostream_char__Osfx +@ cdecl -arch=win64 ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ(ptr) basic_ostream_char__Osfx +@ cdecl -arch=arm ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAXXZ(ptr) basic_ostream_wchar__Osfx +@ thiscall -arch=i386 ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ(ptr) basic_ostream_wchar__Osfx +@ cdecl -arch=win64 ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ(ptr) basic_ostream_wchar__Osfx +@ cdecl -arch=arm ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAXXZ(ptr) basic_ostream_wchar__Osfx +@ thiscall -arch=i386 ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ(ptr) basic_ostream_wchar__Osfx +@ cdecl -arch=win64 ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ(ptr) basic_ostream_wchar__Osfx +@ cdecl -ret64 -arch=arm ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBA_JXZ(ptr) basic_streambuf_char__Pnavail +@ thiscall -ret64 -arch=i386 ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBE_JXZ(ptr) basic_streambuf_char__Pnavail +@ cdecl -arch=win64 ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBA_JXZ(ptr) basic_streambuf_char__Pnavail +@ cdecl -ret64 -arch=arm ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBA_JXZ(ptr) basic_streambuf_wchar__Pnavail +@ thiscall -ret64 -arch=i386 ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBE_JXZ(ptr) basic_streambuf_wchar__Pnavail +@ cdecl -arch=win64 ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBA_JXZ(ptr) basic_streambuf_wchar__Pnavail +@ cdecl -ret64 -arch=arm ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBA_JXZ(ptr) basic_streambuf_wchar__Pnavail +@ thiscall -ret64 -arch=i386 ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBE_JXZ(ptr) basic_streambuf_wchar__Pnavail +@ cdecl -arch=win64 ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBA_JXZ(ptr) basic_streambuf_wchar__Pnavail +@ cdecl -arch=arm ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAPADXZ(ptr) basic_streambuf_char__Pninc +@ thiscall -arch=i386 ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ(ptr) basic_streambuf_char__Pninc +@ cdecl -arch=win64 ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ(ptr) basic_streambuf_char__Pninc +@ cdecl -arch=arm ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAPAGXZ(ptr) basic_streambuf_wchar__Pninc +@ thiscall -arch=i386 ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ(ptr) basic_streambuf_wchar__Pninc +@ cdecl -arch=win64 ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ(ptr) basic_streambuf_wchar__Pninc +@ cdecl -arch=arm ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAPA_WXZ(ptr) basic_streambuf_wchar__Pninc +@ thiscall -arch=i386 ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ(ptr) basic_streambuf_wchar__Pninc +@ cdecl -arch=win64 ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ(ptr) basic_streambuf_wchar__Pninc +@ extern -arch=win32 ?_Ptr_cerr@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A _Ptr_cerr +@ extern -arch=win64 ?_Ptr_cerr@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA _Ptr_cerr +@ extern -arch=win32 ?_Ptr_cin@std@@3PAV?$basic_istream@DU?$char_traits@D@std@@@1@A _Ptr_cin +@ extern -arch=win64 ?_Ptr_cin@std@@3PEAV?$basic_istream@DU?$char_traits@D@std@@@1@EA _Ptr_cin +@ extern -arch=win32 ?_Ptr_clog@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A _Ptr_clog +@ extern -arch=win64 ?_Ptr_clog@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA _Ptr_clog +@ extern -arch=win32 ?_Ptr_cout@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A _Ptr_cout +@ extern -arch=win64 ?_Ptr_cout@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA _Ptr_cout +@ extern -arch=win32 ?_Ptr_wcerr@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A _Ptr_ucerr +@ extern -arch=win64 ?_Ptr_wcerr@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA _Ptr_ucerr +@ extern -arch=win32 ?_Ptr_wcerr@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A _Ptr_wcerr +@ extern -arch=win64 ?_Ptr_wcerr@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA _Ptr_wcerr +@ extern -arch=win32 ?_Ptr_wcin@std@@3PAV?$basic_istream@GU?$char_traits@G@std@@@1@A _Ptr_ucin +@ extern -arch=win64 ?_Ptr_wcin@std@@3PEAV?$basic_istream@GU?$char_traits@G@std@@@1@EA _Ptr_ucin +@ extern -arch=win32 ?_Ptr_wcin@std@@3PAV?$basic_istream@_WU?$char_traits@_W@std@@@1@A _Ptr_wcin +@ extern -arch=win64 ?_Ptr_wcin@std@@3PEAV?$basic_istream@_WU?$char_traits@_W@std@@@1@EA _Ptr_wcin +@ extern -arch=win32 ?_Ptr_wclog@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A _Ptr_uclog +@ extern -arch=win64 ?_Ptr_wclog@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA _Ptr_uclog +@ extern -arch=win32 ?_Ptr_wclog@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A _Ptr_wclog +@ extern -arch=win64 ?_Ptr_wclog@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA _Ptr_wclog +@ extern -arch=win32 ?_Ptr_wcout@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A _Ptr_ucout +@ extern -arch=win64 ?_Ptr_wcout@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA _Ptr_ucout +@ extern -arch=win32 ?_Ptr_wcout@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A _Ptr_wcout +@ extern -arch=win64 ?_Ptr_wcout@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA _Ptr_wcout +@ cdecl -arch=win32 ?_Put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@PBDI@Z(ptr ptr long ptr str long) num_put_char__Put +@ cdecl -arch=win64 ?_Put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@PEBD_K@Z(ptr ptr ptr str long) num_put_char__Put +@ cdecl -arch=win32 ?_Put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@PBGI@Z(ptr ptr long ptr ptr long) num_put_wchar__Put +@ cdecl -arch=win64 ?_Put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@PEBG_K@Z(ptr ptr ptr ptr long) num_put_wchar__Put +@ cdecl -arch=win32 ?_Put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@PB_WI@Z(ptr ptr long ptr wstr long) num_put_wchar__Put +@ cdecl -arch=win64 ?_Put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@PEB_W_K@Z(ptr ptr ptr wstr long) num_put_wchar__Put +@ stub -arch=win32 ?_Raise_handler@std@@3P6AXABVexception@stdext@@@ZA +@ stub -arch=win64 ?_Raise_handler@std@@3P6AXAEBVexception@stdext@@@ZEA +@ cdecl ?_Random_device@std@@YAIXZ() _Random_device +@ stub -arch=win32 ?_Read_dir@sys@tr2@std@@YAPADAAY0BAE@DPAXAAW4file_type@123@@Z +@ stub -arch=win64 ?_Read_dir@sys@tr2@std@@YAPEADAEAY0BAE@DPEAXAEAW4file_type@123@@Z +@ stub -arch=win32 ?_Read_dir@sys@tr2@std@@YAPA_WAAY0BAE@_WPAXAAW4file_type@123@@Z +@ stub -arch=win64 ?_Read_dir@sys@tr2@std@@YAPEA_WAEAY0BAE@_WPEAXAEAW4file_type@123@@Z +@ stub -arch=arm ?_Release@_Pad@std@@QAAXXZ +@ stub -arch=i386 ?_Release@_Pad@std@@QAEXXZ +@ stub -arch=win64 ?_Release@_Pad@std@@QEAAXXZ +@ stub -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPBD@Z +@ stub -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEBD@Z +@ stub -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z +@ stub -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z +@ stub -arch=win32 ?_Rename@sys@tr2@std@@YAHPBD0@Z +@ stub -arch=win64 ?_Rename@sys@tr2@std@@YAHPEBD0@Z +@ stub -arch=win32 ?_Rename@sys@tr2@std@@YAHPB_W0@Z +@ stub -arch=win64 ?_Rename@sys@tr2@std@@YAHPEB_W0@Z +@ cdecl -arch=win32 ?_Rep@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@DI@Z(ptr ptr long ptr long long) num_put_char__Rep +@ cdecl -arch=win64 ?_Rep@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@D_K@Z(ptr ptr ptr long long) num_put_char__Rep +@ cdecl -arch=win32 ?_Rep@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@GI@Z(ptr ptr long ptr long long) num_put_wchar__Rep +@ cdecl -arch=win64 ?_Rep@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@G_K@Z(ptr ptr ptr long long) num_put_wchar__Rep +@ cdecl -arch=win32 ?_Rep@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@_WI@Z(ptr ptr long ptr long long) num_put_wchar__Rep +@ cdecl -arch=win64 ?_Rep@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@_W_K@Z(ptr ptr ptr long long) num_put_wchar__Rep +@ stub ?_Rethrow_future_exception@std@@YAXVexception_ptr@1@@Z +@ stub -arch=win32 ?_Rng_abort@std@@YAXPBD@Z +@ stub -arch=win64 ?_Rng_abort@std@@YAXPEBD@Z +@ stub -arch=win32 ?_Segment_index_of@_Concurrent_vector_base_v4@details@Concurrency@@KAII@Z +@ stub -arch=win64 ?_Segment_index_of@_Concurrent_vector_base_v4@details@Concurrency@@KA_K_K@Z +@ cdecl -arch=win32 ?_Setgloballocale@locale@std@@CAXPAX@Z(ptr) locale__Setgloballocale +@ cdecl -arch=win64 ?_Setgloballocale@locale@std@@CAXPEAX@Z(ptr) locale__Setgloballocale +@ stub -arch=win32 ?_Src@?1??_Getffldx@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@3@1AAVios_base@3@PAH@Z@4QBDB +@ stub -arch=win64 ?_Src@?1??_Getffldx@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@3@1AEAVios_base@3@PEAH@Z@4QBDB +@ stub -arch=win32 ?_Src@?1??_Getffldx@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@3@1AAVios_base@3@PAH@Z@4QBDB +@ stub -arch=win64 ?_Src@?1??_Getffldx@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@3@1AEAVios_base@3@PEAH@Z@4QBDB +@ stub -arch=win32 ?_Src@?1??_Getffldx@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@3@1AAVios_base@3@PAH@Z@4QBDB +@ stub -arch=win64 ?_Src@?1??_Getffldx@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@3@1AEAVios_base@3@PEAH@Z@4QBDB +@ stub -arch=win32 ?_Src@?1??_Getifld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@3@1HABVlocale@3@@Z@4QBDB +@ stub -arch=win64 ?_Src@?1??_Getifld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@3@1HAEBVlocale@3@@Z@4QBDB +@ stub -arch=win32 ?_Src@?1??_Getifld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@3@1HABVlocale@3@@Z@4QBDB +@ stub -arch=win64 ?_Src@?1??_Getifld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@3@1HAEBVlocale@3@@Z@4QBDB +@ stub -arch=win32 ?_Src@?1??_Getifld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@3@1HABVlocale@3@@Z@4QBDB +@ stub -arch=win64 ?_Src@?1??_Getifld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@3@1HAEBVlocale@3@@Z@4QBDB +@ stub -arch=win32 ?_Src@?3??_Getffld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@3@1AAVios_base@3@PAH@Z@4QBDB +@ stub -arch=win64 ?_Src@?3??_Getffld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@3@1AEAVios_base@3@PEAH@Z@4QBDB +@ stub -arch=win32 ?_Src@?3??_Getffld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@3@1AAVios_base@3@PAH@Z@4QBDB +@ stub -arch=win64 ?_Src@?3??_Getffld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@3@1AEAVios_base@3@PEAH@Z@4QBDB +@ stub -arch=win32 ?_Src@?3??_Getffld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@3@1AAVios_base@3@PAH@Z@4QBDB +@ stub -arch=win64 ?_Src@?3??_Getffld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@3@1AEAVios_base@3@PEAH@Z@4QBDB +@ stub -arch=win32 ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PBDAAH@Z +@ stub -arch=win64 ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PEBDAEAH@Z +@ stub -arch=win32 ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PB_WAAH@Z +@ stub -arch=win64 ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PEB_WAEAH@Z +@ stub -arch=win32 ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PBD@Z +@ stub -arch=win64 ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PEBD@Z +@ stub -arch=win32 ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PB_W@Z +@ stub -arch=win64 ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PEB_W@Z +@ cdecl -arch=arm ?_Swap_all@_Container_base0@std@@QAAXAAU12@@Z(ptr ptr) Container_base0_Swap_all +@ thiscall -arch=i386 ?_Swap_all@_Container_base0@std@@QAEXAAU12@@Z(ptr ptr) Container_base0_Swap_all +@ cdecl -arch=win64 ?_Swap_all@_Container_base0@std@@QEAAXAEAU12@@Z(ptr ptr) Container_base0_Swap_all +@ cdecl -arch=arm ?_Swap_all@_Container_base12@std@@QAAXAAU12@@Z(ptr ptr) _Container_base12__Swap_all +@ thiscall -arch=i386 ?_Swap_all@_Container_base12@std@@QAEXAAU12@@Z(ptr ptr) _Container_base12__Swap_all +@ cdecl -arch=win64 ?_Swap_all@_Container_base12@std@@QEAAXAEAU12@@Z(ptr ptr) _Container_base12__Swap_all +@ stub -arch=win32 ?_Symlink@sys@tr2@std@@YAHPBD0@Z +@ stub -arch=win64 ?_Symlink@sys@tr2@std@@YAHPEBD0@Z +@ stub -arch=win32 ?_Symlink@sys@tr2@std@@YAHPB_W0@Z +@ stub -arch=win64 ?_Symlink@sys@tr2@std@@YAHPEB_W0@Z +@ extern ?_Sync@ios_base@std@@0_NA ios_base_Sync +@ stub -arch=win32 ?_Syserror_map@std@@YAPBDH@Z +@ stub -arch=win64 ?_Syserror_map@std@@YAPEBDH@Z +@ stub ?_Throw_C_error@std@@YAXH@Z +@ stub ?_Throw_Cpp_error@std@@YAXH@Z +@ stub -arch=win32 ?_Throw_future_error@std@@YAXABVerror_code@1@@Z +@ stub -arch=win64 ?_Throw_future_error@std@@YAXAEBVerror_code@1@@Z +@ stub ?_Throw_lock_error@threads@stdext@@YAXXZ +@ stub ?_Throw_resource_error@threads@stdext@@YAXXZ +@ cdecl -arch=arm ?_Tidy@?$_Yarn@D@std@@AAAXXZ(ptr) _Yarn_char__Tidy +@ thiscall -arch=i386 ?_Tidy@?$_Yarn@D@std@@AAEXXZ(ptr) _Yarn_char__Tidy +@ cdecl -arch=win64 ?_Tidy@?$_Yarn@D@std@@AEAAXXZ(ptr) _Yarn_char__Tidy +@ stub -arch=arm ?_Tidy@?$_Yarn@_W@std@@AAAXXZ +@ stub -arch=i386 ?_Tidy@?$_Yarn@_W@std@@AAEXXZ +@ stub -arch=win64 ?_Tidy@?$_Yarn@_W@std@@AEAAXXZ +@ cdecl -arch=arm ?_Tidy@?$ctype@D@std@@IAAXXZ(ptr) ctype_char__Tidy +@ thiscall -arch=i386 ?_Tidy@?$ctype@D@std@@IAEXXZ(ptr) ctype_char__Tidy +@ cdecl -arch=win64 ?_Tidy@?$ctype@D@std@@IEAAXXZ(ptr) ctype_char__Tidy +@ stub -arch=arm ?_Tidy@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AAAXXZ +@ stub -arch=i386 ?_Tidy@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AAEXXZ +@ stub -arch=win64 ?_Tidy@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEAAXXZ +@ stub -arch=arm ?_Tidy@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AAAXXZ +@ stub -arch=i386 ?_Tidy@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AAEXXZ +@ stub -arch=win64 ?_Tidy@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEAAXXZ +@ stub -arch=arm ?_Tidy@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AAAXXZ +@ stub -arch=i386 ?_Tidy@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AAEXXZ +@ stub -arch=win64 ?_Tidy@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEAAXXZ +@ cdecl -arch=win32 ?_Tidy@ios_base@std@@AAAXXZ(ptr) ios_base_Tidy +@ stub -arch=i386 ?_Tidy@ios_base@std@@AAEXXZ +@ cdecl -arch=win64 ?_Tidy@ios_base@std@@AEAAXXZ(ptr) ios_base_Tidy +@ stub -arch=win32 ?_Unlink@sys@tr2@std@@YAHPBD@Z +@ stub -arch=win64 ?_Unlink@sys@tr2@std@@YAHPEBD@Z +@ stub -arch=win32 ?_Unlink@sys@tr2@std@@YAHPB_W@Z +@ stub -arch=win64 ?_Unlink@sys@tr2@std@@YAHPEB_W@Z +@ cdecl -arch=arm ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAAXXZ(ptr) basic_streambuf_char__Unlock +@ thiscall -arch=i386 ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAEXXZ(ptr) basic_streambuf_char__Unlock +@ cdecl -arch=win64 ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@UEAAXXZ(ptr) basic_streambuf_char__Unlock +@ cdecl -arch=arm ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAAXXZ(ptr) basic_streambuf_wchar__Unlock +@ thiscall -arch=i386 ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAEXXZ(ptr) basic_streambuf_wchar__Unlock +@ cdecl -arch=win64 ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@UEAAXXZ(ptr) basic_streambuf_wchar__Unlock +@ cdecl -arch=arm ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAAXXZ(ptr) basic_streambuf_wchar__Unlock +@ thiscall -arch=i386 ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAEXXZ(ptr) basic_streambuf_wchar__Unlock +@ cdecl -arch=win64 ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UEAAXXZ(ptr) basic_streambuf_wchar__Unlock +@ stub -arch=arm ?_W_Getdays@_Locinfo@std@@QBAPBGXZ +@ stub -arch=i386 ?_W_Getdays@_Locinfo@std@@QBEPBGXZ +@ stub -arch=win64 ?_W_Getdays@_Locinfo@std@@QEBAPEBGXZ +@ stub -arch=arm ?_W_Getmonths@_Locinfo@std@@QBAPBGXZ +@ stub -arch=i386 ?_W_Getmonths@_Locinfo@std@@QBEPBGXZ +@ stub -arch=win64 ?_W_Getmonths@_Locinfo@std@@QEBAPEBGXZ +@ stub -arch=arm ?_W_Gettnames@_Locinfo@std@@QBA?AV_Timevec@2@XZ +@ stub -arch=i386 ?_W_Gettnames@_Locinfo@std@@QBE?AV_Timevec@2@XZ +@ stub -arch=win64 ?_W_Gettnames@_Locinfo@std@@QEBA?AV_Timevec@2@XZ +@ stub -arch=win32 ?_Winerror_map@std@@YAPBDH@Z +@ stub -arch=win64 ?_Winerror_map@std@@YAPEBDH@Z +@ stub ?_XLgamma@std@@YAMM@Z +@ stub ?_XLgamma@std@@YANN@Z +@ stub ?_XLgamma@std@@YAOO@Z +@ cdecl ?_Xbad_alloc@std@@YAXXZ() _Xmem +@ stub ?_Xbad_function_call@std@@YAXXZ +@ cdecl -arch=win32 ?_Xinvalid_argument@std@@YAXPBD@Z(str) _Xinvalid_argument +@ cdecl -arch=win64 ?_Xinvalid_argument@std@@YAXPEBD@Z(str) _Xinvalid_argument +@ cdecl -arch=win32 ?_Xlength_error@std@@YAXPBD@Z(str) _Xlength_error +@ cdecl -arch=win64 ?_Xlength_error@std@@YAXPEBD@Z(str) _Xlength_error +@ cdecl -arch=win32 ?_Xout_of_range@std@@YAXPBD@Z(str) _Xout_of_range +@ cdecl -arch=win64 ?_Xout_of_range@std@@YAXPEBD@Z(str) _Xout_of_range +@ stub -arch=win32 ?_Xoverflow_error@std@@YAXPBD@Z +@ stub -arch=win64 ?_Xoverflow_error@std@@YAXPEBD@Z +@ stub ?_Xregex_error@std@@YAXW4error_type@regex_constants@1@@Z +@ cdecl -arch=win32 ?_Xruntime_error@std@@YAXPBD@Z(str) _Xruntime_error +@ cdecl -arch=win64 ?_Xruntime_error@std@@YAXPEBD@Z(str) _Xruntime_error +@ stub ?adopt_lock@std@@3Uadopt_lock_t@1@B +@ cdecl -arch=arm ?always_noconv@codecvt_base@std@@QBA_NXZ(ptr) codecvt_base_always_noconv +@ thiscall -arch=i386 ?always_noconv@codecvt_base@std@@QBE_NXZ(ptr) codecvt_base_always_noconv +@ cdecl -arch=win64 ?always_noconv@codecvt_base@std@@QEBA_NXZ(ptr) codecvt_base_always_noconv +@ cdecl -arch=arm ?bad@ios_base@std@@QBA_NXZ(ptr) ios_base_bad +@ thiscall -arch=i386 ?bad@ios_base@std@@QBE_NXZ(ptr) ios_base_bad +@ cdecl -arch=win64 ?bad@ios_base@std@@QEBA_NXZ(ptr) ios_base_bad +@ cdecl -arch=arm ?c_str@?$_Yarn@D@std@@QBAPBDXZ(ptr) _Yarn_char_c_str +@ thiscall -arch=i386 ?c_str@?$_Yarn@D@std@@QBEPBDXZ(ptr) _Yarn_char_c_str +@ cdecl -arch=win64 ?c_str@?$_Yarn@D@std@@QEBAPEBDXZ(ptr) _Yarn_char_c_str +@ stub -arch=arm ?cancel@agent@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?cancel@agent@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?cancel@agent@Concurrency@@QEAA_NXZ +@ extern ?cerr@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A cerr +@ extern ?cin@std@@3V?$basic_istream@DU?$char_traits@D@std@@@1@A cin +@ cdecl -arch=win32 ?classic@locale@std@@SAABV12@XZ() locale_classic +@ cdecl -arch=win64 ?classic@locale@std@@SAAEBV12@XZ() locale_classic +@ stub -arch=win32 ?classic_table@?$ctype@D@std@@SAPBFXZ +@ stub -arch=win64 ?classic_table@?$ctype@D@std@@SAPEBFXZ +@ cdecl -arch=arm ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAXH_N@Z(ptr long long) basic_ios_char_clear_reraise +@ thiscall -arch=i386 ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXH_N@Z(ptr long long) basic_ios_char_clear_reraise +@ cdecl -arch=win64 ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXH_N@Z(ptr long long) basic_ios_char_clear_reraise +@ cdecl -arch=arm ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAXI@Z(ptr long) basic_ios_char_clear +@ thiscall -arch=i386 ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXI@Z(ptr long) basic_ios_char_clear +@ cdecl -arch=win64 ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXI@Z(ptr long) basic_ios_char_clear +@ cdecl -arch=arm ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAXH_N@Z(ptr long long) basic_ios_wchar_clear_reraise +@ thiscall -arch=i386 ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXH_N@Z(ptr long long) basic_ios_wchar_clear_reraise +@ cdecl -arch=win64 ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXH_N@Z(ptr long long) basic_ios_wchar_clear_reraise +@ cdecl -arch=arm ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAXI@Z(ptr long) basic_ios_wchar_clear +@ thiscall -arch=i386 ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXI@Z(ptr long) basic_ios_wchar_clear +@ cdecl -arch=win64 ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXI@Z(ptr long) basic_ios_wchar_clear +@ cdecl -arch=arm ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAXH_N@Z(ptr long long) basic_ios_wchar_clear_reraise +@ thiscall -arch=i386 ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXH_N@Z(ptr long long) basic_ios_wchar_clear_reraise +@ cdecl -arch=win64 ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXH_N@Z(ptr long long) basic_ios_wchar_clear_reraise +@ cdecl -arch=arm ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAXI@Z(ptr long) basic_ios_wchar_clear +@ thiscall -arch=i386 ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXI@Z(ptr long) basic_ios_wchar_clear +@ cdecl -arch=win64 ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXI@Z(ptr long) basic_ios_wchar_clear +@ cdecl -arch=arm ?clear@ios_base@std@@QAAXH@Z(ptr long) ios_base_clear +@ thiscall -arch=i386 ?clear@ios_base@std@@QAEXH@Z(ptr long) ios_base_clear +@ cdecl -arch=win64 ?clear@ios_base@std@@QEAAXH@Z(ptr long) ios_base_clear +@ cdecl -arch=arm ?clear@ios_base@std@@QAAXH_N@Z(ptr long long) ios_base_clear_reraise +@ thiscall -arch=i386 ?clear@ios_base@std@@QAEXH_N@Z(ptr long long) ios_base_clear_reraise +@ cdecl -arch=win64 ?clear@ios_base@std@@QEAAXH_N@Z(ptr long long) ios_base_clear_reraise +@ cdecl -arch=arm ?clear@ios_base@std@@QAAXI@Z(ptr long) ios_base_clear_unsigned +@ thiscall -arch=i386 ?clear@ios_base@std@@QAEXI@Z(ptr long) ios_base_clear_unsigned +@ cdecl -arch=win64 ?clear@ios_base@std@@QEAAXI@Z(ptr long) ios_base_clear_unsigned +@ extern ?clog@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A clog +@ cdecl -arch=arm ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAAAV12@ABV12@@Z(ptr ptr) basic_ios_char_copyfmt +@ thiscall -arch=i386 ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEAAV12@ABV12@@Z(ptr ptr) basic_ios_char_copyfmt +@ cdecl -arch=win64 ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEBV12@@Z(ptr ptr) basic_ios_char_copyfmt +@ cdecl -arch=arm ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAAAV12@ABV12@@Z(ptr ptr) basic_ios_wchar_copyfmt +@ thiscall -arch=i386 ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEAAV12@ABV12@@Z(ptr ptr) basic_ios_wchar_copyfmt +@ cdecl -arch=win64 ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEBV12@@Z(ptr ptr) basic_ios_wchar_copyfmt +@ cdecl -arch=arm ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAAAV12@ABV12@@Z(ptr ptr) basic_ios_wchar_copyfmt +@ thiscall -arch=i386 ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEAAV12@ABV12@@Z(ptr ptr) basic_ios_wchar_copyfmt +@ cdecl -arch=win64 ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEBV12@@Z(ptr ptr) basic_ios_wchar_copyfmt +@ cdecl -arch=arm ?copyfmt@ios_base@std@@QAAAAV12@ABV12@@Z(ptr ptr) ios_base_copyfmt +@ thiscall -arch=i386 ?copyfmt@ios_base@std@@QAEAAV12@ABV12@@Z(ptr ptr) ios_base_copyfmt +@ cdecl -arch=win64 ?copyfmt@ios_base@std@@QEAAAEAV12@AEBV12@@Z(ptr ptr) ios_base_copyfmt +@ extern ?cout@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A cout +@ stub -arch=arm ?date_order@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AW4dateorder@time_base@2@XZ +@ stub -arch=i386 ?date_order@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AW4dateorder@time_base@2@XZ +@ stub -arch=win64 ?date_order@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AW4dateorder@time_base@2@XZ +@ stub -arch=arm ?date_order@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AW4dateorder@time_base@2@XZ +@ stub -arch=i386 ?date_order@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AW4dateorder@time_base@2@XZ +@ stub -arch=win64 ?date_order@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AW4dateorder@time_base@2@XZ +@ stub -arch=arm ?date_order@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AW4dateorder@time_base@2@XZ +@ stub -arch=i386 ?date_order@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AW4dateorder@time_base@2@XZ +@ stub -arch=win64 ?date_order@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AW4dateorder@time_base@2@XZ +@ stub ?defer_lock@std@@3Udefer_lock_t@1@B +@ stub -arch=arm ?do_always_noconv@?$codecvt@DDH@std@@MBA_NXZ +@ stub -arch=i386 ?do_always_noconv@?$codecvt@DDH@std@@MBE_NXZ +@ stub -arch=win64 ?do_always_noconv@?$codecvt@DDH@std@@MEBA_NXZ +@ cdecl -arch=arm ?do_always_noconv@?$codecvt@GDH@std@@MBA_NXZ(ptr) codecvt_wchar_do_always_noconv +@ thiscall -arch=i386 ?do_always_noconv@?$codecvt@GDH@std@@MBE_NXZ(ptr) codecvt_wchar_do_always_noconv +@ cdecl -arch=win64 ?do_always_noconv@?$codecvt@GDH@std@@MEBA_NXZ(ptr) codecvt_wchar_do_always_noconv +@ cdecl -arch=arm ?do_always_noconv@?$codecvt@_WDH@std@@MBA_NXZ(ptr) codecvt_wchar_do_always_noconv +@ thiscall -arch=i386 ?do_always_noconv@?$codecvt@_WDH@std@@MBE_NXZ(ptr) codecvt_wchar_do_always_noconv +@ cdecl -arch=win64 ?do_always_noconv@?$codecvt@_WDH@std@@MEBA_NXZ(ptr) codecvt_wchar_do_always_noconv +@ cdecl -arch=arm ?do_always_noconv@codecvt_base@std@@MBA_NXZ(ptr) codecvt_base_do_always_noconv +@ thiscall -arch=i386 ?do_always_noconv@codecvt_base@std@@MBE_NXZ(ptr) codecvt_base_do_always_noconv +@ cdecl -arch=win64 ?do_always_noconv@codecvt_base@std@@MEBA_NXZ(ptr) codecvt_base_do_always_noconv +@ stub -arch=arm ?do_date_order@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AW4dateorder@time_base@2@XZ +@ stub -arch=i386 ?do_date_order@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AW4dateorder@time_base@2@XZ +@ stub -arch=win64 ?do_date_order@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AW4dateorder@time_base@2@XZ +@ stub -arch=arm ?do_date_order@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AW4dateorder@time_base@2@XZ +@ stub -arch=i386 ?do_date_order@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AW4dateorder@time_base@2@XZ +@ stub -arch=win64 ?do_date_order@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AW4dateorder@time_base@2@XZ +@ stub -arch=arm ?do_date_order@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AW4dateorder@time_base@2@XZ +@ stub -arch=i386 ?do_date_order@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AW4dateorder@time_base@2@XZ +@ stub -arch=win64 ?do_date_order@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AW4dateorder@time_base@2@XZ +@ stub -arch=arm ?do_encoding@?$codecvt@GDH@std@@MBAHXZ +@ stub -arch=i386 ?do_encoding@?$codecvt@GDH@std@@MBEHXZ +@ stub -arch=win64 ?do_encoding@?$codecvt@GDH@std@@MEBAHXZ +@ stub -arch=arm ?do_encoding@?$codecvt@_WDH@std@@MBAHXZ +@ stub -arch=i386 ?do_encoding@?$codecvt@_WDH@std@@MBEHXZ +@ stub -arch=win64 ?do_encoding@?$codecvt@_WDH@std@@MEBAHXZ +@ cdecl -arch=arm ?do_encoding@codecvt_base@std@@MBAHXZ(ptr) codecvt_base_do_encoding +@ thiscall -arch=i386 ?do_encoding@codecvt_base@std@@MBEHXZ(ptr) codecvt_base_do_encoding +@ cdecl -arch=win64 ?do_encoding@codecvt_base@std@@MEBAHXZ(ptr) codecvt_base_do_encoding +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_ushort +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_ushort +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_ushort +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_uint +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_uint +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_uint +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_long +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_long +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_long +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_ulong +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_ulong +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_ulong +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_float +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_float +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_float +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_double +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_double +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_double +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_double +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_double +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_double +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_void +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_void +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_void +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_int64 +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_int64 +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_int64 +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_uint64 +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_uint64 +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_uint64 +@ cdecl -arch=arm ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_bool +@ thiscall -arch=i386 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_do_get_bool +@ cdecl -arch=win64 ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_do_get_bool +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_ushort +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_ushort +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_ushort +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_uint +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_uint +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_uint +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_long +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_long +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_long +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_ulong +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_ulong +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_ulong +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_float +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_float +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_float +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_double +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_double +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_double +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_double +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_double +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_double +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_void +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_void +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_void +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_int64 +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_int64 +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_int64 +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_uint64 +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_uint64 +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_uint64 +@ cdecl -arch=arm ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_bool +@ thiscall -arch=i386 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_short_do_get_bool +@ cdecl -arch=win64 ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_short_do_get_bool +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_ushort +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_ushort +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_ushort +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_uint +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_uint +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_uint +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_long +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_long +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_long +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_ulong +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_ulong +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_ulong +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_float +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_float +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_float +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_double +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_double +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_double +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_double +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_double +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_double +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_void +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_void +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_void +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_int64 +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_int64 +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_int64 +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_uint64 +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_uint64 +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_uint64 +@ cdecl -arch=arm ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_bool +@ thiscall -arch=i386 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_do_get_bool +@ cdecl -arch=win64 ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_do_get_bool +@ stub -arch=arm ?do_get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=i386 ?do_get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=win64 ?do_get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@DD@Z +@ stub -arch=arm ?do_get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=i386 ?do_get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=win64 ?do_get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@DD@Z +@ stub -arch=arm ?do_get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=i386 ?do_get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=win64 ?do_get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@DD@Z +@ stub -arch=arm ?do_get_date@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_date@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_date@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_date@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_date@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_date@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_date@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_date@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_date@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_monthname@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_monthname@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_monthname@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_monthname@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_monthname@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_monthname@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_monthname@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_monthname@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_monthname@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_time@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_time@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_time@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_time@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_time@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_time@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_time@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_time@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_time@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_weekday@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_weekday@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_weekday@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_weekday@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_weekday@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_weekday@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_weekday@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_weekday@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_weekday@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_year@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_year@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_year@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_year@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_year@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_year@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?do_get_year@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?do_get_year@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?do_get_year@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ cdecl -arch=arm ?do_in@?$codecvt@DDH@std@@MBAHAAHPBD1AAPBDPAD3AAPAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_do_in +@ thiscall -arch=i386 ?do_in@?$codecvt@DDH@std@@MBEHAAHPBD1AAPBDPAD3AAPAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_do_in +@ cdecl -arch=win64 ?do_in@?$codecvt@DDH@std@@MEBAHAEAHPEBD1AEAPEBDPEAD3AEAPEAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_do_in +@ cdecl -arch=arm ?do_in@?$codecvt@GDH@std@@MBAHAAHPBD1AAPBDPAG3AAPAG@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_do_in +@ thiscall -arch=i386 ?do_in@?$codecvt@GDH@std@@MBEHAAHPBD1AAPBDPAG3AAPAG@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_do_in +@ cdecl -arch=win64 ?do_in@?$codecvt@GDH@std@@MEBAHAEAHPEBD1AEAPEBDPEAG3AEAPEAG@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_do_in +@ cdecl -arch=arm ?do_in@?$codecvt@_WDH@std@@MBAHAAHPBD1AAPBDPA_W3AAPA_W@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_do_in +@ thiscall -arch=i386 ?do_in@?$codecvt@_WDH@std@@MBEHAAHPBD1AAPBDPA_W3AAPA_W@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_do_in +@ cdecl -arch=win64 ?do_in@?$codecvt@_WDH@std@@MEBAHAEAHPEBD1AEAPEBDPEA_W3AEAPEA_W@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_do_in +@ cdecl -arch=arm ?do_is@?$ctype@G@std@@MBAPBGPBG0PAF@Z(ptr ptr ptr ptr) ctype_wchar_do_is +@ thiscall -arch=i386 ?do_is@?$ctype@G@std@@MBEPBGPBG0PAF@Z(ptr ptr ptr ptr) ctype_wchar_do_is +@ cdecl -arch=win64 ?do_is@?$ctype@G@std@@MEBAPEBGPEBG0PEAF@Z(ptr ptr ptr ptr) ctype_wchar_do_is +@ cdecl -arch=arm ?do_is@?$ctype@G@std@@MBA_NFG@Z(ptr long long) ctype_wchar_do_is_ch +@ thiscall -arch=i386 ?do_is@?$ctype@G@std@@MBE_NFG@Z(ptr long long) ctype_wchar_do_is_ch +@ cdecl -arch=win64 ?do_is@?$ctype@G@std@@MEBA_NFG@Z(ptr long long) ctype_wchar_do_is_ch +@ cdecl -arch=arm ?do_is@?$ctype@_W@std@@MBAPB_WPB_W0PAF@Z(ptr ptr ptr ptr) ctype_wchar_do_is +@ thiscall -arch=i386 ?do_is@?$ctype@_W@std@@MBEPB_WPB_W0PAF@Z(ptr ptr ptr ptr) ctype_wchar_do_is +@ cdecl -arch=win64 ?do_is@?$ctype@_W@std@@MEBAPEB_WPEB_W0PEAF@Z(ptr ptr ptr ptr) ctype_wchar_do_is +@ cdecl -arch=arm ?do_is@?$ctype@_W@std@@MBA_NF_W@Z(ptr long long) ctype_wchar_do_is_ch +@ thiscall -arch=i386 ?do_is@?$ctype@_W@std@@MBE_NF_W@Z(ptr long long) ctype_wchar_do_is_ch +@ cdecl -arch=win64 ?do_is@?$ctype@_W@std@@MEBA_NF_W@Z(ptr long long) ctype_wchar_do_is_ch +@ cdecl -arch=arm ?do_length@?$codecvt@DDH@std@@MBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_do_length +@ thiscall -arch=i386 ?do_length@?$codecvt@DDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@DDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_char_do_length +@ cdecl -arch=arm ?do_length@?$codecvt@GDH@std@@MBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ thiscall -arch=i386 ?do_length@?$codecvt@GDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@GDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_do_length +@ cdecl -arch=arm ?do_length@?$codecvt@_WDH@std@@MBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ thiscall -arch=i386 ?do_length@?$codecvt@_WDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@_WDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_do_length +@ cdecl -arch=arm ?do_max_length@?$codecvt@GDH@std@@MBAHXZ(ptr) codecvt_wchar_do_max_length +@ thiscall -arch=i386 ?do_max_length@?$codecvt@GDH@std@@MBEHXZ(ptr) codecvt_wchar_do_max_length +@ cdecl -arch=win64 ?do_max_length@?$codecvt@GDH@std@@MEBAHXZ(ptr) codecvt_wchar_do_max_length +@ cdecl -arch=arm ?do_max_length@?$codecvt@_WDH@std@@MBAHXZ(ptr) codecvt_wchar_do_max_length +@ thiscall -arch=i386 ?do_max_length@?$codecvt@_WDH@std@@MBEHXZ(ptr) codecvt_wchar_do_max_length +@ cdecl -arch=win64 ?do_max_length@?$codecvt@_WDH@std@@MEBAHXZ(ptr) codecvt_wchar_do_max_length +@ cdecl -arch=arm ?do_max_length@codecvt_base@std@@MBAHXZ(ptr) codecvt_base_do_max_length +@ thiscall -arch=i386 ?do_max_length@codecvt_base@std@@MBEHXZ(ptr) codecvt_base_do_max_length +@ cdecl -arch=win64 ?do_max_length@codecvt_base@std@@MEBAHXZ(ptr) codecvt_base_do_max_length +@ cdecl -arch=arm ?do_narrow@?$ctype@D@std@@MBADDD@Z(ptr long long) ctype_char_do_narrow_ch +@ thiscall -arch=i386 ?do_narrow@?$ctype@D@std@@MBEDDD@Z(ptr long long) ctype_char_do_narrow_ch +@ cdecl -arch=win64 ?do_narrow@?$ctype@D@std@@MEBADDD@Z(ptr long long) ctype_char_do_narrow_ch +@ cdecl -arch=arm ?do_narrow@?$ctype@D@std@@MBAPBDPBD0DPAD@Z(ptr ptr ptr long ptr) ctype_char_do_narrow +@ thiscall -arch=i386 ?do_narrow@?$ctype@D@std@@MBEPBDPBD0DPAD@Z(ptr ptr ptr long ptr) ctype_char_do_narrow +@ cdecl -arch=win64 ?do_narrow@?$ctype@D@std@@MEBAPEBDPEBD0DPEAD@Z(ptr ptr ptr long ptr) ctype_char_do_narrow +@ cdecl -arch=arm ?do_narrow@?$ctype@G@std@@MBADGD@Z(ptr long long) ctype_wchar_do_narrow_ch +@ thiscall -arch=i386 ?do_narrow@?$ctype@G@std@@MBEDGD@Z(ptr long long) ctype_wchar_do_narrow_ch +@ cdecl -arch=win64 ?do_narrow@?$ctype@G@std@@MEBADGD@Z(ptr long long) ctype_wchar_do_narrow_ch +@ cdecl -arch=arm ?do_narrow@?$ctype@G@std@@MBAPBGPBG0DPAD@Z(ptr ptr ptr long ptr) ctype_wchar_do_narrow +@ thiscall -arch=i386 ?do_narrow@?$ctype@G@std@@MBEPBGPBG0DPAD@Z(ptr ptr ptr long ptr) ctype_wchar_do_narrow +@ cdecl -arch=win64 ?do_narrow@?$ctype@G@std@@MEBAPEBGPEBG0DPEAD@Z(ptr ptr ptr long ptr) ctype_wchar_do_narrow +@ cdecl -arch=arm ?do_narrow@?$ctype@_W@std@@MBAD_WD@Z(ptr long long) ctype_wchar_do_narrow_ch +@ thiscall -arch=i386 ?do_narrow@?$ctype@_W@std@@MBED_WD@Z(ptr long long) ctype_wchar_do_narrow_ch +@ cdecl -arch=win64 ?do_narrow@?$ctype@_W@std@@MEBAD_WD@Z(ptr long long) ctype_wchar_do_narrow_ch +@ cdecl -arch=arm ?do_narrow@?$ctype@_W@std@@MBAPB_WPB_W0DPAD@Z(ptr ptr ptr long ptr) ctype_wchar_do_narrow +@ thiscall -arch=i386 ?do_narrow@?$ctype@_W@std@@MBEPB_WPB_W0DPAD@Z(ptr ptr ptr long ptr) ctype_wchar_do_narrow +@ cdecl -arch=win64 ?do_narrow@?$ctype@_W@std@@MEBAPEB_WPEB_W0DPEAD@Z(ptr ptr ptr long ptr) ctype_wchar_do_narrow +@ cdecl -arch=arm ?do_out@?$codecvt@DDH@std@@MBAHAAHPBD1AAPBDPAD3AAPAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_do_out +@ thiscall -arch=i386 ?do_out@?$codecvt@DDH@std@@MBEHAAHPBD1AAPBDPAD3AAPAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_do_out +@ cdecl -arch=win64 ?do_out@?$codecvt@DDH@std@@MEBAHAEAHPEBD1AEAPEBDPEAD3AEAPEAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_do_out +@ cdecl -arch=arm ?do_out@?$codecvt@GDH@std@@MBAHAAHPBG1AAPBGPAD3AAPAD@Z(ptr ptr ptr ptr ptr ptr ptr ptr) codecvt_wchar_do_out +@ thiscall -arch=i386 ?do_out@?$codecvt@GDH@std@@MBEHAAHPBG1AAPBGPAD3AAPAD@Z(ptr ptr ptr ptr ptr ptr ptr ptr) codecvt_wchar_do_out +@ cdecl -arch=win64 ?do_out@?$codecvt@GDH@std@@MEBAHAEAHPEBG1AEAPEBGPEAD3AEAPEAD@Z(ptr ptr ptr ptr ptr ptr ptr ptr) codecvt_wchar_do_out +@ cdecl -arch=arm ?do_out@?$codecvt@_WDH@std@@MBAHAAHPB_W1AAPB_WPAD3AAPAD@Z(ptr ptr wstr wstr ptr ptr ptr ptr) codecvt_wchar_do_out +@ thiscall -arch=i386 ?do_out@?$codecvt@_WDH@std@@MBEHAAHPB_W1AAPB_WPAD3AAPAD@Z(ptr ptr wstr wstr ptr ptr ptr ptr) codecvt_wchar_do_out +@ cdecl -arch=win64 ?do_out@?$codecvt@_WDH@std@@MEBAHAEAHPEB_W1AEAPEB_WPEAD3AEAPEAD@Z(ptr ptr wstr wstr ptr ptr ptr ptr) codecvt_wchar_do_out +@ cdecl -arch=arm ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DJ@Z(ptr ptr long ptr ptr long long) num_put_char_do_put_long +@ thiscall -arch=i386 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DJ@Z(ptr ptr long ptr ptr long long) num_put_char_do_put_long +@ cdecl -arch=win64 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DJ@Z(ptr ptr ptr ptr long long) num_put_char_do_put_long +@ cdecl -arch=arm ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DK@Z(ptr ptr long ptr ptr long long) num_put_char_do_put_ulong +@ thiscall -arch=i386 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DK@Z(ptr ptr long ptr ptr long long) num_put_char_do_put_ulong +@ cdecl -arch=win64 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DK@Z(ptr ptr ptr ptr long long) num_put_char_do_put_ulong +@ cdecl -arch=arm ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DN@Z(ptr ptr long ptr ptr long double) num_put_char_do_put_double +@ thiscall -arch=i386 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DN@Z(ptr ptr long ptr ptr long double) num_put_char_do_put_double +@ cdecl -arch=win64 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DN@Z(ptr ptr ptr ptr long double) num_put_char_do_put_double +@ cdecl -arch=arm ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DO@Z(ptr ptr long ptr ptr long double) num_put_char_do_put_double +@ thiscall -arch=i386 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DO@Z(ptr ptr long ptr ptr long double) num_put_char_do_put_double +@ cdecl -arch=win64 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DO@Z(ptr ptr ptr ptr long double) num_put_char_do_put_double +@ cdecl -arch=arm ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBX@Z(ptr ptr long ptr ptr long ptr) num_put_char_do_put_ptr +@ thiscall -arch=i386 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBX@Z(ptr ptr long ptr ptr long ptr) num_put_char_do_put_ptr +@ cdecl -arch=win64 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DPEBX@Z(ptr ptr ptr ptr long ptr) num_put_char_do_put_ptr +@ cdecl -arch=arm ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_J@Z(ptr ptr long ptr ptr long int64) num_put_char_do_put_int64 +@ thiscall -arch=i386 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_J@Z(ptr ptr long ptr ptr long int64) num_put_char_do_put_int64 +@ cdecl -arch=win64 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@D_J@Z(ptr ptr ptr ptr long int64) num_put_char_do_put_int64 +@ cdecl -arch=arm ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_K@Z(ptr ptr long ptr ptr long int64) num_put_char_do_put_uint64 +@ thiscall -arch=i386 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_K@Z(ptr ptr long ptr ptr long int64) num_put_char_do_put_uint64 +@ cdecl -arch=win64 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@D_K@Z(ptr ptr ptr ptr long int64) num_put_char_do_put_uint64 +@ cdecl -arch=arm ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_N@Z(ptr ptr long ptr ptr long long) num_put_char_do_put_bool +@ thiscall -arch=i386 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_N@Z(ptr ptr long ptr ptr long long) num_put_char_do_put_bool +@ cdecl -arch=win64 ?do_put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@D_N@Z(ptr ptr ptr ptr long long) num_put_char_do_put_bool +@ cdecl -arch=arm ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GJ@Z(ptr ptr long ptr ptr long long) num_put_short_do_put_long +@ thiscall -arch=i386 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GJ@Z(ptr ptr long ptr ptr long long) num_put_short_do_put_long +@ cdecl -arch=win64 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GJ@Z(ptr ptr ptr ptr long long) num_put_short_do_put_long +@ cdecl -arch=arm ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GK@Z(ptr ptr long ptr ptr long long) num_put_short_do_put_ulong +@ thiscall -arch=i386 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GK@Z(ptr ptr long ptr ptr long long) num_put_short_do_put_ulong +@ cdecl -arch=win64 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GK@Z(ptr ptr ptr ptr long long) num_put_short_do_put_ulong +@ cdecl -arch=arm ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GN@Z(ptr ptr long ptr ptr long double) num_put_short_do_put_double +@ thiscall -arch=i386 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GN@Z(ptr ptr long ptr ptr long double) num_put_short_do_put_double +@ cdecl -arch=win64 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GN@Z(ptr ptr ptr ptr long double) num_put_short_do_put_double +@ cdecl -arch=arm ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GO@Z(ptr ptr long ptr ptr long double) num_put_short_do_put_double +@ thiscall -arch=i386 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GO@Z(ptr ptr long ptr ptr long double) num_put_short_do_put_double +@ cdecl -arch=win64 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GO@Z(ptr ptr ptr ptr long double) num_put_short_do_put_double +@ cdecl -arch=arm ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBX@Z(ptr ptr long ptr ptr long ptr) num_put_short_do_put_ptr +@ thiscall -arch=i386 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBX@Z(ptr ptr long ptr ptr long ptr) num_put_short_do_put_ptr +@ cdecl -arch=win64 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GPEBX@Z(ptr ptr ptr ptr long ptr) num_put_short_do_put_ptr +@ cdecl -arch=arm ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_J@Z(ptr ptr long ptr ptr long int64) num_put_short_do_put_int64 +@ thiscall -arch=i386 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_J@Z(ptr ptr long ptr ptr long int64) num_put_short_do_put_int64 +@ cdecl -arch=win64 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@G_J@Z(ptr ptr ptr ptr long int64) num_put_short_do_put_int64 +@ cdecl -arch=arm ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_K@Z(ptr ptr long ptr ptr long int64) num_put_short_do_put_uint64 +@ thiscall -arch=i386 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_K@Z(ptr ptr long ptr ptr long int64) num_put_short_do_put_uint64 +@ cdecl -arch=win64 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@G_K@Z(ptr ptr ptr ptr long int64) num_put_short_do_put_uint64 +@ cdecl -arch=arm ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_N@Z(ptr ptr long ptr ptr long long) num_put_short_do_put_bool +@ thiscall -arch=i386 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_N@Z(ptr ptr long ptr ptr long long) num_put_short_do_put_bool +@ cdecl -arch=win64 ?do_put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@G_N@Z(ptr ptr ptr ptr long long) num_put_short_do_put_bool +@ cdecl -arch=arm ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WJ@Z(ptr ptr long ptr ptr long long) num_put_wchar_do_put_long +@ thiscall -arch=i386 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WJ@Z(ptr ptr long ptr ptr long long) num_put_wchar_do_put_long +@ cdecl -arch=win64 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WJ@Z(ptr ptr ptr ptr long long) num_put_wchar_do_put_long +@ cdecl -arch=arm ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WK@Z(ptr ptr long ptr ptr long long) num_put_wchar_do_put_ulong +@ thiscall -arch=i386 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WK@Z(ptr ptr long ptr ptr long long) num_put_wchar_do_put_ulong +@ cdecl -arch=win64 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WK@Z(ptr ptr ptr ptr long long) num_put_wchar_do_put_ulong +@ cdecl -arch=arm ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WN@Z(ptr ptr long ptr ptr long double) num_put_wchar_do_put_double +@ thiscall -arch=i386 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WN@Z(ptr ptr long ptr ptr long double) num_put_wchar_do_put_double +@ cdecl -arch=win64 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WN@Z(ptr ptr ptr ptr long double) num_put_wchar_do_put_double +@ cdecl -arch=arm ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WO@Z(ptr ptr long ptr ptr long double) num_put_wchar_do_put_double +@ thiscall -arch=i386 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WO@Z(ptr ptr long ptr ptr long double) num_put_wchar_do_put_double +@ cdecl -arch=win64 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WO@Z(ptr ptr ptr ptr long double) num_put_wchar_do_put_double +@ cdecl -arch=arm ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBX@Z(ptr ptr long ptr ptr long ptr) num_put_wchar_do_put_ptr +@ thiscall -arch=i386 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBX@Z(ptr ptr long ptr ptr long ptr) num_put_wchar_do_put_ptr +@ cdecl -arch=win64 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WPEBX@Z(ptr ptr ptr ptr long ptr) num_put_wchar_do_put_ptr +@ cdecl -arch=arm ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_J@Z(ptr ptr long ptr ptr long int64) num_put_wchar_do_put_int64 +@ thiscall -arch=i386 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_J@Z(ptr ptr long ptr ptr long int64) num_put_wchar_do_put_int64 +@ cdecl -arch=win64 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_W_J@Z(ptr ptr ptr ptr long int64) num_put_wchar_do_put_int64 +@ cdecl -arch=arm ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_K@Z(ptr ptr long ptr ptr long int64) num_put_wchar_do_put_uint64 +@ thiscall -arch=i386 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_K@Z(ptr ptr long ptr ptr long int64) num_put_wchar_do_put_uint64 +@ cdecl -arch=win64 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_W_K@Z(ptr ptr ptr ptr long int64) num_put_wchar_do_put_uint64 +@ cdecl -arch=arm ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_N@Z(ptr ptr long ptr ptr long long) num_put_wchar_do_put_bool +@ thiscall -arch=i386 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_N@Z(ptr ptr long ptr ptr long long) num_put_wchar_do_put_bool +@ cdecl -arch=win64 ?do_put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_W_N@Z(ptr ptr ptr ptr long long) num_put_wchar_do_put_bool +@ cdecl -arch=arm ?do_put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_char_do_put +@ thiscall -arch=i386 ?do_put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_char_do_put +@ cdecl -arch=win64 ?do_put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DPEBUtm@@DD@Z(ptr ptr ptr ptr long ptr long long) time_put_char_do_put +@ cdecl -arch=arm ?do_put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_wchar_do_put +@ thiscall -arch=i386 ?do_put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_wchar_do_put +@ cdecl -arch=win64 ?do_put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GPEBUtm@@DD@Z(ptr ptr ptr ptr long ptr long long) time_put_wchar_do_put +@ cdecl -arch=arm ?do_put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_wchar_do_put +@ thiscall -arch=i386 ?do_put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_wchar_do_put +@ cdecl -arch=win64 ?do_put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WPEBUtm@@DD@Z(ptr ptr ptr ptr long ptr long long) time_put_wchar_do_put +@ cdecl -arch=arm ?do_scan_is@?$ctype@G@std@@MBAPBGFPBG0@Z(ptr long ptr ptr) ctype_wchar_do_scan_is +@ thiscall -arch=i386 ?do_scan_is@?$ctype@G@std@@MBEPBGFPBG0@Z(ptr long ptr ptr) ctype_wchar_do_scan_is +@ cdecl -arch=win64 ?do_scan_is@?$ctype@G@std@@MEBAPEBGFPEBG0@Z(ptr long ptr ptr) ctype_wchar_do_scan_is +@ cdecl -arch=arm ?do_scan_is@?$ctype@_W@std@@MBAPB_WFPB_W0@Z(ptr long ptr ptr) ctype_wchar_do_scan_is +@ thiscall -arch=i386 ?do_scan_is@?$ctype@_W@std@@MBEPB_WFPB_W0@Z(ptr long ptr ptr) ctype_wchar_do_scan_is +@ cdecl -arch=win64 ?do_scan_is@?$ctype@_W@std@@MEBAPEB_WFPEB_W0@Z(ptr long ptr ptr) ctype_wchar_do_scan_is +@ cdecl -arch=arm ?do_scan_not@?$ctype@G@std@@MBAPBGFPBG0@Z(ptr long ptr ptr) ctype_wchar_do_scan_not +@ thiscall -arch=i386 ?do_scan_not@?$ctype@G@std@@MBEPBGFPBG0@Z(ptr long ptr ptr) ctype_wchar_do_scan_not +@ cdecl -arch=win64 ?do_scan_not@?$ctype@G@std@@MEBAPEBGFPEBG0@Z(ptr long ptr ptr) ctype_wchar_do_scan_not +@ cdecl -arch=arm ?do_scan_not@?$ctype@_W@std@@MBAPB_WFPB_W0@Z(ptr long ptr ptr) ctype_wchar_do_scan_not +@ thiscall -arch=i386 ?do_scan_not@?$ctype@_W@std@@MBEPB_WFPB_W0@Z(ptr long ptr ptr) ctype_wchar_do_scan_not +@ cdecl -arch=win64 ?do_scan_not@?$ctype@_W@std@@MEBAPEB_WFPEB_W0@Z(ptr long ptr ptr) ctype_wchar_do_scan_not +@ cdecl -arch=arm ?do_tolower@?$ctype@D@std@@MBADD@Z(ptr long) ctype_char_do_tolower_ch +@ thiscall -arch=i386 ?do_tolower@?$ctype@D@std@@MBEDD@Z(ptr long) ctype_char_do_tolower_ch +@ cdecl -arch=win64 ?do_tolower@?$ctype@D@std@@MEBADD@Z(ptr long) ctype_char_do_tolower_ch +@ cdecl -arch=arm ?do_tolower@?$ctype@D@std@@MBAPBDPADPBD@Z(ptr ptr ptr) ctype_char_do_tolower +@ thiscall -arch=i386 ?do_tolower@?$ctype@D@std@@MBEPBDPADPBD@Z(ptr ptr ptr) ctype_char_do_tolower +@ cdecl -arch=win64 ?do_tolower@?$ctype@D@std@@MEBAPEBDPEADPEBD@Z(ptr ptr ptr) ctype_char_do_tolower +@ cdecl -arch=arm ?do_tolower@?$ctype@G@std@@MBAGG@Z(ptr long) ctype_wchar_do_tolower_ch +@ thiscall -arch=i386 ?do_tolower@?$ctype@G@std@@MBEGG@Z(ptr long) ctype_wchar_do_tolower_ch +@ cdecl -arch=win64 ?do_tolower@?$ctype@G@std@@MEBAGG@Z(ptr long) ctype_wchar_do_tolower_ch +@ cdecl -arch=arm ?do_tolower@?$ctype@G@std@@MBAPBGPAGPBG@Z(ptr ptr ptr) ctype_wchar_do_tolower +@ thiscall -arch=i386 ?do_tolower@?$ctype@G@std@@MBEPBGPAGPBG@Z(ptr ptr ptr) ctype_wchar_do_tolower +@ cdecl -arch=win64 ?do_tolower@?$ctype@G@std@@MEBAPEBGPEAGPEBG@Z(ptr ptr ptr) ctype_wchar_do_tolower +@ cdecl -arch=arm ?do_tolower@?$ctype@_W@std@@MBAPB_WPA_WPB_W@Z(ptr ptr ptr) ctype_wchar_do_tolower +@ thiscall -arch=i386 ?do_tolower@?$ctype@_W@std@@MBEPB_WPA_WPB_W@Z(ptr ptr ptr) ctype_wchar_do_tolower +@ cdecl -arch=win64 ?do_tolower@?$ctype@_W@std@@MEBAPEB_WPEA_WPEB_W@Z(ptr ptr ptr) ctype_wchar_do_tolower +@ cdecl -arch=arm ?do_tolower@?$ctype@_W@std@@MBA_W_W@Z(ptr long) ctype_wchar_do_tolower_ch +@ thiscall -arch=i386 ?do_tolower@?$ctype@_W@std@@MBE_W_W@Z(ptr long) ctype_wchar_do_tolower_ch +@ cdecl -arch=win64 ?do_tolower@?$ctype@_W@std@@MEBA_W_W@Z(ptr long) ctype_wchar_do_tolower_ch +@ cdecl -arch=arm ?do_toupper@?$ctype@D@std@@MBADD@Z(ptr long) ctype_char_do_toupper_ch +@ thiscall -arch=i386 ?do_toupper@?$ctype@D@std@@MBEDD@Z(ptr long) ctype_char_do_toupper_ch +@ cdecl -arch=win64 ?do_toupper@?$ctype@D@std@@MEBADD@Z(ptr long) ctype_char_do_toupper_ch +@ cdecl -arch=arm ?do_toupper@?$ctype@D@std@@MBAPBDPADPBD@Z(ptr ptr ptr) ctype_char_do_toupper +@ thiscall -arch=i386 ?do_toupper@?$ctype@D@std@@MBEPBDPADPBD@Z(ptr ptr ptr) ctype_char_do_toupper +@ cdecl -arch=win64 ?do_toupper@?$ctype@D@std@@MEBAPEBDPEADPEBD@Z(ptr ptr ptr) ctype_char_do_toupper +@ cdecl -arch=arm ?do_toupper@?$ctype@G@std@@MBAGG@Z(ptr long) ctype_wchar_do_toupper_ch +@ thiscall -arch=i386 ?do_toupper@?$ctype@G@std@@MBEGG@Z(ptr long) ctype_wchar_do_toupper_ch +@ cdecl -arch=win64 ?do_toupper@?$ctype@G@std@@MEBAGG@Z(ptr long) ctype_wchar_do_toupper_ch +@ cdecl -arch=arm ?do_toupper@?$ctype@G@std@@MBAPBGPAGPBG@Z(ptr ptr ptr) ctype_wchar_do_toupper +@ thiscall -arch=i386 ?do_toupper@?$ctype@G@std@@MBEPBGPAGPBG@Z(ptr ptr ptr) ctype_wchar_do_toupper +@ cdecl -arch=win64 ?do_toupper@?$ctype@G@std@@MEBAPEBGPEAGPEBG@Z(ptr ptr ptr) ctype_wchar_do_toupper +@ cdecl -arch=arm ?do_toupper@?$ctype@_W@std@@MBAPB_WPA_WPB_W@Z(ptr ptr ptr) ctype_wchar_do_toupper +@ thiscall -arch=i386 ?do_toupper@?$ctype@_W@std@@MBEPB_WPA_WPB_W@Z(ptr ptr ptr) ctype_wchar_do_toupper +@ cdecl -arch=win64 ?do_toupper@?$ctype@_W@std@@MEBAPEB_WPEA_WPEB_W@Z(ptr ptr ptr) ctype_wchar_do_toupper +@ cdecl -arch=arm ?do_toupper@?$ctype@_W@std@@MBA_W_W@Z(ptr long) ctype_wchar_do_toupper_ch +@ thiscall -arch=i386 ?do_toupper@?$ctype@_W@std@@MBE_W_W@Z(ptr long) ctype_wchar_do_toupper_ch +@ cdecl -arch=win64 ?do_toupper@?$ctype@_W@std@@MEBA_W_W@Z(ptr long) ctype_wchar_do_toupper_ch +@ cdecl -arch=arm ?do_unshift@?$codecvt@DDH@std@@MBAHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_char_do_unshift +@ thiscall -arch=i386 ?do_unshift@?$codecvt@DDH@std@@MBEHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_char_do_unshift +@ cdecl -arch=win64 ?do_unshift@?$codecvt@DDH@std@@MEBAHAEAHPEAD1AEAPEAD@Z(ptr ptr ptr ptr ptr) codecvt_char_do_unshift +@ cdecl -arch=arm ?do_unshift@?$codecvt@GDH@std@@MBAHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_do_unshift +@ thiscall -arch=i386 ?do_unshift@?$codecvt@GDH@std@@MBEHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_do_unshift +@ cdecl -arch=win64 ?do_unshift@?$codecvt@GDH@std@@MEBAHAEAHPEAD1AEAPEAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_do_unshift +@ cdecl -arch=arm ?do_unshift@?$codecvt@_WDH@std@@MBAHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_do_unshift +@ thiscall -arch=i386 ?do_unshift@?$codecvt@_WDH@std@@MBEHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_do_unshift +@ cdecl -arch=win64 ?do_unshift@?$codecvt@_WDH@std@@MEBAHAEAHPEAD1AEAPEAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_do_unshift +@ cdecl -arch=arm ?do_widen@?$ctype@D@std@@MBADD@Z(ptr long) ctype_char_do_widen_ch +@ thiscall -arch=i386 ?do_widen@?$ctype@D@std@@MBEDD@Z(ptr long) ctype_char_do_widen_ch +@ cdecl -arch=win64 ?do_widen@?$ctype@D@std@@MEBADD@Z(ptr long) ctype_char_do_widen_ch +@ cdecl -arch=arm ?do_widen@?$ctype@D@std@@MBAPBDPBD0PAD@Z(ptr ptr ptr ptr) ctype_char_do_widen +@ thiscall -arch=i386 ?do_widen@?$ctype@D@std@@MBEPBDPBD0PAD@Z(ptr ptr ptr ptr) ctype_char_do_widen +@ cdecl -arch=win64 ?do_widen@?$ctype@D@std@@MEBAPEBDPEBD0PEAD@Z(ptr ptr ptr ptr) ctype_char_do_widen +@ cdecl -arch=arm ?do_widen@?$ctype@G@std@@MBAGD@Z(ptr long) ctype_wchar_do_widen_ch +@ thiscall -arch=i386 ?do_widen@?$ctype@G@std@@MBEGD@Z(ptr long) ctype_wchar_do_widen_ch +@ cdecl -arch=win64 ?do_widen@?$ctype@G@std@@MEBAGD@Z(ptr long) ctype_wchar_do_widen_ch +@ cdecl -arch=arm ?do_widen@?$ctype@G@std@@MBAPBDPBD0PAG@Z(ptr ptr ptr ptr) ctype_wchar_do_widen +@ thiscall -arch=i386 ?do_widen@?$ctype@G@std@@MBEPBDPBD0PAG@Z(ptr ptr ptr ptr) ctype_wchar_do_widen +@ cdecl -arch=win64 ?do_widen@?$ctype@G@std@@MEBAPEBDPEBD0PEAG@Z(ptr ptr ptr ptr) ctype_wchar_do_widen +@ cdecl -arch=arm ?do_widen@?$ctype@_W@std@@MBAPBDPBD0PA_W@Z(ptr ptr ptr ptr) ctype_wchar_do_widen +@ thiscall -arch=i386 ?do_widen@?$ctype@_W@std@@MBEPBDPBD0PA_W@Z(ptr ptr ptr ptr) ctype_wchar_do_widen +@ cdecl -arch=win64 ?do_widen@?$ctype@_W@std@@MEBAPEBDPEBD0PEA_W@Z(ptr ptr ptr ptr) ctype_wchar_do_widen +@ cdecl -arch=arm ?do_widen@?$ctype@_W@std@@MBA_WD@Z(ptr long) ctype_wchar_do_widen_ch +@ thiscall -arch=i386 ?do_widen@?$ctype@_W@std@@MBE_WD@Z(ptr long) ctype_wchar_do_widen_ch +@ cdecl -arch=win64 ?do_widen@?$ctype@_W@std@@MEBA_WD@Z(ptr long) ctype_wchar_do_widen_ch +@ stub -arch=arm ?done@agent@Concurrency@@IAA_NXZ +@ stub -arch=i386 ?done@agent@Concurrency@@IAE_NXZ +@ stub -arch=win64 ?done@agent@Concurrency@@IEAA_NXZ +@ cdecl -arch=arm ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBAPADXZ(ptr) basic_streambuf_char_eback +@ thiscall -arch=i386 ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ(ptr) basic_streambuf_char_eback +@ cdecl -arch=win64 ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ(ptr) basic_streambuf_char_eback +@ cdecl -arch=arm ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBAPAGXZ(ptr) basic_streambuf_wchar_eback +@ thiscall -arch=i386 ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ(ptr) basic_streambuf_wchar_eback +@ cdecl -arch=win64 ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ(ptr) basic_streambuf_wchar_eback +@ cdecl -arch=arm ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBAPA_WXZ(ptr) basic_streambuf_wchar_eback +@ thiscall -arch=i386 ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ(ptr) basic_streambuf_wchar_eback +@ cdecl -arch=win64 ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ(ptr) basic_streambuf_wchar_eback +@ cdecl -arch=arm ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBAPADXZ(ptr) basic_streambuf_char_egptr +@ thiscall -arch=i386 ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ(ptr) basic_streambuf_char_egptr +@ cdecl -arch=win64 ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ(ptr) basic_streambuf_char_egptr +@ cdecl -arch=arm ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBAPAGXZ(ptr) basic_streambuf_wchar_egptr +@ thiscall -arch=i386 ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ(ptr) basic_streambuf_wchar_egptr +@ cdecl -arch=win64 ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ(ptr) basic_streambuf_wchar_egptr +@ cdecl -arch=arm ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBAPA_WXZ(ptr) basic_streambuf_wchar_egptr +@ thiscall -arch=i386 ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ(ptr) basic_streambuf_wchar_egptr +@ cdecl -arch=win64 ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ(ptr) basic_streambuf_wchar_egptr +@ cdecl -arch=arm ?empty@?$_Yarn@D@std@@QBA_NXZ(ptr) _Yarn_char_empty +@ thiscall -arch=i386 ?empty@?$_Yarn@D@std@@QBE_NXZ(ptr) _Yarn_char_empty +@ cdecl -arch=win64 ?empty@?$_Yarn@D@std@@QEBA_NXZ(ptr) _Yarn_char_empty +@ cdecl ?empty@locale@std@@SA?AV12@XZ(ptr) locale_empty +@ cdecl -arch=arm ?encoding@codecvt_base@std@@QBAHXZ(ptr) codecvt_base_encoding +@ thiscall -arch=i386 ?encoding@codecvt_base@std@@QBEHXZ(ptr) codecvt_base_encoding +@ cdecl -arch=win64 ?encoding@codecvt_base@std@@QEBAHXZ(ptr) codecvt_base_encoding +@ cdecl -arch=arm ?eof@ios_base@std@@QBA_NXZ(ptr) ios_base_eof +@ thiscall -arch=i386 ?eof@ios_base@std@@QBE_NXZ(ptr) ios_base_eof +@ cdecl -arch=win64 ?eof@ios_base@std@@QEBA_NXZ(ptr) ios_base_eof +@ cdecl -arch=arm ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBAPADXZ(ptr) basic_streambuf_char_epptr +@ thiscall -arch=i386 ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ(ptr) basic_streambuf_char_epptr +@ cdecl -arch=win64 ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ(ptr) basic_streambuf_char_epptr +@ cdecl -arch=arm ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBAPAGXZ(ptr) basic_streambuf_wchar_epptr +@ thiscall -arch=i386 ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ(ptr) basic_streambuf_wchar_epptr +@ cdecl -arch=win64 ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ(ptr) basic_streambuf_wchar_epptr +@ cdecl -arch=arm ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBAPA_WXZ(ptr) basic_streambuf_wchar_epptr +@ thiscall -arch=i386 ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ(ptr) basic_streambuf_wchar_epptr +@ cdecl -arch=win64 ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ(ptr) basic_streambuf_wchar_epptr +@ cdecl -arch=arm ?exceptions@ios_base@std@@QAAXH@Z(ptr long) ios_base_exceptions_set +@ thiscall -arch=i386 ?exceptions@ios_base@std@@QAEXH@Z(ptr long) ios_base_exceptions_set +@ cdecl -arch=win64 ?exceptions@ios_base@std@@QEAAXH@Z(ptr long) ios_base_exceptions_set +@ cdecl -arch=arm ?exceptions@ios_base@std@@QAAXI@Z(ptr long) ios_base_exceptions_set_unsigned +@ thiscall -arch=i386 ?exceptions@ios_base@std@@QAEXI@Z(ptr long) ios_base_exceptions_set_unsigned +@ cdecl -arch=win64 ?exceptions@ios_base@std@@QEAAXI@Z(ptr long) ios_base_exceptions_set_unsigned +@ cdecl -arch=arm ?exceptions@ios_base@std@@QBAHXZ(ptr) ios_base_exceptions_get +@ thiscall -arch=i386 ?exceptions@ios_base@std@@QBEHXZ(ptr) ios_base_exceptions_get +@ cdecl -arch=win64 ?exceptions@ios_base@std@@QEBAHXZ(ptr) ios_base_exceptions_get +@ cdecl -arch=arm ?fail@ios_base@std@@QBA_NXZ(ptr) ios_base_fail +@ thiscall -arch=i386 ?fail@ios_base@std@@QBE_NXZ(ptr) ios_base_fail +@ cdecl -arch=win64 ?fail@ios_base@std@@QEBA_NXZ(ptr) ios_base_fail +@ cdecl -arch=arm ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QAADD@Z(ptr long) basic_ios_char_fill_set +@ thiscall -arch=i386 ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEDD@Z(ptr long) basic_ios_char_fill_set +@ cdecl -arch=win64 ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAADD@Z(ptr long) basic_ios_char_fill_set +@ cdecl -arch=arm ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QBADXZ(ptr) basic_ios_char_fill_get +@ thiscall -arch=i386 ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDXZ(ptr) basic_ios_char_fill_get +@ cdecl -arch=win64 ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADXZ(ptr) basic_ios_char_fill_get +@ cdecl -arch=arm ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAGG@Z(ptr long) basic_ios_wchar_fill_set +@ thiscall -arch=i386 ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEGG@Z(ptr long) basic_ios_wchar_fill_set +@ cdecl -arch=win64 ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAGG@Z(ptr long) basic_ios_wchar_fill_set +@ cdecl -arch=arm ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QBAGXZ(ptr) basic_ios_wchar_fill_get +@ thiscall -arch=i386 ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEGXZ(ptr) basic_ios_wchar_fill_get +@ cdecl -arch=win64 ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAGXZ(ptr) basic_ios_wchar_fill_get +@ cdecl -arch=arm ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAA_W_W@Z(ptr long) basic_ios_wchar_fill_set +@ thiscall -arch=i386 ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE_W_W@Z(ptr long) basic_ios_wchar_fill_set +@ cdecl -arch=win64 ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA_W_W@Z(ptr long) basic_ios_wchar_fill_set +@ cdecl -arch=arm ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBA_WXZ(ptr) basic_ios_wchar_fill_get +@ thiscall -arch=i386 ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBE_WXZ(ptr) basic_ios_wchar_fill_get +@ cdecl -arch=win64 ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBA_WXZ(ptr) basic_ios_wchar_fill_get +@ cdecl -arch=arm ?flags@ios_base@std@@QAAHH@Z(ptr long) ios_base_flags_set +@ thiscall -arch=i386 ?flags@ios_base@std@@QAEHH@Z(ptr long) ios_base_flags_set +@ cdecl -arch=win64 ?flags@ios_base@std@@QEAAHH@Z(ptr long) ios_base_flags_set +@ cdecl -arch=arm ?flags@ios_base@std@@QBAHXZ(ptr) ios_base_flags_get +@ thiscall -arch=i386 ?flags@ios_base@std@@QBEHXZ(ptr) ios_base_flags_get +@ cdecl -arch=win64 ?flags@ios_base@std@@QEBAHXZ(ptr) ios_base_flags_get +@ cdecl -arch=arm ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV12@XZ(ptr) basic_ostream_char_flush +@ thiscall -arch=i386 ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@XZ(ptr) basic_ostream_char_flush +@ cdecl -arch=win64 ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@XZ(ptr) basic_ostream_char_flush +@ cdecl -arch=arm ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV12@XZ(ptr) basic_ostream_wchar_flush +@ thiscall -arch=i386 ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@XZ(ptr) basic_ostream_wchar_flush +@ cdecl -arch=win64 ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@XZ(ptr) basic_ostream_wchar_flush +@ cdecl -arch=arm ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@XZ(ptr) basic_ostream_wchar_flush +@ thiscall -arch=i386 ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@XZ(ptr) basic_ostream_wchar_flush +@ cdecl -arch=win64 ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@XZ(ptr) basic_ostream_wchar_flush +@ cdecl -arch=arm ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAXH@Z(ptr long) basic_streambuf_char_gbump +@ thiscall -arch=i386 ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXH@Z(ptr long) basic_streambuf_char_gbump +@ cdecl -arch=win64 ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXH@Z(ptr long) basic_streambuf_char_gbump +@ cdecl -arch=arm ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAXH@Z(ptr long) basic_streambuf_wchar_gbump +@ thiscall -arch=i386 ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXH@Z(ptr long) basic_streambuf_wchar_gbump +@ cdecl -arch=win64 ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXH@Z(ptr long) basic_streambuf_wchar_gbump +@ cdecl -arch=arm ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAXH@Z(ptr long) basic_streambuf_wchar_gbump +@ thiscall -arch=i386 ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXH@Z(ptr long) basic_streambuf_wchar_gbump +@ cdecl -arch=win64 ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXH@Z(ptr long) basic_streambuf_wchar_gbump +@ cdecl -ret64 -arch=arm ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBA_JXZ(ptr) basic_istream_char_gcount +@ thiscall -ret64 -arch=i386 ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBE_JXZ(ptr) basic_istream_char_gcount +@ cdecl -arch=win64 ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QEBA_JXZ(ptr) basic_istream_char_gcount +@ cdecl -ret64 -arch=arm ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBA_JXZ(ptr) basic_istream_wchar_gcount +@ thiscall -ret64 -arch=i386 ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBE_JXZ(ptr) basic_istream_wchar_gcount +@ cdecl -arch=win64 ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QEBA_JXZ(ptr) basic_istream_wchar_gcount +@ cdecl -ret64 -arch=arm ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBA_JXZ(ptr) basic_istream_wchar_gcount +@ thiscall -ret64 -arch=i386 ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBE_JXZ(ptr) basic_istream_wchar_gcount +@ cdecl -arch=win64 ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEBA_JXZ(ptr) basic_istream_wchar_gcount +@ cdecl -arch=arm ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@AAD@Z(ptr ptr) basic_istream_char_get_ch +@ thiscall -arch=i386 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAD@Z(ptr ptr) basic_istream_char_get_ch +@ cdecl -arch=win64 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAD@Z(ptr ptr) basic_istream_char_get_ch +@ cdecl -arch=arm ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z(ptr ptr) basic_istream_char_get_streambuf +@ thiscall -arch=i386 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z(ptr ptr) basic_istream_char_get_streambuf +@ cdecl -arch=win64 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z(ptr ptr) basic_istream_char_get_streambuf +@ cdecl -arch=arm ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z(ptr ptr long) basic_istream_char_get_streambuf_delim +@ thiscall -arch=i386 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z(ptr ptr long) basic_istream_char_get_streambuf_delim +@ cdecl -arch=win64 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z(ptr ptr long) basic_istream_char_get_streambuf_delim +@ cdecl -arch=arm ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@PAD_J@Z(ptr ptr int64) basic_istream_char_get_str +@ thiscall -arch=i386 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PAD_J@Z(ptr ptr int64) basic_istream_char_get_str +@ cdecl -arch=win64 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z(ptr ptr long) basic_istream_char_get_str +@ cdecl -arch=arm ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@PAD_JD@Z(ptr ptr int64 long) basic_istream_char_get_str_delim +@ thiscall -arch=i386 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PAD_JD@Z(ptr ptr int64 long) basic_istream_char_get_str_delim +@ cdecl -arch=win64 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_JD@Z(ptr ptr long long) basic_istream_char_get_str_delim +@ cdecl -arch=arm ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAHXZ(ptr) basic_istream_char_get +@ thiscall -arch=i386 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ(ptr) basic_istream_char_get +@ cdecl -arch=win64 ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ(ptr) basic_istream_char_get +@ cdecl -arch=arm ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@AAG@Z(ptr ptr) basic_istream_wchar_get_ch +@ thiscall -arch=i386 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAG@Z(ptr ptr) basic_istream_wchar_get_ch +@ cdecl -arch=win64 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAG@Z(ptr ptr) basic_istream_wchar_get_ch +@ cdecl -arch=arm ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z(ptr ptr) basic_istream_wchar_get_streambuf +@ thiscall -arch=i386 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z(ptr ptr) basic_istream_wchar_get_streambuf +@ cdecl -arch=win64 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z(ptr ptr) basic_istream_wchar_get_streambuf +@ cdecl -arch=arm ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z(ptr ptr long) basic_istream_wchar_get_streambuf_delim +@ thiscall -arch=i386 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z(ptr ptr long) basic_istream_wchar_get_streambuf_delim +@ cdecl -arch=win64 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z(ptr ptr long) basic_istream_wchar_get_streambuf_delim +@ cdecl -arch=arm ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@PAG_J@Z(ptr ptr int64) basic_istream_wchar_get_str +@ thiscall -arch=i386 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAG_J@Z(ptr ptr int64) basic_istream_wchar_get_str +@ cdecl -arch=win64 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z(ptr ptr long) basic_istream_wchar_get_str +@ cdecl -arch=arm ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@PAG_JG@Z(ptr ptr int64 long) basic_istream_wchar_get_str_delim +@ thiscall -arch=i386 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAG_JG@Z(ptr ptr int64 long) basic_istream_wchar_get_str_delim +@ cdecl -arch=win64 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_JG@Z(ptr ptr long long) basic_istream_wchar_get_str_delim +@ cdecl -arch=arm ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAGXZ(ptr) basic_istream_wchar_get +@ thiscall -arch=i386 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEGXZ(ptr) basic_istream_wchar_get +@ cdecl -arch=win64 ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAGXZ(ptr) basic_istream_wchar_get +@ cdecl -arch=arm ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z(ptr ptr) basic_istream_wchar_get_streambuf +@ thiscall -arch=i386 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z(ptr ptr) basic_istream_wchar_get_streambuf +@ cdecl -arch=win64 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z(ptr ptr) basic_istream_wchar_get_streambuf +@ cdecl -arch=arm ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z(ptr ptr long) basic_istream_wchar_get_streambuf_delim +@ thiscall -arch=i386 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z(ptr ptr long) basic_istream_wchar_get_streambuf_delim +@ cdecl -arch=win64 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z(ptr ptr long) basic_istream_wchar_get_streambuf_delim +@ cdecl -arch=arm ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@AA_W@Z(ptr ptr) basic_istream_wchar_get_ch +@ thiscall -arch=i386 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AA_W@Z(ptr ptr) basic_istream_wchar_get_ch +@ cdecl -arch=win64 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEA_W@Z(ptr ptr) basic_istream_wchar_get_ch +@ cdecl -arch=arm ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@PA_W_J@Z(ptr ptr int64) basic_istream_wchar_get_str +@ thiscall -arch=i386 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_W_J@Z(ptr ptr int64) basic_istream_wchar_get_str +@ cdecl -arch=win64 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z(ptr ptr long) basic_istream_wchar_get_str +@ cdecl -arch=arm ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@PA_W_J_W@Z(ptr ptr int64 long) basic_istream_wchar_get_str_delim +@ thiscall -arch=i386 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_W_J_W@Z(ptr ptr int64 long) basic_istream_wchar_get_str_delim +@ cdecl -arch=win64 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J_W@Z(ptr ptr long long) basic_istream_wchar_get_str_delim +@ cdecl -arch=arm ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAGXZ(ptr) basic_istream_wchar_get +@ thiscall -arch=i386 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEGXZ(ptr) basic_istream_wchar_get +@ cdecl -arch=win64 ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAGXZ(ptr) basic_istream_wchar_get +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_ushort +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_ushort +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_ushort +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_uint +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_uint +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_uint +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_long +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_long +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_long +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_ulong +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_ulong +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_ulong +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_float +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_float +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_float +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_double +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_double +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_double +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_ldouble +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_ldouble +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_ldouble +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_void +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_void +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_void +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_int64 +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_int64 +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_int64 +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_uint64 +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_uint64 +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_uint64 +@ cdecl -arch=arm ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_bool +@ thiscall -arch=i386 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_char_get_bool +@ cdecl -arch=win64 ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_char_get_bool +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ushort +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ushort +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_ushort +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_uint +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_uint +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_uint +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_long +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_long +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_long +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ulong +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ulong +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_ulong +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_float +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_float +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_float +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_double +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_double +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_double +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ldouble +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ldouble +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_ldouble +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_void +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_void +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_void +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_int64 +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_int64 +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_int64 +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_uint64 +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_uint64 +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_uint64 +@ cdecl -arch=arm ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_bool +@ thiscall -arch=i386 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_bool +@ cdecl -arch=win64 ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_bool +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ushort +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAG@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ushort +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_ushort +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_uint +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAI@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_uint +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_uint +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_long +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_long +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_long +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ulong +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAK@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ulong +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_ulong +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_float +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAM@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_float +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_float +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_double +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAN@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_double +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_double +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ldouble +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAO@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_ldouble +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_ldouble +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_void +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_void +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_void +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_int64 +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_int64 +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_int64 +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_uint64 +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_uint64 +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_uint64 +@ cdecl -arch=arm ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_bool +@ thiscall -arch=i386 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z(ptr ptr ptr long ptr long ptr ptr ptr) num_get_wchar_get_bool +@ cdecl -arch=win64 ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z(ptr ptr ptr ptr ptr ptr ptr) num_get_wchar_get_bool +@ stub -arch=arm ?get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=i386 ?get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=win64 ?get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@DD@Z +@ stub -arch=arm ?get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBD4@Z +@ stub -arch=i386 ?get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBD4@Z +@ stub -arch=win64 ?get@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@PEBD4@Z +@ stub -arch=arm ?get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=i386 ?get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=win64 ?get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@DD@Z +@ stub -arch=arm ?get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBG4@Z +@ stub -arch=i386 ?get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PBG4@Z +@ stub -arch=win64 ?get@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@PEBG4@Z +@ stub -arch=arm ?get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=i386 ?get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@DD@Z +@ stub -arch=win64 ?get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@DD@Z +@ stub -arch=arm ?get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PB_W4@Z +@ stub -arch=i386 ?get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@PB_W4@Z +@ stub -arch=win64 ?get@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@PEB_W4@Z +@ stub -arch=arm ?get_date@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_date@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_date@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_date@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_date@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_date@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_date@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_date@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_date@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_monthname@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_monthname@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_monthname@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_monthname@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_monthname@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_monthname@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_monthname@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_monthname@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_monthname@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub ?get_new_handler@std@@YAP6AXXZXZ +@ stub -arch=arm ?get_time@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_time@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_time@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_time@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_time@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_time@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_time@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_time@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_time@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_weekday@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_weekday@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_weekday@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_weekday@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_weekday@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_weekday@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_weekday@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_weekday@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_weekday@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_year@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_year@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_year@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_year@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_year@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_year@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ stub -arch=arm ?get_year@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=i386 ?get_year@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHPAUtm@@@Z +@ stub -arch=win64 ?get_year@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHPEAUtm@@@Z +@ cdecl -arch=arm ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@PAD_J@Z(ptr ptr int64) basic_istream_char_getline +@ thiscall -arch=i386 ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PAD_J@Z(ptr ptr int64) basic_istream_char_getline +@ cdecl -arch=win64 ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z(ptr ptr long) basic_istream_char_getline +@ cdecl -arch=arm ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@PAD_JD@Z(ptr ptr int64 long) basic_istream_char_getline_delim +@ thiscall -arch=i386 ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PAD_JD@Z(ptr ptr int64 long) basic_istream_char_getline_delim +@ cdecl -arch=win64 ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_JD@Z(ptr ptr long long) basic_istream_char_getline_delim +@ cdecl -arch=arm ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@PAG_J@Z(ptr ptr int64) basic_istream_wchar_getline +@ thiscall -arch=i386 ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAG_J@Z(ptr ptr int64) basic_istream_wchar_getline +@ cdecl -arch=win64 ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z(ptr ptr long) basic_istream_wchar_getline +@ cdecl -arch=arm ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@PAG_JG@Z(ptr ptr int64 long) basic_istream_wchar_getline_delim +@ thiscall -arch=i386 ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAG_JG@Z(ptr ptr int64 long) basic_istream_wchar_getline_delim +@ cdecl -arch=win64 ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_JG@Z(ptr ptr long long) basic_istream_wchar_getline_delim +@ cdecl -arch=arm ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@PA_W_J@Z(ptr ptr int64) basic_istream_wchar_getline +@ thiscall -arch=i386 ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_W_J@Z(ptr ptr int64) basic_istream_wchar_getline +@ cdecl -arch=win64 ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z(ptr ptr long) basic_istream_wchar_getline +@ cdecl -arch=arm ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@PA_W_J_W@Z(ptr ptr int64 long) basic_istream_wchar_getline_delim +@ thiscall -arch=i386 ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_W_J_W@Z(ptr ptr int64 long) basic_istream_wchar_getline_delim +@ cdecl -arch=win64 ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J_W@Z(ptr ptr long long) basic_istream_wchar_getline_delim +@ cdecl -arch=arm ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QBA?AVlocale@2@XZ(ptr ptr) basic_streambuf_char_getloc +@ thiscall -arch=i386 ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QBE?AVlocale@2@XZ(ptr ptr) basic_streambuf_char_getloc +@ cdecl -arch=win64 ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEBA?AVlocale@2@XZ(ptr ptr) basic_streambuf_char_getloc +@ cdecl -arch=arm ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QBA?AVlocale@2@XZ(ptr ptr) basic_streambuf_wchar_getloc +@ thiscall -arch=i386 ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QBE?AVlocale@2@XZ(ptr ptr) basic_streambuf_wchar_getloc +@ cdecl -arch=win64 ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEBA?AVlocale@2@XZ(ptr ptr) basic_streambuf_wchar_getloc +@ cdecl -arch=arm ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QBA?AVlocale@2@XZ(ptr ptr) basic_streambuf_wchar_getloc +@ thiscall -arch=i386 ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QBE?AVlocale@2@XZ(ptr ptr) basic_streambuf_wchar_getloc +@ cdecl -arch=win64 ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEBA?AVlocale@2@XZ(ptr ptr) basic_streambuf_wchar_getloc +@ cdecl -arch=arm ?getloc@ios_base@std@@QBA?AVlocale@2@XZ(ptr ptr) ios_base_getloc +@ thiscall -arch=i386 ?getloc@ios_base@std@@QBE?AVlocale@2@XZ(ptr ptr) ios_base_getloc +@ cdecl -arch=win64 ?getloc@ios_base@std@@QEBA?AVlocale@2@XZ(ptr ptr) ios_base_getloc +@ cdecl -arch=win32 ?global@locale@std@@SA?AV12@ABV12@@Z(ptr ptr) locale_global +@ cdecl -arch=win64 ?global@locale@std@@SA?AV12@AEBV12@@Z(ptr ptr) locale_global +@ cdecl -arch=arm ?good@ios_base@std@@QBA_NXZ(ptr) ios_base_good +@ thiscall -arch=i386 ?good@ios_base@std@@QBE_NXZ(ptr) ios_base_good +@ cdecl -arch=win64 ?good@ios_base@std@@QEBA_NXZ(ptr) ios_base_good +@ cdecl -arch=arm ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBAPADXZ(ptr) basic_streambuf_char_gptr +@ thiscall -arch=i386 ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ(ptr) basic_streambuf_char_gptr +@ cdecl -arch=win64 ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ(ptr) basic_streambuf_char_gptr +@ cdecl -arch=arm ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBAPAGXZ(ptr) basic_streambuf_wchar_gptr +@ thiscall -arch=i386 ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ(ptr) basic_streambuf_wchar_gptr +@ cdecl -arch=win64 ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ(ptr) basic_streambuf_wchar_gptr +@ cdecl -arch=arm ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBAPA_WXZ(ptr) basic_streambuf_wchar_gptr +@ thiscall -arch=i386 ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ(ptr) basic_streambuf_wchar_gptr +@ cdecl -arch=win64 ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ(ptr) basic_streambuf_wchar_gptr +@ extern ?id@?$codecvt@DDH@std@@2V0locale@2@A codecvt_char_id +@ extern ?id@?$codecvt@GDH@std@@2V0locale@2@A codecvt_short_id +@ extern ?id@?$codecvt@_WDH@std@@2V0locale@2@A codecvt_wchar_id +@ extern ?id@?$collate@D@std@@2V0locale@2@A collate_char_id +@ extern ?id@?$collate@G@std@@2V0locale@2@A collate_short_id +@ extern ?id@?$collate@_W@std@@2V0locale@2@A collate_wchar_id +@ extern ?id@?$ctype@D@std@@2V0locale@2@A ctype_char_id +@ extern ?id@?$ctype@G@std@@2V0locale@2@A ctype_short_id +@ extern ?id@?$ctype@_W@std@@2V0locale@2@A ctype_wchar_id +# extern ?id@?$messages@D@std@@2V0locale@2@A +# extern ?id@?$messages@G@std@@2V0locale@2@A +# extern ?id@?$messages@_W@std@@2V0locale@2@A +# extern ?id@?$money_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@2V0locale@2@A +# extern ?id@?$money_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@2V0locale@2@A +# extern ?id@?$money_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@2V0locale@2@A +# extern ?id@?$money_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@2V0locale@2@A +# extern ?id@?$money_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@2V0locale@2@A +# extern ?id@?$money_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@2V0locale@2@A +# extern ?id@?$moneypunct@D$00@std@@2V0locale@2@A +# extern ?id@?$moneypunct@D$0A@@std@@2V0locale@2@A +# extern ?id@?$moneypunct@G$00@std@@2V0locale@2@A +# extern ?id@?$moneypunct@G$0A@@std@@2V0locale@2@A +# extern ?id@?$moneypunct@_W$00@std@@2V0locale@2@A +# extern ?id@?$moneypunct@_W$0A@@std@@2V0locale@2@A +@ extern ?id@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@2V0locale@2@A num_get_char_id +@ extern ?id@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@2V0locale@2@A num_get_short_id +@ extern ?id@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@2V0locale@2@A num_get_wchar_id +@ extern ?id@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@2V0locale@2@A num_put_char_id +@ extern ?id@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@2V0locale@2@A num_put_short_id +@ extern ?id@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@2V0locale@2@A num_put_wchar_id +@ extern ?id@?$numpunct@D@std@@2V0locale@2@A numpunct_char_id +@ extern ?id@?$numpunct@G@std@@2V0locale@2@A numpunct_short_id +@ extern ?id@?$numpunct@_W@std@@2V0locale@2@A numpunct_wchar_id +# extern ?id@?$time_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@2V0locale@2@A +# extern ?id@?$time_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@2V0locale@2@A +# extern ?id@?$time_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@2V0locale@2@A +@ extern ?id@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@2V0locale@2@A time_put_char_id +@ extern ?id@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@2V0locale@2@A time_put_short_id +@ extern ?id@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@2V0locale@2@A time_put_wchar_id +@ cdecl -arch=arm ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@_JH@Z(ptr int64 long) basic_istream_char_ignore +@ thiscall -arch=i386 ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@_JH@Z(ptr int64 long) basic_istream_char_ignore +@ cdecl -arch=win64 ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z(ptr long long) basic_istream_char_ignore +@ cdecl -arch=arm ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@_JG@Z(ptr int64 long) basic_istream_wchar_ignore +@ thiscall -arch=i386 ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@_JG@Z(ptr int64 long) basic_istream_wchar_ignore +@ cdecl -arch=win64 ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JG@Z(ptr long long) basic_istream_wchar_ignore +@ cdecl -arch=arm ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@_JG@Z(ptr int64 long) basic_istream_wchar_ignore +@ thiscall -arch=i386 ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_JG@Z(ptr int64 long) basic_istream_wchar_ignore +@ cdecl -arch=win64 ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JG@Z(ptr long long) basic_istream_wchar_ignore +@ cdecl -arch=arm ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QAA?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_ios_char_imbue +@ thiscall -arch=i386 ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_ios_char_imbue +@ cdecl -arch=win64 ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z(ptr ptr ptr) basic_ios_char_imbue +@ cdecl -arch=arm ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QAA?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_ios_wchar_imbue +@ thiscall -arch=i386 ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QAE?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_ios_wchar_imbue +@ cdecl -arch=win64 ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z(ptr ptr ptr) basic_ios_wchar_imbue +@ cdecl -arch=arm ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAA?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_ios_wchar_imbue +@ thiscall -arch=i386 ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_ios_wchar_imbue +@ cdecl -arch=win64 ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z(ptr ptr ptr) basic_ios_wchar_imbue +@ cdecl -arch=arm ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAAXABVlocale@2@@Z(ptr ptr) basic_streambuf_char_imbue +@ thiscall -arch=i386 ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEXABVlocale@2@@Z(ptr ptr) basic_streambuf_char_imbue +@ cdecl -arch=win64 ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAXAEBVlocale@2@@Z(ptr ptr) basic_streambuf_char_imbue +@ cdecl -arch=arm ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAAXABVlocale@2@@Z(ptr ptr) basic_streambuf_wchar_imbue +@ thiscall -arch=i386 ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEXABVlocale@2@@Z(ptr ptr) basic_streambuf_wchar_imbue +@ cdecl -arch=win64 ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAXAEBVlocale@2@@Z(ptr ptr) basic_streambuf_wchar_imbue +@ cdecl -arch=arm ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAAXABVlocale@2@@Z(ptr ptr) basic_streambuf_wchar_imbue +@ thiscall -arch=i386 ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEXABVlocale@2@@Z(ptr ptr) basic_streambuf_wchar_imbue +@ cdecl -arch=win64 ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAXAEBVlocale@2@@Z(ptr ptr) basic_streambuf_wchar_imbue +@ cdecl -arch=arm ?imbue@ios_base@std@@QAA?AVlocale@2@ABV32@@Z(ptr ptr ptr) ios_base_imbue +@ thiscall -arch=i386 ?imbue@ios_base@std@@QAE?AVlocale@2@ABV32@@Z(ptr ptr ptr) ios_base_imbue +@ cdecl -arch=win64 ?imbue@ios_base@std@@QEAA?AVlocale@2@AEBV32@@Z(ptr ptr ptr) ios_base_imbue +@ cdecl -arch=arm ?in@?$codecvt@DDH@std@@QBAHAAHPBD1AAPBDPAD3AAPAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_in +@ thiscall -arch=i386 ?in@?$codecvt@DDH@std@@QBEHAAHPBD1AAPBDPAD3AAPAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_in +@ cdecl -arch=win64 ?in@?$codecvt@DDH@std@@QEBAHAEAHPEBD1AEAPEBDPEAD3AEAPEAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_in +@ cdecl -arch=arm ?in@?$codecvt@GDH@std@@QBAHAAHPBD1AAPBDPAG3AAPAG@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_in +@ thiscall -arch=i386 ?in@?$codecvt@GDH@std@@QBEHAAHPBD1AAPBDPAG3AAPAG@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_in +@ cdecl -arch=win64 ?in@?$codecvt@GDH@std@@QEBAHAEAHPEBD1AEAPEBDPEAG3AEAPEAG@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_in +@ cdecl -arch=arm ?in@?$codecvt@_WDH@std@@QBAHAAHPBD1AAPBDPA_W3AAPA_W@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_in +@ thiscall -arch=i386 ?in@?$codecvt@_WDH@std@@QBEHAAHPBD1AAPBDPA_W3AAPA_W@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_in +@ cdecl -arch=win64 ?in@?$codecvt@_WDH@std@@QEBAHAEAHPEBD1AEAPEBDPEA_W3AEAPEA_W@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_wchar_in +@ cdecl -ret64 -arch=arm ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAA_JXZ(ptr) basic_streambuf_char_in_avail +@ thiscall -ret64 -arch=i386 ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE_JXZ(ptr) basic_streambuf_char_in_avail +@ cdecl -arch=win64 ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JXZ(ptr) basic_streambuf_char_in_avail +@ cdecl -ret64 -arch=arm ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAA_JXZ(ptr) basic_streambuf_wchar_in_avail +@ thiscall -ret64 -arch=i386 ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE_JXZ(ptr) basic_streambuf_wchar_in_avail +@ cdecl -arch=win64 ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JXZ(ptr) basic_streambuf_wchar_in_avail +@ cdecl -ret64 -arch=arm ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAA_JXZ(ptr) basic_streambuf_wchar_in_avail +@ thiscall -ret64 -arch=i386 ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE_JXZ(ptr) basic_streambuf_wchar_in_avail +@ cdecl -arch=win64 ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JXZ(ptr) basic_streambuf_wchar_in_avail +@ cdecl -arch=arm ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IAAXPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z(ptr ptr long) basic_ios_char_init +@ thiscall -arch=i386 ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IAEXPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z(ptr ptr long) basic_ios_char_init +@ cdecl -arch=win64 ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IEAAXPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z(ptr ptr long) basic_ios_char_init +@ cdecl -arch=arm ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IAAXPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z(ptr ptr long) basic_ios_wchar_init +@ thiscall -arch=i386 ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IAEXPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z(ptr ptr long) basic_ios_wchar_init +@ cdecl -arch=win64 ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IEAAXPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z(ptr ptr long) basic_ios_wchar_init +@ cdecl -arch=arm ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAAXPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z(ptr ptr long) basic_ios_wchar_init +@ thiscall -arch=i386 ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAEXPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z(ptr ptr long) basic_ios_wchar_init +@ cdecl -arch=win64 ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IEAAXPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z(ptr ptr long) basic_ios_wchar_init +# extern ?intl@?$moneypunct@D$00@std@@2_NB +# extern ?intl@?$moneypunct@D$0A@@std@@2_NB +# extern ?intl@?$moneypunct@G$00@std@@2_NB +# extern ?intl@?$moneypunct@G$0A@@std@@2_NB +# extern ?intl@?$moneypunct@_W$00@std@@2_NB +# extern ?intl@?$moneypunct@_W$0A@@std@@2_NB +@ cdecl -arch=arm ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAA_N_N@Z(ptr long) basic_istream_char_ipfx +@ thiscall -arch=i386 ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z(ptr long) basic_istream_char_ipfx +@ cdecl -arch=win64 ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z(ptr long) basic_istream_char_ipfx +@ cdecl -arch=arm ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAA_N_N@Z(ptr long) basic_istream_wchar_ipfx +@ thiscall -arch=i386 ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z(ptr long) basic_istream_wchar_ipfx +@ cdecl -arch=win64 ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_N_N@Z(ptr long) basic_istream_wchar_ipfx +@ cdecl -arch=arm ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAA_N_N@Z(ptr long) basic_istream_wchar_ipfx +@ thiscall -arch=i386 ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_N_N@Z(ptr long) basic_istream_wchar_ipfx +@ cdecl -arch=win64 ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_N_N@Z(ptr long) basic_istream_wchar_ipfx +@ cdecl -arch=arm ?is@?$ctype@D@std@@QBAPBDPBD0PAF@Z(ptr ptr ptr ptr) ctype_char_is +@ thiscall -arch=i386 ?is@?$ctype@D@std@@QBEPBDPBD0PAF@Z(ptr ptr ptr ptr) ctype_char_is +@ cdecl -arch=win64 ?is@?$ctype@D@std@@QEBAPEBDPEBD0PEAF@Z(ptr ptr ptr ptr) ctype_char_is +@ cdecl -arch=arm ?is@?$ctype@D@std@@QBA_NFD@Z(ptr long long) ctype_char_is_ch +@ thiscall -arch=i386 ?is@?$ctype@D@std@@QBE_NFD@Z(ptr long long) ctype_char_is_ch +@ cdecl -arch=win64 ?is@?$ctype@D@std@@QEBA_NFD@Z(ptr long long) ctype_char_is_ch +@ cdecl -arch=arm ?is@?$ctype@G@std@@QBAPBGPBG0PAF@Z(ptr ptr ptr ptr) ctype_wchar_is +@ thiscall -arch=i386 ?is@?$ctype@G@std@@QBEPBGPBG0PAF@Z(ptr ptr ptr ptr) ctype_wchar_is +@ cdecl -arch=win64 ?is@?$ctype@G@std@@QEBAPEBGPEBG0PEAF@Z(ptr ptr ptr ptr) ctype_wchar_is +@ cdecl -arch=arm ?is@?$ctype@G@std@@QBA_NFG@Z(ptr long long) ctype_wchar_is_ch +@ thiscall -arch=i386 ?is@?$ctype@G@std@@QBE_NFG@Z(ptr long long) ctype_wchar_is_ch +@ cdecl -arch=win64 ?is@?$ctype@G@std@@QEBA_NFG@Z(ptr long long) ctype_wchar_is_ch +@ cdecl -arch=arm ?is@?$ctype@_W@std@@QBAPB_WPB_W0PAF@Z(ptr ptr ptr ptr) ctype_wchar_is +@ thiscall -arch=i386 ?is@?$ctype@_W@std@@QBEPB_WPB_W0PAF@Z(ptr ptr ptr ptr) ctype_wchar_is +@ cdecl -arch=win64 ?is@?$ctype@_W@std@@QEBAPEB_WPEB_W0PEAF@Z(ptr ptr ptr ptr) ctype_wchar_is +@ cdecl -arch=arm ?is@?$ctype@_W@std@@QBA_NF_W@Z(ptr long long) ctype_wchar_is_ch +@ thiscall -arch=i386 ?is@?$ctype@_W@std@@QBE_NF_W@Z(ptr long long) ctype_wchar_is_ch +@ cdecl -arch=win64 ?is@?$ctype@_W@std@@QEBA_NF_W@Z(ptr long long) ctype_wchar_is_ch +@ stub ?is_current_task_group_canceling@Concurrency@@YA_NXZ +@ cdecl -arch=arm ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAXXZ(ptr) basic_istream_char_isfx +@ thiscall -arch=i386 ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXXZ(ptr) basic_istream_char_isfx +@ cdecl -arch=win64 ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXXZ(ptr) basic_istream_char_isfx +@ cdecl -arch=arm ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAXXZ(ptr) basic_istream_wchar_isfx +@ thiscall -arch=i386 ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXXZ(ptr) basic_istream_wchar_isfx +@ cdecl -arch=win64 ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXXZ(ptr) basic_istream_wchar_isfx +@ cdecl -arch=arm ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAXXZ(ptr) basic_istream_wchar_isfx +@ thiscall -arch=i386 ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXXZ(ptr) basic_istream_wchar_isfx +@ cdecl -arch=win64 ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ(ptr) basic_istream_wchar_isfx +@ cdecl -arch=arm ?iword@ios_base@std@@QAAAAJH@Z(ptr long) ios_base_iword +@ thiscall -arch=i386 ?iword@ios_base@std@@QAEAAJH@Z(ptr long) ios_base_iword +@ cdecl -arch=win64 ?iword@ios_base@std@@QEAAAEAJH@Z(ptr long) ios_base_iword +@ cdecl -arch=arm ?length@?$codecvt@DDH@std@@QBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_length +@ thiscall -arch=i386 ?length@?$codecvt@DDH@std@@QBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_length +@ cdecl -arch=win64 ?length@?$codecvt@DDH@std@@QEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_char_length +@ cdecl -arch=arm ?length@?$codecvt@GDH@std@@QBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_length +@ thiscall -arch=i386 ?length@?$codecvt@GDH@std@@QBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_length +@ cdecl -arch=win64 ?length@?$codecvt@GDH@std@@QEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_length +@ cdecl -arch=arm ?length@?$codecvt@_WDH@std@@QBAHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_length +@ thiscall -arch=i386 ?length@?$codecvt@_WDH@std@@QBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_length +@ cdecl -arch=win64 ?length@?$codecvt@_WDH@std@@QEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_length +@ cdecl -arch=arm ?max_length@codecvt_base@std@@QBAHXZ(ptr) codecvt_base_max_length +@ thiscall -arch=i386 ?max_length@codecvt_base@std@@QBEHXZ(ptr) codecvt_base_max_length +@ cdecl -arch=win64 ?max_length@codecvt_base@std@@QEBAHXZ(ptr) codecvt_base_max_length +@ stub -arch=arm ?move@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAX$$QAV12@@Z +@ stub -arch=i386 ?move@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEX$$QAV12@@Z +@ stub -arch=win64 ?move@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAX$$QEAV12@@Z +@ stub -arch=arm ?move@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAXAAV12@@Z +@ stub -arch=i386 ?move@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXAAV12@@Z +@ stub -arch=win64 ?move@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXAEAV12@@Z +@ stub -arch=arm ?move@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAX$$QAV12@@Z +@ stub -arch=i386 ?move@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEX$$QAV12@@Z +@ stub -arch=win64 ?move@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAX$$QEAV12@@Z +@ stub -arch=arm ?move@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAXAAV12@@Z +@ stub -arch=i386 ?move@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXAAV12@@Z +@ stub -arch=win64 ?move@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXAEAV12@@Z +@ stub -arch=arm ?move@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAX$$QAV12@@Z +@ stub -arch=i386 ?move@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEX$$QAV12@@Z +@ stub -arch=win64 ?move@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAX$$QEAV12@@Z +@ stub -arch=arm ?move@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAXAAV12@@Z +@ stub -arch=i386 ?move@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXAAV12@@Z +@ stub -arch=win64 ?move@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXAEAV12@@Z +@ cdecl -arch=arm ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QBADDD@Z(ptr long long) basic_ios_char_narrow +@ thiscall -arch=i386 ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDDD@Z(ptr long long) basic_ios_char_narrow +@ cdecl -arch=win64 ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADDD@Z(ptr long long) basic_ios_char_narrow +@ cdecl -arch=arm ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QBADGD@Z(ptr long long) basic_ios_wchar_narrow +@ thiscall -arch=i386 ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEDGD@Z(ptr long long) basic_ios_wchar_narrow +@ cdecl -arch=win64 ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBADGD@Z(ptr long long) basic_ios_wchar_narrow +@ cdecl -arch=arm ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBAD_WD@Z(ptr long long) basic_ios_wchar_narrow +@ thiscall -arch=i386 ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBED_WD@Z(ptr long long) basic_ios_wchar_narrow +@ cdecl -arch=win64 ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAD_WD@Z(ptr long long) basic_ios_wchar_narrow +@ cdecl -arch=arm ?narrow@?$ctype@D@std@@QBADDD@Z(ptr long long) ctype_char_narrow_ch +@ thiscall -arch=i386 ?narrow@?$ctype@D@std@@QBEDDD@Z(ptr long long) ctype_char_narrow_ch +@ cdecl -arch=win64 ?narrow@?$ctype@D@std@@QEBADDD@Z(ptr long long) ctype_char_narrow_ch +@ cdecl -arch=arm ?narrow@?$ctype@D@std@@QBAPBDPBD0DPAD@Z(ptr ptr ptr long ptr) ctype_char_narrow +@ thiscall -arch=i386 ?narrow@?$ctype@D@std@@QBEPBDPBD0DPAD@Z(ptr ptr ptr long ptr) ctype_char_narrow +@ cdecl -arch=win64 ?narrow@?$ctype@D@std@@QEBAPEBDPEBD0DPEAD@Z(ptr ptr ptr long ptr) ctype_char_narrow +@ cdecl -arch=arm ?narrow@?$ctype@G@std@@QBADGD@Z(ptr long long) ctype_wchar_narrow_ch +@ thiscall -arch=i386 ?narrow@?$ctype@G@std@@QBEDGD@Z(ptr long long) ctype_wchar_narrow_ch +@ cdecl -arch=win64 ?narrow@?$ctype@G@std@@QEBADGD@Z(ptr long long) ctype_wchar_narrow_ch +@ cdecl -arch=arm ?narrow@?$ctype@G@std@@QBAPBGPBG0DPAD@Z(ptr ptr ptr long ptr) ctype_wchar_narrow +@ thiscall -arch=i386 ?narrow@?$ctype@G@std@@QBEPBGPBG0DPAD@Z(ptr ptr ptr long ptr) ctype_wchar_narrow +@ cdecl -arch=win64 ?narrow@?$ctype@G@std@@QEBAPEBGPEBG0DPEAD@Z(ptr ptr ptr long ptr) ctype_wchar_narrow +@ cdecl -arch=arm ?narrow@?$ctype@_W@std@@QBAD_WD@Z(ptr long long) ctype_wchar_narrow_ch +@ thiscall -arch=i386 ?narrow@?$ctype@_W@std@@QBED_WD@Z(ptr long long) ctype_wchar_narrow_ch +@ cdecl -arch=win64 ?narrow@?$ctype@_W@std@@QEBAD_WD@Z(ptr long long) ctype_wchar_narrow_ch +@ cdecl -arch=arm ?narrow@?$ctype@_W@std@@QBAPB_WPB_W0DPAD@Z(ptr ptr ptr long ptr) ctype_wchar_narrow +@ thiscall -arch=i386 ?narrow@?$ctype@_W@std@@QBEPB_WPB_W0DPAD@Z(ptr ptr ptr long ptr) ctype_wchar_narrow +@ cdecl -arch=win64 ?narrow@?$ctype@_W@std@@QEBAPEB_WPEB_W0DPEAD@Z(ptr ptr ptr long ptr) ctype_wchar_narrow +@ cdecl -arch=arm ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAA_NXZ(ptr) basic_ostream_char_opfx +@ thiscall -arch=i386 ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE_NXZ(ptr) basic_ostream_char_opfx +@ cdecl -arch=win64 ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA_NXZ(ptr) basic_ostream_char_opfx +@ cdecl -arch=arm ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAA_NXZ(ptr) basic_ostream_wchar_opfx +@ thiscall -arch=i386 ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE_NXZ(ptr) basic_ostream_wchar_opfx +@ cdecl -arch=win64 ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA_NXZ(ptr) basic_ostream_wchar_opfx +@ cdecl -arch=arm ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAA_NXZ(ptr) basic_ostream_wchar_opfx +@ thiscall -arch=i386 ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE_NXZ(ptr) basic_ostream_wchar_opfx +@ cdecl -arch=win64 ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA_NXZ(ptr) basic_ostream_wchar_opfx +@ cdecl -arch=arm ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAXXZ(ptr) basic_ostream_char_osfx +@ thiscall -arch=i386 ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ(ptr) basic_ostream_char_osfx +@ cdecl -arch=win64 ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ(ptr) basic_ostream_char_osfx +@ cdecl -arch=arm ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAXXZ(ptr) basic_ostream_wchar_osfx +@ thiscall -arch=i386 ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ(ptr) basic_ostream_wchar_osfx +@ cdecl -arch=win64 ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ(ptr) basic_ostream_wchar_osfx +@ cdecl -arch=arm ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAXXZ(ptr) basic_ostream_wchar_osfx +@ thiscall -arch=i386 ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ(ptr) basic_ostream_wchar_osfx +@ cdecl -arch=win64 ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ(ptr) basic_ostream_wchar_osfx +@ cdecl -arch=arm ?out@?$codecvt@DDH@std@@QBAHAAHPBD1AAPBDPAD3AAPAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_out +@ thiscall -arch=i386 ?out@?$codecvt@DDH@std@@QBEHAAHPBD1AAPBDPAD3AAPAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_out +@ cdecl -arch=win64 ?out@?$codecvt@DDH@std@@QEBAHAEAHPEBD1AEAPEBDPEAD3AEAPEAD@Z(ptr ptr str str ptr ptr ptr ptr) codecvt_char_out +@ cdecl -arch=arm ?out@?$codecvt@GDH@std@@QBAHAAHPBG1AAPBGPAD3AAPAD@Z(ptr ptr ptr ptr ptr ptr ptr ptr) codecvt_wchar_out +@ thiscall -arch=i386 ?out@?$codecvt@GDH@std@@QBEHAAHPBG1AAPBGPAD3AAPAD@Z(ptr ptr ptr ptr ptr ptr ptr ptr) codecvt_wchar_out +@ cdecl -arch=win64 ?out@?$codecvt@GDH@std@@QEBAHAEAHPEBG1AEAPEBGPEAD3AEAPEAD@Z(ptr ptr ptr ptr ptr ptr ptr ptr) codecvt_wchar_out +@ cdecl -arch=arm ?out@?$codecvt@_WDH@std@@QBAHAAHPB_W1AAPB_WPAD3AAPAD@Z(ptr ptr wstr wstr ptr ptr ptr ptr) codecvt_wchar_out +@ thiscall -arch=i386 ?out@?$codecvt@_WDH@std@@QBEHAAHPB_W1AAPB_WPAD3AAPAD@Z(ptr ptr wstr wstr ptr ptr ptr ptr) codecvt_wchar_out +@ cdecl -arch=win64 ?out@?$codecvt@_WDH@std@@QEBAHAEAHPEB_W1AEAPEB_WPEAD3AEAPEAD@Z(ptr ptr wstr wstr ptr ptr ptr ptr) codecvt_wchar_out +@ cdecl -arch=arm ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAAHH@Z(ptr long) basic_streambuf_char_overflow +@ thiscall -arch=i386 ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHH@Z(ptr long) basic_streambuf_char_overflow +@ cdecl -arch=win64 ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z(ptr long) basic_streambuf_char_overflow +@ cdecl -arch=arm ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAAGG@Z(ptr long) basic_streambuf_wchar_overflow +@ thiscall -arch=i386 ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGG@Z(ptr long) basic_streambuf_wchar_overflow +@ cdecl -arch=win64 ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z(ptr long) basic_streambuf_wchar_overflow +@ cdecl -arch=arm ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAAGG@Z(ptr long) basic_streambuf_wchar_overflow +@ thiscall -arch=i386 ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z(ptr long) basic_streambuf_wchar_overflow +@ cdecl -arch=win64 ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z(ptr long) basic_streambuf_wchar_overflow +@ cdecl -arch=arm ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAAHH@Z(ptr long) basic_streambuf_char_pbackfail +@ thiscall -arch=i386 ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHH@Z(ptr long) basic_streambuf_char_pbackfail +@ cdecl -arch=win64 ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z(ptr long) basic_streambuf_char_pbackfail +@ cdecl -arch=arm ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAAGG@Z(ptr long) basic_streambuf_wchar_pbackfail +@ thiscall -arch=i386 ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGG@Z(ptr long) basic_streambuf_wchar_pbackfail +@ cdecl -arch=win64 ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z(ptr long) basic_streambuf_wchar_pbackfail +@ cdecl -arch=arm ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAAGG@Z(ptr long) basic_streambuf_wchar_pbackfail +@ thiscall -arch=i386 ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z(ptr long) basic_streambuf_wchar_pbackfail +@ cdecl -arch=win64 ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z(ptr long) basic_streambuf_wchar_pbackfail +@ cdecl -arch=arm ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBAPADXZ(ptr) basic_streambuf_char_pbase +@ thiscall -arch=i386 ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ(ptr) basic_streambuf_char_pbase +@ cdecl -arch=win64 ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ(ptr) basic_streambuf_char_pbase +@ cdecl -arch=arm ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBAPAGXZ(ptr) basic_streambuf_wchar_pbase +@ thiscall -arch=i386 ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ(ptr) basic_streambuf_wchar_pbase +@ cdecl -arch=win64 ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ(ptr) basic_streambuf_wchar_pbase +@ cdecl -arch=arm ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBAPA_WXZ(ptr) basic_streambuf_wchar_pbase +@ thiscall -arch=i386 ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ(ptr) basic_streambuf_wchar_pbase +@ cdecl -arch=win64 ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ(ptr) basic_streambuf_wchar_pbase +@ cdecl -arch=arm ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAXH@Z(ptr long) basic_streambuf_char_pbump +@ thiscall -arch=i386 ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXH@Z(ptr long) basic_streambuf_char_pbump +@ cdecl -arch=win64 ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXH@Z(ptr long) basic_streambuf_char_pbump +@ cdecl -arch=arm ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAXH@Z(ptr long) basic_streambuf_wchar_pbump +@ thiscall -arch=i386 ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXH@Z(ptr long) basic_streambuf_wchar_pbump +@ cdecl -arch=win64 ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXH@Z(ptr long) basic_streambuf_wchar_pbump +@ cdecl -arch=arm ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAXH@Z(ptr long) basic_streambuf_wchar_pbump +@ thiscall -arch=i386 ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXH@Z(ptr long) basic_streambuf_wchar_pbump +@ cdecl -arch=win64 ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXH@Z(ptr long) basic_streambuf_wchar_pbump +@ cdecl -arch=arm ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAHXZ(ptr) basic_istream_char_peek +@ thiscall -arch=i386 ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ(ptr) basic_istream_char_peek +@ cdecl -arch=win64 ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ(ptr) basic_istream_char_peek +@ cdecl -arch=arm ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAGXZ(ptr) basic_istream_wchar_peek +@ thiscall -arch=i386 ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEGXZ(ptr) basic_istream_wchar_peek +@ cdecl -arch=win64 ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAGXZ(ptr) basic_istream_wchar_peek +@ cdecl -arch=arm ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAGXZ(ptr) basic_istream_wchar_peek +@ thiscall -arch=i386 ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEGXZ(ptr) basic_istream_wchar_peek +@ cdecl -arch=win64 ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAGXZ(ptr) basic_istream_wchar_peek +@ cdecl -arch=arm ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBAPADXZ(ptr) basic_streambuf_char_pptr +@ thiscall -arch=i386 ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ(ptr) basic_streambuf_char_pptr +@ cdecl -arch=win64 ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ(ptr) basic_streambuf_char_pptr +@ cdecl -arch=arm ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBAPAGXZ(ptr) basic_streambuf_wchar_pptr +@ thiscall -arch=i386 ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ(ptr) basic_streambuf_wchar_pptr +@ cdecl -arch=win64 ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ(ptr) basic_streambuf_wchar_pptr +@ cdecl -arch=arm ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBAPA_WXZ(ptr) basic_streambuf_wchar_pptr +@ thiscall -arch=i386 ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ(ptr) basic_streambuf_wchar_pptr +@ cdecl -arch=win64 ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ(ptr) basic_streambuf_wchar_pptr +@ cdecl -ret64 -arch=arm ?precision@ios_base@std@@QAA_J_J@Z(ptr int64) ios_base_precision_set +@ thiscall -ret64 -arch=i386 ?precision@ios_base@std@@QAE_J_J@Z(ptr int64) ios_base_precision_set +@ cdecl -arch=win64 ?precision@ios_base@std@@QEAA_J_J@Z(ptr long) ios_base_precision_set +@ cdecl -ret64 -arch=arm ?precision@ios_base@std@@QBA_JXZ(ptr) ios_base_precision_get +@ thiscall -ret64 -arch=i386 ?precision@ios_base@std@@QBE_JXZ(ptr) ios_base_precision_get +@ cdecl -arch=win64 ?precision@ios_base@std@@QEBA_JXZ(ptr) ios_base_precision_get +@ cdecl -arch=arm ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAA?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_streambuf_char_pubimbue +@ thiscall -arch=i386 ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_streambuf_char_pubimbue +@ cdecl -arch=win64 ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z(ptr ptr ptr) basic_streambuf_char_pubimbue +@ cdecl -arch=arm ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAA?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_streambuf_wchar_pubimbue +@ thiscall -arch=i386 ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_streambuf_wchar_pubimbue +@ cdecl -arch=win64 ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z(ptr ptr ptr) basic_streambuf_wchar_pubimbue +@ cdecl -arch=arm ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAA?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_streambuf_wchar_pubimbue +@ thiscall -arch=i386 ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AVlocale@2@ABV32@@Z(ptr ptr ptr) basic_streambuf_wchar_pubimbue +@ cdecl -arch=win64 ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z(ptr ptr ptr) basic_streambuf_wchar_pubimbue +@ cdecl -arch=arm ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAA?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_char_pubseekoff +@ thiscall -arch=i386 ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_char_pubseekoff +@ cdecl -arch=win64 ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z(ptr ptr long long long) basic_streambuf_char_pubseekoff +@ cdecl -arch=arm ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAA?AV?$fpos@H@2@_JII@Z(ptr ptr int64 long long) basic_streambuf_char_pubseekoff_old +@ thiscall -arch=i386 ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@_JII@Z(ptr ptr int64 long long) basic_streambuf_char_pubseekoff_old +@ cdecl -arch=win64 ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z(ptr ptr long long long) basic_streambuf_char_pubseekoff_old +@ cdecl -arch=arm ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAA?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_wchar_pubseekoff +@ thiscall -arch=i386 ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_wchar_pubseekoff +@ cdecl -arch=win64 ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z(ptr ptr long long long) basic_streambuf_wchar_pubseekoff +@ cdecl -arch=arm ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAA?AV?$fpos@H@2@_JII@Z(ptr ptr int64 long long) basic_streambuf_wchar_pubseekoff_old +@ thiscall -arch=i386 ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@_JII@Z(ptr ptr int64 long long) basic_streambuf_wchar_pubseekoff_old +@ cdecl -arch=win64 ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z(ptr ptr long long long) basic_streambuf_wchar_pubseekoff_old +@ cdecl -arch=arm ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAA?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_wchar_pubseekoff +@ thiscall -arch=i386 ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_wchar_pubseekoff +@ cdecl -arch=win64 ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z(ptr ptr long long long) basic_streambuf_wchar_pubseekoff +@ cdecl -arch=arm ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAA?AV?$fpos@H@2@_JII@Z(ptr ptr int64 long long) basic_streambuf_wchar_pubseekoff_old +@ thiscall -arch=i386 ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@_JII@Z(ptr ptr int64 long long) basic_streambuf_wchar_pubseekoff_old +@ cdecl -arch=win64 ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z(ptr ptr long long long) basic_streambuf_wchar_pubseekoff_old +@ cdecl -arch=arm ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAA?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_char_pubseekpos +@ thiscall -arch=i386 ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_char_pubseekpos +@ cdecl -arch=win64 ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z(ptr ptr ptr long) basic_streambuf_char_pubseekpos +@ cdecl -arch=arm ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAA?AV?$fpos@H@2@V32@I@Z(ptr ptr long long int64 long long long) basic_streambuf_char_pubseekpos_old +@ thiscall -arch=i386 ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z(ptr ptr long long int64 long long long) basic_streambuf_char_pubseekpos_old +@ cdecl -arch=win64 ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z(ptr ptr ptr long) basic_streambuf_char_pubseekpos_old +@ cdecl -arch=arm ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAA?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_pubseekpos +@ thiscall -arch=i386 ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_pubseekpos +@ cdecl -arch=win64 ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z(ptr ptr ptr long) basic_streambuf_wchar_pubseekpos +@ cdecl -arch=arm ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAA?AV?$fpos@H@2@V32@I@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_pubseekpos_old +@ thiscall -arch=i386 ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_pubseekpos_old +@ cdecl -arch=win64 ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z(ptr ptr ptr long) basic_streambuf_wchar_pubseekpos_old +@ cdecl -arch=arm ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAA?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_pubseekpos +@ thiscall -arch=i386 ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_pubseekpos +@ cdecl -arch=win64 ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z(ptr ptr ptr long) basic_streambuf_wchar_pubseekpos +@ cdecl -arch=arm ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAA?AV?$fpos@H@2@V32@I@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_pubseekpos_old +@ thiscall -arch=i386 ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_pubseekpos_old +@ cdecl -arch=win64 ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z(ptr ptr ptr long) basic_streambuf_wchar_pubseekpos_old +@ cdecl -arch=arm ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAPAV12@PAD_J@Z(ptr ptr int64) basic_streambuf_char_pubsetbuf +@ thiscall -arch=i386 ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PAD_J@Z(ptr ptr int64) basic_streambuf_char_pubsetbuf +@ cdecl -arch=win64 ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEAD_J@Z(ptr ptr long) basic_streambuf_char_pubsetbuf +@ cdecl -arch=arm ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAPAV12@PAG_J@Z(ptr ptr int64) basic_streambuf_wchar_pubsetbuf +@ thiscall -arch=i386 ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PAG_J@Z(ptr ptr int64) basic_streambuf_wchar_pubsetbuf +@ cdecl -arch=win64 ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEAG_J@Z(ptr ptr long) basic_streambuf_wchar_pubsetbuf +@ cdecl -arch=arm ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAPAV12@PA_W_J@Z(ptr ptr int64) basic_streambuf_wchar_pubsetbuf +@ thiscall -arch=i386 ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PA_W_J@Z(ptr ptr int64) basic_streambuf_wchar_pubsetbuf +@ cdecl -arch=win64 ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEA_W_J@Z(ptr ptr long) basic_streambuf_wchar_pubsetbuf +@ cdecl -arch=arm ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAHXZ(ptr) basic_streambuf_char_pubsync +@ thiscall -arch=i386 ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ(ptr) basic_streambuf_char_pubsync +@ cdecl -arch=win64 ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ(ptr) basic_streambuf_char_pubsync +@ cdecl -arch=arm ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAHXZ(ptr) basic_streambuf_wchar_pubsync +@ thiscall -arch=i386 ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHXZ(ptr) basic_streambuf_wchar_pubsync +@ cdecl -arch=win64 ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAHXZ(ptr) basic_streambuf_wchar_pubsync +@ cdecl -arch=arm ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAHXZ(ptr) basic_streambuf_wchar_pubsync +@ thiscall -arch=i386 ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHXZ(ptr) basic_streambuf_wchar_pubsync +@ cdecl -arch=win64 ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAHXZ(ptr) basic_streambuf_wchar_pubsync +@ cdecl -arch=arm ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV12@D@Z(ptr long) basic_ostream_char_put +@ thiscall -arch=i386 ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@D@Z(ptr long) basic_ostream_char_put +@ cdecl -arch=win64 ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@D@Z(ptr long) basic_ostream_char_put +@ cdecl -arch=arm ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV12@G@Z(ptr long) basic_ostream_wchar_put +@ thiscall -arch=i386 ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@G@Z(ptr long) basic_ostream_wchar_put +@ cdecl -arch=win64 ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@G@Z(ptr long) basic_ostream_wchar_put +@ cdecl -arch=arm ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@_W@Z(ptr long) basic_ostream_wchar_put +@ thiscall -arch=i386 ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_W@Z(ptr long) basic_ostream_wchar_put +@ cdecl -arch=win64 ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_W@Z(ptr long) basic_ostream_wchar_put +@ cdecl -arch=arm ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DJ@Z(ptr ptr long ptr ptr long long) num_put_char_put_long +@ thiscall -arch=i386 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DJ@Z(ptr ptr long ptr ptr long long) num_put_char_put_long +@ cdecl -arch=win64 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DJ@Z(ptr ptr ptr ptr long long) num_put_char_put_long +@ cdecl -arch=arm ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DK@Z(ptr ptr long ptr ptr long long) num_put_char_put_ulong +@ thiscall -arch=i386 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DK@Z(ptr ptr long ptr ptr long long) num_put_char_put_ulong +@ cdecl -arch=win64 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DK@Z(ptr ptr ptr ptr long long) num_put_char_put_ulong +@ cdecl -arch=arm ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DN@Z(ptr ptr long ptr ptr long double) num_put_char_put_double +@ thiscall -arch=i386 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DN@Z(ptr ptr long ptr ptr long double) num_put_char_put_double +@ cdecl -arch=win64 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DN@Z(ptr ptr ptr ptr long double) num_put_char_put_double +@ cdecl -arch=arm ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DO@Z(ptr ptr long ptr ptr long double) num_put_char_put_ldouble +@ thiscall -arch=i386 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DO@Z(ptr ptr long ptr ptr long double) num_put_char_put_ldouble +@ cdecl -arch=win64 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DO@Z(ptr ptr ptr ptr long double) num_put_char_put_ldouble +@ cdecl -arch=arm ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBX@Z(ptr ptr long ptr ptr long ptr) num_put_char_put_ptr +@ thiscall -arch=i386 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBX@Z(ptr ptr long ptr ptr long ptr) num_put_char_put_ptr +@ cdecl -arch=win64 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DPEBX@Z(ptr ptr ptr ptr long ptr) num_put_char_put_ptr +@ cdecl -arch=arm ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_J@Z(ptr ptr long ptr ptr long int64) num_put_char_put_int64 +@ thiscall -arch=i386 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_J@Z(ptr ptr long ptr ptr long int64) num_put_char_put_int64 +@ cdecl -arch=win64 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@D_J@Z(ptr ptr ptr ptr long int64) num_put_char_put_int64 +@ cdecl -arch=arm ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_K@Z(ptr ptr long ptr ptr long int64) num_put_char_put_uint64 +@ thiscall -arch=i386 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_K@Z(ptr ptr long ptr ptr long int64) num_put_char_put_uint64 +@ cdecl -arch=win64 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@D_K@Z(ptr ptr ptr ptr long int64) num_put_char_put_uint64 +@ cdecl -arch=arm ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_N@Z(ptr ptr long ptr ptr long long) num_put_char_put_bool +@ thiscall -arch=i386 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@D_N@Z(ptr ptr long ptr ptr long long) num_put_char_put_bool +@ cdecl -arch=win64 ?put@?$num_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@D_N@Z(ptr ptr ptr ptr long long) num_put_char_put_bool +@ cdecl -arch=arm ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GJ@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_long +@ thiscall -arch=i386 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GJ@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_long +@ cdecl -arch=win64 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GJ@Z(ptr ptr ptr ptr long long) num_put_wchar_put_long +@ cdecl -arch=arm ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GK@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_ulong +@ thiscall -arch=i386 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GK@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_ulong +@ cdecl -arch=win64 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GK@Z(ptr ptr ptr ptr long long) num_put_wchar_put_ulong +@ cdecl -arch=arm ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GN@Z(ptr ptr long ptr ptr long double) num_put_wchar_put_double +@ thiscall -arch=i386 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GN@Z(ptr ptr long ptr ptr long double) num_put_wchar_put_double +@ cdecl -arch=win64 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GN@Z(ptr ptr ptr ptr long double) num_put_wchar_put_double +@ cdecl -arch=arm ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GO@Z(ptr ptr long ptr ptr long double) num_put_wchar_put_ldouble +@ thiscall -arch=i386 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GO@Z(ptr ptr long ptr ptr long double) num_put_wchar_put_ldouble +@ cdecl -arch=win64 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GO@Z(ptr ptr ptr ptr long double) num_put_wchar_put_ldouble +@ cdecl -arch=arm ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBX@Z(ptr ptr long ptr ptr long ptr) num_put_wchar_put_ptr +@ thiscall -arch=i386 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBX@Z(ptr ptr long ptr ptr long ptr) num_put_wchar_put_ptr +@ cdecl -arch=win64 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GPEBX@Z(ptr ptr ptr ptr long ptr) num_put_wchar_put_ptr +@ cdecl -arch=arm ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_J@Z(ptr ptr long ptr ptr long int64) num_put_wchar_put_int64 +@ thiscall -arch=i386 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_J@Z(ptr ptr long ptr ptr long int64) num_put_wchar_put_int64 +@ cdecl -arch=win64 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@G_J@Z(ptr ptr ptr ptr long int64) num_put_wchar_put_int64 +@ cdecl -arch=arm ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_K@Z(ptr ptr long ptr ptr long int64) num_put_wchar_put_uint64 +@ thiscall -arch=i386 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_K@Z(ptr ptr long ptr ptr long int64) num_put_wchar_put_uint64 +@ cdecl -arch=win64 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@G_K@Z(ptr ptr ptr ptr long int64) num_put_wchar_put_uint64 +@ cdecl -arch=arm ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_N@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_bool +@ thiscall -arch=i386 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@G_N@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_bool +@ cdecl -arch=win64 ?put@?$num_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@G_N@Z(ptr ptr ptr ptr long long) num_put_wchar_put_bool +@ cdecl -arch=arm ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WJ@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_long +@ thiscall -arch=i386 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WJ@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_long +@ cdecl -arch=win64 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WJ@Z(ptr ptr ptr ptr long long) num_put_wchar_put_long +@ cdecl -arch=arm ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WK@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_ulong +@ thiscall -arch=i386 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WK@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_ulong +@ cdecl -arch=win64 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WK@Z(ptr ptr ptr ptr long long) num_put_wchar_put_ulong +@ cdecl -arch=arm ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WN@Z(ptr ptr long ptr ptr long double) num_put_wchar_put_double +@ thiscall -arch=i386 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WN@Z(ptr ptr long ptr ptr long double) num_put_wchar_put_double +@ cdecl -arch=win64 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WN@Z(ptr ptr ptr ptr long double) num_put_wchar_put_double +@ cdecl -arch=arm ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WO@Z(ptr ptr long ptr ptr long double) num_put_wchar_put_ldouble +@ thiscall -arch=i386 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WO@Z(ptr ptr long ptr ptr long double) num_put_wchar_put_ldouble +@ cdecl -arch=win64 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WO@Z(ptr ptr ptr ptr long double) num_put_wchar_put_ldouble +@ cdecl -arch=arm ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBX@Z(ptr ptr long ptr ptr long ptr) num_put_wchar_put_ptr +@ thiscall -arch=i386 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBX@Z(ptr ptr long ptr ptr long ptr) num_put_wchar_put_ptr +@ cdecl -arch=win64 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WPEBX@Z(ptr ptr ptr ptr long ptr) num_put_wchar_put_ptr +@ cdecl -arch=arm ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_J@Z(ptr ptr long ptr ptr long int64) num_put_wchar_put_int64 +@ thiscall -arch=i386 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_J@Z(ptr ptr long ptr ptr long int64) num_put_wchar_put_int64 +@ cdecl -arch=win64 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_W_J@Z(ptr ptr ptr ptr long int64) num_put_wchar_put_int64 +@ cdecl -arch=arm ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_K@Z(ptr ptr long ptr ptr long int64) num_put_wchar_put_uint64 +@ thiscall -arch=i386 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_K@Z(ptr ptr long ptr ptr long int64) num_put_wchar_put_uint64 +@ cdecl -arch=win64 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_W_K@Z(ptr ptr ptr ptr long int64) num_put_wchar_put_uint64 +@ cdecl -arch=arm ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_N@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_bool +@ thiscall -arch=i386 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_W_N@Z(ptr ptr long ptr ptr long long) num_put_wchar_put_bool +@ cdecl -arch=win64 ?put@?$num_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_W_N@Z(ptr ptr ptr ptr long long) num_put_wchar_put_bool +@ cdecl -arch=arm ?put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_char_put +@ thiscall -arch=i386 ?put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_char_put +@ cdecl -arch=win64 ?put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DPEBUtm@@DD@Z(ptr ptr ptr ptr long ptr long long) time_put_char_put +@ cdecl -arch=arm ?put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBUtm@@PBD3@Z(ptr ptr long ptr ptr long ptr ptr ptr) time_put_char_put_format +@ thiscall -arch=i386 ?put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AAVios_base@2@DPBUtm@@PBD3@Z(ptr ptr long ptr ptr long ptr ptr ptr) time_put_char_put_format +@ cdecl -arch=win64 ?put@?$time_put@DV?$ostreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@DU?$char_traits@D@std@@@2@V32@AEAVios_base@2@DPEBUtm@@PEBD3@Z(ptr ptr ptr ptr long ptr ptr ptr) time_put_char_put_format +@ cdecl -arch=arm ?put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_wchar_put +@ thiscall -arch=i386 ?put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_wchar_put +@ cdecl -arch=win64 ?put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GPEBUtm@@DD@Z(ptr ptr ptr ptr long ptr long long) time_put_wchar_put +@ cdecl -arch=arm ?put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBUtm@@PBG3@Z(ptr ptr long ptr ptr long ptr ptr ptr) time_put_wchar_put_format +@ thiscall -arch=i386 ?put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AAVios_base@2@GPBUtm@@PBG3@Z(ptr ptr long ptr ptr long ptr ptr ptr) time_put_wchar_put_format +@ cdecl -arch=win64 ?put@?$time_put@GV?$ostreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@GU?$char_traits@G@std@@@2@V32@AEAVios_base@2@GPEBUtm@@PEBG3@Z(ptr ptr ptr ptr long ptr ptr ptr) time_put_wchar_put_format +@ cdecl -arch=arm ?put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_wchar_put +@ thiscall -arch=i386 ?put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBUtm@@DD@Z(ptr ptr long ptr ptr long ptr long long) time_put_wchar_put +@ cdecl -arch=win64 ?put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WPEBUtm@@DD@Z(ptr ptr ptr ptr long ptr long long) time_put_wchar_put +@ cdecl -arch=arm ?put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBUtm@@PB_W4@Z(ptr ptr long ptr ptr long ptr ptr ptr) time_put_wchar_put_format +@ thiscall -arch=i386 ?put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AAVios_base@2@_WPBUtm@@PB_W4@Z(ptr ptr long ptr ptr long ptr ptr ptr) time_put_wchar_put_format +@ cdecl -arch=win64 ?put@?$time_put@_WV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$ostreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@AEAVios_base@2@_WPEBUtm@@PEB_W4@Z(ptr ptr ptr ptr long ptr ptr ptr) time_put_wchar_put_format +@ cdecl -arch=arm ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@D@Z(ptr long) basic_istream_char_putback +@ thiscall -arch=i386 ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@D@Z(ptr long) basic_istream_char_putback +@ cdecl -arch=win64 ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@D@Z(ptr long) basic_istream_char_putback +@ cdecl -arch=arm ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@G@Z(ptr long) basic_istream_wchar_putback +@ thiscall -arch=i386 ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@G@Z(ptr long) basic_istream_wchar_putback +@ cdecl -arch=win64 ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@G@Z(ptr long) basic_istream_wchar_putback +@ cdecl -arch=arm ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@_W@Z(ptr long) basic_istream_wchar_putback +@ thiscall -arch=i386 ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_W@Z(ptr long) basic_istream_wchar_putback +@ cdecl -arch=win64 ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_W@Z(ptr long) basic_istream_wchar_putback +@ cdecl -arch=arm ?pword@ios_base@std@@QAAAAPAXH@Z(ptr long) ios_base_pword +@ thiscall -arch=i386 ?pword@ios_base@std@@QAEAAPAXH@Z(ptr long) ios_base_pword +@ cdecl -arch=win64 ?pword@ios_base@std@@QEAAAEAPEAXH@Z(ptr long) ios_base_pword +@ cdecl -arch=arm ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PAV32@@Z(ptr ptr) basic_ios_char_rdbuf_set +@ thiscall -arch=i386 ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PAV32@@Z(ptr ptr) basic_ios_char_rdbuf_set +@ cdecl -arch=win64 ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PEAV32@@Z(ptr ptr) basic_ios_char_rdbuf_set +@ cdecl -arch=arm ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QBAPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ(ptr) basic_ios_char_rdbuf_get +@ thiscall -arch=i386 ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ(ptr) basic_ios_char_rdbuf_get +@ cdecl -arch=win64 ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ(ptr) basic_ios_char_rdbuf_get +@ cdecl -arch=arm ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PAV32@@Z(ptr ptr) basic_ios_wchar_rdbuf_set +@ thiscall -arch=i386 ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PAV32@@Z(ptr ptr) basic_ios_wchar_rdbuf_set +@ cdecl -arch=win64 ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PEAV32@@Z(ptr ptr) basic_ios_wchar_rdbuf_set +@ cdecl -arch=arm ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QBAPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ(ptr) basic_ios_wchar_rdbuf_get +@ thiscall -arch=i386 ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ(ptr) basic_ios_wchar_rdbuf_get +@ cdecl -arch=win64 ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ(ptr) basic_ios_wchar_rdbuf_get +@ cdecl -arch=arm ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PAV32@@Z(ptr ptr) basic_ios_wchar_rdbuf_set +@ thiscall -arch=i386 ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PAV32@@Z(ptr ptr) basic_ios_wchar_rdbuf_set +@ cdecl -arch=win64 ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PEAV32@@Z(ptr ptr) basic_ios_wchar_rdbuf_set +@ cdecl -arch=arm ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBAPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ(ptr) basic_ios_wchar_rdbuf_get +@ thiscall -arch=i386 ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ(ptr) basic_ios_wchar_rdbuf_get +@ cdecl -arch=win64 ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ(ptr) basic_ios_wchar_rdbuf_get +@ cdecl -arch=arm ?rdstate@ios_base@std@@QBAHXZ(ptr) ios_base_rdstate +@ thiscall -arch=i386 ?rdstate@ios_base@std@@QBEHXZ(ptr) ios_base_rdstate +@ cdecl -arch=win64 ?rdstate@ios_base@std@@QEBAHXZ(ptr) ios_base_rdstate +@ cdecl -arch=arm ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@PAD_J@Z(ptr ptr int64) basic_istream_char_read +@ thiscall -arch=i386 ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PAD_J@Z(ptr ptr int64) basic_istream_char_read +@ cdecl -arch=win64 ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z(ptr ptr long) basic_istream_char_read +@ cdecl -arch=arm ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@PAG_J@Z(ptr ptr int64) basic_istream_wchar_read +@ thiscall -arch=i386 ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAG_J@Z(ptr ptr int64) basic_istream_wchar_read +@ cdecl -arch=win64 ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z(ptr ptr long) basic_istream_wchar_read +@ cdecl -arch=arm ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@PA_W_J@Z(ptr ptr int64) basic_istream_wchar_read +@ thiscall -arch=i386 ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_W_J@Z(ptr ptr int64) basic_istream_wchar_read +@ cdecl -arch=win64 ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z(ptr ptr long) basic_istream_wchar_read +@ cdecl -ret64 -arch=arm ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QAA_JPAD_J@Z(ptr ptr int64) basic_istream_char_readsome +@ thiscall -ret64 -arch=i386 ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_JPAD_J@Z(ptr ptr int64) basic_istream_char_readsome +@ cdecl -arch=win64 ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_J@Z(ptr ptr long) basic_istream_char_readsome +@ cdecl -ret64 -arch=arm ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QAA_JPAG_J@Z(ptr ptr int64) basic_istream_wchar_readsome +@ thiscall -ret64 -arch=i386 ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_JPAG_J@Z(ptr ptr int64) basic_istream_wchar_readsome +@ cdecl -arch=win64 ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_J@Z(ptr ptr long) basic_istream_wchar_readsome +@ cdecl -ret64 -arch=arm ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAA_JPA_W_J@Z(ptr ptr int64) basic_istream_wchar_readsome +@ thiscall -ret64 -arch=i386 ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_JPA_W_J@Z(ptr ptr int64) basic_istream_wchar_readsome +@ cdecl -arch=win64 ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_J@Z(ptr ptr long) basic_istream_wchar_readsome +@ cdecl -arch=arm ?register_callback@ios_base@std@@QAAXP6AXW4event@12@AAV12@H@ZH@Z(ptr ptr long) ios_base_register_callback +@ thiscall -arch=i386 ?register_callback@ios_base@std@@QAEXP6AXW4event@12@AAV12@H@ZH@Z(ptr ptr long) ios_base_register_callback +@ cdecl -arch=win64 ?register_callback@ios_base@std@@QEAAXP6AXW4event@12@AEAV12@H@ZH@Z(ptr ptr long) ios_base_register_callback +@ cdecl ?resetiosflags@std@@YA?AU?$_Smanip@H@1@H@Z(ptr long) resetiosflags +@ cdecl -arch=arm ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAHXZ(ptr) basic_streambuf_char_sbumpc +@ thiscall -arch=i386 ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ(ptr) basic_streambuf_char_sbumpc +@ cdecl -arch=win64 ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ(ptr) basic_streambuf_char_sbumpc +@ cdecl -arch=arm ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAGXZ(ptr) basic_streambuf_wchar_sbumpc +@ thiscall -arch=i386 ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ(ptr) basic_streambuf_wchar_sbumpc +@ cdecl -arch=win64 ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ(ptr) basic_streambuf_wchar_sbumpc +@ cdecl -arch=arm ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAGXZ(ptr) basic_streambuf_wchar_sbumpc +@ thiscall -arch=i386 ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ(ptr) basic_streambuf_wchar_sbumpc +@ cdecl -arch=win64 ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ(ptr) basic_streambuf_wchar_sbumpc +@ cdecl -arch=arm ?scan_is@?$ctype@D@std@@QBAPBDFPBD0@Z(ptr long ptr ptr) ctype_char_scan_is +@ thiscall -arch=i386 ?scan_is@?$ctype@D@std@@QBEPBDFPBD0@Z(ptr long ptr ptr) ctype_char_scan_is +@ cdecl -arch=win64 ?scan_is@?$ctype@D@std@@QEBAPEBDFPEBD0@Z(ptr long ptr ptr) ctype_char_scan_is +@ cdecl -arch=arm ?scan_is@?$ctype@G@std@@QBAPBGFPBG0@Z(ptr long ptr ptr) ctype_wchar_scan_is +@ thiscall -arch=i386 ?scan_is@?$ctype@G@std@@QBEPBGFPBG0@Z(ptr long ptr ptr) ctype_wchar_scan_is +@ cdecl -arch=win64 ?scan_is@?$ctype@G@std@@QEBAPEBGFPEBG0@Z(ptr long ptr ptr) ctype_wchar_scan_is +@ cdecl -arch=arm ?scan_is@?$ctype@_W@std@@QBAPB_WFPB_W0@Z(ptr long ptr ptr) ctype_wchar_scan_is +@ thiscall -arch=i386 ?scan_is@?$ctype@_W@std@@QBEPB_WFPB_W0@Z(ptr long ptr ptr) ctype_wchar_scan_is +@ cdecl -arch=win64 ?scan_is@?$ctype@_W@std@@QEBAPEB_WFPEB_W0@Z(ptr long ptr ptr) ctype_wchar_scan_is +@ cdecl -arch=arm ?scan_not@?$ctype@D@std@@QBAPBDFPBD0@Z(ptr long ptr ptr) ctype_char_scan_not +@ thiscall -arch=i386 ?scan_not@?$ctype@D@std@@QBEPBDFPBD0@Z(ptr long ptr ptr) ctype_char_scan_not +@ cdecl -arch=win64 ?scan_not@?$ctype@D@std@@QEBAPEBDFPEBD0@Z(ptr long ptr ptr) ctype_char_scan_not +@ cdecl -arch=arm ?scan_not@?$ctype@G@std@@QBAPBGFPBG0@Z(ptr long ptr ptr) ctype_wchar_scan_not +@ thiscall -arch=i386 ?scan_not@?$ctype@G@std@@QBEPBGFPBG0@Z(ptr long ptr ptr) ctype_wchar_scan_not +@ cdecl -arch=win64 ?scan_not@?$ctype@G@std@@QEBAPEBGFPEBG0@Z(ptr long ptr ptr) ctype_wchar_scan_not +@ cdecl -arch=arm ?scan_not@?$ctype@_W@std@@QBAPB_WFPB_W0@Z(ptr long ptr ptr) ctype_wchar_scan_not +@ thiscall -arch=i386 ?scan_not@?$ctype@_W@std@@QBEPB_WFPB_W0@Z(ptr long ptr ptr) ctype_wchar_scan_not +@ cdecl -arch=win64 ?scan_not@?$ctype@_W@std@@QEBAPEB_WFPEB_W0@Z(ptr long ptr ptr) ctype_wchar_scan_not +@ cdecl -arch=arm ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_istream_char_seekg_fpos +@ thiscall -arch=i386 ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_istream_char_seekg_fpos +@ cdecl -arch=win64 ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z(ptr ptr) basic_istream_char_seekg_fpos +@ cdecl -arch=arm ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@_JH@Z(ptr int64 long) basic_istream_char_seekg +@ thiscall -arch=i386 ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@_JH@Z(ptr int64 long) basic_istream_char_seekg +@ cdecl -arch=win64 ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z(ptr long long) basic_istream_char_seekg +@ cdecl -arch=arm ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_istream_wchar_seekg_fpos +@ thiscall -arch=i386 ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_istream_wchar_seekg_fpos +@ cdecl -arch=win64 ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z(ptr ptr) basic_istream_wchar_seekg_fpos +@ cdecl -arch=arm ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@_JH@Z(ptr int64 long) basic_istream_wchar_seekg +@ thiscall -arch=i386 ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@_JH@Z(ptr int64 long) basic_istream_wchar_seekg +@ cdecl -arch=win64 ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JH@Z(ptr long long) basic_istream_wchar_seekg +@ cdecl -arch=arm ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_istream_wchar_seekg_fpos +@ thiscall -arch=i386 ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_istream_wchar_seekg_fpos +@ cdecl -arch=win64 ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z(ptr ptr) basic_istream_wchar_seekg_fpos +@ cdecl -arch=arm ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@_JH@Z(ptr int64 long) basic_istream_wchar_seekg +@ thiscall -arch=i386 ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_JH@Z(ptr int64 long) basic_istream_wchar_seekg +@ cdecl -arch=win64 ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JH@Z(ptr long long) basic_istream_wchar_seekg +@ cdecl -arch=arm ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAA?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_char_seekoff +@ thiscall -arch=i386 ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_char_seekoff +@ cdecl -arch=win64 ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z(ptr ptr long long long) basic_streambuf_char_seekoff +@ cdecl -arch=arm ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAA?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_wchar_seekoff +@ thiscall -arch=i386 ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_wchar_seekoff +@ cdecl -arch=win64 ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z(ptr ptr long long long) basic_streambuf_wchar_seekoff +@ cdecl -arch=arm ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAA?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_wchar_seekoff +@ thiscall -arch=i386 ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@_JHH@Z(ptr ptr int64 long long) basic_streambuf_wchar_seekoff +@ cdecl -arch=win64 ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z(ptr ptr long long long) basic_streambuf_wchar_seekoff +@ cdecl -arch=arm ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_ostream_char_seekp_fpos +@ thiscall -arch=i386 ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_ostream_char_seekp_fpos +@ cdecl -arch=win64 ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z(ptr ptr) basic_ostream_char_seekp_fpos +@ cdecl -arch=arm ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV12@_JH@Z(ptr int64 long) basic_ostream_char_seekp +@ thiscall -arch=i386 ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@_JH@Z(ptr int64 long) basic_ostream_char_seekp +@ cdecl -arch=win64 ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z(ptr long long) basic_ostream_char_seekp +@ cdecl -arch=arm ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_ostream_wchar_seekp_fpos +@ thiscall -arch=i386 ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_ostream_wchar_seekp_fpos +@ cdecl -arch=win64 ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z(ptr ptr) basic_ostream_wchar_seekp_fpos +@ cdecl -arch=arm ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV12@_JH@Z(ptr int64 long) basic_ostream_wchar_seekp +@ thiscall -arch=i386 ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@_JH@Z(ptr int64 long) basic_ostream_wchar_seekp +@ cdecl -arch=win64 ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JH@Z(ptr long long) basic_ostream_wchar_seekp +@ cdecl -arch=arm ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_ostream_wchar_seekp_fpos +@ thiscall -arch=i386 ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z(ptr long long int64 long long) basic_ostream_wchar_seekp_fpos +@ cdecl -arch=win64 ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z(ptr ptr) basic_ostream_wchar_seekp_fpos +@ cdecl -arch=arm ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@_JH@Z(ptr int64 long) basic_ostream_wchar_seekp +@ thiscall -arch=i386 ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_JH@Z(ptr int64 long) basic_ostream_wchar_seekp +@ cdecl -arch=win64 ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JH@Z(ptr long long) basic_ostream_wchar_seekp +@ cdecl -arch=arm ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAA?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_char_seekpos +@ thiscall -arch=i386 ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_char_seekpos +@ cdecl -arch=win64 ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z(ptr ptr ptr long) basic_streambuf_char_seekpos +@ cdecl -arch=arm ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAA?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_seekpos +@ thiscall -arch=i386 ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_seekpos +@ cdecl -arch=win64 ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z(ptr ptr ptr long) basic_streambuf_wchar_seekpos +@ cdecl -arch=arm ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAA?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_seekpos +@ thiscall -arch=i386 ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z(ptr ptr long long int64 long long long) basic_streambuf_wchar_seekpos +@ cdecl -arch=win64 ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z(ptr ptr ptr long) basic_streambuf_wchar_seekpos +@ cdecl ?set_new_handler@std@@YAP6AXXZP6AXXZ@Z(ptr) set_new_handler +@ stub -arch=arm ?set_rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAXPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z +@ stub -arch=i386 ?set_rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z +@ stub -arch=win64 ?set_rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z +@ stub -arch=arm ?set_rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAXPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z +@ stub -arch=i386 ?set_rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z +@ stub -arch=win64 ?set_rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z +@ stub -arch=arm ?set_rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAXPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z +@ stub -arch=i386 ?set_rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z +@ stub -arch=win64 ?set_rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z +@ cdecl ?setbase@std@@YA?AU?$_Smanip@H@1@H@Z(ptr long) setbase +@ cdecl -arch=arm ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAAPAV12@PAD_J@Z(ptr ptr int64) basic_streambuf_char_setbuf +@ thiscall -arch=i386 ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEPAV12@PAD_J@Z(ptr ptr int64) basic_streambuf_char_setbuf +@ cdecl -arch=win64 ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAPEAV12@PEAD_J@Z(ptr ptr long) basic_streambuf_char_setbuf +@ cdecl -arch=arm ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAAPAV12@PAG_J@Z(ptr ptr int64) basic_streambuf_wchar_setbuf +@ thiscall -arch=i386 ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEPAV12@PAG_J@Z(ptr ptr int64) basic_streambuf_wchar_setbuf +@ cdecl -arch=win64 ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAPEAV12@PEAG_J@Z(ptr ptr long) basic_streambuf_wchar_setbuf +@ cdecl -arch=arm ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAAPAV12@PA_W_J@Z(ptr ptr int64) basic_streambuf_wchar_setbuf +@ thiscall -arch=i386 ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEPAV12@PA_W_J@Z(ptr ptr int64) basic_streambuf_wchar_setbuf +@ cdecl -arch=win64 ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAPEAV12@PEA_W_J@Z(ptr ptr long) basic_streambuf_wchar_setbuf +@ cdecl -arch=arm ?setf@ios_base@std@@QAAHH@Z(ptr long) ios_base_setf +@ thiscall -arch=i386 ?setf@ios_base@std@@QAEHH@Z(ptr long) ios_base_setf +@ cdecl -arch=win64 ?setf@ios_base@std@@QEAAHH@Z(ptr long) ios_base_setf +@ cdecl -arch=arm ?setf@ios_base@std@@QAAHHH@Z(ptr long long) ios_base_setf_mask +@ thiscall -arch=i386 ?setf@ios_base@std@@QAEHHH@Z(ptr long long) ios_base_setf_mask +@ cdecl -arch=win64 ?setf@ios_base@std@@QEAAHHH@Z(ptr long long) ios_base_setf_mask +@ cdecl -arch=arm ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAXPAD00@Z(ptr ptr ptr ptr) basic_streambuf_char_setg +@ thiscall -arch=i386 ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD00@Z(ptr ptr ptr ptr) basic_streambuf_char_setg +@ cdecl -arch=win64 ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD00@Z(ptr ptr ptr ptr) basic_streambuf_char_setg +@ cdecl -arch=arm ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAXPAG00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setg +@ thiscall -arch=i386 ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setg +@ cdecl -arch=win64 ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setg +@ cdecl -arch=arm ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAXPA_W00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setg +@ thiscall -arch=i386 ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setg +@ cdecl -arch=win64 ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setg +@ cdecl ?setiosflags@std@@YA?AU?$_Smanip@H@1@H@Z(ptr long) setiosflags +@ cdecl -arch=arm ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAXPAD00@Z(ptr ptr ptr ptr) basic_streambuf_char_setp_next +@ thiscall -arch=i386 ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD00@Z(ptr ptr ptr ptr) basic_streambuf_char_setp_next +@ cdecl -arch=win64 ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD00@Z(ptr ptr ptr ptr) basic_streambuf_char_setp_next +@ cdecl -arch=arm ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAXPAD0@Z(ptr ptr ptr) basic_streambuf_char_setp +@ thiscall -arch=i386 ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD0@Z(ptr ptr ptr) basic_streambuf_char_setp +@ cdecl -arch=win64 ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD0@Z(ptr ptr ptr) basic_streambuf_char_setp +@ cdecl -arch=arm ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAXPAG00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setp_next +@ thiscall -arch=i386 ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setp_next +@ cdecl -arch=win64 ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setp_next +@ cdecl -arch=arm ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAXPAG0@Z(ptr ptr ptr) basic_streambuf_wchar_setp +@ thiscall -arch=i386 ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG0@Z(ptr ptr ptr) basic_streambuf_wchar_setp +@ cdecl -arch=win64 ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG0@Z(ptr ptr ptr) basic_streambuf_wchar_setp +@ cdecl -arch=arm ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAXPA_W00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setp_next +@ thiscall -arch=i386 ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setp_next +@ cdecl -arch=win64 ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W00@Z(ptr ptr ptr ptr) basic_streambuf_wchar_setp_next +@ cdecl -arch=arm ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAXPA_W0@Z(ptr ptr ptr) basic_streambuf_wchar_setp +@ thiscall -arch=i386 ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W0@Z(ptr ptr ptr) basic_streambuf_wchar_setp +@ cdecl -arch=win64 ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W0@Z(ptr ptr ptr) basic_streambuf_wchar_setp +@ cdecl ?setprecision@std@@YA?AU?$_Smanip@_J@1@_J@Z(ptr int64) setprecision +@ cdecl -arch=arm ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAXH_N@Z(ptr long long) basic_ios_char_setstate_reraise +@ thiscall -arch=i386 ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXH_N@Z(ptr long long) basic_ios_char_setstate_reraise +@ cdecl -arch=win64 ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXH_N@Z(ptr long long) basic_ios_char_setstate_reraise +@ cdecl -arch=arm ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAXI@Z(ptr long) basic_ios_char_setstate +@ thiscall -arch=i386 ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXI@Z(ptr long) basic_ios_char_setstate +@ cdecl -arch=win64 ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXI@Z(ptr long) basic_ios_char_setstate +@ cdecl -arch=arm ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAXH_N@Z(ptr long long) basic_ios_wchar_setstate_reraise +@ thiscall -arch=i386 ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXH_N@Z(ptr long long) basic_ios_wchar_setstate_reraise +@ cdecl -arch=win64 ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXH_N@Z(ptr long long) basic_ios_wchar_setstate_reraise +@ cdecl -arch=arm ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAXI@Z(ptr long) basic_ios_wchar_setstate +@ thiscall -arch=i386 ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXI@Z(ptr long) basic_ios_wchar_setstate +@ cdecl -arch=win64 ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXI@Z(ptr long) basic_ios_wchar_setstate +@ cdecl -arch=arm ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAXH_N@Z(ptr long long) basic_ios_wchar_setstate_reraise +@ thiscall -arch=i386 ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXH_N@Z(ptr long long) basic_ios_wchar_setstate_reraise +@ cdecl -arch=win64 ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXH_N@Z(ptr long long) basic_ios_wchar_setstate_reraise +@ cdecl -arch=arm ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAXI@Z(ptr long) basic_ios_wchar_setstate +@ thiscall -arch=i386 ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXI@Z(ptr long) basic_ios_wchar_setstate +@ cdecl -arch=win64 ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXI@Z(ptr long) basic_ios_wchar_setstate +@ cdecl -arch=arm ?setstate@ios_base@std@@QAAXH@Z(ptr long) ios_base_setstate +@ thiscall -arch=i386 ?setstate@ios_base@std@@QAEXH@Z(ptr long) ios_base_setstate +@ cdecl -arch=win64 ?setstate@ios_base@std@@QEAAXH@Z(ptr long) ios_base_setstate +@ cdecl -arch=arm ?setstate@ios_base@std@@QAAXH_N@Z(ptr long long) ios_base_setstate_reraise +@ thiscall -arch=i386 ?setstate@ios_base@std@@QAEXH_N@Z(ptr long long) ios_base_setstate_reraise +@ cdecl -arch=win64 ?setstate@ios_base@std@@QEAAXH_N@Z(ptr long long) ios_base_setstate_reraise +@ cdecl -arch=arm ?setstate@ios_base@std@@QAAXI@Z(ptr long) ios_base_setstate_unsigned +@ thiscall -arch=i386 ?setstate@ios_base@std@@QAEXI@Z(ptr long) ios_base_setstate_unsigned +@ cdecl -arch=win64 ?setstate@ios_base@std@@QEAAXI@Z(ptr long) ios_base_setstate_unsigned +@ cdecl ?setw@std@@YA?AU?$_Smanip@_J@1@_J@Z(ptr int64) setw +@ cdecl -arch=arm ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAHXZ(ptr) basic_streambuf_char_sgetc +@ thiscall -arch=i386 ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ(ptr) basic_streambuf_char_sgetc +@ cdecl -arch=win64 ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ(ptr) basic_streambuf_char_sgetc +@ cdecl -arch=arm ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAGXZ(ptr) basic_streambuf_wchar_sgetc +@ thiscall -arch=i386 ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ(ptr) basic_streambuf_wchar_sgetc +@ cdecl -arch=win64 ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ(ptr) basic_streambuf_wchar_sgetc +@ cdecl -arch=arm ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAGXZ(ptr) basic_streambuf_wchar_sgetc +@ thiscall -arch=i386 ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ(ptr) basic_streambuf_wchar_sgetc +@ cdecl -arch=win64 ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ(ptr) basic_streambuf_wchar_sgetc +@ cdecl -ret64 -arch=arm ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAA_JPAD_J@Z(ptr ptr int64) basic_streambuf_char_sgetn +@ thiscall -ret64 -arch=i386 ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE_JPAD_J@Z(ptr ptr int64) basic_streambuf_char_sgetn +@ cdecl -arch=win64 ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_J@Z(ptr ptr long) basic_streambuf_char_sgetn +@ cdecl -ret64 -arch=arm ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAA_JPAG_J@Z(ptr ptr int64) basic_streambuf_wchar_sgetn +@ thiscall -ret64 -arch=i386 ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE_JPAG_J@Z(ptr ptr int64) basic_streambuf_wchar_sgetn +@ cdecl -arch=win64 ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_J@Z(ptr ptr long) basic_streambuf_wchar_sgetn +@ cdecl -ret64 -arch=arm ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAA_JPA_W_J@Z(ptr ptr int64) basic_streambuf_wchar_sgetn +@ thiscall -ret64 -arch=i386 ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE_JPA_W_J@Z(ptr ptr int64) basic_streambuf_wchar_sgetn +@ cdecl -arch=win64 ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_J@Z(ptr ptr long) basic_streambuf_wchar_sgetn +@ cdecl -ret64 -arch=arm ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAA_JXZ(ptr) basic_streambuf_char_showmanyc +@ thiscall -ret64 -arch=i386 ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE_JXZ(ptr) basic_streambuf_char_showmanyc +@ cdecl -arch=win64 ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JXZ(ptr) basic_streambuf_char_showmanyc +@ cdecl -ret64 -arch=arm ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAA_JXZ(ptr) basic_streambuf_wchar_showmanyc +@ thiscall -ret64 -arch=i386 ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE_JXZ(ptr) basic_streambuf_wchar_showmanyc +@ cdecl -arch=win64 ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JXZ(ptr) basic_streambuf_wchar_showmanyc +@ cdecl -ret64 -arch=arm ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAA_JXZ(ptr) basic_streambuf_wchar_showmanyc +@ thiscall -ret64 -arch=i386 ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE_JXZ(ptr) basic_streambuf_wchar_showmanyc +@ cdecl -arch=win64 ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JXZ(ptr) basic_streambuf_wchar_showmanyc +@ cdecl -arch=arm ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAHXZ(ptr) basic_streambuf_char_snextc +@ thiscall -arch=i386 ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ(ptr) basic_streambuf_char_snextc +@ cdecl -arch=win64 ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ(ptr) basic_streambuf_char_snextc +@ cdecl -arch=arm ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAGXZ(ptr) basic_streambuf_wchar_snextc +@ thiscall -arch=i386 ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ(ptr) basic_streambuf_wchar_snextc +@ cdecl -arch=win64 ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ(ptr) basic_streambuf_wchar_snextc +@ cdecl -arch=arm ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAGXZ(ptr) basic_streambuf_wchar_snextc +@ thiscall -arch=i386 ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ(ptr) basic_streambuf_wchar_snextc +@ cdecl -arch=win64 ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ(ptr) basic_streambuf_wchar_snextc +@ cdecl -arch=arm ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAHD@Z(ptr long) basic_streambuf_char_sputbackc +@ thiscall -arch=i386 ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHD@Z(ptr long) basic_streambuf_char_sputbackc +@ cdecl -arch=win64 ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHD@Z(ptr long) basic_streambuf_char_sputbackc +@ cdecl -arch=arm ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAGG@Z(ptr long) basic_streambuf_wchar_sputbackc +@ thiscall -arch=i386 ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGG@Z(ptr long) basic_streambuf_wchar_sputbackc +@ cdecl -arch=win64 ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGG@Z(ptr long) basic_streambuf_wchar_sputbackc +@ cdecl -arch=arm ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAG_W@Z(ptr long) basic_streambuf_wchar_sputbackc +@ thiscall -arch=i386 ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEG_W@Z(ptr long) basic_streambuf_wchar_sputbackc +@ cdecl -arch=win64 ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAG_W@Z(ptr long) basic_streambuf_wchar_sputbackc +@ cdecl -arch=arm ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAHD@Z(ptr long) basic_streambuf_char_sputc +@ thiscall -arch=i386 ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHD@Z(ptr long) basic_streambuf_char_sputc +@ cdecl -arch=win64 ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHD@Z(ptr long) basic_streambuf_char_sputc +@ cdecl -arch=arm ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAGG@Z(ptr long) basic_streambuf_wchar_sputc +@ thiscall -arch=i386 ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGG@Z(ptr long) basic_streambuf_wchar_sputc +@ cdecl -arch=win64 ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGG@Z(ptr long) basic_streambuf_wchar_sputc +@ cdecl -arch=arm ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAG_W@Z(ptr long) basic_streambuf_wchar_sputc +@ thiscall -arch=i386 ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEG_W@Z(ptr long) basic_streambuf_wchar_sputc +@ cdecl -arch=win64 ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAG_W@Z(ptr long) basic_streambuf_wchar_sputc +@ cdecl -ret64 -arch=arm ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAA_JPBD_J@Z(ptr str int64) basic_streambuf_char_sputn +@ thiscall -ret64 -arch=i386 ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE_JPBD_J@Z(ptr str int64) basic_streambuf_char_sputn +@ cdecl -arch=win64 ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEBD_J@Z(ptr str long) basic_streambuf_char_sputn +@ cdecl -ret64 -arch=arm ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAA_JPBG_J@Z(ptr ptr int64) basic_streambuf_wchar_sputn +@ thiscall -ret64 -arch=i386 ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE_JPBG_J@Z(ptr ptr int64) basic_streambuf_wchar_sputn +@ cdecl -arch=win64 ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEBG_J@Z(ptr ptr long) basic_streambuf_wchar_sputn +@ cdecl -ret64 -arch=arm ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAA_JPB_W_J@Z(ptr wstr int64) basic_streambuf_wchar_sputn +@ thiscall -ret64 -arch=i386 ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE_JPB_W_J@Z(ptr wstr int64) basic_streambuf_wchar_sputn +@ cdecl -arch=win64 ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEB_W_J@Z(ptr ptr long) basic_streambuf_wchar_sputn +@ stub -arch=arm ?start@agent@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?start@agent@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?start@agent@Concurrency@@QEAA_NXZ +@ stub -arch=arm ?status@agent@Concurrency@@QAA?AW4agent_status@2@XZ +@ stub -arch=i386 ?status@agent@Concurrency@@QAE?AW4agent_status@2@XZ +@ stub -arch=win64 ?status@agent@Concurrency@@QEAA?AW4agent_status@2@XZ +@ stub -arch=arm ?status_port@agent@Concurrency@@QAAPAV?$ISource@W4agent_status@Concurrency@@@2@XZ +@ stub -arch=i386 ?status_port@agent@Concurrency@@QAEPAV?$ISource@W4agent_status@Concurrency@@@2@XZ +@ stub -arch=win64 ?status_port@agent@Concurrency@@QEAAPEAV?$ISource@W4agent_status@Concurrency@@@2@XZ +@ cdecl -arch=arm ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAXXZ(ptr) basic_streambuf_char_stossc +@ thiscall -arch=i386 ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ(ptr) basic_streambuf_char_stossc +@ cdecl -arch=win64 ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ(ptr) basic_streambuf_char_stossc +@ cdecl -arch=arm ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAXXZ(ptr) basic_streambuf_wchar_stossc +@ thiscall -arch=i386 ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ(ptr) basic_streambuf_wchar_stossc +@ cdecl -arch=win64 ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ(ptr) basic_streambuf_wchar_stossc +@ cdecl -arch=arm ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAXXZ(ptr) basic_streambuf_wchar_stossc +@ thiscall -arch=i386 ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ(ptr) basic_streambuf_wchar_stossc +@ cdecl -arch=win64 ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ(ptr) basic_streambuf_wchar_stossc +@ cdecl -arch=arm ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAAHXZ(ptr) basic_streambuf_char_sungetc +@ thiscall -arch=i386 ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ(ptr) basic_streambuf_char_sungetc +@ cdecl -arch=win64 ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ(ptr) basic_streambuf_char_sungetc +@ cdecl -arch=arm ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAAGXZ(ptr) basic_streambuf_wchar_sungetc +@ thiscall -arch=i386 ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ(ptr) basic_streambuf_wchar_sungetc +@ cdecl -arch=win64 ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ(ptr) basic_streambuf_wchar_sungetc +@ cdecl -arch=arm ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAAGXZ(ptr) basic_streambuf_wchar_sungetc +@ thiscall -arch=i386 ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ(ptr) basic_streambuf_wchar_sungetc +@ cdecl -arch=win64 ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ(ptr) basic_streambuf_wchar_sungetc +@ cdecl -arch=arm ?swap@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAXAAV12@@Z(ptr ptr) basic_ios_char_swap +@ thiscall -arch=i386 ?swap@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXAAV12@@Z(ptr ptr) basic_ios_char_swap +@ cdecl -arch=win64 ?swap@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXAEAV12@@Z(ptr ptr) basic_ios_char_swap +@ cdecl -arch=arm ?swap@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAXAAV12@@Z(ptr ptr) basic_ios_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXAAV12@@Z(ptr ptr) basic_ios_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXAEAV12@@Z(ptr ptr) basic_ios_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAXAAV12@@Z(ptr ptr) basic_ios_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXAAV12@@Z(ptr ptr) basic_ios_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXAEAV12@@Z(ptr ptr) basic_ios_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_iostream@DU?$char_traits@D@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_iostream_char_swap +@ thiscall -arch=i386 ?swap@?$basic_iostream@DU?$char_traits@D@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_iostream_char_swap +@ cdecl -arch=win64 ?swap@?$basic_iostream@DU?$char_traits@D@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_iostream_char_swap +@ cdecl -arch=arm ?swap@?$basic_iostream@GU?$char_traits@G@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_iostream_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_iostream@GU?$char_traits@G@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_iostream_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_iostream@GU?$char_traits@G@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_iostream_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_iostream_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_iostream_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_iostream@_WU?$char_traits@_W@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_iostream_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_istream@DU?$char_traits@D@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_istream_char_swap +@ thiscall -arch=i386 ?swap@?$basic_istream@DU?$char_traits@D@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_istream_char_swap +@ cdecl -arch=win64 ?swap@?$basic_istream@DU?$char_traits@D@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_istream_char_swap +@ cdecl -arch=arm ?swap@?$basic_istream@GU?$char_traits@G@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_istream_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_istream@GU?$char_traits@G@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_istream_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_istream@GU?$char_traits@G@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_istream_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_istream@_WU?$char_traits@_W@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_istream_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_istream@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_istream_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_istream@_WU?$char_traits@_W@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_istream_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_ostream@DU?$char_traits@D@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_ostream_char_swap +@ thiscall -arch=i386 ?swap@?$basic_ostream@DU?$char_traits@D@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_ostream_char_swap +@ cdecl -arch=win64 ?swap@?$basic_ostream@DU?$char_traits@D@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_ostream_char_swap +@ cdecl -arch=arm ?swap@?$basic_ostream@GU?$char_traits@G@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_ostream_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_ostream@GU?$char_traits@G@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_ostream_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_ostream@GU?$char_traits@G@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_ostream_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_ostream_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_ostream_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_ostream_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_streambuf_char_swap +@ thiscall -arch=i386 ?swap@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_streambuf_char_swap +@ cdecl -arch=win64 ?swap@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_streambuf_char_swap +@ cdecl -arch=arm ?swap@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_streambuf_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_streambuf_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_streambuf_wchar_swap +@ cdecl -arch=arm ?swap@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAAXAAV12@@Z(ptr ptr) basic_streambuf_wchar_swap +@ thiscall -arch=i386 ?swap@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z(ptr ptr) basic_streambuf_wchar_swap +@ cdecl -arch=win64 ?swap@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXAEAV12@@Z(ptr ptr) basic_streambuf_wchar_swap +@ cdecl -arch=arm ?swap@ios_base@std@@QAAXAAV12@@Z(ptr ptr) ios_base_swap +@ thiscall -arch=i386 ?swap@ios_base@std@@QAEXAAV12@@Z(ptr ptr) ios_base_swap +@ cdecl -arch=win64 ?swap@ios_base@std@@QEAAXAEAV12@@Z(ptr ptr) ios_base_swap +@ cdecl -arch=arm ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAHXZ(ptr) basic_istream_char_sync +@ thiscall -arch=i386 ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ(ptr) basic_istream_char_sync +@ cdecl -arch=win64 ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ(ptr) basic_istream_char_sync +@ cdecl -arch=arm ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAHXZ(ptr) basic_istream_wchar_sync +@ thiscall -arch=i386 ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHXZ(ptr) basic_istream_wchar_sync +@ cdecl -arch=win64 ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAHXZ(ptr) basic_istream_wchar_sync +@ cdecl -arch=arm ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAHXZ(ptr) basic_istream_wchar_sync +@ thiscall -arch=i386 ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHXZ(ptr) basic_istream_wchar_sync +@ cdecl -arch=win64 ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAHXZ(ptr) basic_istream_wchar_sync +@ cdecl -arch=arm ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAAHXZ(ptr) basic_streambuf_char_sync +@ thiscall -arch=i386 ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ(ptr) basic_streambuf_char_sync +@ cdecl -arch=win64 ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ(ptr) basic_streambuf_char_sync +@ cdecl -arch=arm ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAAHXZ(ptr) basic_streambuf_wchar_sync +@ thiscall -arch=i386 ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHXZ(ptr) basic_streambuf_wchar_sync +@ cdecl -arch=win64 ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAHXZ(ptr) basic_streambuf_wchar_sync +@ cdecl -arch=arm ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAAHXZ(ptr) basic_streambuf_wchar_sync +@ thiscall -arch=i386 ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ(ptr) basic_streambuf_wchar_sync +@ cdecl -arch=win64 ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAHXZ(ptr) basic_streambuf_wchar_sync +@ cdecl ?sync_with_stdio@ios_base@std@@SA_N_N@Z(long) ios_base_sync_with_stdio +@ stub -arch=arm ?table@?$ctype@D@std@@QBAPBFXZ +@ stub -arch=i386 ?table@?$ctype@D@std@@QBEPBFXZ +@ stub -arch=win64 ?table@?$ctype@D@std@@QEBAPEBFXZ +@ extern -arch=win32 ?table_size@?$ctype@D@std@@2IB ctype_char_table_size +@ extern -arch=win64 ?table_size@?$ctype@D@std@@2_KB ctype_char_table_size +@ cdecl -arch=arm ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAA?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_char_tellg +@ thiscall -arch=i386 ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_char_tellg +@ cdecl -arch=win64 ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_char_tellg +@ cdecl -arch=arm ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAA?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_wchar_tellg +@ thiscall -arch=i386 ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_wchar_tellg +@ cdecl -arch=win64 ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_wchar_tellg +@ cdecl -arch=arm ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAA?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_wchar_tellg +@ thiscall -arch=i386 ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_wchar_tellg +@ cdecl -arch=win64 ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@XZ(ptr ptr) basic_istream_wchar_tellg +@ cdecl -arch=arm ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAA?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_char_tellp +@ thiscall -arch=i386 ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_char_tellp +@ cdecl -arch=win64 ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_char_tellp +@ cdecl -arch=arm ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAA?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_wchar_tellp +@ thiscall -arch=i386 ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_wchar_tellp +@ cdecl -arch=win64 ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_wchar_tellp +@ cdecl -arch=arm ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAA?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_wchar_tellp +@ thiscall -arch=i386 ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_wchar_tellp +@ cdecl -arch=win64 ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@XZ(ptr ptr) basic_ostream_wchar_tellp +@ cdecl -arch=arm ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QAAPAV?$basic_ostream@DU?$char_traits@D@std@@@2@PAV32@@Z(ptr ptr) basic_ios_char_tie_set +@ thiscall -arch=i386 ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEPAV?$basic_ostream@DU?$char_traits@D@std@@@2@PAV32@@Z(ptr ptr) basic_ios_char_tie_set +@ cdecl -arch=win64 ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAPEAV?$basic_ostream@DU?$char_traits@D@std@@@2@PEAV32@@Z(ptr ptr) basic_ios_char_tie_set +@ cdecl -arch=arm ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QBAPAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ(ptr) basic_ios_char_tie_get +@ thiscall -arch=i386 ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ(ptr) basic_ios_char_tie_get +@ cdecl -arch=win64 ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ(ptr) basic_ios_char_tie_get +@ cdecl -arch=arm ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QAAPAV?$basic_ostream@GU?$char_traits@G@std@@@2@PAV32@@Z(ptr ptr) basic_ios_wchar_tie_set +@ thiscall -arch=i386 ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEPAV?$basic_ostream@GU?$char_traits@G@std@@@2@PAV32@@Z(ptr ptr) basic_ios_wchar_tie_set +@ cdecl -arch=win64 ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAPEAV?$basic_ostream@GU?$char_traits@G@std@@@2@PEAV32@@Z(ptr ptr) basic_ios_wchar_tie_set +@ cdecl -arch=arm ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QBAPAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ(ptr) basic_ios_wchar_tie_get +@ thiscall -arch=i386 ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ(ptr) basic_ios_wchar_tie_get +@ cdecl -arch=win64 ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ(ptr) basic_ios_wchar_tie_get +@ cdecl -arch=arm ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAAPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PAV32@@Z(ptr ptr) basic_ios_wchar_tie_set +@ thiscall -arch=i386 ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PAV32@@Z(ptr ptr) basic_ios_wchar_tie_set +@ cdecl -arch=win64 ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAPEAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PEAV32@@Z(ptr ptr) basic_ios_wchar_tie_set +@ cdecl -arch=arm ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBAPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ(ptr) basic_ios_wchar_tie_get +@ thiscall -arch=i386 ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ(ptr) basic_ios_wchar_tie_get +@ cdecl -arch=win64 ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ(ptr) basic_ios_wchar_tie_get +@ cdecl -arch=arm ?tolower@?$ctype@D@std@@QBADD@Z(ptr long) ctype_char_tolower_ch +@ thiscall -arch=i386 ?tolower@?$ctype@D@std@@QBEDD@Z(ptr long) ctype_char_tolower_ch +@ cdecl -arch=win64 ?tolower@?$ctype@D@std@@QEBADD@Z(ptr long) ctype_char_tolower_ch +@ cdecl -arch=arm ?tolower@?$ctype@D@std@@QBAPBDPADPBD@Z(ptr ptr ptr) ctype_char_tolower +@ thiscall -arch=i386 ?tolower@?$ctype@D@std@@QBEPBDPADPBD@Z(ptr ptr ptr) ctype_char_tolower +@ cdecl -arch=win64 ?tolower@?$ctype@D@std@@QEBAPEBDPEADPEBD@Z(ptr ptr ptr) ctype_char_tolower +@ cdecl -arch=arm ?tolower@?$ctype@G@std@@QBAGG@Z(ptr long) ctype_wchar_tolower_ch +@ thiscall -arch=i386 ?tolower@?$ctype@G@std@@QBEGG@Z(ptr long) ctype_wchar_tolower_ch +@ cdecl -arch=win64 ?tolower@?$ctype@G@std@@QEBAGG@Z(ptr long) ctype_wchar_tolower_ch +@ cdecl -arch=arm ?tolower@?$ctype@G@std@@QBAPBGPAGPBG@Z(ptr ptr ptr) ctype_wchar_tolower +@ thiscall -arch=i386 ?tolower@?$ctype@G@std@@QBEPBGPAGPBG@Z(ptr ptr ptr) ctype_wchar_tolower +@ cdecl -arch=win64 ?tolower@?$ctype@G@std@@QEBAPEBGPEAGPEBG@Z(ptr ptr ptr) ctype_wchar_tolower +@ cdecl -arch=arm ?tolower@?$ctype@_W@std@@QBAPB_WPA_WPB_W@Z(ptr ptr ptr) ctype_wchar_tolower +@ thiscall -arch=i386 ?tolower@?$ctype@_W@std@@QBEPB_WPA_WPB_W@Z(ptr ptr ptr) ctype_wchar_tolower +@ cdecl -arch=win64 ?tolower@?$ctype@_W@std@@QEBAPEB_WPEA_WPEB_W@Z(ptr ptr ptr) ctype_wchar_tolower +@ cdecl -arch=arm ?tolower@?$ctype@_W@std@@QBA_W_W@Z(ptr long) ctype_wchar_tolower_ch +@ thiscall -arch=i386 ?tolower@?$ctype@_W@std@@QBE_W_W@Z(ptr long) ctype_wchar_tolower_ch +@ cdecl -arch=win64 ?tolower@?$ctype@_W@std@@QEBA_W_W@Z(ptr long) ctype_wchar_tolower_ch +@ cdecl -arch=arm ?toupper@?$ctype@D@std@@QBADD@Z(ptr long) ctype_char_toupper_ch +@ thiscall -arch=i386 ?toupper@?$ctype@D@std@@QBEDD@Z(ptr long) ctype_char_toupper_ch +@ cdecl -arch=win64 ?toupper@?$ctype@D@std@@QEBADD@Z(ptr long) ctype_char_toupper_ch +@ cdecl -arch=arm ?toupper@?$ctype@D@std@@QBAPBDPADPBD@Z(ptr ptr ptr) ctype_char_toupper +@ thiscall -arch=i386 ?toupper@?$ctype@D@std@@QBEPBDPADPBD@Z(ptr ptr ptr) ctype_char_toupper +@ cdecl -arch=win64 ?toupper@?$ctype@D@std@@QEBAPEBDPEADPEBD@Z(ptr ptr ptr) ctype_char_toupper +@ cdecl -arch=arm ?toupper@?$ctype@G@std@@QBAGG@Z(ptr long) ctype_wchar_toupper_ch +@ thiscall -arch=i386 ?toupper@?$ctype@G@std@@QBEGG@Z(ptr long) ctype_wchar_toupper_ch +@ cdecl -arch=win64 ?toupper@?$ctype@G@std@@QEBAGG@Z(ptr long) ctype_wchar_toupper_ch +@ cdecl -arch=arm ?toupper@?$ctype@G@std@@QBAPBGPAGPBG@Z(ptr ptr ptr) ctype_wchar_toupper +@ thiscall -arch=i386 ?toupper@?$ctype@G@std@@QBEPBGPAGPBG@Z(ptr ptr ptr) ctype_wchar_toupper +@ cdecl -arch=win64 ?toupper@?$ctype@G@std@@QEBAPEBGPEAGPEBG@Z(ptr ptr ptr) ctype_wchar_toupper +@ cdecl -arch=arm ?toupper@?$ctype@_W@std@@QBAPB_WPA_WPB_W@Z(ptr ptr ptr) ctype_wchar_toupper +@ thiscall -arch=i386 ?toupper@?$ctype@_W@std@@QBEPB_WPA_WPB_W@Z(ptr ptr ptr) ctype_wchar_toupper +@ cdecl -arch=win64 ?toupper@?$ctype@_W@std@@QEBAPEB_WPEA_WPEB_W@Z(ptr ptr ptr) ctype_wchar_toupper +@ cdecl -arch=arm ?toupper@?$ctype@_W@std@@QBA_W_W@Z(ptr long) ctype_wchar_toupper_ch +@ thiscall -arch=i386 ?toupper@?$ctype@_W@std@@QBE_W_W@Z(ptr long) ctype_wchar_toupper_ch +@ cdecl -arch=win64 ?toupper@?$ctype@_W@std@@QEBA_W_W@Z(ptr long) ctype_wchar_toupper_ch +@ stub ?try_to_lock@std@@3Utry_to_lock_t@1@B +@ cdecl -arch=arm ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAAHXZ(ptr) basic_streambuf_char_uflow +@ thiscall -arch=i386 ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ(ptr) basic_streambuf_char_uflow +@ cdecl -arch=win64 ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ(ptr) basic_streambuf_char_uflow +@ cdecl -arch=arm ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAAGXZ(ptr) basic_streambuf_wchar_uflow +@ thiscall -arch=i386 ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGXZ(ptr) basic_streambuf_wchar_uflow +@ cdecl -arch=win64 ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGXZ(ptr) basic_streambuf_wchar_uflow +@ cdecl -arch=arm ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAAGXZ(ptr) basic_streambuf_wchar_uflow +@ thiscall -arch=i386 ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ(ptr) basic_streambuf_wchar_uflow +@ cdecl -arch=win64 ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ(ptr) basic_streambuf_wchar_uflow +@ cdecl ?uncaught_exception@std@@YA_NXZ() MSVCP__uncaught_exception +@ cdecl -arch=arm ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAAHXZ(ptr) basic_streambuf_char_underflow +@ thiscall -arch=i386 ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ(ptr) basic_streambuf_char_underflow +@ cdecl -arch=win64 ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ(ptr) basic_streambuf_char_underflow +@ cdecl -arch=arm ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAAGXZ(ptr) basic_streambuf_wchar_underflow +@ thiscall -arch=i386 ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGXZ(ptr) basic_streambuf_wchar_underflow +@ cdecl -arch=win64 ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGXZ(ptr) basic_streambuf_wchar_underflow +@ cdecl -arch=arm ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAAGXZ(ptr) basic_streambuf_wchar_underflow +@ thiscall -arch=i386 ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ(ptr) basic_streambuf_wchar_underflow +@ cdecl -arch=win64 ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ(ptr) basic_streambuf_wchar_underflow +@ cdecl -arch=arm ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV12@XZ(ptr) basic_istream_char_unget +@ thiscall -arch=i386 ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@XZ(ptr) basic_istream_char_unget +@ cdecl -arch=win64 ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@XZ(ptr) basic_istream_char_unget +@ cdecl -arch=arm ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QAAAAV12@XZ(ptr) basic_istream_wchar_unget +@ thiscall -arch=i386 ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@XZ(ptr) basic_istream_wchar_unget +@ cdecl -arch=win64 ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@XZ(ptr) basic_istream_wchar_unget +@ cdecl -arch=arm ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@XZ(ptr) basic_istream_wchar_unget +@ thiscall -arch=i386 ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@XZ(ptr) basic_istream_wchar_unget +@ cdecl -arch=win64 ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@XZ(ptr) basic_istream_wchar_unget +@ cdecl -arch=arm ?unsetf@ios_base@std@@QAAXH@Z(ptr long) ios_base_unsetf +@ thiscall -arch=i386 ?unsetf@ios_base@std@@QAEXH@Z(ptr long) ios_base_unsetf +@ cdecl -arch=win64 ?unsetf@ios_base@std@@QEAAXH@Z(ptr long) ios_base_unsetf +@ cdecl -arch=arm ?unshift@?$codecvt@DDH@std@@QBAHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_char_unshift +@ thiscall -arch=i386 ?unshift@?$codecvt@DDH@std@@QBEHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_char_unshift +@ cdecl -arch=win64 ?unshift@?$codecvt@DDH@std@@QEBAHAEAHPEAD1AEAPEAD@Z(ptr ptr ptr ptr ptr) codecvt_char_unshift +@ cdecl -arch=arm ?unshift@?$codecvt@GDH@std@@QBAHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_unshift +@ thiscall -arch=i386 ?unshift@?$codecvt@GDH@std@@QBEHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_unshift +@ cdecl -arch=win64 ?unshift@?$codecvt@GDH@std@@QEBAHAEAHPEAD1AEAPEAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_unshift +@ cdecl -arch=arm ?unshift@?$codecvt@_WDH@std@@QBAHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_unshift +@ thiscall -arch=i386 ?unshift@?$codecvt@_WDH@std@@QBEHAAHPAD1AAPAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_unshift +@ cdecl -arch=win64 ?unshift@?$codecvt@_WDH@std@@QEBAHAEAHPEAD1AEAPEAD@Z(ptr ptr ptr ptr ptr) codecvt_wchar_unshift +@ stub -arch=win32 ?wait@agent@Concurrency@@SA?AW4agent_status@2@PAV12@I@Z +@ stub -arch=win64 ?wait@agent@Concurrency@@SA?AW4agent_status@2@PEAV12@I@Z +@ stub -arch=win32 ?wait_for_all@agent@Concurrency@@SAXIPAPAV12@PAW4agent_status@2@I@Z +@ stub -arch=win64 ?wait_for_all@agent@Concurrency@@SAX_KPEAPEAV12@PEAW4agent_status@2@I@Z +@ stub -arch=win32 ?wait_for_one@agent@Concurrency@@SAXIPAPAV12@AAW4agent_status@2@AAII@Z +@ stub -arch=win64 ?wait_for_one@agent@Concurrency@@SAX_KPEAPEAV12@AEAW4agent_status@2@AEA_KI@Z +@ extern ?wcerr@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A ucerr +@ extern ?wcerr@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A wcerr +@ extern ?wcin@std@@3V?$basic_istream@GU?$char_traits@G@std@@@1@A ucin +@ extern ?wcin@std@@3V?$basic_istream@_WU?$char_traits@_W@std@@@1@A wcin +@ extern ?wclog@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A uclog +@ extern ?wclog@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A wclog +@ extern ?wcout@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A ucout +@ extern ?wcout@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A wcout +@ cdecl -arch=arm ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QBADD@Z(ptr long) basic_ios_char_widen +@ thiscall -arch=i386 ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDD@Z(ptr long) basic_ios_char_widen +@ cdecl -arch=win64 ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADD@Z(ptr long) basic_ios_char_widen +@ cdecl -arch=arm ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QBAGD@Z(ptr long) basic_ios_wchar_widen +@ thiscall -arch=i386 ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEGD@Z(ptr long) basic_ios_wchar_widen +@ cdecl -arch=win64 ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAGD@Z(ptr long) basic_ios_wchar_widen +@ cdecl -arch=arm ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBA_WD@Z(ptr long) basic_ios_wchar_widen +@ thiscall -arch=i386 ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBE_WD@Z(ptr long) basic_ios_wchar_widen +@ cdecl -arch=win64 ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBA_WD@Z(ptr long) basic_ios_wchar_widen +@ cdecl -arch=arm ?widen@?$ctype@D@std@@QBADD@Z(ptr long) ctype_char_widen_ch +@ thiscall -arch=i386 ?widen@?$ctype@D@std@@QBEDD@Z(ptr long) ctype_char_widen_ch +@ cdecl -arch=win64 ?widen@?$ctype@D@std@@QEBADD@Z(ptr long) ctype_char_widen_ch +@ cdecl -arch=arm ?widen@?$ctype@D@std@@QBAPBDPBD0PAD@Z(ptr ptr ptr ptr) ctype_char_widen +@ thiscall -arch=i386 ?widen@?$ctype@D@std@@QBEPBDPBD0PAD@Z(ptr ptr ptr ptr) ctype_char_widen +@ cdecl -arch=win64 ?widen@?$ctype@D@std@@QEBAPEBDPEBD0PEAD@Z(ptr ptr ptr ptr) ctype_char_widen +@ cdecl -arch=arm ?widen@?$ctype@G@std@@QBAGD@Z(ptr long) ctype_wchar_widen_ch +@ thiscall -arch=i386 ?widen@?$ctype@G@std@@QBEGD@Z(ptr long) ctype_wchar_widen_ch +@ cdecl -arch=win64 ?widen@?$ctype@G@std@@QEBAGD@Z(ptr long) ctype_wchar_widen_ch +@ cdecl -arch=arm ?widen@?$ctype@G@std@@QBAPBDPBD0PAG@Z(ptr ptr ptr ptr) ctype_wchar_widen +@ thiscall -arch=i386 ?widen@?$ctype@G@std@@QBEPBDPBD0PAG@Z(ptr ptr ptr ptr) ctype_wchar_widen +@ cdecl -arch=win64 ?widen@?$ctype@G@std@@QEBAPEBDPEBD0PEAG@Z(ptr ptr ptr ptr) ctype_wchar_widen +@ cdecl -arch=arm ?widen@?$ctype@_W@std@@QBAPBDPBD0PA_W@Z(ptr ptr ptr ptr) ctype_wchar_widen +@ thiscall -arch=i386 ?widen@?$ctype@_W@std@@QBEPBDPBD0PA_W@Z(ptr ptr ptr ptr) ctype_wchar_widen +@ cdecl -arch=win64 ?widen@?$ctype@_W@std@@QEBAPEBDPEBD0PEA_W@Z(ptr ptr ptr ptr) ctype_wchar_widen +@ cdecl -arch=arm ?widen@?$ctype@_W@std@@QBA_WD@Z(ptr long) ctype_wchar_widen_ch +@ thiscall -arch=i386 ?widen@?$ctype@_W@std@@QBE_WD@Z(ptr long) ctype_wchar_widen_ch +@ cdecl -arch=win64 ?widen@?$ctype@_W@std@@QEBA_WD@Z(ptr long) ctype_wchar_widen_ch +@ cdecl -ret64 -arch=arm ?width@ios_base@std@@QAA_J_J@Z(ptr int64) ios_base_width_set +@ thiscall -ret64 -arch=i386 ?width@ios_base@std@@QAE_J_J@Z(ptr int64) ios_base_width_set +@ cdecl -arch=win64 ?width@ios_base@std@@QEAA_J_J@Z(ptr long) ios_base_width_set +@ cdecl -ret64 -arch=arm ?width@ios_base@std@@QBA_JXZ(ptr) ios_base_width_get +@ thiscall -ret64 -arch=i386 ?width@ios_base@std@@QBE_JXZ(ptr) ios_base_width_get +@ cdecl -arch=win64 ?width@ios_base@std@@QEBA_JXZ(ptr) ios_base_width_get +@ cdecl -arch=arm ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV12@PBD_J@Z(ptr str int64) basic_ostream_char_write +@ thiscall -arch=i386 ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@PBD_J@Z(ptr str int64) basic_ostream_char_write +@ cdecl -arch=win64 ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEBD_J@Z(ptr str long) basic_ostream_char_write +@ cdecl -arch=arm ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV12@PBG_J@Z(ptr ptr int64) basic_ostream_wchar_write +@ thiscall -arch=i386 ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@PBG_J@Z(ptr ptr int64) basic_ostream_wchar_write +@ cdecl -arch=win64 ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEBG_J@Z(ptr wstr long) basic_ostream_wchar_write +@ cdecl -arch=arm ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAAAAV12@PB_W_J@Z(ptr wstr int64) basic_ostream_wchar_write +@ thiscall -arch=i386 ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PB_W_J@Z(ptr wstr int64) basic_ostream_wchar_write +@ cdecl -arch=win64 ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEB_W_J@Z(ptr wstr long) basic_ostream_wchar_write +@ cdecl -arch=win32 ?ws@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@1@AAV21@@Z(ptr) ws_basic_istream_char +@ cdecl -arch=win64 ?ws@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@1@AEAV21@@Z(ptr) ws_basic_istream_char +@ cdecl -arch=win32 ?ws@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@1@AAV21@@Z(ptr) ws_basic_istream_wchar +@ cdecl -arch=win64 ?ws@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@1@AEAV21@@Z(ptr) ws_basic_istream_wchar +@ cdecl -arch=win32 ?ws@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@1@AAV21@@Z(ptr) ws_basic_istream_wchar +@ cdecl -arch=win64 ?ws@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z(ptr) ws_basic_istream_wchar +@ cdecl ?xalloc@ios_base@std@@SAHXZ() ios_base_xalloc +@ cdecl -ret64 -arch=arm ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAA_JPAD_J@Z(ptr ptr int64) basic_streambuf_char_xsgetn +@ thiscall -ret64 -arch=i386 ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE_JPAD_J@Z(ptr ptr int64) basic_streambuf_char_xsgetn +@ cdecl -arch=win64 ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEAD_J@Z(ptr ptr long) basic_streambuf_char_xsgetn +@ cdecl -ret64 -arch=arm ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAA_JPAG_J@Z(ptr ptr int64) basic_streambuf_wchar_xsgetn +@ thiscall -ret64 -arch=i386 ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE_JPAG_J@Z(ptr ptr int64) basic_streambuf_wchar_xsgetn +@ cdecl -arch=win64 ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEAG_J@Z(ptr ptr long) basic_streambuf_wchar_xsgetn +@ cdecl -ret64 -arch=arm ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAA_JPA_W_J@Z(ptr ptr int64) basic_streambuf_wchar_xsgetn +@ thiscall -ret64 -arch=i386 ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE_JPA_W_J@Z(ptr ptr int64) basic_streambuf_wchar_xsgetn +@ cdecl -arch=win64 ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEA_W_J@Z(ptr ptr long) basic_streambuf_wchar_xsgetn +@ cdecl -ret64 -arch=arm ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAA_JPBD_J@Z(ptr str int64) basic_streambuf_char_xsputn +@ thiscall -ret64 -arch=i386 ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE_JPBD_J@Z(ptr str int64) basic_streambuf_char_xsputn +@ cdecl -arch=win64 ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEBD_J@Z(ptr str long) basic_streambuf_char_xsputn +@ cdecl -ret64 -arch=arm ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAA_JPBG_J@Z(ptr ptr int64) basic_streambuf_wchar_xsputn +@ thiscall -ret64 -arch=i386 ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE_JPBG_J@Z(ptr ptr int64) basic_streambuf_wchar_xsputn +@ cdecl -arch=win64 ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEBG_J@Z(ptr ptr long) basic_streambuf_wchar_xsputn +@ cdecl -ret64 -arch=arm ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAA_JPB_W_J@Z(ptr wstr int64) basic_streambuf_wchar_xsputn +@ thiscall -ret64 -arch=i386 ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE_JPB_W_J@Z(ptr wstr int64) basic_streambuf_wchar_xsputn +@ cdecl -arch=win64 ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEB_W_J@Z(ptr ptr long) basic_streambuf_wchar_xsputn +@ stub _Call_once +@ stub _Call_onceEx +@ stub _Cnd_broadcast +@ stub _Cnd_destroy +@ stub _Cnd_do_broadcast_at_thread_exit +@ stub _Cnd_init +@ stub _Cnd_register_at_thread_exit +@ stub _Cnd_signal +@ stub _Cnd_timedwait +@ stub _Cnd_unregister_at_thread_exit +@ stub _Cnd_wait +@ stub _Cosh +@ extern _Denorm +@ stub _Dint +@ stub _Dnorm +@ stub _Do_call +@ stub _Dscale +@ stub _Dtento +@ stub _Dtest +@ stub _Dunscale +@ extern _Eps +@ stub _Exp +@ stub _FCosh +@ extern _FDenorm +@ stub _FDint +@ stub _FDnorm +@ stub _FDscale +@ stub _FDtento +@ stub _FDtest +@ stub _FDunscale +@ extern _FEps +@ stub _FExp +@ extern _FInf +@ extern _FNan +@ stub _FPlsw +@ stub _FPmsw +# extern _FRteps +@ stub _FSinh +@ extern _FSnan +# extern _FXbig +@ stub _FXp_addh +@ stub _FXp_addx +@ stub _FXp_getw +@ stub _FXp_invx +@ stub _FXp_ldexpx +@ stub _FXp_movx +@ stub _FXp_mulh +@ stub _FXp_mulx +@ stub _FXp_setn +@ stub _FXp_setw +@ stub _FXp_sqrtx +@ stub _FXp_subx +# extern _FZero +@ cdecl -ret64 _Getcoll() +@ cdecl _Getctype(ptr) +@ cdecl -ret64 _Getcvt() +@ stub _Getdateorder +@ cdecl _Getwctype(long ptr) +@ cdecl _Getwctypes(ptr ptr ptr ptr) +@ extern _Hugeval +@ extern _Inf +@ stub _LCosh +@ extern _LDenorm +@ stub _LDint +@ stub _LDscale +@ stub _LDtento +@ stub _LDtest +@ stub _LDunscale +@ extern _LEps +@ stub _LExp +@ extern _LInf +@ extern _LNan +@ stub _LPlsw +@ stub _LPmsw +@ stub _LPoly +# extern _LRteps +@ stub _LSinh +@ extern _LSnan +# extern _LXbig +@ stub _LXp_addh +@ stub _LXp_addx +@ stub _LXp_getw +@ stub _LXp_invx +@ stub _LXp_ldexpx +@ stub _LXp_movx +@ stub _LXp_mulh +@ stub _LXp_mulx +@ stub _LXp_setn +@ stub _LXp_setw +@ stub _LXp_sqrtx +@ stub _LXp_subx +@ extern _LZero +@ stub _Lock_shared_ptr_spin_lock +@ cdecl _Mbrtowc(ptr ptr long ptr ptr) +@ stub _Mtx_clear_owner +@ stub _Mtx_current_owns +@ cdecl _Mtx_destroy(ptr) +@ cdecl _Mtx_getconcrtcs(ptr) +@ cdecl _Mtx_init(ptr long) +@ cdecl _Mtx_lock(ptr) +@ stub _Mtx_reset_owner +@ stub _Mtx_timedlock +@ cdecl _Mtx_trylock(ptr) +@ cdecl _Mtx_unlock(ptr) +@ stub _Mtxdst +@ stub _Mtxinit +@ stub _Mtxlock +@ stub _Mtxunlock +@ extern _Nan +@ stub _Once +@ stub _Plsw +@ stub _Pmsw +@ stub _Poly +# extern _Rteps +@ stub _Sinh +@ extern _Snan +@ cdecl _Stod(ptr ptr long) +@ cdecl _Stodx(ptr ptr long ptr) +@ cdecl _Stof(ptr ptr long) +@ stub _Stoflt +@ cdecl _Stofx(ptr ptr long ptr) +@ cdecl _Stold(ptr ptr long) _Stod +@ cdecl _Stoldx(ptr ptr long ptr) _Stodx +@ cdecl -ret64 _Stoll(ptr ptr long) +@ cdecl -ret64 _Stollx(ptr ptr long ptr) +@ cdecl _Stolx(ptr ptr long ptr) +@ stub _Stopfx +@ cdecl _Stoul(ptr ptr long) +@ cdecl -ret64 _Stoull(ptr ptr long) +@ cdecl -ret64 _Stoullx(ptr ptr long ptr) +@ cdecl _Stoulx(ptr ptr long ptr) +@ stub _Stoxflt +@ cdecl _Strcoll(ptr ptr ptr ptr ptr) +@ stub _Strxfrm +@ stub _Thrd_abort +@ stub _Thrd_create +@ stub _Thrd_current +@ stub _Thrd_detach +@ stub _Thrd_equal +@ stub _Thrd_exit +@ stub _Thrd_join +@ stub _Thrd_lt +@ stub _Thrd_sleep +@ stub _Thrd_start +@ stub _Thrd_yield +@ cdecl _Tolower(long ptr) +@ cdecl _Toupper(long ptr) +@ cdecl _Towlower(long ptr) +@ cdecl _Towupper(long ptr) +@ stub _Tss_create +@ stub _Tss_delete +@ stub _Tss_get +@ stub _Tss_set +@ stub _Unlock_shared_ptr_spin_lock +@ cdecl _Wcrtomb(ptr long ptr ptr) +@ cdecl _Wcscoll(ptr ptr ptr ptr ptr) +@ stub _Wcsxfrm +# extern _Xbig +@ stub _Xp_addh +@ stub _Xp_addx +@ stub _Xp_getw +@ stub _Xp_invx +@ stub _Xp_ldexpx +@ stub _Xp_movx +@ stub _Xp_mulh +@ stub _Xp_mulx +@ stub _Xp_setn +@ stub _Xp_setw +@ stub _Xp_sqrtx +@ stub _Xp_subx +@ stub _Xtime_diff_to_millis +@ stub _Xtime_diff_to_millis2 +@ cdecl _Xtime_get_ticks() +# extern _Zero +@ stub __Wcrtomb_lk +@ stub xtime_get diff -Nru wine1.7-1.7.28/dlls/msvcp60/locale.c wine1.7-1.7.31/dlls/msvcp60/locale.c --- wine1.7-1.7.28/dlls/msvcp60/locale.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp60/locale.c 2014-11-14 13:28:17.000000000 +0000 @@ -2715,6 +2715,16 @@ return (from_end-from > max ? max : from_end-from); } +/* ?length@?$codecvt@DDH@std@@QBEHABHPBD1I@Z */ +/* ?length@?$codecvt@DDH@std@@QEBAHAEBHPEBD1_K@Z */ +DEFINE_THISCALL_WRAPPER(codecvt_char_length, 20) +int __thiscall codecvt_char_length(const codecvt_char *this, const int *state, + const char *from, const char *from_end, MSVCP_size_t max) +{ + TRACE("(%p %p %p %p %lu)\n", this, state, from, from_end, max); + return call_codecvt_char_do_length(this, state, from, from_end, max); +} + /* ?id@?$codecvt@_WDH@std@@2V0locale@2@A */ static locale_id codecvt_wchar_id = {0}; /* ?id@?$codecvt@GDH@std@@2V0locale@2@A */ @@ -8218,8 +8228,28 @@ DEFINE_THISCALL_WRAPPER(locale_ctor_locale_cstr, 16) locale* __thiscall locale_ctor_locale_cstr(locale *this, const locale *loc, const char *locname, category cat) { - FIXME("(%p %p %s %d) stub\n", this, loc, locname, cat); - return NULL; + _Locinfo locinfo; + + TRACE("(%p %p %s %d)\n", this, loc, locname, cat); + + _Locinfo_ctor_cat_cstr(&locinfo, cat, locname); + if(!memcmp(basic_string_char_c_str(&locinfo.newlocname), "*", 2)) { + _Locinfo_dtor(&locinfo); + MSVCRT_operator_delete(this->ptr); + throw_exception(EXCEPTION_RUNTIME_ERROR, "bad locale name"); + } + + this->ptr = MSVCRT_operator_new(sizeof(locale__Locimp)); + if(!this->ptr) { + ERR("Out of memory\n"); + _Locinfo_dtor(&locinfo); + throw_exception(EXCEPTION_BAD_ALLOC, NULL); + } + locale__Locimp_copy_ctor(this->ptr, loc->ptr); + + locale__Locimp__Makeloc(&locinfo, cat, this->ptr, NULL); + _Locinfo_dtor(&locinfo); + return this; } /* ??0locale@std@@QAE@PBDH@Z */ diff -Nru wine1.7-1.7.28/dlls/msvcp60/msvcp60.spec wine1.7-1.7.31/dlls/msvcp60/msvcp60.spec --- wine1.7-1.7.28/dlls/msvcp60/msvcp60.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp60/msvcp60.spec 2014-11-14 13:28:17.000000000 +0000 @@ -2,10 +2,10 @@ @ stub -arch=win64 ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAC@Z @ cdecl -arch=win32 ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAD@Z(ptr ptr) basic_istream_char_read_ch @ cdecl -arch=win64 ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAD@Z(ptr ptr) basic_istream_char_read_ch -@ stub -arch=win32 ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAE@Z -@ stub -arch=win64 ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAE@Z -@ stub -arch=win32 ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAC@Z -@ stub -arch=win64 ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAC@Z +@ cdecl -arch=win32 ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAE@Z(ptr ptr) basic_istream_char_read_ch +@ cdecl -arch=win64 ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAE@Z(ptr ptr) basic_istream_char_read_ch +@ cdecl -arch=win32 ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAC@Z(ptr ptr) basic_istream_char_read_ch +@ cdecl -arch=win64 ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAC@Z(ptr ptr) basic_istream_char_read_ch @ cdecl -arch=win32 ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAD@Z(ptr ptr) basic_istream_char_read_str @ cdecl -arch=win64 ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAD@Z(ptr ptr) basic_istream_char_read_str @ stub -arch=win32 ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAE@Z @@ -2769,8 +2769,8 @@ @ cdecl -arch=win64 ?do_is@?$ctype@G@std@@MEBAPEBGPEBG0PEAF@Z(ptr ptr ptr ptr) ctype_wchar_do_is @ thiscall -arch=win32 ?do_is@?$ctype@G@std@@MBE_NFG@Z(ptr long long) ctype_wchar_do_is_ch @ cdecl -arch=win64 ?do_is@?$ctype@G@std@@MEBA_NFG@Z(ptr long long) ctype_wchar_do_is_ch -@ stub -arch=win32 ?do_length@?$codecvt@DDH@std@@MBEHAAHPBD1I@Z -@ stub -arch=win64 ?do_length@?$codecvt@DDH@std@@MEBAHAEAHPEBD1_K@Z +@ thiscall -arch=i386 ?do_length@?$codecvt@DDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@DDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_char_do_length @ stub -arch=win32 ?do_length@?$codecvt@GDH@std@@MBEHAAHPBG1I@Z @ stub -arch=win64 ?do_length@?$codecvt@GDH@std@@MEBAHAEAHPEBG1_K@Z @ thiscall -arch=win32 ?do_max_length@?$codecvt@GDH@std@@MBEHXZ(ptr) codecvt_wchar_do_max_length @@ -3402,8 +3402,8 @@ @ cdecl -arch=win64 ?length@?$char_traits@D@std@@SA_KPEBD@Z(ptr) msvcp90.?length@?$char_traits@D@std@@SA_KPEBD@Z @ cdecl -arch=win32 ?length@?$char_traits@G@std@@SAIPBG@Z(ptr) msvcp90.?length@?$char_traits@G@std@@SAIPBG@Z @ cdecl -arch=win64 ?length@?$char_traits@G@std@@SA_KPEBG@Z(ptr) msvcp90.?length@?$char_traits@G@std@@SA_KPEBG@Z -@ stub -arch=win32 ?length@?$codecvt@DDH@std@@QBEHAAHPBD1I@Z -@ stub -arch=win64 ?length@?$codecvt@DDH@std@@QEBAHAEAHPEBD1_K@Z +@ thiscall -arch=i386 ?length@?$codecvt@DDH@std@@QBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_length +@ cdecl -arch=win64 ?length@?$codecvt@DDH@std@@QEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_char_length @ stub -arch=win32 ?length@?$codecvt@GDH@std@@QBEHAAHPBG1I@Z @ stub -arch=win64 ?length@?$codecvt@GDH@std@@QEBAHAEAHPEBG1_K@Z @ stub -arch=win32 ?log10@std@@YA?AV?$complex@M@1@ABV21@@Z diff -Nru wine1.7-1.7.28/dlls/msvcp70/msvcp70.spec wine1.7-1.7.31/dlls/msvcp70/msvcp70.spec --- wine1.7-1.7.28/dlls/msvcp70/msvcp70.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp70/msvcp70.spec 2014-11-14 13:28:17.000000000 +0000 @@ -2103,9 +2103,9 @@ @ stub ?_Isinf@?$_Ctraits@M@std@@SA_NM@Z @ stub ?_Isinf@?$_Ctraits@N@std@@SA_NN@Z @ stub ?_Isinf@?$_Ctraits@O@std@@SA_NO@Z -@ stub ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z -@ stub ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z -@ stub ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z +@ cdecl ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z(float) std_Ctraits_float__Isnan +@ cdecl ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z(double) std_Ctraits_double__Isnan +@ cdecl ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z(double) std_Ctraits_long_double__Isnan @ stub -arch=win32 ?_Loc_atexit@std@@YA_NP6AXXZ@Z @ stub -arch=win32 ?_Makpat@?$_Mpunct@D@std@@AAEXAAUpattern@money_base@2@III@Z @ stub -arch=win64 ?_Makpat@?$_Mpunct@D@std@@AEAAXAEAUpattern@money_base@2@III@Z @@ -2855,11 +2855,12 @@ @ cdecl -arch=win64 ?do_is@?$ctype@_W@std@@MEBAPEB_WPEB_W0PEAF@Z(ptr ptr ptr ptr) ctype_wchar_do_is @ thiscall -arch=i386 ?do_is@?$ctype@_W@std@@MBE_NF_W@Z(ptr long long) ctype_wchar_do_is_ch @ cdecl -arch=win64 ?do_is@?$ctype@_W@std@@MEBA_NF_W@Z(ptr long long) ctype_wchar_do_is_ch -@ stub -arch=win32 ?do_length@?$codecvt@DDH@std@@MBEHAAHPBD1I@Z -@ stub -arch=win64 ?do_length@?$codecvt@DDH@std@@MEBAHAEAHPEBD1_K@Z +@ thiscall -arch=i386 ?do_length@?$codecvt@DDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_char_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@DDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_char_do_length @ thiscall -arch=win32 ?do_length@?$codecvt@DDH@std@@MBEHABHPBD1I@Z(ptr ptr str str long) codecvt_char_do_length @ cdecl -arch=win64 ?do_length@?$codecvt@DDH@std@@MEBAHAEBHPEBD1_K@Z(ptr ptr str str long) codecvt_char_do_length -@ stub -arch=win32 ?do_length@?$codecvt@GDH@std@@MBEHAAHPBD1I@Z +@ thiscall -arch=i386 ?do_length@?$codecvt@GDH@std@@MBEHAAHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length +@ cdecl -arch=win64 ?do_length@?$codecvt@GDH@std@@MEBAHAEAHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_do_length @ thiscall -arch=win32 ?do_length@?$codecvt@GDH@std@@MBEHABHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length @ cdecl -arch=win64 ?do_length@?$codecvt@GDH@std@@MEBAHAEBHPEBD1_K@Z(ptr ptr str str long) codecvt_wchar_do_length @ thiscall -arch=win32 ?do_length@?$codecvt@_WDH@std@@MBEHABHPBD1I@Z(ptr ptr str str long) codecvt_wchar_do_length diff -Nru wine1.7-1.7.28/dlls/msvcp71/msvcp71.spec wine1.7-1.7.31/dlls/msvcp71/msvcp71.spec --- wine1.7-1.7.28/dlls/msvcp71/msvcp71.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp71/msvcp71.spec 2014-11-14 13:28:17.000000000 +0000 @@ -50,20 +50,20 @@ @ cdecl -arch=win64 ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@PEBG@Z(ptr ptr) basic_ostream_char_print_str @ cdecl -arch=win32 ??$?6GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z(ptr ptr) basic_ostream_wchar_print_bstr @ cdecl -arch=win64 ??$?6GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z(ptr ptr) basic_ostream_wchar_print_bstr -@ stub -arch=win32 ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z -@ stub -arch=win64 ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z +@ cdecl -arch=win32 ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z(ptr ptr) basic_ostream_char_print_complex_float +@ cdecl -arch=win64 ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z(ptr ptr) basic_ostream_char_print_complex_float @ stub -arch=win32 ??$?6MGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@M@0@@Z @ stub -arch=win64 ??$?6MGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@M@0@@Z @ stub -arch=win32 ??$?6M_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@M@0@@Z @ stub -arch=win64 ??$?6M_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@AEBV?$complex@M@0@@Z -@ stub -arch=win32 ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z -@ stub -arch=win64 ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z +@ cdecl -arch=win32 ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z(ptr ptr) basic_ostream_char_print_complex_double +@ cdecl -arch=win64 ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z(ptr ptr) basic_ostream_char_print_complex_double @ stub -arch=win32 ??$?6NGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@N@0@@Z @ stub -arch=win64 ??$?6NGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@N@0@@Z @ stub -arch=win32 ??$?6N_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@N@0@@Z @ stub -arch=win64 ??$?6N_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@AEBV?$complex@N@0@@Z -@ stub -arch=win32 ??$?6ODU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@O@0@@Z -@ stub -arch=win64 ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z +@ cdecl -arch=win32 ??$?6ODU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@O@0@@Z(ptr ptr) basic_ostream_char_print_complex_ldouble +@ cdecl -arch=win64 ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z(ptr ptr) basic_ostream_char_print_complex_ldouble @ stub -arch=win32 ??$?6OGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@O@0@@Z @ stub -arch=win64 ??$?6OGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@O@0@@Z @ stub -arch=win32 ??$?6O_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@O@0@@Z @@ -2300,9 +2300,9 @@ @ stub ?_Isinf@?$_Ctraits@M@std@@SA_NM@Z @ stub ?_Isinf@?$_Ctraits@N@std@@SA_NN@Z @ stub ?_Isinf@?$_Ctraits@O@std@@SA_NO@Z -@ stub ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z -@ stub ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z -@ stub ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z +@ cdecl ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z(float) std_Ctraits_float__Isnan +@ cdecl ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z(double) std_Ctraits_double__Isnan +@ cdecl ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z(double) std_Ctraits_long_double__Isnan @ thiscall -arch=win32 ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ(ptr) basic_streambuf_char__Lock @ cdecl -arch=win64 ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ(ptr) basic_streambuf_char__Lock @ thiscall -arch=win32 ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ(ptr) basic_streambuf_wchar__Lock diff -Nru wine1.7-1.7.28/dlls/msvcp80/msvcp80.spec wine1.7-1.7.31/dlls/msvcp80/msvcp80.spec --- wine1.7-1.7.28/dlls/msvcp80/msvcp80.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp80/msvcp80.spec 2014-11-14 13:28:17.000000000 +0000 @@ -50,20 +50,20 @@ @ cdecl -arch=win64 ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@PEBG@Z(ptr ptr) basic_ostream_char_print_str @ cdecl -arch=win32 ??$?6GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z(ptr ptr) basic_ostream_wchar_print_bstr @ cdecl -arch=win64 ??$?6GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z(ptr ptr) basic_ostream_wchar_print_bstr -@ stub -arch=win32 ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z -@ stub -arch=win64 ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z +@ cdecl -arch=win32 ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z(ptr ptr) basic_ostream_char_print_complex_float +@ cdecl -arch=win64 ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z(ptr ptr) basic_ostream_char_print_complex_float @ stub -arch=win32 ??$?6MGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@M@0@@Z @ stub -arch=win64 ??$?6MGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@M@0@@Z @ stub -arch=win32 ??$?6M_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@M@0@@Z @ stub -arch=win64 ??$?6M_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@AEBV?$complex@M@0@@Z -@ stub -arch=win32 ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z -@ stub -arch=win64 ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z +@ cdecl -arch=win32 ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z(ptr ptr) basic_ostream_char_print_complex_double +@ cdecl -arch=win64 ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z(ptr ptr) basic_ostream_char_print_complex_double @ stub -arch=win32 ??$?6NGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@N@0@@Z @ stub -arch=win64 ??$?6NGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@N@0@@Z @ stub -arch=win32 ??$?6N_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@N@0@@Z @ stub -arch=win64 ??$?6N_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@AEBV?$complex@N@0@@Z -@ stub -arch=win32 ??$?6ODU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@O@0@@Z -@ stub -arch=win64 ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z +@ cdecl -arch=win32 ??$?6ODU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@O@0@@Z(ptr ptr) basic_ostream_char_print_complex_ldouble +@ cdecl -arch=win64 ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z(ptr ptr) basic_ostream_char_print_complex_ldouble @ stub -arch=win32 ??$?6OGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@O@0@@Z @ stub -arch=win64 ??$?6OGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@O@0@@Z @ stub -arch=win32 ??$?6O_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@O@0@@Z @@ -2557,9 +2557,9 @@ @ stub ?_Isinf@?$_Ctraits@M@std@@SA_NM@Z @ stub ?_Isinf@?$_Ctraits@N@std@@SA_NN@Z @ stub ?_Isinf@?$_Ctraits@O@std@@SA_NO@Z -@ stub ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z -@ stub ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z -@ stub ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z +@ cdecl ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z(float) std_Ctraits_float__Isnan +@ cdecl ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z(double) std_Ctraits_double__Isnan +@ cdecl ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z(double) std_Ctraits_long_double__Isnan @ cdecl -arch=win32 ?_Locimp_Addfac@_Locimp@locale@std@@CAXPAV123@PAVfacet@23@I@Z(ptr ptr long) locale__Locimp__Locimp_Addfac @ cdecl -arch=win64 ?_Locimp_Addfac@_Locimp@locale@std@@CAXPEAV123@PEAVfacet@23@_K@Z(ptr ptr long) locale__Locimp__Locimp_Addfac @ cdecl -arch=win32 ?_Locimp_ctor@_Locimp@locale@std@@CAXPAV123@ABV123@@Z(ptr ptr) locale__Locimp__Locimp_ctor diff -Nru wine1.7-1.7.28/dlls/msvcp90/ios.c wine1.7-1.7.31/dlls/msvcp90/ios.c --- wine1.7-1.7.28/dlls/msvcp90/ios.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/ios.c 2014-11-14 13:28:17.000000000 +0000 @@ -13770,6 +13770,108 @@ return (strstream*)((char*)ptr-strstream_vbtable1[1]); } +/* ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z */ +/* ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z */ +basic_ostream_char* __cdecl basic_ostream_char_print_complex_float(basic_ostream_char *ostr, const complex_float *val) +{ + struct { + basic_ostringstream_char obj; + basic_ios_char vbase; + } oss; + ios_base *ostringstream_ios_base, *ostream_ios_base; + locale loc; + basic_string_char str; + basic_ostringstream_char_ctor(&oss.obj); + ostringstream_ios_base = &oss.vbase.base; + ostream_ios_base = &basic_ostream_char_get_basic_ios(ostr)->base; + TRACE("(%p %p)\n", ostr, val); + + ios_base_imbue(ostringstream_ios_base, &loc, ostream_ios_base->loc); + locale_dtor(&loc); + ios_base_precision_set(ostringstream_ios_base, ios_base_precision_get(ostream_ios_base)); + ios_base_flags_set(ostringstream_ios_base, ios_base_flags_get(ostream_ios_base)); + + basic_ostream_char_print_ch(&oss.obj.base, '('); + basic_ostream_char_print_float(&oss.obj.base, val->real); + basic_ostream_char_print_ch(&oss.obj.base, ','); + basic_ostream_char_print_float(&oss.obj.base, val->imag); + basic_ostream_char_print_ch(&oss.obj.base, ')'); + + basic_ostringstream_char_str_get(&oss.obj, &str); + basic_ostringstream_char_dtor(&oss.vbase); + basic_ostream_char_print_bstr(ostr, &str); + MSVCP_basic_string_char_dtor(&str); + return ostr; +} + +/* ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z */ +/* ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z */ +basic_ostream_char* __cdecl basic_ostream_char_print_complex_double(basic_ostream_char *ostr, const complex_double *val) +{ + struct { + basic_ostringstream_char obj; + basic_ios_char vbase; + } oss; + ios_base *ostringstream_ios_base, *ostream_ios_base; + locale loc; + basic_string_char str; + basic_ostringstream_char_ctor(&oss.obj); + ostringstream_ios_base = &oss.vbase.base; + ostream_ios_base = &basic_ostream_char_get_basic_ios(ostr)->base; + TRACE("(%p %p)\n", ostr, val); + + ios_base_imbue(ostringstream_ios_base, &loc, ostream_ios_base->loc); + locale_dtor(&loc); + ios_base_precision_set(ostringstream_ios_base, ios_base_precision_get(ostream_ios_base)); + ios_base_flags_set(ostringstream_ios_base, ios_base_flags_get(ostream_ios_base)); + + basic_ostream_char_print_ch(&oss.obj.base, '('); + basic_ostream_char_print_double(&oss.obj.base, val->real); + basic_ostream_char_print_ch(&oss.obj.base, ','); + basic_ostream_char_print_double(&oss.obj.base, val->imag); + basic_ostream_char_print_ch(&oss.obj.base, ')'); + + basic_ostringstream_char_str_get(&oss.obj, &str); + basic_ostringstream_char_dtor(&oss.vbase); + basic_ostream_char_print_bstr(ostr, &str); + MSVCP_basic_string_char_dtor(&str); + return ostr; +} + +/* ??$?6odu?$char_traits@d@std@@@std@@yaaav?$basic_ostream@du?$char_traits@d@std@@@0@aav10@abv?$complex@o@0@@Z */ +/* ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z */ +basic_ostream_char* __cdecl basic_ostream_char_print_complex_ldouble(basic_ostream_char *ostr, const complex_double *val) +{ + struct { + basic_ostringstream_char obj; + basic_ios_char vbase; + } oss; + ios_base *ostringstream_ios_base, *ostream_ios_base; + locale loc; + basic_string_char str; + basic_ostringstream_char_ctor(&oss.obj); + ostringstream_ios_base = &oss.vbase.base; + ostream_ios_base = &basic_ostream_char_get_basic_ios(ostr)->base; + TRACE("(%p %p)\n", ostr, val); + + ios_base_imbue(ostringstream_ios_base, &loc, ostream_ios_base->loc); + locale_dtor(&loc); + ios_base_precision_set(ostringstream_ios_base, ios_base_precision_get(ostream_ios_base)); + ios_base_flags_set(ostringstream_ios_base, ios_base_flags_get(ostream_ios_base)); + + basic_ostream_char_print_ch(&oss.obj.base, '('); + basic_ostream_char_print_ldouble(&oss.obj.base, val->real); + basic_ostream_char_print_ch(&oss.obj.base, ','); + basic_ostream_char_print_ldouble(&oss.obj.base, val->imag); + basic_ostream_char_print_ch(&oss.obj.base, ')'); + + basic_ostringstream_char_str_get(&oss.obj, &str); + basic_ostringstream_char_dtor(&oss.vbase); + basic_ostream_char_print_bstr(ostr, &str); + MSVCP_basic_string_char_dtor(&str); + return ostr; +} + /* ??0strstream@std@@QAE@PADHH@Z */ /* ??0strstream@std@@QEAA@PEAD_JH@Z */ #if STREAMSIZE_BITS == 64 diff -Nru wine1.7-1.7.28/dlls/msvcp90/locale.c wine1.7-1.7.31/dlls/msvcp90/locale.c --- wine1.7-1.7.28/dlls/msvcp90/locale.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/locale.c 2014-11-14 13:28:17.000000000 +0000 @@ -9958,8 +9958,28 @@ DEFINE_THISCALL_WRAPPER(locale_ctor_locale_cstr, 16) locale* __thiscall locale_ctor_locale_cstr(locale *this, const locale *loc, const char *locname, category cat) { - FIXME("(%p %p %s %d) stub\n", this, loc, locname, cat); - return NULL; + _Locinfo locinfo; + + TRACE("(%p %p %s %d)\n", this, loc, locname, cat); + + _Locinfo_ctor_cat_cstr(&locinfo, cat, locname); + if(!memcmp(locale_string_char_c_str(&locinfo.newlocname), "*", 2)) { + _Locinfo_dtor(&locinfo); + MSVCRT_operator_delete(this->ptr); + throw_exception(EXCEPTION_RUNTIME_ERROR, "bad locale name"); + } + + this->ptr = MSVCRT_operator_new(sizeof(locale__Locimp)); + if(!this->ptr) { + ERR("Out of memory\n"); + _Locinfo_dtor(&locinfo); + throw_exception(EXCEPTION_BAD_ALLOC, NULL); + } + locale__Locimp_copy_ctor(this->ptr, loc->ptr); + + locale__Locimp__Makeloc(&locinfo, cat, this->ptr, NULL); + _Locinfo_dtor(&locinfo); + return this; } /* ??0locale@std@@QAE@PBDH@Z */ diff -Nru wine1.7-1.7.28/dlls/msvcp90/math.c wine1.7-1.7.31/dlls/msvcp90/math.c --- wine1.7-1.7.28/dlls/msvcp90/math.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/math.c 2014-11-14 13:28:17.000000000 +0000 @@ -815,6 +815,15 @@ return this; } +/* ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z -> public: static bool __cdecl std::_Ctraits::_Isnan(float) */ +BOOLEAN __cdecl std_Ctraits_float__Isnan( float x ) { return _isnan(x); } + +/* ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z -> public: static bool __cdecl std::_Ctraits::_Isnan(double) */ +BOOLEAN __cdecl std_Ctraits_double__Isnan( double x ) { return _isnan(x); } + +/* ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z -> public: static bool __cdecl std::_Ctraits::_Isnan(long double) */ +BOOLEAN __cdecl std_Ctraits_long_double__Isnan( LDOUBLE x ) { return _isnan(x); } + /* ?atan2@?$_Ctraits@M@std@@SAMMM@Z -> public: static float __cdecl std::_Ctraits::atan2(float,float) */ float __cdecl std_Ctraits_float_atan2( float y, float x ) { return atan2f( y, x ); } diff -Nru wine1.7-1.7.28/dlls/msvcp90/memory.c wine1.7-1.7.31/dlls/msvcp90/memory.c --- wine1.7-1.7.28/dlls/msvcp90/memory.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/memory.c 2014-11-14 13:28:17.000000000 +0000 @@ -111,7 +111,7 @@ /* ?max_size@?$allocator@D@std@@QBEIXZ */ /* ?max_size@?$allocator@D@std@@QEBA_KXZ */ DEFINE_THISCALL_WRAPPER(MSVCP_allocator_char_max_size, 4) -MSVCP_size_t __thiscall MSVCP_allocator_char_max_size(void *this) +MSVCP_size_t __thiscall MSVCP_allocator_char_max_size(const void *this) { return UINT_MAX/sizeof(char); } @@ -208,7 +208,7 @@ /* ?max_size@?$allocator@_W@std@@QBEIXZ */ /* ?max_size@?$allocator@_W@std@@QEBA_KXZ */ DEFINE_THISCALL_WRAPPER(MSVCP_allocator_wchar_max_size, 4) -MSVCP_size_t __thiscall MSVCP_allocator_wchar_max_size(void *this) +MSVCP_size_t __thiscall MSVCP_allocator_wchar_max_size(const void *this) { return UINT_MAX/sizeof(wchar_t); } diff -Nru wine1.7-1.7.28/dlls/msvcp90/misc.c wine1.7-1.7.31/dlls/msvcp90/misc.c --- wine1.7-1.7.28/dlls/msvcp90/misc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/misc.c 2014-11-14 13:28:17.000000000 +0000 @@ -478,3 +478,118 @@ return &(*mtx)->cs; } #endif + +#if _MSVCP_VER == 100 +typedef struct { + const vtable_ptr *vtable; +} error_category; + +typedef struct { + error_category base; + const char *type; +} custom_category; +static custom_category iostream_category; + +DEFINE_RTTI_DATA0(error_category, 0, ".?AVerror_category@std@@") +DEFINE_RTTI_DATA1(iostream_category, 0, &error_category_rtti_base_descriptor, ".?AV_Iostream_error_category@std@@") + +extern const vtable_ptr MSVCP_iostream_category_vtable; + +static void iostream_category_ctor(custom_category *this) +{ + this->base.vtable = &MSVCP_iostream_category_vtable; + this->type = "iostream"; +} + +DEFINE_THISCALL_WRAPPER(custom_category_vector_dtor, 8) +custom_category* __thiscall custom_category_vector_dtor(custom_category *this, unsigned int flags) +{ + TRACE("(%p %x)\n", this, flags); + if(flags & 2) { + /* we have an array, with the number of elements stored before the first object */ + INT_PTR i, *ptr = (INT_PTR *)this-1; + + for(i=*ptr-1; i>=0; i--) + MSVCRT_operator_delete(ptr); + } else { + if(flags & 1) + MSVCRT_operator_delete(this); + } + + return this; +} + +DEFINE_THISCALL_WRAPPER(custom_category_name, 4) +const char* __thiscall custom_category_name(const custom_category *this) +{ + return this->type; +} + +DEFINE_THISCALL_WRAPPER(custom_category_message, 12) +basic_string_char* __thiscall custom_category_message(const custom_category *this, + basic_string_char *ret, int err) +{ + if(err == 1) return MSVCP_basic_string_char_ctor_cstr(ret, "iostream error"); + return MSVCP_basic_string_char_ctor_cstr(ret, strerror(err)); +} + +DEFINE_THISCALL_WRAPPER(custom_category_default_error_condition, 12) +/*error_condition*/void* __thiscall custom_category_default_error_condition( + custom_category *this, /*error_condition*/void *ret, int code) +{ + FIXME("(%p %p %x) stub\n", this, ret, code); + return NULL; +} + +DEFINE_THISCALL_WRAPPER(custom_category_equivalent, 12) +MSVCP_bool __thiscall custom_category_equivalent(const custom_category *this, + int code, const /*error_condition*/void *condition) +{ + FIXME("(%p %x %p) stub\n", this, code, condition); + return FALSE; +} + +DEFINE_THISCALL_WRAPPER(custom_category_equivalent_code, 12) +MSVCP_bool __thiscall custom_category_equivalent_code(custom_category *this, + const /*error_code*/void *code, int condition) +{ + FIXME("(%p %p %x) stub\n", this, code, condition); + return FALSE; +} + +/* ?iostream_category@std@@YAABVerror_category@1@XZ */ +/* ?iostream_category@std@@YAAEBVerror_category@1@XZ */ +const error_category* __cdecl std_iostream_category(void) +{ + TRACE("()\n"); + return &iostream_category.base; +} + +#ifndef __GNUC__ +void __asm_dummy_vtables(void) { +#endif + __ASM_VTABLE(iostream_category, + VTABLE_ADD_FUNC(custom_category_vector_dtor) + VTABLE_ADD_FUNC(custom_category_name) + VTABLE_ADD_FUNC(custom_category_message) + VTABLE_ADD_FUNC(custom_category_default_error_condition) + VTABLE_ADD_FUNC(custom_category_equivalent) + VTABLE_ADD_FUNC(custom_category_equivalent_code)); +#ifndef __GNUC__ +} +#endif +#endif + +void init_misc(void *base) +{ +#ifdef __x86_64__ +#if _MSVCP_VER == 100 + init_error_category_rtti(base); + init_iostream_category_rtti(base); +#endif +#endif + +#if _MSVCP_VER == 100 + iostream_category_ctor(&iostream_category); +#endif +} diff -Nru wine1.7-1.7.28/dlls/msvcp90/msvcp90.h wine1.7-1.7.31/dlls/msvcp90/msvcp90.h --- wine1.7-1.7.28/dlls/msvcp90/msvcp90.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/msvcp90.h 2014-11-14 13:28:17.000000000 +0000 @@ -74,13 +74,18 @@ #define BUF_SIZE_CHAR 16 typedef struct { +#if _MSVCP_VER <= 90 void *allocator; +#endif union { char buf[BUF_SIZE_CHAR]; char *ptr; } data; MSVCP_size_t size; MSVCP_size_t res; +#if _MSVCP_VER == 100 + char allocator; +#endif } basic_string_char; basic_string_char* __thiscall MSVCP_basic_string_char_ctor(basic_string_char*); @@ -97,13 +102,18 @@ #define BUF_SIZE_WCHAR 8 typedef struct { +#if _MSVCP_VER <= 90 void *allocator; +#endif union { wchar_t buf[BUF_SIZE_WCHAR]; wchar_t *ptr; } data; MSVCP_size_t size; MSVCP_size_t res; +#if _MSVCP_VER == 100 + char allocator; +#endif } basic_string_wchar; basic_string_wchar* __thiscall MSVCP_basic_string_wchar_ctor(basic_string_wchar*); @@ -117,10 +127,10 @@ char* __thiscall MSVCP_allocator_char_allocate(void*, MSVCP_size_t); void __thiscall MSVCP_allocator_char_deallocate(void*, char*, MSVCP_size_t); -MSVCP_size_t __thiscall MSVCP_allocator_char_max_size(void*); +MSVCP_size_t __thiscall MSVCP_allocator_char_max_size(const void*); wchar_t* __thiscall MSVCP_allocator_wchar_allocate(void*, MSVCP_size_t); void __thiscall MSVCP_allocator_wchar_deallocate(void*, wchar_t*, MSVCP_size_t); -MSVCP_size_t __thiscall MSVCP_allocator_wchar_max_size(void*); +MSVCP_size_t __thiscall MSVCP_allocator_wchar_max_size(const void*); typedef struct { @@ -536,6 +546,7 @@ void init_locale(void*); void init_io(void*); void free_io(void); +void init_misc(void*); /* class complex */ typedef struct { @@ -551,8 +562,23 @@ } complex_double; #if _MSVCP_VER < 80 -#define memcpy_s( dst, size, src, count ) (memcpy( (dst), (src), (count) ), 0) -#define memmove_s( dst, size, src, count ) (memmove( (dst), (src), (count) ), 0) -#define mbstowcs_s( ret, wcs, size, mbs, count ) (mbstowcs( (wcs), (mbs), (count) ), 0) +static inline int memcpy_wrapper( void *dst, size_t size, const void *src, size_t count ) +{ + memcpy( dst, src, count ); + return 0; +} +static inline int memmove_wrapper( void *dst, size_t size, const void *src, size_t count ) +{ + memmove( dst, src, count ); + return 0; +} +static inline int mbstowcs_wrapper( size_t *ret, wchar_t *wcs, size_t size, const char *mbs, size_t count ) +{ + mbstowcs( wcs, mbs, count ); + return 0; +} +#define memcpy_s( dst, size, src, count ) memcpy_wrapper( dst, size, src, count ) +#define memmove_s( dst, size, src, count ) memmove_wrapper( dst, size, src, count ) +#define mbstowcs_s( ret, wcs, size, mbs, count ) mbstowcs_wrapper( ret, wcs, size, mbs, count ) #define hypotf( x, y ) ((float)hypot( (double)(x), (double)(y) )) #endif diff -Nru wine1.7-1.7.28/dlls/msvcp90/msvcp90.spec wine1.7-1.7.31/dlls/msvcp90/msvcp90.spec --- wine1.7-1.7.28/dlls/msvcp90/msvcp90.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/msvcp90.spec 2014-11-14 13:28:17.000000000 +0000 @@ -50,20 +50,20 @@ @ cdecl -arch=win64 ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@PEBG@Z(ptr ptr) basic_ostream_char_print_str @ cdecl -arch=win32 ??$?6GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z(ptr ptr) basic_ostream_wchar_print_bstr @ cdecl -arch=win64 ??$?6GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z(ptr ptr) basic_ostream_wchar_print_bstr -@ stub -arch=win32 ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z -@ stub -arch=win64 ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z +@ cdecl -arch=win32 ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z(ptr ptr) basic_ostream_char_print_complex_float +@ cdecl -arch=win64 ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z(ptr ptr) basic_ostream_char_print_complex_float @ stub -arch=win32 ??$?6MGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@M@0@@Z @ stub -arch=win64 ??$?6MGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@M@0@@Z @ stub -arch=win32 ??$?6M_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@M@0@@Z @ stub -arch=win64 ??$?6M_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@AEBV?$complex@M@0@@Z -@ stub -arch=win32 ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z -@ stub -arch=win64 ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z +@ cdecl -arch=win32 ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z(ptr ptr) basic_ostream_char_print_complex_double +@ cdecl -arch=win64 ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z(ptr ptr) basic_ostream_char_print_complex_double @ stub -arch=win32 ??$?6NGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@N@0@@Z @ stub -arch=win64 ??$?6NGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@N@0@@Z @ stub -arch=win32 ??$?6N_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@N@0@@Z @ stub -arch=win64 ??$?6N_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@AEBV?$complex@N@0@@Z -@ stub -arch=win32 ??$?6ODU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@O@0@@Z -@ stub -arch=win64 ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z +@ cdecl -arch=win32 ??$?6ODU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@O@0@@Z(ptr ptr) basic_ostream_char_print_complex_ldouble +@ cdecl -arch=win64 ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z(ptr ptr) basic_ostream_char_print_complex_ldouble @ stub -arch=win32 ??$?6OGU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$complex@O@0@@Z @ stub -arch=win64 ??$?6OGU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$complex@O@0@@Z @ stub -arch=win32 ??$?6O_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$complex@O@0@@Z @@ -2878,9 +2878,9 @@ @ stub ?_Isinf@?$_Ctraits@M@std@@SA_NM@Z @ stub ?_Isinf@?$_Ctraits@N@std@@SA_NN@Z @ stub ?_Isinf@?$_Ctraits@O@std@@SA_NO@Z -@ stub ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z -@ stub ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z -@ stub ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z +@ cdecl ?_Isnan@?$_Ctraits@M@std@@SA_NM@Z(float) std_Ctraits_float__Isnan +@ cdecl ?_Isnan@?$_Ctraits@N@std@@SA_NN@Z(double) std_Ctraits_double__Isnan +@ cdecl ?_Isnan@?$_Ctraits@O@std@@SA_NO@Z(double) std_Ctraits_long_double__Isnan @ cdecl -arch=win32 ?_Locimp_Addfac@_Locimp@locale@std@@CAXPAV123@PAVfacet@23@I@Z(ptr ptr long) locale__Locimp__Locimp_Addfac @ cdecl -arch=win64 ?_Locimp_Addfac@_Locimp@locale@std@@CAXPEAV123@PEAVfacet@23@_K@Z(ptr ptr long) locale__Locimp__Locimp_Addfac @ cdecl -arch=win32 ?_Locimp_ctor@_Locimp@locale@std@@CAXPAV123@ABV123@@Z(ptr ptr) locale__Locimp__Locimp_ctor diff -Nru wine1.7-1.7.28/dlls/msvcp90/msvcp_main.c wine1.7-1.7.31/dlls/msvcp90/msvcp_main.c --- wine1.7-1.7.28/dlls/msvcp90/msvcp_main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/msvcp_main.c 2014-11-14 13:28:17.000000000 +0000 @@ -127,6 +127,7 @@ init_exception(hinstDLL); init_locale(hinstDLL); init_io(hinstDLL); + init_misc(hinstDLL); break; case DLL_PROCESS_DETACH: if (lpvReserved) break; diff -Nru wine1.7-1.7.28/dlls/msvcp90/string.c wine1.7-1.7.31/dlls/msvcp90/string.c --- wine1.7-1.7.28/dlls/msvcp90/string.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/string.c 2014-11-14 13:28:17.000000000 +0000 @@ -29,6 +29,14 @@ #include "wine/debug.h" WINE_DEFAULT_DEBUG_CHANNEL(msvcp); +#if _MSVCP_VER <= 90 +#define STRING_ALLOCATOR(this) ((this)->allocator) +#elif _MSVCP_VER == 100 +#define STRING_ALLOCATOR(this) (&(this)->allocator) +#else +#define STRING_ALLOCATOR(this) NULL +#endif + /* size_t_noverify structure */ typedef struct { MSVCP_size_t val; @@ -546,7 +554,7 @@ if(new_size > 0) MSVCP_char_traits_char__Copy_s(this->data.buf, BUF_SIZE_CHAR, ptr, new_size); - MSVCP_allocator_char_deallocate(this->allocator, ptr, this->res+1); + MSVCP_allocator_char_deallocate(STRING_ALLOCATOR(this), ptr, this->res+1); } this->res = BUF_SIZE_CHAR-1; @@ -577,9 +585,9 @@ if(new_res/3 < this->res/2) new_res = this->res + this->res/2; - ptr = MSVCP_allocator_char_allocate(this->allocator, new_res+1); + ptr = MSVCP_allocator_char_allocate(STRING_ALLOCATOR(this), new_res+1); if(!ptr) - ptr = MSVCP_allocator_char_allocate(this->allocator, new_size+1); + ptr = MSVCP_allocator_char_allocate(STRING_ALLOCATOR(this), new_size+1); else new_size = new_res; if(!ptr) { @@ -988,7 +996,7 @@ MSVCP_size_t __thiscall basic_string_char_max_size(const basic_string_char *this) { TRACE("%p\n", this); - return MSVCP_allocator_char_max_size(this->allocator)-1; + return MSVCP_allocator_char_max_size(STRING_ALLOCATOR(this))-1; } /* ?empty@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBE_NXZ */ @@ -2228,7 +2236,7 @@ if(new_size > 0) MSVCP_char_traits_wchar__Copy_s(this->data.buf, BUF_SIZE_WCHAR, ptr, new_size); - MSVCP_allocator_wchar_deallocate(this->allocator, ptr, this->res+1); + MSVCP_allocator_wchar_deallocate(STRING_ALLOCATOR(this), ptr, this->res+1); } this->res = BUF_SIZE_WCHAR-1; @@ -2252,9 +2260,9 @@ if(new_res/3 < this->res/2) new_res = this->res + this->res/2; - ptr = MSVCP_allocator_wchar_allocate(this->allocator, new_res+1); + ptr = MSVCP_allocator_wchar_allocate(STRING_ALLOCATOR(this), new_res+1); if(!ptr) - ptr = MSVCP_allocator_wchar_allocate(this->allocator, new_size+1); + ptr = MSVCP_allocator_wchar_allocate(STRING_ALLOCATOR(this), new_size+1); else new_size = new_res; if(!ptr) { @@ -2733,7 +2741,7 @@ MSVCP_size_t __thiscall basic_string_wchar_max_size(const basic_string_wchar *this) { TRACE("%p\n", this); - return MSVCP_allocator_wchar_max_size(this->allocator)-1; + return MSVCP_allocator_wchar_max_size(STRING_ALLOCATOR(this))-1; } /* ?empty@?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBE_NXZ */ diff -Nru wine1.7-1.7.28/dlls/msvcp90/tests/ios.c wine1.7-1.7.31/dlls/msvcp90/tests/ios.c --- wine1.7-1.7.28/dlls/msvcp90/tests/ios.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/tests/ios.c 2014-11-14 13:28:17.000000000 +0000 @@ -422,6 +422,19 @@ int state; } fpos_int; +/* class complex */ +typedef struct { + float real; + float imag; +} complex_float; + +/* class complex */ +/* class complex */ +typedef struct { + double real; + double imag; +} complex_double; + /* stringstream */ static basic_stringstream_char* (*__thiscall p_basic_stringstream_char_ctor)(basic_stringstream_char*); static basic_stringstream_char* (*__thiscall p_basic_stringstream_char_ctor_str)(basic_stringstream_char*, const basic_string_char*, int, MSVCP_bool); @@ -442,6 +455,7 @@ /* istream */ static basic_istream_char* (*__thiscall p_basic_istream_char_read_uint64)(basic_istream_char*, unsigned __int64*); +static basic_istream_char* (*__thiscall p_basic_istream_char_read_float)(basic_istream_char*, float*); static basic_istream_char* (*__thiscall p_basic_istream_char_read_double)(basic_istream_char*, double*); static int (*__thiscall p_basic_istream_char_get)(basic_istream_char*); static MSVCP_bool (*__thiscall p_basic_istream_char_ipfx)(basic_istream_char*, MSVCP_bool); @@ -464,10 +478,18 @@ static basic_istream_wchar* (*__cdecl p_basic_istream_wchar_getline_bstr_delim)(basic_istream_wchar*, basic_string_wchar*, wchar_t); /* ostream */ +static basic_ostream_char* (*__thiscall p_basic_ostream_char_print_float)(basic_ostream_char*, float); + static basic_ostream_char* (*__thiscall p_basic_ostream_char_print_double)(basic_ostream_char*, double); static basic_ostream_wchar* (*__thiscall p_basic_ostream_wchar_print_double)(basic_ostream_wchar*, double); +static basic_ostream_char* (*__cdecl p_basic_ostream_char_print_complex_float)(basic_ostream_char*, complex_float*); + +static basic_ostream_char* (*__cdecl p_basic_ostream_char_print_complex_double)(basic_ostream_char*, complex_double*); + +static basic_ostream_char* (*__cdecl p_basic_ostream_char_print_complex_ldouble)(basic_ostream_char*, complex_double*); + static basic_ostream_wchar* (*__thiscall p_basic_ostream_short_print_ushort)(basic_ostream_wchar*, unsigned short); /* basic_ios */ @@ -544,6 +566,7 @@ /* to silence compiler errors */ static void * (WINAPI *call_thiscall_func2_ptr_dbl)( void *func, void *this, double a ); +static void * (WINAPI *call_thiscall_func2_ptr_flt)( void *func, void *this, float a ); static void * (WINAPI *call_thiscall_func2_ptr_fpos)( void *func, void *this, fpos_int a ); static void init_thiscall_thunk(void) @@ -562,6 +585,7 @@ call_thiscall_func5 = (void *)thunk; call_thiscall_func2_ptr_dbl = (void *)thunk; + call_thiscall_func2_ptr_flt = (void *)thunk; call_thiscall_func2_ptr_fpos = (void *)thunk; } @@ -574,6 +598,7 @@ (const void*)(c), (const void *)(d)) #define call_func2_ptr_dbl(func,_this,a) call_thiscall_func2_ptr_dbl(func,_this,a) +#define call_func2_ptr_flt(func,_this,a) call_thiscall_func2_ptr_flt(func,_this,a) #define call_func2_ptr_fpos(func,_this,a) call_thiscall_func2_ptr_fpos(func,_this,a) #else @@ -586,6 +611,7 @@ #define call_func5(func,_this,a,b,c,d) func(_this,a,b,c,d) #define call_func2_ptr_dbl call_func2 +#define call_func2_ptr_flt call_func2 #define call_func2_ptr_fpos call_func2 #endif /* __i386__ */ @@ -642,6 +668,8 @@ SET(p_basic_istream_char_read_uint64, "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_K@Z"); + SET(p_basic_istream_char_read_float, + "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAM@Z"); SET(p_basic_istream_char_read_double, "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAN@Z"); SET(p_basic_istream_char_get, @@ -682,6 +710,9 @@ SET(p_basic_istream_wchar_getline_bstr_delim, "??$getline@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@AEAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@_W@Z"); + SET(p_basic_ostream_char_print_float, + "??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@M@Z"); + SET(p_basic_ostream_char_print_double, "??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@N@Z"); @@ -691,6 +722,15 @@ SET(p_basic_ostream_short_print_ushort, "??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@G@Z"); + SET(p_basic_ostream_char_print_complex_float, + "??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z"); + + SET(p_basic_ostream_char_print_complex_double, + "??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z"); + + SET(p_basic_ostream_char_print_complex_ldouble, + "??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z"); + SET(p_ios_base_rdstate, "?rdstate@ios_base@std@@QEBAHXZ"); SET(p_ios_base_setf_mask, @@ -756,6 +796,8 @@ SET(p_basic_istream_char_read_uint64, "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AA_K@Z"); + SET(p_basic_istream_char_read_float, + "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAM@Z"); SET(p_basic_istream_char_read_double, "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAAAAV01@AAN@Z"); SET(p_basic_istream_char_get, @@ -796,6 +838,9 @@ SET(p_basic_istream_wchar_getline_bstr_delim, "??$getline@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@AAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@_W@Z"); + SET(p_basic_ostream_char_print_float, + "??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@M@Z"); + SET(p_basic_ostream_char_print_double, "??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAAAAV01@N@Z"); @@ -805,6 +850,15 @@ SET(p_basic_ostream_short_print_ushort, "??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAAAAV01@G@Z"); + SET(p_basic_ostream_char_print_complex_float, + "??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z"); + + SET(p_basic_ostream_char_print_complex_double, + "??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z"); + + SET(p_basic_ostream_char_print_complex_ldouble, + "??$?6ODU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@O@0@@Z"); + SET(p_ios_base_rdstate, "?rdstate@ios_base@std@@QBAHXZ"); SET(p_ios_base_setf_mask, @@ -869,6 +923,8 @@ SET(p_basic_istream_char_read_uint64, "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_K@Z"); + SET(p_basic_istream_char_read_float, + "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAM@Z"); SET(p_basic_istream_char_read_double, "??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAN@Z"); SET(p_basic_istream_char_get, @@ -909,6 +965,9 @@ SET(p_basic_istream_wchar_getline_bstr_delim, "??$getline@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@AAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@_W@Z"); + SET(p_basic_ostream_char_print_float, + "??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@M@Z"); + SET(p_basic_ostream_char_print_double, "??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@N@Z"); @@ -918,6 +977,15 @@ SET(p_basic_ostream_short_print_ushort, "??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@G@Z"); + SET(p_basic_ostream_char_print_complex_float, + "??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z"); + + SET(p_basic_ostream_char_print_complex_double, + "??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z"); + + SET(p_basic_ostream_char_print_complex_ldouble, + "??$?6ODU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@O@0@@Z"); + SET(p_ios_base_rdstate, "?rdstate@ios_base@std@@QBEHXZ"); SET(p_ios_base_setf_mask, @@ -1951,6 +2019,166 @@ call_func1(p_basic_stringstream_wchar_vbase_dtor, &wss); } +static void test_ostream_print_float(void) +{ + static const char float_str[] = "3.14159"; + + basic_stringstream_char ss; + basic_string_char pstr; + const char *str; + float val; + val = 3.14159; + + call_func1(p_basic_stringstream_char_ctor, &ss); + call_func2_ptr_flt(p_basic_ostream_char_print_float, &ss.base.base2, val); + call_func2(p_basic_stringstream_char_str_get, &ss, &pstr); + str = call_func1(p_basic_string_char_cstr, &pstr); + ok(!strcmp(float_str, str), "str = %s\n", str); + + call_func1(p_basic_string_char_dtor, &pstr); + call_func1(p_basic_stringstream_char_vbase_dtor, &ss); +} + +static void test_ostream_print_double(void) +{ + static const char double_str[] = "3.14159"; + + basic_stringstream_char ss; + basic_string_char pstr; + const char *str; + double val; + val = 3.14159; + + call_func1(p_basic_stringstream_char_ctor, &ss); + call_func2_ptr_dbl(p_basic_ostream_char_print_double, &ss.base.base2, val); + call_func2(p_basic_stringstream_char_str_get, &ss, &pstr); + str = call_func1(p_basic_string_char_cstr, &pstr); + ok(!strcmp(double_str, str), "str = %s\n", str); + + call_func1(p_basic_string_char_dtor, &pstr); + call_func1(p_basic_stringstream_char_vbase_dtor, &ss); +} + +static void test_ostream_wchar_print_double(void) +{ + static const wchar_t double_str[] = { '3', '.', '1', '4', '1', '5', '9', 0 }; + + basic_stringstream_wchar wss; + basic_string_wchar pwstr; + const wchar_t *wstr; + double val; + val = 3.14159; + + call_func1(p_basic_stringstream_wchar_ctor, &wss); + call_func2_ptr_dbl(p_basic_ostream_wchar_print_double, &wss.base.base2, val); + + call_func2(p_basic_stringstream_wchar_str_get, &wss, &pwstr); + wstr = call_func1(p_basic_string_wchar_cstr, &pwstr); + + ok(!lstrcmpW(double_str, wstr), "wstr = %s\n", wine_dbgstr_w(wstr)); + call_func1(p_basic_string_wchar_dtor, &pwstr); + call_func1(p_basic_stringstream_wchar_vbase_dtor, &wss); +} + +static void test_istream_read_float(void) +{ + basic_stringstream_char ss; + basic_string_char str; + const char *test_str; + float val, correct_val; + + test_str = "3.14159"; + call_func2(p_basic_string_char_ctor_cstr, &str, test_str); + call_func4(p_basic_stringstream_char_ctor_str, &ss, &str, OPENMODE_in, TRUE); + + val = 0; + call_func2(p_basic_istream_char_read_float, &ss.base.base1, &val); + correct_val = 3.14159; + ok(correct_val == val, "wrong val, expected = %g found %g\n", correct_val, val); + + call_func1(p_basic_stringstream_char_vbase_dtor, &ss); + call_func1(p_basic_string_char_dtor, &str); +} + +static void test_istream_read_double(void) +{ + basic_stringstream_char ss; + basic_string_char str; + const char *test_str; + double val, correct_val; + + test_str = "3.14159"; + call_func2(p_basic_string_char_ctor_cstr, &str, test_str); + call_func4(p_basic_stringstream_char_ctor_str, &ss, &str, OPENMODE_in, TRUE); + + val = 0; + call_func2(p_basic_istream_char_read_double, &ss.base.base1, &val); + correct_val = 3.14159; + ok(correct_val == val, "wrong val, expected = %g found %g\n", correct_val, val); + + call_func1(p_basic_stringstream_char_vbase_dtor, &ss); + call_func1(p_basic_string_char_dtor, &str); +} + +static void test_ostream_print_complex_float(void) +{ + static const char complex_float_str[] = "(3.14,1.57)"; + + basic_stringstream_char ss; + basic_string_char pstr; + const char *str; + complex_float val = {3.14, 1.57}; + + call_func1(p_basic_stringstream_char_ctor, &ss); + p_basic_ostream_char_print_complex_float(&ss.base.base2, &val); + + call_func2(p_basic_stringstream_char_str_get, &ss, &pstr); + str = call_func1(p_basic_string_char_cstr, &pstr); + ok(!strcmp(complex_float_str, str), "str = %s\n", str); + + call_func1(p_basic_string_char_dtor, &pstr); + call_func1(p_basic_stringstream_char_vbase_dtor, &ss); +} + +static void test_ostream_print_complex_double(void) +{ + static const char complex_double_str[] = "(3.14159,1.23459)"; + + basic_stringstream_char ss; + basic_string_char pstr; + const char *str; + complex_double val= {3.14159, 1.23459}; + + call_func1(p_basic_stringstream_char_ctor, &ss); + p_basic_ostream_char_print_complex_double(&ss.base.base2, &val); + + call_func2(p_basic_stringstream_char_str_get, &ss, &pstr); + str = call_func1(p_basic_string_char_cstr, &pstr); + ok(!strcmp(complex_double_str, str), "str = %s\n", str); + + call_func1(p_basic_string_char_dtor, &pstr); + call_func1(p_basic_stringstream_char_vbase_dtor, &ss); +} + +static void test_ostream_print_complex_ldouble(void) +{ + static const char complex_double_str[] = "(3.14159,1.23459)"; + + basic_stringstream_char ss; + basic_string_char pstr; + const char *str; + complex_double val = {3.14159, 1.23459}; + + call_func1(p_basic_stringstream_char_ctor, &ss); + p_basic_ostream_char_print_complex_ldouble(&ss.base.base2, &val); + + call_func2(p_basic_stringstream_char_str_get, &ss, &pstr); + str = call_func1(p_basic_string_char_cstr, &pstr); + ok(!strcmp(complex_double_str, str), "str = %s\n", str); + + call_func1(p_basic_string_char_dtor, &pstr); + call_func1(p_basic_stringstream_char_vbase_dtor, &ss); +} START_TEST(ios) { @@ -1968,6 +2196,14 @@ test_istream_tellg(); test_istream_getline(); test_ostream_print_ushort(); + test_ostream_print_float(); + test_ostream_print_double(); + test_ostream_wchar_print_double(); + test_istream_read_float(); + test_istream_read_double(); + test_ostream_print_complex_float(); + test_ostream_print_complex_double(); + test_ostream_print_complex_ldouble(); ok(!invalid_parameter, "invalid_parameter_handler was invoked too many times\n"); diff -Nru wine1.7-1.7.28/dlls/msvcp90/tests/misc.c wine1.7-1.7.31/dlls/msvcp90/tests/misc.c --- wine1.7-1.7.28/dlls/msvcp90/tests/misc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcp90/tests/misc.c 2014-11-14 13:28:17.000000000 +0000 @@ -19,6 +19,7 @@ #include #include #include +#include #include #include @@ -26,6 +27,8 @@ #include #include "wine/test.h" +typedef double LDOUBLE; /* long double is just a double */ + typedef struct { LCID handle; unsigned page; @@ -110,6 +113,10 @@ static void (__thiscall *p_basic_ostringstream_char_vbase_dtor)(/*basic_ostringstream_char*/void*); static void (__thiscall *p_basic_ios_char_dtor)(/*basic_ios_char*/void*); +static BOOL (__cdecl *p_std_Ctraits_float__Isnan)(float); +static BOOL (__cdecl *p_std_Ctraits_double__Isnan)(double); +static BOOL (__cdecl *p_std_Ctraits_long_double__Isnan)(LDOUBLE); + static complex_float* (__thiscall *p_complex_float_ctor)(complex_float*, const float*, const float*); static complex_float* (__cdecl *p_complex_float_add)(complex_float*, const complex_float*, const complex_float*); static complex_float* (__cdecl *p_complex_float_div)(complex_float*, const complex_float*, const complex_float*); @@ -216,6 +223,11 @@ SET(p_wctrans, "wctrans"); SET(p_towctrans, "towctrans"); SET(basic_ostringstream_char_vbtable, "??_8?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B@"); + + SET(p_std_Ctraits_float__Isnan, "?_Isnan@?$_Ctraits@M@std@@SA_NM@Z"); + SET(p_std_Ctraits_double__Isnan, "?_Isnan@?$_Ctraits@N@std@@SA_NN@Z"); + SET(p_std_Ctraits_long_double__Isnan, "?_Isnan@?$_Ctraits@O@std@@SA_NO@Z"); + if(sizeof(void*) == 8) { /* 64-bit initialization */ SET(p_char_assign, "?assign@?$char_traits@D@std@@SAXAEADAEBD@Z"); SET(p_wchar_assign, "?assign@?$char_traits@_W@std@@SAXAEA_WAEB_W@Z"); @@ -688,6 +700,41 @@ return f1 < 0.0001; } +static void test_Ctraits_math_functions(void) +{ + BYTE ret; + + ret = p_std_Ctraits_float__Isnan(0.0); + ok(ret == FALSE, "ret = %d\n", ret); + + ret = p_std_Ctraits_float__Isnan(0.0 / 0.0); + ok(ret == TRUE, "ret = %d\n", ret); + + ret = p_std_Ctraits_float__Isnan(1.0 / 0.0); + ok(ret == FALSE, "ret = %d\n", ret); + + ret = p_std_Ctraits_float__Isnan(-1.0 / 0.0); + ok(ret == FALSE, "ret = %d\n", ret); + + ret = p_std_Ctraits_float__Isnan(log(-1.0)); + ok(ret == TRUE, "ret = %d\n", ret); + + ret = p_std_Ctraits_float__Isnan(sqrt(-1.0)); + ok(ret == TRUE, "ret = %d\n", ret); + + ret = p_std_Ctraits_double__Isnan(3.14159 / 0.0); + ok(ret == FALSE, "ret = %d\n", ret); + + ret = p_std_Ctraits_double__Isnan(log(-3.14159)); + ok(ret == TRUE, "ret = %d\n", ret); + + ret = p_std_Ctraits_long_double__Isnan(3.14159 / 0.0); + ok(ret == FALSE, "ret = %d\n", ret); + + ret = p_std_Ctraits_long_double__Isnan(sqrt(-3.14159)); + ok(ret == TRUE, "ret = %d\n", ret); +} + static void test_complex(void) { complex_float c1, c2, c3; @@ -935,6 +982,7 @@ test_virtual_call(); test_virtual_base_dtors(); test_allocator_char(); + test_Ctraits_math_functions(); test_complex(); ok(!invalid_parameter, "invalid_parameter_handler was invoked too many times\n"); diff -Nru wine1.7-1.7.28/dlls/msvcr100/msvcr100.spec wine1.7-1.7.31/dlls/msvcr100/msvcr100.spec --- wine1.7-1.7.28/dlls/msvcr100/msvcr100.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcr100/msvcr100.spec 2014-11-14 13:28:17.000000000 +0000 @@ -794,14 +794,15 @@ @ cdecl _execvpe(str ptr ptr) @ cdecl _exit(long) MSVCRT__exit @ cdecl _expand(ptr long) -@ stub _fclose_nolock +@ cdecl _fclose_nolock(ptr) MSVCRT__fclose_nolock @ cdecl _fcloseall() MSVCRT__fcloseall @ cdecl _fcvt(double long ptr ptr) MSVCRT__fcvt @ cdecl _fcvt_s(ptr long double long ptr ptr) MSVCRT__fcvt_s @ cdecl _fdopen(long str) MSVCRT__fdopen -@ stub _fflush_nolock +@ cdecl _fflush_nolock(ptr) MSVCRT__fflush_nolock +@ cdecl _fgetc_nolock(ptr) MSVCRT__fgetc_nolock @ cdecl _fgetchar() MSVCRT__fgetchar -@ stub _fgetwc_nolock +@ cdecl _fgetwc_nolock(ptr) MSVCRT__fgetwc_nolock @ cdecl _fgetwchar() MSVCRT__fgetwchar @ cdecl _filbuf(ptr) MSVCRT__filbuf @ cdecl _filelength(long) MSVCRT__filelength @@ -829,28 +830,29 @@ @ stub _fprintf_p @ stub _fprintf_p_l @ stub _fprintf_s_l +@ cdecl _fputc_nolock(long ptr) MSVCRT__fputc_nolock @ cdecl _fputchar(long) MSVCRT__fputchar -@ stub _fputwc_nolock +@ cdecl _fputwc_nolock(long ptr) MSVCRT__fputwc_nolock @ cdecl _fputwchar(long) MSVCRT__fputwchar -@ stub _fread_nolock -@ stub _fread_nolock_s +@ cdecl _fread_nolock(ptr long long ptr) MSVCRT__fread_nolock +@ cdecl _fread_nolock_s(ptr long long long ptr) MSVCRT__fread_nolock_s @ cdecl _free_locale(ptr) MSVCRT__free_locale @ stub _freea @ stub _freea_s @ stub _freefls @ varargs _fscanf_l(ptr str ptr) MSVCRT__fscanf_l @ varargs _fscanf_s_l(ptr str ptr) MSVCRT__fscanf_s_l -@ stub _fseek_nolock +@ cdecl _fseek_nolock(ptr long long) MSVCRT__fseek_nolock @ cdecl _fseeki64(ptr int64 long) MSVCRT__fseeki64 -@ stub _fseeki64_nolock +@ cdecl _fseeki64_nolock(ptr int64 long) MSVCRT__fseeki64_nolock @ cdecl _fsopen(str str long) MSVCRT__fsopen @ cdecl _fstat32(long ptr) MSVCRT__fstat32 @ stub _fstat32i64 @ cdecl _fstat64(long ptr) MSVCRT__fstat64 @ cdecl _fstat64i32(long ptr) MSVCRT__fstat64i32 -@ stub _ftell_nolock +@ cdecl _ftell_nolock(ptr) MSVCRT__ftell_nolock @ cdecl -ret64 _ftelli64(ptr) MSVCRT__ftelli64 -@ stub _ftelli64_nolock +@ cdecl -ret64 _ftelli64_nolock(ptr) MSVCRT__ftelli64_nolock @ cdecl _ftime32(ptr) MSVCRT__ftime32 @ cdecl _ftime32_s(ptr) MSVCRT__ftime32_s @ cdecl _ftime64(ptr) MSVCRT__ftime64 @@ -863,7 +865,7 @@ @ stub _fwprintf_p @ stub _fwprintf_p_l @ stub _fwprintf_s_l -@ stub _fwrite_nolock +@ cdecl _fwrite_nolock(ptr long long ptr) MSVCRT__fwrite_nolock @ varargs _fwscanf_l(ptr wstr ptr) MSVCRT__fwscanf_l @ varargs _fwscanf_s_l(ptr wstr ptr) MSVCRT__fwscanf_s_l @ cdecl _gcvt(double long str) MSVCRT__gcvt @@ -886,7 +888,7 @@ @ cdecl _get_tzname(ptr str long long) MSVCRT__get_tzname @ cdecl _get_unexpected() MSVCRT__get_unexpected @ cdecl _get_wpgmptr(ptr) -@ stub _getc_nolock +@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock @ cdecl _getch() @ stub _getch_nolock @ cdecl _getche() @@ -904,6 +906,7 @@ @ cdecl _getptd() @ stub _getsystime(ptr) @ cdecl _getw(ptr) MSVCRT__getw +@ cdecl _getwc_nolock(ptr) MSVCRT__fgetwc_nolock @ stub _getwch @ stub _getwch_nolock @ stub _getwche @@ -1229,11 +1232,13 @@ @ stub _printf_p_l @ stub _printf_s_l @ cdecl _purecall() +@ cdecl _putc_nolock(long ptr) MSVCRT__fputc_nolock @ cdecl _putch(long) @ stub _putch_nolock @ cdecl _putenv(str) @ cdecl _putenv_s(str str) @ cdecl _putw(long ptr) MSVCRT__putw +@ cdecl _putwc_nolock(long ptr) MSVCRT__fputwc_nolock @ cdecl _putwch(long) MSVCRT__putwch @ stub _putwch_nolock @ cdecl _putws(wstr) MSVCRT__putws @@ -1289,7 +1294,7 @@ @ varargs _snprintf(ptr long str) MSVCRT__snprintf @ stub _snprintf_c @ stub _snprintf_c_l -@ stub _snprintf_l +@ varargs _snprintf_l(ptr long str ptr) MSVCRT__snprintf_l @ varargs _snprintf_s(ptr long long str) MSVCRT__snprintf_s @ stub _snprintf_s_l @ varargs _snscanf(str long str) MSVCRT__snscanf @@ -1362,7 +1367,7 @@ @ stub _strtol_l @ cdecl -ret64 _strtoui64(str ptr long) MSVCRT_strtoui64 @ cdecl -ret64 _strtoui64_l(str ptr long ptr) MSVCRT_strtoui64_l -@ stub _strtoul_l +@ cdecl _strtoul_l(str ptr long ptr) MSVCRT_strtoul_l @ cdecl _strupr(str) MSVCRT__strupr @ cdecl _strupr_l(str ptr) MSVCRT__strupr_l @ cdecl _strupr_s(str long) MSVCRT__strupr_s @@ -1403,10 +1408,10 @@ @ cdecl _ultow_s(long ptr long long) MSVCRT__ultow_s @ cdecl _umask(long) MSVCRT__umask @ stub _umask_s -@ stub _ungetc_nolock +@ cdecl _ungetc_nolock(long ptr) MSVCRT__ungetc_nolock @ cdecl _ungetch(long) @ stub _ungetch_nolock -@ stub _ungetwc_nolock +@ cdecl _ungetwc_nolock(long ptr) MSVCRT__ungetwc_nolock @ stub _ungetwch @ stub _ungetwch_nolock @ cdecl _unlink(str) MSVCRT__unlink @@ -1497,7 +1502,7 @@ @ cdecl _wcsncoll(wstr wstr long) MSVCRT__wcsncoll @ cdecl _wcsncoll_l(wstr wstr long ptr) MSVCRT__wcsncoll_l @ cdecl _wcsnicmp(wstr wstr long) MSVCRT__wcsnicmp -@ stub _wcsnicmp_l +@ cdecl _wcsnicmp_l(wstr wstr long ptr) MSVCRT__wcsnicmp_l @ cdecl _wcsnicoll(wstr wstr long) MSVCRT__wcsnicoll @ cdecl _wcsnicoll_l(wstr wstr long ptr) MSVCRT__wcsnicoll_l @ cdecl _wcsnset(wstr long long) MSVCRT__wcsnset diff -Nru wine1.7-1.7.28/dlls/msvcr100/tests/msvcr100.c wine1.7-1.7.31/dlls/msvcr100/tests/msvcr100.c --- wine1.7-1.7.28/dlls/msvcr100/tests/msvcr100.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcr100/tests/msvcr100.c 2014-11-14 13:28:17.000000000 +0000 @@ -140,6 +140,8 @@ static FILE* (__cdecl *p_fopen)(const char*,const char*); static int (__cdecl *p_fclose)(FILE*); static size_t (__cdecl *p_fread_s)(void*,size_t,size_t,size_t,FILE*); +static void (__cdecl *p_lock_file)(FILE*); +static void (__cdecl *p_unlock_file)(FILE*); static void* (__cdecl *p__aligned_offset_malloc)(size_t, size_t, size_t); static void (__cdecl *p__aligned_free)(void*); static size_t (__cdecl *p__aligned_msize)(void*, size_t, size_t); @@ -178,6 +180,8 @@ SET(p_fopen, "fopen"); SET(p_fclose, "fclose"); SET(p_fread_s, "fread_s"); + SET(p_lock_file, "_lock_file"); + SET(p_unlock_file, "_unlock_file"); SET(p__aligned_offset_malloc, "_aligned_offset_malloc"); SET(p__aligned_free, "_aligned_free"); SET(p__aligned_msize, "_aligned_msize"); @@ -357,11 +361,30 @@ "Cannot reset invalid parameter handler\n"); } +struct block_file_arg +{ + FILE *test_file; + HANDLE init; + HANDLE finish; +}; + +static DWORD WINAPI block_file(void *arg) +{ + struct block_file_arg *files = arg; + p_lock_file(files->test_file); + SetEvent(files->init); + WaitForSingleObject(files->finish, INFINITE); + p_unlock_file(files->test_file); + return 0; +} + static void test_fread_s(void) { static const char test_file[] = "fread_s.tst"; int ret; char buf[10]; + HANDLE thread; + struct block_file_arg arg; FILE *f = fopen(test_file, "w"); if(!f) { @@ -382,6 +405,12 @@ CHECK_CALLED(invalid_parameter_handler); f = p_fopen(test_file, "r"); + arg.test_file = f; + arg.init = CreateEventW(NULL, FALSE, FALSE, NULL); + arg.finish = CreateEventW(NULL, FALSE, FALSE, NULL); + thread = CreateThread(NULL, 0, block_file, (void*)&arg, 0, NULL); + WaitForSingleObject(arg.init, INFINITE); + errno = 0xdeadbeef; ret = p_fread_s(NULL, sizeof(buf), 0, 1, f); ok(ret == 0, "fread_s returned %d, expected 0\n", ret); @@ -390,6 +419,9 @@ ok(ret == 0, "fread_s returned %d, expected 0\n", ret); ok(errno == 0xdeadbeef, "errno = %d, expected 0xdeadbeef\n", errno); + SetEvent(arg.finish); + WaitForSingleObject(thread, INFINITE); + SET_EXPECT(invalid_parameter_handler); errno = 0xdeadbeef; ret = p_fread_s(NULL, sizeof(buf), 1, 1, f); @@ -426,6 +458,9 @@ ok(p_set_invalid_parameter_handler(NULL) == test_invalid_parameter_handler, "Cannot reset invalid parameter handler\n"); + CloseHandle(arg.init); + CloseHandle(arg.finish); + CloseHandle(thread); unlink(test_file); } diff -Nru wine1.7-1.7.28/dlls/msvcr110/msvcr110.spec wine1.7-1.7.31/dlls/msvcr110/msvcr110.spec --- wine1.7-1.7.28/dlls/msvcr110/msvcr110.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcr110/msvcr110.spec 2014-11-14 13:28:17.000000000 +0000 @@ -1142,14 +1142,15 @@ @ cdecl _execvpe(str ptr ptr) @ cdecl _exit(long) MSVCRT__exit @ cdecl _expand(ptr long) -@ stub _fclose_nolock +@ cdecl _fclose_nolock(ptr) MSVCRT__fclose_nolock @ cdecl _fcloseall() MSVCRT__fcloseall @ cdecl _fcvt(double long ptr ptr) MSVCRT__fcvt @ cdecl _fcvt_s(ptr long double long ptr ptr) MSVCRT__fcvt_s @ cdecl _fdopen(long str) MSVCRT__fdopen -@ stub _fflush_nolock +@ cdecl _fflush_nolock(ptr) MSVCRT__fflush_nolock +@ cdecl _fgetc_nolock(ptr) MSVCRT__fgetc_nolock @ cdecl _fgetchar() MSVCRT__fgetchar -@ stub _fgetwc_nolock +@ cdecl _fgetwc_nolock(ptr) MSVCRT__fgetwc_nolock @ cdecl _fgetwchar() MSVCRT__fgetwchar @ cdecl _filbuf(ptr) MSVCRT__filbuf @ cdecl _filelength(long) MSVCRT__filelength @@ -1177,28 +1178,29 @@ @ stub _fprintf_p @ stub _fprintf_p_l @ stub _fprintf_s_l +@ cdecl _fputc_nolock(long ptr) MSVCRT__fputc_nolock @ cdecl _fputchar(long) MSVCRT__fputchar -@ stub _fputwc_nolock +@ cdecl _fputwc_nolock(long ptr) MSVCRT__fputwc_nolock @ cdecl _fputwchar(long) MSVCRT__fputwchar -@ stub _fread_nolock -@ stub _fread_nolock_s +@ cdecl _fread_nolock(ptr long long ptr) MSVCRT__fread_nolock +@ cdecl _fread_nolock_s(ptr long long long ptr) MSVCRT__fread_nolock_s @ cdecl _free_locale(ptr) MSVCRT__free_locale @ stub _freea @ stub _freea_s @ stub _freefls @ varargs _fscanf_l(ptr str ptr) MSVCRT__fscanf_l @ varargs _fscanf_s_l(ptr str ptr) MSVCRT__fscanf_s_l -@ stub _fseek_nolock +@ cdecl _fseek_nolock(ptr long long) MSVCRT__fseek_nolock @ cdecl _fseeki64(ptr int64 long) MSVCRT__fseeki64 -@ stub _fseeki64_nolock +@ cdecl _fseeki64_nolock(ptr int64 long) MSVCRT__fseeki64_nolock @ cdecl _fsopen(str str long) MSVCRT__fsopen @ cdecl _fstat32(long ptr) MSVCRT__fstat32 @ stub _fstat32i64 @ cdecl _fstat64(long ptr) MSVCRT__fstat64 @ cdecl _fstat64i32(long ptr) MSVCRT__fstat64i32 -@ stub _ftell_nolock +@ cdecl _ftell_nolock(ptr) MSVCRT__ftell_nolock @ cdecl -ret64 _ftelli64(ptr) MSVCRT__ftelli64 -@ stub _ftelli64_nolock +@ cdecl -ret64 _ftelli64_nolock(ptr) MSVCRT__ftelli64_nolock @ cdecl _ftime32(ptr) MSVCRT__ftime32 @ cdecl _ftime32_s(ptr) MSVCRT__ftime32_s @ cdecl _ftime64(ptr) MSVCRT__ftime64 @@ -1211,7 +1213,7 @@ @ stub _fwprintf_p @ stub _fwprintf_p_l @ stub _fwprintf_s_l -@ stub _fwrite_nolock +@ cdecl _fwrite_nolock(ptr long long ptr) MSVCRT__fwrite_nolock @ varargs _fwscanf_l(ptr wstr ptr) MSVCRT__fwscanf_l @ varargs _fwscanf_s_l(ptr wstr ptr) MSVCRT__fwscanf_s_l @ cdecl _gcvt(double long str) MSVCRT__gcvt @@ -1234,7 +1236,7 @@ @ cdecl _get_tzname(ptr str long long) MSVCRT__get_tzname @ cdecl _get_unexpected() MSVCRT__get_unexpected @ cdecl _get_wpgmptr(ptr) -@ stub _getc_nolock +@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock @ cdecl _getch() @ stub _getch_nolock @ cdecl _getche() @@ -1251,6 +1253,7 @@ @ cdecl _getptd() @ stub _getsystime(ptr) @ cdecl _getw(ptr) MSVCRT__getw +@ cdecl _getwc_nolock(ptr) MSVCRT__fgetwc_nolock @ stub _getwch @ stub _getwch_nolock @ stub _getwche @@ -1587,11 +1590,13 @@ @ stub _printf_p_l @ stub _printf_s_l @ cdecl _purecall() +@ cdecl _putc_nolock(long ptr) MSVCRT__fputc_nolock @ cdecl _putch(long) @ stub _putch_nolock @ cdecl _putenv(str) @ cdecl _putenv_s(str str) @ cdecl _putw(long ptr) MSVCRT__putw +@ cdecl _putwc_nolock(long ptr) MSVCRT__fputwc_nolock @ cdecl _putwch(long) MSVCRT__putwch @ stub _putwch_nolock @ cdecl _putws(wstr) MSVCRT__putws @@ -1647,7 +1652,7 @@ @ varargs _snprintf(ptr long str) MSVCRT__snprintf @ stub _snprintf_c @ stub _snprintf_c_l -@ stub _snprintf_l +@ varargs _snprintf_l(ptr long str ptr) MSVCRT__snprintf_l @ varargs _snprintf_s(ptr long long str) MSVCRT__snprintf_s @ stub _snprintf_s_l @ varargs _snscanf(str long str) MSVCRT__snscanf @@ -1720,7 +1725,7 @@ @ stub _strtol_l @ cdecl -ret64 _strtoui64(str ptr long) MSVCRT_strtoui64 @ cdecl -ret64 _strtoui64_l(str ptr long ptr) MSVCRT_strtoui64_l -@ stub _strtoul_l +@ cdecl _strtoul_l(str ptr long ptr) MSVCRT_strtoul_l @ cdecl _strupr(str) MSVCRT__strupr @ cdecl _strupr_l(str ptr) MSVCRT__strupr_l @ cdecl _strupr_s(str long) MSVCRT__strupr_s @@ -1761,10 +1766,10 @@ @ cdecl _ultow_s(long ptr long long) MSVCRT__ultow_s @ cdecl _umask(long) MSVCRT__umask @ stub _umask_s -@ stub _ungetc_nolock +@ cdecl _ungetc_nolock(long ptr) MSVCRT__ungetc_nolock @ cdecl _ungetch(long) @ stub _ungetch_nolock -@ stub _ungetwc_nolock +@ cdecl _ungetwc_nolock(long ptr) MSVCRT__ungetwc_nolock @ stub _ungetwch @ stub _ungetwch_nolock @ cdecl _unlink(str) MSVCRT__unlink @@ -1856,7 +1861,7 @@ @ cdecl _wcsncoll(wstr wstr long) MSVCRT__wcsncoll @ cdecl _wcsncoll_l(wstr wstr long ptr) MSVCRT__wcsncoll_l @ cdecl _wcsnicmp(wstr wstr long) MSVCRT__wcsnicmp -@ stub _wcsnicmp_l +@ cdecl _wcsnicmp_l(wstr wstr long ptr) MSVCRT__wcsnicmp_l @ cdecl _wcsnicoll(wstr wstr long) MSVCRT__wcsnicoll @ cdecl _wcsnicoll_l(wstr wstr long ptr) MSVCRT__wcsnicoll_l @ cdecl _wcsnset(wstr long long) MSVCRT__wcsnset diff -Nru wine1.7-1.7.28/dlls/msvcr120/Makefile.in wine1.7-1.7.31/dlls/msvcr120/Makefile.in --- wine1.7-1.7.28/dlls/msvcr120/Makefile.in 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcr120/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,34 @@ +EXTRADEFS = -D_MT -D_MSVCR_VER=120 +MODULE = msvcr120.dll +IMPORTLIB = msvcr120 +DELAYIMPORTS = advapi32 user32 +PARENTSRC = ../msvcrt + +C_SRCS = \ + console.c \ + cpp.c \ + ctype.c \ + data.c \ + dir.c \ + environ.c \ + errno.c \ + except.c \ + except_arm.c \ + except_i386.c \ + except_x86_64.c \ + exit.c \ + file.c \ + heap.c \ + locale.c \ + lock.c \ + main.c \ + math.c \ + mbcs.c \ + misc.c \ + process.c \ + scanf.c \ + string.c \ + thread.c \ + time.c \ + undname.c \ + wcs.c diff -Nru wine1.7-1.7.28/dlls/msvcr120/msvcr120.spec wine1.7-1.7.31/dlls/msvcr120/msvcr120.spec --- wine1.7-1.7.28/dlls/msvcr120/msvcr120.spec 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcr120/msvcr120.spec 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,2493 @@ +# MS VC++2013 runtime library + +@ cdecl -arch=arm ??0?$_SpinWait@$00@details@Concurrency@@QAA@P6AXXZ@Z(ptr ptr) SpinWait_ctor_yield +@ thiscall -arch=i386 ??0?$_SpinWait@$00@details@Concurrency@@QAE@P6AXXZ@Z(ptr ptr) SpinWait_ctor_yield +@ cdecl -arch=win64 ??0?$_SpinWait@$00@details@Concurrency@@QEAA@P6AXXZ@Z(ptr ptr) SpinWait_ctor_yield +@ cdecl -arch=arm ??0?$_SpinWait@$0A@@details@Concurrency@@QAA@P6AXXZ@Z(ptr ptr) SpinWait_ctor +@ thiscall -arch=i386 ??0?$_SpinWait@$0A@@details@Concurrency@@QAE@P6AXXZ@Z(ptr ptr) SpinWait_ctor +@ cdecl -arch=win64 ??0?$_SpinWait@$0A@@details@Concurrency@@QEAA@P6AXXZ@Z(ptr ptr) SpinWait_ctor +@ stub -arch=win32 ??0SchedulerPolicy@Concurrency@@QAA@IZZ +@ stub -arch=win64 ??0SchedulerPolicy@Concurrency@@QEAA@_KZZ +@ stub -arch=arm ??0SchedulerPolicy@Concurrency@@QAA@ABV01@@Z +@ stub -arch=i386 ??0SchedulerPolicy@Concurrency@@QAE@ABV01@@Z +@ stub -arch=win64 ??0SchedulerPolicy@Concurrency@@QEAA@AEBV01@@Z +@ stub -arch=arm ??0SchedulerPolicy@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0SchedulerPolicy@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0SchedulerPolicy@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_Cancellation_beacon@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_Cancellation_beacon@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_Cancellation_beacon@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_Condition_variable@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_Condition_variable@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_Condition_variable@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_Context@details@Concurrency@@QAA@PAVContext@2@@Z +@ stub -arch=i386 ??0_Context@details@Concurrency@@QAE@PAVContext@2@@Z +@ stub -arch=win64 ??0_Context@details@Concurrency@@QEAA@PEAVContext@2@@Z +@ stub -arch=arm ??0_Interruption_exception@details@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0_Interruption_exception@details@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0_Interruption_exception@details@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0_Interruption_exception@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_Interruption_exception@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_Interruption_exception@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_NonReentrantBlockingLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_NonReentrantBlockingLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_NonReentrantBlockingLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_NonReentrantPPLLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_NonReentrantPPLLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_NonReentrantPPLLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_ReaderWriterLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_ReaderWriterLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_ReaderWriterLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_ReentrantBlockingLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_ReentrantBlockingLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_ReentrantBlockingLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_ReentrantLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_ReentrantLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_ReentrantLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_ReentrantPPLLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_ReentrantPPLLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_ReentrantPPLLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_Scheduler@details@Concurrency@@QAA@PAVScheduler@2@@Z +@ stub -arch=i386 ??0_Scheduler@details@Concurrency@@QAE@PAVScheduler@2@@Z +@ stub -arch=win64 ??0_Scheduler@details@Concurrency@@QEAA@PEAVScheduler@2@@Z +@ stub -arch=arm ??0_Scoped_lock@_NonReentrantPPLLock@details@Concurrency@@QAA@AAV123@@Z +@ stub -arch=i386 ??0_Scoped_lock@_NonReentrantPPLLock@details@Concurrency@@QAE@AAV123@@Z +@ stub -arch=win64 ??0_Scoped_lock@_NonReentrantPPLLock@details@Concurrency@@QEAA@AEAV123@@Z +@ stub -arch=arm ??0_Scoped_lock@_ReentrantPPLLock@details@Concurrency@@QAA@AAV123@@Z +@ stub -arch=i386 ??0_Scoped_lock@_ReentrantPPLLock@details@Concurrency@@QAE@AAV123@@Z +@ stub -arch=win64 ??0_Scoped_lock@_ReentrantPPLLock@details@Concurrency@@QEAA@AEAV123@@Z +@ stub -arch=arm ??0_SpinLock@details@Concurrency@@QAA@ACJ@Z +@ stub -arch=i386 ??0_SpinLock@details@Concurrency@@QAE@ACJ@Z +@ stub -arch=win64 ??0_SpinLock@details@Concurrency@@QEAA@AECJ@Z +@ stub -arch=arm ??0_StructuredTaskCollection@details@Concurrency@@QAA@PAV_CancellationTokenState@12@@Z +@ stub -arch=i386 ??0_StructuredTaskCollection@details@Concurrency@@QAE@PAV_CancellationTokenState@12@@Z +@ stub -arch=win64 ??0_StructuredTaskCollection@details@Concurrency@@QEAA@PEAV_CancellationTokenState@12@@Z +@ stub -arch=arm ??0_TaskCollection@details@Concurrency@@QAA@PAV_CancellationTokenState@12@@Z +@ stub -arch=i386 ??0_TaskCollection@details@Concurrency@@QAE@PAV_CancellationTokenState@12@@Z +@ stub -arch=win64 ??0_TaskCollection@details@Concurrency@@QEAA@PEAV_CancellationTokenState@12@@Z +@ stub -arch=arm ??0_TaskCollection@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0_TaskCollection@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0_TaskCollection@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0_Timer@details@Concurrency@@IAA@I_N@Z +@ stub -arch=i386 ??0_Timer@details@Concurrency@@IAE@I_N@Z +@ stub -arch=win64 ??0_Timer@details@Concurrency@@IEAA@I_N@Z +@ cdecl -arch=arm ??0__non_rtti_object@std@@QAA@ABV01@@Z(ptr ptr) MSVCRT___non_rtti_object_copy_ctor +@ thiscall -arch=i386 ??0__non_rtti_object@std@@QAE@ABV01@@Z(ptr ptr) MSVCRT___non_rtti_object_copy_ctor +@ cdecl -arch=win64 ??0__non_rtti_object@std@@QEAA@AEBV01@@Z(ptr ptr) MSVCRT___non_rtti_object_copy_ctor +@ cdecl -arch=arm ??0__non_rtti_object@std@@QAA@PBD@Z(ptr ptr) MSVCRT___non_rtti_object_ctor +@ thiscall -arch=i386 ??0__non_rtti_object@std@@QAE@PBD@Z(ptr ptr) MSVCRT___non_rtti_object_ctor +@ cdecl -arch=win64 ??0__non_rtti_object@std@@QEAA@PEBD@Z(ptr ptr) MSVCRT___non_rtti_object_ctor +@ cdecl -arch=arm ??0bad_cast@std@@AAA@PBQBD@Z(ptr ptr) MSVCRT_bad_cast_ctor +@ thiscall -arch=i386 ??0bad_cast@std@@AAE@PBQBD@Z(ptr ptr) MSVCRT_bad_cast_ctor +@ cdecl -arch=win64 ??0bad_cast@std@@AEAA@PEBQEBD@Z(ptr ptr) MSVCRT_bad_cast_ctor +@ cdecl -arch=arm ??0bad_cast@std@@QAA@ABV01@@Z(ptr ptr) MSVCRT_bad_cast_ctor +@ thiscall -arch=i386 ??0bad_cast@std@@QAE@ABV01@@Z(ptr ptr) MSVCRT_bad_cast_copy_ctor +@ cdecl -arch=win64 ??0bad_cast@std@@QEAA@AEBV01@@Z(ptr ptr) MSVCRT_bad_cast_copy_ctor +@ cdecl -arch=arm ??0bad_cast@std@@QAA@PBD@Z(ptr str) MSVCRT_bad_cast_ctor_charptr +@ thiscall -arch=i386 ??0bad_cast@std@@QAE@PBD@Z(ptr str) MSVCRT_bad_cast_ctor_charptr +@ cdecl -arch=win64 ??0bad_cast@std@@QEAA@PEBD@Z(ptr str) MSVCRT_bad_cast_ctor_charptr +@ stub -arch=arm ??0bad_target@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0bad_target@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0bad_target@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0bad_target@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0bad_target@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0bad_target@Concurrency@@QEAA@XZ +@ cdecl -arch=arm ??0bad_typeid@std@@QAA@ABV01@@Z(ptr ptr) MSVCRT_bad_typeid_copy_ctor +@ thiscall -arch=i386 ??0bad_typeid@std@@QAE@ABV01@@Z(ptr ptr) MSVCRT_bad_typeid_copy_ctor +@ cdecl -arch=win64 ??0bad_typeid@std@@QEAA@AEBV01@@Z(ptr ptr) MSVCRT_bad_typeid_copy_ctor +@ cdecl -arch=arm ??0bad_typeid@std@@QAA@PBD@Z(ptr str) MSVCRT_bad_typeid_ctor +@ thiscall -arch=i386 ??0bad_typeid@std@@QAE@PBD@Z(ptr str) MSVCRT_bad_typeid_ctor +@ cdecl -arch=win64 ??0bad_typeid@std@@QEAA@PEBD@Z(ptr str) MSVCRT_bad_typeid_ctor +@ stub -arch=arm ??0context_self_unblock@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0context_self_unblock@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0context_self_unblock@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0context_self_unblock@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0context_self_unblock@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0context_self_unblock@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0context_unblock_unbalanced@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0context_unblock_unbalanced@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0context_unblock_unbalanced@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0context_unblock_unbalanced@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0context_unblock_unbalanced@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0context_unblock_unbalanced@Concurrency@@QEAA@XZ +@ cdecl -arch=arm ??0critical_section@Concurrency@@QAA@XZ(ptr) critical_section_ctor +@ thiscall -arch=i386 ??0critical_section@Concurrency@@QAE@XZ(ptr) critical_section_ctor +@ cdecl -arch=win64 ??0critical_section@Concurrency@@QEAA@XZ(ptr) critical_section_ctor +@ stub -arch=arm ??0default_scheduler_exists@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0default_scheduler_exists@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0default_scheduler_exists@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0default_scheduler_exists@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0default_scheduler_exists@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0default_scheduler_exists@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0event@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0event@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0event@Concurrency@@QEAA@XZ +@ cdecl -arch=arm ??0exception@std@@QAA@ABQBD@Z(ptr ptr) MSVCRT_exception_ctor +@ thiscall -arch=i386 ??0exception@std@@QAE@ABQBD@Z(ptr ptr) MSVCRT_exception_ctor +@ cdecl -arch=win64 ??0exception@std@@QEAA@AEBQEBD@Z(ptr ptr) MSVCRT_exception_ctor +@ cdecl -arch=arm ??0exception@std@@QAA@ABQBDH@Z(ptr ptr long) MSVCRT_exception_ctor_noalloc +@ thiscall -arch=i386 ??0exception@std@@QAE@ABQBDH@Z(ptr ptr long) MSVCRT_exception_ctor_noalloc +@ cdecl -arch=win64 ??0exception@std@@QEAA@AEBQEBDH@Z(ptr ptr long) MSVCRT_exception_ctor_noalloc +@ cdecl -arch=arm ??0exception@std@@QAA@ABV01@@Z(ptr ptr) MSVCRT_exception_copy_ctor +@ thiscall -arch=i386 ??0exception@std@@QAE@ABV01@@Z(ptr ptr) MSVCRT_exception_copy_ctor +@ cdecl -arch=win64 ??0exception@std@@QEAA@AEBV01@@Z(ptr ptr) MSVCRT_exception_copy_ctor +@ cdecl -arch=arm ??0exception@std@@QAA@XZ(ptr) MSVCRT_exception_default_ctor +@ thiscall -arch=i386 ??0exception@std@@QAE@XZ(ptr) MSVCRT_exception_default_ctor +@ cdecl -arch=win64 ??0exception@std@@QEAA@XZ(ptr) MSVCRT_exception_default_ctor +@ stub -arch=arm ??0improper_lock@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0improper_lock@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0improper_lock@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0improper_lock@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0improper_lock@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0improper_lock@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0improper_scheduler_attach@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0improper_scheduler_attach@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0improper_scheduler_attach@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0improper_scheduler_attach@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0improper_scheduler_attach@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0improper_scheduler_attach@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0improper_scheduler_detach@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0improper_scheduler_detach@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0improper_scheduler_detach@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0improper_scheduler_detach@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0improper_scheduler_detach@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0improper_scheduler_detach@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0improper_scheduler_reference@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0improper_scheduler_reference@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0improper_scheduler_reference@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0improper_scheduler_reference@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0improper_scheduler_reference@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0improper_scheduler_reference@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0invalid_link_target@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0invalid_link_target@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0invalid_link_target@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0invalid_link_target@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0invalid_link_target@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0invalid_link_target@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0invalid_multiple_scheduling@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0invalid_multiple_scheduling@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0invalid_multiple_scheduling@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0invalid_multiple_scheduling@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0invalid_multiple_scheduling@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0invalid_multiple_scheduling@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0invalid_operation@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0invalid_operation@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0invalid_operation@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0invalid_operation@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0invalid_operation@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0invalid_operation@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0invalid_oversubscribe_operation@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0invalid_oversubscribe_operation@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0invalid_oversubscribe_operation@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0invalid_oversubscribe_operation@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0invalid_oversubscribe_operation@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0invalid_oversubscribe_operation@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0invalid_scheduler_policy_key@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0invalid_scheduler_policy_key@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0invalid_scheduler_policy_key@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0invalid_scheduler_policy_key@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0invalid_scheduler_policy_key@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0invalid_scheduler_policy_key@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0invalid_scheduler_policy_thread_specification@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0invalid_scheduler_policy_thread_specification@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0invalid_scheduler_policy_thread_specification@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0invalid_scheduler_policy_thread_specification@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0invalid_scheduler_policy_thread_specification@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0invalid_scheduler_policy_thread_specification@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0invalid_scheduler_policy_value@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0invalid_scheduler_policy_value@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0invalid_scheduler_policy_value@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0invalid_scheduler_policy_value@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0invalid_scheduler_policy_value@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0invalid_scheduler_policy_value@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0message_not_found@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0message_not_found@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0message_not_found@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0message_not_found@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0message_not_found@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0message_not_found@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0missing_wait@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0missing_wait@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0missing_wait@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0missing_wait@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0missing_wait@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0missing_wait@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0nested_scheduler_missing_detach@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0nested_scheduler_missing_detach@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0nested_scheduler_missing_detach@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0nested_scheduler_missing_detach@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0nested_scheduler_missing_detach@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0nested_scheduler_missing_detach@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0operation_timed_out@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0operation_timed_out@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0operation_timed_out@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0operation_timed_out@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0operation_timed_out@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0operation_timed_out@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0reader_writer_lock@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0reader_writer_lock@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0reader_writer_lock@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0scheduler_not_attached@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0scheduler_not_attached@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0scheduler_not_attached@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0scheduler_not_attached@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0scheduler_not_attached@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0scheduler_not_attached@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0scheduler_resource_allocation_error@Concurrency@@QAA@J@Z +@ stub -arch=i386 ??0scheduler_resource_allocation_error@Concurrency@@QAE@J@Z +@ stub -arch=win64 ??0scheduler_resource_allocation_error@Concurrency@@QEAA@J@Z +@ stub -arch=arm ??0scheduler_resource_allocation_error@Concurrency@@QAA@PBDJ@Z +@ stub -arch=i386 ??0scheduler_resource_allocation_error@Concurrency@@QAE@PBDJ@Z +@ stub -arch=win64 ??0scheduler_resource_allocation_error@Concurrency@@QEAA@PEBDJ@Z +@ stub -arch=arm ??0scheduler_worker_creation_error@Concurrency@@QAA@J@Z +@ stub -arch=i386 ??0scheduler_worker_creation_error@Concurrency@@QAE@J@Z +@ stub -arch=win64 ??0scheduler_worker_creation_error@Concurrency@@QEAA@J@Z +@ stub -arch=arm ??0scheduler_worker_creation_error@Concurrency@@QAA@PBDJ@Z +@ stub -arch=i386 ??0scheduler_worker_creation_error@Concurrency@@QAE@PBDJ@Z +@ stub -arch=win64 ??0scheduler_worker_creation_error@Concurrency@@QEAA@PEBDJ@Z +@ cdecl -arch=arm ??0scoped_lock@critical_section@Concurrency@@QAA@AAV12@@Z(ptr ptr) critical_section_scoped_lock_ctor +@ thiscall -arch=i386 ??0scoped_lock@critical_section@Concurrency@@QAE@AAV12@@Z(ptr ptr) critical_section_scoped_lock_ctor +@ cdecl -arch=win64 ??0scoped_lock@critical_section@Concurrency@@QEAA@AEAV12@@Z(ptr ptr) critical_section_scoped_lock_ctor +@ stub -arch=arm ??0scoped_lock@reader_writer_lock@Concurrency@@QAA@AAV12@@Z +@ stub -arch=i386 ??0scoped_lock@reader_writer_lock@Concurrency@@QAE@AAV12@@Z +@ stub -arch=win64 ??0scoped_lock@reader_writer_lock@Concurrency@@QEAA@AEAV12@@Z +@ stub -arch=arm ??0scoped_lock_read@reader_writer_lock@Concurrency@@QAA@AAV12@@Z +@ stub -arch=i386 ??0scoped_lock_read@reader_writer_lock@Concurrency@@QAE@AAV12@@Z +@ stub -arch=win64 ??0scoped_lock_read@reader_writer_lock@Concurrency@@QEAA@AEAV12@@Z +@ stub -arch=arm ??0task_canceled@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0task_canceled@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0task_canceled@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0task_canceled@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0task_canceled@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0task_canceled@Concurrency@@QEAA@XZ +@ stub -arch=arm ??0unsupported_os@Concurrency@@QAA@PBD@Z +@ stub -arch=i386 ??0unsupported_os@Concurrency@@QAE@PBD@Z +@ stub -arch=win64 ??0unsupported_os@Concurrency@@QEAA@PEBD@Z +@ stub -arch=arm ??0unsupported_os@Concurrency@@QAA@XZ +@ stub -arch=i386 ??0unsupported_os@Concurrency@@QAE@XZ +@ stub -arch=win64 ??0unsupported_os@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1SchedulerPolicy@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1SchedulerPolicy@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1SchedulerPolicy@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1_Cancellation_beacon@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1_Cancellation_beacon@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1_Cancellation_beacon@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1_Condition_variable@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1_Condition_variable@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1_Condition_variable@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1_NonReentrantBlockingLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1_NonReentrantBlockingLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1_NonReentrantBlockingLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1_ReentrantBlockingLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1_ReentrantBlockingLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1_ReentrantBlockingLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1_Scoped_lock@_NonReentrantPPLLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1_Scoped_lock@_NonReentrantPPLLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1_Scoped_lock@_NonReentrantPPLLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1_Scoped_lock@_ReentrantPPLLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1_Scoped_lock@_ReentrantPPLLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1_Scoped_lock@_ReentrantPPLLock@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1_SpinLock@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1_SpinLock@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1_SpinLock@details@Concurrency@@QEAA@XZ +@ stub -arch=i386 ??1_StructuredTaskCollection@details@Concurrency@@QAE@XZ +@ stub -arch=arm ??1_TaskCollection@details@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1_TaskCollection@details@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1_TaskCollection@details@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1_Timer@details@Concurrency@@MAA@XZ +@ stub -arch=i386 ??1_Timer@details@Concurrency@@MAE@XZ +@ stub -arch=win64 ??1_Timer@details@Concurrency@@MEAA@XZ +@ cdecl -arch=arm ??1__non_rtti_object@std@@UAA@XZ(ptr) MSVCRT___non_rtti_object_dtor +@ thiscall -arch=i386 ??1__non_rtti_object@std@@UAE@XZ(ptr) MSVCRT___non_rtti_object_dtor +@ cdecl -arch=win64 ??1__non_rtti_object@std@@UEAA@XZ(ptr) MSVCRT___non_rtti_object_dtor +@ cdecl -arch=arm ??1bad_cast@std@@UAA@XZ(ptr) MSVCRT_bad_cast_dtor +@ thiscall -arch=i386 ??1bad_cast@std@@UAE@XZ(ptr) MSVCRT_bad_cast_dtor +@ cdecl -arch=win64 ??1bad_cast@std@@UEAA@XZ(ptr) MSVCRT_bad_cast_dtor +@ cdecl -arch=arm ??1bad_typeid@std@@UAA@XZ(ptr) MSVCRT_bad_typeid_dtor +@ thiscall -arch=i386 ??1bad_typeid@std@@UAE@XZ(ptr) MSVCRT_bad_typeid_dtor +@ cdecl -arch=win64 ??1bad_typeid@std@@UEAA@XZ(ptr) MSVCRT_bad_typeid_dtor +@ cdecl -arch=arm ??1critical_section@Concurrency@@QAA@XZ(ptr) critical_section_dtor +@ thiscall -arch=i386 ??1critical_section@Concurrency@@QAE@XZ(ptr) critical_section_dtor +@ cdecl -arch=win64 ??1critical_section@Concurrency@@QEAA@XZ(ptr) critical_section_dtor +@ stub -arch=arm ??1event@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1event@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1event@Concurrency@@QEAA@XZ +@ cdecl -arch=arm ??1exception@std@@UAA@XZ(ptr) MSVCRT_exception_dtor +@ thiscall -arch=i386 ??1exception@std@@UAE@XZ(ptr) MSVCRT_exception_dtor +@ cdecl -arch=win64 ??1exception@std@@UEAA@XZ(ptr) MSVCRT_exception_dtor +@ stub -arch=arm ??1reader_writer_lock@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1reader_writer_lock@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1reader_writer_lock@Concurrency@@QEAA@XZ +@ cdecl -arch=arm ??1scoped_lock@critical_section@Concurrency@@QAA@XZ(ptr) critical_section_scoped_lock_dtor +@ thiscall -arch=i386 ??1scoped_lock@critical_section@Concurrency@@QAE@XZ(ptr) critical_section_scoped_lock_dtor +@ cdecl -arch=win64 ??1scoped_lock@critical_section@Concurrency@@QEAA@XZ(ptr) critical_section_scoped_lock_dtor +@ stub -arch=arm ??1scoped_lock@reader_writer_lock@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1scoped_lock@reader_writer_lock@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1scoped_lock@reader_writer_lock@Concurrency@@QEAA@XZ +@ stub -arch=arm ??1scoped_lock_read@reader_writer_lock@Concurrency@@QAA@XZ +@ stub -arch=i386 ??1scoped_lock_read@reader_writer_lock@Concurrency@@QAE@XZ +@ stub -arch=win64 ??1scoped_lock_read@reader_writer_lock@Concurrency@@QEAA@XZ +@ cdecl -arch=arm ??1type_info@@UAA@XZ(ptr) MSVCRT_type_info_dtor +@ thiscall -arch=i386 ??1type_info@@UAE@XZ(ptr) MSVCRT_type_info_dtor +@ cdecl -arch=win64 ??1type_info@@UEAA@XZ(ptr) MSVCRT_type_info_dtor +@ cdecl -arch=win32 ??2@YAPAXI@Z(long) MSVCRT_operator_new +@ cdecl -arch=win64 ??2@YAPEAX_K@Z(long) MSVCRT_operator_new +@ cdecl -arch=win32 ??2@YAPAXIHPBDH@Z(long long str long) MSVCRT_operator_new_dbg +@ cdecl -arch=win64 ??2@YAPEAX_KHPEBDH@Z(long long str long) MSVCRT_operator_new_dbg +@ cdecl -arch=win32 ??3@YAXPAX@Z(ptr) MSVCRT_operator_delete +@ cdecl -arch=win64 ??3@YAXPEAX@Z(ptr) MSVCRT_operator_delete +@ stub -arch=win32 ??3@YAXPAXHPBDH@Z +@ stub -arch=win64 ??3@YAXPEAXHPEBDH@Z +@ stub -arch=arm ??4?$_SpinWait@$00@details@Concurrency@@QAAAAV012@ABV012@@Z +@ stub -arch=i386 ??4?$_SpinWait@$00@details@Concurrency@@QAEAAV012@ABV012@@Z +@ stub -arch=win64 ??4?$_SpinWait@$00@details@Concurrency@@QEAAAEAV012@AEBV012@@Z +@ stub -arch=arm ??4?$_SpinWait@$0A@@details@Concurrency@@QAAAAV012@ABV012@@Z +@ stub -arch=i386 ??4?$_SpinWait@$0A@@details@Concurrency@@QAEAAV012@ABV012@@Z +@ stub -arch=win64 ??4?$_SpinWait@$0A@@details@Concurrency@@QEAAAEAV012@AEBV012@@Z +@ stub -arch=arm ??4SchedulerPolicy@Concurrency@@QAAAAV01@ABV01@@Z +@ stub -arch=i386 ??4SchedulerPolicy@Concurrency@@QAEAAV01@ABV01@@Z +@ stub -arch=win64 ??4SchedulerPolicy@Concurrency@@QEAAAEAV01@AEBV01@@Z +@ cdecl -arch=arm ??4__non_rtti_object@std@@QAAAAV01@ABV01@@Z(ptr ptr) MSVCRT___non_rtti_object_opequals +@ thiscall -arch=i386 ??4__non_rtti_object@std@@QAEAAV01@ABV01@@Z(ptr ptr) MSVCRT___non_rtti_object_opequals +@ cdecl -arch=win64 ??4__non_rtti_object@std@@QEAAAEAV01@AEBV01@@Z(ptr ptr) MSVCRT___non_rtti_object_opequals +@ cdecl -arch=arm ??4bad_cast@std@@QAAAAV01@ABV01@@Z(ptr ptr) MSVCRT_bad_cast_opequals +@ thiscall -arch=i386 ??4bad_cast@std@@QAEAAV01@ABV01@@Z(ptr ptr) MSVCRT_bad_cast_opequals +@ cdecl -arch=win64 ??4bad_cast@std@@QEAAAEAV01@AEBV01@@Z(ptr ptr) MSVCRT_bad_cast_opequals +@ cdecl -arch=arm ??4bad_typeid@std@@QAAAAV01@ABV01@@Z(ptr ptr) MSVCRT_bad_typeid_opequals +@ thiscall -arch=i386 ??4bad_typeid@std@@QAEAAV01@ABV01@@Z(ptr ptr) MSVCRT_bad_typeid_opequals +@ cdecl -arch=win64 ??4bad_typeid@std@@QEAAAEAV01@AEBV01@@Z(ptr ptr) MSVCRT_bad_typeid_opequals +@ cdecl -arch=arm ??4exception@std@@QAAAAV01@ABV01@@Z(ptr ptr) MSVCRT_exception_opequals +@ thiscall -arch=i386 ??4exception@std@@QAEAAV01@ABV01@@Z(ptr ptr) MSVCRT_exception_opequals +@ cdecl -arch=win64 ??4exception@std@@QEAAAEAV01@AEBV01@@Z(ptr ptr) MSVCRT_exception_opequals +@ cdecl -arch=arm ??8type_info@@QBA_NABV0@@Z(ptr ptr) MSVCRT_type_info_opequals_equals +@ thiscall -arch=i386 ??8type_info@@QBE_NABV0@@Z(ptr ptr) MSVCRT_type_info_opequals_equals +@ cdecl -arch=win64 ??8type_info@@QEBA_NAEBV0@@Z(ptr ptr) MSVCRT_type_info_opequals_equals +@ cdecl -arch=arm ??9type_info@@QBA_NABV0@@Z(ptr ptr) MSVCRT_type_info_opnot_equals +@ thiscall -arch=i386 ??9type_info@@QBE_NABV0@@Z(ptr ptr) MSVCRT_type_info_opnot_equals +@ cdecl -arch=win64 ??9type_info@@QEBA_NAEBV0@@Z(ptr ptr) MSVCRT_type_info_opnot_equals +@ extern ??_7__non_rtti_object@std@@6B@ MSVCRT___non_rtti_object_vtable +@ extern ??_7bad_cast@std@@6B@ MSVCRT_bad_cast_vtable +@ extern ??_7bad_typeid@std@@6B@ MSVCRT_bad_typeid_vtable +@ extern ??_7exception@std@@6B@ MSVCRT_exception_vtable +@ cdecl -arch=arm ??_F?$_SpinWait@$00@details@Concurrency@@QAAXXZ(ptr) SpinWait_dtor +@ thiscall -arch=i386 ??_F?$_SpinWait@$00@details@Concurrency@@QAEXXZ(ptr) SpinWait_dtor +@ cdecl -arch=win64 ??_F?$_SpinWait@$00@details@Concurrency@@QEAAXXZ(ptr) SpinWait_dtor +@ cdecl -arch=arm ??_F?$_SpinWait@$0A@@details@Concurrency@@QAAXXZ(ptr) SpinWait_dtor +@ thiscall -arch=i386 ??_F?$_SpinWait@$0A@@details@Concurrency@@QAEXXZ(ptr) SpinWait_dtor +@ cdecl -arch=win64 ??_F?$_SpinWait@$0A@@details@Concurrency@@QEAAXXZ(ptr) SpinWait_dtor +@ stub -arch=arm ??_F_Context@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ??_F_Context@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ??_F_Context@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ??_F_Scheduler@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ??_F_Scheduler@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ??_F_Scheduler@details@Concurrency@@QEAAXXZ +@ cdecl -arch=arm ??_Fbad_cast@std@@QAAXXZ(ptr) MSVCRT_bad_cast_default_ctor +@ thiscall -arch=i386 ??_Fbad_cast@std@@QAEXXZ(ptr) MSVCRT_bad_cast_default_ctor +@ cdecl -arch=win64 ??_Fbad_cast@std@@QEAAXXZ(ptr) MSVCRT_bad_cast_default_ctor +@ cdecl -arch=arm ??_Fbad_typeid@std@@QAAXXZ(ptr) MSVCRT_bad_typeid_default_ctor +@ thiscall -arch=i386 ??_Fbad_typeid@std@@QAEXXZ(ptr) MSVCRT_bad_typeid_default_ctor +@ cdecl -arch=win64 ??_Fbad_typeid@std@@QEAAXXZ(ptr) MSVCRT_bad_typeid_default_ctor +@ cdecl -arch=win32 ??_U@YAPAXI@Z(long) MSVCRT_operator_new +@ cdecl -arch=win64 ??_U@YAPEAX_K@Z(long) MSVCRT_operator_new +@ cdecl -arch=win32 ??_U@YAPAXIHPBDH@Z(long long str long) MSVCRT_operator_new_dbg +@ cdecl -arch=win64 ??_U@YAPEAX_KHPEBDH@Z(long long str long) MSVCRT_operator_new_dbg +@ cdecl -arch=win32 ??_V@YAXPAX@Z(ptr) MSVCRT_operator_delete +@ cdecl -arch=win64 ??_V@YAXPEAX@Z(ptr) MSVCRT_operator_delete +@ stub -arch=win32 ??_V@YAXPAXHPBDH@Z +@ stub -arch=win64 ??_V@YAXPEAXHPEBDH@Z +@ stub -arch=win32 ?Alloc@Concurrency@@YAPAXI@Z +@ stub -arch=win64 ?Alloc@Concurrency@@YAPEAX_K@Z +@ stub ?Block@Context@Concurrency@@SAXXZ +@ stub ?CaptureCallstack@platform@details@Concurrency@@YAIPAPAXII@Z +@ stub -arch=win32 ?Create@CurrentScheduler@Concurrency@@SAXABVSchedulerPolicy@2@@Z +@ stub -arch=win64 ?Create@CurrentScheduler@Concurrency@@SAXAEBVSchedulerPolicy@2@@Z +@ stub -arch=win32 ?Create@Scheduler@Concurrency@@SAPAV12@ABVSchedulerPolicy@2@@Z +@ stub -arch=win64 ?Create@Scheduler@Concurrency@@SAPEAV12@AEBVSchedulerPolicy@2@@Z +@ stub -arch=win32 ?CreateResourceManager@Concurrency@@YAPAUIResourceManager@1@XZ +@ stub -arch=win64 ?CreateResourceManager@Concurrency@@YAPEAUIResourceManager@1@XZ +@ stub -arch=win32 ?CreateScheduleGroup@CurrentScheduler@Concurrency@@SAPAVScheduleGroup@2@AAVlocation@2@@Z +@ stub -arch=win64 ?CreateScheduleGroup@CurrentScheduler@Concurrency@@SAPEAVScheduleGroup@2@AEAVlocation@2@@Z +@ stub -arch=win32 ?CreateScheduleGroup@CurrentScheduler@Concurrency@@SAPAVScheduleGroup@2@XZ +@ stub -arch=win64 ?CreateScheduleGroup@CurrentScheduler@Concurrency@@SAPEAVScheduleGroup@2@XZ +@ stub -arch=win32 ?CurrentContext@Context@Concurrency@@SAPAV12@XZ +@ stub -arch=win64 ?CurrentContext@Context@Concurrency@@SAPEAV12@XZ +@ stub ?Detach@CurrentScheduler@Concurrency@@SAXXZ +@ stub ?DisableTracing@Concurrency@@YAJXZ +@ stub ?EnableTracing@Concurrency@@YAJXZ +@ stub -arch=win32 ?Free@Concurrency@@YAXPAX@Z +@ stub -arch=win64 ?Free@Concurrency@@YAXPEAX@Z +@ stub -arch=win32 ?Get@CurrentScheduler@Concurrency@@SAPAVScheduler@2@XZ +@ stub -arch=win64 ?Get@CurrentScheduler@Concurrency@@SAPEAVScheduler@2@XZ +@ stub ?GetCurrentThreadId@platform@details@Concurrency@@YAJXZ +@ stub ?GetExecutionContextId@Concurrency@@YAIXZ +@ stub ?GetNumberOfVirtualProcessors@CurrentScheduler@Concurrency@@SAIXZ +@ stub ?GetOSVersion@Concurrency@@YA?AW4OSVersion@IResourceManager@1@XZ +@ stub ?GetPolicy@CurrentScheduler@Concurrency@@SA?AVSchedulerPolicy@2@XZ +@ stub -arch=arm ?GetPolicyValue@SchedulerPolicy@Concurrency@@QBAIW4PolicyElementKey@2@@Z +@ stub -arch=i386 ?GetPolicyValue@SchedulerPolicy@Concurrency@@QBEIW4PolicyElementKey@2@@Z +@ stub -arch=win64 ?GetPolicyValue@SchedulerPolicy@Concurrency@@QEBAIW4PolicyElementKey@2@@Z +@ stub ?GetProcessorCount@Concurrency@@YAIXZ +@ stub ?GetProcessorNodeCount@Concurrency@@YAIXZ +@ stub ?GetSchedulerId@Concurrency@@YAIXZ +@ stub -arch=win32 ?GetSharedTimerQueue@details@Concurrency@@YAPAXXZ +@ stub -arch=win64 ?GetSharedTimerQueue@details@Concurrency@@YAPEAXXZ +@ stub ?Id@Context@Concurrency@@SAIXZ +@ stub ?Id@CurrentScheduler@Concurrency@@SAIXZ +@ stub -arch=win32 ?IsAvailableLocation@CurrentScheduler@Concurrency@@SA_NABVlocation@2@@Z +@ stub -arch=win64 ?IsAvailableLocation@CurrentScheduler@Concurrency@@SA_NAEBVlocation@2@@Z +@ stub ?IsCurrentTaskCollectionCanceling@Context@Concurrency@@SA_NXZ +@ stub -arch=win32 ?Log2@details@Concurrency@@YAKI@Z +@ stub -arch=win64 ?Log2@details@Concurrency@@YAK_K@Z +@ stub ?Oversubscribe@Context@Concurrency@@SAX_N@Z +@ stub -arch=win32 ?RegisterShutdownEvent@CurrentScheduler@Concurrency@@SAXPAX@Z +@ stub -arch=win64 ?RegisterShutdownEvent@CurrentScheduler@Concurrency@@SAXPEAX@Z +@ stub ?ResetDefaultSchedulerPolicy@Scheduler@Concurrency@@SAXXZ +@ stub ?ScheduleGroupId@Context@Concurrency@@SAIXZ +@ stub -arch=win32 ?ScheduleTask@CurrentScheduler@Concurrency@@SAXP6AXPAX@Z0@Z +@ stub -arch=win64 ?ScheduleTask@CurrentScheduler@Concurrency@@SAXP6AXPEAX@Z0@Z +@ stub -arch=win32 ?ScheduleTask@CurrentScheduler@Concurrency@@SAXP6AXPAX@Z0AAVlocation@2@@Z +@ stub -arch=win64 ?ScheduleTask@CurrentScheduler@Concurrency@@SAXP6AXPEAX@Z0AEAVlocation@2@@Z +@ stub -arch=arm ?SetConcurrencyLimits@SchedulerPolicy@Concurrency@@QAAXII@Z +@ stub -arch=i386 ?SetConcurrencyLimits@SchedulerPolicy@Concurrency@@QAEXII@Z +@ stub -arch=win64 ?SetConcurrencyLimits@SchedulerPolicy@Concurrency@@QEAAXII@Z +@ stub -arch=win32 ?SetDefaultSchedulerPolicy@Scheduler@Concurrency@@SAXABVSchedulerPolicy@2@@Z +@ stub -arch=win64 ?SetDefaultSchedulerPolicy@Scheduler@Concurrency@@SAXAEBVSchedulerPolicy@2@@Z +@ stub -arch=arm ?SetPolicyValue@SchedulerPolicy@Concurrency@@QAAIW4PolicyElementKey@2@I@Z +@ stub -arch=i386 ?SetPolicyValue@SchedulerPolicy@Concurrency@@QAEIW4PolicyElementKey@2@I@Z +@ stub -arch=win64 ?SetPolicyValue@SchedulerPolicy@Concurrency@@QEAAIW4PolicyElementKey@2@I@Z +@ stub ?VirtualProcessorId@Context@Concurrency@@SAIXZ +@ stub ?Yield@Context@Concurrency@@SAXXZ +@ stub -arch=arm ?_Abort@_StructuredTaskCollection@details@Concurrency@@AAAXXZ +@ stub -arch=i386 ?_Abort@_StructuredTaskCollection@details@Concurrency@@AAEXXZ +@ stub -arch=win64 ?_Abort@_StructuredTaskCollection@details@Concurrency@@AEAAXXZ +@ stub -arch=arm ?_Acquire@_NonReentrantBlockingLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Acquire@_NonReentrantBlockingLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Acquire@_NonReentrantBlockingLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Acquire@_NonReentrantPPLLock@details@Concurrency@@QAAXPAX@Z +@ stub -arch=i386 ?_Acquire@_NonReentrantPPLLock@details@Concurrency@@QAEXPAX@Z +@ stub -arch=win64 ?_Acquire@_NonReentrantPPLLock@details@Concurrency@@QEAAXPEAX@Z +@ stub -arch=arm ?_Acquire@_ReentrantBlockingLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Acquire@_ReentrantBlockingLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Acquire@_ReentrantBlockingLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Acquire@_ReentrantLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Acquire@_ReentrantLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Acquire@_ReentrantLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Acquire@_ReentrantPPLLock@details@Concurrency@@QAAXPAX@Z +@ stub -arch=i386 ?_Acquire@_ReentrantPPLLock@details@Concurrency@@QAEXPAX@Z +@ stub -arch=win64 ?_Acquire@_ReentrantPPLLock@details@Concurrency@@QEAAXPEAX@Z +@ stub -arch=arm ?_AcquireRead@_ReaderWriterLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_AcquireRead@_ReaderWriterLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_AcquireRead@_ReaderWriterLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_AcquireWrite@_ReaderWriterLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_AcquireWrite@_ReaderWriterLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_AcquireWrite@_ReaderWriterLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Cancel@_StructuredTaskCollection@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Cancel@_StructuredTaskCollection@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Cancel@_StructuredTaskCollection@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Cancel@_TaskCollection@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Cancel@_TaskCollection@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Cancel@_TaskCollection@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_CheckTaskCollection@_UnrealizedChore@details@Concurrency@@IAAXXZ +@ stub -arch=i386 ?_CheckTaskCollection@_UnrealizedChore@details@Concurrency@@IAEXXZ +@ stub -arch=win64 ?_CheckTaskCollection@_UnrealizedChore@details@Concurrency@@IEAAXXZ +@ stub -arch=arm ?_CleanupToken@_StructuredTaskCollection@details@Concurrency@@AAAXXZ +@ stub -arch=i386 ?_CleanupToken@_StructuredTaskCollection@details@Concurrency@@AAEXXZ +@ stub -arch=win64 ?_CleanupToken@_StructuredTaskCollection@details@Concurrency@@AEAAXXZ +@ stub -arch=i386 ?_ConcRT_Assert@details@Concurrency@@YAXPBD0H@Z +@ stub -arch=win64 ?_ConcRT_Assert@details@Concurrency@@YAXPEBD0H@Z +@ stub -arch=win32 ?_ConcRT_CoreAssert@details@Concurrency@@YAXPBD0H@Z +@ stub -arch=win64 ?_ConcRT_CoreAssert@details@Concurrency@@YAXPEBD0H@Z +@ stub -arch=i386 ?_ConcRT_DumpMessage@details@Concurrency@@YAXPB_WZZ +@ stub -arch=win64 ?_ConcRT_DumpMessage@details@Concurrency@@YAXPEB_WZZ +@ stub -arch=win32 ?_ConcRT_Trace@details@Concurrency@@YAXHPB_WZZ +@ stub -arch=win64 ?_ConcRT_Trace@details@Concurrency@@YAXHPEB_WZZ +@ stub -arch=arm ?_Confirm_cancel@_Cancellation_beacon@details@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?_Confirm_cancel@_Cancellation_beacon@details@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?_Confirm_cancel@_Cancellation_beacon@details@Concurrency@@QEAA_NXZ +@ stub -arch=arm ?_Copy_str@exception@std@@AAAXPBD@Z +@ stub -arch=i386 ?_Copy_str@exception@std@@AAEXPBD@Z +@ stub -arch=win64 ?_Copy_str@exception@std@@AEAAXPEBD@Z +@ stub ?_CurrentContext@_Context@details@Concurrency@@SA?AV123@XZ +@ stub ?_Current_node@location@Concurrency@@SA?AV12@XZ +@ stub -arch=arm ?_Destroy@_AsyncTaskCollection@details@Concurrency@@EAAXXZ +@ stub -arch=i386 ?_Destroy@_AsyncTaskCollection@details@Concurrency@@EAEXXZ +@ stub -arch=win64 ?_Destroy@_AsyncTaskCollection@details@Concurrency@@EEAAXXZ +@ stub -arch=arm ?_Destroy@_CancellationTokenState@details@Concurrency@@EAAXXZ +@ stub -arch=i386 ?_Destroy@_CancellationTokenState@details@Concurrency@@EAEXXZ +@ stub -arch=win64 ?_Destroy@_CancellationTokenState@details@Concurrency@@EEAAXXZ +@ cdecl -arch=arm ?_DoYield@?$_SpinWait@$00@details@Concurrency@@IAAXXZ(ptr) SpinWait__DoYield +@ thiscall -arch=i386 ?_DoYield@?$_SpinWait@$00@details@Concurrency@@IAEXXZ(ptr) SpinWait__DoYield +@ cdecl -arch=win64 ?_DoYield@?$_SpinWait@$00@details@Concurrency@@IEAAXXZ(ptr) SpinWait__DoYield +@ cdecl -arch=arm ?_DoYield@?$_SpinWait@$0A@@details@Concurrency@@IAAXXZ(ptr) SpinWait__DoYield +@ thiscall -arch=i386 ?_DoYield@?$_SpinWait@$0A@@details@Concurrency@@IAEXXZ(ptr) SpinWait__DoYield +@ cdecl -arch=win64 ?_DoYield@?$_SpinWait@$0A@@details@Concurrency@@IEAAXXZ(ptr) SpinWait__DoYield +@ stub ?_Get@_CurrentScheduler@details@Concurrency@@SA?AV_Scheduler@23@XZ +@ stub -arch=win32 ?_GetConcRTTraceInfo@Concurrency@@YAPBU_CONCRT_TRACE_INFO@details@1@XZ +@ stub -arch=win64 ?_GetConcRTTraceInfo@Concurrency@@YAPEBU_CONCRT_TRACE_INFO@details@1@XZ +@ stub ?_GetConcurrency@details@Concurrency@@YAIXZ +@ stub -arch=win32 ?_GetCurrentInlineDepth@_StackGuard@details@Concurrency@@CAAAIXZ +@ stub -arch=win64 ?_GetCurrentInlineDepth@_StackGuard@details@Concurrency@@CAAEA_KXZ +@ stub ?_GetNumberOfVirtualProcessors@_CurrentScheduler@details@Concurrency@@SAIXZ +@ stub -arch=arm ?_GetScheduler@_Scheduler@details@Concurrency@@QAAPAVScheduler@3@XZ +@ stub -arch=i386 ?_GetScheduler@_Scheduler@details@Concurrency@@QAEPAVScheduler@3@XZ +@ stub -arch=win64 ?_GetScheduler@_Scheduler@details@Concurrency@@QEAAPEAVScheduler@3@XZ +@ stub ?_Id@_CurrentScheduler@details@Concurrency@@SAIXZ +@ stub -arch=arm ?_IsCanceling@_StructuredTaskCollection@details@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?_IsCanceling@_StructuredTaskCollection@details@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?_IsCanceling@_StructuredTaskCollection@details@Concurrency@@QEAA_NXZ +@ stub -arch=arm ?_IsCanceling@_TaskCollection@details@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?_IsCanceling@_TaskCollection@details@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?_IsCanceling@_TaskCollection@details@Concurrency@@QEAA_NXZ +@ stub -arch=arm ?_IsSynchronouslyBlocked@_Context@details@Concurrency@@QBA_NXZ +@ stub -arch=i386 ?_IsSynchronouslyBlocked@_Context@details@Concurrency@@QBE_NXZ +@ stub -arch=win64 ?_IsSynchronouslyBlocked@_Context@details@Concurrency@@QEBA_NXZ +@ stub -arch=win32 ?_Name_base@type_info@@CAPBDPBV1@PAU__type_info_node@@@Z +@ stub -arch=win64 ?_Name_base@type_info@@CAPEBDPEBV1@PEAU__type_info_node@@@Z +@ stub -arch=win32 ?_Name_base_internal@type_info@@CAPBDPBV1@PAU__type_info_node@@@Z +@ stub -arch=win64 ?_Name_base_internal@type_info@@CAPEBDPEBV1@PEAU__type_info_node@@@Z +@ stub -arch=win32 ?_NewCollection@_AsyncTaskCollection@details@Concurrency@@SAPAV123@PAV_CancellationTokenState@23@@Z +@ stub -arch=win64 ?_NewCollection@_AsyncTaskCollection@details@Concurrency@@SAPEAV123@PEAV_CancellationTokenState@23@@Z +@ cdecl -arch=arm ?_NumberOfSpins@?$_SpinWait@$00@details@Concurrency@@IAAKXZ(ptr) SpinWait__NumberOfSpins +@ thiscall -arch=i386 ?_NumberOfSpins@?$_SpinWait@$00@details@Concurrency@@IAEKXZ(ptr) SpinWait__NumberOfSpins +@ cdecl -arch=win64 ?_NumberOfSpins@?$_SpinWait@$00@details@Concurrency@@IEAAKXZ(ptr) SpinWait__NumberOfSpins +@ cdecl -arch=arm ?_NumberOfSpins@?$_SpinWait@$0A@@details@Concurrency@@IAAKXZ(ptr) SpinWait__NumberOfSpins +@ thiscall -arch=i386 ?_NumberOfSpins@?$_SpinWait@$0A@@details@Concurrency@@IAEKXZ(ptr) SpinWait__NumberOfSpins +@ cdecl -arch=win64 ?_NumberOfSpins@?$_SpinWait@$0A@@details@Concurrency@@IEAAKXZ(ptr) SpinWait__NumberOfSpins +@ stub ?_Oversubscribe@_Context@details@Concurrency@@SAX_N@Z +@ stub -arch=arm ?_Reference@_Scheduler@details@Concurrency@@QAAIXZ +@ stub -arch=i386 ?_Reference@_Scheduler@details@Concurrency@@QAEIXZ +@ stub -arch=win64 ?_Reference@_Scheduler@details@Concurrency@@QEAAIXZ +@ stub -arch=arm ?_Release@_NonReentrantBlockingLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Release@_NonReentrantBlockingLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Release@_NonReentrantBlockingLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Release@_NonReentrantPPLLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Release@_NonReentrantPPLLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Release@_NonReentrantPPLLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Release@_ReentrantBlockingLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Release@_ReentrantBlockingLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Release@_ReentrantBlockingLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Release@_ReentrantLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Release@_ReentrantLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Release@_ReentrantLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Release@_ReentrantPPLLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_Release@_ReentrantPPLLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_Release@_ReentrantPPLLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_Release@_Scheduler@details@Concurrency@@QAAIXZ +@ stub -arch=i386 ?_Release@_Scheduler@details@Concurrency@@QAEIXZ +@ stub -arch=win64 ?_Release@_Scheduler@details@Concurrency@@QEAAIXZ +@ stub -arch=arm ?_ReleaseRead@_ReaderWriterLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_ReleaseRead@_ReaderWriterLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_ReleaseRead@_ReaderWriterLock@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?_ReleaseWrite@_ReaderWriterLock@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?_ReleaseWrite@_ReaderWriterLock@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?_ReleaseWrite@_ReaderWriterLock@details@Concurrency@@QEAAXXZ +@ stub ?_ReportUnobservedException@details@Concurrency@@YAXXZ +@ cdecl -arch=arm ?_Reset@?$_SpinWait@$00@details@Concurrency@@IAAXXZ(ptr) SpinWait__Reset +@ thiscall -arch=i386 ?_Reset@?$_SpinWait@$00@details@Concurrency@@IAEXXZ(ptr) SpinWait__Reset +@ cdecl -arch=win64 ?_Reset@?$_SpinWait@$00@details@Concurrency@@IEAAXXZ(ptr) SpinWait__Reset +@ cdecl -arch=arm ?_Reset@?$_SpinWait@$0A@@details@Concurrency@@IAAXXZ(ptr) SpinWait__Reset +@ thiscall -arch=i386 ?_Reset@?$_SpinWait@$0A@@details@Concurrency@@IAEXXZ(ptr) SpinWait__Reset +@ cdecl -arch=win64 ?_Reset@?$_SpinWait@$0A@@details@Concurrency@@IEAAXXZ(ptr) SpinWait__Reset +@ stub -arch=arm ?_RunAndWait@_StructuredTaskCollection@details@Concurrency@@QAA?AW4_TaskCollectionStatus@23@PAV_UnrealizedChore@23@@Z +@ stub -arch=i386 ?_RunAndWait@_StructuredTaskCollection@details@Concurrency@@QAG?AW4_TaskCollectionStatus@23@PAV_UnrealizedChore@23@@Z +@ stub -arch=win64 ?_RunAndWait@_StructuredTaskCollection@details@Concurrency@@QEAA?AW4_TaskCollectionStatus@23@PEAV_UnrealizedChore@23@@Z +@ stub -arch=arm ?_RunAndWait@_TaskCollection@details@Concurrency@@QAA?AW4_TaskCollectionStatus@23@PAV_UnrealizedChore@23@@Z +@ stub -arch=i386 ?_RunAndWait@_TaskCollection@details@Concurrency@@QAG?AW4_TaskCollectionStatus@23@PAV_UnrealizedChore@23@@Z +@ stub -arch=win64 ?_RunAndWait@_TaskCollection@details@Concurrency@@QEAA?AW4_TaskCollectionStatus@23@PEAV_UnrealizedChore@23@@Z +@ stub -arch=arm ?_Schedule@_StructuredTaskCollection@details@Concurrency@@QAAXPAV_UnrealizedChore@23@@Z +@ stub -arch=i386 ?_Schedule@_StructuredTaskCollection@details@Concurrency@@QAEXPAV_UnrealizedChore@23@@Z +@ stub -arch=win64 ?_Schedule@_StructuredTaskCollection@details@Concurrency@@QEAAXPEAV_UnrealizedChore@23@@Z +@ stub -arch=arm ?_Schedule@_StructuredTaskCollection@details@Concurrency@@QAAXPAV_UnrealizedChore@23@PAVlocation@3@@Z +@ stub -arch=i386 ?_Schedule@_StructuredTaskCollection@details@Concurrency@@QAEXPAV_UnrealizedChore@23@PAVlocation@3@@Z +@ stub -arch=win64 ?_Schedule@_StructuredTaskCollection@details@Concurrency@@QEAAXPEAV_UnrealizedChore@23@PEAVlocation@3@@Z +@ stub -arch=arm ?_Schedule@_TaskCollection@details@Concurrency@@QAAXPAV_UnrealizedChore@23@@Z +@ stub -arch=i386 ?_Schedule@_TaskCollection@details@Concurrency@@QAEXPAV_UnrealizedChore@23@@Z +@ stub -arch=win64 ?_Schedule@_TaskCollection@details@Concurrency@@QEAAXPEAV_UnrealizedChore@23@@Z +@ stub -arch=arm ?_Schedule@_TaskCollection@details@Concurrency@@QAAXPAV_UnrealizedChore@23@PAVlocation@3@@Z +@ stub -arch=i386 ?_Schedule@_TaskCollection@details@Concurrency@@QAEXPAV_UnrealizedChore@23@PAVlocation@3@@Z +@ stub -arch=win64 ?_Schedule@_TaskCollection@details@Concurrency@@QEAAXPEAV_UnrealizedChore@23@PEAVlocation@3@@Z +@ stub -arch=win32 ?_ScheduleTask@_CurrentScheduler@details@Concurrency@@SAXP6AXPAX@Z0@Z +@ stub -arch=win64 ?_ScheduleTask@_CurrentScheduler@details@Concurrency@@SAXP6AXPEAX@Z0@Z +@ cdecl -arch=arm ?_SetSpinCount@?$_SpinWait@$00@details@Concurrency@@QAAXI@Z(ptr long) SpinWait__SetSpinCount +@ thiscall -arch=i386 ?_SetSpinCount@?$_SpinWait@$00@details@Concurrency@@QAEXI@Z(ptr long) SpinWait__SetSpinCount +@ cdecl -arch=win64 ?_SetSpinCount@?$_SpinWait@$00@details@Concurrency@@QEAAXI@Z(ptr long) SpinWait__SetSpinCount +@ cdecl -arch=arm ?_SetSpinCount@?$_SpinWait@$0A@@details@Concurrency@@QAAXI@Z(ptr long) SpinWait__SetSpinCount +@ thiscall -arch=i386 ?_SetSpinCount@?$_SpinWait@$0A@@details@Concurrency@@QAEXI@Z(ptr long) SpinWait__SetSpinCount +@ cdecl -arch=win64 ?_SetSpinCount@?$_SpinWait@$0A@@details@Concurrency@@QEAAXI@Z(ptr long) SpinWait__SetSpinCount +@ stub ?_SetUnobservedExceptionHandler@details@Concurrency@@YAXP6AXXZ@Z +@ cdecl -arch=arm ?_ShouldSpinAgain@?$_SpinWait@$00@details@Concurrency@@IAA_NXZ(ptr) SpinWait__ShouldSpinAgain +@ thiscall -arch=i386 ?_ShouldSpinAgain@?$_SpinWait@$00@details@Concurrency@@IAE_NXZ(ptr) SpinWait__ShouldSpinAgain +@ cdecl -arch=win64 ?_ShouldSpinAgain@?$_SpinWait@$00@details@Concurrency@@IEAA_NXZ(ptr) SpinWait__ShouldSpinAgain +@ cdecl -arch=arm ?_ShouldSpinAgain@?$_SpinWait@$0A@@details@Concurrency@@IAA_NXZ(ptr) SpinWait__ShouldSpinAgain +@ thiscall -arch=i386 ?_ShouldSpinAgain@?$_SpinWait@$0A@@details@Concurrency@@IAE_NXZ(ptr) SpinWait__ShouldSpinAgain +@ cdecl -arch=win64 ?_ShouldSpinAgain@?$_SpinWait@$0A@@details@Concurrency@@IEAA_NXZ(ptr) SpinWait__ShouldSpinAgain +@ cdecl -arch=arm ?_SpinOnce@?$_SpinWait@$00@details@Concurrency@@QAA_NXZ(ptr) SpinWait__SpinOnce +@ thiscall -arch=i386 ?_SpinOnce@?$_SpinWait@$00@details@Concurrency@@QAE_NXZ(ptr) SpinWait__SpinOnce +@ cdecl -arch=win64 ?_SpinOnce@?$_SpinWait@$00@details@Concurrency@@QEAA_NXZ(ptr) SpinWait__SpinOnce +@ cdecl -arch=arm ?_SpinOnce@?$_SpinWait@$0A@@details@Concurrency@@QAA_NXZ(ptr) SpinWait__SpinOnce +@ thiscall -arch=i386 ?_SpinOnce@?$_SpinWait@$0A@@details@Concurrency@@QAE_NXZ(ptr) SpinWait__SpinOnce +@ cdecl -arch=win64 ?_SpinOnce@?$_SpinWait@$0A@@details@Concurrency@@QEAA_NXZ(ptr) SpinWait__SpinOnce +@ stub ?_SpinYield@Context@Concurrency@@SAXXZ +@ stub -arch=arm ?_Start@_Timer@details@Concurrency@@IAAXXZ +@ stub -arch=i386 ?_Start@_Timer@details@Concurrency@@IAEXXZ +@ stub -arch=win64 ?_Start@_Timer@details@Concurrency@@IEAAXXZ +@ stub -arch=arm ?_Stop@_Timer@details@Concurrency@@IAAXXZ +@ stub -arch=i386 ?_Stop@_Timer@details@Concurrency@@IAEXXZ +@ stub -arch=win64 ?_Stop@_Timer@details@Concurrency@@IEAAXXZ +@ stub -arch=arm ?_Tidy@exception@std@@AAAXXZ +@ stub -arch=i386 ?_Tidy@exception@std@@AAEXXZ +@ stub -arch=win64 ?_Tidy@exception@std@@AEAAXXZ +@ stub ?_Trace_agents@Concurrency@@YAXW4Agents_EventType@1@_JZZ +@ stub -arch=win32 ?_Trace_ppl_function@Concurrency@@YAXABU_GUID@@EW4ConcRT_EventType@1@@Z +@ stub -arch=win64 ?_Trace_ppl_function@Concurrency@@YAXAEBU_GUID@@EW4ConcRT_EventType@1@@Z +@ stub -arch=arm ?_TryAcquire@_NonReentrantBlockingLock@details@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?_TryAcquire@_NonReentrantBlockingLock@details@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?_TryAcquire@_NonReentrantBlockingLock@details@Concurrency@@QEAA_NXZ +@ stub -arch=arm ?_TryAcquire@_ReentrantBlockingLock@details@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?_TryAcquire@_ReentrantBlockingLock@details@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?_TryAcquire@_ReentrantBlockingLock@details@Concurrency@@QEAA_NXZ +@ stub -arch=arm ?_TryAcquire@_ReentrantLock@details@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?_TryAcquire@_ReentrantLock@details@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?_TryAcquire@_ReentrantLock@details@Concurrency@@QEAA_NXZ +@ stub -arch=arm ?_TryAcquireWrite@_ReaderWriterLock@details@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?_TryAcquireWrite@_ReaderWriterLock@details@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?_TryAcquireWrite@_ReaderWriterLock@details@Concurrency@@QEAA_NXZ +@ stub -arch=win32 ?_Type_info_dtor@type_info@@CAXPAV1@@Z +@ stub -arch=win64 ?_Type_info_dtor@type_info@@CAXPEAV1@@Z +@ stub -arch=win32 ?_Type_info_dtor_internal@type_info@@CAXPAV1@@Z +@ stub -arch=win64 ?_Type_info_dtor_internal@type_info@@CAXPEAV1@@Z +@ stub ?_UnderlyingYield@details@Concurrency@@YAXXZ +@ stub -arch=arm ?_ValidateExecute@@YAHP6AHXZ@Z +@ stub -arch=i386 ?_ValidateExecute@@YAHP6GHXZ@Z +@ stub -arch=win64 ?_ValidateExecute@@YAHP6A_JXZ@Z +@ stub -arch=win32 ?_ValidateRead@@YAHPBXI@Z +@ stub -arch=win64 ?_ValidateRead@@YAHPEBXI@Z +@ stub -arch=win32 ?_ValidateWrite@@YAHPAXI@Z +@ stub -arch=win64 ?_ValidateWrite@@YAHPEAXI@Z +@ cdecl ?_Value@_SpinCount@details@Concurrency@@SAIXZ() SpinCount__Value +@ stub ?_Yield@_Context@details@Concurrency@@SAXXZ +@ stub -arch=win32 ?__ExceptionPtrAssign@@YAXPAXPBX@Z +@ stub -arch=win64 ?__ExceptionPtrAssign@@YAXPEAXPEBX@Z +@ stub -arch=win32 ?__ExceptionPtrCompare@@YA_NPBX0@Z +@ stub -arch=win64 ?__ExceptionPtrCompare@@YA_NPEBX0@Z +@ cdecl -arch=win32 ?__ExceptionPtrCopy@@YAXPAXPBX@Z(ptr ptr) __ExceptionPtrCopy +@ cdecl -arch=win64 ?__ExceptionPtrCopy@@YAXPEAXPEBX@Z(ptr ptr) __ExceptionPtrCopy +@ stub -arch=win32 ?__ExceptionPtrCopyException@@YAXPAXPBX1@Z +@ stub -arch=win64 ?__ExceptionPtrCopyException@@YAXPEAXPEBX1@Z +@ cdecl -arch=win32 ?__ExceptionPtrCreate@@YAXPAX@Z(ptr) __ExceptionPtrCreate +@ cdecl -arch=win64 ?__ExceptionPtrCreate@@YAXPEAX@Z(ptr) __ExceptionPtrCreate +@ cdecl -arch=win32 ?__ExceptionPtrCurrentException@@YAXPAX@Z(ptr) __ExceptionPtrCurrentException +@ cdecl -arch=win64 ?__ExceptionPtrCurrentException@@YAXPEAX@Z(ptr) __ExceptionPtrCurrentException +@ cdecl -arch=win32 ?__ExceptionPtrDestroy@@YAXPAX@Z(ptr) __ExceptionPtrDestroy +@ cdecl -arch=win64 ?__ExceptionPtrDestroy@@YAXPEAX@Z(ptr) __ExceptionPtrDestroy +@ cdecl -arch=win32 ?__ExceptionPtrRethrow@@YAXPBX@Z(ptr) __ExceptionPtrRethrow +@ cdecl -arch=win64 ?__ExceptionPtrRethrow@@YAXPEBX@Z(ptr) __ExceptionPtrRethrow +@ stub -arch=win32 ?__ExceptionPtrSwap@@YAXPAX0@Z +@ stub -arch=win64 ?__ExceptionPtrSwap@@YAXPEAX0@Z +@ stub -arch=win32 ?__ExceptionPtrToBool@@YA_NPBX@Z +@ stub -arch=win64 ?__ExceptionPtrToBool@@YA_NPEBX@Z +@ cdecl __uncaught_exception() MSVCRT___uncaught_exception +@ stub ?_inconsistency@@YAXXZ +@ cdecl -arch=win32 ?_invalid_parameter@@YAXPBG00II@Z(wstr wstr wstr long long) MSVCRT__invalid_parameter +@ cdecl -arch=win64 ?_invalid_parameter@@YAXPEBG00I_K@Z(wstr wstr wstr long long) MSVCRT__invalid_parameter +@ cdecl -arch=win32 ?_is_exception_typeof@@YAHABVtype_info@@PAU_EXCEPTION_POINTERS@@@Z(ptr ptr) _is_exception_typeof +@ cdecl -arch=win64 ?_is_exception_typeof@@YAHAEBVtype_info@@PEAU_EXCEPTION_POINTERS@@@Z(ptr ptr) _is_exception_typeof +@ cdecl -arch=arm ?_name_internal_method@type_info@@QBAPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ thiscall -arch=i386 ?_name_internal_method@type_info@@QBEPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ cdecl -arch=win64 ?_name_internal_method@type_info@@QEBAPEBDPEAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ varargs -arch=win32 ?_open@@YAHPBDHH@Z(str long) MSVCRT__open +@ varargs -arch=win64 ?_open@@YAHPEBDHH@Z(str long) MSVCRT__open +@ cdecl -arch=win32 ?_query_new_handler@@YAP6AHI@ZXZ() MSVCRT__query_new_handler +@ cdecl -arch=win64 ?_query_new_handler@@YAP6AH_K@ZXZ() MSVCRT__query_new_handler +@ cdecl ?_query_new_mode@@YAHXZ() MSVCRT__query_new_mode +@ stub -arch=win32 ?_set_new_handler@@YAP6AHI@ZH@Z # int (__cdecl*__cdecl _set_new_handler(int))(unsigned int) +@ stub -arch=win64 ?_set_new_handler@@YAP6AH_K@ZH@Z # int (__cdecl*__cdecl _set_new_handler(int))(unsigned __int64) +@ cdecl -arch=win32 ?_set_new_handler@@YAP6AHI@ZP6AHI@Z@Z(ptr) MSVCRT__set_new_handler +@ cdecl -arch=win64 ?_set_new_handler@@YAP6AH_K@ZP6AH0@Z@Z(ptr) MSVCRT__set_new_handler +@ cdecl ?_set_new_mode@@YAHH@Z(long) MSVCRT__set_new_mode +@ stub -arch=win32 ?_set_se_translator@@YAP6AXIPAU_EXCEPTION_POINTERS@@@ZH@Z # void (__cdecl*__cdecl _set_se_translator(int))(unsigned int,struct _EXCEPTION_POINTERS *) +@ stub -arch=win64 ?_set_se_translator@@YAP6AXIPEAU_EXCEPTION_POINTERS@@@ZH@Z # void (__cdecl*__cdecl _set_se_translator(int))(unsigned int,struct _EXCEPTION_POINTERS * __ptr64) +@ cdecl -arch=win32 ?_set_se_translator@@YAP6AXIPAU_EXCEPTION_POINTERS@@@ZP6AXI0@Z@Z(ptr) MSVCRT__set_se_translator +@ cdecl -arch=win64 ?_set_se_translator@@YAP6AXIPEAU_EXCEPTION_POINTERS@@@ZP6AXI0@Z@Z(ptr) MSVCRT__set_se_translator +@ cdecl -arch=win32 ?_sopen@@YAHPBDHHH@Z(str long long long) MSVCRT__sopen +@ cdecl -arch=win64 ?_sopen@@YAHPEBDHHH@Z(str long long long) MSVCRT__sopen +@ stub -arch=arm ?_type_info_dtor_internal_method@type_info@@QAAXXZ +@ stub -arch=i386 ?_type_info_dtor_internal_method@type_info@@QAEXXZ # public: void __thiscall type_info::_type_info_dtor_internal_method(void) +@ stub -arch=win64 ?_type_info_dtor_internal_method@type_info@@QEAAXXZ # public: void __cdecl type_info::_type_info_dtor_internal_method(void) __ptr64 +@ cdecl -arch=win32 ?_wopen@@YAHPB_WHH@Z(wstr long long) MSVCRT__wopen +@ cdecl -arch=win64 ?_wopen@@YAHPEB_WHH@Z(wstr long long) MSVCRT__wopen +@ cdecl -arch=win32 ?_wsopen@@YAHPB_WHHH@Z(wstr long long long) MSVCRT__wsopen +@ cdecl -arch=win64 ?_wsopen@@YAHPEB_WHHH@Z(wstr long long long) MSVCRT__wsopen +@ cdecl -arch=arm ?before@type_info@@QBA_NABV1@@Z(ptr ptr) MSVCRT_type_info_before +@ thiscall -arch=i386 ?before@type_info@@QBE_NABV1@@Z(ptr ptr) MSVCRT_type_info_before +@ cdecl -arch=win64 ?before@type_info@@QEBA_NAEBV1@@Z(ptr ptr) MSVCRT_type_info_before +@ stub ?current@location@Concurrency@@SA?AV12@XZ +@ stub ?from_numa_node@location@Concurrency@@SA?AV12@G@Z +@ stub -arch=arm ?get_error_code@scheduler_resource_allocation_error@Concurrency@@QBAJXZ +@ stub -arch=i386 ?get_error_code@scheduler_resource_allocation_error@Concurrency@@QBEJXZ +@ stub -arch=win64 ?get_error_code@scheduler_resource_allocation_error@Concurrency@@QEBAJXZ +@ cdecl -arch=arm ?lock@critical_section@Concurrency@@QAAXXZ(ptr) critical_section_lock +@ thiscall -arch=i386 ?lock@critical_section@Concurrency@@QAEXXZ(ptr) critical_section_lock +@ cdecl -arch=win64 ?lock@critical_section@Concurrency@@QEAAXXZ(ptr) critical_section_lock +@ stub -arch=arm ?lock@reader_writer_lock@Concurrency@@QAAXXZ +@ stub -arch=i386 ?lock@reader_writer_lock@Concurrency@@QAEXXZ +@ stub -arch=win64 ?lock@reader_writer_lock@Concurrency@@QEAAXXZ +@ stub -arch=arm ?lock_read@reader_writer_lock@Concurrency@@QAAXXZ +@ stub -arch=i386 ?lock_read@reader_writer_lock@Concurrency@@QAEXXZ +@ stub -arch=win64 ?lock_read@reader_writer_lock@Concurrency@@QEAAXXZ +@ cdecl -arch=arm ?name@type_info@@QBAPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ thiscall -arch=i386 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ cdecl -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ cdecl -arch=arm ?native_handle@critical_section@Concurrency@@QAAAAV12@XZ(ptr) critical_section_native_handle +@ thiscall -arch=i386 ?native_handle@critical_section@Concurrency@@QAEAAV12@XZ(ptr) critical_section_native_handle +@ cdecl -arch=win64 ?native_handle@critical_section@Concurrency@@QEAAAEAV12@XZ(ptr) critical_section_native_handle +@ stub -arch=arm ?notify_all@_Condition_variable@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?notify_all@_Condition_variable@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?notify_all@_Condition_variable@details@Concurrency@@QEAAXXZ +@ stub -arch=arm ?notify_one@_Condition_variable@details@Concurrency@@QAAXXZ +@ stub -arch=i386 ?notify_one@_Condition_variable@details@Concurrency@@QAEXXZ +@ stub -arch=win64 ?notify_one@_Condition_variable@details@Concurrency@@QEAAXXZ +@ cdecl -arch=arm ?raw_name@type_info@@QBAPBDXZ(ptr) MSVCRT_type_info_raw_name +@ thiscall -arch=i386 ?raw_name@type_info@@QBEPBDXZ(ptr) MSVCRT_type_info_raw_name +@ cdecl -arch=win64 ?raw_name@type_info@@QEBAPEBDXZ(ptr) MSVCRT_type_info_raw_name +@ stub -arch=arm ?reset@event@Concurrency@@QAAXXZ +@ stub -arch=i386 ?reset@event@Concurrency@@QAEXXZ +@ stub -arch=win64 ?reset@event@Concurrency@@QEAAXXZ +@ stub -arch=arm ?set@event@Concurrency@@QAAXXZ +@ stub -arch=i386 ?set@event@Concurrency@@QAEXXZ +@ stub -arch=win64 ?set@event@Concurrency@@QEAAXXZ +@ cdecl ?set_new_handler@@YAP6AXXZP6AXXZ@Z(ptr) MSVCRT_set_new_handler +@ stub -arch=win32 ?set_task_execution_resources@Concurrency@@YAXGPAU_GROUP_AFFINITY@@@Z +@ stub -arch=win64 ?set_task_execution_resources@Concurrency@@YAXGPEAU_GROUP_AFFINITY@@@Z +@ stub -arch=win32 ?set_task_execution_resources@Concurrency@@YAXK@Z +@ stub -arch=win64 ?set_task_execution_resources@Concurrency@@YAX_K@Z +@ stub ?set_terminate@@YAP6AXXZH@Z +@ cdecl ?set_terminate@@YAP6AXXZP6AXXZ@Z(ptr) MSVCRT_set_terminate +@ stub ?set_unexpected@@YAP6AXXZH@Z +@ cdecl ?set_unexpected@@YAP6AXXZP6AXXZ@Z(ptr) MSVCRT_set_unexpected +@ varargs ?swprintf@@YAHPAGIPBGZZ(ptr long wstr) MSVCRT__snwprintf +@ varargs ?swprintf@@YAHPA_WIPB_WZZ(ptr long wstr) MSVCRT__snwprintf +@ cdecl ?terminate@@YAXXZ() MSVCRT_terminate +@ cdecl -arch=arm ?try_lock@critical_section@Concurrency@@QAA_NXZ(ptr) critical_section_try_lock +@ thiscall -arch=i386 ?try_lock@critical_section@Concurrency@@QAE_NXZ(ptr) critical_section_try_lock +@ cdecl -arch=win64 ?try_lock@critical_section@Concurrency@@QEAA_NXZ(ptr) critical_section_try_lock +@ stub -arch=arm ?try_lock@reader_writer_lock@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?try_lock@reader_writer_lock@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?try_lock@reader_writer_lock@Concurrency@@QEAA_NXZ +@ cdecl -arch=arm ?try_lock_for@critical_section@Concurrency@@QAA_NI@Z(ptr long) critical_section_try_lock_for +@ thiscall -arch=i386 ?try_lock_for@critical_section@Concurrency@@QAE_NI@Z(ptr long) critical_section_try_lock_for +@ cdecl -arch=win64 ?try_lock_for@critical_section@Concurrency@@QEAA_NI@Z(ptr long) critical_section_try_lock_for +@ stub -arch=arm ?try_lock_read@reader_writer_lock@Concurrency@@QAA_NXZ +@ stub -arch=i386 ?try_lock_read@reader_writer_lock@Concurrency@@QAE_NXZ +@ stub -arch=win64 ?try_lock_read@reader_writer_lock@Concurrency@@QEAA_NXZ +@ cdecl ?unexpected@@YAXXZ() MSVCRT_unexpected +@ cdecl -arch=arm ?unlock@critical_section@Concurrency@@QAAXXZ(ptr) critical_section_unlock +@ thiscall -arch=i386 ?unlock@critical_section@Concurrency@@QAEXXZ(ptr) critical_section_unlock +@ cdecl -arch=win64 ?unlock@critical_section@Concurrency@@QEAAXXZ(ptr) critical_section_unlock +@ stub -arch=arm ?unlock@reader_writer_lock@Concurrency@@QAAXXZ +@ stub -arch=i386 ?unlock@reader_writer_lock@Concurrency@@QAEXXZ +@ stub -arch=win64 ?unlock@reader_writer_lock@Concurrency@@QEAAXXZ +@ cdecl ?vswprintf@@YAHPA_WIPB_WPAD@Z(ptr long wstr ptr) MSVCRT_vsnwprintf +@ stub ?wait@Concurrency@@YAXI@Z +@ stub -arch=arm ?wait@_Condition_variable@details@Concurrency@@QAAXAAVcritical_section@3@@Z +@ stub -arch=i386 ?wait@_Condition_variable@details@Concurrency@@QAEXAAVcritical_section@3@@Z +@ stub -arch=win64 ?wait@_Condition_variable@details@Concurrency@@QEAAXAEAVcritical_section@3@@Z +@ stub -arch=arm ?wait@event@Concurrency@@QAAII@Z +@ stub -arch=i386 ?wait@event@Concurrency@@QAEII@Z +@ stub -arch=win64 ?wait@event@Concurrency@@QEAA_KI@Z +@ stub -arch=arm ?wait_for@_Condition_variable@details@Concurrency@@QAA_NAAVcritical_section@3@I@Z +@ stub -arch=i386 ?wait_for@_Condition_variable@details@Concurrency@@QAE_NAAVcritical_section@3@I@Z +@ stub -arch=win64 ?wait_for@_Condition_variable@details@Concurrency@@QEAA_NAEAVcritical_section@3@I@Z +@ stub -arch=win32 ?wait_for_multiple@event@Concurrency@@SAIPAPAV12@I_NI@Z +@ stub -arch=win64 ?wait_for_multiple@event@Concurrency@@SA_KPEAPEAV12@_K_NI@Z +@ cdecl -arch=arm ?what@exception@std@@UBAPBDXZ(ptr) MSVCRT_what_exception +@ thiscall -arch=i386 ?what@exception@std@@UBEPBDXZ(ptr) MSVCRT_what_exception +@ cdecl -arch=win64 ?what@exception@std@@UEBAPEBDXZ(ptr) MSVCRT_what_exception +@ cdecl -norelay $I10_OUTPUT(double long long long ptr) MSVCRT_I10_OUTPUT +@ cdecl -arch=i386 _CIacos() +@ cdecl -arch=i386 _CIasin() +@ cdecl -arch=i386 _CIatan() +@ cdecl -arch=i386 _CIatan2() +@ cdecl -arch=i386 _CIcos() +@ cdecl -arch=i386 _CIcosh() +@ cdecl -arch=i386 _CIexp() +@ cdecl -arch=i386 _CIfmod() +@ cdecl -arch=i386 _CIlog() +@ cdecl -arch=i386 _CIlog10() +@ cdecl -arch=i386 _CIpow() +@ cdecl -arch=i386 _CIsin() +@ cdecl -arch=i386 _CIsinh() +@ cdecl -arch=i386 _CIsqrt() +@ cdecl -arch=i386 _CItan() +@ cdecl -arch=i386 _CItanh() +@ cdecl _CRT_RTC_INIT(ptr ptr long long long) +@ cdecl _CRT_RTC_INITW(ptr ptr long long long) +@ stub _Cbuild +@ stub _CreateFrameInfo +@ stdcall _CxxThrowException(long long) +@ cdecl -arch=i386 -norelay _EH_prolog() +@ stub -arch=arm _FPE_Raise +@ stub _FCbuild +@ stub _FindAndUnlinkFrame +@ stub -arch=win64 _GetImageBase +@ stub -arch=win64 _GetThrowImageBase +@ cdecl _Getdays() +@ cdecl _Getmonths() +@ cdecl _Gettnames() +@ extern _HUGE MSVCRT__HUGE +@ stub _IsExceptionObjectToBeDestroyed +@ stub _LCbuild +@ stub -arch=i386 _NLG_Dispatch2 +@ stub -arch=arm,win64 __NLG_Dispatch2 +@ stub -arch=i386 _NLG_Return +@ stub -arch=i386 _NLG_Return2 +@ stub -arch=arm,win64 __NLG_Return2 +@ stub _SetWinRTOutOfMemoryExceptionCallback +@ stub -arch=win64 _SetImageBase +@ stub -arch=win64 _SetThrowImageBase +@ cdecl _Strftime(str long str ptr ptr) +@ stub _W_Getdays +@ stub _W_Getmonths +@ stub _W_Gettnames +@ stub _Wcsftime +@ cdecl _XcptFilter(long ptr) +@ cdecl __AdjustPointer(ptr ptr) +@ stub __BuildCatchObject +@ stub __BuildCatchObjectHelper +@ stdcall -arch=x86_64 __C_specific_handler(ptr long ptr ptr) ntdll.__C_specific_handler +@ cdecl -arch=i386,x86_64,arm __CppXcptFilter(long ptr) +@ cdecl -arch=i386,x86_64,arm __CxxDetectRethrow(ptr) +@ stub __CxxExceptionFilter +@ cdecl -arch=i386,x86_64,arm -norelay __CxxFrameHandler(ptr ptr ptr ptr) +@ cdecl -arch=i386,x86_64,arm -norelay __CxxFrameHandler2(ptr ptr ptr ptr) __CxxFrameHandler +@ cdecl -arch=i386,x86_64,arm -norelay __CxxFrameHandler3(ptr ptr ptr ptr) __CxxFrameHandler +@ stdcall -arch=i386 __CxxLongjmpUnwind(ptr) +@ cdecl -arch=i386,x86_64,arm __CxxQueryExceptionSize() +@ stub __CxxRegisterExceptionObject +@ stub __CxxUnregisterExceptionObject +@ stub __DestructExceptionObject +@ stub __FrameUnwindFilter +@ stub __GetPlatformExceptionInfo +@ cdecl __RTCastToVoid(ptr) MSVCRT___RTCastToVoid +@ cdecl __RTDynamicCast(ptr long ptr ptr long) MSVCRT___RTDynamicCast +@ cdecl __RTtypeid(ptr) MSVCRT___RTtypeid +@ cdecl __STRINGTOLD(ptr ptr str long) +@ stub __STRINGTOLD_L +@ stub __TypeMatch +@ cdecl ___lc_codepage_func() +@ cdecl ___lc_collate_cp_func() +@ stub ___lc_locale_name_func +@ cdecl ___mb_cur_max_func() MSVCRT____mb_cur_max_func +@ cdecl ___mb_cur_max_l_func(ptr) +@ cdecl ___setlc_active_func() MSVCRT____setlc_active_func +@ cdecl ___unguarded_readlc_active_add_func() MSVCRT____unguarded_readlc_active_add_func +@ extern __argc MSVCRT___argc +@ extern __argv MSVCRT___argv +@ extern __badioinfo MSVCRT___badioinfo +@ cdecl __clean_type_info_names_internal(ptr) +@ cdecl -arch=i386 __control87_2(long long ptr ptr) +@ stub __create_locale +@ stub -arch=win64 __crtCaptureCurrentContext +@ stub -arch=win64 __crtCapturePreviousContext +@ cdecl __crtCompareStringA(long long str long str long) +@ stub -arch=i386,win64 __crtCompareStringEx +@ cdecl __crtCompareStringW(long long wstr long wstr long) +@ stub __crtCreateEventExW +@ stub -arch=i386 ___crtCreateSemaphoreExW +@ stub -arch=x86_64 __crtCreateSymbolicLinkW +@ stub -arch=i386,win64 __crtEnumSystemLocalesEx +@ stub -arch=i386,win64 __crtFlsAlloc +@ stub -arch=i386,win64 __crtFlsFree +@ stub -arch=i386,win64 __crtFlsGetValue +@ stub -arch=i386,win64 __crtFlsSetValue +@ stub -arch=i386,win64 __crtGetDateFormatEx +@ stub __crtGetFileInformationByHandleEx +@ stub -arch=i386,win64 __crtGetLocaleInfoEx +@ cdecl __crtGetShowWindowMode() MSVCR110__crtGetShowWindowMode +@ stub __crtGetTickCount64 +@ stub -arch=i386,win64 __crtGetTimeFormatEx +@ stub -arch=i386,win64 __crtGetUserDefaultLocaleName +@ cdecl -arch=i386,win64 __crtInitializeCriticalSectionEx(ptr long long) MSVCR110__crtInitializeCriticalSectionEx +@ stub __crtIsPackagedApp +@ stub -arch=i386,win64 __crtIsValidLocaleName +@ cdecl __crtLCMapStringA(long long str long ptr long long long) +@ stub -arch=i386,win64 __crtLCMapStringEx +@ cdecl __crtLCMapStringW(long long wstr long ptr long long long) +@ stub __crtSetFileInformationByHandle +@ stub -arch=i386,win64 __crtSetThreadStackGuarantee +@ cdecl __crtSetUnhandledExceptionFilter(ptr) MSVCR110__crtSetUnhandledExceptionFilter +@ cdecl -arch=i386,win64 __crtTerminateProcess(long) MSVCR110__crtTerminateProcess +@ stub __crtSleep +@ stub -arch=i386,win64 __crtUnhandledException +@ cdecl __daylight() MSVCRT___p__daylight +@ cdecl __dllonexit(ptr ptr ptr) +@ cdecl __doserrno() MSVCRT___doserrno +@ cdecl __dstbias() MSVCRT___p__dstbias +@ cdecl __fpecode() +@ stub __free_locale +@ stub __get_current_locale +@ stub __get_flsindex +@ stub __get_tlsindex +@ cdecl __getmainargs(ptr ptr ptr long ptr) +@ extern __initenv MSVCRT___initenv +@ cdecl __iob_func() MSVCRT___iob_func +@ cdecl __isascii(long) MSVCRT___isascii +@ cdecl __iscsym(long) MSVCRT___iscsym +@ cdecl __iscsymf(long) MSVCRT___iscsymf +@ stub __iswcsym +@ stub __iswcsymf +@ stub -arch=arm __jump_unwind +# extern __lconv +@ cdecl __lconv_init() +@ cdecl -arch=i386 __libm_sse2_acos() +@ cdecl -arch=i386 __libm_sse2_acosf() +@ cdecl -arch=i386 __libm_sse2_asin() +@ cdecl -arch=i386 __libm_sse2_asinf() +@ cdecl -arch=i386 __libm_sse2_atan() +@ cdecl -arch=i386 __libm_sse2_atan2() +@ cdecl -arch=i386 __libm_sse2_atanf() +@ cdecl -arch=i386 __libm_sse2_cos() +@ cdecl -arch=i386 __libm_sse2_cosf() +@ cdecl -arch=i386 __libm_sse2_exp() +@ cdecl -arch=i386 __libm_sse2_expf() +@ cdecl -arch=i386 __libm_sse2_log() +@ cdecl -arch=i386 __libm_sse2_log10() +@ cdecl -arch=i386 __libm_sse2_log10f() +@ cdecl -arch=i386 __libm_sse2_logf() +@ cdecl -arch=i386 __libm_sse2_pow() +@ cdecl -arch=i386 __libm_sse2_powf() +@ cdecl -arch=i386 __libm_sse2_sin() +@ cdecl -arch=i386 __libm_sse2_sinf() +@ cdecl -arch=i386 __libm_sse2_tan() +@ cdecl -arch=i386 __libm_sse2_tanf() +@ extern __mb_cur_max MSVCRT___mb_cur_max +@ cdecl __p___argc() MSVCRT___p___argc +@ cdecl __p___argv() MSVCRT___p___argv +@ cdecl __p___initenv() +@ cdecl __p___mb_cur_max() +@ cdecl __p___wargv() MSVCRT___p___wargv +@ cdecl __p___winitenv() +@ cdecl __p__acmdln() +@ cdecl __p__commode() +@ cdecl __p__daylight() MSVCRT___p__daylight +@ cdecl __p__dstbias() MSVCRT___p__dstbias +@ cdecl __p__environ() MSVCRT___p__environ +@ cdecl __p__fmode() +@ cdecl __p__iob() MSVCRT___iob_func +@ stub __p__mbcasemap() +@ cdecl __p__mbctype() +@ cdecl __p__pctype() MSVCRT___p__pctype +@ cdecl __p__pgmptr() MSVCRT___p__pgmptr +@ stub __p__pwctype() +@ cdecl __p__timezone() MSVCRT___p__timezone +@ cdecl __p__tzname() +@ cdecl __p__wcmdln() +@ cdecl __p__wenviron() MSVCRT___p__wenviron +@ cdecl __p__wpgmptr() MSVCRT___p__wpgmptr +@ cdecl __pctype_func() MSVCRT___pctype_func +@ extern __pioinfo MSVCRT___pioinfo +@ stub __pwctype_func +@ cdecl __pxcptinfoptrs() MSVCRT___pxcptinfoptrs +@ stub __report_gsfailure +@ cdecl __set_app_type(long) MSVCRT___set_app_type +@ extern __setlc_active MSVCRT___setlc_active +@ cdecl __setusermatherr(ptr) MSVCRT___setusermatherr +@ stub __strncnt +@ stub __swprintf_l +@ cdecl __sys_errlist() +@ cdecl __sys_nerr() +@ cdecl __threadhandle() kernel32.GetCurrentThread +@ cdecl __threadid() kernel32.GetCurrentThreadId +@ cdecl __timezone() MSVCRT___p__timezone +@ cdecl __toascii(long) MSVCRT___toascii +@ cdecl __tzname() __p__tzname +@ cdecl __unDName(ptr str long ptr ptr long) +@ cdecl __unDNameEx(ptr str long ptr ptr ptr long) +@ stub __unDNameHelper +@ extern __unguarded_readlc_active MSVCRT___unguarded_readlc_active +@ cdecl __vswprintf_l(ptr wstr ptr ptr) MSVCRT_vswprintf_l +@ extern __wargv MSVCRT___wargv +@ cdecl __wcserror(wstr) MSVCRT___wcserror +@ cdecl __wcserror_s(ptr long wstr) MSVCRT___wcserror_s +@ stub __wcsncnt +@ cdecl __wgetmainargs(ptr ptr ptr long ptr) +@ extern __winitenv MSVCRT___winitenv +@ cdecl _abnormal_termination() +@ cdecl -ret64 _abs64(int64) +@ cdecl _access(str long) MSVCRT__access +@ cdecl _access_s(str long) MSVCRT__access_s +@ extern _acmdln MSVCRT__acmdln +@ cdecl _aligned_free(ptr) +@ cdecl _aligned_malloc(long long) +@ cdecl _aligned_msize(ptr long long) +@ cdecl _aligned_offset_malloc(long long long) +@ cdecl _aligned_offset_realloc(ptr long long long) +@ stub _aligned_offset_recalloc +@ cdecl _aligned_realloc(ptr long long) +@ stub _aligned_recalloc +@ cdecl _amsg_exit(long) +@ cdecl _assert(str str long) MSVCRT__assert +@ cdecl _atodbl(ptr str) MSVCRT__atodbl +@ cdecl _atodbl_l(ptr str ptr) MSVCRT__atodbl_l +@ cdecl _atof_l(str ptr) MSVCRT__atof_l +@ cdecl _atoflt(ptr str) MSVCRT__atoflt +@ cdecl _atoflt_l(ptr str ptr) MSVCRT__atoflt_l +@ cdecl -ret64 _atoi64(str) ntdll._atoi64 +@ stub _atoi64_l +@ cdecl _atoi_l(str ptr) MSVCRT__atoi_l +@ stub _atol_l +@ cdecl _atoldbl(ptr str) MSVCRT__atoldbl +@ stub _atoldbl_l +@ stub _atoll_l +@ cdecl _beep(long long) MSVCRT__beep +@ cdecl _beginthread(ptr long ptr) +@ cdecl _beginthreadex(ptr long ptr ptr long ptr) +@ cdecl _byteswap_uint64(int64) +@ cdecl _byteswap_ulong(long) MSVCRT__byteswap_ulong +@ cdecl _byteswap_ushort(long) +@ cdecl _c_exit() MSVCRT__c_exit +@ cdecl _cabs(long) MSVCRT__cabs +@ cdecl _callnewh(long) +@ cdecl _calloc_crt(long long) MSVCRT_calloc +@ cdecl _cexit() MSVCRT__cexit +@ cdecl _cgets(ptr) +@ stub _cgets_s +@ stub _cgetws +@ stub _cgetws_s +@ cdecl _chdir(str) MSVCRT__chdir +@ cdecl _chdrive(long) MSVCRT__chdrive +@ cdecl _chgsign(double) MSVCRT__chgsign +@ cdecl -arch=arm,x86_64 _chgsignf(float) MSVCRT__chgsignf +@ cdecl -arch=i386 -norelay _chkesp() +@ cdecl _chmod(str long) MSVCRT__chmod +@ cdecl _chsize(long long) MSVCRT__chsize +@ cdecl _chsize_s(long int64) MSVCRT__chsize_s +@ cdecl _clearfp() +@ cdecl _close(long) MSVCRT__close +@ cdecl _commit(long) MSVCRT__commit +@ extern _commode MSVCRT__commode +@ cdecl _configthreadlocale(long) +@ cdecl _control87(long long) +@ cdecl _controlfp(long long) +@ cdecl _controlfp_s(ptr long long) +@ cdecl _copysign(double double) MSVCRT__copysign +@ cdecl -arch=arm,x86_64 _copysignf(float float) MSVCRT__copysignf +@ varargs _cprintf(str) +@ stub _cprintf_l +@ stub _cprintf_p +@ stub _cprintf_p_l +@ stub _cprintf_s +@ stub _cprintf_s_l +@ cdecl _cputs(str) +@ cdecl _cputws(wstr) +@ cdecl _creat(str long) MSVCRT__creat +@ cdecl _create_locale(long str) MSVCRT__create_locale +@ stub -arch=i386 _crt_debugger_hook +@ stub -arch=arm,win64 __crt_debugger_hook +@ varargs _cscanf(str) +@ varargs _cscanf_l(str ptr) +@ varargs _cscanf_s(str) +@ varargs _cscanf_s_l(str ptr) +@ cdecl _ctime32(ptr) MSVCRT__ctime32 +@ cdecl _ctime32_s(str long ptr) MSVCRT__ctime32_s +@ cdecl _ctime64(ptr) MSVCRT__ctime64 +@ cdecl _ctime64_s(str long ptr) MSVCRT__ctime64_s +@ cdecl _cwait(ptr long long) +@ varargs _cwprintf(wstr) +@ stub _cwprintf_l +@ stub _cwprintf_p +@ stub _cwprintf_p_l +@ stub _cwprintf_s +@ stub _cwprintf_s_l +@ varargs _cwscanf(wstr) +@ varargs _cwscanf_l(wstr ptr) +@ varargs _cwscanf_s(wstr) +@ varargs _cwscanf_s_l(wstr ptr) +@ extern _daylight MSVCRT___daylight +@ stub _dclass +@ cdecl _difftime32(long long) MSVCRT__difftime32 +@ cdecl _difftime64(long long) MSVCRT__difftime64 +@ stub _dosmaperr +@ stub _dpcomp +@ stub _dsign +@ extern _dstbias MSVCRT__dstbias +@ stub _dtest +@ cdecl _dup(long) MSVCRT__dup +@ cdecl _dup2(long long) MSVCRT__dup2 +@ cdecl _dupenv_s(ptr ptr str) +@ cdecl _ecvt(double long ptr ptr) MSVCRT__ecvt +@ cdecl _ecvt_s(str long double long ptr ptr) MSVCRT__ecvt_s +@ cdecl _endthread() +@ cdecl _endthreadex(long) +@ extern _environ MSVCRT__environ +@ cdecl _eof(long) MSVCRT__eof +@ cdecl _errno() MSVCRT__errno +@ stub _except1 +@ cdecl -arch=i386 _except_handler2(ptr ptr ptr ptr) +@ cdecl -arch=i386 _except_handler3(ptr ptr ptr ptr) +@ cdecl -arch=i386 _except_handler4_common(ptr ptr ptr ptr ptr ptr) +@ varargs _execl(str str) +@ varargs _execle(str str) +@ varargs _execlp(str str) +@ varargs _execlpe(str str) +@ cdecl _execv(str ptr) +@ cdecl _execve(str ptr ptr) MSVCRT__execve +@ cdecl _execvp(str ptr) +@ cdecl _execvpe(str ptr ptr) +@ cdecl _exit(long) MSVCRT__exit +@ cdecl _expand(ptr long) +@ cdecl _fclose_nolock(ptr) MSVCRT__fclose_nolock +@ cdecl _fcloseall() MSVCRT__fcloseall +@ cdecl _fcvt(double long ptr ptr) MSVCRT__fcvt +@ cdecl _fcvt_s(ptr long double long ptr ptr) MSVCRT__fcvt_s +@ stub _fdclass +@ cdecl _fdopen(long str) MSVCRT__fdopen +@ stub _fdpcomp +@ stub _fdsign +@ stub _fdtest +@ cdecl _fflush_nolock(ptr) MSVCRT__fflush_nolock +@ cdecl _fgetc_nolock(ptr) MSVCRT__fgetc_nolock +@ cdecl _fgetchar() MSVCRT__fgetchar +@ cdecl _fgetwc_nolock(ptr) MSVCRT__fgetwc_nolock +@ cdecl _fgetwchar() MSVCRT__fgetwchar +@ cdecl _filbuf(ptr) MSVCRT__filbuf +@ cdecl _filelength(long) MSVCRT__filelength +@ cdecl -ret64 _filelengthi64(long) MSVCRT__filelengthi64 +@ cdecl _fileno(ptr) MSVCRT__fileno +@ cdecl _findclose(long) MSVCRT__findclose +@ cdecl _findfirst32(str ptr) MSVCRT__findfirst32 +@ stub _findfirst32i64 +@ cdecl _findfirst64(str ptr) MSVCRT__findfirst64 +@ cdecl _findfirst64i32(str ptr) MSVCRT__findfirst64i32 +@ cdecl _findnext32(long ptr) MSVCRT__findnext32 +@ stub _findnext32i64 +@ cdecl _findnext64(long ptr) MSVCRT__findnext64 +@ cdecl _findnext64i32(long ptr) MSVCRT__findnext64i32 +@ cdecl _finite(double) MSVCRT__finite +@ cdecl -arch=arm,x86_64 _finitef(float) MSVCRT__finitef +@ cdecl _flsbuf(long ptr) MSVCRT__flsbuf +@ cdecl _flushall() MSVCRT__flushall +@ extern _fmode MSVCRT__fmode +@ cdecl _fpclass(double) MSVCRT__fpclass +# stub -arch=x86_64 _fpclassf +@ stub _fpieee_flt(long ptr ptr) +@ cdecl _fpreset() +@ stub _fprintf_l +@ stub _fprintf_p +@ stub _fprintf_p_l +@ stub _fprintf_s_l +@ cdecl _fputc_nolock(long ptr) MSVCRT__fputc_nolock +@ cdecl _fputchar(long) MSVCRT__fputchar +@ cdecl _fputwc_nolock(long ptr) MSVCRT__fputwc_nolock +@ cdecl _fputwchar(long) MSVCRT__fputwchar +@ cdecl _fread_nolock(ptr long long ptr) MSVCRT__fread_nolock +@ cdecl _fread_nolock_s(ptr long long long ptr) MSVCRT__fread_nolock_s +@ cdecl _free_locale(ptr) MSVCRT__free_locale +@ stub _freea +@ stub _freea_s +@ stub _freefls +@ varargs _fscanf_l(ptr str ptr) MSVCRT__fscanf_l +@ varargs _fscanf_s_l(ptr str ptr) MSVCRT__fscanf_s_l +@ cdecl _fseek_nolock(ptr long long) MSVCRT__fseek_nolock +@ cdecl _fseeki64(ptr int64 long) MSVCRT__fseeki64 +@ cdecl _fseeki64_nolock(ptr int64 long) MSVCRT__fseeki64_nolock +@ cdecl _fsopen(str str long) MSVCRT__fsopen +@ cdecl _fstat32(long ptr) MSVCRT__fstat32 +@ stub _fstat32i64 +@ cdecl _fstat64(long ptr) MSVCRT__fstat64 +@ cdecl _fstat64i32(long ptr) MSVCRT__fstat64i32 +@ cdecl _ftell_nolock(ptr) MSVCRT__ftell_nolock +@ cdecl -ret64 _ftelli64(ptr) MSVCRT__ftelli64 +@ cdecl -ret64 _ftelli64_nolock(ptr) MSVCRT__ftelli64_nolock +@ cdecl _ftime32(ptr) MSVCRT__ftime32 +@ cdecl _ftime32_s(ptr) MSVCRT__ftime32_s +@ cdecl _ftime64(ptr) MSVCRT__ftime64 +@ cdecl _ftime64_s(ptr) MSVCRT__ftime64_s +@ cdecl -arch=i386 -ret64 _ftol() MSVCRT__ftol +@ cdecl _fullpath(ptr str long) MSVCRT__fullpath +@ cdecl _futime32(long ptr) +@ cdecl _futime64(long ptr) +@ varargs _fwprintf_l(ptr wstr ptr) MSVCRT__fwprintf_l +@ stub _fwprintf_p +@ stub _fwprintf_p_l +@ stub _fwprintf_s_l +@ cdecl _fwrite_nolock(ptr long long ptr) MSVCRT__fwrite_nolock +@ varargs _fwscanf_l(ptr wstr ptr) MSVCRT__fwscanf_l +@ varargs _fwscanf_s_l(ptr wstr ptr) MSVCRT__fwscanf_s_l +@ cdecl _gcvt(double long str) MSVCRT__gcvt +@ cdecl _gcvt_s(ptr long double long) MSVCRT__gcvt_s +@ cdecl _get_current_locale() MSVCRT__get_current_locale +@ cdecl _get_daylight(ptr) +@ cdecl _get_doserrno(ptr) +@ stub _get_dstbias +@ cdecl _get_errno(ptr) +@ cdecl _get_fmode(ptr) MSVCRT__get_fmode +@ cdecl _get_heap_handle() +@ cdecl _get_invalid_parameter_handler() +@ cdecl _get_osfhandle(long) MSVCRT__get_osfhandle +@ cdecl _get_output_format() MSVCRT__get_output_format +@ cdecl _get_pgmptr(ptr) +@ cdecl _get_printf_count_output() MSVCRT__get_printf_count_output +@ stub _get_purecall_handler +@ cdecl _get_terminate() MSVCRT__get_terminate +@ cdecl _get_timezone(ptr) +@ cdecl _get_tzname(ptr str long long) MSVCRT__get_tzname +@ cdecl _get_unexpected() MSVCRT__get_unexpected +@ cdecl _get_wpgmptr(ptr) +@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock +@ cdecl _getch() +@ stub _getch_nolock +@ cdecl _getche() +@ stub _getche_nolock +@ cdecl _getcwd(str long) MSVCRT__getcwd +@ cdecl _getdcwd(long str long) MSVCRT__getdcwd +@ cdecl _getdiskfree(long ptr) MSVCRT__getdiskfree +@ cdecl _getdllprocaddr(long str long) +@ cdecl _getdrive() MSVCRT__getdrive +@ cdecl _getdrives() kernel32.GetLogicalDrives +@ cdecl _getmaxstdio() MSVCRT__getmaxstdio +@ cdecl _getmbcp() +@ cdecl _getpid() _getpid +@ cdecl _getptd() +@ stub _getsystime(ptr) +@ cdecl _getw(ptr) MSVCRT__getw +@ cdecl _getwc_nolock(ptr) MSVCRT__fgetwc_nolock +@ stub _getwch +@ stub _getwch_nolock +@ stub _getwche +@ stub _getwche_nolock +@ cdecl _getws(ptr) MSVCRT__getws +@ stub _getws_s +@ cdecl -arch=i386 _global_unwind2(ptr) +@ cdecl _gmtime32(ptr) MSVCRT__gmtime32 +@ cdecl _gmtime32_s(ptr ptr) MSVCRT__gmtime32_s +@ cdecl _gmtime64(ptr) MSVCRT__gmtime64 +@ cdecl _gmtime64_s(ptr ptr) MSVCRT__gmtime64_s +@ cdecl _heapadd(ptr long) +@ cdecl _heapchk() +@ cdecl _heapmin() +@ cdecl _heapset(long) +@ stub _heapused(ptr ptr) +@ cdecl _heapwalk(ptr) +@ cdecl _hypot(double double) +@ cdecl _hypotf(float float) MSVCRT__hypotf +@ cdecl _i64toa(int64 ptr long) ntdll._i64toa +@ cdecl _i64toa_s(int64 ptr long long) MSVCRT__i64toa_s +@ cdecl _i64tow(int64 ptr long) ntdll._i64tow +@ cdecl _i64tow_s(int64 ptr long long) MSVCRT__i64tow_s +@ stub _initptd +@ cdecl _initterm(ptr ptr) +@ cdecl _initterm_e(ptr ptr) +@ stub -arch=i386 _inp(long) +@ stub -arch=i386 _inpd(long) +@ stub -arch=i386 _inpw(long) +@ cdecl _invalid_parameter(wstr wstr wstr long long) MSVCRT__invalid_parameter +@ cdecl _invalid_parameter_noinfo() +@ stub _invalid_parameter_noinfo_noreturn +@ stub _invoke_watson +@ extern _iob MSVCRT__iob +@ cdecl _isalnum_l(long ptr) MSVCRT__isalnum_l +@ cdecl _isalpha_l(long ptr) MSVCRT__isalpha_l +@ cdecl _isatty(long) MSVCRT__isatty +@ stub _isblank_l +@ cdecl _iscntrl_l(long ptr) MSVCRT__iscntrl_l +@ cdecl _isctype(long long) MSVCRT__isctype +@ cdecl _isctype_l(long long ptr) MSVCRT__isctype_l +@ cdecl _isdigit_l(long ptr) MSVCRT__isdigit_l +@ cdecl _isgraph_l(long ptr) MSVCRT__isgraph_l +@ cdecl _isleadbyte_l(long ptr) MSVCRT__isleadbyte_l +@ cdecl _islower_l(long ptr) MSVCRT__islower_l +@ stub _ismbbalnum(long) +@ stub _ismbbalnum_l +@ stub _ismbbalpha(long) +@ stub _ismbbalpha_l +@ stub _ismbbblank +@ stub _ismbbblank_l +@ stub _ismbbgraph(long) +@ stub _ismbbgraph_l +@ stub _ismbbkalnum(long) +@ stub _ismbbkalnum_l +@ cdecl _ismbbkana(long) +@ stub _ismbbkana_l +@ stub _ismbbkprint(long) +@ stub _ismbbkprint_l +@ stub _ismbbkpunct(long) +@ stub _ismbbkpunct_l +@ cdecl _ismbblead(long) +@ stub _ismbblead_l +@ stub _ismbbprint(long) +@ stub _ismbbprint_l +@ stub _ismbbpunct(long) +@ stub _ismbbpunct_l +@ cdecl _ismbbtrail(long) +@ stub _ismbbtrail_l +@ cdecl _ismbcalnum(long) +@ stub _ismbcalnum_l +@ cdecl _ismbcalpha(long) +@ stub _ismbcalpha_l +@ stub _ismbcblank +@ stub _ismbcblank_l +@ cdecl _ismbcdigit(long) +@ stub _ismbcdigit_l +@ cdecl _ismbcgraph(long) +@ stub _ismbcgraph_l +@ cdecl _ismbchira(long) +@ stub _ismbchira_l +@ cdecl _ismbckata(long) +@ stub _ismbckata_l +@ stub _ismbcl0(long) +@ stub _ismbcl0_l +@ stub _ismbcl1(long) +@ stub _ismbcl1_l +@ stub _ismbcl2(long) +@ stub _ismbcl2_l +@ cdecl _ismbclegal(long) +@ stub _ismbclegal_l +@ stub _ismbclower(long) +@ stub _ismbclower_l +@ stub _ismbcprint(long) +@ stub _ismbcprint_l +@ cdecl _ismbcpunct(long) +@ stub _ismbcpunct_l +@ cdecl _ismbcspace(long) +@ stub _ismbcspace_l +@ cdecl _ismbcsymbol(long) +@ stub _ismbcsymbol_l +@ cdecl _ismbcupper(long) +@ stub _ismbcupper_l +@ cdecl _ismbslead(ptr ptr) +@ stub _ismbslead_l +@ cdecl _ismbstrail(ptr ptr) +@ stub _ismbstrail_l +@ cdecl _isnan(double) MSVCRT__isnan +@ cdecl -arch=arm,x86_64 _isnanf(float) MSVCRT__isnanf +@ cdecl _isprint_l(long ptr) MSVCRT__isprint_l +@ stub _ispunct_l +@ cdecl _isspace_l(long ptr) MSVCRT__isspace_l +@ cdecl _isupper_l(long ptr) MSVCRT__isupper_l +@ stub _iswalnum_l +@ cdecl _iswalpha_l(long ptr) MSVCRT__iswalpha_l +@ stub _iswblank_l +@ stub _iswcntrl_l +@ stub _iswcsym_l +@ stub _iswcsymf_l +@ stub _iswctype_l +@ cdecl _iswdigit_l(long ptr) MSVCRT__iswdigit_l +@ stub _iswgraph_l +@ stub _iswlower_l +@ stub _iswprint_l +@ stub _iswpunct_l +@ stub _iswspace_l +@ stub _iswupper_l +@ stub _iswxdigit_l +@ cdecl _isxdigit_l(long ptr) MSVCRT__isxdigit_l +@ cdecl _itoa(long ptr long) MSVCRT__itoa +@ cdecl _itoa_s(long ptr long long) MSVCRT__itoa_s +@ cdecl _itow(long ptr long) ntdll._itow +@ cdecl _itow_s(long ptr long long) MSVCRT__itow_s +@ cdecl _j0(double) MSVCRT__j0 +@ cdecl _j1(double) MSVCRT__j1 +@ cdecl _jn(long double) MSVCRT__jn +@ cdecl _kbhit() +@ stub _ldclass +@ stub _ldpcomp +@ stub _ldsign +@ stub _ldtest +@ cdecl _lfind(ptr ptr ptr long ptr) +@ stub _lfind_s +@ cdecl -arch=i386 _libm_sse2_acos_precise() __libm_sse2_acos +@ cdecl -arch=i386 _libm_sse2_asin_precise() __libm_sse2_asin +@ cdecl -arch=i386 _libm_sse2_atan_precise() __libm_sse2_atan +@ cdecl -arch=i386 _libm_sse2_cos_precise() __libm_sse2_cos +@ cdecl -arch=i386 _libm_sse2_exp_precise() __libm_sse2_exp +@ cdecl -arch=i386 _libm_sse2_log10_precise() __libm_sse2_log10 +@ cdecl -arch=i386 _libm_sse2_log_precise() __libm_sse2_log +@ cdecl -arch=i386 _libm_sse2_pow_precise() __libm_sse2_pow +@ cdecl -arch=i386 _libm_sse2_sin_precise() __libm_sse2_sin +@ cdecl -arch=i386 _libm_sse2_sqrt_precise() __libm_sse2_sqrt_precise +@ cdecl -arch=i386 _libm_sse2_tan_precise() __libm_sse2_tan +@ cdecl _loaddll(str) +@ cdecl -arch=x86_64 _local_unwind(ptr ptr) +@ cdecl -arch=i386 _local_unwind2(ptr long) +@ cdecl -arch=i386 _local_unwind4(ptr ptr long) +@ cdecl _localtime32(ptr) MSVCRT__localtime32 +@ cdecl _localtime32_s(ptr ptr) +@ cdecl _localtime64(ptr) MSVCRT__localtime64 +@ cdecl _localtime64_s(ptr ptr) +@ cdecl _lock(long) +@ cdecl _lock_file(ptr) MSVCRT__lock_file +@ cdecl _locking(long long long) MSVCRT__locking +@ cdecl _logb(double) MSVCRT__logb +@ cdecl -arch=arm,x86_64 _logbf(float) MSVCRT__logbf +@ cdecl -arch=i386 _longjmpex(ptr long) MSVCRT_longjmp +@ cdecl _lrotl(long long) MSVCRT__lrotl +@ cdecl _lrotr(long long) MSVCRT__lrotr +@ cdecl _lsearch(ptr ptr ptr long ptr) +@ stub _lsearch_s +@ cdecl _lseek(long long long) MSVCRT__lseek +@ cdecl -ret64 _lseeki64(long int64 long) MSVCRT__lseeki64 +@ cdecl _ltoa(long ptr long) ntdll._ltoa +@ cdecl _ltoa_s(long ptr long long) MSVCRT__ltoa_s +@ cdecl _ltow(long ptr long) ntdll._ltow +@ cdecl _ltow_s(long ptr long long) MSVCRT__ltow_s +@ cdecl _makepath(ptr str str str str) MSVCRT__makepath +@ cdecl _makepath_s(ptr long str str str str) MSVCRT__makepath_s +@ cdecl _malloc_crt(long) MSVCRT_malloc +@ cdecl _mbbtombc(long) +@ stub _mbbtombc_l +@ cdecl _mbbtype(long long) +@ stub _mbbtype_l +# extern _mbcasemap +@ cdecl _mbccpy(ptr str) +@ stub _mbccpy_l +@ stub _mbccpy_s +@ stub _mbccpy_s_l +@ cdecl _mbcjistojms(long) +@ stub _mbcjistojms_l +@ cdecl _mbcjmstojis(long) +@ stub _mbcjmstojis_l +@ cdecl _mbclen(ptr) +@ stub _mbclen_l +@ stub _mbctohira(long) +@ stub _mbctohira_l +@ stub _mbctokata(long) +@ stub _mbctokata_l +@ cdecl _mbctolower(long) +@ stub _mbctolower_l +@ cdecl _mbctombb(long) +@ stub _mbctombb_l +@ cdecl _mbctoupper(long) +@ stub _mbctoupper_l +@ extern _mbctype MSVCRT_mbctype +@ stub _mblen_l +@ cdecl _mbsbtype(str long) +@ stub _mbsbtype_l +@ stub _mbscat_s +@ stub _mbscat_s_l +@ cdecl _mbschr(str long) +@ stub _mbschr_l +@ cdecl _mbscmp(str str) +@ stub _mbscmp_l +@ cdecl _mbscoll(str str) +@ cdecl _mbscoll_l(str str ptr) +@ cdecl _mbscpy_s(ptr long str) +@ cdecl _mbscpy_s_l(ptr long str ptr) +@ cdecl _mbscspn(str str) +@ stub _mbscspn_l +@ cdecl _mbsdec(ptr ptr) +@ stub _mbsdec_l +@ cdecl _mbsicmp(str str) +@ stub _mbsicmp_l +@ cdecl _mbsicoll(str str) +@ cdecl _mbsicoll_l(str str ptr) +@ cdecl _mbsinc(str) +@ stub _mbsinc_l +@ cdecl _mbslen(str) +@ stub _mbslen_l +@ cdecl _mbslwr(str) +@ stub _mbslwr_l +@ cdecl _mbslwr_s(str long) +@ stub _mbslwr_s_l +@ cdecl _mbsnbcat(str str long) +@ stub _mbsnbcat_l +@ cdecl _mbsnbcat_s(str long ptr long) +@ stub _mbsnbcat_s_l +@ cdecl _mbsnbcmp(str str long) +@ stub _mbsnbcmp_l +@ cdecl _mbsnbcnt(ptr long) +@ stub _mbsnbcnt_l +@ cdecl _mbsnbcoll(str str long) +@ cdecl _mbsnbcoll_l(str str long ptr) +@ cdecl _mbsnbcpy(ptr str long) +@ stub _mbsnbcpy_l +@ cdecl _mbsnbcpy_s(ptr long str long) +@ cdecl _mbsnbcpy_s_l(ptr long str long ptr) +@ cdecl _mbsnbicmp(str str long) +@ stub _mbsnbicmp_l +@ cdecl _mbsnbicoll(str str long) +@ cdecl _mbsnbicoll_l(str str long ptr) +@ cdecl _mbsnbset(ptr long long) +@ stub _mbsnbset_l +@ stub _mbsnbset_s +@ stub _mbsnbset_s_l +@ cdecl _mbsncat(str str long) +@ stub _mbsncat_l +@ stub _mbsncat_s +@ stub _mbsncat_s_l +@ cdecl _mbsnccnt(str long) +@ stub _mbsnccnt_l +@ cdecl _mbsncmp(str str long) +@ stub _mbsncmp_l +@ stub _mbsncoll(str str long) +@ stub _mbsncoll_l +@ cdecl _mbsncpy(ptr str long) +@ stub _mbsncpy_l +@ stub _mbsncpy_s +@ stub _mbsncpy_s_l +@ cdecl _mbsnextc(str) +@ stub _mbsnextc_l +@ cdecl _mbsnicmp(str str long) +@ stub _mbsnicmp_l +@ stub _mbsnicoll(str str long) +@ stub _mbsnicoll_l +@ cdecl _mbsninc(str long) +@ stub _mbsninc_l +@ stub _mbsnlen +@ stub _mbsnlen_l +@ cdecl _mbsnset(ptr long long) +@ stub _mbsnset_l +@ stub _mbsnset_s +@ stub _mbsnset_s_l +@ cdecl _mbspbrk(str str) +@ stub _mbspbrk_l +@ cdecl _mbsrchr(str long) +@ stub _mbsrchr_l +@ cdecl _mbsrev(str) +@ stub _mbsrev_l +@ cdecl _mbsset(ptr long) +@ stub _mbsset_l +@ stub _mbsset_s +@ stub _mbsset_s_l +@ cdecl _mbsspn(str str) +@ stub _mbsspn_l +@ cdecl _mbsspnp(str str) +@ stub _mbsspnp_l +@ cdecl _mbsstr(str str) +@ stub _mbsstr_l +@ cdecl _mbstok(str str) +@ cdecl _mbstok_l(str str ptr) +@ cdecl _mbstok_s(str str ptr) +@ cdecl _mbstok_s_l(str str ptr ptr) +@ cdecl _mbstowcs_l(ptr str long ptr) MSVCRT__mbstowcs_l +@ cdecl _mbstowcs_s_l(ptr ptr long str long ptr) MSVCRT__mbstowcs_s_l +@ cdecl _mbstrlen(str) +@ cdecl _mbstrlen_l(str ptr) +@ stub _mbstrnlen +@ stub _mbstrnlen_l +@ cdecl _mbsupr(str) +@ stub _mbsupr_l +@ cdecl _mbsupr_s(str long) +@ stub _mbsupr_s_l +@ cdecl _mbtowc_l(ptr str long ptr) MSVCRT_mbtowc_l +@ cdecl _memccpy(ptr ptr long long) ntdll._memccpy +@ cdecl _memicmp(str str long) ntdll._memicmp +@ stub _memicmp_l +@ cdecl _mkdir(str) MSVCRT__mkdir +@ cdecl _mkgmtime32(ptr) MSVCRT__mkgmtime32 +@ cdecl _mkgmtime64(ptr) MSVCRT__mkgmtime64 +@ cdecl _mktemp(str) MSVCRT__mktemp +@ cdecl _mktemp_s(str long) MSVCRT__mktemp_s +@ cdecl _mktime32(ptr) MSVCRT__mktime32 +@ cdecl _mktime64(ptr) MSVCRT__mktime64 +@ cdecl _msize(ptr) +@ cdecl _nextafter(double double) MSVCRT__nextafter +@ cdecl -arch=arm,x86_64 _nextafterf(float float) MSVCRT__nextafterf +@ cdecl _onexit(ptr) MSVCRT__onexit +@ varargs _open(str long) MSVCRT__open +@ cdecl _open_osfhandle(long long) MSVCRT__open_osfhandle +@ stub -arch=i386 _outp(long long) +@ stub -arch=i386 _outpd(long long) +@ stub -arch=i386 _outpw(long long) +@ cdecl _pclose(ptr) MSVCRT__pclose +@ extern _pctype MSVCRT__pctype +@ extern _pgmptr MSVCRT__pgmptr +@ cdecl _pipe(ptr long long) MSVCRT__pipe +@ cdecl _popen(str str) MSVCRT__popen +@ stub _printf_l +@ stub _printf_p +@ stub _printf_p_l +@ stub _printf_s_l +@ cdecl _purecall() +@ cdecl _putc_nolock(long ptr) MSVCRT__fputc_nolock +@ cdecl _putch(long) +@ stub _putch_nolock +@ cdecl _putenv(str) +@ cdecl _putenv_s(str str) +@ cdecl _putw(long ptr) MSVCRT__putw +@ cdecl _putwc_nolock(long ptr) MSVCRT__fputwc_nolock +@ cdecl _putwch(long) MSVCRT__putwch +@ stub _putwch_nolock +@ cdecl _putws(wstr) MSVCRT__putws +# extern _pwctype +@ cdecl _read(long ptr long) MSVCRT__read +@ cdecl _realloc_crt(ptr long) MSVCRT_realloc +@ cdecl _recalloc(ptr long long) +@ stub _recalloc_crt +@ cdecl _resetstkoflw() MSVCRT__resetstkoflw +@ cdecl _rmdir(str) MSVCRT__rmdir +@ cdecl _rmtmp() MSVCRT__rmtmp +@ cdecl _rotl(long long) +@ cdecl -ret64 _rotl64(int64 long) +@ cdecl _rotr(long long) +@ cdecl -ret64 _rotr64(int64 long) +@ cdecl _scalb(double long) MSVCRT__scalb +@ cdecl -arch=arm,x86_64 _scalbf(float long) MSVCRT__scalbf +@ varargs _scanf_l(str ptr) MSVCRT__scanf_l +@ varargs _scanf_s_l(str ptr) MSVCRT__scanf_s_l +@ varargs _scprintf(str) MSVCRT__scprintf +@ stub _scprintf_l +@ stub _scprintf_p +@ stub _scprintf_p_l +@ varargs _scwprintf(wstr) MSVCRT__scwprintf +@ stub _scwprintf_l +@ stub _scwprintf_p +@ stub _scwprintf_p_l +@ cdecl _searchenv(str str ptr) MSVCRT__searchenv +@ cdecl _searchenv_s(str str ptr long) MSVCRT__searchenv_s +@ stdcall -arch=i386 _seh_longjmp_unwind4(ptr) +@ stdcall -arch=i386 _seh_longjmp_unwind(ptr) +@ cdecl -arch=i386 _set_SSE2_enable(long) MSVCRT__set_SSE2_enable +@ cdecl _set_abort_behavior(long long) MSVCRT__set_abort_behavior +@ cdecl _set_controlfp(long long) +@ cdecl _set_doserrno(long) +@ cdecl _set_errno(long) +@ cdecl _set_error_mode(long) +@ cdecl _set_fmode(long) MSVCRT__set_fmode +@ cdecl _set_invalid_parameter_handler(ptr) +@ stub _set_malloc_crt_max_wait +@ cdecl _set_output_format(long) MSVCRT__set_output_format +@ cdecl _set_printf_count_output(long) MSVCRT__set_printf_count_output +@ cdecl _set_purecall_handler(ptr) +@ cdecl _seterrormode(long) +@ cdecl -arch=i386,x86_64,arm -norelay _setjmp(ptr) MSVCRT__setjmp +@ cdecl -arch=i386 -norelay _setjmp3(ptr long) MSVCRT__setjmp3 +@ cdecl -arch=x86_64,arm -norelay _setjmpex(ptr ptr) MSVCRT__setjmpex +@ cdecl _setmaxstdio(long) MSVCRT__setmaxstdio +@ cdecl _setmbcp(long) +@ cdecl _setmode(long long) MSVCRT__setmode +@ stub _setsystime(ptr long) +@ cdecl _sleep(long) MSVCRT__sleep +@ varargs _snprintf(ptr long str) MSVCRT__snprintf +@ stub _snprintf_c +@ stub _snprintf_c_l +@ varargs _snprintf_l(ptr long str ptr) MSVCRT__snprintf_l +@ varargs _snprintf_s(ptr long long str) MSVCRT__snprintf_s +@ stub _snprintf_s_l +@ varargs _snscanf(str long str) MSVCRT__snscanf +@ varargs _snscanf_l(str long str ptr) MSVCRT__snscanf_l +@ varargs _snscanf_s(str long str) MSVCRT__snscanf_s +@ varargs _snscanf_s_l(str long str ptr) MSVCRT__snscanf_s_l +@ varargs _snwprintf(ptr long wstr) MSVCRT__snwprintf +@ varargs _snwprintf_l(ptr long wstr ptr) MSVCRT__snwprintf_l +@ varargs _snwprintf_s(ptr long long wstr) MSVCRT__snwprintf_s +@ varargs _snwprintf_s_l(ptr long long wstr ptr) MSVCRT__snwprintf_s_l +@ varargs _snwscanf(wstr long wstr) MSVCRT__snwscanf +@ varargs _snwscanf_l(wstr long wstr ptr) MSVCRT__snwscanf_l +@ varargs _snwscanf_s(wstr long wstr) MSVCRT__snwscanf_s +@ varargs _snwscanf_s_l(wstr long wstr ptr) MSVCRT__snwscanf_s_l +@ varargs _sopen(str long long) MSVCRT__sopen +@ cdecl _sopen_s(ptr str long long long) MSVCRT__sopen_s +@ varargs _spawnl(long str str) +@ varargs _spawnle(long str str) +@ varargs _spawnlp(long str str) +@ varargs _spawnlpe(long str str) +@ cdecl _spawnv(long str ptr) +@ cdecl _spawnve(long str ptr ptr) MSVCRT__spawnve +@ cdecl _spawnvp(long str ptr) +@ cdecl _spawnvpe(long str ptr ptr) MSVCRT__spawnvpe +@ cdecl _splitpath(str ptr ptr ptr ptr) MSVCRT__splitpath +@ cdecl _splitpath_s(str ptr long ptr long ptr long ptr long) MSVCRT__splitpath_s +@ varargs _sprintf_l(ptr str ptr) MSVCRT_sprintf_l +@ varargs _sprintf_p(ptr long str) MSVCRT__sprintf_p +@ varargs _sprintf_p_l(ptr long str ptr) MSVCRT_sprintf_p_l +@ varargs _sprintf_s_l(ptr long str ptr) MSVCRT_sprintf_s_l +@ varargs _sscanf_l(str str ptr) MSVCRT__sscanf_l +@ varargs _sscanf_s_l(str str ptr) MSVCRT__sscanf_s_l +@ cdecl _stat32(str ptr) MSVCRT__stat32 +@ cdecl _stat32i64(str ptr) MSVCRT__stat32i64 +@ cdecl _stat64(str ptr) MSVCRT_stat64 +@ cdecl _stat64i32(str ptr) MSVCRT__stat64i32 +@ cdecl _statusfp() +@ cdecl -arch=i386 _statusfp2(ptr ptr) +@ cdecl _strcoll_l(str str ptr) MSVCRT_strcoll_l +@ cdecl _strdate(ptr) MSVCRT__strdate +@ cdecl _strdate_s(ptr long) +@ cdecl _strdup(str) MSVCRT__strdup +@ cdecl _strerror(long) MSVCRT__strerror +@ stub _strerror_s +@ stub _strftime_l +@ cdecl _stricmp(str str) MSVCRT__stricmp +@ cdecl _stricmp_l(str str ptr) MSVCRT__stricmp_l +@ cdecl _stricoll(str str) MSVCRT__stricoll +@ cdecl _stricoll_l(str str ptr) MSVCRT__stricoll_l +@ cdecl _strlwr(str) MSVCRT__strlwr +@ cdecl _strlwr_l(str ptr) +@ cdecl _strlwr_s(ptr long) MSVCRT__strlwr_s +@ cdecl _strlwr_s_l(ptr long ptr) MSVCRT__strlwr_s_l +@ cdecl _strncoll(str str long) MSVCRT__strncoll +@ cdecl _strncoll_l(str str long ptr) MSVCRT__strncoll_l +@ cdecl _strnicmp(str str long) MSVCRT__strnicmp +@ cdecl _strnicmp_l(str str long ptr) MSVCRT__strnicmp_l +@ cdecl _strnicoll(str str long) MSVCRT__strnicoll +@ cdecl _strnicoll_l(str str long ptr) MSVCRT__strnicoll_l +@ cdecl _strnset(str long long) MSVCRT__strnset +@ cdecl _strnset_s(str long long long) MSVCRT__strnset_s +@ cdecl _strrev(str) MSVCRT__strrev +@ cdecl _strset(str long) +@ stub _strset_s +@ cdecl _strtime(ptr) MSVCRT__strtime +@ cdecl _strtime_s(ptr long) +@ cdecl _strtod_l(str ptr ptr) MSVCRT_strtod_l +@ stub _strtof_l +@ cdecl -ret64 _strtoi64(str ptr long) MSVCRT_strtoi64 +@ cdecl -ret64 _strtoi64_l(str ptr long ptr) MSVCRT_strtoi64_l +@ stub _strtoimax_l +@ stub _strtol_l +@ stub _strtold_l +@ stub _strtoll_l +@ cdecl -ret64 _strtoui64(str ptr long) MSVCRT_strtoui64 +@ cdecl -ret64 _strtoui64_l(str ptr long ptr) MSVCRT_strtoui64_l +@ cdecl _strtoul_l(str ptr long ptr) MSVCRT_strtoul_l +@ stub _strtoull_l +@ stub _strtoumax_l +@ cdecl _strupr(str) MSVCRT__strupr +@ cdecl _strupr_l(str ptr) MSVCRT__strupr_l +@ cdecl _strupr_s(str long) MSVCRT__strupr_s +@ cdecl _strupr_s_l(str long ptr) MSVCRT__strupr_s_l +@ cdecl _strxfrm_l(ptr str long ptr) MSVCRT__strxfrm_l +@ cdecl _swab(str str long) MSVCRT__swab +@ varargs _swprintf(ptr wstr) MSVCRT_swprintf +@ stub _swprintf_c +@ stub _swprintf_c_l +@ stub _swprintf_p +@ varargs _swprintf_p_l(ptr long wstr ptr) MSVCRT_swprintf_p_l +@ varargs _swprintf_s_l(ptr long wstr ptr) MSVCRT__swprintf_s_l +@ varargs _swscanf_l(wstr wstr ptr) MSVCRT__swscanf_l +@ varargs _swscanf_s_l(wstr wstr ptr) MSVCRT__swscanf_s_l +@ extern _sys_errlist MSVCRT__sys_errlist +@ extern _sys_nerr MSVCRT__sys_nerr +@ cdecl _tell(long) MSVCRT__tell +@ cdecl -ret64 _telli64(long) +@ cdecl _tempnam(str str) MSVCRT__tempnam +@ cdecl _time32(ptr) MSVCRT__time32 +@ cdecl _time64(ptr) MSVCRT__time64 +@ extern _timezone MSVCRT___timezone +@ cdecl _tolower(long) MSVCRT__tolower +@ cdecl _tolower_l(long ptr) MSVCRT__tolower_l +@ cdecl _toupper(long) MSVCRT__toupper +@ cdecl _toupper_l(long ptr) MSVCRT__toupper_l +@ cdecl _towlower_l(long ptr) MSVCRT__towlower_l +@ cdecl _towupper_l(long ptr) MSVCRT__towupper_l +@ extern _tzname MSVCRT__tzname +@ cdecl _tzset() MSVCRT__tzset +@ cdecl _ui64toa(int64 ptr long) ntdll._ui64toa +@ cdecl _ui64toa_s(int64 ptr long long) MSVCRT__ui64toa_s +@ cdecl _ui64tow(int64 ptr long) ntdll._ui64tow +@ cdecl _ui64tow_s(int64 ptr long long) MSVCRT__ui64tow_s +@ cdecl _ultoa(long ptr long) ntdll._ultoa +@ cdecl _ultoa_s(long ptr long long) MSVCRT__ultoa_s +@ cdecl _ultow(long ptr long) ntdll._ultow +@ cdecl _ultow_s(long ptr long long) MSVCRT__ultow_s +@ cdecl _umask(long) MSVCRT__umask +@ stub _umask_s +@ cdecl _ungetc_nolock(long ptr) MSVCRT__ungetc_nolock +@ cdecl _ungetch(long) +@ stub _ungetch_nolock +@ cdecl _ungetwc_nolock(long ptr) MSVCRT__ungetwc_nolock +@ stub _ungetwch +@ stub _ungetwch_nolock +@ cdecl _unlink(str) MSVCRT__unlink +@ cdecl _unloaddll(long) +@ cdecl _unlock(long) +@ cdecl _unlock_file(ptr) MSVCRT__unlock_file +@ cdecl _utime32(str ptr) +@ cdecl _utime64(str ptr) +@ stub _vacopy +@ cdecl _vcprintf(str ptr) +@ stub _vcprintf_l +@ stub _vcprintf_p +@ stub _vcprintf_p_l +@ stub _vcprintf_s +@ stub _vcprintf_s_l +@ cdecl _vcwprintf(wstr ptr) +@ stub _vcwprintf_l +@ stub _vcwprintf_p +@ stub _vcwprintf_p_l +@ stub _vcwprintf_s +@ stub _vcwprintf_s_l +@ stub _vfprintf_l +@ stub _vfprintf_p +@ stub _vfprintf_p_l +@ stub _vfprintf_s_l +@ cdecl _vfwprintf_l(ptr wstr ptr ptr) MSVCRT__vfwprintf_l +@ stub _vfwprintf_p +@ stub _vfwprintf_p_l +@ stub _vfwprintf_s_l +@ stub _vprintf_l +@ stub _vprintf_p +@ stub _vprintf_p_l +@ stub _vprintf_s_l +@ cdecl _vscprintf(str ptr) MSVCRT__vscprintf +@ stub _vscprintf_l +@ stub _vscprintf_p +@ stub _vscprintf_p_l +@ cdecl _vscwprintf(wstr ptr) MSVCRT__vscwprintf +@ cdecl _vscwprintf_l(wstr ptr ptr) MSVCRT__vscwprintf_l +@ cdecl _vscwprintf_p(wstr ptr) MSVCRT__vscwprintf_p +@ cdecl _vscwprintf_p_l(wstr ptr ptr) MSVCRT__vscwprintf_p_l +@ cdecl _vsnprintf(ptr long str ptr) MSVCRT_vsnprintf +@ cdecl _vsnprintf_c(ptr long str ptr) MSVCRT_vsnprintf +@ cdecl _vsnprintf_c_l(ptr long str ptr ptr) MSVCRT_vsnprintf_l +@ cdecl _vsnprintf_l(ptr long str ptr ptr) MSVCRT_vsnprintf_l +@ cdecl _vsnprintf_s(ptr long long str ptr) MSVCRT_vsnprintf_s +@ cdecl _vsnprintf_s_l(ptr long long str ptr ptr) MSVCRT_vsnprintf_s_l +@ cdecl _vsnwprintf(ptr long wstr ptr) MSVCRT_vsnwprintf +@ cdecl _vsnwprintf_l(ptr long wstr ptr ptr) MSVCRT_vsnwprintf_l +@ cdecl _vsnwprintf_s(ptr long long wstr ptr) MSVCRT_vsnwprintf_s +@ cdecl _vsnwprintf_s_l(ptr long long wstr ptr ptr) MSVCRT_vsnwprintf_s_l +@ cdecl _vsprintf_l(ptr str ptr ptr) MSVCRT_vsprintf_l +@ cdecl _vsprintf_p(ptr long str ptr) MSVCRT_vsprintf_p +@ cdecl _vsprintf_p_l(ptr long str ptr ptr) MSVCRT_vsprintf_p_l +@ cdecl _vsprintf_s_l(ptr long str ptr ptr) MSVCRT_vsprintf_s_l +@ cdecl _vswprintf(ptr wstr ptr) MSVCRT_vswprintf +@ cdecl _vswprintf_c(ptr long wstr ptr) MSVCRT_vsnwprintf +@ cdecl _vswprintf_c_l(ptr long wstr ptr ptr) MSVCRT_vsnwprintf_l +@ cdecl _vswprintf_l(ptr wstr ptr ptr) MSVCRT_vswprintf_l +@ cdecl _vswprintf_p(ptr long wstr ptr) MSVCRT__vswprintf_p +@ cdecl _vswprintf_p_l(ptr long wstr ptr ptr) MSVCRT_vswprintf_p_l +@ cdecl _vswprintf_s_l(ptr long wstr ptr ptr) MSVCRT_vswprintf_s_l +@ stub _vwprintf_l +@ stub _vwprintf_p +@ stub _vwprintf_p_l +@ stub _vwprintf_s_l +@ cdecl _waccess(wstr long) MSVCRT__waccess +@ cdecl _waccess_s(wstr long) MSVCRT__waccess_s +@ cdecl _wasctime(ptr) MSVCRT__wasctime +@ cdecl _wasctime_s(ptr long ptr) MSVCRT__wasctime_s +@ cdecl _wassert(wstr wstr long) MSVCRT__wassert +@ cdecl _wchdir(wstr) MSVCRT__wchdir +@ cdecl _wchmod(wstr long) MSVCRT__wchmod +@ extern _wcmdln MSVCRT__wcmdln +@ cdecl _wcreat(wstr long) MSVCRT__wcreat +@ stub _wcreate_locale +@ cdecl _wcscoll_l(wstr wstr ptr) MSVCRT__wcscoll_l +@ cdecl _wcsdup(wstr) MSVCRT__wcsdup +@ cdecl _wcserror(long) MSVCRT__wcserror +@ cdecl _wcserror_s(ptr long long) MSVCRT__wcserror_s +@ stub _wcsftime_l +@ cdecl _wcsicmp(wstr wstr) MSVCRT__wcsicmp +@ cdecl _wcsicmp_l(wstr wstr ptr) MSVCRT__wcsicmp_l +@ cdecl _wcsicoll(wstr wstr) MSVCRT__wcsicoll +@ cdecl _wcsicoll_l(wstr wstr ptr) MSVCRT__wcsicoll_l +@ cdecl _wcslwr(wstr) MSVCRT__wcslwr +@ cdecl _wcslwr_l(wstr ptr) MSVCRT__wcslwr_l +@ cdecl _wcslwr_s(wstr long) MSVCRT__wcslwr_s +@ cdecl _wcslwr_s_l(wstr long ptr) MSVCRT__wcslwr_s_l +@ cdecl _wcsncoll(wstr wstr long) MSVCRT__wcsncoll +@ cdecl _wcsncoll_l(wstr wstr long ptr) MSVCRT__wcsncoll_l +@ cdecl _wcsnicmp(wstr wstr long) MSVCRT__wcsnicmp +@ cdecl _wcsnicmp_l(wstr wstr long ptr) MSVCRT__wcsnicmp_l +@ cdecl _wcsnicoll(wstr wstr long) MSVCRT__wcsnicoll +@ cdecl _wcsnicoll_l(wstr wstr long ptr) MSVCRT__wcsnicoll_l +@ cdecl _wcsnset(wstr long long) MSVCRT__wcsnset +@ stub _wcsnset_s +@ cdecl _wcsrev(wstr) MSVCRT__wcsrev +@ cdecl _wcsset(wstr long) MSVCRT__wcsset +@ stub _wcsset_s +@ cdecl _wcstod_l(wstr ptr) MSVCRT__wcstod_l +@ stub _wcstof_l +@ cdecl -ret64 _wcstoi64(wstr ptr long) MSVCRT__wcstoi64 +@ cdecl -ret64 _wcstoi64_l(wstr ptr long ptr) MSVCRT__wcstoi64_l +@ stub _wcstoimax_l +@ cdecl _wcstol_l(wstr ptr long ptr) MSVCRT__wcstol_l +@ stub _wcstold_l +@ stub _wcstoll_l +@ cdecl _wcstombs_l(ptr ptr long ptr) MSVCRT__wcstombs_l +@ cdecl _wcstombs_s_l(ptr ptr long wstr long ptr) MSVCRT__wcstombs_s_l +@ cdecl -ret64 _wcstoui64(wstr ptr long) MSVCRT__wcstoui64 +@ cdecl -ret64 _wcstoui64_l(wstr ptr long ptr) MSVCRT__wcstoui64_l +@ cdecl _wcstoul_l(wstr ptr long ptr) MSVCRT__wcstoul_l +@ stub _wcstoull_l +@ stub _wcstoumax_l +@ cdecl _wcsupr(wstr) ntdll._wcsupr +@ cdecl _wcsupr_l(wstr ptr) MSVCRT__wcsupr_l +@ cdecl _wcsupr_s(wstr long) MSVCRT__wcsupr_s +@ cdecl _wcsupr_s_l(wstr long ptr) MSVCRT__wcsupr_s_l +@ cdecl _wcsxfrm_l(ptr wstr long ptr) MSVCRT__wcsxfrm_l +@ cdecl _wctime32(ptr) MSVCRT__wctime32 +@ stub _wctime32_s +@ cdecl _wctime64(ptr) MSVCRT__wctime64 +@ stub _wctime64_s +@ cdecl _wctomb_l(ptr long ptr) MSVCRT__wctomb_l +@ cdecl _wctomb_s_l(ptr ptr long long ptr) MSVCRT__wctomb_s_l +# extern _wctype +@ cdecl _wdupenv_s(ptr ptr wstr) +@ extern _wenviron MSVCRT__wenviron +@ varargs _wexecl(wstr wstr) +@ varargs _wexecle(wstr wstr) +@ varargs _wexeclp(wstr wstr) +@ varargs _wexeclpe(wstr wstr) +@ cdecl _wexecv(wstr ptr) +@ cdecl _wexecve(wstr ptr ptr) +@ cdecl _wexecvp(wstr ptr) +@ cdecl _wexecvpe(wstr ptr ptr) +@ cdecl _wfdopen(long wstr) MSVCRT__wfdopen +@ cdecl _wfindfirst32(wstr ptr) MSVCRT__wfindfirst32 +@ stub _wfindfirst32i64 +@ cdecl _wfindfirst64(wstr ptr) MSVCRT__wfindfirst64 +@ cdecl _wfindfirst64i32(wstr ptr) MSVCRT__wfindfirst64i32 +@ stub _wfindnext32 +@ stub _wfindnext32i64 +@ cdecl _wfindnext64(long ptr) MSVCRT__wfindnext64 +@ cdecl _wfindnext64i32(long ptr) MSVCRT__wfindnext64i32 +@ cdecl _wfopen(wstr wstr) MSVCRT__wfopen +@ cdecl _wfopen_s(ptr wstr wstr) MSVCRT__wfopen_s +@ cdecl _wfreopen(wstr wstr ptr) MSVCRT__wfreopen +@ cdecl _wfreopen_s(ptr wstr wstr ptr) MSVCRT__wfreopen_s +@ cdecl _wfsopen(wstr wstr long) MSVCRT__wfsopen +@ cdecl _wfullpath(ptr wstr long) MSVCRT__wfullpath +@ cdecl _wgetcwd(wstr long) MSVCRT__wgetcwd +@ cdecl _wgetdcwd(long wstr long) MSVCRT__wgetdcwd +@ cdecl _wgetenv(wstr) MSVCRT__wgetenv +@ cdecl _wgetenv_s(ptr ptr long wstr) +@ cdecl _wmakepath(ptr wstr wstr wstr wstr) MSVCRT__wmakepath +@ cdecl _wmakepath_s(ptr long wstr wstr wstr wstr) MSVCRT__wmakepath_s +@ cdecl _wmkdir(wstr) MSVCRT__wmkdir +@ cdecl _wmktemp(wstr) MSVCRT__wmktemp +@ cdecl _wmktemp_s(wstr long) MSVCRT__wmktemp_s +@ varargs _wopen(wstr long) MSVCRT__wopen +@ stub _wperror(wstr) +@ extern _wpgmptr MSVCRT__wpgmptr +@ cdecl _wpopen(wstr wstr) MSVCRT__wpopen +@ stub _wprintf_l +@ stub _wprintf_p +@ stub _wprintf_p_l +@ stub _wprintf_s_l +@ cdecl _wputenv(wstr) +@ cdecl _wputenv_s(wstr wstr) +@ cdecl _wremove(wstr) MSVCRT__wremove +@ cdecl _wrename(wstr wstr) MSVCRT__wrename +@ cdecl _write(long ptr long) MSVCRT__write +@ cdecl _wrmdir(wstr) MSVCRT__wrmdir +@ varargs _wscanf_l(wstr ptr) MSVCRT__wscanf_l +@ varargs _wscanf_s_l(wstr ptr) MSVCRT__wscanf_s_l +@ cdecl _wsearchenv(wstr wstr ptr) MSVCRT__wsearchenv +@ cdecl _wsearchenv_s(wstr wstr ptr long) MSVCRT__wsearchenv_s +@ cdecl _wsetlocale(long wstr) MSVCRT__wsetlocale +@ varargs _wsopen(wstr long long) MSVCRT__wsopen +@ cdecl _wsopen_s(ptr wstr long long long) MSVCRT__wsopen_s +@ varargs _wspawnl(long wstr wstr) +@ varargs _wspawnle(long wstr wstr) +@ varargs _wspawnlp(long wstr wstr) +@ varargs _wspawnlpe(long wstr wstr) +@ cdecl _wspawnv(long wstr ptr) +@ cdecl _wspawnve(long wstr ptr ptr) MSVCRT__wspawnve +@ cdecl _wspawnvp(long wstr ptr) +@ cdecl _wspawnvpe(long wstr ptr ptr) MSVCRT__wspawnvpe +@ cdecl _wsplitpath(wstr ptr ptr ptr ptr) MSVCRT__wsplitpath +@ cdecl _wsplitpath_s(wstr ptr long ptr long ptr long ptr long) MSVCRT__wsplitpath_s +@ cdecl _wstat32(wstr ptr) MSVCRT__wstat32 +@ cdecl _wstat32i64(wstr ptr) MSVCRT__wstat32i64 +@ cdecl _wstat64(wstr ptr) MSVCRT__wstat64 +@ cdecl _wstat64i32(wstr ptr) MSVCRT__wstat64i32 +@ cdecl _wstrdate(ptr) MSVCRT__wstrdate +@ cdecl _wstrdate_s(ptr long) +@ cdecl _wstrtime(ptr) MSVCRT__wstrtime +@ cdecl _wstrtime_s(ptr long) +@ cdecl _wsystem(wstr) +@ cdecl _wtempnam(wstr wstr) MSVCRT__wtempnam +@ cdecl _wtmpnam(ptr) MSVCRT_wtmpnam +@ stub _wtmpnam_s +@ cdecl _wtof(wstr) MSVCRT__wtof +@ cdecl _wtof_l(wstr ptr) MSVCRT__wtof_l +@ cdecl _wtoi(wstr) MSVCRT__wtoi +@ cdecl -ret64 _wtoi64(wstr) MSVCRT__wtoi64 +@ cdecl -ret64 _wtoi64_l(wstr ptr) MSVCRT__wtoi64_l +@ cdecl _wtoi_l(wstr ptr) MSVCRT__wtoi_l +@ cdecl _wtol(wstr) MSVCRT__wtol +@ cdecl _wtol_l(wstr ptr) MSVCRT__wtol_l +@ stub _wtoll +@ stub _wtoll_l +@ cdecl _wunlink(wstr) MSVCRT__wunlink +@ cdecl _wutime32(wstr ptr) +@ cdecl _wutime64(wstr ptr) +@ cdecl _y0(double) MSVCRT__y0 +@ cdecl _y1(double) MSVCRT__y1 +@ cdecl _yn(long double) MSVCRT__yn +@ cdecl abort() MSVCRT_abort +@ cdecl abs(long) MSVCRT_abs +@ cdecl acos(double) MSVCRT_acos +@ cdecl -arch=arm,x86_64 acosf(float) MSVCRT_acosf +@ stub acosh +@ stub acoshf +@ stub acoshl +@ cdecl asctime(ptr) MSVCRT_asctime +@ cdecl asctime_s(ptr long ptr) MSVCRT_asctime_s +@ cdecl asin(double) MSVCRT_asin +@ cdecl -arch=arm,x86_64 asinf(float) MSVCRT_asinf +@ stub asinh +@ stub asinhf +@ stub asinhl +@ cdecl atan(double) MSVCRT_atan +@ cdecl -arch=arm,x86_64 atanf(float) MSVCRT_atanf +@ cdecl atan2(double double) MSVCRT_atan2 +@ cdecl -arch=arm,x86_64 atan2f(float float) MSVCRT_atan2f +@ stub atanh +@ stub atanhf +@ stub atanhl +@ cdecl atexit(ptr) MSVCRT_atexit +@ cdecl atof(str) MSVCRT_atof +@ cdecl atoi(str) MSVCRT_atoi +@ cdecl atol(str) ntdll.atol +@ stub atoll +@ cdecl bsearch(ptr ptr long long ptr) MSVCRT_bsearch +@ cdecl bsearch_s(ptr ptr long long ptr ptr) MSVCRT_bsearch_s +@ cdecl btowc(long) MSVCRT_btowc +@ stub cabs +@ stub cabsf +@ stub cabsl +@ stub cacos +@ stub cacosf +@ stub cacosh +@ stub cacoshf +@ stub cacoshl +@ stub cacosl +@ cdecl calloc(long long) MSVCRT_calloc +@ stub carg +@ stub cargf +@ stub cargl +@ stub casin +@ stub casinf +@ stub casinh +@ stub casinhf +@ stub casinhl +@ stub casinl +@ stub catan +@ stub catanf +@ stub catanh +@ stub catanhf +@ stub catanhl +@ stub catanl +@ stub cbrt +@ stub cbrtf +@ stub cbrtl +@ stub ccos +@ stub ccosf +@ stub ccosh +@ stub ccoshf +@ stub ccoshl +@ stub ccosl +@ cdecl ceil(double) MSVCRT_ceil +@ cdecl -arch=arm,x86_64 ceilf(float) MSVCRT_ceilf +@ stub cexp +@ stub cexpf +@ stub cexpl +@ stub cimag +@ stub cimagf +@ stub cimagl +@ cdecl clearerr(ptr) MSVCRT_clearerr +@ stub clearerr_s +@ cdecl clock() MSVCRT_clock +@ stub clog +@ stub clog10 +@ stub clog10f +@ stub clog10l +@ stub clogf +@ stub clogl +@ stub conj +@ stub conjf +@ stub conjl +@ stub copysign +@ stub copysignf +@ stub copysignl +@ cdecl cos(double) MSVCRT_cos +@ cdecl -arch=arm,x86_64 cosf(float) MSVCRT_cosf +@ cdecl cosh(double) MSVCRT_cosh +@ cdecl -arch=arm,x86_64 coshf(float) MSVCRT_coshf +@ stub cpow +@ stub cpowf +@ stub cpowl +@ stub cproj +@ stub cprojf +@ stub cprojl +@ stub creal +@ stub crealf +@ stub creall +@ stub csin +@ stub csinf +@ stub csinh +@ stub csinhf +@ stub csinhl +@ stub csinl +@ stub csqrt +@ stub csqrtf +@ stub csqrtl +@ stub ctan +@ stub ctanf +@ stub ctanh +@ stub ctanhf +@ stub ctanhl +@ stub ctanl +@ cdecl -ret64 div(long long) MSVCRT_div +@ stub erf +@ stub erfc +@ stub erfcf +@ stub erfcl +@ stub erff +@ stub erfl +@ cdecl exit(long) MSVCRT_exit +@ cdecl exp(double) MSVCRT_exp +@ stub exp2 +@ stub exp2f +@ stub exp2l +@ cdecl -arch=arm,x86_64 expf(float) MSVCRT_expf +@ stub expm1 +@ stub expm1f +@ stub expm1l +@ cdecl fabs(double) MSVCRT_fabs +@ cdecl -arch=arm,x86_64 fabsf(float) MSVCRT_fabsf +@ cdecl fclose(ptr) MSVCRT_fclose +@ stub fdim +@ stub fdimf +@ stub fdiml +@ stub feclearexcept +@ stub fegetenv +@ stub fegetexceptflag +@ stub fegetround +@ stub feholdexcept +@ cdecl feof(ptr) MSVCRT_feof +@ stub feraiseexcept +@ cdecl ferror(ptr) MSVCRT_ferror +@ stub fesetenv +@ stub fesetexceptflag +@ stub fesetround +@ stub fetestexcept +@ stub feupdateenv +@ cdecl fflush(ptr) MSVCRT_fflush +@ cdecl fgetc(ptr) MSVCRT_fgetc +@ cdecl fgetpos(ptr ptr) MSVCRT_fgetpos +@ cdecl fgets(ptr long ptr) MSVCRT_fgets +@ cdecl fgetwc(ptr) MSVCRT_fgetwc +@ cdecl fgetws(ptr long ptr) MSVCRT_fgetws +@ cdecl floor(double) MSVCRT_floor +@ cdecl -arch=arm,x86_64 floorf(float) MSVCRT_floorf +@ stub fma +@ stub fmaf +@ stub fmal +@ stub fmax +@ stub fmaxf +@ stub fmaxl +@ stub fmin +@ stub fminf +@ stub fminl +@ cdecl fmod(double double) MSVCRT_fmod +@ cdecl -arch=arm,x86_64 fmodf(float float) MSVCRT_fmodf +@ cdecl fopen(str str) MSVCRT_fopen +@ cdecl fopen_s(ptr str str) MSVCRT_fopen_s +@ varargs fprintf(ptr str) MSVCRT_fprintf +@ varargs fprintf_s(ptr str) MSVCRT_fprintf_s +@ cdecl fputc(long ptr) MSVCRT_fputc +@ cdecl fputs(str ptr) MSVCRT_fputs +@ cdecl fputwc(long ptr) MSVCRT_fputwc +@ cdecl fputws(wstr ptr) MSVCRT_fputws +@ cdecl fread(ptr long long ptr) MSVCRT_fread +@ cdecl fread_s(ptr long long long ptr) MSVCRT_fread_s +@ cdecl free(ptr) MSVCRT_free +@ cdecl freopen(str str ptr) MSVCRT_freopen +@ cdecl freopen_s(ptr str str ptr) MSVCRT_freopen_s +@ cdecl frexp(double ptr) MSVCRT_frexp +@ varargs fscanf(ptr str) MSVCRT_fscanf +@ varargs fscanf_s(ptr str) MSVCRT_fscanf_s +@ cdecl fseek(ptr long long) MSVCRT_fseek +@ cdecl fsetpos(ptr ptr) MSVCRT_fsetpos +@ cdecl ftell(ptr) MSVCRT_ftell +@ varargs fwprintf(ptr wstr) MSVCRT_fwprintf +@ varargs fwprintf_s(ptr wstr) MSVCRT_fwprintf_s +@ cdecl fwrite(ptr long long ptr) MSVCRT_fwrite +@ varargs fwscanf(ptr wstr) MSVCRT_fwscanf +@ varargs fwscanf_s(ptr wstr) MSVCRT_fwscanf_s +@ cdecl getc(ptr) MSVCRT_getc +@ cdecl getchar() MSVCRT_getchar +@ cdecl getenv(str) MSVCRT_getenv +@ cdecl getenv_s(ptr ptr long str) +@ cdecl gets(str) MSVCRT_gets +@ stub gets_s +@ cdecl getwc(ptr) MSVCRT_getwc +@ cdecl getwchar() MSVCRT_getwchar +@ stub ilogb +@ stub ilogbf +@ stub ilogbl +@ stub imaxabs +@ stub imaxdiv +@ cdecl is_wctype(long long) ntdll.iswctype +@ cdecl isalnum(long) MSVCRT_isalnum +@ cdecl isalpha(long) MSVCRT_isalpha +@ stub isblank +@ cdecl iscntrl(long) MSVCRT_iscntrl +@ cdecl isdigit(long) MSVCRT_isdigit +@ cdecl isgraph(long) MSVCRT_isgraph +@ cdecl isleadbyte(long) MSVCRT_isleadbyte +@ cdecl islower(long) MSVCRT_islower +@ cdecl isprint(long) MSVCRT_isprint +@ cdecl ispunct(long) MSVCRT_ispunct +@ cdecl isspace(long) MSVCRT_isspace +@ cdecl isupper(long) MSVCRT_isupper +@ cdecl iswalnum(long) MSVCRT_iswalnum +@ cdecl iswalpha(long) ntdll.iswalpha +@ cdecl iswascii(long) MSVCRT_iswascii +@ stub iswblank +@ cdecl iswcntrl(long) MSVCRT_iswcntrl +@ cdecl iswctype(long long) ntdll.iswctype +@ cdecl iswdigit(long) MSVCRT_iswdigit +@ cdecl iswgraph(long) MSVCRT_iswgraph +@ cdecl iswlower(long) MSVCRT_iswlower +@ cdecl iswprint(long) MSVCRT_iswprint +@ cdecl iswpunct(long) MSVCRT_iswpunct +@ cdecl iswspace(long) MSVCRT_iswspace +@ cdecl iswupper(long) MSVCRT_iswupper +@ cdecl iswxdigit(long) MSVCRT_iswxdigit +@ cdecl isxdigit(long) MSVCRT_isxdigit +@ cdecl labs(long) MSVCRT_labs +@ cdecl ldexp(double long) MSVCRT_ldexp +@ cdecl ldiv(long long) MSVCRT_ldiv +@ stub lgamma +@ stub lgammaf +@ stub lgammal +@ cdecl -ret64 llabs(int64) MSVCRT_llabs +@ stub lldiv +@ stub llrint +@ stub llrintf +@ stub llrintl +@ stub llround +@ stub llroundf +@ stub llroundl +@ cdecl localeconv() MSVCRT_localeconv +@ cdecl log(double) MSVCRT_log +@ cdecl -arch=arm,x86_64 logf(float) MSVCRT_logf +@ cdecl log10(double) MSVCRT_log10 +@ cdecl -arch=arm,x86_64 log10f(float) MSVCRT_log10f +@ stub log1p +@ stub log1pf +@ stub log1pl +@ stub log2 +@ stub log2f +@ stub log2l +@ stub logb +@ stub logbf +@ stub logbl +@ cdecl -arch=i386,x86_64,arm longjmp(ptr long) MSVCRT_longjmp +@ stub lrint +@ stub lrintf +@ stub lrintl +@ stub lround +@ stub lroundf +@ stub lroundl +@ cdecl malloc(long) MSVCRT_malloc +@ cdecl mblen(ptr long) MSVCRT_mblen +@ cdecl mbrlen(ptr long ptr) MSVCRT_mbrlen +@ cdecl mbrtowc(ptr str long ptr) MSVCRT_mbrtowc +@ cdecl mbsrtowcs(ptr ptr long ptr) MSVCRT_mbsrtowcs +@ stub mbsrtowcs_s +@ cdecl mbstowcs(ptr str long) MSVCRT_mbstowcs +@ cdecl mbstowcs_s(ptr ptr long str long) MSVCRT__mbstowcs_s +@ cdecl mbtowc(ptr str long) MSVCRT_mbtowc +@ cdecl memchr(ptr long long) MSVCRT_memchr +@ cdecl memcmp(ptr ptr long) MSVCRT_memcmp +@ cdecl memcpy(ptr ptr long) MSVCRT_memcpy +@ cdecl memcpy_s(ptr long ptr long) MSVCRT_memcpy_s +@ cdecl memmove(ptr ptr long) MSVCRT_memmove +@ cdecl memmove_s(ptr long ptr long) MSVCRT_memmove_s +@ cdecl memset(ptr long long) MSVCRT_memset +@ cdecl modf(double ptr) MSVCRT_modf +@ cdecl -arch=arm,x86_64 modff(float ptr) MSVCRT_modff +@ stub nan +@ stub nanf +@ stub nanl +@ stub nearbyint +@ stub nearbyintf +@ stub nearbyintl +@ stub nextafter +@ stub nextafterf +@ stub nextafterl +@ stub nexttoward +@ stub nexttowardf +@ stub nexttowardl +@ stub norm +@ stub normf +@ stub norml +@ cdecl perror(str) MSVCRT_perror +@ cdecl pow(double double) MSVCRT_pow +@ cdecl -arch=arm,x86_64 powf(float float) MSVCRT_powf +@ varargs printf(str) MSVCRT_printf +@ varargs printf_s(str) MSVCRT_printf_s +@ cdecl putc(long ptr) MSVCRT_putc +@ cdecl putchar(long) MSVCRT_putchar +@ cdecl puts(str) MSVCRT_puts +@ cdecl putwc(long ptr) MSVCRT_fputwc +@ cdecl putwchar(long) MSVCRT__fputwchar +@ cdecl qsort(ptr long long ptr) MSVCRT_qsort +@ cdecl qsort_s(ptr long long ptr ptr) MSVCRT_qsort_s +@ cdecl raise(long) MSVCRT_raise +@ cdecl rand() MSVCRT_rand +@ cdecl rand_s(ptr) MSVCRT_rand_s +@ cdecl realloc(ptr long) MSVCRT_realloc +@ stub remainder +@ stub remainderf +@ stub remainderl +@ cdecl remove(str) MSVCRT_remove +@ stub remquo +@ stub remquof +@ stub remquol +@ cdecl rename(str str) MSVCRT_rename +@ cdecl rewind(ptr) MSVCRT_rewind +@ stub rint +@ stub rintf +@ stub rintl +@ stub round +@ stub roundf +@ stub roundl +@ stub scalbln +@ stub scalblnf +@ stub scalblnl +@ stub scalbn +@ stub scalbnf +@ stub scalbnl +@ varargs scanf(str) MSVCRT_scanf +@ varargs scanf_s(str) MSVCRT_scanf_s +@ cdecl setbuf(ptr ptr) MSVCRT_setbuf +@ cdecl -arch=arm,x86_64 -norelay -private setjmp(ptr) MSVCRT__setjmp +@ cdecl setlocale(long str) MSVCRT_setlocale +@ cdecl setvbuf(ptr str long long) MSVCRT_setvbuf +@ cdecl signal(long long) MSVCRT_signal +@ cdecl sin(double) MSVCRT_sin +@ cdecl -arch=arm,x86_64 sinf(float) MSVCRT_sinf +@ cdecl sinh(double) MSVCRT_sinh +@ cdecl -arch=arm,x86_64 sinhf(float) MSVCRT_sinhf +@ varargs sprintf(ptr str) MSVCRT_sprintf +@ varargs sprintf_s(ptr long str) MSVCRT_sprintf_s +@ cdecl sqrt(double) MSVCRT_sqrt +@ cdecl -arch=arm,x86_64 sqrtf(float) MSVCRT_sqrtf +@ cdecl srand(long) MSVCRT_srand +@ varargs sscanf(str str) MSVCRT_sscanf +@ varargs sscanf_s(str str) MSVCRT_sscanf_s +@ cdecl strcat(str str) ntdll.strcat +@ cdecl strcat_s(str long str) MSVCRT_strcat_s +@ cdecl strchr(str long) MSVCRT_strchr +@ cdecl strcmp(str str) MSVCRT_strcmp +@ cdecl strcoll(str str) MSVCRT_strcoll +@ cdecl strcpy(ptr str) ntdll.strcpy +@ cdecl strcpy_s(ptr long str) MSVCRT_strcpy_s +@ cdecl strcspn(str str) ntdll.strcspn +@ cdecl strerror(long) MSVCRT_strerror +@ cdecl strerror_s(ptr long long) MSVCRT_strerror_s +@ cdecl strftime(str long str ptr) MSVCRT_strftime +@ cdecl strlen(str) MSVCRT_strlen +@ cdecl strncat(str str long) MSVCRT_strncat +@ cdecl strncat_s(str long str long) MSVCRT_strncat_s +@ cdecl strncmp(str str long) MSVCRT_strncmp +@ cdecl strncpy(ptr str long) MSVCRT_strncpy +@ cdecl strncpy_s(ptr long str long) MSVCRT_strncpy_s +@ cdecl strnlen(str long) MSVCRT_strnlen +@ cdecl strpbrk(str str) ntdll.strpbrk +@ cdecl strrchr(str long) MSVCRT_strrchr +@ cdecl strspn(str str) ntdll.strspn +@ cdecl strstr(str str) MSVCRT_strstr +@ cdecl strtod(str ptr) MSVCRT_strtod +@ stub strtof +@ stub strtoimax +@ cdecl strtok(str str) MSVCRT_strtok +@ cdecl strtok_s(ptr str ptr) MSVCRT_strtok_s +@ cdecl strtol(str ptr long) MSVCRT_strtol +@ stub strtold +@ stub strtoll +@ cdecl strtoul(str ptr long) MSVCRT_strtoul +@ stub strtoull +@ stub strtoumax +@ cdecl strxfrm(ptr str long) MSVCRT_strxfrm +@ varargs swprintf_s(ptr long wstr) MSVCRT_swprintf_s +@ varargs swscanf(wstr wstr) MSVCRT_swscanf +@ varargs swscanf_s(wstr wstr) MSVCRT_swscanf_s +@ cdecl system(str) MSVCRT_system +@ cdecl tan(double) MSVCRT_tan +@ cdecl -arch=arm,x86_64 tanf(float) MSVCRT_tanf +@ cdecl tanh(double) MSVCRT_tanh +@ cdecl -arch=arm,x86_64 tanhf(float) MSVCRT_tanhf +@ stub tgamma +@ stub tgammaf +@ stub tgammal +@ cdecl tmpfile() MSVCRT_tmpfile +@ cdecl tmpfile_s(ptr) MSVCRT_tmpfile_s +@ cdecl tmpnam(ptr) MSVCRT_tmpnam +@ stub tmpnam_s +@ cdecl tolower(long) MSVCRT_tolower +@ cdecl toupper(long) MSVCRT_toupper +@ stub towctrans +@ cdecl towlower(long) MSVCRT_towlower +@ cdecl towupper(long) MSVCRT_towupper +@ stub trunc +@ stub truncf +@ stub truncl +@ cdecl ungetc(long ptr) MSVCRT_ungetc +@ cdecl ungetwc(long ptr) MSVCRT_ungetwc +@ cdecl vfprintf(ptr str ptr) MSVCRT_vfprintf +@ cdecl vfprintf_s(ptr str ptr) MSVCRT_vfprintf_s +@ stub vfscanf +@ stub vfscanf_s +@ cdecl vfwprintf(ptr wstr ptr) MSVCRT_vfwprintf +@ cdecl vfwprintf_s(ptr wstr ptr) MSVCRT_vfwprintf_s +@ stub vfwscanf +@ stub vfwscanf_s +@ cdecl vprintf(str ptr) MSVCRT_vprintf +@ cdecl vprintf_s(str ptr) MSVCRT_vprintf_s +@ stub vscanf +@ stub vscanf_s +@ cdecl vsprintf(ptr str ptr) MSVCRT_vsprintf +@ cdecl vsprintf_s(ptr long str ptr) MSVCRT_vsprintf_s +@ stub vsscanf +@ stub vsscanf_s +@ cdecl vswprintf_s(ptr long wstr ptr) MSVCRT_vswprintf_s +@ stub vswscanf +@ stub vswscanf_s +@ cdecl vwprintf(wstr ptr) MSVCRT_vwprintf +@ cdecl vwprintf_s(wstr ptr) MSVCRT_vwprintf_s +@ stub vwscanf +@ stub vwscanf_s +@ cdecl wcrtomb(ptr long ptr) MSVCRT_wcrtomb +@ stub wcrtomb_s +@ cdecl wcscat(wstr wstr) ntdll.wcscat +@ cdecl wcscat_s(wstr long wstr) MSVCRT_wcscat_s +@ cdecl wcschr(wstr long) MSVCRT_wcschr +@ cdecl wcscmp(wstr wstr) ntdll.wcscmp +@ cdecl wcscoll(wstr wstr) MSVCRT_wcscoll +@ cdecl wcscpy(ptr wstr) ntdll.wcscpy +@ cdecl wcscpy_s(ptr long wstr) MSVCRT_wcscpy_s +@ cdecl wcscspn(wstr wstr) ntdll.wcscspn +@ cdecl wcsftime(ptr long wstr ptr) MSVCRT_wcsftime +@ cdecl wcslen(wstr) MSVCRT_wcslen +@ cdecl wcsncat(wstr wstr long) ntdll.wcsncat +@ cdecl wcsncat_s(wstr long wstr long) MSVCRT_wcsncat_s +@ cdecl wcsncmp(wstr wstr long) MSVCRT_wcsncmp +@ cdecl wcsncpy(ptr wstr long) MSVCRT_wcsncpy +@ cdecl wcsncpy_s(ptr long wstr long) MSVCRT_wcsncpy_s +@ cdecl wcsnlen(wstr long) MSVCRT_wcsnlen +@ cdecl wcspbrk(wstr wstr) MSVCRT_wcspbrk +@ cdecl wcsrchr(wstr long) ntdll.wcsrchr +@ cdecl wcsrtombs(ptr ptr long ptr) MSVCRT_wcsrtombs +@ cdecl wcsrtombs_s(ptr ptr long ptr long ptr) MSVCRT_wcsrtombs_s +@ cdecl wcsspn(wstr wstr) ntdll.wcsspn +@ cdecl wcsstr(wstr wstr) MSVCRT_wcsstr +@ cdecl wcstod(wstr ptr) MSVCRT_wcstod +@ stub wcstof +@ stub wcstoimax +@ cdecl wcstok(wstr wstr) MSVCRT_wcstok +@ cdecl wcstok_s(ptr wstr ptr) MSVCRT_wcstok_s +@ cdecl wcstol(wstr ptr long) ntdll.wcstol +@ stub wcstold +@ stub wcstoll +@ cdecl wcstombs(ptr ptr long) MSVCRT_wcstombs +@ cdecl wcstombs_s(ptr ptr long wstr long) MSVCRT_wcstombs_s +@ cdecl wcstoul(wstr ptr long) MSVCRT_wcstoul +@ stub wcstoull +@ stub wcstoumax +@ cdecl wcsxfrm(ptr wstr long) MSVCRT_wcsxfrm +@ cdecl wctob(long) MSVCRT_wctob +@ cdecl wctomb(ptr long) MSVCRT_wctomb +@ cdecl wctomb_s(ptr ptr long long) MSVCRT_wctomb_s +@ stub wctrans +@ stub wctype +@ cdecl wmemcpy_s(ptr long ptr long) +@ cdecl wmemmove_s(ptr long ptr long) +@ varargs wprintf(wstr) MSVCRT_wprintf +@ varargs wprintf_s(wstr) MSVCRT_wprintf_s +@ varargs wscanf(wstr) MSVCRT_wscanf +@ varargs wscanf_s(wstr) MSVCRT_wscanf_s diff -Nru wine1.7-1.7.28/dlls/msvcr80/msvcr80.spec wine1.7-1.7.31/dlls/msvcr80/msvcr80.spec --- wine1.7-1.7.28/dlls/msvcr80/msvcr80.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcr80/msvcr80.spec 2014-11-14 13:28:17.000000000 +0000 @@ -461,14 +461,15 @@ @ cdecl _execvpe(str ptr ptr) @ cdecl _exit(long) MSVCRT__exit @ cdecl _expand(ptr long) -@ stub _fclose_nolock +@ cdecl _fclose_nolock(ptr) MSVCRT__fclose_nolock @ cdecl _fcloseall() MSVCRT__fcloseall @ cdecl _fcvt(double long ptr ptr) MSVCRT__fcvt @ cdecl _fcvt_s(ptr long double long ptr ptr) MSVCRT__fcvt_s @ cdecl _fdopen(long str) MSVCRT__fdopen -@ stub _fflush_nolock +@ cdecl _fflush_nolock(ptr) MSVCRT__fflush_nolock +@ cdecl _fgetc_nolock(ptr) MSVCRT__fgetc_nolock @ cdecl _fgetchar() MSVCRT__fgetchar -@ stub _fgetwc_nolock +@ cdecl _fgetwc_nolock(ptr) MSVCRT__fgetwc_nolock @ cdecl _fgetwchar() MSVCRT__fgetwchar @ cdecl _filbuf(ptr) MSVCRT__filbuf @ cdecl _filelength(long) MSVCRT__filelength @@ -496,28 +497,29 @@ @ stub _fprintf_p @ stub _fprintf_p_l @ stub _fprintf_s_l +@ cdecl _fputc_nolock(long ptr) MSVCRT__fputc_nolock @ cdecl _fputchar(long) MSVCRT__fputchar -@ stub _fputwc_nolock +@ cdecl _fputwc_nolock(long ptr) MSVCRT__fputwc_nolock @ cdecl _fputwchar(long) MSVCRT__fputwchar -@ stub _fread_nolock -@ stub _fread_nolock_s +@ cdecl _fread_nolock(ptr long long ptr) MSVCRT__fread_nolock +@ cdecl _fread_nolock_s(ptr long long long ptr) MSVCRT__fread_nolock_s @ cdecl _free_locale(ptr) MSVCRT__free_locale @ stub _freea @ stub _freea_s @ stub _freefls @ varargs _fscanf_l(ptr str ptr) MSVCRT__fscanf_l @ varargs _fscanf_s_l(ptr str ptr) MSVCRT__fscanf_s_l -@ stub _fseek_nolock +@ cdecl _fseek_nolock(ptr long long) MSVCRT__fseek_nolock @ cdecl _fseeki64(ptr int64 long) MSVCRT__fseeki64 -@ stub _fseeki64_nolock +@ cdecl _fseeki64_nolock(ptr int64 long) MSVCRT__fseeki64_nolock @ cdecl _fsopen(str str long) MSVCRT__fsopen @ cdecl _fstat32(long ptr) MSVCRT__fstat32 @ stub _fstat32i64 @ cdecl _fstat64(long ptr) MSVCRT__fstat64 @ cdecl _fstat64i32(long ptr) MSVCRT__fstat64i32 -@ stub _ftell_nolock +@ cdecl _ftell_nolock(ptr) MSVCRT__ftell_nolock @ cdecl -ret64 _ftelli64(ptr) MSVCRT__ftelli64 -@ stub _ftelli64_nolock +@ cdecl -ret64 _ftelli64_nolock(ptr) MSVCRT__ftelli64_nolock @ cdecl _ftime32(ptr) MSVCRT__ftime32 @ cdecl _ftime32_s(ptr) MSVCRT__ftime32_s @ cdecl _ftime64(ptr) MSVCRT__ftime64 @@ -530,7 +532,7 @@ @ stub _fwprintf_p @ stub _fwprintf_p_l @ stub _fwprintf_s_l -@ stub _fwrite_nolock +@ cdecl _fwrite_nolock(ptr long long ptr) MSVCRT__fwrite_nolock @ varargs _fwscanf_l(ptr wstr ptr) MSVCRT__fwscanf_l @ varargs _fwscanf_s_l(ptr wstr ptr) MSVCRT__fwscanf_s_l @ cdecl _gcvt(double long str) MSVCRT__gcvt @@ -560,6 +562,7 @@ @ stub _get_winminor @ stub _get_winver @ cdecl _get_wpgmptr(ptr) +@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock @ cdecl _getch() @ stub _getch_nolock @ cdecl _getche() @@ -577,6 +580,7 @@ @ cdecl _getptd() @ stub _getsystime(ptr) @ cdecl _getw(ptr) MSVCRT__getw +@ cdecl _getwc_nolock(ptr) MSVCRT__fgetwc_nolock @ stub _getwch @ stub _getwch_nolock @ stub _getwche @@ -903,11 +907,13 @@ @ stub _printf_p_l @ stub _printf_s_l @ cdecl _purecall() +@ cdecl _putc_nolock(long ptr) MSVCRT__fputc_nolock @ cdecl _putch(long) @ stub _putch_nolock @ cdecl _putenv(str) @ cdecl _putenv_s(str str) @ cdecl _putw(long ptr) MSVCRT__putw +@ cdecl _putwc_nolock(long ptr) MSVCRT__fputwc_nolock @ cdecl _putwch(long) MSVCRT__putwch @ stub _putwch_nolock @ cdecl _putws(wstr) MSVCRT__putws @@ -969,7 +975,7 @@ @ varargs _snprintf(ptr long str) MSVCRT__snprintf @ stub _snprintf_c @ stub _snprintf_c_l -@ stub _snprintf_l +@ varargs _snprintf_l(ptr long str ptr) MSVCRT__snprintf_l @ varargs _snprintf_s(ptr long long str) MSVCRT__snprintf_s @ stub _snprintf_s_l @ varargs _snscanf(str long str) MSVCRT__snscanf @@ -1042,7 +1048,7 @@ @ stub _strtol_l @ cdecl -ret64 _strtoui64(str ptr long) MSVCRT_strtoui64 @ cdecl -ret64 _strtoui64_l(str ptr long ptr) MSVCRT_strtoui64_l -@ stub _strtoul_l +@ cdecl _strtoul_l(str ptr long ptr) MSVCRT_strtoul_l @ cdecl _strupr(str) MSVCRT__strupr @ cdecl _strupr_l(str ptr) MSVCRT__strupr_l @ cdecl _strupr_s(str long) MSVCRT__strupr_s @@ -1082,10 +1088,10 @@ @ cdecl _ultow_s(long ptr long long) MSVCRT__ultow_s @ cdecl _umask(long) MSVCRT__umask @ stub _umask_s -@ stub _ungetc_nolock +@ cdecl _ungetc_nolock(long ptr) MSVCRT__ungetc_nolock @ cdecl _ungetch(long) @ stub _ungetch_nolock -@ stub _ungetwc_nolock +@ cdecl _ungetwc_nolock(long ptr) MSVCRT__ungetwc_nolock @ stub _ungetwch @ stub _ungetwch_nolock @ cdecl _unlink(str) MSVCRT__unlink @@ -1176,7 +1182,7 @@ @ cdecl _wcsncoll(wstr wstr long) MSVCRT__wcsncoll @ cdecl _wcsncoll_l(wstr wstr long ptr) MSVCRT__wcsncoll_l @ cdecl _wcsnicmp(wstr wstr long) MSVCRT__wcsnicmp -@ stub _wcsnicmp_l +@ cdecl _wcsnicmp_l(wstr wstr long ptr) MSVCRT__wcsnicmp_l @ cdecl _wcsnicoll(wstr wstr long) MSVCRT__wcsnicoll @ cdecl _wcsnicoll_l(wstr wstr long ptr) MSVCRT__wcsnicoll_l @ cdecl _wcsnset(wstr long long) MSVCRT__wcsnset diff -Nru wine1.7-1.7.28/dlls/msvcr90/msvcr90.spec wine1.7-1.7.31/dlls/msvcr90/msvcr90.spec --- wine1.7-1.7.28/dlls/msvcr90/msvcr90.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcr90/msvcr90.spec 2014-11-14 13:28:17.000000000 +0000 @@ -443,14 +443,15 @@ @ cdecl _execvpe(str ptr ptr) @ cdecl _exit(long) MSVCRT__exit @ cdecl _expand(ptr long) -@ stub _fclose_nolock +@ cdecl _fclose_nolock(ptr) MSVCRT__fclose_nolock @ cdecl _fcloseall() MSVCRT__fcloseall @ cdecl _fcvt(double long ptr ptr) MSVCRT__fcvt @ cdecl _fcvt_s(ptr long double long ptr ptr) MSVCRT__fcvt_s @ cdecl _fdopen(long str) MSVCRT__fdopen -@ stub _fflush_nolock +@ cdecl _fflush_nolock(ptr) MSVCRT__fflush_nolock +@ cdecl _fgetc_nolock(ptr) MSVCRT__fgetc_nolock @ cdecl _fgetchar() MSVCRT__fgetchar -@ stub _fgetwc_nolock +@ cdecl _fgetwc_nolock(ptr) MSVCRT__fgetwc_nolock @ cdecl _fgetwchar() MSVCRT__fgetwchar @ cdecl _filbuf(ptr) MSVCRT__filbuf @ cdecl _filelength(long) MSVCRT__filelength @@ -478,28 +479,29 @@ @ stub _fprintf_p @ stub _fprintf_p_l @ stub _fprintf_s_l +@ cdecl _fputc_nolock(long ptr) MSVCRT__fputc_nolock @ cdecl _fputchar(long) MSVCRT__fputchar -@ stub _fputwc_nolock +@ cdecl _fputwc_nolock(long ptr) MSVCRT__fputwc_nolock @ cdecl _fputwchar(long) MSVCRT__fputwchar -@ stub _fread_nolock -@ stub _fread_nolock_s +@ cdecl _fread_nolock(ptr long long ptr) MSVCRT__fread_nolock +@ cdecl _fread_nolock_s(ptr long long long ptr) MSVCRT__fread_nolock_s @ cdecl _free_locale(ptr) MSVCRT__free_locale @ stub _freea @ stub _freea_s @ stub _freefls @ varargs _fscanf_l(ptr str ptr) MSVCRT__fscanf_l @ varargs _fscanf_s_l(ptr str ptr) MSVCRT__fscanf_s_l -@ stub _fseek_nolock +@ cdecl _fseek_nolock(ptr long long) MSVCRT__fseek_nolock @ cdecl _fseeki64(ptr int64 long) MSVCRT__fseeki64 -@ stub _fseeki64_nolock +@ cdecl _fseeki64_nolock(ptr int64 long) MSVCRT__fseeki64_nolock @ cdecl _fsopen(str str long) MSVCRT__fsopen @ cdecl _fstat32(long ptr) MSVCRT__fstat32 @ stub _fstat32i64 @ cdecl _fstat64(long ptr) MSVCRT__fstat64 @ cdecl _fstat64i32(long ptr) MSVCRT__fstat64i32 -@ stub _ftell_nolock +@ cdecl _ftell_nolock(ptr) MSVCRT__ftell_nolock @ cdecl -ret64 _ftelli64(ptr) MSVCRT__ftelli64 -@ stub _ftelli64_nolock +@ cdecl -ret64 _ftelli64_nolock(ptr) MSVCRT__ftelli64_nolock @ cdecl _ftime32(ptr) MSVCRT__ftime32 @ cdecl _ftime32_s(ptr) MSVCRT__ftime32_s @ cdecl _ftime64(ptr) MSVCRT__ftime64 @@ -512,7 +514,7 @@ @ stub _fwprintf_p @ stub _fwprintf_p_l @ stub _fwprintf_s_l -@ stub _fwrite_nolock +@ cdecl _fwrite_nolock(ptr long long ptr) MSVCRT__fwrite_nolock @ varargs _fwscanf_l(ptr wstr ptr) MSVCRT__fwscanf_l @ varargs _fwscanf_s_l(ptr wstr ptr) MSVCRT__fwscanf_s_l @ cdecl _gcvt(double long str) MSVCRT__gcvt @@ -537,7 +539,7 @@ @ cdecl _get_tzname(ptr str long long) MSVCRT__get_tzname @ cdecl _get_unexpected() MSVCRT__get_unexpected @ cdecl _get_wpgmptr(ptr) -@ stub _getc_nolock +@ cdecl _getc_nolock(ptr) MSVCRT__fgetc_nolock @ cdecl _getch() @ stub _getch_nolock @ cdecl _getche() @@ -555,6 +557,7 @@ @ cdecl _getptd() @ stub _getsystime(ptr) @ cdecl _getw(ptr) MSVCRT__getw +@ cdecl _getwc_nolock(ptr) MSVCRT__fgetwc_nolock @ stub _getwch @ stub _getwch_nolock @ stub _getwche @@ -879,11 +882,13 @@ @ stub _printf_p_l @ stub _printf_s_l @ cdecl _purecall() +@ cdecl _putc_nolock(long ptr) MSVCRT__fputc_nolock @ cdecl _putch(long) @ stub _putch_nolock @ cdecl _putenv(str) @ cdecl _putenv_s(str str) @ cdecl _putw(long ptr) MSVCRT__putw +@ cdecl _putwc_nolock(long ptr) MSVCRT__fputwc_nolock @ cdecl _putwch(long) MSVCRT__putwch @ stub _putwch_nolock @ cdecl _putws(wstr) MSVCRT__putws @@ -944,7 +949,7 @@ @ varargs _snprintf(ptr long str) MSVCRT__snprintf @ stub _snprintf_c @ stub _snprintf_c_l -@ stub _snprintf_l +@ varargs _snprintf_l(ptr long str ptr) MSVCRT__snprintf_l @ varargs _snprintf_s(ptr long long str) MSVCRT__snprintf_s @ stub _snprintf_s_l @ varargs _snscanf(str long str) MSVCRT__snscanf @@ -1017,7 +1022,7 @@ @ stub _strtol_l @ cdecl -ret64 _strtoui64(str ptr long) MSVCRT_strtoui64 @ cdecl -ret64 _strtoui64_l(str ptr long ptr) MSVCRT_strtoui64_l -@ stub _strtoul_l +@ cdecl _strtoul_l(str ptr long ptr) MSVCRT_strtoul_l @ cdecl _strupr(str) MSVCRT__strupr @ cdecl _strupr_l(str ptr) MSVCRT__strupr_l @ cdecl _strupr_s(str long) MSVCRT__strupr_s @@ -1058,10 +1063,10 @@ @ cdecl _ultow_s(long ptr long long) MSVCRT__ultow_s @ cdecl _umask(long) MSVCRT__umask @ stub _umask_s -@ stub _ungetc_nolock +@ cdecl _ungetc_nolock(long ptr) MSVCRT__ungetc_nolock @ cdecl _ungetch(long) @ stub _ungetch_nolock -@ stub _ungetwc_nolock +@ cdecl _ungetwc_nolock(long ptr) MSVCRT__ungetwc_nolock @ stub _ungetwch @ stub _ungetwch_nolock @ cdecl _unlink(str) MSVCRT__unlink @@ -1152,7 +1157,7 @@ @ cdecl _wcsncoll(wstr wstr long) MSVCRT__wcsncoll @ cdecl _wcsncoll_l(wstr wstr long ptr) MSVCRT__wcsncoll_l @ cdecl _wcsnicmp(wstr wstr long) MSVCRT__wcsnicmp -@ stub _wcsnicmp_l +@ cdecl _wcsnicmp_l(wstr wstr long ptr) MSVCRT__wcsnicmp_l @ cdecl _wcsnicoll(wstr wstr long) MSVCRT__wcsnicoll @ cdecl _wcsnicoll_l(wstr wstr long ptr) MSVCRT__wcsnicoll_l @ cdecl _wcsnset(wstr long long) MSVCRT__wcsnset diff -Nru wine1.7-1.7.28/dlls/msvcr90/tests/msvcr90.c wine1.7-1.7.31/dlls/msvcr90/tests/msvcr90.c --- wine1.7-1.7.28/dlls/msvcr90/tests/msvcr90.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcr90/tests/msvcr90.c 2014-11-14 13:28:17.000000000 +0000 @@ -118,9 +118,11 @@ static int (__cdecl *p_feof)(FILE*); static int (__cdecl *p_ferror)(FILE*); static int (__cdecl *p_flsbuf)(int, FILE*); +static int (__cdecl *p_filbuf)(FILE*); static unsigned long (__cdecl *p_byteswap_ulong)(unsigned long); static void** (__cdecl *p__pxcptinfoptrs)(void); static void* (__cdecl *p__AdjustPointer)(void*, const void*); +static int (__cdecl *p_fflush_nolock)(FILE*); /* make sure we use the correct errno */ #undef errno @@ -376,9 +378,11 @@ SET(p_feof, "feof"); SET(p_ferror, "ferror"); SET(p_flsbuf, "_flsbuf"); + SET(p_filbuf, "_filbuf"); SET(p_byteswap_ulong, "_byteswap_ulong"); SET(p__pxcptinfoptrs, "__pxcptinfoptrs"); SET(p__AdjustPointer, "__AdjustPointer"); + SET(p_fflush_nolock, "_fflush_nolock"); if (sizeof(void *) == 8) { SET(p_type_info_name_internal_method, "?_name_internal_method@type_info@@QEBAPEBDPEAU__type_info_node@@@Z"); @@ -1207,16 +1211,22 @@ FILE *write; HANDLE init; HANDLE finish; + int deadlock_test; }; static DWORD WINAPI block_file(void *arg) { struct block_file_arg *files = arg; + int deadlock_test; p_lock_file(files->read); p_lock_file(files->write); SetEvent(files->init); + WaitForSingleObject(files->finish, INFINITE); + Sleep(200); + deadlock_test = InterlockedIncrement(&files->deadlock_test); + ok(deadlock_test == 1, "deadlock_test = %d\n", deadlock_test); p_unlock_file(files->read); p_unlock_file(files->write); return 0; @@ -1250,6 +1260,7 @@ arg.write = filew; arg.init = CreateEventW(NULL, FALSE, FALSE, NULL); arg.finish = CreateEventW(NULL, FALSE, FALSE, NULL); + arg.deadlock_test = 0; ok(arg.init != NULL, "CreateEventW failed\n"); ok(arg.finish != NULL, "CreateEventW failed\n"); thread = CreateThread(NULL, 0, block_file, (void*)&arg, 0, NULL); @@ -1276,7 +1287,23 @@ ret = p_flsbuf('a', filew); ok(ret=='a', "_flsbuf(filew) returned %d\n", ret); + ret = p_filbuf(filer); + ok(ret==-1, "_filbuf(filer) returned %d\n", ret); + ret = p_filbuf(filew); + ok(ret==-1, "_filbuf(filew) returned %d\n", ret); + + ret = p_fflush_nolock(filer); + ok(ret==0, "_fflush_nolock(filer) returned %d\n", ret); + ret = p_fflush_nolock(filew); + ok(ret==0, "_fflush_nolock(filew) returned %d\n", ret); + SetEvent(arg.finish); + + ret = p_fflush_nolock(NULL); + ok(ret==0, "_fflush_nolock(NULL) returned %d\n", ret); + ret = InterlockedIncrement(&arg.deadlock_test); + ok(ret==2, "InterlockedIncrement returned %d\n", ret); + WaitForSingleObject(thread, INFINITE); CloseHandle(arg.init); CloseHandle(arg.finish); diff -Nru wine1.7-1.7.28/dlls/msvcrt/file.c wine1.7-1.7.31/dlls/msvcrt/file.c --- wine1.7-1.7.28/dlls/msvcrt/file.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcrt/file.c 2014-11-14 13:28:17.000000000 +0000 @@ -246,10 +246,10 @@ ft->dwLowDateTime = ticks; } -static inline ioinfo* msvcrt_get_ioinfo(int fd) +static inline ioinfo* get_ioinfo_nolock(int fd) { ioinfo *ret = NULL; - if(fd < MSVCRT_MAX_FILES) + if(fd>=0 && fdexflag & EF_CRIT_INIT) + EnterCriticalSection(&ret->crit); + return ret; +} + +static inline void release_ioinfo(ioinfo *info) +{ + if(info->exflag & EF_CRIT_INIT) + LeaveCriticalSection(&info->crit); +} + static inline MSVCRT_FILE* msvcrt_get_file(int i) { file_crit *ret; @@ -285,7 +299,7 @@ static inline BOOL msvcrt_is_valid_fd(int fd) { - return fd >= 0 && fd < MSVCRT_fdend && (msvcrt_get_ioinfo(fd)->wxflag & WX_OPEN); + return fd >= 0 && fd < MSVCRT_fdend && (get_ioinfo_nolock(fd)->wxflag & WX_OPEN); } /* INTERNAL: Get the HANDLE for a fd @@ -303,9 +317,9 @@ *MSVCRT__errno() = MSVCRT_EBADF; return INVALID_HANDLE_VALUE; } - if (msvcrt_get_ioinfo(fd)->handle == INVALID_HANDLE_VALUE) + if (get_ioinfo_nolock(fd)->handle == INVALID_HANDLE_VALUE) WARN("returning INVALID_HANDLE_VALUE for %d\n", fd); - return msvcrt_get_ioinfo(fd)->handle; + return get_ioinfo_nolock(fd)->handle; } /* INTERNAL: free a file entry fd */ @@ -314,7 +328,7 @@ ioinfo *fdinfo; LOCK_FILES(); - fdinfo = msvcrt_get_ioinfo(fd); + fdinfo = get_ioinfo_nolock(fd); if(fdinfo != &MSVCRT___badioinfo) { fdinfo->handle = INVALID_HANDLE_VALUE; @@ -358,7 +372,7 @@ return -1; } - fdinfo = msvcrt_get_ioinfo(fd); + fdinfo = get_ioinfo_nolock(fd); if(fdinfo == &MSVCRT___badioinfo) { int i; @@ -372,7 +386,7 @@ for(i=0; ihandle = hand; @@ -380,14 +394,16 @@ fdinfo->lookahead[0] = '\n'; fdinfo->lookahead[1] = '\n'; fdinfo->lookahead[2] = '\n'; - fdinfo->exflag = 0; + if(!(fdinfo->exflag & EF_CRIT_INIT)) + InitializeCriticalSection(&fdinfo->crit); + fdinfo->exflag = EF_CRIT_INIT; /* locate next free slot */ if (fd == MSVCRT_fdstart && fd == MSVCRT_fdend) MSVCRT_fdstart = MSVCRT_fdend + 1; else while (MSVCRT_fdstart < MSVCRT_fdend && - msvcrt_get_ioinfo(MSVCRT_fdstart)->handle != INVALID_HANDLE_VALUE) + get_ioinfo_nolock(MSVCRT_fdstart)->handle != INVALID_HANDLE_VALUE) MSVCRT_fdstart++; /* update last fd in use */ if (fd >= MSVCRT_fdend) @@ -495,7 +511,7 @@ for (fd = 0; fd < MSVCRT_fdend; fd++) { /* to be inherited, we need it to be open, and that DONTINHERIT isn't set */ - fdinfo = msvcrt_get_ioinfo(fd); + fdinfo = get_ioinfo_nolock(fd); if ((fdinfo->wxflag & (WX_OPEN | WX_DONTINHERIT)) == WX_OPEN) { *wxflag_ptr = fdinfo->wxflag; @@ -542,10 +558,10 @@ } MSVCRT_fdend = max( 3, count ); for (MSVCRT_fdstart = 3; MSVCRT_fdstart < MSVCRT_fdend; MSVCRT_fdstart++) - if (msvcrt_get_ioinfo(MSVCRT_fdstart)->handle == INVALID_HANDLE_VALUE) break; + if (get_ioinfo_nolock(MSVCRT_fdstart)->handle == INVALID_HANDLE_VALUE) break; } - fdinfo = msvcrt_get_ioinfo(MSVCRT_STDIN_FILENO); + fdinfo = get_ioinfo_nolock(MSVCRT_STDIN_FILENO); if (!(fdinfo->wxflag & WX_OPEN) || fdinfo->handle == INVALID_HANDLE_VALUE) { HANDLE h = GetStdHandle(STD_INPUT_HANDLE); DWORD type = GetFileType(h); @@ -554,7 +570,7 @@ |((type&0xf)==FILE_TYPE_PIPE ? WX_PIPE : 0), MSVCRT_STDIN_FILENO); } - fdinfo = msvcrt_get_ioinfo(MSVCRT_STDOUT_FILENO); + fdinfo = get_ioinfo_nolock(MSVCRT_STDOUT_FILENO); if (!(fdinfo->wxflag & WX_OPEN) || fdinfo->handle == INVALID_HANDLE_VALUE) { HANDLE h = GetStdHandle(STD_OUTPUT_HANDLE); DWORD type = GetFileType(h); @@ -563,7 +579,7 @@ |((type&0xf)==FILE_TYPE_PIPE ? WX_PIPE : 0), MSVCRT_STDOUT_FILENO); } - fdinfo = msvcrt_get_ioinfo(MSVCRT_STDERR_FILENO); + fdinfo = get_ioinfo_nolock(MSVCRT_STDERR_FILENO); if (!(fdinfo->wxflag & WX_OPEN) || fdinfo->handle == INVALID_HANDLE_VALUE) { HANDLE h = GetStdHandle(STD_ERROR_HANDLE); DWORD type = GetFileType(h); @@ -572,9 +588,9 @@ |((type&0xf)==FILE_TYPE_PIPE ? WX_PIPE : 0), MSVCRT_STDERR_FILENO); } - TRACE(":handles (%p)(%p)(%p)\n", msvcrt_get_ioinfo(MSVCRT_STDIN_FILENO)->handle, - msvcrt_get_ioinfo(MSVCRT_STDOUT_FILENO)->handle, - msvcrt_get_ioinfo(MSVCRT_STDERR_FILENO)->handle); + TRACE(":handles (%p)(%p)(%p)\n", get_ioinfo_nolock(MSVCRT_STDIN_FILENO)->handle, + get_ioinfo_nolock(MSVCRT_STDOUT_FILENO)->handle, + get_ioinfo_nolock(MSVCRT_STDERR_FILENO)->handle); memset(MSVCRT__iob,0,3*sizeof(MSVCRT_FILE)); for (i = 0; i < 3; i++) @@ -609,7 +625,7 @@ { TRACE(":fd (%d)\n",fd); - return msvcrt_get_ioinfo(fd)->wxflag & WX_TTY; + return get_ioinfo_nolock(fd)->wxflag & WX_TTY; } /* INTERNAL: Allocate stdio file buffer */ @@ -856,27 +872,37 @@ */ int CDECL MSVCRT__commit(int fd) { - HANDLE hand = msvcrt_fdtoh(fd); + ioinfo *info = get_ioinfo(fd); + int ret; - TRACE(":fd (%d) handle (%p)\n",fd,hand); - if (hand == INVALID_HANDLE_VALUE) - return -1; + TRACE(":fd (%d) handle (%p)\n", fd, info->handle); - if (!FlushFileBuffers(hand)) + if (info->handle == INVALID_HANDLE_VALUE) + ret = -1; + else if (!FlushFileBuffers(info->handle)) { if (GetLastError() == ERROR_INVALID_HANDLE) { /* FlushFileBuffers fails for console handles * so we ignore this error. */ - return 0; + ret = 0; + } + else + { + TRACE(":failed-last error (%d)\n",GetLastError()); + msvcrt_set_errno(GetLastError()); + ret = -1; } - TRACE(":failed-last error (%d)\n",GetLastError()); - msvcrt_set_errno(GetLastError()); - return -1; } - TRACE(":ok\n"); - return 0; + else + { + TRACE(":ok\n"); + ret = 0; + } + + release_ioinfo(info); + return ret; } /* flush_all_buffers calls MSVCRT_fflush which calls flush_all_buffers */ @@ -919,24 +945,38 @@ */ int CDECL MSVCRT_fflush(MSVCRT_FILE* file) { + int ret; + + if(!file) { + msvcrt_flush_all_buffers(MSVCRT__IOWRT); + ret = 0; + } else { + MSVCRT__lock_file(file); + ret = MSVCRT__fflush_nolock(file); + MSVCRT__unlock_file(file); + } + + return ret; +} + +/********************************************************************* + * _fflush_nolock (MSVCRT.@) + */ +int CDECL MSVCRT__fflush_nolock(MSVCRT_FILE* file) +{ if(!file) { msvcrt_flush_all_buffers(MSVCRT__IOWRT); } else if(file->_flag & MSVCRT__IOWRT) { int res; - MSVCRT__lock_file(file); res = msvcrt_flush_buffer(file); - if(!res && (file->_flag & MSVCRT__IOCOMMIT)) res = MSVCRT__commit(file->_file) ? MSVCRT_EOF : 0; - MSVCRT__unlock_file(file); return res; } else if(file->_flag & MSVCRT__IOREAD) { - MSVCRT__lock_file(file); file->_cnt = 0; file->_ptr = file->_base; - MSVCRT__unlock_file(file); return 0; } @@ -948,24 +988,23 @@ */ int CDECL MSVCRT__close(int fd) { - HANDLE hand; + ioinfo *info = get_ioinfo(fd); int ret; LOCK_FILES(); - hand = msvcrt_fdtoh(fd); - TRACE(":fd (%d) handle (%p)\n",fd,hand); - if (!msvcrt_is_valid_fd(fd)) { + TRACE(":fd (%d) handle (%p)\n", fd, info->handle); + if (!(info->wxflag & WX_OPEN)) { ret = -1; } else { + ret = CloseHandle(info->handle) ? 0 : -1; msvcrt_free_fd(fd); - ret = CloseHandle(hand) ? 0 : -1; if (ret) { WARN(":failed-last error (%d)\n",GetLastError()); msvcrt_set_errno(GetLastError()); } } UNLOCK_FILES(); - TRACE(":ok\n"); + release_ioinfo(info); return ret; } @@ -986,10 +1025,10 @@ { HANDLE handle; - if (DuplicateHandle(GetCurrentProcess(), msvcrt_get_ioinfo(od)->handle, + if (DuplicateHandle(GetCurrentProcess(), get_ioinfo_nolock(od)->handle, GetCurrentProcess(), &handle, 0, TRUE, DUPLICATE_SAME_ACCESS)) { - int wxflag = msvcrt_get_ioinfo(od)->wxflag & ~MSVCRT__O_NOINHERIT; + int wxflag = get_ioinfo_nolock(od)->wxflag & ~MSVCRT__O_NOINHERIT; if (msvcrt_is_valid_fd(nd)) MSVCRT__close(nd); @@ -1051,7 +1090,7 @@ if (hand == INVALID_HANDLE_VALUE) return -1; - if (msvcrt_get_ioinfo(fd)->wxflag & WX_ATEOF) return TRUE; + if (get_ioinfo_nolock(fd)->wxflag & WX_ATEOF) return TRUE; /* Otherwise we do it the hard way */ hcurpos = hendpos = 0; @@ -1099,7 +1138,17 @@ MSVCRT__fcloseall(); for(i=0; iwxflag &= ~WX_ATEOF; + get_ioinfo_nolock(fd)->wxflag &= ~WX_ATEOF; /* FIXME: What if we seek _to_ EOF - is EOF set? */ return ofs.QuadPart; @@ -1246,16 +1295,29 @@ */ int CDECL MSVCRT__fseeki64(MSVCRT_FILE* file, __int64 offset, int whence) { + int ret; + + MSVCRT__lock_file(file); + ret = MSVCRT__fseeki64_nolock(file, offset, whence); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _fseeki64_nolock (MSVCRT.@) + */ +int CDECL MSVCRT__fseeki64_nolock(MSVCRT_FILE* file, __int64 offset, int whence) +{ int ret; - MSVCRT__lock_file(file); /* Flush output if needed */ if(file->_flag & MSVCRT__IOWRT) msvcrt_flush_buffer(file); if(whence == SEEK_CUR && file->_flag & MSVCRT__IOREAD ) { whence = SEEK_SET; - offset += MSVCRT__ftelli64(file); + offset += MSVCRT__ftelli64_nolock(file); } /* Discard buffered input */ @@ -1269,7 +1331,6 @@ file->_flag &= ~MSVCRT__IOEOF; ret = (MSVCRT__lseeki64(file->_file,offset,whence) == -1)?-1:0; - MSVCRT__unlock_file(file); return ret; } @@ -1282,6 +1343,14 @@ } /********************************************************************* + * _fseek_nolock (MSVCRT.@) + */ +int CDECL MSVCRT__fseek_nolock(MSVCRT_FILE* file, MSVCRT_long offset, int whence) +{ + return MSVCRT__fseeki64_nolock( file, offset, whence ); +} + +/********************************************************************* * _chsize_s (MSVCRT.@) */ int CDECL MSVCRT__chsize_s(int fd, __int64 size) @@ -2146,11 +2215,11 @@ return *MSVCRT__errno(); if (oflags & MSVCRT__O_WTEXT) - msvcrt_get_ioinfo(*fd)->exflag |= EF_UTF16|EF_UNK_UNICODE; + get_ioinfo_nolock(*fd)->exflag |= EF_UTF16|EF_UNK_UNICODE; else if (oflags & MSVCRT__O_U16TEXT) - msvcrt_get_ioinfo(*fd)->exflag |= EF_UTF16; + get_ioinfo_nolock(*fd)->exflag |= EF_UTF16; else if (oflags & MSVCRT__O_U8TEXT) - msvcrt_get_ioinfo(*fd)->exflag |= EF_UTF8; + get_ioinfo_nolock(*fd)->exflag |= EF_UTF8; TRACE(":fd (%d) handle (%p)\n", *fd, hand); return 0; @@ -2355,7 +2424,7 @@ */ static int read_utf8(int fd, MSVCRT_wchar_t *buf, unsigned int count) { - ioinfo *fdinfo = msvcrt_get_ioinfo(fd); + ioinfo *fdinfo = get_ioinfo_nolock(fd); HANDLE hand = fdinfo->handle; char min_buf[4], *readbuf, lookahead; DWORD readbuf_size, pos=0, num_read=1, char_len, i, j; @@ -2535,7 +2604,7 @@ DWORD num_read, utf16; char *bufstart = buf; HANDLE hand = msvcrt_fdtoh(fd); - ioinfo *fdinfo = msvcrt_get_ioinfo(fd); + ioinfo *fdinfo = get_ioinfo_nolock(fd); if (count == 0) return 0; @@ -2704,8 +2773,8 @@ */ int CDECL MSVCRT__setmode(int fd,int mode) { - int ret = msvcrt_get_ioinfo(fd)->wxflag & WX_TEXT ? MSVCRT__O_TEXT : MSVCRT__O_BINARY; - if(ret==MSVCRT__O_TEXT && (msvcrt_get_ioinfo(fd)->exflag & (EF_UTF8|EF_UTF16))) + int ret = get_ioinfo_nolock(fd)->wxflag & WX_TEXT ? MSVCRT__O_TEXT : MSVCRT__O_BINARY; + if(ret==MSVCRT__O_TEXT && (get_ioinfo_nolock(fd)->exflag & (EF_UTF8|EF_UTF16))) ret = MSVCRT__O_WTEXT; if(mode!=MSVCRT__O_TEXT && mode!=MSVCRT__O_BINARY && mode!=MSVCRT__O_WTEXT @@ -2715,18 +2784,18 @@ } if(mode == MSVCRT__O_BINARY) { - msvcrt_get_ioinfo(fd)->wxflag &= ~WX_TEXT; - msvcrt_get_ioinfo(fd)->exflag &= ~(EF_UTF8|EF_UTF16); + get_ioinfo_nolock(fd)->wxflag &= ~WX_TEXT; + get_ioinfo_nolock(fd)->exflag &= ~(EF_UTF8|EF_UTF16); return ret; } - msvcrt_get_ioinfo(fd)->wxflag |= WX_TEXT; + get_ioinfo_nolock(fd)->wxflag |= WX_TEXT; if(mode == MSVCRT__O_TEXT) - msvcrt_get_ioinfo(fd)->exflag &= ~(EF_UTF8|EF_UTF16); + get_ioinfo_nolock(fd)->exflag &= ~(EF_UTF8|EF_UTF16); else if(mode == MSVCRT__O_U8TEXT) - msvcrt_get_ioinfo(fd)->exflag = (msvcrt_get_ioinfo(fd)->exflag & ~EF_UTF16) | EF_UTF8; + get_ioinfo_nolock(fd)->exflag = (get_ioinfo_nolock(fd)->exflag & ~EF_UTF16) | EF_UTF8; else - msvcrt_get_ioinfo(fd)->exflag = (msvcrt_get_ioinfo(fd)->exflag & ~EF_UTF8) | EF_UTF16; + get_ioinfo_nolock(fd)->exflag = (get_ioinfo_nolock(fd)->exflag & ~EF_UTF8) | EF_UTF16; return ret; } @@ -3184,7 +3253,7 @@ int CDECL MSVCRT__write(int fd, const void* buf, unsigned int count) { DWORD num_written; - ioinfo *info = msvcrt_get_ioinfo(fd); + ioinfo *info = get_ioinfo_nolock(fd); HANDLE hand = info->handle; /* Don't trace small writes, it gets *very* annoying */ @@ -3373,22 +3442,33 @@ */ int CDECL MSVCRT_fclose(MSVCRT_FILE* file) { - int r, flag; + int ret; MSVCRT__lock_file(file); + ret = MSVCRT__fclose_nolock(file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _fclose_nolock (MSVCRT.@) + */ +int CDECL MSVCRT__fclose_nolock(MSVCRT_FILE* file) +{ + int r, flag; + flag = file->_flag; MSVCRT_free(file->_tmpfname); file->_tmpfname = NULL; /* flush stdio buffers */ if(file->_flag & MSVCRT__IOWRT) - MSVCRT_fflush(file); + MSVCRT__fflush_nolock(file); if(file->_flag & MSVCRT__IOMYBUF) MSVCRT_free(file->_base); r=MSVCRT__close(file->_file); - file->_flag = 0; - MSVCRT__unlock_file(file); return ((r == -1) || (flag & MSVCRT__IOERR) ? MSVCRT_EOF : 0); } @@ -3415,12 +3495,9 @@ int CDECL MSVCRT__filbuf(MSVCRT_FILE* file) { unsigned char c; - MSVCRT__lock_file(file); - if(file->_flag & MSVCRT__IOSTRG) { - MSVCRT__unlock_file(file); + if(file->_flag & MSVCRT__IOSTRG) return MSVCRT_EOF; - } /* Allocate buffer if needed */ if(!(file->_flag & (MSVCRT__IONBF | MSVCRT__IOMYBUF | MSVCRT__USERBUF))) @@ -3429,35 +3506,29 @@ if(!(file->_flag & MSVCRT__IOREAD)) { if(file->_flag & MSVCRT__IORW) file->_flag |= MSVCRT__IOREAD; - else { - MSVCRT__unlock_file(file); + else return MSVCRT_EOF; - } } if(!(file->_flag & (MSVCRT__IOMYBUF | MSVCRT__USERBUF))) { int r; if ((r = read_i(file->_file,&c,1)) != 1) { file->_flag |= (r == 0) ? MSVCRT__IOEOF : MSVCRT__IOERR; - MSVCRT__unlock_file(file); return MSVCRT_EOF; } - MSVCRT__unlock_file(file); return c; } else { file->_cnt = read_i(file->_file, file->_base, file->_bufsiz); if(file->_cnt<=0) { file->_flag |= (file->_cnt == 0) ? MSVCRT__IOEOF : MSVCRT__IOERR; file->_cnt = 0; - MSVCRT__unlock_file(file); return MSVCRT_EOF; } file->_cnt--; file->_ptr = file->_base+1; c = *(unsigned char *)file->_base; - MSVCRT__unlock_file(file); return c; } } @@ -3467,10 +3538,23 @@ */ int CDECL MSVCRT_fgetc(MSVCRT_FILE* file) { + int ret; + + MSVCRT__lock_file(file); + ret = MSVCRT__fgetc_nolock(file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _fgetc_nolock (MSVCRT.@) + */ +int CDECL MSVCRT__fgetc_nolock(MSVCRT_FILE* file) +{ unsigned char *i; unsigned int j; - MSVCRT__lock_file(file); if (file->_cnt>0) { file->_cnt--; i = (unsigned char *)file->_ptr++; @@ -3478,7 +3562,6 @@ } else j = MSVCRT__filbuf(file); - MSVCRT__unlock_file(file); return j; } @@ -3528,16 +3611,28 @@ MSVCRT_wint_t CDECL MSVCRT_fgetwc(MSVCRT_FILE* file) { MSVCRT_wint_t ret; - int ch; MSVCRT__lock_file(file); + ret = MSVCRT__fgetwc_nolock(file); + MSVCRT__unlock_file(file); + + return ret; +} - if((msvcrt_get_ioinfo(file->_file)->exflag & (EF_UTF8 | EF_UTF16)) - || !(msvcrt_get_ioinfo(file->_file)->wxflag & WX_TEXT)) { +/********************************************************************* + * _fgetwc_nolock (MSVCRT.@) + */ +MSVCRT_wint_t CDECL MSVCRT__fgetwc_nolock(MSVCRT_FILE* file) +{ + MSVCRT_wint_t ret; + int ch; + + if((get_ioinfo_nolock(file->_file)->exflag & (EF_UTF8 | EF_UTF16)) + || !(get_ioinfo_nolock(file->_file)->wxflag & WX_TEXT)) { char *p; for(p=(char*)&ret; (MSVCRT_wint_t*)p<&ret+1; p++) { - ch = MSVCRT_fgetc(file); + ch = MSVCRT__fgetc_nolock(file); if(ch == MSVCRT_EOF) { ret = MSVCRT_WEOF; break; @@ -3548,11 +3643,11 @@ char mbs[MSVCRT_MB_LEN_MAX]; int len = 0; - ch = MSVCRT_fgetc(file); + ch = MSVCRT__fgetc_nolock(file); if(ch != MSVCRT_EOF) { mbs[0] = (char)ch; if(MSVCRT_isleadbyte((unsigned char)mbs[0])) { - ch = MSVCRT_fgetc(file); + ch = MSVCRT__fgetc_nolock(file); if(ch != MSVCRT_EOF) { mbs[1] = (char)ch; len = 2; @@ -3566,7 +3661,6 @@ ret = MSVCRT_WEOF; } - MSVCRT__unlock_file(file); return ret; } @@ -3696,13 +3790,25 @@ */ MSVCRT_size_t CDECL MSVCRT_fwrite(const void *ptr, MSVCRT_size_t size, MSVCRT_size_t nmemb, MSVCRT_FILE* file) { + MSVCRT_size_t ret; + + MSVCRT__lock_file(file); + ret = MSVCRT__fwrite_nolock(ptr, size, nmemb, file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _fwrite_nolock (MSVCRT.@) + */ +MSVCRT_size_t CDECL MSVCRT__fwrite_nolock(const void *ptr, MSVCRT_size_t size, MSVCRT_size_t nmemb, MSVCRT_FILE* file) +{ MSVCRT_size_t wrcnt=size * nmemb; int written = 0; if (size == 0) return 0; - MSVCRT__lock_file(file); - while(wrcnt) { if(file->_cnt < 0) { WARN("negative file->_cnt value in %p\n", file); @@ -3750,7 +3856,6 @@ } } - MSVCRT__unlock_file(file); return written / size; } @@ -3759,29 +3864,41 @@ */ MSVCRT_wint_t CDECL MSVCRT_fputwc(MSVCRT_wint_t wc, MSVCRT_FILE* file) { + MSVCRT_wint_t ret; + + MSVCRT__lock_file(file); + ret = MSVCRT__fputwc_nolock(wc, file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _fputwc_nolock (MSVCRT.@) + */ +MSVCRT_wint_t CDECL MSVCRT__fputwc_nolock(MSVCRT_wint_t wc, MSVCRT_FILE* file) +{ MSVCRT_wchar_t mwc=wc; ioinfo *fdinfo; MSVCRT_wint_t ret; - MSVCRT__lock_file(file); - fdinfo = msvcrt_get_ioinfo(file->_file); + fdinfo = get_ioinfo_nolock(file->_file); if((fdinfo->wxflag&WX_TEXT) && !(fdinfo->exflag&(EF_UTF8|EF_UTF16))) { char buf[MSVCRT_MB_LEN_MAX]; int char_len; char_len = MSVCRT_wctomb(buf, mwc); - if(char_len!=-1 && MSVCRT_fwrite(buf, char_len, 1, file)==1) + if(char_len!=-1 && MSVCRT__fwrite_nolock(buf, char_len, 1, file)==1) ret = wc; else ret = MSVCRT_WEOF; - }else if(MSVCRT_fwrite(&mwc, sizeof(mwc), 1, file) == 1) { + }else if(MSVCRT__fwrite_nolock(&mwc, sizeof(mwc), 1, file) == 1) { ret = wc; }else { ret = MSVCRT_WEOF; } - MSVCRT__unlock_file(file); return ret; } @@ -3910,25 +4027,35 @@ */ int CDECL MSVCRT_fputc(int c, MSVCRT_FILE* file) { + int ret; + + MSVCRT__lock_file(file); + ret = MSVCRT__fputc_nolock(c, file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _fputc_nolock (MSVCRT.@) + */ +int CDECL MSVCRT__fputc_nolock(int c, MSVCRT_FILE* file) +{ int res; - MSVCRT__lock_file(file); if(file->_cnt>0) { *file->_ptr++=c; file->_cnt--; if (c == '\n') { res = msvcrt_flush_buffer(file); - MSVCRT__unlock_file(file); return res ? res : c; } else { - MSVCRT__unlock_file(file); return c & 0xff; } } else { res = MSVCRT__flsbuf(c, file); - MSVCRT__unlock_file(file); return res; } } @@ -3946,6 +4073,20 @@ */ MSVCRT_size_t CDECL MSVCRT_fread(void *ptr, MSVCRT_size_t size, MSVCRT_size_t nmemb, MSVCRT_FILE* file) { + MSVCRT_size_t ret; + + MSVCRT__lock_file(file); + ret = MSVCRT__fread_nolock(ptr, size, nmemb, file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _fread_nolock (MSVCRT.@) + */ +MSVCRT_size_t CDECL MSVCRT__fread_nolock(void *ptr, MSVCRT_size_t size, MSVCRT_size_t nmemb, MSVCRT_FILE* file) +{ MSVCRT_size_t rcnt=size * nmemb; MSVCRT_size_t read=0; MSVCRT_size_t pread=0; @@ -3953,8 +4094,6 @@ if(!rcnt) return 0; - MSVCRT__lock_file(file); - /* first buffered data */ if(file->_cnt>0) { int pcnt= (rcnt>file->_cnt)? file->_cnt:rcnt; @@ -3968,7 +4107,6 @@ if(file->_flag & MSVCRT__IORW) { file->_flag |= MSVCRT__IOREAD; } else { - MSVCRT__unlock_file(file); return 0; } } @@ -3985,7 +4123,7 @@ i = (file->_cnt_cnt : rcnt; /* If the buffer fill reaches eof but fread wouldn't, clear eof. */ if (i > 0 && i < file->_cnt) { - msvcrt_get_ioinfo(file->_file)->wxflag &= ~WX_ATEOF; + get_ioinfo_nolock(file->_file)->wxflag &= ~WX_ATEOF; file->_flag &= ~MSVCRT__IOEOF; } if (i > 0) { @@ -4006,7 +4144,7 @@ /* expose feof condition in the flags * MFC tests file->_flag for feof, and doesn't call feof()) */ - if (msvcrt_get_ioinfo(file->_file)->wxflag & WX_ATEOF) + if (get_ioinfo_nolock(file->_file)->wxflag & WX_ATEOF) file->_flag |= MSVCRT__IOEOF; else if (i == -1) { @@ -4017,7 +4155,6 @@ if (i < 1) break; } read+=pread; - MSVCRT__unlock_file(file); return read / size; } @@ -4028,9 +4165,31 @@ MSVCRT_size_t CDECL MSVCRT_fread_s(void *buf, MSVCRT_size_t buf_size, MSVCRT_size_t elem_size, MSVCRT_size_t count, MSVCRT_FILE *stream) { + MSVCRT_size_t ret; + + if(!MSVCRT_CHECK_PMT(stream != NULL)) { + if(buf && buf_size) + memset(buf, 0, buf_size); + return 0; + } + if(!elem_size || !count) return 0; + + MSVCRT__lock_file(stream); + ret = MSVCRT__fread_nolock_s(buf, buf_size, elem_size, count, stream); + MSVCRT__unlock_file(stream); + + return ret; +} + +/********************************************************************* + * _fread_nolock_s (MSVCR80.@) + */ +MSVCRT_size_t CDECL MSVCRT__fread_nolock_s(void *buf, MSVCRT_size_t buf_size, MSVCRT_size_t elem_size, + MSVCRT_size_t count, MSVCRT_FILE *stream) +{ size_t bytes_left, buf_pos; - TRACE("(%p %lu %lu %lu %p\n", buf, buf_size, elem_size, count, stream); + TRACE("(%p %lu %lu %lu %p)\n", buf, buf_size, elem_size, count, stream); if(!MSVCRT_CHECK_PMT(stream != NULL)) { if(buf && buf_size) @@ -4052,7 +4211,7 @@ return 0; } - MSVCRT_fread((char*)buf+buf_pos, 1, size, stream); + MSVCRT__fread_nolock((char*)buf+buf_pos, 1, size, stream); buf_pos += size; bytes_left -= size; }else { @@ -4194,19 +4353,30 @@ */ __int64 CDECL MSVCRT__ftelli64(MSVCRT_FILE* file) { - __int64 pos; + __int64 ret; MSVCRT__lock_file(file); + ret = MSVCRT__ftelli64_nolock(file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _ftelli64_nolock (MSVCRT.@) + */ +__int64 CDECL MSVCRT__ftelli64_nolock(MSVCRT_FILE* file) +{ + __int64 pos; + pos = _telli64(file->_file); - if(pos == -1) { - MSVCRT__unlock_file(file); + if(pos == -1) return -1; - } if(file->_flag & (MSVCRT__IOMYBUF | MSVCRT__USERBUF)) { if(file->_flag & MSVCRT__IOWRT) { pos += file->_ptr - file->_base; - if(msvcrt_get_ioinfo(file->_file)->wxflag & WX_TEXT) { + if(get_ioinfo_nolock(file->_file)->wxflag & WX_TEXT) { char *p; for(p=file->_base; p_ptr; p++) @@ -4218,7 +4388,7 @@ int i; pos -= file->_cnt; - if(msvcrt_get_ioinfo(file->_file)->wxflag & WX_TEXT) { + if(get_ioinfo_nolock(file->_file)->wxflag & WX_TEXT) { for(i=0; i_cnt; i++) if(file->_ptr[i] == '\n') pos--; @@ -4226,16 +4396,14 @@ } else { char *p; - if(MSVCRT__lseeki64(file->_file, pos, SEEK_SET) != pos) { - MSVCRT__unlock_file(file); + if(MSVCRT__lseeki64(file->_file, pos, SEEK_SET) != pos) return -1; - } pos -= file->_bufsiz; pos += file->_ptr - file->_base; - if(msvcrt_get_ioinfo(file->_file)->wxflag & WX_TEXT) { - if(msvcrt_get_ioinfo(file->_file)->wxflag & WX_READNL) + if(get_ioinfo_nolock(file->_file)->wxflag & WX_TEXT) { + if(get_ioinfo_nolock(file->_file)->wxflag & WX_READNL) pos--; for(p=file->_base; p_ptr; p++) @@ -4245,7 +4413,6 @@ } } - MSVCRT__unlock_file(file); return pos; } @@ -4258,6 +4425,14 @@ } /********************************************************************* + * _ftell_nolock (MSVCRT.@) + */ +LONG CDECL MSVCRT__ftell_nolock(MSVCRT_FILE* file) +{ + return MSVCRT__ftelli64_nolock(file); +} + +/********************************************************************* * fgetpos (MSVCRT.@) */ int CDECL MSVCRT_fgetpos(MSVCRT_FILE* file, MSVCRT_fpos_t *pos) @@ -4292,7 +4467,7 @@ int ret; MSVCRT__lock_file(file); - if (!(msvcrt_get_ioinfo(file->_file)->wxflag & WX_TEXT)) { + if (!(get_ioinfo_nolock(file->_file)->wxflag & WX_TEXT)) { ret = MSVCRT_fwrite(s,sizeof(*s),len,file) == len ? 0 : MSVCRT_EOF; MSVCRT__unlock_file(file); return ret; @@ -4647,7 +4822,7 @@ MSVCRT__lock_file(file); - if(!(msvcrt_get_ioinfo(((MSVCRT_FILE*)file)->_file)->wxflag & WX_TEXT)) { + if(!(get_ioinfo_nolock(((MSVCRT_FILE*)file)->_file)->wxflag & WX_TEXT)) { ret = MSVCRT_fwrite(str, sizeof(MSVCRT_wchar_t), len, file); MSVCRT__unlock_file(file); return ret; @@ -4884,13 +5059,28 @@ */ int CDECL MSVCRT_ungetc(int c, MSVCRT_FILE * file) { + int ret; + + if(!MSVCRT_CHECK_PMT(file != NULL)) return MSVCRT_EOF; + + MSVCRT__lock_file(file); + ret = MSVCRT__ungetc_nolock(c, file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _ungetc_nolock (MSVCRT.@) + */ +int CDECL MSVCRT__ungetc_nolock(int c, MSVCRT_FILE * file) +{ if(!MSVCRT_CHECK_PMT(file != NULL)) return MSVCRT_EOF; if (c == MSVCRT_EOF || !(file->_flag&MSVCRT__IOREAD || (file->_flag&MSVCRT__IORW && !(file->_flag&MSVCRT__IOWRT)))) return MSVCRT_EOF; - MSVCRT__lock_file(file); if((!(file->_flag & (MSVCRT__IONBF | MSVCRT__IOMYBUF | MSVCRT__USERBUF)) && msvcrt_alloc_buffer(file)) || (!file->_cnt && file->_ptr==file->_base)) @@ -4901,20 +5091,17 @@ if(file->_flag & MSVCRT__IOSTRG) { if(*file->_ptr != c) { file->_ptr++; - MSVCRT__unlock_file(file); return MSVCRT_EOF; } }else { *file->_ptr = c; } file->_cnt++; - MSVCRT_clearerr(file); + file->_flag &= ~(MSVCRT__IOERR | MSVCRT__IOEOF); file->_flag |= MSVCRT__IOREAD; - MSVCRT__unlock_file(file); return c; } - MSVCRT__unlock_file(file); return MSVCRT_EOF; } @@ -4923,43 +5110,51 @@ */ MSVCRT_wint_t CDECL MSVCRT_ungetwc(MSVCRT_wint_t wc, MSVCRT_FILE * file) { + MSVCRT_wint_t ret; + + if(!MSVCRT_CHECK_PMT(file != NULL)) return MSVCRT_WEOF; + + MSVCRT__lock_file(file); + ret = MSVCRT__ungetwc_nolock(wc, file); + MSVCRT__unlock_file(file); + + return ret; +} + +/********************************************************************* + * _ungetwc_nolock (MSVCRT.@) + */ +MSVCRT_wint_t CDECL MSVCRT__ungetwc_nolock(MSVCRT_wint_t wc, MSVCRT_FILE * file) +{ MSVCRT_wchar_t mwc = wc; + if(!MSVCRT_CHECK_PMT(file != NULL)) return MSVCRT_WEOF; if (wc == MSVCRT_WEOF) return MSVCRT_WEOF; - MSVCRT__lock_file(file); - - if((msvcrt_get_ioinfo(file->_file)->exflag & (EF_UTF8 | EF_UTF16)) - || !(msvcrt_get_ioinfo(file->_file)->wxflag & WX_TEXT)) { + if((get_ioinfo_nolock(file->_file)->exflag & (EF_UTF8 | EF_UTF16)) + || !(get_ioinfo_nolock(file->_file)->wxflag & WX_TEXT)) { unsigned char * pp = (unsigned char *)&mwc; int i; for(i=sizeof(MSVCRT_wchar_t)-1;i>=0;i--) { - if(pp[i] != MSVCRT_ungetc(pp[i],file)) { - MSVCRT__unlock_file(file); + if(pp[i] != MSVCRT__ungetc_nolock(pp[i],file)) return MSVCRT_WEOF; - } } }else { char mbs[MSVCRT_MB_LEN_MAX]; int len; len = MSVCRT_wctomb(mbs, mwc); - if(len == -1) { - MSVCRT__unlock_file(file); + if(len == -1) return MSVCRT_WEOF; - } for(len--; len>=0; len--) { - if(mbs[len] != MSVCRT_ungetc(mbs[len], file)) { - MSVCRT__unlock_file(file); + if(mbs[len] != MSVCRT__ungetc_nolock(mbs[len], file)) return MSVCRT_WEOF; - } } } - MSVCRT__unlock_file(file); return mwc; } diff -Nru wine1.7-1.7.28/dlls/msvcrt/msvcrt.h wine1.7-1.7.31/dlls/msvcrt/msvcrt.h --- wine1.7-1.7.28/dlls/msvcrt/msvcrt.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcrt/msvcrt.h 2014-11-14 13:28:17.000000000 +0000 @@ -916,16 +916,29 @@ void __cdecl MSVCRT__lock_file(MSVCRT_FILE*); void __cdecl MSVCRT__unlock_file(MSVCRT_FILE*); int __cdecl MSVCRT_fgetc(MSVCRT_FILE*); +int __cdecl MSVCRT__fgetc_nolock(MSVCRT_FILE*); +int __cdecl MSVCRT__fputc_nolock(int,MSVCRT_FILE*); int __cdecl MSVCRT_ungetc(int,MSVCRT_FILE*); +int __cdecl MSVCRT__ungetc_nolock(int,MSVCRT_FILE*); MSVCRT_wint_t __cdecl MSVCRT_fgetwc(MSVCRT_FILE*); +MSVCRT_wint_t __cdecl MSVCRT__fgetwc_nolock(MSVCRT_FILE*); +MSVCRT_wint_t __cdecl MSVCRT__fputwc_nolock(MSVCRT_wint_t,MSVCRT_FILE*); MSVCRT_wint_t __cdecl MSVCRT_ungetwc(MSVCRT_wint_t,MSVCRT_FILE*); +MSVCRT_wint_t __cdecl MSVCRT__ungetwc_nolock(MSVCRT_wint_t, MSVCRT_FILE*); +int __cdecl MSVCRT__fseeki64_nolock(MSVCRT_FILE*,__int64,int); __int64 __cdecl MSVCRT__ftelli64(MSVCRT_FILE* file); +__int64 __cdecl MSVCRT__ftelli64_nolock(MSVCRT_FILE*); void __cdecl MSVCRT__exit(int); void __cdecl MSVCRT_abort(void); MSVCRT_ulong* __cdecl MSVCRT___doserrno(void); int* __cdecl MSVCRT__errno(void); char* __cdecl MSVCRT_getenv(const char*); +MSVCRT_size_t __cdecl MSVCRT__fread_nolock(void*,MSVCRT_size_t,MSVCRT_size_t,MSVCRT_FILE*); +MSVCRT_size_t __cdecl MSVCRT__fread_nolock_s(void*,MSVCRT_size_t,MSVCRT_size_t,MSVCRT_size_t,MSVCRT_FILE*); +MSVCRT_size_t __cdecl MSVCRT__fwrite_nolock(const void*,MSVCRT_size_t,MSVCRT_size_t,MSVCRT_FILE*); int __cdecl MSVCRT_fclose(MSVCRT_FILE*); +int __cdecl MSVCRT__fclose_nolock(MSVCRT_FILE*); +int __cdecl MSVCRT__fflush_nolock(MSVCRT_FILE*); void __cdecl MSVCRT_terminate(void); MSVCRT_FILE* __cdecl MSVCRT__iob_func(void); MSVCRT_clock_t __cdecl MSVCRT_clock(void); diff -Nru wine1.7-1.7.28/dlls/msvcrt/msvcrt.spec wine1.7-1.7.31/dlls/msvcrt/msvcrt.spec --- wine1.7-1.7.28/dlls/msvcrt/msvcrt.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcrt/msvcrt.spec 2014-11-14 13:28:17.000000000 +0000 @@ -912,7 +912,7 @@ @ varargs _snprintf(ptr long str) MSVCRT__snprintf # stub _snprintf_c(ptr long str) # stub _snprintf_c_l(ptr long str ptr) -# stub _snprintf_l(ptr long str ptr) +@ varargs _snprintf_l(ptr long str ptr) MSVCRT__snprintf_l @ varargs _snprintf_s(ptr long long str) MSVCRT__snprintf_s # stub _snprintf_s_l(ptr long long str ptr) @ varargs _snscanf(str long str) MSVCRT__snscanf @@ -983,7 +983,7 @@ # stub _strtol_l(str ptr long ptr) @ cdecl -ret64 _strtoui64(str ptr long) MSVCRT_strtoui64 @ cdecl -ret64 _strtoui64_l(str ptr long ptr) MSVCRT_strtoui64_l -# stub _strtoul_l(str ptr long ptr) +@ cdecl _strtoul_l(str ptr long ptr) MSVCRT_strtoul_l @ cdecl _strupr(str) MSVCRT__strupr @ cdecl _strupr_l(str ptr) MSVCRT__strupr_l @ cdecl _strupr_s(str long) MSVCRT__strupr_s @@ -1113,7 +1113,7 @@ @ cdecl _wcsncoll(wstr wstr long) MSVCRT__wcsncoll @ cdecl _wcsncoll_l(wstr wstr long ptr) MSVCRT__wcsncoll_l @ cdecl _wcsnicmp(wstr wstr long) MSVCRT__wcsnicmp -# stub _wcsnicmp_l(wstr wstr long ptr) +@ cdecl _wcsnicmp_l(wstr wstr long ptr) MSVCRT__wcsnicmp_l @ cdecl _wcsnicoll(wstr wstr long) MSVCRT__wcsnicoll @ cdecl _wcsnicoll_l(wstr wstr long ptr) MSVCRT__wcsnicoll_l @ cdecl _wcsnset(wstr long long) MSVCRT__wcsnset diff -Nru wine1.7-1.7.28/dlls/msvcrt/string.c wine1.7-1.7.31/dlls/msvcrt/string.c --- wine1.7-1.7.28/dlls/msvcrt/string.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcrt/string.c 2014-11-14 13:28:17.000000000 +0000 @@ -982,11 +982,11 @@ } /****************************************************************** - * strtoul (MSVCRT.@) + * _strtoul_l (MSVCRT.@) */ -MSVCRT_ulong CDECL MSVCRT_strtoul(const char* nptr, char** end, int base) +MSVCRT_ulong CDECL MSVCRT_strtoul_l(const char* nptr, char** end, int base, MSVCRT__locale_t locale) { - __int64 ret = MSVCRT_strtoi64_l(nptr, end, base, NULL); + __int64 ret = MSVCRT_strtoi64_l(nptr, end, base, locale); if(ret > MSVCRT_ULONG_MAX) { ret = MSVCRT_ULONG_MAX; @@ -999,6 +999,14 @@ return ret; } +/****************************************************************** + * strtoul (MSVCRT.@) + */ +MSVCRT_ulong CDECL MSVCRT_strtoul(const char* nptr, char** end, int base) +{ + return MSVCRT_strtoul_l(nptr, end, base, NULL); +} + /********************************************************************* * _strtoui64_l (MSVCRT.@) * diff -Nru wine1.7-1.7.28/dlls/msvcrt/wcs.c wine1.7-1.7.31/dlls/msvcrt/wcs.c --- wine1.7-1.7.28/dlls/msvcrt/wcs.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvcrt/wcs.c 2014-11-14 13:28:17.000000000 +0000 @@ -90,11 +90,19 @@ } /********************************************************************* + * _wcsnicmp_l (MSVCRT.@) + */ +INT CDECL MSVCRT__wcsnicmp_l(const MSVCRT_wchar_t *str1, const MSVCRT_wchar_t *str2, INT n, MSVCRT__locale_t locale) +{ + return strncmpiW(str1, str2, n); +} + +/********************************************************************* * _wcsnicmp (MSVCRT.@) */ INT CDECL MSVCRT__wcsnicmp(const MSVCRT_wchar_t *str1, const MSVCRT_wchar_t *str2, INT n) { - return strncmpiW(str1, str2, n); + return MSVCRT__wcsnicmp_l(str1, str2, n, NULL); } /********************************************************************* @@ -808,6 +816,20 @@ __ms_va_end(valist); return retval; } + +/********************************************************************* + * _snprintf_l (MSVCRT.@) + */ +int CDECL MSVCRT__snprintf_l(char *str, unsigned int count, MSVCRT__locale_t locale, + const char *format, ...) +{ + int retval; + __ms_va_list valist; + __ms_va_start(valist, format); + retval = MSVCRT_vsnprintf_l(str, count, format, locale, valist); + __ms_va_end(valist); + return retval; +} /********************************************************************* * _snprintf_s (MSVCRT.@) diff -Nru wine1.7-1.7.28/dlls/msvfw32/mciwnd.c wine1.7-1.7.31/dlls/msvfw32/mciwnd.c --- wine1.7-1.7.28/dlls/msvfw32/mciwnd.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msvfw32/mciwnd.c 2014-11-14 13:28:17.000000000 +0000 @@ -86,7 +86,7 @@ wc.cbWndExtra = sizeof(MCIWndInfo*); wc.hInstance = MSVFW32_hModule; wc.hIcon = 0; - wc.hCursor = LoadCursorW(0, MAKEINTRESOURCEW(IDC_ARROW)); + wc.hCursor = LoadCursorW(0, (LPWSTR)IDC_ARROW); wc.hbrBackground = (HBRUSH)(COLOR_WINDOW + 1); wc.lpszMenuName = NULL; wc.lpszClassName = mciWndClassW; diff -Nru wine1.7-1.7.28/dlls/msxml3/doctype.c wine1.7-1.7.31/dlls/msxml3/doctype.c --- wine1.7-1.7.28/dlls/msxml3/doctype.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msxml3/doctype.c 2014-11-14 13:28:17.000000000 +0000 @@ -155,8 +155,8 @@ BSTR* p ) { domdoctype *This = impl_from_IXMLDOMDocumentType( iface ); - FIXME("(%p)->(%p): stub\n", This, p); - return E_NOTIMPL; + TRACE("(%p)->(%p)\n", This, p); + return node_get_nodeName(&This->node, p); } static HRESULT WINAPI domdoctype_get_nodeValue( @@ -489,8 +489,8 @@ BSTR *p) { domdoctype *This = impl_from_IXMLDOMDocumentType( iface ); - FIXME("(%p)->(%p): stub\n", This, p); - return E_NOTIMPL; + TRACE("(%p)->(%p)\n", This, p); + return node_get_nodeName(&This->node, p); } static HRESULT WINAPI domdoctype_get_entities( diff -Nru wine1.7-1.7.28/dlls/msxml3/pi.c wine1.7-1.7.31/dlls/msxml3/pi.c --- wine1.7-1.7.28/dlls/msxml3/pi.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msxml3/pi.c 2014-11-14 13:28:17.000000000 +0000 @@ -685,7 +685,9 @@ static HRESULT dom_pi_get_named_item(const xmlNodePtr node, BSTR name, IXMLDOMNode **item) { FIXME("(%p)->(%s %p): stub\n", node, debugstr_w(name), item ); - return E_NOTIMPL; + if (item) + *item = NULL; + return S_FALSE; } static HRESULT dom_pi_set_named_item(xmlNodePtr node, IXMLDOMNode *newItem, IXMLDOMNode **namedItem) diff -Nru wine1.7-1.7.28/dlls/msxml3/tests/domdoc.c wine1.7-1.7.31/dlls/msxml3/tests/domdoc.c --- wine1.7-1.7.28/dlls/msxml3/tests/domdoc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/msxml3/tests/domdoc.c 2014-11-14 13:28:17.000000000 +0000 @@ -8912,9 +8912,12 @@ static void test_get_doctype(void) { + static const WCHAR emailW[] = {'e','m','a','i','l',0}; IXMLDOMDocumentType *doctype; IXMLDOMDocument *doc; + VARIANT_BOOL b; HRESULT hr; + BSTR s; doc = create_document(&IID_IXMLDOMDocument); @@ -8926,6 +8929,28 @@ ok(hr == S_FALSE, "got 0x%08x\n", hr); ok(doctype == NULL, "got %p\n", doctype); + hr = IXMLDOMDocument_loadXML(doc, _bstr_(szEmailXML), &b); + ok(b == VARIANT_TRUE, "failed to load XML string\n"); + + doctype = NULL; + hr = IXMLDOMDocument_get_doctype(doc, &doctype); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(doctype != NULL, "got %p\n", doctype); + + hr = IXMLDOMDocumentType_get_name(doctype, NULL); + ok(hr == E_INVALIDARG, "got 0x%08x\n", hr); + + hr = IXMLDOMDocumentType_get_name(doctype, &s); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(!lstrcmpW(emailW, s), "got name %s\n", wine_dbgstr_w(s)); + SysFreeString(s); + + hr = IXMLDOMDocumentType_get_nodeName(doctype, &s); + ok(hr == S_OK, "got 0x%08x\n", hr); + ok(!lstrcmpW(emailW, s), "got name %s\n", wine_dbgstr_w(s)); + SysFreeString(s); + + IXMLDOMDocumentType_Release(doctype); IXMLDOMDocument_Release(doc); } @@ -9127,6 +9152,11 @@ hr = IXMLDOMNode_get_attributes(node, &map); ok(hr == S_OK, "got %08x\n", hr); + node2 = (void*)0xdeadbeef; + hr = IXMLDOMNamedNodeMap_getNamedItem(map, _bstr_("attr"), &node2); + ok(hr == S_FALSE, "got %08x\n", hr); + ok(node2 == NULL, "got %p\n", node2); + length = -1; hr = IXMLDOMNamedNodeMap_get_length(map, &length); EXPECT_HR(hr, S_OK); diff -Nru wine1.7-1.7.28/dlls/ndis.sys/main.c wine1.7-1.7.31/dlls/ndis.sys/main.c --- wine1.7-1.7.28/dlls/ndis.sys/main.c 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/ndis.sys/main.c 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,40 @@ +/* + * ndis.sys + * + * Copyright 2014 Austin English + * + * 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 + +#include "windef.h" +#include "winbase.h" + +BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved) +{ + switch (reason) + { + case DLL_WINE_PREATTACH: + return FALSE; /* prefer native version */ + case DLL_PROCESS_ATTACH: + DisableThreadLibraryCalls(instance); + break; + } + + return TRUE; +} diff -Nru wine1.7-1.7.28/dlls/ndis.sys/Makefile.in wine1.7-1.7.31/dlls/ndis.sys/Makefile.in --- wine1.7-1.7.28/dlls/ndis.sys/Makefile.in 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/ndis.sys/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,4 @@ +MODULE = ndis.sys + +C_SRCS = \ + main.c diff -Nru wine1.7-1.7.28/dlls/ndis.sys/ndis.sys.spec wine1.7-1.7.31/dlls/ndis.sys/ndis.sys.spec --- wine1.7-1.7.28/dlls/ndis.sys/ndis.sys.spec 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/ndis.sys/ndis.sys.spec 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,276 @@ +@ stub ArcFilterDprIndicateReceive +@ stub ArcFilterDprIndicateReceiveComplete +@ stub EthFilterDprIndicateReceive +@ stub EthFilterDprIndicateReceiveComplete +@ stub FddiFilterDprIndicateReceive +@ stub FddiFilterDprIndicateReceiveComplete +@ stub NDIS_BUFFER_TO_SPAN_PAGES +@ stub NdisAcquireReadWriteLock +@ stub NdisAcquireSpinLock +@ stub NdisAdjustBufferLength +@ stub NdisAllocateBuffer +@ stub NdisAllocateBufferPool +@ stub NdisAllocateFromBlockPool +@ stub NdisAllocateMemory +@ stub NdisAllocateMemoryWithTag +@ stub NdisAllocatePacket +@ stub NdisAllocatePacketPool +@ stub NdisAllocatePacketPoolEx +@ stub NdisAllocateSpinLock +@ stub NdisAnsiStringToUnicodeString +@ stub NdisBufferLength +@ stub NdisBufferVirtualAddress +@ stub NdisCancelSendPackets +@ stub NdisCancelTimer +@ stub NdisClAddParty +@ stub NdisClCloseAddressFamily +@ stub NdisClCloseCall +@ stub NdisClDeregisterSap +@ stub NdisClDropParty +@ stub NdisClGetProtocolVcContextFromTapiCallId +@ stub NdisClIncomingCallComplete +@ stub NdisClMakeCall +@ stub NdisClModifyCallQoS +@ stub NdisClOpenAddressFamily +@ stub NdisClRegisterSap +@ stub NdisCloseAdapter +@ stub NdisCloseConfiguration +@ stub NdisCloseFile +@ stub NdisCmActivateVc +@ stub NdisCmAddPartyComplete +@ stub NdisCmCloseAddressFamilyComplete +@ stub NdisCmCloseCallComplete +@ stub NdisCmDeactivateVc +@ stub NdisCmDeregisterSapComplete +@ stub NdisCmDispatchCallConnected +@ stub NdisCmDispatchIncomingCall +@ stub NdisCmDispatchIncomingCallQoSChange +@ stub NdisCmDispatchIncomingCloseCall +@ stub NdisCmDispatchIncomingDropParty +@ stub NdisCmDropPartyComplete +@ stub NdisCmMakeCallComplete +@ stub NdisCmModifyCallQoSComplete +@ stub NdisCmOpenAddressFamilyComplete +@ stub NdisCmRegisterAddressFamily +@ stub NdisCmRegisterSapComplete +@ stub NdisCoAssignInstanceName +@ stub NdisCoCreateVc +@ stub NdisCoDeleteVc +@ stub NdisCoGetTapiCallId +@ stub NdisCoRequest +@ stub NdisCoRequestComplete +@ stub NdisCoSendPackets +@ stub NdisCompareAnsiString +@ stub NdisCompareUnicodeString +@ stub NdisCompleteBindAdapter +@ stub NdisCompleteDmaTransfer +@ stub NdisCompletePnPEvent +@ stub NdisCompleteUnbindAdapter +@ stub NdisConvertStringToAtmAddress +@ stub NdisCopyBuffer +@ stub NdisCopyFromPacketToPacket +@ stub NdisCopyFromPacketToPacketSafe +@ stub NdisCreateBlockPool +@ stub NdisDeregisterProtocol +@ stub NdisDeregisterTdiCallBack +@ stub NdisDestroyBlockPool +@ stub NdisDprAcquireSpinLock +@ stub NdisDprAllocatePacket +@ stub NdisDprAllocatePacketNonInterlocked +@ stub NdisDprFreePacket +@ stub NdisDprFreePacketNonInterlocked +@ stub NdisDprReleaseSpinLock +@ stub NdisEqualString +@ stub NdisFreeBuffer +@ stub NdisFreeBufferPool +@ stub NdisFreeMemory +@ stub NdisFreePacket +@ stub NdisFreePacketPool +@ stub NdisFreeSpinLock +@ stub NdisFreeToBlockPool +@ stub NdisGeneratePartialCancelId +@ stub NdisGetBufferPhysicalArraySize +@ stub NdisGetCurrentProcessorCounts +@ stub NdisGetCurrentProcessorCpuUsage +@ stub NdisGetCurrentSystemTime +@ stub NdisGetDriverHandle +@ stub NdisGetFirstBufferFromPacket +@ stub NdisGetFirstBufferFromPacketSafe +@ stub NdisGetPacketCancelId +@ stub NdisGetPoolFromPacket +@ stub NdisGetReceivedPacket +@ stub NdisGetRoutineAddress +@ stub NdisGetSharedDataAlignment +@ stub NdisGetSystemUpTime +@ stub NdisGetVersion +@ stub NdisIMAssociateMiniport +@ stub NdisIMCancelInitializeDeviceInstance +@ stub NdisIMCopySendCompletePerPacketInfo +@ stub NdisIMCopySendPerPacketInfo +@ stub NdisIMDeInitializeDeviceInstance +@ stub NdisIMDeregisterLayeredMiniport +@ stub NdisIMGetBindingContext +@ stub NdisIMGetCurrentPacketStack +@ stub NdisIMGetDeviceContext +@ stub NdisIMInitializeDeviceInstance +@ stub NdisIMInitializeDeviceInstanceEx +@ stub NdisIMNotifyPnPEvent +@ stub NdisIMQueueMiniportCallback +@ stub NdisIMRegisterLayeredMiniport +@ stub NdisIMRevertBack +@ stub NdisIMSwitchToMiniport +@ stub NdisImmediateReadPciSlotInformation +@ stub NdisImmediateReadPortUchar +@ stub NdisImmediateReadPortUlong +@ stub NdisImmediateReadPortUshort +@ stub NdisImmediateReadSharedMemory +@ stub NdisImmediateWritePciSlotInformation +@ stub NdisImmediateWritePortUchar +@ stub NdisImmediateWritePortUlong +@ stub NdisImmediateWritePortUshort +@ stub NdisImmediateWriteSharedMemory +@ stub NdisInitAnsiString +@ stub NdisInitUnicodeString +@ stub NdisInitializeEvent +@ stub NdisInitializeReadWriteLock +@ stub NdisInitializeString +@ stub NdisInitializeTimer +@ stub NdisInitializeWrapper +@ stub NdisInterlockedAddLargeInterger +@ stub NdisInterlockedAddUlong +@ stub NdisInterlockedDecrement +@ stub NdisInterlockedIncrement +@ stub NdisInterlockedInsertHeadList +@ stub NdisInterlockedInsertTailList +@ stub NdisInterlockedPopEntryList +@ stub NdisInterlockedPushEntryList +@ stub NdisInterlockedRemoveHeadList +@ stub NdisMAllocateMapRegisters +@ stub NdisMAllocateSharedMemory +@ stub NdisMAllocateSharedMemoryAsync +@ stub NdisMCancelTimer +@ stub NdisMCloseLog +@ stub NdisMCmActivateVc +@ stub NdisMCmCreateVc +@ stub NdisMCmDeactivateVc +@ stub NdisMCmDeleteVc +@ stub NdisMCmRegisterAddressFamily +@ stub NdisMCmRequest +@ stub NdisMCoActivateVcComplete +@ stub NdisMCoDeactivateVcComplete +@ stub NdisMCoIndicateReceivePacket +@ stub NdisMCoIndicateStatus +@ stub NdisMCoReceiveComplete +@ stub NdisMCoRequestComplete +@ stub NdisMCoSendComplete +@ stub NdisMCompleteBufferPhysicalMapping +@ stub NdisMCreateLog +@ stub NdisMDeregisterAdapterShutdownHandler +@ stub NdisMDeregisterDevice +@ stub NdisMDeregisterDmaChannel +@ stub NdisMDeregisterInterrupt +@ stub NdisMDeregisterIoPortRange +@ stub NdisMFlushLog +@ stub NdisMFreeMapRegisters +@ stub NdisMFreeSharedMemory +@ stub NdisMGetDeviceProperty +@ stub NdisMGetDmaAlignment +@ stub NdisMIndicateStatus +@ stub NdisMIndicateStatusComplete +@ stub NdisMInitializeScatterGatherDma +@ stub NdisMInitializeTimer +@ stub NdisMMapIoSpace +@ stub NdisMPciAssignResources +@ stub NdisMPromoteMiniport +@ stub NdisMQueryAdapterInstanceName +@ stub NdisMQueryAdapterResources +@ stub NdisMQueryInformationComplete +@ stub NdisMReadDmaCounter +@ stub NdisMRegisterAdapterShutdownHandler +@ stub NdisMRegisterDevice +@ stub NdisMRegisterDmaChannel +@ stub NdisMRegisterInterrupt +@ stub NdisMRegisterIoPortRange +@ stub NdisMRegisterMiniport +@ stub NdisMRegisterUnloadHandler +@ stub NdisMRemoveMiniport +@ stub NdisMResetComplete +@ stub NdisMSendComplete +@ stub NdisMSendResourcesAvailable +@ stub NdisMSetAttributes +@ stub NdisMSetAttributesEx +@ stub NdisMSetInformationComplete +@ stub NdisMSetMiniportSecondary +@ stub NdisMSetPeriodicTimer +@ stub NdisMSetTimer +@ stub NdisMSleep +@ stub NdisMStartBufferPhysicalMapping +@ stub NdisMSynchronizeWithInterrupt +@ stub NdisMTransferDataComplete +@ stub NdisMUnmapIoSpace +@ stub NdisMWanIndicateReceive +@ stub NdisMWanIndicateReceiveComplete +@ stub NdisMWanSendComplete +@ stub NdisMWriteLogData +@ stub NdisMapFile +@ stub NdisMatchPdoWithPacket +@ stub NdisOpenAdapter +@ stub NdisOpenConfiguration +@ stub NdisOpenConfigurationKeyByIndex +@ stub NdisOpenConfigurationKeyByName +@ stub NdisOpenFile +@ stub NdisOpenProtocolConfiguration +@ stub NdisOverrideBusNumber +@ stub NdisPacketPoolUsage +@ stub NdisPacketSize +@ stub NdisQueryAdapterInstanceName +@ stub NdisQueryBindInstanceName +@ stub NdisQueryBuffer +@ stub NdisQueryBufferOffset +@ stub NdisQueryBufferSafe +@ stub NdisQueryMapRegisterCount +@ stub NdisQueryPendingIOCount +@ stub NdisReEnumerateProtocolBindings +@ stub NdisReadConfiguration +@ stub NdisReadEisaSlotInformation +@ stub NdisReadEisaSlotInformationEx +@ stub NdisReadMcaPosInformation +@ stub NdisReadNetworkAddress +@ stub NdisReadPciSlotInformation +@ stub NdisReadPcmciaAttributeMemory +@ stub NdisRegisterProtocol +@ stub NdisRegisterTdiCallBack +@ stub NdisReleaseReadWriteLock +@ stub NdisReleaseSpinLock +@ stub NdisRequest +@ stub NdisReset +@ stub NdisResetEvent +@ stub NdisReturnPackets +@ stub NdisScheduleWorkItem +@ stub NdisSend +@ stub NdisSendPackets +@ stub NdisSetEvent +@ stub NdisSetPacketCancelId +@ stub NdisSetPacketPoolProtocolId +@ stub NdisSetPacketStatus +@ stub NdisSetProtocolFilter +@ stub NdisSetTimer +@ stub NdisSetTimerEx +@ stub NdisSetupDmaTransfer +@ stub NdisSystemProcessorCount +@ stub NdisTerminateWrapper +@ stub NdisTransferData +@ stub NdisUnchainBufferAtBack +@ stub NdisUnchainBufferAtFront +@ stub NdisUnicodeStringToAnsiString +@ stub NdisUnmapFile +@ stub NdisUpcaseUnicodeString +@ stub NdisUpdateSharedMemory +@ stub NdisWaitEvent +@ stub NdisWriteConfiguration +@ stub NdisWriteErrorLogEntry +@ stub NdisWriteEventLogEntry +@ stub NdisWritePciSlotInformation +@ stub NdisWritePcmciaAttributeMemory +@ stub TrFilterDprIndicateReceive +@ stub TrFilterDprIndicateReceiveComplete diff -Nru wine1.7-1.7.28/dlls/ntdll/exception.c wine1.7-1.7.31/dlls/ntdll/exception.c --- wine1.7-1.7.28/dlls/ntdll/exception.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/exception.c 2014-11-14 13:28:17.000000000 +0000 @@ -47,7 +47,8 @@ ULONG count; } VECTORED_HANDLER; -static struct list vectored_handlers = LIST_INIT(vectored_handlers); +static struct list vectored_exception_handlers = LIST_INIT(vectored_exception_handlers); +static struct list vectored_continue_handlers = LIST_INIT(vectored_continue_handlers); static RTL_CRITICAL_SECTION vectored_handlers_section; static RTL_CRITICAL_SECTION_DEBUG critsect_debug = @@ -58,6 +59,47 @@ }; static RTL_CRITICAL_SECTION vectored_handlers_section = { &critsect_debug, -1, 0, 0, 0, 0 }; + +static VECTORED_HANDLER *add_vectored_handler( struct list *handler_list, ULONG first, + PVECTORED_EXCEPTION_HANDLER func ) +{ + VECTORED_HANDLER *handler = RtlAllocateHeap( GetProcessHeap(), 0, sizeof(*handler) ); + if (handler) + { + handler->func = RtlEncodePointer( func ); + handler->count = 1; + RtlEnterCriticalSection( &vectored_handlers_section ); + if (first) list_add_head( handler_list, &handler->entry ); + else list_add_tail( handler_list, &handler->entry ); + RtlLeaveCriticalSection( &vectored_handlers_section ); + } + return handler; +} + + +static ULONG remove_vectored_handler( struct list *handler_list, VECTORED_HANDLER *handler ) +{ + struct list *ptr; + ULONG ret = FALSE; + + RtlEnterCriticalSection( &vectored_handlers_section ); + LIST_FOR_EACH( ptr, handler_list ) + { + VECTORED_HANDLER *curr_handler = LIST_ENTRY( ptr, VECTORED_HANDLER, entry ); + if (curr_handler == handler) + { + if (!--curr_handler->count) list_remove( ptr ); + else handler = NULL; /* don't free it yet */ + ret = TRUE; + break; + } + } + RtlLeaveCriticalSection( &vectored_handlers_section ); + if (ret) RtlFreeHeap( GetProcessHeap(), 0, handler ); + return ret; +} + + /********************************************************************** * wait_suspend * @@ -165,7 +207,7 @@ except_ptrs.ContextRecord = context; RtlEnterCriticalSection( &vectored_handlers_section ); - ptr = list_head( &vectored_handlers ); + ptr = list_head( &vectored_exception_handlers ); while (ptr) { handler = LIST_ENTRY( ptr, VECTORED_HANDLER, entry ); @@ -181,7 +223,7 @@ TRACE( "handler at %p returned %x\n", func, ret ); RtlEnterCriticalSection( &vectored_handlers_section ); - ptr = list_next( &vectored_handlers, ptr ); + ptr = list_next( &vectored_exception_handlers, ptr ); if (!--handler->count) /* removed during execution */ { list_remove( &handler->entry ); @@ -224,21 +266,29 @@ /******************************************************************* + * RtlAddVectoredContinueHandler (NTDLL.@) + */ +PVOID WINAPI RtlAddVectoredContinueHandler( ULONG first, PVECTORED_EXCEPTION_HANDLER func ) +{ + return add_vectored_handler( &vectored_continue_handlers, first, func ); +} + + +/******************************************************************* + * RtlRemoveVectoredContinueHandler (NTDLL.@) + */ +ULONG WINAPI RtlRemoveVectoredContinueHandler( PVOID handler ) +{ + return remove_vectored_handler( &vectored_continue_handlers, handler ); +} + + +/******************************************************************* * RtlAddVectoredExceptionHandler (NTDLL.@) */ PVOID WINAPI RtlAddVectoredExceptionHandler( ULONG first, PVECTORED_EXCEPTION_HANDLER func ) { - VECTORED_HANDLER *handler = RtlAllocateHeap( GetProcessHeap(), 0, sizeof(*handler) ); - if (handler) - { - handler->func = RtlEncodePointer( func ); - handler->count = 1; - RtlEnterCriticalSection( &vectored_handlers_section ); - if (first) list_add_head( &vectored_handlers, &handler->entry ); - else list_add_tail( &vectored_handlers, &handler->entry ); - RtlLeaveCriticalSection( &vectored_handlers_section ); - } - return handler; + return add_vectored_handler( &vectored_exception_handlers, first, func ); } @@ -247,24 +297,7 @@ */ ULONG WINAPI RtlRemoveVectoredExceptionHandler( PVOID handler ) { - struct list *ptr; - ULONG ret = FALSE; - - RtlEnterCriticalSection( &vectored_handlers_section ); - LIST_FOR_EACH( ptr, &vectored_handlers ) - { - VECTORED_HANDLER *curr_handler = LIST_ENTRY( ptr, VECTORED_HANDLER, entry ); - if (curr_handler == handler) - { - if (!--curr_handler->count) list_remove( ptr ); - else handler = NULL; /* don't free it yet */ - ret = TRUE; - break; - } - } - RtlLeaveCriticalSection( &vectored_handlers_section ); - if (ret) RtlFreeHeap( GetProcessHeap(), 0, handler ); - return ret; + return remove_vectored_handler( &vectored_exception_handlers, handler ); } diff -Nru wine1.7-1.7.28/dlls/ntdll/file.c wine1.7-1.7.31/dlls/ntdll/file.c --- wine1.7-1.7.28/dlls/ntdll/file.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/file.c 2014-11-14 13:28:17.000000000 +0000 @@ -3043,7 +3043,9 @@ ULONG inbound_quota, ULONG outbound_quota, PLARGE_INTEGER timeout) { - NTSTATUS status; + struct security_descriptor *sd = NULL; + struct object_attributes objattr; + NTSTATUS status; TRACE("(%p %x %s %p %x %d %x %d %d %d %d %d %d %p)\n", handle, access, debugstr_w(attr->ObjectName->Buffer), iosb, sharing, dispo, @@ -3054,11 +3056,17 @@ if (timeout->QuadPart > 0) FIXME("Wrong time %s\n", wine_dbgstr_longlong(timeout->QuadPart)); + objattr.rootdir = wine_server_obj_handle( attr->RootDirectory ); + objattr.sd_len = 0; + objattr.name_len = attr->ObjectName->Length; + + status = NTDLL_create_struct_sd( attr->SecurityDescriptor, &sd, &objattr.sd_len ); + if (status != STATUS_SUCCESS) return status; + SERVER_START_REQ( create_named_pipe ) { req->access = access; req->attributes = attr->Attributes; - req->rootdir = wine_server_obj_handle( attr->RootDirectory ); req->options = options; req->sharing = sharing; req->flags = @@ -3069,12 +3077,15 @@ req->outsize = outbound_quota; req->insize = inbound_quota; req->timeout = timeout->QuadPart; - wine_server_add_data( req, attr->ObjectName->Buffer, - attr->ObjectName->Length ); + wine_server_add_data( req, &objattr, sizeof(objattr) ); + if (objattr.sd_len) wine_server_add_data( req, sd, objattr.sd_len ); + wine_server_add_data( req, attr->ObjectName->Buffer, attr->ObjectName->Length ); status = wine_server_call( req ); if (!status) *handle = wine_server_ptr_handle( reply->handle ); } SERVER_END_REQ; + + NTDLL_free_struct_sd( sd ); return status; } diff -Nru wine1.7-1.7.28/dlls/ntdll/loader.c wine1.7-1.7.31/dlls/ntdll/loader.c --- wine1.7-1.7.28/dlls/ntdll/loader.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/loader.c 2014-11-14 13:28:17.000000000 +0000 @@ -934,9 +934,10 @@ else p = wm->ldr.FullDllName.Buffer; RtlInitUnicodeString( &wm->ldr.BaseDllName, p ); - if ((nt->FileHeader.Characteristics & IMAGE_FILE_DLL) && !is_dll_native_subsystem( hModule, nt, p )) + if (!(nt->FileHeader.Characteristics & IMAGE_FILE_DLL) || !is_dll_native_subsystem( hModule, nt, p )) { - wm->ldr.Flags |= LDR_IMAGE_IS_DLL; + if (nt->FileHeader.Characteristics & IMAGE_FILE_DLL) + wm->ldr.Flags |= LDR_IMAGE_IS_DLL; if (nt->OptionalHeader.AddressOfEntryPoint) wm->ldr.EntryPoint = (char *)hModule + nt->OptionalHeader.AddressOfEntryPoint; } @@ -1062,7 +1063,7 @@ if (wm->ldr.Flags & LDR_DONT_RESOLVE_REFS) return STATUS_SUCCESS; if (wm->ldr.TlsIndex != -1) call_tls_callbacks( wm->ldr.BaseAddress, reason ); - if (!entry) return STATUS_SUCCESS; + if (!entry || !(wm->ldr.Flags & LDR_IMAGE_IS_DLL)) return STATUS_SUCCESS; if (TRACE_ON(relay)) { @@ -2641,8 +2642,8 @@ free_tls_slot( &wm->ldr ); RtlReleaseActivationContext( wm->ldr.ActivationContext ); - NtUnmapViewOfSection( NtCurrentProcess(), wm->ldr.BaseAddress ); if (wm->ldr.Flags & LDR_WINE_INTERNAL) wine_dll_unload( wm->ldr.SectionHandle ); + NtUnmapViewOfSection( NtCurrentProcess(), wm->ldr.BaseAddress ); if (cached_modref == wm) cached_modref = NULL; RtlFreeUnicodeString( &wm->ldr.FullDllName ); RtlFreeHeap( GetProcessHeap(), 0, wm->deps ); diff -Nru wine1.7-1.7.28/dlls/ntdll/ntdll_misc.h wine1.7-1.7.31/dlls/ntdll/ntdll_misc.h --- wine1.7-1.7.28/dlls/ntdll/ntdll_misc.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/ntdll_misc.h 2014-11-14 13:28:17.000000000 +0000 @@ -169,6 +169,8 @@ extern NTSTATUS virtual_handle_fault( LPCVOID addr, DWORD err ) DECLSPEC_HIDDEN; extern BOOL virtual_check_buffer_for_read( const void *ptr, SIZE_T size ) DECLSPEC_HIDDEN; extern BOOL virtual_check_buffer_for_write( void *ptr, SIZE_T size ) DECLSPEC_HIDDEN; +extern SIZE_T virtual_uninterrupted_read_memory( const void *addr, void *buffer, SIZE_T size ) DECLSPEC_HIDDEN; +extern SIZE_T virtual_uninterrupted_write_memory( void *addr, const void *buffer, SIZE_T size ) DECLSPEC_HIDDEN; extern void VIRTUAL_SetForceExec( BOOL enable ) DECLSPEC_HIDDEN; extern void virtual_release_address_space(void) DECLSPEC_HIDDEN; extern void virtual_set_large_address_space(void) DECLSPEC_HIDDEN; diff -Nru wine1.7-1.7.28/dlls/ntdll/ntdll.spec wine1.7-1.7.31/dlls/ntdll/ntdll.spec --- wine1.7-1.7.28/dlls/ntdll/ntdll.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/ntdll.spec 2014-11-14 13:28:17.000000000 +0000 @@ -415,6 +415,7 @@ @ cdecl -arch=arm,x86_64 RtlAddFunctionTable(ptr long long) @ stdcall RtlAddRefActivationContext(ptr) # @ stub RtlAddRefMemoryStream +@ stdcall RtlAddVectoredContinueHandler(long ptr) @ stdcall RtlAddVectoredExceptionHandler(long ptr) # @ stub RtlAddressInSectionTable @ stdcall RtlAdjustPrivilege(long long long ptr) @@ -819,6 +820,7 @@ @ stdcall RtlReleaseSRWLockExclusive(ptr) @ stdcall RtlReleaseSRWLockShared(ptr) @ stub RtlRemoteCall +@ stdcall RtlRemoveVectoredContinueHandler(ptr) @ stdcall RtlRemoveVectoredExceptionHandler(ptr) @ stub RtlResetRtlTranslations @ stdcall RtlRestoreLastWin32Error(long) RtlSetLastWin32Error diff -Nru wine1.7-1.7.28/dlls/ntdll/signal_i386.c wine1.7-1.7.31/dlls/ntdll/signal_i386.c --- wine1.7-1.7.28/dlls/ntdll/signal_i386.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/signal_i386.c 2014-11-14 13:28:17.000000000 +0000 @@ -1616,12 +1616,46 @@ #include "pshpack1.h" -struct atl_thunk +union atl_thunk { - DWORD movl; /* movl this,4(%esp) */ - DWORD this; - BYTE jmp; /* jmp func */ - int func; + struct + { + DWORD movl; /* movl this,4(%esp) */ + DWORD this; + BYTE jmp; /* jmp func */ + int func; + } t1; + struct + { + BYTE movl; /* movl this,ecx */ + DWORD this; + BYTE jmp; /* jmp func */ + int func; + } t2; + struct + { + BYTE movl1; /* movl this,edx */ + DWORD this; + BYTE movl2; /* movl func,ecx */ + DWORD func; + WORD jmp; /* jmp ecx */ + } t3; + struct + { + BYTE movl1; /* movl this,ecx */ + DWORD this; + BYTE movl2; /* movl func,eax */ + DWORD func; + WORD jmp; /* jmp eax */ + } t4; + struct + { + DWORD inst1; /* pop ecx + * pop eax + * push ecx + * jmp 4(%eax) */ + WORD inst2; + } t5; }; #include "poppack.h" @@ -1632,28 +1666,78 @@ */ static BOOL check_atl_thunk( EXCEPTION_RECORD *rec, CONTEXT *context ) { - const struct atl_thunk *thunk = (const struct atl_thunk *)rec->ExceptionInformation[1]; - BOOL ret = FALSE; + const union atl_thunk *thunk = (const union atl_thunk *)rec->ExceptionInformation[1]; + union atl_thunk thunk_copy; + SIZE_T thunk_len; - if (!virtual_is_valid_code_address( thunk, sizeof(*thunk) )) return FALSE; + thunk_len = virtual_uninterrupted_read_memory( thunk, &thunk_copy, sizeof(*thunk) ); + if (!thunk_len) return FALSE; - __TRY + if (thunk_len >= sizeof(thunk_copy.t1) && thunk_copy.t1.movl == 0x042444c7 && + thunk_copy.t1.jmp == 0xe9) { - if (thunk->movl == 0x042444c7 && thunk->jmp == 0xe9) + if (virtual_uninterrupted_write_memory( (DWORD *)context->Esp + 1, + &thunk_copy.t1.this, sizeof(DWORD) ) == sizeof(DWORD)) { - *((DWORD *)context->Esp + 1) = thunk->this; - context->Eip = (DWORD_PTR)(&thunk->func + 1) + thunk->func; - TRACE( "emulating ATL thunk at %p, func=%08x arg=%08x\n", - thunk, context->Eip, *((DWORD *)context->Esp + 1) ); - ret = TRUE; + context->Eip = (DWORD_PTR)(&thunk->t1.func + 1) + thunk_copy.t1.func; + TRACE( "emulating ATL thunk type 1 at %p, func=%08x arg=%08x\n", + thunk, context->Eip, thunk_copy.t1.this ); + return TRUE; } } - __EXCEPT_PAGE_FAULT + else if (thunk_len >= sizeof(thunk_copy.t2) && thunk_copy.t2.movl == 0xb9 && + thunk_copy.t2.jmp == 0xe9) + { + context->Ecx = thunk_copy.t2.this; + context->Eip = (DWORD_PTR)(&thunk->t2.func + 1) + thunk_copy.t2.func; + TRACE( "emulating ATL thunk type 2 at %p, func=%08x ecx=%08x\n", + thunk, context->Eip, context->Ecx ); + return TRUE; + } + else if (thunk_len >= sizeof(thunk_copy.t3) && thunk_copy.t3.movl1 == 0xba && + thunk_copy.t3.movl2 == 0xb9 && + thunk_copy.t3.jmp == 0xe1ff) + { + context->Edx = thunk_copy.t3.this; + context->Ecx = thunk_copy.t3.func; + context->Eip = thunk_copy.t3.func; + TRACE( "emulating ATL thunk type 3 at %p, func=%08x ecx=%08x edx=%08x\n", + thunk, context->Eip, context->Ecx, context->Edx ); + return TRUE; + } + else if (thunk_len >= sizeof(thunk_copy.t4) && thunk_copy.t4.movl1 == 0xb9 && + thunk_copy.t4.movl2 == 0xb8 && + thunk_copy.t4.jmp == 0xe0ff) { - return FALSE; + context->Ecx = thunk_copy.t4.this; + context->Eax = thunk_copy.t4.func; + context->Eip = thunk_copy.t4.func; + TRACE( "emulating ATL thunk type 4 at %p, func=%08x eax=%08x ecx=%08x\n", + thunk, context->Eip, context->Eax, context->Ecx ); + return TRUE; } - __ENDTRY - return ret; + else if (thunk_len >= sizeof(thunk_copy.t5) && thunk_copy.t5.inst1 == 0xff515859 && + thunk_copy.t5.inst2 == 0x0460) + { + DWORD func, stack[2]; + if (virtual_uninterrupted_read_memory( (DWORD *)context->Esp, + stack, sizeof(stack) ) == sizeof(stack) && + virtual_uninterrupted_read_memory( (DWORD *)stack[1] + 1, + &func, sizeof(DWORD) ) == sizeof(DWORD) && + virtual_uninterrupted_write_memory( (DWORD *)context->Esp + 1, + &stack[0], sizeof(stack[0]) ) == sizeof(stack[0])) + { + context->Ecx = stack[0]; + context->Eax = stack[1]; + context->Esp = context->Esp + sizeof(DWORD); + context->Eip = func; + TRACE( "emulating ATL thunk type 5 at %p, func=%08x eax=%08x ecx=%08x esp=%08x\n", + thunk, context->Eip, context->Eax, context->Ecx, context->Esp ); + return TRUE; + } + } + + return FALSE; } @@ -1821,19 +1905,22 @@ case EXCEPTION_ACCESS_VIOLATION: if (rec->NumberParameters == 2) { - if (rec->ExceptionInformation[0] == EXCEPTION_EXECUTE_FAULT && check_atl_thunk( rec, context )) - goto done; if (rec->ExceptionInformation[1] == 0xffffffff && check_invalid_gs( context )) goto done; if (!(rec->ExceptionCode = virtual_handle_fault( (void *)rec->ExceptionInformation[1], rec->ExceptionInformation[0] ))) goto done; - /* send EXCEPTION_EXECUTE_FAULT only if data execution prevention is enabled */ - if (rec->ExceptionInformation[0] == EXCEPTION_EXECUTE_FAULT) + if (rec->ExceptionCode == EXCEPTION_ACCESS_VIOLATION && + rec->ExceptionInformation[0] == EXCEPTION_EXECUTE_FAULT) { ULONG flags; NtQueryInformationProcess( GetCurrentProcess(), ProcessExecuteFlags, &flags, sizeof(flags), NULL ); + + if (!(flags & MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION) && check_atl_thunk( rec, context )) + goto done; + + /* send EXCEPTION_EXECUTE_FAULT only if data execution prevention is enabled */ if (!(flags & MEM_EXECUTE_OPTION_DISABLE)) rec->ExceptionInformation[0] = EXCEPTION_READ_FAULT; } diff -Nru wine1.7-1.7.28/dlls/ntdll/tests/exception.c wine1.7-1.7.31/dlls/ntdll/tests/exception.c --- wine1.7-1.7.28/dlls/ntdll/tests/exception.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/tests/exception.c 2014-11-14 13:28:17.000000000 +0000 @@ -46,6 +46,8 @@ static PVOID (WINAPI *pRtlUnwind)(PVOID, PVOID, PEXCEPTION_RECORD, PVOID); static PVOID (WINAPI *pRtlAddVectoredExceptionHandler)(ULONG first, PVECTORED_EXCEPTION_HANDLER func); static ULONG (WINAPI *pRtlRemoveVectoredExceptionHandler)(PVOID handler); +static PVOID (WINAPI *pRtlAddVectoredContinueHandler)(ULONG first, PVECTORED_EXCEPTION_HANDLER func); +static ULONG (WINAPI *pRtlRemoveVectoredContinueHandler)(PVOID handler); static NTSTATUS (WINAPI *pNtReadVirtualMemory)(HANDLE, const void*, void*, SIZE_T, SIZE_T*); static NTSTATUS (WINAPI *pNtTerminateProcess)(HANDLE handle, LONG exit_code); static NTSTATUS (WINAPI *pNtQueryInformationProcess)(HANDLE, PROCESSINFOCLASS, PVOID, ULONG, PULONG); @@ -1695,6 +1697,7 @@ #endif /* __x86_64__ */ +#if defined(__i386__) || defined(__x86_64__) static DWORD outputdebugstring_exceptions; static LONG CALLBACK outputdebugstring_vectored_handler(EXCEPTION_POINTERS *ExceptionInfo) @@ -1788,6 +1791,44 @@ pRtlRemoveVectoredExceptionHandler(vectored_handler); } +static void test_vectored_continue_handler(void) +{ + PVOID handler1, handler2; + ULONG ret; + + if (!pRtlAddVectoredContinueHandler || !pRtlRemoveVectoredContinueHandler) + { + skip("RtlAddVectoredContinueHandler or RtlRemoveVectoredContinueHandler not found\n"); + return; + } + + handler1 = pRtlAddVectoredContinueHandler(TRUE, (void *)0xdeadbeef); + ok(handler1 != 0, "RtlAddVectoredContinueHandler failed\n"); + + handler2 = pRtlAddVectoredContinueHandler(TRUE, (void *)0xdeadbeef); + ok(handler2 != 0, "RtlAddVectoredContinueHandler failed\n"); + ok(handler1 != handler2, "RtlAddVectoredContinueHandler returned same handler\n"); + + if (pRtlRemoveVectoredExceptionHandler) + { + ret = pRtlRemoveVectoredExceptionHandler(handler1); + ok(!ret, "RtlRemoveVectoredExceptionHandler succeeded\n"); + } + + ret = pRtlRemoveVectoredContinueHandler(handler1); + ok(ret, "RtlRemoveVectoredContinueHandler failed\n"); + + ret = pRtlRemoveVectoredContinueHandler(handler2); + ok(ret, "RtlRemoveVectoredContinueHandler failed\n"); + + ret = pRtlRemoveVectoredContinueHandler(handler1); + ok(!ret, "RtlRemoveVectoredContinueHandler succeeded\n"); + + ret = pRtlRemoveVectoredContinueHandler((void *)0x11223344); + ok(!ret, "RtlRemoveVectoredContinueHandler succeeded\n"); +} +#endif /* defined(__i386__) || defined(__x86_64__) */ + START_TEST(exception) { HMODULE hntdll = GetModuleHandleA("ntdll.dll"); @@ -1809,6 +1850,10 @@ "RtlAddVectoredExceptionHandler" ); pRtlRemoveVectoredExceptionHandler = (void *)GetProcAddress( hntdll, "RtlRemoveVectoredExceptionHandler" ); + pRtlAddVectoredContinueHandler = (void *)GetProcAddress( hntdll, + "RtlAddVectoredContinueHandler" ); + pRtlRemoveVectoredContinueHandler = (void *)GetProcAddress( hntdll, + "RtlRemoveVectoredContinueHandler" ); pNtQueryInformationProcess = (void*)GetProcAddress( hntdll, "NtQueryInformationProcess" ); pNtSetInformationProcess = (void*)GetProcAddress( hntdll, @@ -1878,6 +1923,7 @@ test_rtlraiseexception(); test_outputdebugstring(1, FALSE); test_ripevent(1); + test_vectored_continue_handler(); test_debugger(); test_simd_exceptions(); test_fpu_exceptions(); @@ -1896,6 +1942,7 @@ test_outputdebugstring(1, FALSE); test_ripevent(1); + test_vectored_continue_handler(); test_virtual_unwind(); if (pRtlAddFunctionTable && pRtlDeleteFunctionTable && pRtlInstallFunctionTableCallback && pRtlLookupFunctionEntry) diff -Nru wine1.7-1.7.28/dlls/ntdll/tests/reg.c wine1.7-1.7.31/dlls/ntdll/tests/reg.c --- wine1.7-1.7.28/dlls/ntdll/tests/reg.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/tests/reg.c 2014-11-14 13:28:17.000000000 +0000 @@ -1285,7 +1285,7 @@ HANDLE key; NTSTATUS status; OBJECT_ATTRIBUTES attr; - ULONG len; + ULONG length, len; KEY_NAME_INFORMATION *info = NULL; UNICODE_STRING str; @@ -1293,21 +1293,30 @@ status = pNtOpenKey(&key, KEY_READ, &attr); ok(status == STATUS_SUCCESS, "NtOpenKey Failed: 0x%08x\n", status); - status = pNtQueryKey(key, KeyNameInformation, NULL, 0, &len); + status = pNtQueryKey(key, KeyNameInformation, NULL, 0, &length); if (status == STATUS_INVALID_PARAMETER) { win_skip("KeyNameInformation is not supported\n"); pNtClose(key); return; } todo_wine ok(status == STATUS_BUFFER_TOO_SMALL, "NtQueryKey Failed: 0x%08x\n", status); + info = HeapAlloc(GetProcessHeap(), 0, length); - info = HeapAlloc(GetProcessHeap(), 0, len); - status = pNtQueryKey(key, KeyNameInformation, info, len, &len); + /* non-zero buffer size, but insufficient */ + status = pNtQueryKey(key, KeyNameInformation, info, sizeof(*info), &len); + ok(status == STATUS_BUFFER_OVERFLOW, "NtQueryKey Failed: 0x%08x\n", status); + ok(length == len, "got %d, expected %d\n", len, length); + ok(info->NameLength == winetestpath.Length, "got %d, expected %d\n", + info->NameLength, winetestpath.Length); + + /* correct buffer size */ + status = pNtQueryKey(key, KeyNameInformation, info, length, &len); ok(status == STATUS_SUCCESS, "NtQueryKey Failed: 0x%08x\n", status); + ok(length == len, "got %d, expected %d\n", len, length); str.Buffer = info->Name; str.Length = info->NameLength; - todo_wine ok(pRtlCompareUnicodeString(&winetestpath, &str, TRUE) == 0, + ok(pRtlCompareUnicodeString(&winetestpath, &str, TRUE) == 0, "got %s, expected %s\n", wine_dbgstr_wn(str.Buffer, str.Length/sizeof(WCHAR)), wine_dbgstr_wn(winetestpath.Buffer, winetestpath.Length/sizeof(WCHAR))); diff -Nru wine1.7-1.7.28/dlls/ntdll/tests/string.c wine1.7-1.7.31/dlls/ntdll/tests/string.c --- wine1.7-1.7.28/dlls/ntdll/tests/string.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/tests/string.c 2014-11-14 13:28:17.000000000 +0000 @@ -1083,8 +1083,8 @@ result = p_atoi64(str2longlong[test_num].str); if (str2longlong[test_num].overflow) ok(result == str2longlong[test_num].value || - (result == (str2longlong[test_num].overflow == -1) ? - ULL(0x80000000,0x00000000) : ULL(0x7fffffff,0xffffffff)), + (result == ((str2longlong[test_num].overflow == -1) ? + ULL(0x80000000,0x00000000) : ULL(0x7fffffff,0xffffffff))), "(test %d): call failed: _atoi64(\"%s\") has result 0x%x%08x, expected: 0x%x%08x\n", test_num, str2longlong[test_num].str, (DWORD)(result >> 32), (DWORD)result, (DWORD)(str2longlong[test_num].value >> 32), (DWORD)str2longlong[test_num].value); @@ -1108,8 +1108,8 @@ result = p_wtoi64(uni.Buffer); if (str2longlong[test_num].overflow) ok(result == str2longlong[test_num].value || - (result == (str2longlong[test_num].overflow == -1) ? - ULL(0x80000000,0x00000000) : ULL(0x7fffffff,0xffffffff)), + (result == ((str2longlong[test_num].overflow == -1) ? + ULL(0x80000000,0x00000000) : ULL(0x7fffffff,0xffffffff))), "(test %d): call failed: _atoi64(\"%s\") has result 0x%x%08x, expected: 0x%x%08x\n", test_num, str2longlong[test_num].str, (DWORD)(result >> 32), (DWORD)result, (DWORD)(str2longlong[test_num].value >> 32), (DWORD)str2longlong[test_num].value); diff -Nru wine1.7-1.7.28/dlls/ntdll/version.c wine1.7-1.7.31/dlls/ntdll/version.c --- wine1.7-1.7.28/dlls/ntdll/version.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/version.c 2014-11-14 13:28:17.000000000 +0000 @@ -57,6 +57,7 @@ WIN2K8R2,/* Windows 2008 R2 */ WIN7, /* Windows 7 */ WIN8, /* Windows 8 */ + WIN81, /* Windows 8.1 */ NB_WINDOWS_VERSIONS } WINDOWS_VERSION; @@ -177,6 +178,12 @@ {' ',0}, 0, 0, VER_SUITE_SINGLEUSERTS, VER_NT_WORKSTATION, 0 }, + /* WIN81 */ + { + sizeof(RTL_OSVERSIONINFOEXW), 6, 3, 0x2580, VER_PLATFORM_WIN32_NT, + {' ',0}, + 0, 0, VER_SUITE_SINGLEUSERTS, VER_NT_WORKSTATION, 0 + }, }; @@ -199,6 +206,7 @@ "win2008r2,win2k8r2", /* WIN2K8R2 */ "win7", /* WIN7 */ "win8", /* WIN8 */ + "win81", /* WIN81 */ }; diff -Nru wine1.7-1.7.28/dlls/ntdll/virtual.c wine1.7-1.7.31/dlls/ntdll/virtual.c --- wine1.7-1.7.28/dlls/ntdll/virtual.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdll/virtual.c 2014-11-14 13:28:17.000000000 +0000 @@ -591,6 +591,25 @@ /*********************************************************************** + * mprotect_exec + * + * Wrapper for mprotect, adds PROT_EXEC if forced by force_exec_prot + */ +static inline int mprotect_exec( void *base, size_t size, int unix_prot, unsigned int view_protect ) +{ + if (force_exec_prot && !(view_protect & VPROT_NOEXEC) && + (unix_prot & PROT_READ) && !(unix_prot & PROT_EXEC)) + { + TRACE( "forcing exec permission on %p-%p\n", base, (char *)base + size - 1 ); + if (!mprotect( base, size, unix_prot | PROT_EXEC )) return 0; + /* exec + write may legitimately fail, in that case fall back to write only */ + if (!(unix_prot & PROT_WRITE)) return -1; + } + + return mprotect( base, size, unix_prot ); +} + +/*********************************************************************** * VIRTUAL_SetProt * * Change the protection of a range of pages. @@ -624,12 +643,12 @@ p[i] = vprot | (p[i] & VPROT_WRITEWATCH); prot = VIRTUAL_GetUnixProt( p[i] ); if (prot == unix_prot) continue; - mprotect( addr, count << page_shift, unix_prot ); + mprotect_exec( addr, count << page_shift, unix_prot, view->protect ); addr += count << page_shift; unix_prot = prot; count = 0; } - if (count) mprotect( addr, count << page_shift, unix_prot ); + if (count) mprotect_exec( addr, count << page_shift, unix_prot, view->protect ); VIRTUAL_DEBUG_DUMP_VIEW( view ); return TRUE; } @@ -646,18 +665,9 @@ return TRUE; } - if (force_exec_prot && !(view->protect & VPROT_NOEXEC) && - (unix_prot & PROT_READ) && !(unix_prot & PROT_EXEC)) - { - TRACE( "forcing exec permission on %p-%p\n", base, (char *)base + size - 1 ); - if (!mprotect( base, size, unix_prot | PROT_EXEC )) goto done; - /* exec + write may legitimately fail, in that case fall back to write only */ - if (!(unix_prot & PROT_WRITE)) return FALSE; - } - - if (mprotect( base, size, unix_prot )) return FALSE; /* FIXME: last error */ + if (mprotect_exec( base, size, unix_prot, view->protect )) /* FIXME: last error */ + return FALSE; -done: memset( p, vprot, size >> page_shift ); VIRTUAL_DEBUG_DUMP_VIEW( view ); return TRUE; @@ -683,12 +693,12 @@ p[i] |= VPROT_WRITEWATCH; prot = VIRTUAL_GetUnixProt( p[i] ); if (prot == unix_prot) continue; - mprotect( addr, count << page_shift, unix_prot ); + mprotect_exec( addr, count << page_shift, unix_prot, view->protect ); addr += count << page_shift; unix_prot = prot; count = 0; } - if (count) mprotect( addr, count << page_shift, unix_prot ); + if (count) mprotect_exec( addr, count << page_shift, unix_prot, view->protect ); } @@ -1522,11 +1532,6 @@ { void *page = ROUND_ADDR( addr, page_mask ); BYTE *vprot = &view->prot[((const char *)page - (const char *)view->base) >> page_shift]; - if (*vprot & VPROT_GUARD) - { - VIRTUAL_SetProt( view, page, page_size, *vprot & ~VPROT_GUARD ); - ret = STATUS_GUARD_PAGE_VIOLATION; - } if ((err & EXCEPTION_WRITE_FAULT) && (view->protect & VPROT_WRITEWATCH)) { if (*vprot & VPROT_WRITEWATCH) @@ -1537,6 +1542,11 @@ /* ignore fault if page is writable now */ if (VIRTUAL_GetUnixProt( *vprot ) & PROT_WRITE) ret = STATUS_SUCCESS; } + if (*vprot & VPROT_GUARD) + { + VIRTUAL_SetProt( view, page, page_size, *vprot & ~VPROT_GUARD ); + ret = STATUS_GUARD_PAGE_VIOLATION; + } } server_leave_uninterrupted_section( &csVirtual, &sigset ); return ret; @@ -1661,6 +1671,84 @@ } +/*********************************************************************** + * virtual_uninterrupted_read_memory + * + * Similar to NtReadVirtualMemory, but without wineserver calls. Moreover + * permissions are checked before accessing each page, to ensure that no + * exceptions can happen. + */ +SIZE_T virtual_uninterrupted_read_memory( const void *addr, void *buffer, SIZE_T size ) +{ + struct file_view *view; + sigset_t sigset; + SIZE_T bytes_read = 0; + + if (!size) return 0; + + server_enter_uninterrupted_section( &csVirtual, &sigset ); + if ((view = VIRTUAL_FindView( addr, size ))) + { + if (!(view->protect & VPROT_SYSTEM)) + { + void *page = ROUND_ADDR( addr, page_mask ); + BYTE *p = view->prot + (((const char *)page - (const char *)view->base) >> page_shift); + + while (bytes_read < size && (VIRTUAL_GetUnixProt( *p++ ) & PROT_READ)) + { + SIZE_T block_size = min( size, page_size - ((UINT_PTR)addr & page_mask) ); + memcpy( buffer, addr, block_size ); + + addr = (const void *)((const char *)addr + block_size); + buffer = (void *)((char *)buffer + block_size); + bytes_read += block_size; + } + } + } + server_leave_uninterrupted_section( &csVirtual, &sigset ); + return bytes_read; +} + + +/*********************************************************************** + * virtual_uninterrupted_write_memory + * + * Similar to NtWriteVirtualMemory, but without wineserver calls. Moreover + * permissions are checked before accessing each page, to ensure that no + * exceptions can happen. + */ +SIZE_T virtual_uninterrupted_write_memory( void *addr, const void *buffer, SIZE_T size ) +{ + struct file_view *view; + sigset_t sigset; + SIZE_T bytes_written = 0; + + if (!size) return 0; + + server_enter_uninterrupted_section( &csVirtual, &sigset ); + if ((view = VIRTUAL_FindView( addr, size ))) + { + if (!(view->protect & VPROT_SYSTEM)) + { + void *page = ROUND_ADDR( addr, page_mask ); + BYTE *p = view->prot + (((const char *)page - (const char *)view->base) >> page_shift); + + while (bytes_written < size && (VIRTUAL_GetUnixProt( *p++ ) & PROT_WRITE)) + { + SIZE_T block_size = min( size, page_size - ((UINT_PTR)addr & page_mask) ); + memcpy( addr, buffer, block_size ); + + addr = (void *)((char *)addr + block_size); + buffer = (const void *)((const char *)buffer + block_size); + bytes_written += block_size; + } + } + } + server_leave_uninterrupted_section( &csVirtual, &sigset ); + return bytes_written; +} + + /*********************************************************************** * VIRTUAL_SetForceExec * diff -Nru wine1.7-1.7.28/dlls/ntdsapi/ntdsapi.c wine1.7-1.7.31/dlls/ntdsapi/ntdsapi.c --- wine1.7-1.7.28/dlls/ntdsapi/ntdsapi.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdsapi/ntdsapi.c 2014-11-14 13:28:17.000000000 +0000 @@ -48,6 +48,24 @@ } /*********************************************************************** + * DsBindA (NTDSAPI.@) + */ +DWORD WINAPI DsBindA(LPCSTR controller, LPCSTR domain, HANDLE *handle) + { + FIXME("(%s,%s, %p): stub!\n", debugstr_a(controller), debugstr_a(domain), handle); + return ERROR_CALL_NOT_IMPLEMENTED; +} + +/*********************************************************************** + * DsBindW (NTDSAPI.@) + */ +DWORD WINAPI DsBindW(LPCWSTR controller, LPCWSTR domain, HANDLE *handle) + { + FIXME("(%s,%s, %p): stub!\n", debugstr_w(controller), debugstr_w(domain), handle); + return ERROR_CALL_NOT_IMPLEMENTED; +} + +/*********************************************************************** * DsMakeSpnW (NTDSAPI.@) */ DWORD WINAPI DsMakeSpnW(LPCWSTR svc_class, LPCWSTR svc_name, diff -Nru wine1.7-1.7.28/dlls/ntdsapi/ntdsapi.spec wine1.7-1.7.31/dlls/ntdsapi/ntdsapi.spec --- wine1.7-1.7.28/dlls/ntdsapi/ntdsapi.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntdsapi/ntdsapi.spec 2014-11-14 13:28:17.000000000 +0000 @@ -1,7 +1,7 @@ @ stub DsAddSidHistoryA @ stub DsAddSidHistoryW -@ stub DsBindA -@ stub DsBindW +@ stdcall DsBindA(str str ptr) +@ stdcall DsBindW(wstr wstr ptr) @ stub DsBindWithCredA @ stub DsBindWithCredW @ stub DsBindWithSpnA diff -Nru wine1.7-1.7.28/dlls/ntoskrnl.exe/instr.c wine1.7-1.7.31/dlls/ntoskrnl.exe/instr.c --- wine1.7-1.7.28/dlls/ntoskrnl.exe/instr.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntoskrnl.exe/instr.c 2014-11-14 13:28:17.000000000 +0000 @@ -139,7 +139,7 @@ GET_VAL( &sib, BYTE ); rm = sib & 7; ss = sib >> 6; - switch(sib >> 3) + switch((sib >> 3) & 7) { case 0: index = context->Eax; break; case 1: index = context->Ecx; break; diff -Nru wine1.7-1.7.28/dlls/ntoskrnl.exe/ntoskrnl.c wine1.7-1.7.31/dlls/ntoskrnl.exe/ntoskrnl.c --- wine1.7-1.7.28/dlls/ntoskrnl.exe/ntoskrnl.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntoskrnl.exe/ntoskrnl.c 2014-11-14 13:28:17.000000000 +0000 @@ -44,6 +44,7 @@ WINE_DECLARE_DEBUG_CHANNEL(relay); BOOLEAN KdDebuggerEnabled = FALSE; +ULONG InitSafeBootMode = 0; extern LONG CALLBACK vectored_handler( EXCEPTION_POINTERS *ptrs ); @@ -1926,3 +1927,23 @@ { FIXME("(%p %d) stub\n", deviceobject, cancelable); } + +/***************************************************** + * ObQueryNameString (NTOSKRNL.EXE.@) + */ +NTSTATUS WINAPI ObQueryNameString(PVOID object, POBJECT_NAME_INFORMATION name, ULONG maxlength, PULONG returnlength) +{ + FIXME("(%p %p %u %p) stub\n", object, name, maxlength, returnlength); + return STATUS_NOT_IMPLEMENTED; +} + +/***************************************************** + * IoRegisterPlugPlayNotification (NTOSKRNL.EXE.@) + */ +NTSTATUS WINAPI IoRegisterPlugPlayNotification(IO_NOTIFICATION_EVENT_CATEGORY category, ULONG flags, PVOID data, + PDRIVER_OBJECT driver, PDRIVER_NOTIFICATION_CALLBACK_ROUTINE callback, + PVOID context, PVOID *notification) +{ + FIXME("(%u %u %p %p %p %p %p) stub\n", category, flags, data, driver, callback, context, notification); + return STATUS_SUCCESS; +} diff -Nru wine1.7-1.7.28/dlls/ntoskrnl.exe/ntoskrnl.exe.spec wine1.7-1.7.31/dlls/ntoskrnl.exe/ntoskrnl.exe.spec --- wine1.7-1.7.28/dlls/ntoskrnl.exe/ntoskrnl.exe.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ntoskrnl.exe/ntoskrnl.exe.spec 2014-11-14 13:28:17.000000000 +0000 @@ -302,7 +302,7 @@ @ stub InbvSetScrollRegion @ stub InbvSetTextColor @ stub InbvSolidColorFill -@ stub InitSafeBootMode +@ extern InitSafeBootMode @ stdcall IoAcquireCancelSpinLock(ptr) @ stdcall IoAcquireRemoveLockEx(ptr ptr ptr long long) @ stub IoAcquireVpbSpinLock @@ -430,7 +430,7 @@ @ stdcall IoRegisterFileSystem(ptr) @ stub IoRegisterFsRegistrationChange @ stub IoRegisterLastChanceShutdownNotification -@ stub IoRegisterPlugPlayNotification +@ stdcall IoRegisterPlugPlayNotification(long long ptr ptr ptr ptr ptr) @ stdcall IoRegisterShutdownNotification(ptr) @ stdcall IoReleaseCancelSpinLock(ptr) @ stub IoReleaseRemoveLockAndWaitEx @@ -807,7 +807,7 @@ @ stub ObMakeTemporaryObject @ stub ObOpenObjectByName @ stub ObOpenObjectByPointer -@ stub ObQueryNameString +@ stdcall ObQueryNameString(ptr ptr long ptr) @ stub ObQueryObjectAuditingByHandle @ stdcall ObReferenceObjectByHandle(long long ptr long ptr ptr) @ stdcall ObReferenceObjectByName(ptr long ptr long ptr long ptr ptr) diff -Nru wine1.7-1.7.28/dlls/odbc32/Makefile.in wine1.7-1.7.31/dlls/odbc32/Makefile.in --- wine1.7-1.7.28/dlls/odbc32/Makefile.in 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/odbc32/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -4,3 +4,5 @@ C_SRCS = \ proxyodbc.c + +RC_SRCS = rsrc.rc diff -Nru wine1.7-1.7.28/dlls/odbc32/rsrc.rc wine1.7-1.7.31/dlls/odbc32/rsrc.rc --- wine1.7-1.7.28/dlls/odbc32/rsrc.rc 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/odbc32/rsrc.rc 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,26 @@ +/* + * Copyright 2014 Hans Leidekker 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 + */ + +#define WINE_FILEDESCRIPTION_STR "Wine ODBC Library" +#define WINE_FILENAME_STR "odbc32.dll" +#define WINE_FILEVERSION 3,520,6301,0 +#define WINE_FILEVERSION_STR "3.520.6301.0" +#define WINE_PRODUCTVERSION 3,520,6301,0 +#define WINE_PRODUCTVERSION_STR "3.520.6301.0" + +#include "wine/wine_common_ver.rc" diff -Nru wine1.7-1.7.28/dlls/ole32/clipboard.c wine1.7-1.7.31/dlls/ole32/clipboard.c --- wine1.7-1.7.28/dlls/ole32/clipboard.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ole32/clipboard.c 2014-11-14 13:28:17.000000000 +0000 @@ -210,13 +210,11 @@ static UINT wine_marshal_clipboard_format; -static inline char *dump_fmtetc(FORMATETC *fmt) +static inline const char *dump_fmtetc(FORMATETC *fmt) { - static char buf[100]; - - snprintf(buf, sizeof(buf), "cf %04x ptd %p aspect %x lindex %d tymed %x", - fmt->cfFormat, fmt->ptd, fmt->dwAspect, fmt->lindex, fmt->tymed); - return buf; + if (!fmt) return "(null)"; + return wine_dbg_sprintf("cf %04x ptd %p aspect %x lindex %d tymed %x", + fmt->cfFormat, fmt->ptd, fmt->dwAspect, fmt->lindex, fmt->tymed); } /*---------------------------------------------------------------------* @@ -1133,6 +1131,8 @@ return TYMED_ENHMF; case CF_METAFILEPICT: return TYMED_MFPICT; + case CF_BITMAP: + return TYMED_GDI; default: FIXME("returning TYMED_NULL for cf %04x\n", cf); return TYMED_NULL; @@ -1310,6 +1310,27 @@ return S_OK; } +/************************************************************************ + * get_stgmed_for_bitmap + * + * Returns a stg medium with a bitmap based on the handle + */ +static HRESULT get_stgmed_for_bitmap(HBITMAP hbmp, STGMEDIUM *med) +{ + HRESULT hr; + + med->pUnkForRelease = NULL; + med->tymed = TYMED_NULL; + + hr = dup_bitmap(hbmp, &med->u.hBitmap); + + if (FAILED(hr)) + return hr; + + med->tymed = TYMED_GDI; + return S_OK; +} + static inline BOOL string_off_equal(const DVTARGETDEVICE *t1, WORD off1, const DVTARGETDEVICE *t2, WORD off2) { const WCHAR *str1, *str2; @@ -1401,6 +1422,8 @@ hr = get_stgmed_for_stream(h, med); else if(mask & TYMED_ENHMF) hr = get_stgmed_for_emf((HENHMETAFILE)h, med); + else if(mask & TYMED_GDI) + hr = get_stgmed_for_bitmap((HBITMAP)h, med); else { FIXME("Unhandled tymed - mask %x req tymed %x\n", mask, fmt->tymed); diff -Nru wine1.7-1.7.28/dlls/oleacc/main.c wine1.7-1.7.31/dlls/oleacc/main.c --- wine1.7-1.7.28/dlls/oleacc/main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/oleacc/main.c 2014-11-14 13:28:17.000000000 +0000 @@ -219,10 +219,10 @@ return E_FAIL; data = GlobalAlloc(GMEM_FIXED, size); - memcpy(data, view, size); - UnmapViewOfFile(view); if(!data) return E_OUTOFMEMORY; + memcpy(data, view, size); + UnmapViewOfFile(view); hr = CreateStreamOnHGlobal(data, TRUE, &stream); if(FAILED(hr)) { diff -Nru wine1.7-1.7.28/dlls/oleaut32/tests/typelib.c wine1.7-1.7.31/dlls/oleaut32/tests/typelib.c --- wine1.7-1.7.28/dlls/oleaut32/tests/typelib.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/oleaut32/tests/typelib.c 2014-11-14 13:28:17.000000000 +0000 @@ -5594,7 +5594,7 @@ ok(hr == S_OK, "got: %x\n", hr); hr = ITypeInfo_GetRefTypeInfo(ptInfo, refType, &ptInfoExt); - todo_wine ok(hr == S_OK || broken(hr == TYPE_E_CANTLOADLIBRARY) /* win 2000 */, "got: %x\n", hr); + ok(hr == S_OK || broken(hr == TYPE_E_CANTLOADLIBRARY) /* win 2000 */, "got: %x\n", hr); ITypeInfo_Release(ptInfo); if(ptInfoExt) diff -Nru wine1.7-1.7.28/dlls/oleaut32/tests/vartest.c wine1.7-1.7.31/dlls/oleaut32/tests/vartest.c --- wine1.7-1.7.28/dlls/oleaut32/tests/vartest.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/oleaut32/tests/vartest.c 2014-11-14 13:28:17.000000000 +0000 @@ -295,16 +295,14 @@ HRESULT res; res = VarBstrFromBool(VARIANT_TRUE, LANG_USER_DEFAULT, VAR_LOCALBOOL, &bstr); - ok(res == S_OK && (lstrlenW(bstr) > 0), - "Expected localized string for 'True'\n"); + ok(res == S_OK && bstr[0], "Expected localized string for 'True'\n"); /* lstrcpyW / lstrcatW do not work on win95 */ memcpy(sz12_true, sz12, sizeof(sz12)); if (bstr) memcpy(&sz12_true[2], bstr, SysStringByteLen(bstr) + sizeof(WCHAR)); SysFreeString(bstr); res = VarBstrFromBool(VARIANT_FALSE, LANG_USER_DEFAULT, VAR_LOCALBOOL, &bstr); - ok(res == S_OK && (lstrlenW(bstr) > 0), - "Expected localized string for 'False'\n"); + ok(res == S_OK && bstr[0], "Expected localized string for 'False'\n"); memcpy(sz12_false, sz12, sizeof(sz12)); if (bstr) memcpy(&sz12_false[2], bstr, SysStringByteLen(bstr) + sizeof(WCHAR)); SysFreeString(bstr); @@ -7403,10 +7401,10 @@ hres = pVarPow(&cy, &right, &result); if (hres == S_OK) { - ok(hres == S_OK && V_VT(&result) == VT_R8, + ok(V_VT(&result) == VT_R8, "VARPOW: expected coerced hres 0x%X type VT_R8, got hres 0x%X type %s!\n", S_OK, hres, vtstr(V_VT(&result))); - ok(hres == S_OK && EQ_DOUBLE(V_R8(&result), 4.0), + ok(EQ_DOUBLE(V_R8(&result), 4.0), "VARPOW: CY value %f, expected %f\n", V_R8(&result), 4.0); } else @@ -7440,10 +7438,10 @@ hres = pVarPow(&dec, &right, &result); if (hres == S_OK) { - ok(hres == S_OK && V_VT(&result) == VT_R8, + ok(V_VT(&result) == VT_R8, "VARPOW: expected coerced hres 0x%X type VT_R8, got hres 0x%X type %s!\n", S_OK, hres, vtstr(V_VT(&result))); - ok(hres == S_OK && EQ_DOUBLE(V_R8(&result), 4.0), + ok(EQ_DOUBLE(V_R8(&result), 4.0), "VARPOW: DECIMAL value %f, expected %f\n", V_R8(&result), 4.0); } else diff -Nru wine1.7-1.7.28/dlls/oleaut32/typelib.c wine1.7-1.7.31/dlls/oleaut32/typelib.c --- wine1.7-1.7.28/dlls/oleaut32/typelib.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/oleaut32/typelib.c 2014-11-14 13:28:17.000000000 +0000 @@ -7572,6 +7572,45 @@ return E_FAIL; } +struct search_res_tlb_params +{ + const GUID *guid; + ITypeLib *pTLib; +}; + +static BOOL CALLBACK search_res_tlb(HMODULE hModule, LPCWSTR lpszType, LPWSTR lpszName, LONG_PTR lParam) +{ + struct search_res_tlb_params *params = (LPVOID)lParam; + static const WCHAR formatW[] = {'\\','%','d',0}; + WCHAR szPath[MAX_PATH+1]; + ITypeLib *pTLib = NULL; + HRESULT ret; + DWORD len; + + if (IS_INTRESOURCE(lpszName) == FALSE) + return TRUE; + + if (!(len = GetModuleFileNameW(hModule, szPath, MAX_PATH))) + return TRUE; + + if (snprintfW(szPath + len, sizeof(szPath)/sizeof(WCHAR) - len, formatW, LOWORD(lpszName)) < 0) + return TRUE; + + ret = LoadTypeLibEx(szPath, REGKIND_NONE, &pTLib); + if (SUCCEEDED(ret)) + { + ITypeLibImpl *impl = impl_from_ITypeLib(pTLib); + if (IsEqualGUID(params->guid, impl->guid)) + { + params->pTLib = pTLib; + return FALSE; /* stop enumeration */ + } + ITypeLib_Release(pTLib); + } + + return TRUE; +} + /* ITypeInfo::GetRefTypeInfo * * If a type description references other type descriptions, it retrieves @@ -7665,20 +7704,33 @@ ITypeLib_AddRef(pTLib); result = S_OK; } else { + static const WCHAR TYPELIBW[] = {'T','Y','P','E','L','I','B',0}; + struct search_res_tlb_params params; BSTR libnam; TRACE("typeinfo in imported typelib that isn't already loaded\n"); - result = query_typelib_path(TLB_get_guid_null(ref_type->pImpTLInfo->guid), - ref_type->pImpTLInfo->wVersionMajor, - ref_type->pImpTLInfo->wVersionMinor, - This->pTypeLib->syskind, - ref_type->pImpTLInfo->lcid, &libnam, TRUE); - if(FAILED(result)) - libnam = SysAllocString(ref_type->pImpTLInfo->name); + /* Search in resource table */ + params.guid = TLB_get_guid_null(ref_type->pImpTLInfo->guid); + params.pTLib = NULL; + EnumResourceNamesW(NULL, TYPELIBW, search_res_tlb, (LONG_PTR)¶ms); + pTLib = params.pTLib; + result = S_OK; - result = LoadTypeLib(libnam, &pTLib); - SysFreeString(libnam); + if (!pTLib) + { + /* Search on disk */ + result = query_typelib_path(TLB_get_guid_null(ref_type->pImpTLInfo->guid), + ref_type->pImpTLInfo->wVersionMajor, + ref_type->pImpTLInfo->wVersionMinor, + This->pTypeLib->syskind, + ref_type->pImpTLInfo->lcid, &libnam, TRUE); + if (FAILED(result)) + libnam = SysAllocString(ref_type->pImpTLInfo->name); + + result = LoadTypeLib(libnam, &pTLib); + SysFreeString(libnam); + } if(SUCCEEDED(result)) { ref_type->pImpTLInfo->pImpTypeLib = impl_from_ITypeLib(pTLib); @@ -9144,7 +9196,7 @@ file->arraydesc_seg.data = heap_alloc(file->arraydesc_seg.len); else file->arraydesc_seg.data = heap_realloc(file->arraydesc_seg.data, file->arraydesc_seg.len); - encoded = (DWORD*)((char *)file->arraydesc_seg.data) + offs; + encoded = (DWORD*)((char *)file->arraydesc_seg.data + offs); encoded[0] = WMSFT_append_typedesc(&desc->tdescElem, file, NULL, NULL); encoded[1] = desc->cDims | ((desc->cDims * 2 * sizeof(DWORD)) << 16); diff -Nru wine1.7-1.7.28/dlls/prntvpt/main.c wine1.7-1.7.31/dlls/prntvpt/main.c --- wine1.7-1.7.28/dlls/prntvpt/main.c 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/prntvpt/main.c 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,43 @@ +/* + * Print Ticket Services Module + * + * Copyright 2014 Jactry Zeng 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 + +#include "windef.h" +#include "winbase.h" +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(prntvpt); + +BOOL WINAPI DllMain(HINSTANCE hinst, DWORD reason, LPVOID reserved) +{ + TRACE("(%p, %d, %p)\n", hinst, reason, reserved); + + switch(reason) + { + case DLL_WINE_PREATTACH: + return FALSE; /* prefer native version */ + case DLL_PROCESS_ATTACH: + DisableThreadLibraryCalls(hinst); + break; + } + return TRUE; +} diff -Nru wine1.7-1.7.28/dlls/prntvpt/Makefile.in wine1.7-1.7.31/dlls/prntvpt/Makefile.in --- wine1.7-1.7.28/dlls/prntvpt/Makefile.in 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/prntvpt/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,4 @@ +MODULE = prntvpt.dll + +C_SRCS = \ + main.c diff -Nru wine1.7-1.7.28/dlls/prntvpt/prntvpt.spec wine1.7-1.7.31/dlls/prntvpt/prntvpt.spec --- wine1.7-1.7.28/dlls/prntvpt/prntvpt.spec 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/dlls/prntvpt/prntvpt.spec 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,27 @@ +1 stub PTQuerySchemaVersionSupport +2 stub PTOpenProvider +3 stub PTOpenProviderEx +4 stub PTCloseProvider +5 stub BindPTProviderThunk +6 stub PTGetPrintCapabilities +7 stub PTMergeAndValidatePrintTicket +8 stub PTConvertPrintTicketToDevMode +9 stub PTConvertDevModeToPrintTicket +10 stub PTReleaseMemory +11 stub ConvertDevModeToPrintTicketThunk2 +12 stub ConvertDevModeToPrintTicketThunk +13 stub ConvertPrintTicketToDevModeThunk2 +14 stub ConvertPrintTicketToDevModeThunk +15 stub DllCanUnloadNow +16 stub DllGetClassObject +17 stdcall -private DllMain(long long ptr) +18 stub DllRegisterServer +19 stub DllUnregisterServer +20 stub GetDeviceDefaultPrintTicketThunk +21 stub GetDeviceNamespacesThunk +22 stub GetPrintCapabilitiesThunk2 +23 stub GetPrintCapabilitiesThunk +24 stub GetSchemaVersionThunk +25 stub MergeAndValidatePrintTicketThunk2 +26 stub MergeAndValidatePrintTicketThunk +27 stub UnbindPTProviderThunk diff -Nru wine1.7-1.7.28/dlls/propsys/propsys_main.c wine1.7-1.7.31/dlls/propsys/propsys_main.c --- wine1.7-1.7.28/dlls/propsys/propsys_main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/propsys/propsys_main.c 2014-11-14 13:28:17.000000000 +0000 @@ -293,12 +293,12 @@ /* GUIDSTRING_MAX accounts for null terminator, +1 for space character. */ if (cch <= GUIDSTRING_MAX + 1) - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; if (!pkey) { psz[0] = '\0'; - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; } sprintfW(psz, guid_fmtW, pkey->fmtid.Data1, pkey->fmtid.Data2, @@ -336,7 +336,7 @@ *p++ = *ptr--; } - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; } } diff -Nru wine1.7-1.7.28/dlls/propsys/tests/propsys.c wine1.7-1.7.31/dlls/propsys/tests/propsys.c --- wine1.7-1.7.28/dlls/propsys/tests/propsys.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/propsys/tests/propsys.c 2014-11-14 13:28:17.000000000 +0000 @@ -108,19 +108,19 @@ {NULL, NULL, 0, E_POINTER}, {&prop, NULL, 0, E_POINTER}, {&prop, NULL, PKEYSTR_MAX, E_POINTER}, - {NULL, out, 0, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), fillerW}, - {NULL, out, PKEYSTR_MAX, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), zero_fillerW, FALSE, 0, TRUE, fillerW}, - {&prop, out, 0, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), fillerW}, - {&prop, out, GUIDSTRING_MAX, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), fillerW}, - {&prop, out, GUIDSTRING_MAX + 1, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), fillerW}, - {&prop, out, GUIDSTRING_MAX + 2, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), zero_truncatedW, TRUE, S_OK, TRUE, truncatedW}, - {&prop, out, PKEYSTR_MAX - 2, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), zero_truncated2W, TRUE, S_OK, TRUE, truncated2W}, - {&prop, out, PKEYSTR_MAX - 1, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), zero_truncated3W, TRUE, S_OK, TRUE, truncated3W}, + {NULL, out, 0, E_NOT_SUFFICIENT_BUFFER, fillerW}, + {NULL, out, PKEYSTR_MAX, E_NOT_SUFFICIENT_BUFFER, zero_fillerW, FALSE, 0, TRUE, fillerW}, + {&prop, out, 0, E_NOT_SUFFICIENT_BUFFER, fillerW}, + {&prop, out, GUIDSTRING_MAX, E_NOT_SUFFICIENT_BUFFER, fillerW}, + {&prop, out, GUIDSTRING_MAX + 1, E_NOT_SUFFICIENT_BUFFER, fillerW}, + {&prop, out, GUIDSTRING_MAX + 2, E_NOT_SUFFICIENT_BUFFER, zero_truncatedW, TRUE, S_OK, TRUE, truncatedW}, + {&prop, out, PKEYSTR_MAX - 2, E_NOT_SUFFICIENT_BUFFER, zero_truncated2W, TRUE, S_OK, TRUE, truncated2W}, + {&prop, out, PKEYSTR_MAX - 1, E_NOT_SUFFICIENT_BUFFER, zero_truncated3W, TRUE, S_OK, TRUE, truncated3W}, {&prop, out, PKEYSTR_MAX, S_OK, expectedW}, - {&prop2, out, GUIDSTRING_MAX + 2, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), zero_truncated4W, TRUE, S_OK, TRUE, truncated4W}, + {&prop2, out, GUIDSTRING_MAX + 2, E_NOT_SUFFICIENT_BUFFER, zero_truncated4W, TRUE, S_OK, TRUE, truncated4W}, {&prop2, out, GUIDSTRING_MAX + 6, S_OK, expected2W}, {&prop2, out, PKEYSTR_MAX, S_OK, expected2W}, - {&prop3, out, GUIDSTRING_MAX + 1, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), fillerW}, + {&prop3, out, GUIDSTRING_MAX + 1, E_NOT_SUFFICIENT_BUFFER, fillerW}, {&prop3, out, GUIDSTRING_MAX + 2, S_OK, expected3W}, {&prop3, out, PKEYSTR_MAX, S_OK, expected3W}, }; diff -Nru wine1.7-1.7.28/dlls/psapi/tests/psapi_main.c wine1.7-1.7.31/dlls/psapi/tests/psapi_main.c --- wine1.7-1.7.28/dlls/psapi/tests/psapi_main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/psapi/tests/psapi_main.c 2014-11-14 13:28:17.000000000 +0000 @@ -53,14 +53,16 @@ static BOOL (WINAPI *pGetModuleInformation)(HANDLE, HMODULE, LPMODULEINFO, DWORD); static DWORD (WINAPI *pGetMappedFileNameA)(HANDLE, LPVOID, LPSTR, DWORD); static DWORD (WINAPI *pGetMappedFileNameW)(HANDLE, LPVOID, LPWSTR, DWORD); +static BOOL (WINAPI *pGetPerformanceInfo)(PPERFORMANCE_INFORMATION, DWORD); static DWORD (WINAPI *pGetProcessImageFileNameA)(HANDLE, LPSTR, DWORD); static DWORD (WINAPI *pGetProcessImageFileNameW)(HANDLE, LPWSTR, DWORD); static BOOL (WINAPI *pGetProcessMemoryInfo)(HANDLE, PPROCESS_MEMORY_COUNTERS, DWORD); static BOOL (WINAPI *pGetWsChanges)(HANDLE, PPSAPI_WS_WATCH_INFORMATION, DWORD); static BOOL (WINAPI *pInitializeProcessForWsWatch)(HANDLE); static BOOL (WINAPI *pQueryWorkingSet)(HANDLE, PVOID, DWORD); +static NTSTATUS (WINAPI *pNtQuerySystemInformation)(SYSTEM_INFORMATION_CLASS, PVOID, ULONG, PULONG); static NTSTATUS (WINAPI *pNtQueryVirtualMemory)(HANDLE, LPCVOID, ULONG, PVOID, SIZE_T, SIZE_T *); - + static BOOL InitFunctionPtrs(HMODULE hpsapi) { PSAPI_GET_PROC(EmptyWorkingSet); @@ -77,10 +79,13 @@ PSAPI_GET_PROC(InitializeProcessForWsWatch); PSAPI_GET_PROC(QueryWorkingSet); /* GetProcessImageFileName is not exported on NT4 */ + pGetPerformanceInfo = + (void *)GetProcAddress(hpsapi, "GetPerformanceInfo"); pGetProcessImageFileNameA = (void *)GetProcAddress(hpsapi, "GetProcessImageFileNameA"); pGetProcessImageFileNameW = (void *)GetProcAddress(hpsapi, "GetProcessImageFileNameW"); + pNtQuerySystemInformation = (void *)GetProcAddress(GetModuleHandleA("ntdll.dll"), "NtQuerySystemInformation"); pNtQueryVirtualMemory = (void *)GetProcAddress(GetModuleHandleA("ntdll.dll"), "NtQueryVirtualMemory"); return TRUE; } @@ -184,6 +189,121 @@ ok(info.lpBaseOfDll == hMod, "lpBaseOfDll=%p hMod=%p\n", info.lpBaseOfDll, hMod); } +static void test_GetPerformanceInfo(void) +{ + PERFORMANCE_INFORMATION info; + NTSTATUS status; + DWORD size; + BOOL ret; + + SetLastError(0xdeadbeef); + ret = pGetPerformanceInfo(&info, sizeof(info)-1); + ok(!ret, "GetPerformanceInfo unexpectedly succeeded\n"); + ok(GetLastError() == ERROR_BAD_LENGTH, "expected error=ERROR_BAD_LENGTH but got %d\n", GetLastError()); + + SetLastError(0xdeadbeef); + ret = pGetPerformanceInfo(&info, sizeof(info)); + ok(ret, "GetPerformanceInfo failed with %d\n", GetLastError()); + ok(info.cb == sizeof(PERFORMANCE_INFORMATION), "got %d\n", info.cb); + + if (!pNtQuerySystemInformation) + win_skip("NtQuerySystemInformation not found, skipping tests\n"); + else + { + char performance_buffer[sizeof(SYSTEM_PERFORMANCE_INFORMATION) + 16]; /* larger on w2k8/win7 */ + SYSTEM_PERFORMANCE_INFORMATION *sys_performance_info = (SYSTEM_PERFORMANCE_INFORMATION *)performance_buffer; + SYSTEM_PROCESS_INFORMATION *sys_process_info = NULL, *spi; + SYSTEM_BASIC_INFORMATION sys_basic_info; + DWORD process_count, handle_count, thread_count; + + /* compare with values from SYSTEM_PERFORMANCE_INFORMATION */ + size = 0; + status = pNtQuerySystemInformation(SystemPerformanceInformation, sys_performance_info, sizeof(performance_buffer), &size); + ok(status == STATUS_SUCCESS, "expected STATUS_SUCCESS, got %08x\n", status); + ok(size >= sizeof(SYSTEM_PERFORMANCE_INFORMATION), "incorrect length %d\n", size); + + ok(info.CommitTotal == sys_performance_info->TotalCommittedPages, + "expected info.CommitTotal=%u but got %u\n", + sys_performance_info->TotalCommittedPages, (ULONG)info.CommitTotal); + + ok(info.CommitLimit == sys_performance_info->TotalCommitLimit, + "expected info.CommitLimit=%u but got %u\n", + sys_performance_info->TotalCommitLimit, (ULONG)info.CommitLimit); + + ok(info.CommitPeak == sys_performance_info->PeakCommitment, + "expected info.CommitPeak=%u but got %u\n", + sys_performance_info->PeakCommitment, (ULONG)info.CommitPeak); + + ok(info.PhysicalAvailable >= max(sys_performance_info->AvailablePages, 25) - 25 && + info.PhysicalAvailable <= sys_performance_info->AvailablePages + 25, + "expected approximately info.PhysicalAvailable=%u but got %u\n", + sys_performance_info->AvailablePages, (ULONG)info.PhysicalAvailable); + + /* TODO: info.SystemCache not checked yet - to which field(s) does this value correspond to? */ + + ok(info.KernelTotal == sys_performance_info->PagedPoolUsage + sys_performance_info->NonPagedPoolUsage, + "expected info.KernelTotal=%u but got %u\n", + sys_performance_info->PagedPoolUsage + sys_performance_info->NonPagedPoolUsage, (ULONG)info.KernelTotal); + + ok(info.KernelPaged == sys_performance_info->PagedPoolUsage, + "expected info.KernelPaged=%u but got %u\n", + sys_performance_info->PagedPoolUsage, (ULONG)info.KernelPaged); + + ok(info.KernelNonpaged == sys_performance_info->NonPagedPoolUsage, + "expected info.KernelNonpaged=%u but got %u\n", + sys_performance_info->NonPagedPoolUsage, (ULONG)info.KernelNonpaged); + + /* compare with values from SYSTEM_BASIC_INFORMATION */ + size = 0; + status = pNtQuerySystemInformation(SystemBasicInformation, &sys_basic_info, sizeof(sys_basic_info), &size); + ok(status == STATUS_SUCCESS, "expected STATUS_SUCCESS, got %08x\n", status); + ok(size >= sizeof(SYSTEM_BASIC_INFORMATION), "incorrect length %d\n", size); + + ok(info.PhysicalTotal == sys_basic_info.MmNumberOfPhysicalPages, + "expected info.PhysicalTotal=%u but got %u\n", + sys_basic_info.MmNumberOfPhysicalPages, (ULONG)info.PhysicalTotal); + + ok(info.PageSize == sys_basic_info.PageSize, + "expected info.PageSize=%u but got %u\n", + sys_basic_info.PageSize, (ULONG)info.PageSize); + + /* compare with values from SYSTEM_PROCESS_INFORMATION */ + size = 0; + status = pNtQuerySystemInformation(SystemProcessInformation, NULL, 0, &size); + ok(status == STATUS_INFO_LENGTH_MISMATCH, "expected STATUS_LENGTH_MISMATCH, got %08x\n", status); + ok(size > 0, "incorrect length %d\n", size); + while (status == STATUS_INFO_LENGTH_MISMATCH) + { + sys_process_info = HeapAlloc(GetProcessHeap(), 0, size); + ok(sys_process_info != NULL, "failed to allocate memory\n"); + status = pNtQuerySystemInformation(SystemProcessInformation, sys_process_info, size, &size); + if (status == STATUS_SUCCESS) break; + HeapFree(GetProcessHeap(), 0, sys_process_info); + } + ok(status == STATUS_SUCCESS, "expected STATUS_SUCCESS, got %08x\n", status); + + process_count = handle_count = thread_count = 0; + for (spi = sys_process_info;; spi = (SYSTEM_PROCESS_INFORMATION *)(((char *)spi) + spi->NextEntryOffset)) + { + process_count++; + handle_count += spi->HandleCount; + thread_count += spi->dwThreadCount; + if (spi->NextEntryOffset == 0) break; + } + HeapFree(GetProcessHeap(), 0, sys_process_info); + + ok(info.HandleCount == handle_count, + "expected info.HandleCount=%u but got %u\n", handle_count, info.HandleCount); + + ok(info.ProcessCount == process_count, + "expected info.ProcessCount=%u but got %u\n", process_count, info.ProcessCount); + + ok(info.ThreadCount == thread_count, + "expected info.ThreadCount=%u but got %u\n", thread_count, info.ThreadCount); + } +} + + static void test_GetProcessMemoryInfo(void) { PROCESS_MEMORY_COUNTERS pmc; @@ -677,6 +797,7 @@ test_EnumProcesses(); test_EnumProcessModules(); test_GetModuleInformation(); + test_GetPerformanceInfo(); test_GetProcessMemoryInfo(); test_GetMappedFileName(); test_GetProcessImageFileName(); diff -Nru wine1.7-1.7.28/dlls/riched20/editor.c wine1.7-1.7.31/dlls/riched20/editor.c --- wine1.7-1.7.28/dlls/riched20/editor.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/riched20/editor.c 2014-11-14 13:28:17.000000000 +0000 @@ -1194,7 +1194,7 @@ if (!info->lpRichEditOle) { - CreateIRichEditOle(info->editor, (VOID**)&info->lpRichEditOle); + CreateIRichEditOle(NULL, info->editor, (VOID**)&info->lpRichEditOle); } if (OleCreateDefaultHandler(&CLSID_NULL, NULL, &IID_IOleObject, (void**)&lpObject) == S_OK && @@ -2118,7 +2118,7 @@ hr = OleSetClipboard(dataObj); IDataObject_Release(dataObj); } - return SUCCEEDED(hr) != 0; + return SUCCEEDED(hr); } /* helper to send a msg filter notification */ @@ -2863,7 +2863,7 @@ return ed; } -static void ME_DestroyEditor(ME_TextEditor *editor) +void ME_DestroyEditor(ME_TextEditor *editor) { ME_DisplayItem *pFirst = editor->pBuffer->pFirst; ME_DisplayItem *p = pFirst, *pNext = NULL; @@ -2889,7 +2889,7 @@ ITextHost_Release(editor->texthost); if (editor->reOle) { - IRichEditOle_Release(editor->reOle); + DestroyIRichEditOle(editor->reOle); editor->reOle = NULL; } OleUninitialize(); @@ -4474,7 +4474,7 @@ case EM_GETOLEINTERFACE: { if (!editor->reOle) - if (!CreateIRichEditOle(editor, (LPVOID *)&editor->reOle)) + if (!CreateIRichEditOle(NULL, editor, (LPVOID *)&editor->reOle)) return 0; *(LPVOID *)lParam = editor->reOle; IRichEditOle_AddRef(editor->reOle); diff -Nru wine1.7-1.7.28/dlls/riched20/editor.h wine1.7-1.7.31/dlls/riched20/editor.h --- wine1.7-1.7.28/dlls/riched20/editor.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/riched20/editor.h 2014-11-14 13:28:17.000000000 +0000 @@ -240,14 +240,17 @@ int ME_GetParaBorderWidth(const ME_Context *c, int flags) DECLSPEC_HIDDEN; /* richole.c */ -LRESULT CreateIRichEditOle(ME_TextEditor *editor, LPVOID *) DECLSPEC_HIDDEN; +LRESULT CreateIRichEditOle(IUnknown *outer_unk, ME_TextEditor *editor, LPVOID *ppvObj) DECLSPEC_HIDDEN; +void DestroyIRichEditOle(IRichEditOle *iface) DECLSPEC_HIDDEN; void ME_DrawOLE(ME_Context *c, int x, int y, ME_Run* run, ME_Paragraph *para, BOOL selected) DECLSPEC_HIDDEN; void ME_GetOLEObjectSize(const ME_Context *c, ME_Run *run, SIZE *pSize) DECLSPEC_HIDDEN; void ME_CopyReObject(REOBJECT* dst, const REOBJECT* src) DECLSPEC_HIDDEN; void ME_DeleteReObject(REOBJECT* reo) DECLSPEC_HIDDEN; +void ME_GetITextDocumentInterface(IRichEditOle *iface, LPVOID *ppvObj) DECLSPEC_HIDDEN; /* editor.c */ ME_TextEditor *ME_MakeEditor(ITextHost *texthost, BOOL bEmulateVersion10) DECLSPEC_HIDDEN; +void ME_DestroyEditor(ME_TextEditor *editor) DECLSPEC_HIDDEN; LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam, LPARAM lParam, BOOL unicode, HRESULT* phresult) DECLSPEC_HIDDEN; void ME_SendOldNotify(ME_TextEditor *editor, int nCode) DECLSPEC_HIDDEN; diff -Nru wine1.7-1.7.28/dlls/riched20/richole.c wine1.7-1.7.31/dlls/riched20/richole.c --- wine1.7-1.7.28/dlls/riched20/richole.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/riched20/richole.c 2014-11-14 13:28:17.000000000 +0000 @@ -52,8 +52,10 @@ typedef struct ITextRangeImpl ITextRangeImpl; typedef struct IRichEditOleImpl { + IUnknown IUnknown_inner; IRichEditOle IRichEditOle_iface; ITextDocument ITextDocument_iface; + IUnknown *outer_unk; LONG ref; ME_TextEditor *editor; @@ -95,63 +97,84 @@ return CONTAINING_RECORD(iface, IRichEditOleImpl, ITextDocument_iface); } -static HRESULT WINAPI -IRichEditOle_fnQueryInterface(IRichEditOle *me, REFIID riid, LPVOID *ppvObj) +static inline IRichEditOleImpl *impl_from_IUnknown(IUnknown *iface) { - IRichEditOleImpl *This = impl_from_IRichEditOle(me); + return CONTAINING_RECORD(iface, IRichEditOleImpl, IUnknown_inner); +} + +static HRESULT WINAPI IRichEditOleImpl_inner_fnQueryInterface(IUnknown *iface, REFIID riid, LPVOID *ppvObj) +{ + IRichEditOleImpl *This = impl_from_IUnknown(iface); - TRACE("%p %s\n", This, debugstr_guid(riid) ); + TRACE("%p %s\n", This, debugstr_guid(riid)); *ppvObj = NULL; - if (IsEqualGUID(riid, &IID_IUnknown) || - IsEqualGUID(riid, &IID_IRichEditOle)) + if (IsEqualGUID(riid, &IID_IUnknown)) + *ppvObj = &This->IUnknown_inner; + else if (IsEqualGUID(riid, &IID_IRichEditOle)) *ppvObj = &This->IRichEditOle_iface; else if (IsEqualGUID(riid, &IID_ITextDocument)) *ppvObj = &This->ITextDocument_iface; if (*ppvObj) { - IRichEditOle_AddRef(me); + IUnknown_AddRef((IUnknown *)*ppvObj); return S_OK; } - FIXME("%p: unhandled interface %s\n", This, debugstr_guid(riid) ); + FIXME("%p: unhandled interface %s\n", This, debugstr_guid(riid)); return E_NOINTERFACE; } -static ULONG WINAPI -IRichEditOle_fnAddRef(IRichEditOle *me) +static ULONG WINAPI IRichEditOleImpl_inner_fnAddRef(IUnknown *iface) { - IRichEditOleImpl *This = impl_from_IRichEditOle(me); - ULONG ref = InterlockedIncrement( &This->ref ); + IRichEditOleImpl *This = impl_from_IUnknown(iface); + ULONG ref = InterlockedIncrement(&This->ref); TRACE("%p ref = %u\n", This, ref); return ref; } -static ULONG WINAPI -IRichEditOle_fnRelease(IRichEditOle *me) +static ULONG WINAPI IRichEditOleImpl_inner_fnRelease(IUnknown *iface) { - IRichEditOleImpl *This = impl_from_IRichEditOle(me); + IRichEditOleImpl *This = impl_from_IUnknown(iface); ULONG ref = InterlockedDecrement(&This->ref); TRACE ("%p ref=%u\n", This, ref); if (!ref) - { - ITextRangeImpl *txtRge; - TRACE ("Destroying %p\n", This); - This->txtSel->reOle = NULL; - This->editor->reOle = NULL; - ITextSelection_Release(&This->txtSel->ITextSelection_iface); - IOleClientSite_Release(&This->clientSite->IOleClientSite_iface); - LIST_FOR_EACH_ENTRY(txtRge, &This->rangelist, ITextRangeImpl, entry) - txtRge->reOle = NULL; - heap_free(This); - } + DestroyIRichEditOle(&This->IRichEditOle_iface); return ref; } +static const IUnknownVtbl reo_unk_vtbl = +{ + IRichEditOleImpl_inner_fnQueryInterface, + IRichEditOleImpl_inner_fnAddRef, + IRichEditOleImpl_inner_fnRelease +}; + +static HRESULT WINAPI +IRichEditOle_fnQueryInterface(IRichEditOle *me, REFIID riid, LPVOID *ppvObj) +{ + IRichEditOleImpl *This = impl_from_IRichEditOle(me); + return IUnknown_QueryInterface(This->outer_unk, riid, ppvObj); +} + +static ULONG WINAPI +IRichEditOle_fnAddRef(IRichEditOle *me) +{ + IRichEditOleImpl *This = impl_from_IRichEditOle(me); + return IUnknown_AddRef(This->outer_unk); +} + +static ULONG WINAPI +IRichEditOle_fnRelease(IRichEditOle *me) +{ + IRichEditOleImpl *This = impl_from_IRichEditOle(me); + return IUnknown_Release(This->outer_unk); +} + static HRESULT WINAPI IRichEditOle_fnActivateAs(IRichEditOle *me, REFCLSID rclsid, REFCLSID rclsidAs) { @@ -2305,7 +2328,7 @@ return txtSel; } -LRESULT CreateIRichEditOle(ME_TextEditor *editor, LPVOID *ppObj) +LRESULT CreateIRichEditOle(IUnknown *outer_unk, ME_TextEditor *editor, LPVOID *ppvObj) { IRichEditOleImpl *reo; @@ -2313,6 +2336,7 @@ if (!reo) return 0; + reo->IUnknown_inner.lpVtbl = &reo_unk_vtbl; reo->IRichEditOle_iface.lpVtbl = &revt; reo->ITextDocument_iface.lpVtbl = &tdvt; reo->ref = 1; @@ -2331,12 +2355,31 @@ return 0; } TRACE("Created %p\n",reo); - *ppObj = reo; list_init(&reo->rangelist); + if (outer_unk) + reo->outer_unk = outer_unk; + else + reo->outer_unk = &reo->IUnknown_inner; + *ppvObj = &reo->IRichEditOle_iface; return 1; } +void DestroyIRichEditOle(IRichEditOle *iface) +{ + IRichEditOleImpl *This = impl_from_IRichEditOle(iface); + ITextRangeImpl *txtRge; + + TRACE("Destroying %p\n", This); + This->txtSel->reOle = NULL; + This->editor->reOle = NULL; + ITextSelection_Release(&This->txtSel->ITextSelection_iface); + IOleClientSite_Release(&This->clientSite->IOleClientSite_iface); + LIST_FOR_EACH_ENTRY(txtRge, &This->rangelist, ITextRangeImpl, entry) + txtRge->reOle = NULL; + heap_free(This); +} + static void convert_sizel(const ME_Context *c, const SIZEL* szl, SIZE* sz) { /* sizel is in .01 millimeters, sz in pixels */ @@ -2540,3 +2583,9 @@ if (dst->pstg) IStorage_AddRef(dst->pstg); if (dst->polesite) IOleClientSite_AddRef(dst->polesite); } + +void ME_GetITextDocumentInterface(IRichEditOle *iface, LPVOID *ppvObj) +{ + IRichEditOleImpl *This = impl_from_IRichEditOle(iface); + *ppvObj = &This->ITextDocument_iface; +} diff -Nru wine1.7-1.7.28/dlls/riched20/tests/editor.c wine1.7-1.7.31/dlls/riched20/tests/editor.c --- wine1.7-1.7.28/dlls/riched20/tests/editor.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/riched20/tests/editor.c 2014-11-14 13:28:17.000000000 +0000 @@ -3736,9 +3736,8 @@ ok (result == 1, "EM_SETTEXTEX returned %d, instead of 1\n",result); - ok(lstrlenW(buf) == 0, - "EM_SETTEXTEX with NULL lParam should clear rich edit.\n"); - + ok(!buf[0], "EM_SETTEXTEX with NULL lParam should clear rich edit.\n"); + /* put some text back: !ST_SELECTION && Unicode && !\rtf */ setText.flags = 0; SendMessageA(hwndRichEdit, EM_SETTEXTEX, (WPARAM)&setText, (LPARAM)TestItem1); @@ -5225,8 +5224,7 @@ result = SendMessageA(hwndRichEdit, WM_GETTEXT, 1024, (LPARAM)buffer); ok (result == 0, "EM_STREAMIN: Test 2 returned %ld, expected 0\n", result); - ok (strlen(buffer) == 0, - "EM_STREAMIN: Test 2 set wrong text: Result: %s\n",buffer); + ok(!buffer[0], "EM_STREAMIN: Test 2 set wrong text: Result: %s\n",buffer); ok(es.dwError == -16, "EM_STREAMIN: Test 2 set error %d, expected %d\n", es.dwError, -16); es.dwCookie = (DWORD_PTR)&streamText3; @@ -5237,8 +5235,7 @@ result = SendMessageA(hwndRichEdit, WM_GETTEXT, 1024, (LPARAM)buffer); ok (result == 0, "EM_STREAMIN: Test 3 returned %ld, expected 0\n", result); - ok (strlen(buffer) == 0, - "EM_STREAMIN: Test 3 set wrong text: Result: %s\n",buffer); + ok(!buffer[0], "EM_STREAMIN: Test 3 set wrong text: Result: %s\n",buffer); ok(es.dwError == -16, "EM_STREAMIN: Test 3 set error %d, expected %d\n", es.dwError, -16); es.dwCookie = (DWORD_PTR)&streamTextUTF8BOM; diff -Nru wine1.7-1.7.28/dlls/riched20/tests/txtsrv.c wine1.7-1.7.31/dlls/riched20/tests/txtsrv.c --- wine1.7-1.7.28/dlls/riched20/tests/txtsrv.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/riched20/tests/txtsrv.c 2014-11-14 13:28:17.000000000 +0000 @@ -29,6 +29,8 @@ #include #include #include +#include +#include #include #include #include @@ -862,6 +864,72 @@ IUnknown_Release(unk_obj.inner_unk); } +static ULONG get_refcount(IUnknown *iface) +{ + IUnknown_AddRef(iface); + return IUnknown_Release(iface); +} + +static void test_QueryInterface(void) +{ + HRESULT hres; + IRichEditOle *reole, *txtsrv_reole; + ITextDocument *txtdoc, *txtsrv_txtdoc; + ULONG refcount; + + if(!init_texthost()) + return; + + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 1, "got wrong ref count: %d\n", refcount); + + /* IID_IRichEditOle */ + hres = ITextServices_QueryInterface(txtserv, &IID_IRichEditOle, (void **)&txtsrv_reole); + ok(hres == S_OK, "ITextServices_QueryInterface: 0x%08x\n", hres); + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 2, "got wrong ref count: %d\n", refcount); + refcount = get_refcount((IUnknown *)txtsrv_reole); + ok(refcount == 2, "got wrong ref count: %d\n", refcount); + + hres = IRichEditOle_QueryInterface(txtsrv_reole, &IID_ITextDocument, (void **)&txtdoc); + ok(hres == S_OK, "IRichEditOle_QueryInterface: 0x%08x\n", hres); + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 3, "got wrong ref count: %d\n", refcount); + refcount = get_refcount((IUnknown *)txtsrv_reole); + ok(refcount == 3, "got wrong ref count: %d\n", refcount); + + ITextDocument_Release(txtdoc); + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 2, "got wrong ref count: %d\n", refcount); + IRichEditOle_Release(txtsrv_reole); + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 1, "got wrong ref count: %d\n", refcount); + + /* IID_ITextDocument */ + hres = ITextServices_QueryInterface(txtserv, &IID_ITextDocument, (void **)&txtsrv_txtdoc); + ok(hres == S_OK, "ITextServices_QueryInterface: 0x%08x\n", hres); + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 2, "got wrong ref count: %d\n", refcount); + refcount = get_refcount((IUnknown *)txtsrv_txtdoc); + ok(refcount == 2, "got wrong ref count: %d\n", refcount); + + hres = ITextDocument_QueryInterface(txtsrv_txtdoc, &IID_IRichEditOle, (void **)&reole); + ok(hres == S_OK, "ITextDocument_QueryInterface: 0x%08x\n", hres); + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 3, "got wrong ref count: %d\n", refcount); + refcount = get_refcount((IUnknown *)txtsrv_txtdoc); + ok(refcount == 3, "got wrong ref count: %d\n", refcount); + + IRichEditOle_Release(reole); + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 2, "got wrong ref count: %d\n", refcount); + ITextDocument_Release(txtsrv_txtdoc); + refcount = get_refcount((IUnknown *)txtserv); + ok(refcount == 1, "got wrong ref count: %d\n", refcount); + + free_texthost(); +} + START_TEST( txtsrv ) { setup_thiscall_wrappers(); @@ -887,6 +955,7 @@ test_TxSetText(); test_TxGetNaturalSize(); test_TxDraw(); + test_QueryInterface(); } if (wrapperCodeMem) VirtualFree(wrapperCodeMem, 0, MEM_RELEASE); } diff -Nru wine1.7-1.7.28/dlls/riched20/txtsrv.c wine1.7-1.7.31/dlls/riched20/txtsrv.c --- wine1.7-1.7.28/dlls/riched20/txtsrv.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/riched20/txtsrv.c 2014-11-14 13:28:17.000000000 +0000 @@ -29,6 +29,7 @@ #include "ole2.h" #include "oleauto.h" #include "richole.h" +#include "tom.h" #include "imm.h" #include "textserv.h" #include "wine/debug.h" @@ -79,7 +80,15 @@ *ppv = &This->IUnknown_inner; else if (IsEqualIID(riid, &IID_ITextServices)) *ppv = &This->ITextServices_iface; - else { + else if (IsEqualIID(riid, &IID_IRichEditOle) || IsEqualIID(riid, &IID_ITextDocument)) { + if (!This->editor->reOle) + if (!CreateIRichEditOle(This->outer_unk, This->editor, (void **)(&This->editor->reOle))) + return E_OUTOFMEMORY; + if (IsEqualIID(riid, &IID_ITextDocument)) + ME_GetITextDocumentInterface(This->editor->reOle, ppv); + else + *ppv = This->editor->reOle; + } else { *ppv = NULL; FIXME("Unknown interface: %s\n", debugstr_guid(riid)); return E_NOINTERFACE; @@ -108,7 +117,7 @@ if (!ref) { - ITextHost_Release(This->pMyHost); + ME_DestroyEditor(This->editor); This->csTxtSrv.DebugInfo->Spare[0] = 0; DeleteCriticalSection(&This->csTxtSrv); CoTaskMemFree(This); diff -Nru wine1.7-1.7.28/dlls/rpcrt4/tests/cstub.c wine1.7-1.7.31/dlls/rpcrt4/tests/cstub.c --- wine1.7-1.7.28/dlls/rpcrt4/tests/cstub.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/rpcrt4/tests/cstub.c 2014-11-14 13:28:17.000000000 +0000 @@ -288,12 +288,6 @@ 0, 0}; - -static const PRPC_STUB_FUNCTION if3_table[] = -{ - if1_fn1_Stub -}; - static CInterfaceStubVtbl if3_stub_vtbl = { { @@ -338,15 +332,6 @@ 0, 0}; - -static const PRPC_STUB_FUNCTION if4_table[] = -{ - STUB_FORWARDING_FUNCTION, - STUB_FORWARDING_FUNCTION, - STUB_FORWARDING_FUNCTION, - STUB_FORWARDING_FUNCTION, -}; - static CInterfaceStubVtbl if4_stub_vtbl = { { diff -Nru wine1.7-1.7.28/dlls/secur32/tests/schannel.c wine1.7-1.7.31/dlls/secur32/tests/schannel.c --- wine1.7-1.7.28/dlls/secur32/tests/schannel.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/secur32/tests/schannel.c 2014-11-14 13:28:17.000000000 +0000 @@ -533,7 +533,7 @@ cred->aphMappers = NULL; cred->cSupportedAlgs = 0; cred->palgSupportedAlgs = NULL; - cred->grbitEnabledProtocols = SP_PROT_SSL3_CLIENT; + cred->grbitEnabledProtocols = SP_PROT_TLS1_CLIENT; cred->dwMinimumCipherStrength = 0; cred->dwMaximumCipherStrength = 0; cred->dwSessionLifespan = 0; @@ -685,7 +685,7 @@ ok(status == SEC_E_OK, "AcquireCredentialsHandleA failed: %08x\n", status); if (status != SEC_E_OK) return; - test_supported_protocols(&cred_handle, SP_PROT_SSL3_CLIENT); + test_supported_protocols(&cred_handle, SP_PROT_TLS1_CLIENT); /* Initialize the connection */ init_buffers(&buffers[0], 4, buf_size); diff -Nru wine1.7-1.7.28/dlls/setupapi/setupapi.spec wine1.7-1.7.31/dlls/setupapi/setupapi.spec --- wine1.7-1.7.28/dlls/setupapi/setupapi.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/setupapi/setupapi.spec 2014-11-14 13:28:17.000000000 +0000 @@ -95,8 +95,8 @@ @ stub CM_Get_Device_Interface_ListW @ stub CM_Get_Device_Interface_List_ExA @ stub CM_Get_Device_Interface_List_ExW -@ stub CM_Get_Device_Interface_List_SizeA -@ stub CM_Get_Device_Interface_List_SizeW +@ stdcall CM_Get_Device_Interface_List_SizeA(ptr ptr str long) +@ stdcall CM_Get_Device_Interface_List_SizeW(ptr ptr wstr long) @ stdcall CM_Get_Device_Interface_List_Size_ExA(ptr ptr str long ptr) @ stdcall CM_Get_Device_Interface_List_Size_ExW(ptr ptr wstr long ptr) @ stub CM_Get_First_Log_Conf diff -Nru wine1.7-1.7.28/dlls/setupapi/stubs.c wine1.7-1.7.31/dlls/setupapi/stubs.c --- wine1.7-1.7.28/dlls/setupapi/stubs.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/setupapi/stubs.c 2014-11-14 13:28:17.000000000 +0000 @@ -367,6 +367,26 @@ } /*********************************************************************** + * CM_Get_Device_Interface_List_SizeA (SETUPAPI.@) + */ +CONFIGRET WINAPI CM_Get_Device_Interface_List_SizeA(PULONG len, LPGUID class, DEVINSTID_A id, + ULONG flags) +{ + FIXME("%p %p %s 0x%08x: stub\n", len, class, debugstr_a(id), flags); + return CR_FAILURE; +} + +/*********************************************************************** + * CM_Get_Device_Interface_List_SizeW (SETUPAPI.@) + */ +CONFIGRET WINAPI CM_Get_Device_Interface_List_SizeW(PULONG len, LPGUID class, DEVINSTID_W id, + ULONG flags) +{ + FIXME("%p %p %s 0x%08x: stub\n", len, class, debugstr_w(id), flags); + return CR_FAILURE; +} + +/*********************************************************************** * CM_Get_Device_Interface_List_Size_ExA (SETUPAPI.@) */ CONFIGRET WINAPI CM_Get_Device_Interface_List_Size_ExA(PULONG len, LPGUID class, DEVINSTID_A id, diff -Nru wine1.7-1.7.28/dlls/shell32/shell32.spec wine1.7-1.7.31/dlls/shell32/shell32.spec --- wine1.7-1.7.28/dlls/shell32/shell32.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shell32/shell32.spec 2014-11-14 13:28:17.000000000 +0000 @@ -324,7 +324,7 @@ @ stub RealShellExecuteExA @ stub RealShellExecuteExW @ stub RealShellExecuteW -@ stub RegenerateUserEnvironment +@ stdcall RegenerateUserEnvironment(ptr long) @ stdcall SetCurrentProcessExplicitAppUserModelID(wstr) @ stdcall SHAddToRecentDocs (long ptr) @ stdcall SHAppBarMessage(long ptr) diff -Nru wine1.7-1.7.28/dlls/shell32/shellord.c wine1.7-1.7.31/dlls/shell32/shellord.c --- wine1.7-1.7.28/dlls/shell32/shellord.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shell32/shellord.c 2014-11-14 13:28:17.000000000 +0000 @@ -947,7 +947,7 @@ /* buffer size looks good */ ptr += 12; /* get to string */ len = bufused - (ptr-buffer); /* get length of buf remaining */ - if ((lstrlenA(ptr) > 0) && (lstrlenA(ptr) <= len-1)) { + if (ptr[0] && (lstrlenA(ptr) <= len-1)) { /* appears to be good string */ lstrcpyA(old_lnk_name, link_dir); PathAppendA(old_lnk_name, ptr); diff -Nru wine1.7-1.7.28/dlls/shell32/shellpath.c wine1.7-1.7.31/dlls/shell32/shellpath.c --- wine1.7-1.7.28/dlls/shell32/shellpath.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shell32/shellpath.c 2014-11-14 13:28:17.000000000 +0000 @@ -2097,7 +2097,7 @@ DWORD ret = ExpandEnvironmentStringsW(szSrc, szDest, MAX_PATH); if (ret > MAX_PATH) - hr = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + hr = E_NOT_SUFFICIENT_BUFFER; else if (ret == 0) hr = HRESULT_FROM_WIN32(GetLastError()); else diff -Nru wine1.7-1.7.28/dlls/shell32/shfldr_desktop.c wine1.7-1.7.31/dlls/shell32/shfldr_desktop.c --- wine1.7-1.7.28/dlls/shell32/shfldr_desktop.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shell32/shfldr_desktop.c 2014-11-14 13:28:17.000000000 +0000 @@ -247,7 +247,7 @@ else { /* should never reach here, but for completeness */ - hr = HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + hr = E_NOT_SUFFICIENT_BUFFER; } } } diff -Nru wine1.7-1.7.28/dlls/shell32/shlexec.c wine1.7-1.7.31/dlls/shell32/shlexec.c --- wine1.7-1.7.28/dlls/shell32/shlexec.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shell32/shlexec.c 2014-11-14 13:28:17.000000000 +0000 @@ -2097,3 +2097,12 @@ { FIXME("%p, %p, %s, %d\n", hwnd, hinst, debugstr_w(cmdline), cmdshow); } + +/************************************************************************* + * RegenerateUserEnvironment [SHELL32.@] + */ +BOOL WINAPI RegenerateUserEnvironment(WCHAR *wunknown, BOOL bunknown) +{ + FIXME("stub: %p, %d\n", wunknown, bunknown); + return FALSE; +} diff -Nru wine1.7-1.7.28/dlls/shell32/tests/ebrowser.c wine1.7-1.7.31/dlls/shell32/tests/ebrowser.c --- wine1.7-1.7.28/dlls/shell32/tests/ebrowser.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shell32/tests/ebrowser.c 2014-11-14 13:28:17.000000000 +0000 @@ -1381,7 +1381,7 @@ ok(pSHCreateShellItem != NULL, "pSHCreateShellItem unexpectedly missing.\n"); GetCurrentDirectoryW(MAX_PATH, current_path); - if(!lstrlenW(current_path)) + if(!current_path[0]) { skip("Failed to create test-directory.\n"); return; diff -Nru wine1.7-1.7.28/dlls/shell32/tests/shellpath.c wine1.7-1.7.31/dlls/shell32/tests/shellpath.c --- wine1.7-1.7.28/dlls/shell32/tests/shellpath.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shell32/tests/shellpath.c 2014-11-14 13:28:17.000000000 +0000 @@ -878,7 +878,7 @@ ok(hr == E_INVALIDARG, "expected E_INVALIDARG, got 0x%08x\n", hr); } hr = pSHGetFolderPathEx(&FOLDERID_Desktop, 0, NULL, buffer, len); - ok(hr == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), "expected 0x8007007a, got 0x%08x\n", hr); + ok(hr == E_NOT_SUFFICIENT_BUFFER, "expected E_NOT_SUFFICIENT_BUFFER, got 0x%08x\n", hr); hr = pSHGetFolderPathEx(&FOLDERID_Desktop, 0, NULL, buffer, len + 1); ok(hr == S_OK, "expected S_OK, got 0x%08x\n", hr); diff -Nru wine1.7-1.7.28/dlls/shell32/tests/shlfolder.c wine1.7-1.7.31/dlls/shell32/tests/shlfolder.c --- wine1.7-1.7.28/dlls/shell32/tests/shlfolder.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shell32/tests/shlfolder.c 2014-11-14 13:28:17.000000000 +0000 @@ -81,7 +81,7 @@ WCHAR *ret; int len; - if(!str || strlen(str) == 0) + if (!str || !str[0]) return NULL; len = MultiByteToWideChar(CP_ACP, 0, str, -1, NULL, 0); @@ -2203,7 +2203,7 @@ return; } - if (!lstrlenA(curdirA)) + if (!curdirA[0]) { win_skip("GetCurrentDirectoryA returned empty string, skipping test_SHCreateShellItem\n"); return; @@ -2780,7 +2780,7 @@ } GetCurrentDirectoryW(MAX_PATH, curdirW); - if(!lstrlenW(curdirW)) + if (!curdirW[0]) { skip("Failed to get current directory, skipping.\n"); return; @@ -4387,7 +4387,7 @@ } GetCurrentDirectoryW(MAX_PATH, path); - if(!lstrlenW(path)) + if (!path[0]) { skip("GetCurrentDirectoryW returned an empty string.\n"); return; @@ -4989,8 +4989,8 @@ exp_data->missing_events = exp_data->notify_count; SHChangeNotify(exp_data->signal, SHCNF_PATHA | SHCNF_FLUSH, - strlen(exp_data->path_1) > 0 ? exp_data->path_1 : NULL, - strlen(exp_data->path_2) > 0 ? exp_data->path_2 : NULL); + exp_data->path_1[0] ? exp_data->path_1 : NULL, + exp_data->path_2[0] ? exp_data->path_2 : NULL); do_events(); ok(exp_data->missing_events == 0, "%s: Expected wndproc to be called\n", exp_data->id); @@ -5045,7 +5045,7 @@ } GetCurrentDirectoryW(MAX_PATH, path); - if(!lstrlenW(path)) + if (!path[0]) { skip("GetCurrentDirectoryW returned an empty string.\n"); return; diff -Nru wine1.7-1.7.28/dlls/shlwapi/ordinal.c wine1.7-1.7.31/dlls/shlwapi/ordinal.c --- wine1.7-1.7.28/dlls/shlwapi/ordinal.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shlwapi/ordinal.c 2014-11-14 13:28:17.000000000 +0000 @@ -453,7 +453,7 @@ * Success: S_OK. langbuf is set to the language string found. * Failure: E_FAIL, If any arguments are invalid, error occurred, or Explorer * does not contain the setting. - * HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), If the buffer is not big enough + * E_NOT_SUFFICIENT_BUFFER, If the buffer is not big enough */ HRESULT WINAPI GetAcceptLanguagesW( LPWSTR langbuf, LPDWORD buflen) { @@ -506,7 +506,7 @@ } *buflen = 0; - return __HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; } /************************************************************************* diff -Nru wine1.7-1.7.28/dlls/shlwapi/tests/ordinal.c wine1.7-1.7.31/dlls/shlwapi/tests/ordinal.c --- wine1.7-1.7.28/dlls/shlwapi/tests/ordinal.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shlwapi/tests/ordinal.c 2014-11-14 13:28:17.000000000 +0000 @@ -290,14 +290,14 @@ When the buffer is large enough, the default language is returned When the buffer is too small for that fallback, win7_32 and w2k8_64 - fail with HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), win8 fails - with HRESULT_FROM_WIN32(ERROR_MORE_DATA), other versions succeed and - return a partial result while older os succeed and overflow the buffer */ + fail with E_NOT_SUFFICIENT_BUFFER, win8 fails with HRESULT_FROM_WIN32(ERROR_MORE_DATA), + other versions succeed and return a partial result while older os succeed + and overflow the buffer */ ok(((hr == E_INVALIDARG) && (len == 0)) || (((hr == S_OK) && !lstrcmpA(buffer, language) && (len == lstrlenA(language))) || ((hr == S_OK) && !memcmp(buffer, language, len)) || - ((hr == __HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER)) && !len) || + ((hr == E_NOT_SUFFICIENT_BUFFER) && !len) || ((hr == __HRESULT_FROM_WIN32(ERROR_MORE_DATA)) && len == exactsize)), "==_#%d: got 0x%x with %d and %s\n", i, hr, len, buffer); @@ -309,7 +309,7 @@ ok(((hr == E_INVALIDARG) && (len == 0)) || (((hr == S_OK) && !lstrcmpA(buffer, language) && (len == lstrlenA(language))) || ((hr == S_OK) && !memcmp(buffer, language, len)) || - ((hr == __HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER)) && !len) || + ((hr == E_NOT_SUFFICIENT_BUFFER) && !len) || ((hr == __HRESULT_FROM_WIN32(ERROR_MORE_DATA)) && len == exactsize - 1)), "-1_#%d: got 0x%x with %d and %s\n", i, hr, len, buffer); } @@ -321,7 +321,7 @@ ok(((hr == E_INVALIDARG) && (len == 0)) || (((hr == S_OK) && !lstrcmpA(buffer, language) && (len == lstrlenA(language))) || ((hr == S_OK) && !memcmp(buffer, language, len)) || - ((hr == __HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER)) && !len) || + ((hr == E_NOT_SUFFICIENT_BUFFER) && !len) || ((hr == __HRESULT_FROM_WIN32(ERROR_MORE_DATA)) && len == 1)), "=1_#%d: got 0x%x with %d and %s\n", i, hr, len, buffer); @@ -353,7 +353,7 @@ buffer[maxlen] = 0; hr = pGetAcceptLanguagesA( buffer, &len); ok( (((hr == S_OK) || (hr == E_INVALIDARG)) && !memcmp(buffer, language, len)) || - ((hr == __HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER)) && !len) || + ((hr == E_NOT_SUFFICIENT_BUFFER) && !len) || ((hr == __HRESULT_FROM_WIN32(ERROR_CANNOT_COPY)) && !len), "=2: got 0x%x with %d and %s\n", hr, len, buffer); @@ -362,11 +362,11 @@ buffer[maxlen] = 0; hr = pGetAcceptLanguagesA( buffer, &len); /* When the buffer is too small, win7_32 and w2k8_64 and above fail with - HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), win8 ERROR_CANNOT_COPY, + E_NOT_SUFFICIENT_BUFFER, win8 ERROR_CANNOT_COPY, other versions succeed and return a partial 0 terminated result while other versions fail with E_INVALIDARG and return a partial unterminated result */ ok( (((hr == S_OK) || (hr == E_INVALIDARG)) && !memcmp(buffer, language, len)) || - ((hr == __HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER)) && !len) || + ((hr == E_NOT_SUFFICIENT_BUFFER) && !len) || ((hr == __HRESULT_FROM_WIN32(ERROR_CANNOT_COPY)) && !len), "=1: got 0x%x with %d and %s\n", hr, len, buffer); diff -Nru wine1.7-1.7.28/dlls/shlwapi/tests/path.c wine1.7-1.7.31/dlls/shlwapi/tests/path.c --- wine1.7-1.7.28/dlls/shlwapi/tests/path.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shlwapi/tests/path.c 2014-11-14 13:28:17.000000000 +0000 @@ -634,8 +634,7 @@ ok(str == NULL || broken(str != NULL), /* Win95 and some W2K */ "Expected str == NULL, got %p\n", str); - ok(lstrlenA(dest) == 0 || - broken(!lstrcmpA(dest, "control")), /* Win95 and some W2K */ + ok(!dest[0] || broken(!lstrcmpA(dest, "control")), /* Win95 and some W2K */ "Expected 0 length, got %i\n", lstrlenA(dest)); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); @@ -724,8 +723,7 @@ lstrcpyA(dest, "control"); str = PathCombineA(dest, "C:\\", too_long); ok(str == NULL, "Expected str == NULL, got %p\n", str); - ok(lstrlenA(dest) == 0 || - broken(!lstrcmpA(dest, "control")), /* Win95 and some W2K */ + ok(!dest[0] || broken(!lstrcmpA(dest, "control")), /* Win95 and some W2K */ "Expected 0 length, got %i\n", lstrlenA(dest)); todo_wine ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); @@ -734,8 +732,7 @@ lstrcpyA(dest, "control"); str = PathCombineA(dest, too_long, "one\\two\\three"); ok(str == NULL, "Expected str == NULL, got %p\n", str); - ok(lstrlenA(dest) == 0 || - broken(!lstrcmpA(dest, "control")), /* Win95 and some W2K */ + ok(!dest[0] || broken(!lstrcmpA(dest, "control")), /* Win95 and some W2K */ "Expected 0 length, got %i\n", lstrlenA(dest)); todo_wine ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); @@ -749,8 +746,7 @@ lstrcpyA(dest, "control"); str = PathCombineA(dest, one, two); ok(str == NULL, "Expected str == NULL, got %p\n", str); - ok(lstrlenA(dest) == 0 || - broken(!lstrcmpA(dest, "control")), /* Win95 and some W2K */ + ok(!dest[0] || broken(!lstrcmpA(dest, "control")), /* Win95 and some W2K */ "Expected 0 length, got %i\n", lstrlenA(dest)); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); } @@ -772,7 +768,7 @@ SetLastError(0xdeadbeef); str = PathAddBackslashA(path); ok(str == (path + lstrlenA(path)), "Expected str to point to end of path, got %p\n", str); - ok(lstrlenA(path) == 0, "Expected empty string, got %i\n", lstrlenA(path)); + ok(!path[0], "Expected empty string, got %i\n", lstrlenA(path)); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); /* try a relative path */ @@ -917,8 +913,7 @@ res = PathAppendA(too_long, "two\\three"); ok(!res, "Expected failure\n"); todo_wine ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); - ok(lstrlenA(too_long) == 0 || - broken(lstrlenA(too_long) == (LONG_LEN - 1)), /* Win95 and some W2K */ + ok(!too_long[0] || broken(lstrlenA(too_long) == (LONG_LEN - 1)), /* Win95 and some W2K */ "Expected length of too_long to be zero, got %i\n", lstrlenA(too_long)); /* pszMore is too long */ @@ -929,8 +924,7 @@ res = PathAppendA(path, too_long); ok(!res, "Expected failure\n"); todo_wine ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); - ok(lstrlenA(path) == 0 || - broken(!lstrcmpA(path, "C:\\one")), /* Win95 and some W2K */ + ok(!path[0] || broken(!lstrcmpA(path, "C:\\one")), /* Win95 and some W2K */ "Expected length of path to be zero, got %i\n", lstrlenA(path)); /* both params combined are too long */ @@ -941,8 +935,7 @@ SetLastError(0xdeadbeef); res = PathAppendA(path, half); ok(!res, "Expected failure\n"); - ok(lstrlenA(path) == 0 || - broken(lstrlenA(path) == (HALF_LEN - 1)), /* Win95 and some W2K */ + ok(!path[0] || broken(lstrlenA(path) == (HALF_LEN - 1)), /* Win95 and some W2K */ "Expected length of path to be zero, got %i\n", lstrlenA(path)); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); } @@ -1092,7 +1085,7 @@ SetLastError(0xdeadbeef); ext = PathFindExtensionA(path); ok(ext == path, "Expected ext == path, got %p\n", ext); - ok(lstrlenA(ext) == 0, "Expected length 0, got %i\n", lstrlenA(ext)); + ok(!ext[0], "Expected length 0, got %i\n", lstrlenA(ext)); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); /* try a path without an extension */ @@ -1100,7 +1093,7 @@ SetLastError(0xdeadbeef); ext = PathFindExtensionA(path); ok(ext == path + lstrlenA(path), "Expected ext == path, got %p\n", ext); - ok(lstrlenA(ext) == 0, "Expected length 0, got %i\n", lstrlenA(ext)); + ok(!ext[0], "Expected length 0, got %i\n", lstrlenA(ext)); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); /* try a path with an extension */ @@ -1169,8 +1162,7 @@ lstrcpyA(path, "aaaaaaaaa"); root = PathBuildRootA(path, -1); ok(root == path, "Expected root == path, got %p\n", root); - ok(!lstrcmpA(path, "aaaaaaaaa") || - lstrlenA(path) == 0, /* Vista */ + ok(!lstrcmpA(path, "aaaaaaaaa") || !path[0], /* Vista */ "Expected aaaaaaaaa or empty string, got %s\n", path); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); @@ -1179,8 +1171,7 @@ lstrcpyA(path, "aaaaaaaaa"); root = PathBuildRootA(path, 26); ok(root == path, "Expected root == path, got %p\n", root); - ok(!lstrcmpA(path, "aaaaaaaaa") || - lstrlenA(path) == 0, /* Vista */ + ok(!lstrcmpA(path, "aaaaaaaaa") || !path[0], /* Vista */ "Expected aaaaaaaaa or empty string, got %s\n", path); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); @@ -1238,8 +1229,8 @@ lstrcpyA(out, "aaa"); count = PathCommonPrefixA(path1, path2, out); ok(count == 0, "Expected 0, got %i\n", count); - ok(lstrlenA(out) == 0, "Expected 0 length out, got %i\n", lstrlenA(out)); - ok(lstrlenA(path1) == 0, "Expected 0 length path1, got %i\n", lstrlenA(path1)); + ok(!out[0], "Expected 0 length out, got %i\n", lstrlenA(out)); + ok(!path1[0], "Expected 0 length path1, got %i\n", lstrlenA(path1)); ok(!lstrcmpA(path2, "C:\\"), "Expected C:\\, got %s\n", path2); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); @@ -1250,8 +1241,8 @@ lstrcpyA(out, "aaa"); count = PathCommonPrefixA(path1, path2, out); ok(count == 0, "Expected 0, got %i\n", count); - ok(lstrlenA(out) == 0, "Expected 0 length out, got %i\n", lstrlenA(out)); - ok(lstrlenA(path2) == 0, "Expected 0 length path2, got %i\n", lstrlenA(path2)); + ok(!out[0], "Expected 0 length out, got %i\n", lstrlenA(out)); + ok(!path2[0], "Expected 0 length path2, got %i\n", lstrlenA(path2)); ok(!lstrcmpA(path1, "C:\\"), "Expected C:\\, got %s\n", path1); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); @@ -1406,7 +1397,7 @@ ok(count == 0, "Expected 0, got %i\n", count); ok(!lstrcmpA(path1, "one\\..\\two"), "Expected one\\..\\two, got %s\n", path1); ok(!lstrcmpA(path2, "two"), "Expected two, got %s\n", path2); - ok(lstrlenA(out) == 0, "Expected 0 length out, got %i\n", lstrlenA(out)); + ok(!out[0], "Expected 0 length out, got %i\n", lstrlenA(out)); ok(GetLastError() == 0xdeadbeef, "Expected 0xdeadbeef, got %d\n", GetLastError()); } diff -Nru wine1.7-1.7.28/dlls/shlwapi/tests/string.c wine1.7-1.7.31/dlls/shlwapi/tests/string.c --- wine1.7-1.7.28/dlls/shlwapi/tests/string.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/shlwapi/tests/string.c 2014-11-14 13:28:17.000000000 +0000 @@ -1058,7 +1058,7 @@ memset(wbuf, 0xbf, sizeof(wbuf)); strret.uType = STRRET_WSTR; U(strret).pOleStr = StrDupW(wstr1); - expect_eq2(pStrRetToBufW(&strret, NULL, wbuf, 10), S_OK, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER) /* Vista */, HRESULT, "%x"); + expect_eq2(pStrRetToBufW(&strret, NULL, wbuf, 10), S_OK, E_NOT_SUFFICIENT_BUFFER /* Vista */, HRESULT, "%x"); expect_eq(wbuf[9], 0, WCHAR, "%x"); expect_eq(wbuf[10], (WCHAR)0xbfbf, WCHAR, "%x"); } @@ -1070,7 +1070,7 @@ memset(buf, 0xbf, sizeof(buf)); strret.uType = STRRET_CSTR; StrCpyNA(U(strret).cStr, str1, MAX_PATH); - expect_eq2(pStrRetToBufA(&strret, NULL, buf, 10), S_OK, HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER) /* Vista */, HRESULT, "%x"); + expect_eq2(pStrRetToBufA(&strret, NULL, buf, 10), S_OK, E_NOT_SUFFICIENT_BUFFER /* Vista */, HRESULT, "%x"); expect_eq(buf[9], 0, CHAR, "%x"); expect_eq(buf[10], (CHAR)0xbf, CHAR, "%x"); } diff -Nru wine1.7-1.7.28/dlls/slc/slc.c wine1.7-1.7.31/dlls/slc/slc.c --- wine1.7-1.7.28/dlls/slc/slc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/slc/slc.c 2014-11-14 13:28:17.000000000 +0000 @@ -28,7 +28,14 @@ WINE_DEFAULT_DEBUG_CHANNEL(slc); -DWORD WINAPI SLGetWindowsInformationDWORD(LPCWSTR lpszValueName, LPDWORD pdwValue) +HRESULT WINAPI SLGetWindowsInformation(LPCWSTR name, SLDATATYPE *type, UINT *val, LPBYTE *size) +{ + FIXME("(%s %p %p %p) stub\n", debugstr_w(name), type, val, size ); + + return SL_E_RIGHT_NOT_GRANTED; +} + +HRESULT WINAPI SLGetWindowsInformationDWORD(LPCWSTR lpszValueName, LPDWORD pdwValue) { FIXME("(%s) stub\n", debugstr_w(lpszValueName) ); diff -Nru wine1.7-1.7.28/dlls/slc/slc.spec wine1.7-1.7.31/dlls/slc/slc.spec --- wine1.7-1.7.28/dlls/slc/slc.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/slc/slc.spec 2014-11-14 13:28:17.000000000 +0000 @@ -25,7 +25,7 @@ @ stub SLGetSAMLicense @ stub SLGetSLIDList @ stub SLGetServiceInformation -@ stub SLGetWindowsInformation +@ stdcall SLGetWindowsInformation(wstr ptr ptr ptr) @ stdcall SLGetWindowsInformationDWORD(wstr ptr) @ stub SLInstallLicense @ stub SLInstallProofOfPurchase diff -Nru wine1.7-1.7.28/dlls/strmbase/pin.c wine1.7-1.7.31/dlls/strmbase/pin.c --- wine1.7-1.7.28/dlls/strmbase/pin.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/strmbase/pin.c 2014-11-14 13:28:17.000000000 +0000 @@ -31,8 +31,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(strmbase); -static const IPinVtbl InputPin_Vtbl; -static const IPinVtbl OutputPin_Vtbl; static const IMemInputPinVtbl MemInputPin_Vtbl; typedef HRESULT (*SendPinFunc)( IPin *to, LPVOID arg ); @@ -555,28 +553,6 @@ return E_UNEXPECTED; } -static const IPinVtbl OutputPin_Vtbl = -{ - BaseOutputPinImpl_QueryInterface, - BasePinImpl_AddRef, - BaseOutputPinImpl_Release, - BaseOutputPinImpl_Connect, - BaseOutputPinImpl_ReceiveConnection, - BaseOutputPinImpl_Disconnect, - BasePinImpl_ConnectedTo, - BasePinImpl_ConnectionMediaType, - BasePinImpl_QueryPinInfo, - BasePinImpl_QueryDirection, - BasePinImpl_QueryId, - BasePinImpl_QueryAccept, - BasePinImpl_EnumMediaTypes, - BasePinImpl_QueryInternalConnections, - BaseOutputPinImpl_EndOfStream, - BaseOutputPinImpl_BeginFlush, - BaseOutputPinImpl_EndFlush, - BasePinImpl_NewSegment -}; - HRESULT WINAPI BaseOutputPinImpl_GetDeliveryBuffer(BaseOutputPin *This, IMediaSample ** ppSample, REFERENCE_TIME * tStart, REFERENCE_TIME * tStop, DWORD dwFlags) { HRESULT hr; @@ -861,11 +837,6 @@ return CONTAINING_RECORD(iface, BaseInputPin, pin.IPin_iface); } -static inline BaseInputPin *impl_BaseInputPin_from_BasePin( BasePin *iface ) -{ - return CONTAINING_RECORD(iface, BaseInputPin, pin); -} - HRESULT WINAPI BaseInputPinImpl_QueryInterface(IPin * iface, REFIID riid, LPVOID * ppv) { BaseInputPin *This = impl_BaseInputPin_from_IPin(iface); @@ -1060,28 +1031,6 @@ return SendFurther( iface, deliver_newsegment, &args, NULL ); } -static const IPinVtbl InputPin_Vtbl = -{ - BaseInputPinImpl_QueryInterface, - BasePinImpl_AddRef, - BaseInputPinImpl_Release, - BaseInputPinImpl_Connect, - BaseInputPinImpl_ReceiveConnection, - BasePinImpl_Disconnect, - BasePinImpl_ConnectedTo, - BasePinImpl_ConnectionMediaType, - BasePinImpl_QueryPinInfo, - BasePinImpl_QueryDirection, - BasePinImpl_QueryId, - BaseInputPinImpl_QueryAccept, - BasePinImpl_EnumMediaTypes, - BasePinImpl_QueryInternalConnections, - BaseInputPinImpl_EndOfStream, - BaseInputPinImpl_BeginFlush, - BaseInputPinImpl_EndFlush, - BaseInputPinImpl_NewSegment -}; - /*** IMemInputPin implementation ***/ static inline BaseInputPin *impl_from_IMemInputPin( IMemInputPin *iface ) diff -Nru wine1.7-1.7.28/dlls/strmbase/transform.c wine1.7-1.7.31/dlls/strmbase/transform.c --- wine1.7-1.7.28/dlls/strmbase/transform.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/strmbase/transform.c 2014-11-14 13:28:17.000000000 +0000 @@ -42,7 +42,6 @@ static const WCHAR wcsInputPinName[] = {'i','n','p','u','t',' ','p','i','n',0}; static const WCHAR wcsOutputPinName[] = {'o','u','t','p','u','t',' ','p','i','n',0}; -static const IBaseFilterVtbl TransformFilter_Vtbl; static const IPinVtbl TransformFilter_InputPin_Vtbl; static const IPinVtbl TransformFilter_OutputPin_Vtbl; static const IQualityControlVtbl TransformFilter_QualityControl_Vtbl; @@ -439,25 +438,6 @@ return E_NOTIMPL; } -static const IBaseFilterVtbl TransformFilter_Vtbl = -{ - TransformFilterImpl_QueryInterface, - BaseFilterImpl_AddRef, - TransformFilterImpl_Release, - BaseFilterImpl_GetClassID, - TransformFilterImpl_Stop, - TransformFilterImpl_Pause, - TransformFilterImpl_Run, - BaseFilterImpl_GetState, - BaseFilterImpl_SetSyncSource, - BaseFilterImpl_GetSyncSource, - BaseFilterImpl_EnumPins, - TransformFilterImpl_FindPin, - BaseFilterImpl_QueryFilterInfo, - BaseFilterImpl_JoinFilterGraph, - BaseFilterImpl_QueryVendorInfo -}; - static HRESULT WINAPI TransformFilter_InputPin_EndOfStream(IPin * iface) { BaseInputPin* This = impl_BaseInputPin_from_IPin(iface); diff -Nru wine1.7-1.7.28/dlls/urlmon/protocol.c wine1.7-1.7.31/dlls/urlmon/protocol.c --- wine1.7-1.7.28/dlls/urlmon/protocol.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/urlmon/protocol.c 2014-11-14 13:28:17.000000000 +0000 @@ -302,6 +302,12 @@ return internet_session; } +void update_user_agent(WCHAR *user_agent) +{ + if(internet_session) + InternetSetOptionW(internet_session, INTERNET_OPTION_USER_AGENT, user_agent, strlenW(user_agent)); +} + HRESULT protocol_start(Protocol *protocol, IInternetProtocol *prot, IUri *uri, IInternetProtocolSink *protocol_sink, IInternetBindInfo *bind_info) { diff -Nru wine1.7-1.7.28/dlls/urlmon/sec_mgr.c wine1.7-1.7.31/dlls/urlmon/sec_mgr.c --- wine1.7-1.7.28/dlls/urlmon/sec_mgr.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/urlmon/sec_mgr.c 2014-11-14 13:28:17.000000000 +0000 @@ -740,7 +740,7 @@ if(len+sizeof(DWORD) > *secid_len) { SysFreeString(display_uri); - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; } WideCharToMultiByte(CP_ACP, 0, display_uri, -1, (LPSTR)secid, len, NULL, NULL); @@ -776,7 +776,7 @@ if(len+sizeof(DWORD) > *secid_len) { SysFreeString(host); SysFreeString(scheme); - return HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER); + return E_NOT_SUFFICIENT_BUFFER; } WideCharToMultiByte(CP_ACP, 0, scheme, -1, (LPSTR)secid, len, NULL, NULL); diff -Nru wine1.7-1.7.28/dlls/urlmon/session.c wine1.7-1.7.31/dlls/urlmon/session.c --- wine1.7-1.7.28/dlls/urlmon/session.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/urlmon/session.c 2014-11-14 13:28:17.000000000 +0000 @@ -718,6 +718,7 @@ heap_free(user_agent); user_agent = new_user_agent; + update_user_agent(user_agent); LeaveCriticalSection(&session_cs); break; diff -Nru wine1.7-1.7.28/dlls/urlmon/tests/protocol.c wine1.7-1.7.31/dlls/urlmon/tests/protocol.c --- wine1.7-1.7.28/dlls/urlmon/tests/protocol.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/urlmon/tests/protocol.c 2014-11-14 13:28:17.000000000 +0000 @@ -1991,7 +1991,9 @@ memcpy(pv, "gif87a", 6); prot_read += *pcbRead = cb; return S_OK; - }if(prot_state == 4) { + } + + if(prot_state == 4) { *pcbRead = 0; return S_FALSE; } @@ -2925,7 +2927,7 @@ ok(hres == S_OK, "LockRequest failed: %08x\n", hres); hres = IInternetProtocol_Read(protocol, buf, 1, &cb); - ok(hres == test_abort ? S_OK : S_FALSE, "Read failed: %08x\n", hres); + ok(hres == (test_abort ? S_OK : S_FALSE), "Read failed: %08x\n", hres); hres = IInternetProtocol_Terminate(protocol, 0); ok(hres == S_OK, "Terminate failed: %08x\n", hres); diff -Nru wine1.7-1.7.28/dlls/urlmon/tests/url.c wine1.7-1.7.31/dlls/urlmon/tests/url.c --- wine1.7-1.7.28/dlls/urlmon/tests/url.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/urlmon/tests/url.c 2014-11-14 13:28:17.000000000 +0000 @@ -764,7 +764,7 @@ } IHttpNegotiate2_Release(http_negotiate2); ok(hres == E_FAIL, "GetRootSecurityId failed: %08x, expected E_FAIL\n", hres); - ok(size == no_callback ? 512 : 13, "size=%d\n", size); + ok(size == (no_callback ? 512 : 13), "size=%d\n", size); if(!no_callback) { SET_EXPECT(QueryService_IHttpSecurity); diff -Nru wine1.7-1.7.28/dlls/urlmon/urlmon_main.h wine1.7-1.7.31/dlls/urlmon/urlmon_main.h --- wine1.7-1.7.28/dlls/urlmon/urlmon_main.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/urlmon/urlmon_main.h 2014-11-14 13:28:17.000000000 +0000 @@ -72,7 +72,8 @@ BOOL is_registered_protocol(LPCWSTR) DECLSPEC_HIDDEN; HRESULT register_namespace(IClassFactory*,REFIID,LPCWSTR,BOOL) DECLSPEC_HIDDEN; HINTERNET get_internet_session(IInternetBindInfo*) DECLSPEC_HIDDEN; -LPWSTR get_useragent(void) DECLSPEC_HIDDEN; +WCHAR *get_useragent(void) DECLSPEC_HIDDEN; +void update_user_agent(WCHAR*) DECLSPEC_HIDDEN; void free_session(void) DECLSPEC_HIDDEN; HRESULT bind_to_storage(IUri*,IBindCtx*,REFIID,void**) DECLSPEC_HIDDEN; diff -Nru wine1.7-1.7.28/dlls/user32/class.c wine1.7-1.7.31/dlls/user32/class.c --- wine1.7-1.7.28/dlls/user32/class.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/class.c 2014-11-14 13:28:17.000000000 +0000 @@ -447,6 +447,7 @@ register_builtin( &MENU_builtin_class ); register_builtin( &SCROLL_builtin_class ); register_builtin( &STATIC_builtin_class ); + register_builtin( &IME_builtin_class ); return TRUE; } diff -Nru wine1.7-1.7.28/dlls/user32/combo.c wine1.7-1.7.31/dlls/user32/combo.c --- wine1.7-1.7.28/dlls/user32/combo.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/combo.c 2014-11-14 13:28:17.000000000 +0000 @@ -1059,7 +1059,7 @@ r.bottom = min( r.top + nDroppedHeight, mon_info.rcWork.bottom ); } - SetWindowPos( lphc->hWndLBox, HWND_TOP, r.left, r.top, r.right - r.left, r.bottom - r.top, + SetWindowPos( lphc->hWndLBox, HWND_TOPMOST, r.left, r.top, r.right - r.left, r.bottom - r.top, SWP_NOACTIVATE | SWP_SHOWWINDOW ); diff -Nru wine1.7-1.7.28/dlls/user32/controls.h wine1.7-1.7.31/dlls/user32/controls.h --- wine1.7-1.7.28/dlls/user32/controls.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/controls.h 2014-11-14 13:28:17.000000000 +0000 @@ -42,6 +42,7 @@ WINPROC_MDICLIENT, WINPROC_SCROLLBAR, WINPROC_STATIC, + WINPROC_IME, /* unicode-only procs */ WINPROC_DESKTOP, WINPROC_ICONTITLE, @@ -78,7 +79,10 @@ extern const struct builtin_class_descr MESSAGE_builtin_class DECLSPEC_HIDDEN; extern const struct builtin_class_descr SCROLL_builtin_class DECLSPEC_HIDDEN; extern const struct builtin_class_descr STATIC_builtin_class DECLSPEC_HIDDEN; +extern const struct builtin_class_descr IME_builtin_class DECLSPEC_HIDDEN; +extern LRESULT WINAPI ImeWndProcA(HWND,UINT,WPARAM,LPARAM); +extern LRESULT WINAPI ImeWndProcW(HWND,UINT,WPARAM,LPARAM); extern LRESULT WINAPI DesktopWndProc(HWND,UINT,WPARAM,LPARAM) DECLSPEC_HIDDEN; extern LRESULT WINAPI IconTitleWndProc(HWND,UINT,WPARAM,LPARAM) DECLSPEC_HIDDEN; extern LRESULT WINAPI PopupMenuWndProc(HWND,UINT,WPARAM,LPARAM) DECLSPEC_HIDDEN; diff -Nru wine1.7-1.7.28/dlls/user32/message.c wine1.7-1.7.31/dlls/user32/message.c --- wine1.7-1.7.28/dlls/user32/message.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/message.c 2014-11-14 13:28:17.000000000 +0000 @@ -2266,13 +2266,12 @@ * Tell the server we have passed the message to the app * (even though we may end up dropping it later on) */ -static void accept_hardware_message( UINT hw_id, BOOL remove, HWND new_hwnd ) +static void accept_hardware_message( UINT hw_id, BOOL remove ) { SERVER_START_REQ( accept_hardware_message ) { req->hw_id = hw_id; req->remove = remove; - req->new_win = wine_server_user_handle( new_hwnd ); if (wine_server_call( req )) FIXME("Failed to reply to MSG_HARDWARE message. Message may not be removed from queue.\n"); } @@ -2460,10 +2459,10 @@ { /* skip this message */ HOOK_CallHooks( WH_CBT, HCBT_KEYSKIPPED, LOWORD(msg->wParam), msg->lParam, TRUE ); - accept_hardware_message( hw_id, TRUE, 0 ); + accept_hardware_message( hw_id, TRUE ); return FALSE; } - accept_hardware_message( hw_id, remove, 0 ); + accept_hardware_message( hw_id, remove ); if ( remove && msg->message == WM_KEYDOWN ) if (ImmProcessKey(msg->hwnd, GetKeyboardLayout(0), msg->wParam, msg->lParam, 0) ) @@ -2507,7 +2506,7 @@ if (!msg->hwnd || !WIN_IsCurrentThread( msg->hwnd )) { - accept_hardware_message( hw_id, TRUE, msg->hwnd ); + accept_hardware_message( hw_id, TRUE ); return FALSE; } @@ -2596,7 +2595,7 @@ hook.wHitTestCode = hittest; hook.dwExtraInfo = extra_info; HOOK_CallHooks( WH_CBT, HCBT_CLICKSKIPPED, message, (LPARAM)&hook, TRUE ); - accept_hardware_message( hw_id, TRUE, 0 ); + accept_hardware_message( hw_id, TRUE ); return FALSE; } @@ -2604,11 +2603,11 @@ { SendMessageW( msg->hwnd, WM_SETCURSOR, (WPARAM)msg->hwnd, MAKELONG( hittest, msg->message )); - accept_hardware_message( hw_id, TRUE, 0 ); + accept_hardware_message( hw_id, TRUE ); return FALSE; } - accept_hardware_message( hw_id, remove, 0 ); + accept_hardware_message( hw_id, remove ); if (!remove || info.hwndCapture) { @@ -3935,7 +3934,7 @@ retval = CallWindowProcA( (WNDPROC)msg->lParam, msg->hwnd, msg->message, msg->wParam, GetTickCount() ); } - __EXCEPT_PAGE_FAULT + __EXCEPT_ALL { retval = 0; } @@ -4006,7 +4005,7 @@ retval = CallWindowProcW( (WNDPROC)msg->lParam, msg->hwnd, msg->message, msg->wParam, GetTickCount() ); } - __EXCEPT_PAGE_FAULT + __EXCEPT_ALL { retval = 0; } diff -Nru wine1.7-1.7.28/dlls/user32/misc.c wine1.7-1.7.31/dlls/user32/misc.c --- wine1.7-1.7.28/dlls/user32/misc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/misc.c 2014-11-14 13:28:17.000000000 +0000 @@ -29,6 +29,7 @@ #include "winuser.h" #include "winnls.h" #include "winternl.h" +#include "controls.h" #include "user_private.h" #include "wine/unicode.h" @@ -36,6 +37,18 @@ WINE_DEFAULT_DEBUG_CHANNEL(win); +#define IMM_INIT_MAGIC 0x19650412 +static HWND (WINAPI *imm_get_ui_window)(HKL); + +/* MSIME messages */ +static UINT WM_MSIME_SERVICE; +static UINT WM_MSIME_RECONVERTOPTIONS; +static UINT WM_MSIME_MOUSE; +static UINT WM_MSIME_RECONVERTREQUEST; +static UINT WM_MSIME_RECONVERT; +static UINT WM_MSIME_QUERYPOSITION; +static UINT WM_MSIME_DOCUMENTFEED; + /* USER signal proc flags and codes */ /* See UserSignalProc for comments */ #define USIG_FLAGS_WIN32 0x0001 @@ -597,10 +610,32 @@ /*********************************************************************** * User32InitializeImmEntryTable */ -BOOL WINAPI User32InitializeImmEntryTable(LPVOID ptr) +BOOL WINAPI User32InitializeImmEntryTable(DWORD magic) { - FIXME("(%p): stub\n", ptr); - return TRUE; + static const WCHAR imm32_dllW[] = {'i','m','m','3','2','.','d','l','l',0}; + HMODULE imm32 = GetModuleHandleW(imm32_dllW); + + TRACE("(%x)\n", magic); + + if (!imm32 || magic != IMM_INIT_MAGIC) + return FALSE; + + if (imm_get_ui_window) + return TRUE; + + WM_MSIME_SERVICE = RegisterWindowMessageA("MSIMEService"); + WM_MSIME_RECONVERTOPTIONS = RegisterWindowMessageA("MSIMEReconvertOptions"); + WM_MSIME_MOUSE = RegisterWindowMessageA("MSIMEMouseOperation"); + WM_MSIME_RECONVERTREQUEST = RegisterWindowMessageA("MSIMEReconvertRequest"); + WM_MSIME_RECONVERT = RegisterWindowMessageA("MSIMEReconvert"); + WM_MSIME_QUERYPOSITION = RegisterWindowMessageA("MSIMEQueryPosition"); + WM_MSIME_DOCUMENTFEED = RegisterWindowMessageA("MSIMEDocumentFeed"); + + /* this part is not compatible with native imm32.dll */ + imm_get_ui_window = (void*)GetProcAddress(imm32, "__wine_get_ui_window"); + if (!imm_get_ui_window) + FIXME("native imm32.dll not supported\n"); + return TRUE; } /********************************************************************** @@ -694,3 +729,78 @@ SetLastError(ERROR_CALL_NOT_IMPLEMENTED); return 0; } + +static const WCHAR imeW[] = {'I','M','E',0}; +const struct builtin_class_descr IME_builtin_class = +{ + imeW, /* name */ + 0, /* style */ + WINPROC_IME, /* proc */ + 2*sizeof(LONG_PTR), /* extra */ + IDC_ARROW, /* cursor */ + 0 /* brush */ +}; + +static BOOL is_ime_ui_msg( UINT msg ) +{ + switch(msg) { + case WM_IME_STARTCOMPOSITION: + case WM_IME_ENDCOMPOSITION: + case WM_IME_COMPOSITION: + case WM_IME_SETCONTEXT: + case WM_IME_NOTIFY: + case WM_IME_CONTROL: + case WM_IME_COMPOSITIONFULL: + case WM_IME_SELECT: + case WM_IME_CHAR: + case WM_IME_REQUEST: + case WM_IME_KEYDOWN: + case WM_IME_KEYUP: + return TRUE; + default: + if ((msg == WM_MSIME_RECONVERTOPTIONS) || + (msg == WM_MSIME_SERVICE) || + (msg == WM_MSIME_MOUSE) || + (msg == WM_MSIME_RECONVERTREQUEST) || + (msg == WM_MSIME_RECONVERT) || + (msg == WM_MSIME_QUERYPOSITION) || + (msg == WM_MSIME_DOCUMENTFEED)) + return TRUE; + + return FALSE; + } +} + +LRESULT WINAPI ImeWndProcA( HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam ) +{ + HWND uiwnd; + + if (msg==WM_CREATE || msg==WM_NCCREATE) + return TRUE; + + if (imm_get_ui_window && is_ime_ui_msg(msg)) + { + if ((uiwnd = imm_get_ui_window(GetKeyboardLayout(0)))) + return SendMessageA(uiwnd, msg, wParam, lParam); + return FALSE; + } + + return DefWindowProcA(hwnd, msg, wParam, lParam); +} + +LRESULT WINAPI ImeWndProcW( HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam ) +{ + HWND uiwnd; + + if (msg==WM_CREATE || msg==WM_NCCREATE) + return TRUE; + + if (imm_get_ui_window && is_ime_ui_msg(msg)) + { + if ((uiwnd = imm_get_ui_window(GetKeyboardLayout(0)))) + return SendMessageW(uiwnd, msg, wParam, lParam); + return FALSE; + } + + return DefWindowProcW(hwnd, msg, wParam, lParam); +} diff -Nru wine1.7-1.7.28/dlls/user32/painting.c wine1.7-1.7.31/dlls/user32/painting.c --- wine1.7-1.7.28/dlls/user32/painting.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/painting.c 2014-11-14 13:28:17.000000000 +0000 @@ -139,7 +139,7 @@ data->rdh.iType = RDH_RECTANGLES; data->rdh.nCount = reply_size / sizeof(RECT); data->rdh.nRgnSize = reply_size; - vis_rgn = ExtCreateRegion( NULL, size, data ); + vis_rgn = ExtCreateRegion( NULL, data->rdh.dwSize + data->rdh.nRgnSize, data ); top_win = wine_server_ptr_handle( reply->top_win ); win_rect.left = reply->win_rect.left; @@ -557,7 +557,7 @@ data->rdh.iType = RDH_RECTANGLES; data->rdh.nCount = reply_size / sizeof(RECT); data->rdh.nRgnSize = reply_size; - hrgn = ExtCreateRegion( NULL, size, data ); + hrgn = ExtCreateRegion( NULL, data->rdh.dwSize + data->rdh.nRgnSize, data ); if (child) *child = wine_server_ptr_handle( reply->child ); *flags = reply->flags; } diff -Nru wine1.7-1.7.28/dlls/user32/static.c wine1.7-1.7.31/dlls/user32/static.c --- wine1.7-1.7.28/dlls/user32/static.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/static.c 2014-11-14 13:28:17.000000000 +0000 @@ -775,19 +775,15 @@ GetClientRect(hwnd, &rcClient); if (style & SS_CENTERIMAGE) { - INT x, y; - x = (rcClient.right - rcClient.left)/2 - bm.bmWidth/2; - y = (rcClient.bottom - rcClient.top)/2 - bm.bmHeight/2; FillRect( hdc, &rcClient, hbrush ); - BitBlt(hdc, x, y, bm.bmWidth, bm.bmHeight, hMemDC, 0, 0, - SRCCOPY); - } - else - { - StretchBlt(hdc, 0, 0, rcClient.right - rcClient.left, - rcClient.bottom - rcClient.top, hMemDC, - 0, 0, bm.bmWidth, bm.bmHeight, SRCCOPY); + rcClient.left = (rcClient.right - rcClient.left)/2 - bm.bmWidth/2; + rcClient.top = (rcClient.bottom - rcClient.top)/2 - bm.bmHeight/2; + rcClient.right = rcClient.left + bm.bmWidth; + rcClient.bottom = rcClient.top + bm.bmHeight; } + StretchBlt(hdc, rcClient.left, rcClient.top, rcClient.right - rcClient.left, + rcClient.bottom - rcClient.top, hMemDC, + 0, 0, bm.bmWidth, bm.bmHeight, SRCCOPY); SelectObject(hMemDC, oldbitmap); DeleteDC(hMemDC); } diff -Nru wine1.7-1.7.28/dlls/user32/tests/class.c wine1.7-1.7.31/dlls/user32/tests/class.c --- wine1.7-1.7.28/dlls/user32/tests/class.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/tests/class.c 2014-11-14 13:28:17.000000000 +0000 @@ -1101,6 +1101,52 @@ } } +static void test_IME(void) +{ + static const WCHAR ime_classW[] = {'I','M','E',0}; + + char module_name[MAX_PATH], *ptr; + MEMORY_BASIC_INFORMATION mbi; + WNDCLASSW wnd_classw; + WNDCLASSA wnd_class; + SIZE_T size; + BOOL ret; + + if (!GetProcAddress(GetModuleHandleA("user32.dll"), "BroadcastSystemMessageExA")) + { + win_skip("BroadcastSystemMessageExA not available, skipping IME class test\n"); + return; + } + + ok(GetModuleHandleA("imm32") != 0, "imm32.dll is not loaded\n"); + + ret = GetClassInfoA(NULL, "IME", &wnd_class); + ok(ret, "GetClassInfo failed: %d\n", GetLastError()); + + size = VirtualQuery(wnd_class.lpfnWndProc, &mbi, sizeof(mbi)); + ok(size == sizeof(mbi), "VirtualQuery returned %ld\n", size); + if (size == sizeof(mbi)) { + size = GetModuleFileNameA(mbi.AllocationBase, module_name, sizeof(module_name)); + ok(size, "GetModuleFileName failed\n"); + for (ptr = module_name+size-1; ptr > module_name; ptr--) + if (*ptr == '\\' || *ptr == '/') break; + if (*ptr == '\\' || *ptr=='/') ptr++; + ok(!lstrcmpiA(ptr, "user32.dll") || !lstrcmpiA(ptr, "ntdll.dll"), "IME window proc implemented in %s\n", ptr); + } + + ret = GetClassInfoW(NULL, ime_classW, &wnd_classw); + ok(ret, "GetClassInfo failed: %d\n", GetLastError()); + + size = VirtualQuery(wnd_classw.lpfnWndProc, &mbi, sizeof(mbi)); + ok(size == sizeof(mbi), "VirtualQuery returned %ld\n", size); + size = GetModuleFileNameA(mbi.AllocationBase, module_name, sizeof(module_name)); + ok(size, "GetModuleFileName failed\n"); + for (ptr = module_name+size-1; ptr > module_name; ptr--) + if (*ptr == '\\' || *ptr == '/') break; + if (*ptr == '\\' || *ptr=='/') ptr++; + ok(!lstrcmpiA(ptr, "user32.dll") || !lstrcmpiA(ptr, "ntdll.dll"), "IME window proc implemented in %s\n", ptr); +} + START_TEST(class) { char **argv; @@ -1113,6 +1159,7 @@ return; } + test_IME(); test_GetClassInfo(); test_extra_values(); diff -Nru wine1.7-1.7.28/dlls/user32/tests/combo.c wine1.7-1.7.31/dlls/user32/tests/combo.c --- wine1.7-1.7.28/dlls/user32/tests/combo.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/tests/combo.c 2014-11-14 13:28:17.000000000 +0000 @@ -537,6 +537,61 @@ DestroyWindow(hCombo); } +static void test_listbox_styles(DWORD cb_style) +{ + BOOL (WINAPI *pGetComboBoxInfo)(HWND, PCOMBOBOXINFO); + HWND combo; + COMBOBOXINFO info; + DWORD style, exstyle, expect_style, expect_exstyle; + BOOL ret; + + pGetComboBoxInfo = (void*)GetProcAddress(GetModuleHandleA("user32.dll"), "GetComboBoxInfo"); + if (!pGetComboBoxInfo){ + win_skip("GetComboBoxInfo is not available\n"); + return; + } + + expect_style = WS_CHILD|WS_CLIPSIBLINGS|LBS_COMBOBOX|LBS_HASSTRINGS|LBS_NOTIFY; + if (cb_style == CBS_SIMPLE) + { + expect_style |= WS_VISIBLE; + expect_exstyle = WS_EX_CLIENTEDGE; + } + else + { + expect_style |= WS_BORDER; + expect_exstyle = WS_EX_TOOLWINDOW; + } + + combo = build_combo(cb_style); + info.cbSize = sizeof(COMBOBOXINFO); + SetLastError(0xdeadbeef); + ret = pGetComboBoxInfo(combo, &info); + ok(ret, "Failed to get combobox info structure.\n"); + + style = GetWindowLongW( info.hwndList, GWL_STYLE ); + exstyle = GetWindowLongW( info.hwndList, GWL_EXSTYLE ); + ok(style == expect_style, "%08x: got %08x\n", cb_style, style); + ok(exstyle == expect_exstyle, "%08x: got %08x\n", cb_style, exstyle); + + if (cb_style != CBS_SIMPLE) + expect_exstyle |= WS_EX_TOPMOST; + + SendMessageW(combo, CB_SHOWDROPDOWN, TRUE, 0 ); + style = GetWindowLongW( info.hwndList, GWL_STYLE ); + exstyle = GetWindowLongW( info.hwndList, GWL_EXSTYLE ); + ok(style == (expect_style | WS_VISIBLE), "%08x: got %08x\n", cb_style, style); + ok(exstyle == expect_exstyle, "%08x: got %08x\n", cb_style, exstyle); + + SendMessageW(combo, CB_SHOWDROPDOWN, FALSE, 0 ); + style = GetWindowLongW( info.hwndList, GWL_STYLE ); + exstyle = GetWindowLongW( info.hwndList, GWL_EXSTYLE ); + ok(style == expect_style, "%08x: got %08x\n", cb_style, style); + ok(exstyle == expect_exstyle, "%08x: got %08x\n", cb_style, exstyle); + + DestroyWindow(combo); +} + START_TEST(combo) { hMainWnd = CreateWindowA("static", "Test", WS_OVERLAPPEDWINDOW, 10, 10, 300, 300, NULL, NULL, NULL, 0); @@ -551,6 +606,9 @@ test_changesize(CBS_DROPDOWN); test_changesize(CBS_DROPDOWNLIST); test_editselection(); + test_listbox_styles(CBS_SIMPLE); + test_listbox_styles(CBS_DROPDOWN); + test_listbox_styles(CBS_DROPDOWNLIST); DestroyWindow(hMainWnd); } diff -Nru wine1.7-1.7.28/dlls/user32/tests/dde.c wine1.7-1.7.31/dlls/user32/tests/dde.c --- wine1.7-1.7.28/dlls/user32/tests/dde.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/tests/dde.c 2014-11-14 13:28:17.000000000 +0000 @@ -1591,7 +1591,7 @@ info.cb = sizeof(info); ret = DdeQueryConvInfo(hconv, QID_SYNC, &info); ok(ret, "wrong info size %d, DdeQueryConvInfo error %x\n", ret, DdeGetLastError(dde_inst)); - ok(info.ConvCtxt.iCodePage == client_unicode ? CP_WINUNICODE : CP_WINANSI, + ok(info.ConvCtxt.iCodePage == (client_unicode ? CP_WINUNICODE : CP_WINANSI), "wrong iCodePage %d\n", info.ConvCtxt.iCodePage); ok(!info.hConvPartner, "unexpected info.hConvPartner: %p\n", info.hConvPartner); todo_wine { diff -Nru wine1.7-1.7.28/dlls/user32/tests/input.c wine1.7-1.7.31/dlls/user32/tests/input.c --- wine1.7-1.7.28/dlls/user32/tests/input.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/tests/input.c 2014-11-14 13:28:17.000000000 +0000 @@ -1361,7 +1361,7 @@ /* Get a valid content for the input struct */ if(!GetCursorPos(&point)) { - skip("GetCursorPos() failed with error %u\n", GetLastError()); + win_skip("GetCursorPos() failed with error %u\n", GetLastError()); return; } memset(&in, 0, sizeof(MOUSEMOVEPOINT)); @@ -1643,6 +1643,308 @@ ok( bufferW[0] == 0xcccc, "wrong string %s\n", wine_dbgstr_w(bufferW) ); } +static void simulate_click(BOOL left, int x, int y) +{ + INPUT input[2]; + UINT events_no; + + SetCursorPos(x, y); + memset(input, 0, sizeof(input)); + input[0].type = INPUT_MOUSE; + U(input[0]).mi.dx = x; + U(input[0]).mi.dy = y; + U(input[0]).mi.dwFlags = left ? MOUSEEVENTF_LEFTDOWN : MOUSEEVENTF_RIGHTDOWN; + input[1].type = INPUT_MOUSE; + U(input[1]).mi.dx = x; + U(input[1]).mi.dy = y; + U(input[1]).mi.dwFlags = left ? MOUSEEVENTF_LEFTUP : MOUSEEVENTF_RIGHTUP; + events_no = SendInput(2, input, sizeof(input[0])); + ok(events_no == 2, "SendInput returned %d\n", events_no); +} + +static BOOL wait_for_message( MSG *msg ) +{ + BOOL ret; + + for (;;) + { + ret = PeekMessageA(msg, 0, 0, 0, PM_REMOVE); + if (ret) + { + if (msg->message == WM_PAINT) DispatchMessageA(msg); + else break; + } + else if (MsgWaitForMultipleObjects(0, NULL, FALSE, 100, QS_ALLINPUT) == WAIT_TIMEOUT) break; + } + if (!ret) msg->message = 0; + return ret; +} + +static BOOL wait_for_event(HANDLE event, int timeout) +{ + DWORD end_time = GetTickCount() + timeout; + MSG msg; + + do { + if(MsgWaitForMultipleObjects(1, &event, FALSE, timeout, QS_ALLINPUT) == WAIT_OBJECT_0) + return TRUE; + while(PeekMessageA(&msg, 0, 0, 0, PM_REMOVE)) + DispatchMessageA(&msg); + timeout = end_time - GetTickCount(); + }while(timeout > 0); + + return FALSE; +} + +static WNDPROC def_static_proc; +static DWORD hittest_no; +static LRESULT WINAPI static_hook_proc(HWND hwnd, UINT msg, WPARAM wp, LPARAM lp) +{ + if (msg == WM_NCHITTEST) + { + /* break infinite hittest loop */ + if(hittest_no > 50) return HTCLIENT; + hittest_no++; + } + + return def_static_proc(hwnd, msg, wp, lp); +} + +struct thread_data +{ + HANDLE start_event; + HANDLE end_event; + HWND win; +}; + +static DWORD WINAPI create_static_win(void *arg) +{ + struct thread_data *thread_data = arg; + HWND win; + + win = CreateWindowA("static", "static", WS_VISIBLE | WS_POPUP, + 100, 100, 100, 100, 0, NULL, NULL, NULL); + ok(win != 0, "CreateWindow failed\n"); + def_static_proc = (void*)SetWindowLongPtrA(win, + GWLP_WNDPROC, (LONG_PTR)static_hook_proc); + thread_data->win = win; + + SetEvent(thread_data->start_event); + wait_for_event(thread_data->end_event, 5000); + return 0; +} + +static void test_Input_mouse(void) +{ + BOOL got_button_down, got_button_up; + HWND hwnd, button_win, static_win; + struct thread_data thread_data; + HANDLE thread; + DWORD thread_id; + POINT pt; + MSG msg; + + button_win = CreateWindowA("button", "button", WS_VISIBLE | WS_POPUP, + 100, 100, 100, 100, 0, NULL, NULL, NULL); + ok(button_win != 0, "CreateWindow failed\n"); + + pt.x = pt.y = 150; + hwnd = WindowFromPoint(pt); + if (hwnd != button_win) + { + skip("there's another window covering test window\n"); + DestroyWindow(button_win); + return; + } + + /* simple button click test */ + simulate_click(TRUE, 150, 150); + got_button_down = got_button_up = FALSE; + while (wait_for_message(&msg)) + { + DispatchMessageA(&msg); + + if (msg.message == WM_LBUTTONDOWN) + { + got_button_down = TRUE; + } + else if (msg.message == WM_LBUTTONUP) + { + got_button_up = TRUE; + break; + } + } + ok(got_button_down, "expected WM_LBUTTONDOWN message\n"); + ok(got_button_up, "expected WM_LBUTTONUP message\n"); + + /* click through HTTRANSPARENT child window */ + static_win = CreateWindowA("static", "static", WS_VISIBLE | WS_CHILD, + 0, 0, 100, 100, button_win, NULL, NULL, NULL); + ok(static_win != 0, "CreateWindow failed\n"); + def_static_proc = (void*)SetWindowLongPtrA(static_win, + GWLP_WNDPROC, (LONG_PTR)static_hook_proc); + simulate_click(FALSE, 150, 150); + hittest_no = 0; + got_button_down = got_button_up = FALSE; + while (wait_for_message(&msg)) + { + DispatchMessageA(&msg); + + if (msg.message == WM_RBUTTONDOWN) + { + ok(msg.hwnd == button_win, "msg.hwnd = %p\n", msg.hwnd); + got_button_down = TRUE; + } + else if (msg.message == WM_RBUTTONUP) + { + ok(msg.hwnd == button_win, "msg.hwnd = %p\n", msg.hwnd); + got_button_up = TRUE; + break; + } + } + ok(hittest_no && hittest_no<50, "expected WM_NCHITTEST message\n"); + ok(got_button_down, "expected WM_RBUTTONDOWN message\n"); + ok(got_button_up, "expected WM_RBUTTONUP message\n"); + DestroyWindow(static_win); + + /* click through HTTRANSPARENT top-level window */ + static_win = CreateWindowA("static", "static", WS_VISIBLE | WS_POPUP, + 100, 100, 100, 100, 0, NULL, NULL, NULL); + ok(static_win != 0, "CreateWindow failed\n"); + def_static_proc = (void*)SetWindowLongPtrA(static_win, + GWLP_WNDPROC, (LONG_PTR)static_hook_proc); + simulate_click(TRUE, 150, 150); + hittest_no = 0; + got_button_down = got_button_up = FALSE; + while (wait_for_message(&msg)) + { + DispatchMessageA(&msg); + + if (msg.message == WM_LBUTTONDOWN) + { + ok(msg.hwnd == button_win, "msg.hwnd = %p\n", msg.hwnd); + got_button_down = TRUE; + } + else if (msg.message == WM_LBUTTONUP) + { + ok(msg.hwnd == button_win, "msg.hwnd = %p\n", msg.hwnd); + got_button_up = TRUE; + break; + } + } + ok(hittest_no && hittest_no<50, "expected WM_NCHITTEST message\n"); + todo_wine ok(got_button_down, "expected WM_LBUTTONDOWN message\n"); + todo_wine ok(got_button_up, "expected WM_LBUTTONUP message\n"); + DestroyWindow(static_win); + + /* click on HTTRANSPARENT top-level window that belongs to other thread */ + thread_data.start_event = CreateEventA(NULL, FALSE, FALSE, NULL); + ok(thread_data.start_event != NULL, "CreateEvent failed\n"); + thread_data.end_event = CreateEventA(NULL, FALSE, FALSE, NULL); + ok(thread_data.end_event != NULL, "CreateEvent failed\n"); + thread = CreateThread(NULL, 0, create_static_win, &thread_data, 0, NULL); + ok(thread != NULL, "CreateThread failed\n"); + hittest_no = 0; + got_button_down = got_button_up = FALSE; + WaitForSingleObject(thread_data.start_event, INFINITE); + simulate_click(FALSE, 150, 150); + while (wait_for_message(&msg)) + { + DispatchMessageA(&msg); + + if (msg.message == WM_RBUTTONDOWN) + got_button_down = TRUE; + else if (msg.message == WM_RBUTTONUP) + got_button_up = TRUE; + } + SetEvent(thread_data.end_event); + WaitForSingleObject(thread, INFINITE); + ok(hittest_no && hittest_no<50, "expected WM_NCHITTEST message\n"); + ok(!got_button_down, "unexpected WM_RBUTTONDOWN message\n"); + ok(!got_button_up, "unexpected WM_RBUTTONUP message\n"); + + /* click on HTTRANSPARENT top-level window that belongs to ther thread, + * threads input queues are attached */ + thread = CreateThread(NULL, 0, create_static_win, &thread_data, 0, &thread_id); + ok(thread != NULL, "CreateThread failed\n"); + hittest_no = 0; + got_button_down = got_button_up = FALSE; + WaitForSingleObject(thread_data.start_event, INFINITE); + ok(AttachThreadInput(thread_id, GetCurrentThreadId(), TRUE), + "AttachThreadInput failed\n"); + while (wait_for_message(&msg)) DispatchMessageA(&msg); + SetWindowPos(thread_data.win, button_win, 0, 0, 0, 0, SWP_NOSIZE|SWP_NOMOVE); + simulate_click(TRUE, 150, 150); + while (wait_for_message(&msg)) + { + DispatchMessageA(&msg); + + if (msg.message == WM_LBUTTONDOWN) + got_button_down = TRUE; + else if (msg.message == WM_LBUTTONUP) + got_button_up = TRUE; + } + SetEvent(thread_data.end_event); + WaitForSingleObject(thread, INFINITE); + todo_wine ok(hittest_no > 50, "expected loop with WM_NCHITTEST messages\n"); + ok(!got_button_down, "unexpected WM_LBUTTONDOWN message\n"); + ok(!got_button_up, "unexpected WM_LBUTTONUP message\n"); + + /* click after SetCapture call */ + SetCapture(button_win); + got_button_down = got_button_up = FALSE; + simulate_click(FALSE, 50, 50); + while (wait_for_message(&msg)) + { + DispatchMessageA(&msg); + + if (msg.message == WM_RBUTTONDOWN) + { + ok(msg.hwnd == button_win, "msg.hwnd = %p\n", msg.hwnd); + got_button_down = TRUE; + } + else if (msg.message == WM_RBUTTONUP) + { + ok(msg.hwnd == button_win, "msg.hwnd = %p\n", msg.hwnd); + got_button_up = TRUE; + break; + } + } + ok(got_button_down, "expected WM_RBUTTONDOWN message\n"); + ok(got_button_up, "expected WM_RBUTTONUP message\n"); + + /* click on child window after SetCapture call */ + hwnd = CreateWindowA("button", "button2", WS_VISIBLE | WS_CHILD, + 0, 0, 100, 100, button_win, NULL, NULL, NULL); + ok(hwnd != 0, "CreateWindow failed\n"); + got_button_down = got_button_up = FALSE; + simulate_click(TRUE, 150, 150); + while (wait_for_message(&msg)) + { + DispatchMessageA(&msg); + + if (msg.message == WM_LBUTTONDOWN) + { + ok(msg.hwnd == button_win, "msg.hwnd = %p\n", msg.hwnd); + got_button_down = TRUE; + } + else if (msg.message == WM_LBUTTONUP) + { + ok(msg.hwnd == button_win, "msg.hwnd = %p\n", msg.hwnd); + got_button_up = TRUE; + break; + } + } + ok(got_button_down, "expected WM_LBUTTONDOWN message\n"); + ok(got_button_up, "expected WM_LBUTTONUP message\n"); + DestroyWindow(hwnd); + ok(ReleaseCapture(), "ReleaseCapture failed\n"); + + CloseHandle(thread_data.start_event); + CloseHandle(thread_data.end_event); + DestroyWindow(button_win); +} + START_TEST(input) { init_function_pointers(); @@ -1652,6 +1954,7 @@ test_Input_blackbox(); test_Input_whitebox(); test_Input_unicode(); + test_Input_mouse(); } else win_skip("SendInput is not available\n"); diff -Nru wine1.7-1.7.28/dlls/user32/tests/msg.c wine1.7-1.7.31/dlls/user32/tests/msg.c --- wine1.7-1.7.28/dlls/user32/tests/msg.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/tests/msg.c 2014-11-14 13:28:17.000000000 +0000 @@ -4542,6 +4542,11 @@ { 0 } }; +static void CALLBACK apc_test_proc(ULONG_PTR param) +{ + /* nothing */ +} + static void test_MsgWaitForMultipleObjects(HWND hwnd) { DWORD ret; @@ -4583,6 +4588,37 @@ ok(msg.message == WM_USER, "got %04x instead of WM_USER\n", msg.message); ok(PeekMessageA( &msg, 0, 0, 0, PM_REMOVE ), "PeekMessage should succeed\n"); ok(msg.message == WM_USER, "got %04x instead of WM_USER\n", msg.message); + + /* MWMO_INPUTAVAILABLE should succeed even if the message was already seen */ + PostMessageA( hwnd, WM_USER, 0, 0 ); + ok(PeekMessageA( &msg, 0, 0, 0, PM_NOREMOVE ), "PeekMessage should succeed\n"); + ok(msg.message == WM_USER, "got %04x instead of WM_USER\n", msg.message); + + ret = MsgWaitForMultipleObjectsEx( 0, NULL, 0, QS_POSTMESSAGE, MWMO_INPUTAVAILABLE ); + ok(ret == WAIT_OBJECT_0, "MsgWaitForMultipleObjectsEx returned %x\n", ret); + + ok(PeekMessageA( &msg, 0, 0, 0, PM_REMOVE ), "PeekMessage should succeed\n"); + ok(msg.message == WM_USER, "got %04x instead of WM_USER\n", msg.message); + + /* without MWMO_ALERTABLE the result is never WAIT_IO_COMPLETION */ + ret = QueueUserAPC( apc_test_proc, GetCurrentThread(), 0 ); + ok(ret, "QueueUserAPC failed %u\n", GetLastError()); + + ret = MsgWaitForMultipleObjectsEx( 0, NULL, 0, QS_POSTMESSAGE, 0 ); + ok(ret == WAIT_TIMEOUT, "MsgWaitForMultipleObjectsEx returned %x\n", ret); + + /* but even with MWMO_ALERTABLE window events are preferred */ + PostMessageA( hwnd, WM_USER, 0, 0 ); + + ret = MsgWaitForMultipleObjectsEx( 0, NULL, 0, QS_POSTMESSAGE, MWMO_ALERTABLE ); + ok(ret == WAIT_OBJECT_0, "MsgWaitForMultipleObjectsEx returned %x\n", ret); + + ok(PeekMessageA( &msg, 0, 0, 0, PM_REMOVE ), "PeekMessage should succeed\n"); + ok(msg.message == WM_USER, "got %04x instead of WM_USER\n", msg.message); + + /* the APC call is still queued */ + ret = MsgWaitForMultipleObjectsEx( 0, NULL, 0, QS_POSTMESSAGE, MWMO_ALERTABLE ); + ok(ret == WAIT_IO_COMPLETION, "MsgWaitForMultipleObjectsEx returned %x\n", ret); } /* test if we receive the right sequence of messages */ @@ -8412,6 +8448,13 @@ count++; } +static DWORD exception; +static void CALLBACK callback_exception(HWND hwnd, UINT uMsg, UINT_PTR idEvent, DWORD dwTime) +{ + count++; + RaiseException(exception, 0, 0, NULL); +} + static DWORD WINAPI timer_thread_proc(LPVOID x) { struct timer_info *info = x; @@ -8542,6 +8585,41 @@ /* Note: SetSystemTimer doesn't support a NULL window, see test_timers */ } +static void test_timers_exception(DWORD code) +{ + UINT_PTR id; + MSG msg; + + exception = code; + id = SetTimer(NULL, 0, 1000, callback_exception); + ok(id != 0, "did not get id from SetTimer.\n"); + + memset(&msg, 0, sizeof(msg)); + msg.message = WM_TIMER; + msg.wParam = id; + msg.lParam = (LPARAM)callback_exception; + + count = 0; + DispatchMessageA(&msg); + ok(count == 1, "did not get one count as expected (%i).\n", count); + + KillTimer(NULL, id); +} + +static void test_timers_exceptions(void) +{ + test_timers_exception(EXCEPTION_ACCESS_VIOLATION); + test_timers_exception(EXCEPTION_DATATYPE_MISALIGNMENT); + test_timers_exception(EXCEPTION_BREAKPOINT); + test_timers_exception(EXCEPTION_SINGLE_STEP); + test_timers_exception(EXCEPTION_ARRAY_BOUNDS_EXCEEDED); + test_timers_exception(EXCEPTION_FLT_DENORMAL_OPERAND); + test_timers_exception(EXCEPTION_FLT_DIVIDE_BY_ZERO); + test_timers_exception(EXCEPTION_FLT_INEXACT_RESULT); + test_timers_exception(EXCEPTION_ILLEGAL_INSTRUCTION); + test_timers_exception(0xE000BEEF); /* customer exception */ +} + /* Various win events with arbitrary parameters */ static const struct message WmWinEventsSeq[] = { { EVENT_SYSTEM_SOUND, winevent_hook|wparam|lparam, OBJID_WINDOW, 0 }, @@ -14583,6 +14661,7 @@ test_accelerators(); test_timers(); test_timers_no_wnd(); + test_timers_exceptions(); if (hCBT_hook) test_set_hook(); test_DestroyWindow(); test_DispatchMessage(); diff -Nru wine1.7-1.7.28/dlls/user32/tests/win.c wine1.7-1.7.31/dlls/user32/tests/win.c --- wine1.7-1.7.28/dlls/user32/tests/win.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/tests/win.c 2014-11-14 13:28:17.000000000 +0000 @@ -7295,7 +7295,7 @@ DispatchMessageA(&msg); } ok(got_hittest, "transparent window didn't get WM_NCHITTEST message\n"); - todo_wine ok(got_click, "button under static window didn't get WM_LBUTTONUP\n"); + ok(got_click, "button under static window didn't get WM_LBUTTONUP\n"); ret = WaitForSingleObject(end_event, 5000); ok(ret == WAIT_OBJECT_0, "WaitForSingleObject returned %x\n", ret); diff -Nru wine1.7-1.7.28/dlls/user32/tests/winstation.c wine1.7-1.7.31/dlls/user32/tests/winstation.c --- wine1.7-1.7.28/dlls/user32/tests/winstation.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/tests/winstation.c 2014-11-14 13:28:17.000000000 +0000 @@ -932,7 +932,7 @@ GetProcessWindowStation(); if (GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) { - skip("WindowStation calls not supported on this platform\n"); + win_skip("WindowStation calls not supported on this platform\n"); return; } diff -Nru wine1.7-1.7.28/dlls/user32/user_main.c wine1.7-1.7.31/dlls/user32/user_main.c --- wine1.7-1.7.28/dlls/user32/user_main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/user_main.c 2014-11-14 13:28:17.000000000 +0000 @@ -322,18 +322,24 @@ */ BOOL WINAPI DllMain( HINSTANCE inst, DWORD reason, LPVOID reserved ) { + static const WCHAR imm32_dllW[] = {'i','m','m','3','2','.','d','l','l',0}; + static HMODULE imm32_module; BOOL ret = TRUE; + switch(reason) { case DLL_PROCESS_ATTACH: user32_module = inst; ret = process_attach(); + if(ret) + imm32_module = LoadLibraryW(imm32_dllW); break; case DLL_THREAD_DETACH: thread_detach(); break; case DLL_PROCESS_DETACH: USER_unload_driver(); + FreeLibrary(imm32_module); DeleteCriticalSection(&user_section); break; } diff -Nru wine1.7-1.7.28/dlls/user32/winpos.c wine1.7-1.7.31/dlls/user32/winpos.c --- wine1.7-1.7.28/dlls/user32/winpos.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/winpos.c 2014-11-14 13:28:17.000000000 +0000 @@ -131,7 +131,7 @@ data->rdh.iType = RDH_RECTANGLES; data->rdh.nCount = reply_size / sizeof(RECT); data->rdh.nRgnSize = reply_size; - win_rgn = ExtCreateRegion( NULL, size, data ); + win_rgn = ExtCreateRegion( NULL, data->rdh.dwSize + data->rdh.nRgnSize, data ); } } else size = reply->total_size; @@ -532,7 +532,7 @@ rect[i].top += offset.y; rect[i].bottom += offset.y; } - if ((new_rgn = ExtCreateRegion( NULL, data->rdh.nCount, data ))) + if ((new_rgn = ExtCreateRegion( NULL, data->rdh.dwSize + data->rdh.nRgnSize, data ))) { CombineRgn( hrgn, new_rgn, 0, RGN_COPY ); DeleteObject( new_rgn ); @@ -2018,7 +2018,7 @@ data->rdh.iType = RDH_RECTANGLES; data->rdh.nCount = reply_size / sizeof(RECT); data->rdh.nRgnSize = reply_size; - region = ExtCreateRegion( NULL, size, data ); + region = ExtCreateRegion( NULL, data->rdh.dwSize + data->rdh.nRgnSize, data ); OffsetRgn( region, -reply->visible_rect.left, -reply->visible_rect.top ); } } diff -Nru wine1.7-1.7.28/dlls/user32/winproc.c wine1.7-1.7.31/dlls/user32/winproc.c --- wine1.7-1.7.28/dlls/user32/winproc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/user32/winproc.c 2014-11-14 13:28:17.000000000 +0000 @@ -75,6 +75,7 @@ { MDIClientWndProcA, MDIClientWndProcW }, /* WINPROC_MDICLIENT */ { ScrollBarWndProcA, ScrollBarWndProcW }, /* WINPROC_SCROLLBAR */ { StaticWndProcA, StaticWndProcW }, /* WINPROC_STATIC */ + { ImeWndProcA, ImeWndProcW }, /* WINPROC_IME */ { NULL, DesktopWndProc }, /* WINPROC_DESKTOP */ { NULL, IconTitleWndProc }, /* WINPROC_ICONTITLE */ { NULL, PopupMenuWndProc }, /* WINPROC_MENU */ diff -Nru wine1.7-1.7.28/dlls/usp10/opentype.c wine1.7-1.7.31/dlls/usp10/opentype.c --- wine1.7-1.7.28/dlls/usp10/opentype.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/usp10/opentype.c 2014-11-14 13:28:17.000000000 +0000 @@ -924,10 +924,9 @@ static INT GSUB_apply_ChainContextSubst(const OT_LookupList* lookup, const OT_LookupTable *look, WORD *glyphs, INT glyph_index, INT write_dir, INT *glyph_count) { int j; - BOOL done = FALSE; TRACE("Chaining Contextual Substitution Subtable\n"); - for (j = 0; j < GET_BE_WORD(look->SubTableCount) && !done; j++) + for (j = 0; j < GET_BE_WORD(look->SubTableCount); j++) { const GSUB_ChainContextSubstFormat1 *ccsf1; int offset; @@ -938,12 +937,16 @@ ccsf1 = (const GSUB_ChainContextSubstFormat1*)((const BYTE*)look+offset); if (GET_BE_WORD(ccsf1->SubstFormat) == 1) { - FIXME(" TODO: subtype 1 (Simple context glyph substitution)\n"); + static int once; + if (!once++) + FIXME(" TODO: subtype 1 (Simple context glyph substitution)\n"); continue; } else if (GET_BE_WORD(ccsf1->SubstFormat) == 2) { - FIXME(" TODO: subtype 2 (Class-based Chaining Context Glyph Substitution)\n"); + static int once; + if (!once++) + FIXME(" TODO: subtype 2 (Class-based Chaining Context Glyph Substitution)\n"); continue; } else if (GET_BE_WORD(ccsf1->SubstFormat) == 3) @@ -1649,12 +1652,16 @@ if (GET_BE_WORD(ccpf3->PosFormat) == 1) { - FIXME(" TODO: subtype 1 (Simple Chaining Context Glyph Positioning)\n"); + static int once; + if (!once++) + FIXME(" TODO: subtype 1 (Simple Chaining Context Glyph Positioning)\n"); continue; } else if (GET_BE_WORD(ccpf3->PosFormat) == 2) { - FIXME(" TODO: subtype 2 (Class-based Chaining Context Glyph Positioning)\n"); + static int once; + if (!once++) + FIXME(" TODO: subtype 2 (Class-based Chaining Context Glyph Positioning)\n"); continue; } else if (GET_BE_WORD(ccpf3->PosFormat) == 3) diff -Nru wine1.7-1.7.28/dlls/uxtheme/tests/system.c wine1.7-1.7.31/dlls/uxtheme/tests/system.c --- wine1.7-1.7.28/dlls/uxtheme/tests/system.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/uxtheme/tests/system.c 2014-11-14 13:28:17.000000000 +0000 @@ -474,9 +474,9 @@ hRes = pGetCurrentThemeName(currentTheme, 2, NULL, 0, NULL, 0); if (bThemeActive) todo_wine - ok(hRes == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER) || + ok(hRes == E_NOT_SUFFICIENT_BUFFER || broken(hRes == E_FAIL /* WinXP SP1 */), - "Expected HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), got 0x%08x\n", hRes); + "Expected E_NOT_SUFFICIENT_BUFFER, got 0x%08x\n", hRes); else ok( hRes == E_PROP_ID_UNSUPPORTED, "Expected E_PROP_ID_UNSUPPORTED, got 0x%08x\n", hRes); @@ -486,9 +486,9 @@ currentSize, sizeof(currentSize) / sizeof(WCHAR)); if (bThemeActive) todo_wine - ok(hRes == HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER) || + ok(hRes == E_NOT_SUFFICIENT_BUFFER || broken(hRes == E_FAIL /* WinXP SP1 */), - "Expected HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER), got 0x%08x\n", hRes); + "Expected E_NOT_SUFFICIENT_BUFFER, got 0x%08x\n", hRes); else ok( hRes == E_PROP_ID_UNSUPPORTED, "Expected E_PROP_ID_UNSUPPORTED, got 0x%08x\n", hRes); diff -Nru wine1.7-1.7.28/dlls/vbscript/global.c wine1.7-1.7.31/dlls/vbscript/global.c --- wine1.7-1.7.28/dlls/vbscript/global.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/vbscript/global.c 2014-11-14 13:28:17.000000000 +0000 @@ -130,6 +130,16 @@ return S_OK; } +static inline HRESULT return_float(VARIANT *res, float val) +{ + if(res) { + V_VT(res) = VT_R4; + V_R4(res) = val; + } + + return S_OK; +} + static inline HRESULT return_null(VARIANT *res) { if(res) @@ -760,8 +770,13 @@ static HRESULT Global_Timer(vbdisp_t *This, VARIANT *arg, unsigned args_cnt, VARIANT *res) { - FIXME("\n"); - return E_NOTIMPL; + SYSTEMTIME lt; + double sec; + + GetLocalTime(<); + sec = lt.wHour * 3600 + lt.wMinute * 60 + lt.wSecond + lt.wMilliseconds / 1000.0; + return return_float(res, sec); + } static HRESULT Global_LBound(vbdisp_t *This, VARIANT *arg, unsigned args_cnt, VARIANT *res) diff -Nru wine1.7-1.7.28/dlls/vbscript/tests/api.vbs wine1.7-1.7.31/dlls/vbscript/tests/api.vbs --- wine1.7-1.7.28/dlls/vbscript/tests/api.vbs 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/vbscript/tests/api.vbs 2014-11-14 13:28:17.000000000 +0000 @@ -1264,4 +1264,6 @@ Call testRGBError(-1, &h1e&, &h3b&, 5) Call testRGBError(&h4d&, -2, &h2f&, 5) +Call ok(getVT(Timer) = "VT_R4", "getVT(Timer) = " & getVT(Timer)) + Call reportSuccess() diff -Nru wine1.7-1.7.28/dlls/version/version.c wine1.7-1.7.31/dlls/version/version.c --- wine1.7-1.7.28/dlls/version/version.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/version/version.c 2014-11-14 13:28:17.000000000 +0000 @@ -976,7 +976,7 @@ len = WideCharToMultiByte(CP_ACP, 0, *lplpBuffer, -1, lpBufferA + pos, info->wLength - pos, NULL, NULL); *lplpBuffer = lpBufferA + pos; - *puLen = len; + if (puLen) *puLen = len; } return ret; } @@ -1036,7 +1036,7 @@ len = MultiByteToWideChar(CP_ACP, 0, *lplpBuffer, -1, lpBufferW + pos, max/sizeof(WCHAR) - pos ); *lplpBuffer = lpBufferW + pos; - *puLen = len; + if (puLen) *puLen = len; } return ret; } diff -Nru wine1.7-1.7.28/dlls/windowscodecs/imgfactory.c wine1.7-1.7.31/dlls/windowscodecs/imgfactory.c --- wine1.7-1.7.28/dlls/windowscodecs/imgfactory.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/windowscodecs/imgfactory.c 2014-11-14 13:28:17.000000000 +0000 @@ -956,9 +956,129 @@ static HRESULT WINAPI ComponentFactory_CreateMetadataReaderFromContainer(IWICComponentFactory *iface, REFGUID format, const GUID *vendor, DWORD options, IStream *stream, IWICMetadataReader **reader) { - FIXME("%p,%s,%s,%x,%p,%p: stub\n", iface, debugstr_guid(format), debugstr_guid(vendor), + HRESULT hr; + IEnumUnknown *enumreaders; + IUnknown *unkreaderinfo; + IWICMetadataReaderInfo *readerinfo; + IWICPersistStream *wicpersiststream; + ULONG num_fetched; + GUID decoder_vendor; + BOOL matches; + LARGE_INTEGER zero; + + TRACE("%p,%s,%s,%x,%p,%p\n", iface, debugstr_guid(format), debugstr_guid(vendor), options, stream, reader); - return E_NOTIMPL; + + if (!format || !stream || !reader) + return E_INVALIDARG; + + zero.QuadPart = 0; + + hr = CreateComponentEnumerator(WICMetadataReader, WICComponentEnumerateDefault, &enumreaders); + if (FAILED(hr)) return hr; + + *reader = NULL; + +start: + while (!*reader) + { + hr = IEnumUnknown_Next(enumreaders, 1, &unkreaderinfo, &num_fetched); + + if (hr == S_OK) + { + hr = IUnknown_QueryInterface(unkreaderinfo, &IID_IWICMetadataReaderInfo, (void**)&readerinfo); + + if (SUCCEEDED(hr)) + { + if (vendor) + { + hr = IWICMetadataReaderInfo_GetVendorGUID(readerinfo, &decoder_vendor); + + if (FAILED(hr) || !IsEqualIID(vendor, &decoder_vendor)) + { + IWICMetadataReaderInfo_Release(readerinfo); + IUnknown_Release(unkreaderinfo); + continue; + } + } + + hr = IWICMetadataReaderInfo_MatchesPattern(readerinfo, format, stream, &matches); + + if (SUCCEEDED(hr) && matches) + { + hr = IStream_Seek(stream, zero, STREAM_SEEK_SET, NULL); + + if (SUCCEEDED(hr)) + hr = IWICMetadataReaderInfo_CreateInstance(readerinfo, reader); + + if (SUCCEEDED(hr)) + { + hr = IWICMetadataReader_QueryInterface(*reader, &IID_IWICPersistStream, (void**)&wicpersiststream); + + if (SUCCEEDED(hr)) + { + hr = IWICPersistStream_LoadEx(wicpersiststream, + stream, vendor, options & WICPersistOptionsMask); + + IWICPersistStream_Release(wicpersiststream); + } + + if (FAILED(hr)) + { + IWICMetadataReader_Release(*reader); + *reader = NULL; + } + } + } + + IUnknown_Release(readerinfo); + } + + IUnknown_Release(unkreaderinfo); + } + else + break; + } + + if (!*reader && vendor) + { + vendor = NULL; + IEnumUnknown_Reset(enumreaders); + goto start; + } + + IEnumUnknown_Release(enumreaders); + + if (!*reader && !(options & WICMetadataCreationFailUnknown)) + { + hr = IStream_Seek(stream, zero, STREAM_SEEK_SET, NULL); + + if (SUCCEEDED(hr)) + hr = UnknownMetadataReader_CreateInstance(&IID_IWICMetadataReader, (void**)reader); + + if (SUCCEEDED(hr)) + { + hr = IWICMetadataReader_QueryInterface(*reader, &IID_IWICPersistStream, (void**)&wicpersiststream); + + if (SUCCEEDED(hr)) + { + hr = IWICPersistStream_LoadEx(wicpersiststream, stream, NULL, options & WICPersistOptionsMask); + + IWICPersistStream_Release(wicpersiststream); + } + + if (FAILED(hr)) + { + IWICMetadataReader_Release(*reader); + *reader = NULL; + } + } + } + + if (*reader) + return S_OK; + else + return WINCODEC_ERR_COMPONENTNOTFOUND; } static HRESULT WINAPI ComponentFactory_CreateMetadataWriter(IWICComponentFactory *iface, diff -Nru wine1.7-1.7.28/dlls/windowscodecs/info.c wine1.7-1.7.31/dlls/windowscodecs/info.c --- wine1.7-1.7.28/dlls/windowscodecs/info.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/windowscodecs/info.c 2014-11-14 13:28:17.000000000 +0000 @@ -56,6 +56,7 @@ static const WCHAR requiresfullstream_valuename[] = {'R','e','q','u','i','r','e','s','F','u','l','l','S','t','r','e','a','m',0}; static const WCHAR supportspadding_valuename[] = {'S','u','p','p','o','r','t','s','P','a','d','d','i','n','g',0}; static const WCHAR fileextensions_valuename[] = {'F','i','l','e','E','x','t','e','n','s','i','o','n','s',0}; +static const WCHAR containers_keyname[] = {'C','o','n','t','a','i','n','e','r','s',0}; static HRESULT ComponentInfo_GetStringValue(HKEY classkey, LPCWSTR value, UINT buffer_size, WCHAR *buffer, UINT *actual_size) @@ -151,7 +152,12 @@ return E_INVALIDARG; ret = RegOpenKeyExW(classkey, subkeyname, 0, KEY_READ, &subkey); - if (ret != ERROR_SUCCESS) return HRESULT_FROM_WIN32(ret); + if (ret == ERROR_FILE_NOT_FOUND) + { + *actual_size = 0; + return S_OK; + } + else if (ret != ERROR_SUCCESS) return HRESULT_FROM_WIN32(ret); if (buffer) { @@ -1630,10 +1636,11 @@ static HRESULT WINAPI MetadataReaderInfo_GetContainerFormats(IWICMetadataReaderInfo *iface, UINT length, GUID *formats, UINT *actual_length) { - if (!actual_length) return E_INVALIDARG; + MetadataReaderInfo *This = impl_from_IWICMetadataReaderInfo(iface); + TRACE("(%p,%u,%p,%p)\n", iface, length, formats, actual_length); - FIXME("(%p,%u,%p,%p): stub\n", iface, length, formats, actual_length); - return E_NOTIMPL; + return ComponentInfo_GetGuidList(This->classkey, containers_keyname, length, + formats, actual_length); } static HRESULT WINAPI MetadataReaderInfo_GetDeviceManufacturer(IWICMetadataReaderInfo *iface, @@ -1674,19 +1681,187 @@ } static HRESULT WINAPI MetadataReaderInfo_GetPatterns(IWICMetadataReaderInfo *iface, - REFGUID container, UINT length, WICMetadataPattern *pattern, UINT *count, UINT *actual_length) + REFGUID container, UINT length, WICMetadataPattern *patterns, UINT *count, UINT *actual_length) { - if (!actual_length) return E_INVALIDARG; + MetadataReaderInfo *This = impl_from_IWICMetadataReaderInfo(iface); + HRESULT hr=S_OK; + LONG res; + UINT pattern_count=0, patterns_size=0; + DWORD valuesize, patternsize; + BYTE *bPatterns=(BYTE*)patterns; + HKEY containers_key, guid_key, pattern_key; + WCHAR subkeyname[11]; + WCHAR guidkeyname[39]; + int i; + static const WCHAR uintformatW[] = {'%','u',0}; + static const WCHAR patternW[] = {'P','a','t','t','e','r','n',0}; + static const WCHAR positionW[] = {'P','o','s','i','t','i','o','n',0}; + static const WCHAR maskW[] = {'M','a','s','k',0}; + static const WCHAR dataoffsetW[] = {'D','a','t','a','O','f','f','s','e','t',0}; - FIXME("(%p,%s,%u,%p,%p,%p): stub\n", iface, debugstr_guid(container), length, pattern, count, actual_length); - return E_NOTIMPL; + TRACE("(%p,%s,%u,%p,%p,%p)\n", iface, debugstr_guid(container), length, patterns, count, actual_length); + + if (!actual_length || !container) return E_INVALIDARG; + + res = RegOpenKeyExW(This->classkey, containers_keyname, 0, KEY_READ, &containers_key); + if (res == ERROR_SUCCESS) + { + StringFromGUID2(container, guidkeyname, 39); + + res = RegOpenKeyExW(containers_key, guidkeyname, 0, KEY_READ, &guid_key); + if (res == ERROR_FILE_NOT_FOUND) hr = WINCODEC_ERR_COMPONENTNOTFOUND; + else if (res != ERROR_SUCCESS) hr = HRESULT_FROM_WIN32(res); + + RegCloseKey(containers_key); + } + else if (res == ERROR_FILE_NOT_FOUND) hr = WINCODEC_ERR_COMPONENTNOTFOUND; + else hr = HRESULT_FROM_WIN32(res); + + if (SUCCEEDED(hr)) + { + res = RegQueryInfoKeyW(guid_key, NULL, NULL, NULL, &pattern_count, NULL, NULL, NULL, NULL, NULL, NULL, NULL); + if (res != ERROR_SUCCESS) hr = HRESULT_FROM_WIN32(res); + + if (SUCCEEDED(hr)) + { + patterns_size = pattern_count * sizeof(WICMetadataPattern); + + for (i=0; i= patterns_size) && (res == ERROR_SUCCESS)) + { + patterns[i].Length = patternsize; + + patterns[i].DataOffset.QuadPart = 0; + valuesize = sizeof(ULARGE_INTEGER); + RegGetValueW(pattern_key, NULL, dataoffsetW, RRF_RT_DWORD|RRF_RT_QWORD, NULL, + &patterns[i].DataOffset, &valuesize); + + patterns[i].Position.QuadPart = 0; + valuesize = sizeof(ULARGE_INTEGER); + res = RegGetValueW(pattern_key, NULL, positionW, RRF_RT_DWORD|RRF_RT_QWORD, NULL, + &patterns[i].Position, &valuesize); + + if (res == ERROR_SUCCESS) + { + patterns[i].Pattern = bPatterns+patterns_size-patternsize*2; + valuesize = patternsize; + res = RegGetValueW(pattern_key, NULL, patternW, RRF_RT_REG_BINARY, NULL, + patterns[i].Pattern, &valuesize); + } + + if (res == ERROR_SUCCESS) + { + patterns[i].Mask = bPatterns+patterns_size-patternsize; + valuesize = patternsize; + res = RegGetValueW(pattern_key, NULL, maskW, RRF_RT_REG_BINARY, NULL, + patterns[i].Mask, &valuesize); + } + } + + RegCloseKey(pattern_key); + } + if (res != ERROR_SUCCESS) + { + hr = HRESULT_FROM_WIN32(res); + break; + } + } + } + + RegCloseKey(guid_key); + } + + if (hr == S_OK) + { + *count = pattern_count; + *actual_length = patterns_size; + if (patterns && length < patterns_size) + hr = WINCODEC_ERR_INSUFFICIENTBUFFER; + } + + return hr; } static HRESULT WINAPI MetadataReaderInfo_MatchesPattern(IWICMetadataReaderInfo *iface, REFGUID container, IStream *stream, BOOL *matches) { - FIXME("(%p,%s,%p,%p): stub\n", iface, debugstr_guid(container), stream, matches); - return E_NOTIMPL; + HRESULT hr; + WICMetadataPattern *patterns; + UINT pattern_count=0, patterns_size=0; + ULONG datasize=0; + BYTE *data=NULL; + ULONG bytesread; + UINT i; + LARGE_INTEGER seekpos; + ULONG pos; + + TRACE("(%p,%s,%p,%p)\n", iface, debugstr_guid(container), stream, matches); + + hr = MetadataReaderInfo_GetPatterns(iface, container, 0, NULL, &pattern_count, &patterns_size); + if (FAILED(hr)) return hr; + + patterns = HeapAlloc(GetProcessHeap(), 0, patterns_size); + if (!patterns) return E_OUTOFMEMORY; + + hr = MetadataReaderInfo_GetPatterns(iface, container, patterns_size, patterns, &pattern_count, &patterns_size); + if (FAILED(hr)) goto end; + + for (i=0; iwFormatTag == WAVE_FORMAT_EXTENSIBLE || fmt->nChannels > 2){ + if(This->dataflow != eCapture && (fmt->wFormatTag == WAVE_FORMAT_EXTENSIBLE || fmt->nChannels > 2) ){ WAVEFORMATEXTENSIBLE *fmtex = (void*)fmt; DWORD mask, flag = SPEAKER_FRONT_LEFT; UINT i = 0; diff -Nru wine1.7-1.7.28/dlls/winecoreaudio.drv/mmdevdrv.c wine1.7-1.7.31/dlls/winecoreaudio.drv/mmdevdrv.c --- wine1.7-1.7.28/dlls/winecoreaudio.drv/mmdevdrv.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/winecoreaudio.drv/mmdevdrv.c 2014-11-14 13:28:17.000000000 +0000 @@ -562,7 +562,7 @@ GUID reg_guid; key_name_size = sizeof(key_name); - if(RegEnumKeyExW(devices_key, i, key_name, &key_name_size, NULL, + if(RegEnumKeyExW(devices_key, i++, key_name, &key_name_size, NULL, NULL, NULL, NULL) != ERROR_SUCCESS) break; @@ -596,8 +596,6 @@ } RegCloseKey(key); - - ++i; } RegCloseKey(devices_key); diff -Nru wine1.7-1.7.28/dlls/wined3d/arb_program_shader.c wine1.7-1.7.31/dlls/wined3d/arb_program_shader.c --- wine1.7-1.7.28/dlls/wined3d/arb_program_shader.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/arb_program_shader.c 2014-11-14 13:28:17.000000000 +0000 @@ -823,7 +823,7 @@ max_constantsF -= count_bits(reg_maps->integer_constants); max_constantsF -= gl_info->reserved_arb_constants; - for (i = 0; i < shader->limits.constant_float; ++i) + for (i = 0; i < shader->limits->constant_float; ++i) { DWORD idx = i >> 5; DWORD shift = i & 0x1f; @@ -899,7 +899,7 @@ } /* Avoid declaring more constants than needed */ - max_constantsF = min(max_constantsF, shader->limits.constant_float); + max_constantsF = min(max_constantsF, shader->limits->constant_float); /* we use the array-based constants array if the local constants are marked for loading, * because then we use indirect addressing, or when the local constant list is empty, @@ -4257,7 +4257,7 @@ { int i; const char *one = arb_get_helper_value(WINED3D_SHADER_TYPE_VERTEX, ARB_ONE); - for(i = 0; i < min(8, MAX_REG_TEXCRD); i++) + for(i = 0; i < MAX_REG_TEXCRD; i++) { if (reg_maps->texcoord_mask[i] && reg_maps->texcoord_mask[i] != WINED3DSP_WRITEMASK_ALL) shader_addline(buffer, "MOV result.texcoord[%u].w, %s\n", i, one); @@ -7469,7 +7469,7 @@ struct arbfp_blit_type type; struct arbfp_blit_desc *desc; - if (surface->flags & SFLAG_CONVERTED) + if (surface->container->flags & WINED3D_TEXTURE_CONVERTED) { gl_info->gl_ops.gl.p_glEnable(textype); checkGLcall("glEnable(textype)"); diff -Nru wine1.7-1.7.28/dlls/wined3d/context.c wine1.7-1.7.31/dlls/wined3d/context.c --- wine1.7-1.7.28/dlls/wined3d/context.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/context.c 2014-11-14 13:28:17.000000000 +0000 @@ -141,7 +141,7 @@ { case WINED3D_LOCATION_TEXTURE_RGB: case WINED3D_LOCATION_TEXTURE_SRGB: - surface_prepare_texture(depth_stencil, context, FALSE); + wined3d_texture_prepare_texture(depth_stencil->container, context, FALSE); if (format_flags & WINED3DFMT_FLAG_DEPTH) { @@ -217,7 +217,7 @@ case WINED3D_LOCATION_TEXTURE_RGB: case WINED3D_LOCATION_TEXTURE_SRGB: srgb = location == WINED3D_LOCATION_TEXTURE_SRGB; - surface_prepare_texture(surface, context, srgb); + wined3d_texture_prepare_texture(surface->container, context, srgb); gl_info->fbo_ops.glFramebufferTexture2D(fbo_target, GL_COLOR_ATTACHMENT0 + idx, surface->texture_target, surface_get_texture_name(surface, gl_info, srgb), surface->texture_level); diff -Nru wine1.7-1.7.28/dlls/wined3d/cs.c wine1.7-1.7.31/dlls/wined3d/cs.c --- wine1.7-1.7.28/dlls/wined3d/cs.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/cs.c 2014-11-14 13:28:17.000000000 +0000 @@ -636,10 +636,15 @@ if (op->texture) { + const struct wined3d_format *new_format = op->texture->resource.format; + const struct wined3d_format *old_format = prev ? prev->resource.format : NULL; + if (InterlockedIncrement(&op->texture->resource.bind_count) == 1) op->texture->sampler = op->stage; - if (!prev || op->texture->target != prev->target) + if (!prev || op->texture->target != prev->target + || !is_same_fixup(new_format->color_fixup, old_format->color_fixup) + || (new_format->flags & WINED3DFMT_FLAG_SHADOW) != (old_format->flags & WINED3DFMT_FLAG_SHADOW)) device_invalidate_state(cs->device, STATE_SHADER(WINED3D_SHADER_TYPE_PIXEL)); if (!prev && op->stage < d3d_info->limits.ffp_blend_stages) diff -Nru wine1.7-1.7.28/dlls/wined3d/device.c wine1.7-1.7.31/dlls/wined3d/device.c --- wine1.7-1.7.28/dlls/wined3d/device.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/device.c 2014-11-14 13:28:17.000000000 +0000 @@ -3481,7 +3481,8 @@ context = context_acquire(device, NULL); - wined3d_volume_load(dst_volume, context, FALSE); + /* Only a prepare, since we're uploading the entire volume. */ + wined3d_texture_prepare_texture(dst_volume->container, context, FALSE); data.buffer_object = 0; data.addr = src.data; diff -Nru wine1.7-1.7.28/dlls/wined3d/directx.c wine1.7-1.7.31/dlls/wined3d/directx.c --- wine1.7-1.7.28/dlls/wined3d/directx.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/directx.c 2014-11-14 13:28:17.000000000 +0000 @@ -36,10 +36,6 @@ #define WINE_DEFAULT_VIDMEM (64 * 1024 * 1024) #define DEFAULT_REFRESH_RATE 0 -#ifndef ARRAY_SIZE -#define ARRAY_SIZE(array) (sizeof(array)/sizeof((array)[0])) -#endif - /* The driver names reflect the lowest GPU supported * by a certain driver, so DRIVER_AMD_R300 supports * R3xx, R4xx and R5xx GPUs. */ @@ -57,6 +53,7 @@ DRIVER_NVIDIA_GEFORCE2MX, DRIVER_NVIDIA_GEFORCEFX, DRIVER_NVIDIA_GEFORCE6, + DRIVER_NVIDIA_GEFORCE8, DRIVER_VMWARE, DRIVER_UNKNOWN }; @@ -1165,9 +1162,9 @@ {DRIVER_AMD_RAGE_128PRO, DRIVER_MODEL_NT5X, "ati2dvaa.dll", 13, 3279, 0}, {DRIVER_AMD_R100, DRIVER_MODEL_NT5X, "ati2dvag.dll", 14, 10, 6614}, {DRIVER_AMD_R300, DRIVER_MODEL_NT5X, "ati2dvag.dll", 14, 10, 6764}, - {DRIVER_AMD_R600, DRIVER_MODEL_NT5X, "ati2dvag.dll", 14, 10, 8681}, + {DRIVER_AMD_R600, DRIVER_MODEL_NT5X, "ati2dvag.dll", 17, 10, 1280}, {DRIVER_AMD_R300, DRIVER_MODEL_NT6X, "atiumdag.dll", 14, 10, 741 }, - {DRIVER_AMD_R600, DRIVER_MODEL_NT6X, "atiumdag.dll", 14, 10, 741 }, + {DRIVER_AMD_R600, DRIVER_MODEL_NT6X, "atiumdag.dll", 17, 10, 1280 }, /* Intel * The drivers are unified but not all versions support all GPUs. At some point the 2k/xp @@ -1181,7 +1178,8 @@ {DRIVER_INTEL_GMA3000, DRIVER_MODEL_NT6X, "igdumd32.dll", 15, 10, 1666}, /* Nvidia - * - Geforce6 and newer cards are supported by the current driver (197.x) on XP-Win7 + * - Geforce8 and newer is supported by the current 340.52 driver on XP-Win8 + * - Geforce6 and 7 support is up to 307.83 on XP-Win8 * - GeforceFX support is up to 173.x on <= XP * - Geforce2MX/3/4 up to 96.x on <= XP * - TNT/Geforce1/2 up to 71.x on <= XP @@ -1189,8 +1187,10 @@ {DRIVER_NVIDIA_TNT, DRIVER_MODEL_NT5X, "nv4_disp.dll", 14, 10, 7186}, {DRIVER_NVIDIA_GEFORCE2MX, DRIVER_MODEL_NT5X, "nv4_disp.dll", 14, 10, 9371}, {DRIVER_NVIDIA_GEFORCEFX, DRIVER_MODEL_NT5X, "nv4_disp.dll", 14, 11, 7516}, - {DRIVER_NVIDIA_GEFORCE6, DRIVER_MODEL_NT5X, "nv4_disp.dll", 15, 12, 6658}, - {DRIVER_NVIDIA_GEFORCE6, DRIVER_MODEL_NT6X, "nvd3dum.dll", 15, 12, 6658}, + {DRIVER_NVIDIA_GEFORCE6, DRIVER_MODEL_NT5X, "nv4_disp.dll", 18, 13, 783}, + {DRIVER_NVIDIA_GEFORCE8, DRIVER_MODEL_NT5X, "nv4_disp.dll", 18, 13, 4052}, + {DRIVER_NVIDIA_GEFORCE6, DRIVER_MODEL_NT6X, "nvd3dum.dll", 18, 13, 783}, + {DRIVER_NVIDIA_GEFORCE8, DRIVER_MODEL_NT6X, "nvd3dum.dll", 18, 13, 4052}, /* VMware */ {DRIVER_VMWARE, DRIVER_MODEL_NT5X, "vm3dum.dll", 14, 1, 1134}, @@ -1228,70 +1228,71 @@ {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7400, "NVIDIA GeForce Go 7400", DRIVER_NVIDIA_GEFORCE6, 256 }, {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7600, "NVIDIA GeForce 7600 GT", DRIVER_NVIDIA_GEFORCE6, 256 }, {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_7800GT, "NVIDIA GeForce 7800 GT", DRIVER_NVIDIA_GEFORCE6, 256 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8300GS, "NVIDIA GeForce 8300 GS", DRIVER_NVIDIA_GEFORCE6, 128 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8400GS, "NVIDIA GeForce 8400 GS", DRIVER_NVIDIA_GEFORCE6, 128 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8600GT, "NVIDIA GeForce 8600 GT", DRIVER_NVIDIA_GEFORCE6, 256 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8600MGT, "NVIDIA GeForce 8600M GT", DRIVER_NVIDIA_GEFORCE6, 512 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8800GTS, "NVIDIA GeForce 8800 GTS", DRIVER_NVIDIA_GEFORCE6, 320 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8800GTX, "NVIDIA GeForce 8800 GTX", DRIVER_NVIDIA_GEFORCE6, 768 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9200, "NVIDIA GeForce 9200", DRIVER_NVIDIA_GEFORCE6, 256 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9300, "NVIDIA GeForce 9300", DRIVER_NVIDIA_GEFORCE6, 256 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9400M, "NVIDIA GeForce 9400M", DRIVER_NVIDIA_GEFORCE6, 256 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9400GT, "NVIDIA GeForce 9400 GT", DRIVER_NVIDIA_GEFORCE6, 256 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9500GT, "NVIDIA GeForce 9500 GT", DRIVER_NVIDIA_GEFORCE6, 256 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9600GT, "NVIDIA GeForce 9600 GT", DRIVER_NVIDIA_GEFORCE6, 384 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9800GT, "NVIDIA GeForce 9800 GT", DRIVER_NVIDIA_GEFORCE6, 512 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_210, "NVIDIA GeForce 210", DRIVER_NVIDIA_GEFORCE6, 512 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT220, "NVIDIA GeForce GT 220", DRIVER_NVIDIA_GEFORCE6, 512 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT240, "NVIDIA GeForce GT 240", DRIVER_NVIDIA_GEFORCE6, 512 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX260, "NVIDIA GeForce GTX 260", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX275, "NVIDIA GeForce GTX 275", DRIVER_NVIDIA_GEFORCE6, 896 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX280, "NVIDIA GeForce GTX 280", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_315M, "NVIDIA GeForce 315M", DRIVER_NVIDIA_GEFORCE6, 512 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_320M, "NVIDIA GeForce 320M", DRIVER_NVIDIA_GEFORCE6, 256}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_410M, "NVIDIA GeForce 410M", DRIVER_NVIDIA_GEFORCE6, 512}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT320M, "NVIDIA GeForce GT 320M", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT325M, "NVIDIA GeForce GT 325M", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT330, "NVIDIA GeForce GT 330", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTS350M, "NVIDIA GeForce GTS 350M", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT420, "NVIDIA GeForce GT 420", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT430, "NVIDIA GeForce GT 430", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT440, "NVIDIA GeForce GT 440", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTS450, "NVIDIA GeForce GTS 450", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX460, "NVIDIA GeForce GTX 460", DRIVER_NVIDIA_GEFORCE6, 768 }, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX460M, "NVIDIA GeForce GTX 460M", DRIVER_NVIDIA_GEFORCE6, 1536}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX465, "NVIDIA GeForce GTX 465", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX470, "NVIDIA GeForce GTX 470", DRIVER_NVIDIA_GEFORCE6, 1280}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX480, "NVIDIA GeForce GTX 480", DRIVER_NVIDIA_GEFORCE6, 1536}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT520, "NVIDIA GeForce GT 520", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT540M, "NVIDIA GeForce GT 540M", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX550, "NVIDIA GeForce GTX 550 Ti", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT555M, "NVIDIA GeForce GT 555M", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX560TI, "NVIDIA GeForce GTX 560 Ti", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX560, "NVIDIA GeForce GTX 560", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX570, "NVIDIA GeForce GTX 570", DRIVER_NVIDIA_GEFORCE6, 1280}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX580, "NVIDIA GeForce GTX 580", DRIVER_NVIDIA_GEFORCE6, 1536}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT610, "NVIDIA GeForce GT 610", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT630, "NVIDIA GeForce GT 630", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT630M, "NVIDIA GeForce GT 630M", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT640M, "NVIDIA GeForce GT 640M", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT650M, "NVIDIA GeForce GT 650M", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX650, "NVIDIA GeForce GTX 650", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX650TI, "NVIDIA GeForce GTX 650 Ti", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX660, "NVIDIA GeForce GTX 660", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX660M, "NVIDIA GeForce GTX 660M", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX660TI, "NVIDIA GeForce GTX 660 Ti", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX670, "NVIDIA GeForce GTX 670", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX670MX, "NVIDIA GeForce GTX 670MX", DRIVER_NVIDIA_GEFORCE6, 3072}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX680, "NVIDIA GeForce GTX 680", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX750, "NVIDIA GeForce GTX 750", DRIVER_NVIDIA_GEFORCE6, 1024}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX750TI, "NVIDIA GeForce GTX 750 Ti", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX760, "NVIDIA Geforce GTX 760", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX765M, "NVIDIA GeForce GTX 765M", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX770M, "NVIDIA GeForce GTX 770M", DRIVER_NVIDIA_GEFORCE6, 3072}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX770, "NVIDIA GeForce GTX 770", DRIVER_NVIDIA_GEFORCE6, 2048}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX780, "NVIDIA GeForce GTX 780", DRIVER_NVIDIA_GEFORCE6, 3072}, - {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX780TI, "NVIDIA GeForce GTX 780 Ti", DRIVER_NVIDIA_GEFORCE6, 3072}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8300GS, "NVIDIA GeForce 8300 GS", DRIVER_NVIDIA_GEFORCE8, 128 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8400GS, "NVIDIA GeForce 8400 GS", DRIVER_NVIDIA_GEFORCE8, 128 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8600GT, "NVIDIA GeForce 8600 GT", DRIVER_NVIDIA_GEFORCE8, 256 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8600MGT, "NVIDIA GeForce 8600M GT", DRIVER_NVIDIA_GEFORCE8, 512 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8800GTS, "NVIDIA GeForce 8800 GTS", DRIVER_NVIDIA_GEFORCE8, 320 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_8800GTX, "NVIDIA GeForce 8800 GTX", DRIVER_NVIDIA_GEFORCE8, 768 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9200, "NVIDIA GeForce 9200", DRIVER_NVIDIA_GEFORCE8, 256 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9300, "NVIDIA GeForce 9300", DRIVER_NVIDIA_GEFORCE8, 256 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9400M, "NVIDIA GeForce 9400M", DRIVER_NVIDIA_GEFORCE8, 256 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9400GT, "NVIDIA GeForce 9400 GT", DRIVER_NVIDIA_GEFORCE8, 256 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9500GT, "NVIDIA GeForce 9500 GT", DRIVER_NVIDIA_GEFORCE8, 256 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9600GT, "NVIDIA GeForce 9600 GT", DRIVER_NVIDIA_GEFORCE8, 384 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_9800GT, "NVIDIA GeForce 9800 GT", DRIVER_NVIDIA_GEFORCE8, 512 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_210, "NVIDIA GeForce 210", DRIVER_NVIDIA_GEFORCE8, 512 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT220, "NVIDIA GeForce GT 220", DRIVER_NVIDIA_GEFORCE8, 512 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT240, "NVIDIA GeForce GT 240", DRIVER_NVIDIA_GEFORCE8, 512 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX260, "NVIDIA GeForce GTX 260", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX275, "NVIDIA GeForce GTX 275", DRIVER_NVIDIA_GEFORCE8, 896 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX280, "NVIDIA GeForce GTX 280", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_315M, "NVIDIA GeForce 315M", DRIVER_NVIDIA_GEFORCE8, 512 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_320M, "NVIDIA GeForce 320M", DRIVER_NVIDIA_GEFORCE8, 256}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_410M, "NVIDIA GeForce 410M", DRIVER_NVIDIA_GEFORCE8, 512}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT320M, "NVIDIA GeForce GT 320M", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT325M, "NVIDIA GeForce GT 325M", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT330, "NVIDIA GeForce GT 330", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTS350M, "NVIDIA GeForce GTS 350M", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT420, "NVIDIA GeForce GT 420", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT430, "NVIDIA GeForce GT 430", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT440, "NVIDIA GeForce GT 440", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTS450, "NVIDIA GeForce GTS 450", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX460, "NVIDIA GeForce GTX 460", DRIVER_NVIDIA_GEFORCE8, 768 }, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX460M, "NVIDIA GeForce GTX 460M", DRIVER_NVIDIA_GEFORCE8, 1536}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX465, "NVIDIA GeForce GTX 465", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX470, "NVIDIA GeForce GTX 470", DRIVER_NVIDIA_GEFORCE8, 1280}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX480, "NVIDIA GeForce GTX 480", DRIVER_NVIDIA_GEFORCE8, 1536}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT520, "NVIDIA GeForce GT 520", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT540M, "NVIDIA GeForce GT 540M", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX550, "NVIDIA GeForce GTX 550 Ti", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT555M, "NVIDIA GeForce GT 555M", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX560TI, "NVIDIA GeForce GTX 560 Ti", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX560, "NVIDIA GeForce GTX 560", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX570, "NVIDIA GeForce GTX 570", DRIVER_NVIDIA_GEFORCE8, 1280}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX580, "NVIDIA GeForce GTX 580", DRIVER_NVIDIA_GEFORCE8, 1536}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT610, "NVIDIA GeForce GT 610", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT630, "NVIDIA GeForce GT 630", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT630M, "NVIDIA GeForce GT 630M", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT640M, "NVIDIA GeForce GT 640M", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT650M, "NVIDIA GeForce GT 650M", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX650, "NVIDIA GeForce GTX 650", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX650TI, "NVIDIA GeForce GTX 650 Ti", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX660, "NVIDIA GeForce GTX 660", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX660M, "NVIDIA GeForce GTX 660M", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX660TI, "NVIDIA GeForce GTX 660 Ti", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX670, "NVIDIA GeForce GTX 670", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX670MX, "NVIDIA GeForce GTX 670MX", DRIVER_NVIDIA_GEFORCE8, 3072}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX680, "NVIDIA GeForce GTX 680", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT750M, "NVIDIA GeForce GT 750M", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX750, "NVIDIA GeForce GTX 750", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX750TI, "NVIDIA GeForce GTX 750 Ti", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX760, "NVIDIA Geforce GTX 760", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX765M, "NVIDIA GeForce GTX 765M", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX770M, "NVIDIA GeForce GTX 770M", DRIVER_NVIDIA_GEFORCE8, 3072}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX770, "NVIDIA GeForce GTX 770", DRIVER_NVIDIA_GEFORCE8, 2048}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX780, "NVIDIA GeForce GTX 780", DRIVER_NVIDIA_GEFORCE8, 3072}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX780TI, "NVIDIA GeForce GTX 780 Ti", DRIVER_NVIDIA_GEFORCE8, 3072}, /* AMD cards */ {HW_VENDOR_AMD, CARD_AMD_RAGE_128PRO, "ATI Rage Fury", DRIVER_AMD_RAGE_128PRO, 16 }, @@ -1727,6 +1728,7 @@ {"GTX 760", CARD_NVIDIA_GEFORCE_GTX760}, /* Geforce 700 - midend high */ {"GTX 750 Ti", CARD_NVIDIA_GEFORCE_GTX750TI}, /* Geforce 700 - midend */ {"GTX 750", CARD_NVIDIA_GEFORCE_GTX750}, /* Geforce 700 - midend */ + {"GT 750M", CARD_NVIDIA_GEFORCE_GT750M}, /* Geforce 700 - midend mobile */ {"GTX 680", CARD_NVIDIA_GEFORCE_GTX680}, /* Geforce 600 - highend */ {"GTX 670MX", CARD_NVIDIA_GEFORCE_GTX670MX}, /* Geforce 600 - highend */ {"GTX 670", CARD_NVIDIA_GEFORCE_GTX670}, /* Geforce 600 - midend high */ diff -Nru wine1.7-1.7.28/dlls/wined3d/glsl_shader.c wine1.7-1.7.31/dlls/wined3d/glsl_shader.c --- wine1.7-1.7.28/dlls/wined3d/glsl_shader.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/glsl_shader.c 2014-11-14 13:28:17.000000000 +0000 @@ -971,7 +971,7 @@ } /* Declare the constants (aka uniforms) */ - if (shader->limits.constant_float > 0) + if (shader->limits->constant_float > 0) { unsigned max_constantsF; @@ -1025,7 +1025,7 @@ /* Set by driver quirks in directx.c */ max_constantsF -= gl_info->reserved_glsl_constants; - if (max_constantsF < shader->limits.constant_float) + if (max_constantsF < shader->limits->constant_float) { static unsigned int once; @@ -1041,18 +1041,18 @@ max_constantsF = gl_info->limits.glsl_vs_float_constants; } } - max_constantsF = min(shader->limits.constant_float, max_constantsF); + max_constantsF = min(shader->limits->constant_float, max_constantsF); shader_addline(buffer, "uniform vec4 %s_c[%u];\n", prefix, max_constantsF); } /* Always declare the full set of constants, the compiler can remove the * unused ones because d3d doesn't (yet) support indirect int and bool * constant addressing. This avoids problems if the app uses e.g. i0 and i9. */ - if (shader->limits.constant_int > 0 && reg_maps->integer_constants) - shader_addline(buffer, "uniform ivec4 %s_i[%u];\n", prefix, shader->limits.constant_int); + if (shader->limits->constant_int > 0 && reg_maps->integer_constants) + shader_addline(buffer, "uniform ivec4 %s_i[%u];\n", prefix, shader->limits->constant_int); - if (shader->limits.constant_bool > 0 && reg_maps->boolean_constants) - shader_addline(buffer, "uniform bool %s_b[%u];\n", prefix, shader->limits.constant_bool); + if (shader->limits->constant_bool > 0 && reg_maps->boolean_constants) + shader_addline(buffer, "uniform bool %s_b[%u];\n", prefix, shader->limits->constant_bool); for (i = 0; i < WINED3D_MAX_CBS; ++i) { @@ -1062,7 +1062,7 @@ } /* Declare texture samplers */ - for (i = 0; i < shader->limits.sampler; ++i) + for (i = 0; i < shader->limits->sampler; ++i) { if (reg_maps->sampler_type[i]) { @@ -1128,7 +1128,7 @@ * samplerNP2Fixup stores texture dimensions and is updated through * shader_glsl_load_np2fixup_constants when the sampler changes. */ - for (i = 0; i < shader->limits.sampler; ++i) + for (i = 0; i < shader->limits->sampler; ++i) { if (reg_maps->sampler_type[i]) { @@ -1170,17 +1170,17 @@ } shader_addline(buffer, "uniform vec4 posFixup;\n"); - shader_addline(buffer, "void order_ps_input(in vec4[%u]);\n", shader->limits.packed_output); + shader_addline(buffer, "void order_ps_input(in vec4[%u]);\n", shader->limits->packed_output); } else if (version->type == WINED3D_SHADER_TYPE_GEOMETRY) { - shader_addline(buffer, "varying in vec4 gs_in[][%u];\n", shader->limits.packed_input); + shader_addline(buffer, "varying in vec4 gs_in[][%u];\n", shader->limits->packed_input); } else if (version->type == WINED3D_SHADER_TYPE_PIXEL) { if (version->major >= 3) { - UINT in_count = min(vec4_varyings(version->major, gl_info), shader->limits.packed_input); + UINT in_count = min(vec4_varyings(version->major, gl_info), shader->limits->packed_input); if (use_vs(state)) shader_addline(buffer, "varying vec4 %s_in[%u];\n", prefix, in_count); @@ -1221,7 +1221,7 @@ } if (reg_maps->vpos || reg_maps->usesdsy) { - if (shader->limits.constant_float + extra_constants_needed + if (shader->limits->constant_float + extra_constants_needed + 1 < gl_info->limits.glsl_ps_float_constants) { shader_addline(buffer, "uniform vec4 ycorrection;\n"); @@ -1250,8 +1250,8 @@ } /* Declare output register temporaries */ - if (shader->limits.packed_output) - shader_addline(buffer, "vec4 %s_out[%u];\n", prefix, shader->limits.packed_output); + if (shader->limits->packed_output) + shader_addline(buffer, "vec4 %s_out[%u];\n", prefix, shader->limits->packed_output); /* Declare temporary variables */ for (i = 0, map = reg_maps->temporary; map; map >>= 1, ++i) @@ -4306,7 +4306,7 @@ if (ps_major < 3) { - shader_addline(buffer, "void order_ps_input(in vec4 vs_out[%u])\n{\n", vs->limits.packed_output); + shader_addline(buffer, "void order_ps_input(in vec4 vs_out[%u])\n{\n", vs->limits->packed_output); for (i = 0; map; map >>= 1, ++i) { @@ -4359,10 +4359,10 @@ } else { - UINT in_count = min(vec4_varyings(ps_major, gl_info), ps->limits.packed_input); + UINT in_count = min(vec4_varyings(ps_major, gl_info), ps->limits->packed_input); /* This one is tricky: a 3.0 pixel shader reads from a 3.0 vertex shader */ shader_addline(buffer, "varying vec4 ps_in[%u];\n", in_count); - shader_addline(buffer, "void order_ps_input(in vec4 vs_out[%u])\n{\n", vs->limits.packed_output); + shader_addline(buffer, "void order_ps_input(in vec4 vs_out[%u])\n{\n", vs->limits->packed_output); /* First, sort out position and point size. Those are not passed to the pixel shader */ for (i = 0; map; map >>= 1, ++i) @@ -5958,9 +5958,9 @@ shader_glsl_validate_link(gl_info, programId); shader_glsl_init_vs_uniform_locations(gl_info, programId, &entry->vs, - vshader ? vshader->limits.constant_float : 0); + vshader ? min(vshader->limits->constant_float, gl_info->limits.glsl_vs_float_constants) : 0); shader_glsl_init_ps_uniform_locations(gl_info, programId, &entry->ps, - pshader ? pshader->limits.constant_float : 0); + pshader ? min(pshader->limits->constant_float, gl_info->limits.glsl_ps_float_constants) : 0); checkGLcall("Find glsl program uniform locations"); if (pshader && pshader->reg_maps.shader_version.major >= 3 diff -Nru wine1.7-1.7.28/dlls/wined3d/resource.c wine1.7-1.7.31/dlls/wined3d/resource.c --- wine1.7-1.7.28/dlls/wined3d/resource.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/resource.c 2014-11-14 13:28:17.000000000 +0000 @@ -151,7 +151,7 @@ if (resource->pool == WINED3D_POOL_DEFAULT && d3d->flags & WINED3D_VIDMEM_ACCOUNTING) { TRACE("Decrementing device memory pool by %u.\n", resource->size); - adapter_adjust_memory(resource->device->adapter, 0 - resource->size); + adapter_adjust_memory(resource->device->adapter, (INT64)0 - resource->size); } wined3d_resource_free_sysmem(resource); diff -Nru wine1.7-1.7.28/dlls/wined3d/shader.c wine1.7-1.7.31/dlls/wined3d/shader.c --- wine1.7-1.7.28/dlls/wined3d/shader.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/shader.c 2014-11-14 13:28:17.000000000 +0000 @@ -370,6 +370,84 @@ list_init(clist); } +static void shader_set_limits(struct wined3d_shader *shader) +{ + static const struct limits_entry + { + unsigned int min_version; + unsigned int max_version; + struct wined3d_shader_limits limits; + } + vs_limits[] = + { + /* min_version, max_version, sampler, constant_int, constant_float, constant_bool, packed_output, packed_input */ + {WINED3D_SHADER_VERSION(1, 0), WINED3D_SHADER_VERSION(1, 1), { 0, 0, 256, 0, 12, 0}}, + {WINED3D_SHADER_VERSION(2, 0), WINED3D_SHADER_VERSION(2, 1), { 0, 16, 256, 16, 12, 0}}, + /* DX10 cards on Windows advertise a D3D9 constant limit of 256 + * even though they are capable of supporting much more (GL + * drivers advertise 1024). d3d9.dll and d3d8.dll clamp the + * wined3d-advertised maximum. Clamp the constant limit for <= 3.0 + * shaders to 256. */ + {WINED3D_SHADER_VERSION(3, 0), WINED3D_SHADER_VERSION(3, 0), { 4, 16, 256, 16, 12, 0}}, + {WINED3D_SHADER_VERSION(4, 0), WINED3D_SHADER_VERSION(4, 0), {16, 0, 0, 0, 16, 0}}, + {0} + }, + gs_limits[] = + { + /* min_version, max_version, sampler, constant_int, constant_float, constant_bool, packed_output, packed_input */ + {WINED3D_SHADER_VERSION(4, 0), WINED3D_SHADER_VERSION(4, 0), {16, 0, 0, 0, 32, 16}}, + {0} + }, + ps_limits[] = + { + /* min_version, max_version, sampler, constant_int, constant_float, constant_bool, packed_output, packed_input */ + {WINED3D_SHADER_VERSION(1, 0), WINED3D_SHADER_VERSION(1, 3), { 4, 0, 8, 0, 0, 0}}, + {WINED3D_SHADER_VERSION(1, 4), WINED3D_SHADER_VERSION(1, 4), { 6, 0, 8, 0, 0, 0}}, + {WINED3D_SHADER_VERSION(2, 0), WINED3D_SHADER_VERSION(2, 0), {16, 0, 32, 0, 0, 0}}, + {WINED3D_SHADER_VERSION(2, 1), WINED3D_SHADER_VERSION(2, 1), {16, 16, 32, 16, 0, 0}}, + {WINED3D_SHADER_VERSION(3, 0), WINED3D_SHADER_VERSION(3, 0), {16, 16, 224, 16, 0, 12}}, + {WINED3D_SHADER_VERSION(4, 0), WINED3D_SHADER_VERSION(4, 0), {16, 0, 0, 0, 0, 32}}, + {0} + }; + const struct limits_entry *limits_array; + DWORD shader_version = WINED3D_SHADER_VERSION(shader->reg_maps.shader_version.major, + shader->reg_maps.shader_version.minor); + int i = 0; + + switch (shader->reg_maps.shader_version.type) + { + default: + FIXME("Unexpected shader type %u found.\n", shader->reg_maps.shader_version.type); + /* Fall-through. */ + case WINED3D_SHADER_TYPE_VERTEX: + limits_array = vs_limits; + break; + case WINED3D_SHADER_TYPE_GEOMETRY: + limits_array = gs_limits; + break; + case WINED3D_SHADER_TYPE_PIXEL: + limits_array = ps_limits; + break; + } + + while (limits_array[i].min_version && limits_array[i].min_version <= shader_version) + { + if (shader_version <= limits_array[i].max_version) + { + shader->limits = &limits_array[i].limits; + break; + } + ++i; + } + if (!shader->limits) + { + FIXME("Unexpected shader version \"%u.%u\".\n", + shader->reg_maps.shader_version.major, + shader->reg_maps.shader_version.minor); + shader->limits = &limits_array[max(0, i - 1)].limits; + } +} + static inline void set_bitmap_bit(DWORD *bitmap, DWORD bit) { DWORD idx, shift; @@ -378,8 +456,8 @@ bitmap[idx] |= (1 << shift); } -static void shader_record_register_usage(struct wined3d_shader *shader, struct wined3d_shader_reg_maps *reg_maps, - const struct wined3d_shader_register *reg, enum wined3d_shader_type shader_type) +static BOOL shader_record_register_usage(struct wined3d_shader *shader, struct wined3d_shader_reg_maps *reg_maps, + const struct wined3d_shader_register *reg, enum wined3d_shader_type shader_type, unsigned int constf_size) { switch (reg->type) { @@ -443,16 +521,40 @@ } else { - set_bitmap_bit(reg_maps->constf, reg->idx[0].offset); + if (reg->idx[0].offset >= min(shader->limits->constant_float, constf_size)) + { + WARN("Shader using float constant %u which is not supported.\n", reg->idx[0].offset); + return FALSE; + } + else + { + set_bitmap_bit(reg_maps->constf, reg->idx[0].offset); + } } break; case WINED3DSPR_CONSTINT: - reg_maps->integer_constants |= (1 << reg->idx[0].offset); + if (reg->idx[0].offset >= shader->limits->constant_int) + { + WARN("Shader using integer constant %u which is not supported.\n", reg->idx[0].offset); + return FALSE; + } + else + { + reg_maps->integer_constants |= (1 << reg->idx[0].offset); + } break; case WINED3DSPR_CONSTBOOL: - reg_maps->boolean_constants |= (1 << reg->idx[0].offset); + if (reg->idx[0].offset >= shader->limits->constant_bool) + { + WARN("Shader using bool constant %u which is not supported.\n", reg->idx[0].offset); + return FALSE; + } + else + { + reg_maps->boolean_constants |= (1 << reg->idx[0].offset); + } break; case WINED3DSPR_COLOROUT: @@ -464,6 +566,7 @@ reg->type, reg->idx[0].offset, reg->idx[1].offset); break; } + return TRUE; } static unsigned int get_instr_extra_regcount(enum WINED3D_SHADER_INSTRUCTION_HANDLER instr, unsigned int param) @@ -502,8 +605,10 @@ fe->shader_read_header(fe_data, &ptr, &shader_version); reg_maps->shader_version = shader_version; + shader_set_limits(shader); + reg_maps->constf = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, - sizeof(*reg_maps->constf) * ((constf_size + 31) / 32)); + sizeof(*reg_maps->constf) * ((min(shader->limits->constant_float, constf_size) + 31) / 32)); if (!reg_maps->constf) { ERR("Failed to allocate constant map memory.\n"); @@ -659,7 +764,9 @@ * they are initialized (required by spec). */ for (i = 0; i < ins.dst_count; ++i) { - shader_record_register_usage(shader, reg_maps, &ins.dst[i].reg, shader_version.type); + if (!shader_record_register_usage(shader, reg_maps, &ins.dst[i].reg, + shader_version.type, constf_size)) + return WINED3DERR_INVALIDCALL; /* WINED3DSPR_TEXCRDOUT is the same as WINED3DSPR_OUTPUT. _OUTPUT can be > MAX_REG_TEXCRD and * is used in >= 3.0 shaders. Filter 3.0 shaders to prevent overflows, and also filter pixel @@ -817,18 +924,24 @@ --cur_loop_depth; if (ins.predicate) - shader_record_register_usage(shader, reg_maps, &ins.predicate->reg, shader_version.type); + if (!shader_record_register_usage(shader, reg_maps, &ins.predicate->reg, + shader_version.type, constf_size)) + return WINED3DERR_INVALIDCALL; for (i = 0; i < ins.src_count; ++i) { unsigned int count = get_instr_extra_regcount(ins.handler_idx, i); struct wined3d_shader_register reg = ins.src[i].reg; - shader_record_register_usage(shader, reg_maps, &ins.src[i].reg, shader_version.type); + if (!shader_record_register_usage(shader, reg_maps, &ins.src[i].reg, + shader_version.type, constf_size)) + return WINED3DERR_INVALIDCALL; while (count) { ++reg.idx[0].offset; - shader_record_register_usage(shader, reg_maps, ®, shader_version.type); + if (!shader_record_register_usage(shader, reg_maps, ®, + shader_version.type, constf_size)) + return WINED3DERR_INVALIDCALL; --count; } @@ -1490,6 +1603,7 @@ static void shader_cleanup(struct wined3d_shader *shader) { + HeapFree(GetProcessHeap(), 0, shader->signature_strings); shader->device->shader_backend->shader_destroy(shader); HeapFree(GetProcessHeap(), 0, shader->reg_maps.constf); HeapFree(GetProcessHeap(), 0, shader->function); @@ -1790,11 +1904,11 @@ TRACE("shader %p, start_idx %u, src_data %p, count %u.\n", shader, start_idx, src_data, count); - if (end_idx > shader->limits.constant_float) + if (end_idx > shader->limits->constant_float) { WARN("end_idx %u > float constants limit %u.\n", - end_idx, shader->limits.constant_float); - end_idx = shader->limits.constant_float; + end_idx, shader->limits->constant_float); + end_idx = shader->limits->constant_float; } for (i = start_idx; i < end_idx; ++i) @@ -1863,75 +1977,8 @@ return FALSE; } -static void vertexshader_set_limits(struct wined3d_shader *shader) -{ - DWORD shader_version = WINED3D_SHADER_VERSION(shader->reg_maps.shader_version.major, - shader->reg_maps.shader_version.minor); - struct wined3d_device *device = shader->device; - const DWORD vs_uniform_count = device->adapter->d3d_info.limits.vs_uniform_count; - - shader->limits.packed_input = 0; - - switch (shader_version) - { - case WINED3D_SHADER_VERSION(1, 0): - case WINED3D_SHADER_VERSION(1, 1): - shader->limits.constant_bool = 0; - shader->limits.constant_int = 0; - shader->limits.packed_output = 12; - shader->limits.sampler = 0; - /* TODO: vs_1_1 has a minimum of 96 constants. What happens when - * a vs_1_1 shader is used on a vs_3_0 capable card that has 256 - * constants? */ - shader->limits.constant_float = min(256, vs_uniform_count); - break; - - case WINED3D_SHADER_VERSION(2, 0): - case WINED3D_SHADER_VERSION(2, 1): - shader->limits.constant_bool = 16; - shader->limits.constant_int = 16; - shader->limits.packed_output = 12; - shader->limits.sampler = 0; - shader->limits.constant_float = min(256, vs_uniform_count); - break; - - case WINED3D_SHADER_VERSION(3, 0): - shader->limits.constant_bool = 16; - shader->limits.constant_int = 16; - shader->limits.packed_output = 12; - shader->limits.sampler = 4; - /* DX10 cards on Windows advertise a d3d9 constant limit of 256 - * even though they are capable of supporting much more (GL - * drivers advertise 1024). d3d9.dll and d3d8.dll clamp the - * wined3d-advertised maximum. Clamp the constant limit for <= 3.0 - * shaders to 256. */ - shader->limits.constant_float = min(256, vs_uniform_count); - break; - - case WINED3D_SHADER_VERSION(4, 0): - shader->limits.sampler = 16; /* FIXME: 128 resources, 16 sampler states */ - shader->limits.constant_int = 0; - shader->limits.constant_float = 0; - shader->limits.constant_bool = 0; - shader->limits.packed_output = 16; - shader->limits.packed_input = 0; - break; - - default: - shader->limits.constant_bool = 16; - shader->limits.constant_int = 16; - shader->limits.packed_output = 12; - shader->limits.sampler = 0; - shader->limits.constant_float = min(256, vs_uniform_count); - FIXME("Unrecognized vertex shader version \"%u.%u\".\n", - shader->reg_maps.shader_version.major, - shader->reg_maps.shader_version.minor); - } -} - static HRESULT vertexshader_init(struct wined3d_shader *shader, struct wined3d_device *device, - const DWORD *byte_code, const struct wined3d_shader_signature *output_signature, - void *parent, const struct wined3d_parent_ops *parent_ops, unsigned int max_version) + const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops) { struct wined3d_shader_reg_maps *reg_maps = &shader->reg_maps; unsigned int i; @@ -1939,12 +1986,12 @@ WORD map; const DWORD vs_uniform_count = device->adapter->d3d_info.limits.vs_uniform_count; - if (!byte_code) return WINED3DERR_INVALIDCALL; + if (!desc->byte_code) + return WINED3DERR_INVALIDCALL; shader_init(shader, device, parent, parent_ops); - hr = shader_set_function(shader, byte_code, output_signature, vs_uniform_count, - WINED3D_SHADER_TYPE_VERTEX, max_version); - if (FAILED(hr)) + if (FAILED(hr = shader_set_function(shader, desc->byte_code, desc->output_signature, + vs_uniform_count, WINED3D_SHADER_TYPE_VERTEX, desc->max_version))) { WARN("Failed to set function, hr %#x.\n", hr); shader_cleanup(shader); @@ -1962,66 +2009,66 @@ shader->u.vs.attributes[i].usage_idx = shader->input_signature[i].semantic_idx; } - if (output_signature) + if (desc->output_signature) { - for (i = 0; i < output_signature->element_count; ++i) + struct wined3d_shader_signature_element *e; + SIZE_T total, len; + char *ptr; + + total = 0; + for (i = 0; i < desc->output_signature->element_count; ++i) + { + e = &desc->output_signature->elements[i]; + len = strlen(e->semantic_name); + if (len >= ~(SIZE_T)0 - total) + { + shader_cleanup(shader); + return E_OUTOFMEMORY; + } + + total += len + 1; + } + + if (!(shader->signature_strings = HeapAlloc(GetProcessHeap(), 0, total))) { - struct wined3d_shader_signature_element *e = &output_signature->elements[i]; + shader_cleanup(shader); + return E_OUTOFMEMORY; + } + ptr = shader->signature_strings; + + for (i = 0; i < desc->output_signature->element_count; ++i) + { + e = &desc->output_signature->elements[i]; reg_maps->output_registers |= 1 << e->register_idx; shader->output_signature[e->register_idx] = *e; + + len = strlen(e->semantic_name); + memcpy(ptr, e->semantic_name, len + 1); + shader->output_signature[e->register_idx].semantic_name = ptr; + ptr += len + 1; } } - vertexshader_set_limits(shader); - shader->load_local_constsF = (reg_maps->usesrelconstF && !list_empty(&shader->constantsF)) || shader->lconst_inf_or_nan; return WINED3D_OK; } -static void geometryshader_set_limits(struct wined3d_shader *shader) -{ - DWORD shader_version = WINED3D_SHADER_VERSION(shader->reg_maps.shader_version.major, - shader->reg_maps.shader_version.minor); - - switch (shader_version) - { - case WINED3D_SHADER_VERSION(4, 0): - shader->limits.sampler = 16; /* FIXME: 128 resources, 16 sampler states */ - shader->limits.constant_int = 0; - shader->limits.constant_float = 0; - shader->limits.constant_bool = 0; - shader->limits.packed_output = 32; - shader->limits.packed_input = 16; - break; - - default: - memset(&shader->limits, 0, sizeof(shader->limits)); - FIXME("Unhandled geometry shader version \"%u.%u\".\n", - shader->reg_maps.shader_version.major, - shader->reg_maps.shader_version.minor); - } -} - static HRESULT geometryshader_init(struct wined3d_shader *shader, struct wined3d_device *device, - const DWORD *byte_code, const struct wined3d_shader_signature *output_signature, - void *parent, const struct wined3d_parent_ops *parent_ops, unsigned int max_version) + const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops) { HRESULT hr; shader_init(shader, device, parent, parent_ops); - hr = shader_set_function(shader, byte_code, output_signature, 0, - WINED3D_SHADER_TYPE_GEOMETRY, max_version); - if (FAILED(hr)) + if (FAILED(hr = shader_set_function(shader, desc->byte_code, desc->output_signature, + 0, WINED3D_SHADER_TYPE_GEOMETRY, desc->max_version))) { WARN("Failed to set function, hr %#x.\n", hr); shader_cleanup(shader); return hr; } - geometryshader_set_limits(shader); - shader->load_local_constsF = shader->lconst_inf_or_nan; return WINED3D_OK; @@ -2051,7 +2098,7 @@ if (shader->reg_maps.shader_version.major == 1 && shader->reg_maps.shader_version.minor <= 3) { - for (i = 0; i < shader->limits.sampler; ++i) + for (i = 0; i < shader->limits->sampler; ++i) { DWORD flags = state->texture_states[i][WINED3D_TSS_TEXTURE_TRANSFORM_FLAGS]; @@ -2105,7 +2152,7 @@ if (shader->reg_maps.shader_version.major == 1 && shader->reg_maps.shader_version.minor <= 4) { - for (i = 0; i < shader->limits.sampler; ++i) + for (i = 0; i < shader->limits->sampler; ++i) { const struct wined3d_texture *texture = state->textures[i]; @@ -2201,102 +2248,26 @@ } } -static void pixelshader_set_limits(struct wined3d_shader *shader) -{ - DWORD shader_version = WINED3D_SHADER_VERSION(shader->reg_maps.shader_version.major, - shader->reg_maps.shader_version.minor); - - shader->limits.packed_output = 0; - - switch (shader_version) - { - case WINED3D_SHADER_VERSION(1, 0): - case WINED3D_SHADER_VERSION(1, 1): - case WINED3D_SHADER_VERSION(1, 2): - case WINED3D_SHADER_VERSION(1, 3): - shader->limits.constant_float = 8; - shader->limits.constant_int = 0; - shader->limits.constant_bool = 0; - shader->limits.sampler = 4; - shader->limits.packed_input = 0; - break; - - case WINED3D_SHADER_VERSION(1, 4): - shader->limits.constant_float = 8; - shader->limits.constant_int = 0; - shader->limits.constant_bool = 0; - shader->limits.sampler = 6; - shader->limits.packed_input = 0; - break; - - /* FIXME: Temporaries must match D3DPSHADERCAPS2_0.NumTemps. */ - case WINED3D_SHADER_VERSION(2, 0): - shader->limits.constant_float = 32; - shader->limits.constant_int = 16; - shader->limits.constant_bool = 16; - shader->limits.sampler = 16; - shader->limits.packed_input = 0; - break; - - case WINED3D_SHADER_VERSION(2, 1): - shader->limits.constant_float = 32; - shader->limits.constant_int = 16; - shader->limits.constant_bool = 16; - shader->limits.sampler = 16; - shader->limits.packed_input = 0; - break; - - case WINED3D_SHADER_VERSION(3, 0): - shader->limits.constant_float = 224; - shader->limits.constant_int = 16; - shader->limits.constant_bool = 16; - shader->limits.sampler = 16; - shader->limits.packed_input = 12; - break; - - case WINED3D_SHADER_VERSION(4, 0): - shader->limits.sampler = 16; /* FIXME: 128 resources, 16 sampler states */ - shader->limits.constant_int = 0; - shader->limits.constant_float = 0; - shader->limits.constant_bool = 0; - shader->limits.packed_input = 32; - break; - - default: - shader->limits.constant_float = 32; - shader->limits.constant_int = 16; - shader->limits.constant_bool = 16; - shader->limits.sampler = 16; - shader->limits.packed_input = 0; - FIXME("Unrecognized pixel shader version %u.%u\n", - shader->reg_maps.shader_version.major, - shader->reg_maps.shader_version.minor); - } -} - static HRESULT pixelshader_init(struct wined3d_shader *shader, struct wined3d_device *device, - const DWORD *byte_code, const struct wined3d_shader_signature *output_signature, - void *parent, const struct wined3d_parent_ops *parent_ops, unsigned int max_version) + const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops) { const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; unsigned int i, highest_reg_used = 0, num_regs_used = 0; HRESULT hr; const DWORD ps_uniform_count = device->adapter->d3d_info.limits.ps_uniform_count; - if (!byte_code) return WINED3DERR_INVALIDCALL; + if (!desc->byte_code) + return WINED3DERR_INVALIDCALL; shader_init(shader, device, parent, parent_ops); - hr = shader_set_function(shader, byte_code, output_signature, ps_uniform_count, - WINED3D_SHADER_TYPE_PIXEL, max_version); - if (FAILED(hr)) + if (FAILED(hr = shader_set_function(shader, desc->byte_code, desc->output_signature, + ps_uniform_count, WINED3D_SHADER_TYPE_PIXEL, desc->max_version))) { WARN("Failed to set function, hr %#x.\n", hr); shader_cleanup(shader); return hr; } - pixelshader_set_limits(shader); - for (i = 0; i < MAX_REG_INPUT; ++i) { if (shader->u.ps.input_reg_used[i]) @@ -2339,6 +2310,46 @@ shader->load_local_constsF = shader->lconst_inf_or_nan; + if (desc->input_signature) + { + struct wined3d_shader_signature_element *e; + SIZE_T total, len; + char *ptr; + + total = 0; + for (i = 0; i < desc->input_signature->element_count; ++i) + { + e = &desc->input_signature->elements[i]; + len = strlen(e->semantic_name); + if (len >= ~(SIZE_T)0 - total) + { + shader_cleanup(shader); + return E_OUTOFMEMORY; + } + + total += len + 1; + } + + if (!(shader->signature_strings = HeapAlloc(GetProcessHeap(), 0, total))) + { + shader_cleanup(shader); + return E_OUTOFMEMORY; + } + ptr = shader->signature_strings; + + for (i = 0; i < desc->input_signature->element_count; ++i) + { + e = &desc->input_signature->elements[i]; + shader->reg_maps.input_registers |= 1 << e->register_idx; + shader->input_signature[e->register_idx] = *e; + + len = strlen(e->semantic_name); + memcpy(ptr, e->semantic_name, len + 1); + shader->output_signature[e->register_idx].semantic_name = ptr; + ptr += len + 1; + } + } + return WINED3D_OK; } @@ -2350,7 +2361,7 @@ if (reg_maps->shader_version.major != 1) return; - for (i = 0; i < shader->limits.sampler; ++i) + for (i = 0; i < shader->limits->sampler; ++i) { /* We don't sample from this sampler. */ if (!sampler_type[i]) continue; @@ -2372,22 +2383,20 @@ } } -HRESULT CDECL wined3d_shader_create_gs(struct wined3d_device *device, const DWORD *byte_code, - const struct wined3d_shader_signature *output_signature, void *parent, - const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader, unsigned int max_version) +HRESULT CDECL wined3d_shader_create_gs(struct wined3d_device *device, const struct wined3d_shader_desc *desc, + void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader) { struct wined3d_shader *object; HRESULT hr; - TRACE("device %p, byte_code %p, output_signature %p, parent %p, parent_ops %p, shader %p.\n", - device, byte_code, output_signature, parent, parent_ops, shader); + TRACE("device %p, desc %p, parent %p, parent_ops %p, shader %p.\n", + device, desc, parent, parent_ops, shader); object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*object)); if (!object) return E_OUTOFMEMORY; - hr = geometryshader_init(object, device, byte_code, output_signature, parent, parent_ops, max_version); - if (FAILED(hr)) + if (FAILED(hr = geometryshader_init(object, device, desc, parent, parent_ops))) { WARN("Failed to initialize geometry shader, hr %#x.\n", hr); HeapFree(GetProcessHeap(), 0, object); @@ -2400,22 +2409,20 @@ return WINED3D_OK; } -HRESULT CDECL wined3d_shader_create_ps(struct wined3d_device *device, const DWORD *byte_code, - const struct wined3d_shader_signature *output_signature, void *parent, - const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader, unsigned int max_version) +HRESULT CDECL wined3d_shader_create_ps(struct wined3d_device *device, const struct wined3d_shader_desc *desc, + void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader) { struct wined3d_shader *object; HRESULT hr; - TRACE("device %p, byte_code %p, output_signature %p, parent %p, parent_ops %p, shader %p.\n", - device, byte_code, output_signature, parent, parent_ops, shader); + TRACE("device %p, desc %p, parent %p, parent_ops %p, shader %p.\n", + device, desc, parent, parent_ops, shader); object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*object)); if (!object) return E_OUTOFMEMORY; - hr = pixelshader_init(object, device, byte_code, output_signature, parent, parent_ops, max_version); - if (FAILED(hr)) + if (FAILED(hr = pixelshader_init(object, device, desc, parent, parent_ops))) { WARN("Failed to initialize pixel shader, hr %#x.\n", hr); HeapFree(GetProcessHeap(), 0, object); @@ -2428,22 +2435,20 @@ return WINED3D_OK; } -HRESULT CDECL wined3d_shader_create_vs(struct wined3d_device *device, const DWORD *byte_code, - const struct wined3d_shader_signature *output_signature, void *parent, - const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader, unsigned int max_version) +HRESULT CDECL wined3d_shader_create_vs(struct wined3d_device *device, const struct wined3d_shader_desc *desc, + void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader) { struct wined3d_shader *object; HRESULT hr; - TRACE("device %p, byte_code %p, output_signature %p, parent %p, parent_ops %p, shader %p.\n", - device, byte_code, output_signature, parent, parent_ops, shader); + TRACE("device %p, desc %p, parent %p, parent_ops %p, shader %p.\n", + device, desc, parent, parent_ops, shader); object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*object)); if (!object) return E_OUTOFMEMORY; - hr = vertexshader_init(object, device, byte_code, output_signature, parent, parent_ops, max_version); - if (FAILED(hr)) + if (FAILED(hr = vertexshader_init(object, device, desc, parent, parent_ops))) { WARN("Failed to initialize vertex shader, hr %#x.\n", hr); HeapFree(GetProcessHeap(), 0, object); diff -Nru wine1.7-1.7.28/dlls/wined3d/shader_sm4.c wine1.7-1.7.31/dlls/wined3d/shader_sm4.c --- wine1.7-1.7.28/dlls/wined3d/shader_sm4.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/shader_sm4.c 2014-11-14 13:28:17.000000000 +0000 @@ -176,7 +176,12 @@ { struct wined3d_shader_version shader_version; const DWORD *end; - const struct wined3d_shader_signature *output_signature; + + struct + { + enum wined3d_shader_register_type register_type; + UINT register_idx; + } output_map[MAX_REG_OUTPUT]; struct wined3d_shader_src_param src_param[5]; struct wined3d_shader_dst_param dst_param[2]; @@ -331,20 +336,6 @@ return NULL; } -static void map_sysval(enum wined3d_sysval_semantic sysval, struct wined3d_shader_register *reg) -{ - unsigned int i; - - for (i = 0; i < sizeof(sysval_map) / sizeof(*sysval_map); ++i) - { - if (sysval == sysval_map[i].sysval) - { - reg->type = sysval_map[i].register_type; - reg->idx[0].offset = sysval_map[i].register_idx; - } - } -} - static void map_register(const struct wined3d_sm4_data *priv, struct wined3d_shader_register *reg) { switch (priv->shader_version.type) @@ -352,23 +343,16 @@ case WINED3D_SHADER_TYPE_PIXEL: if (reg->type == WINED3DSPR_OUTPUT) { - unsigned int i; - const struct wined3d_shader_signature *s = priv->output_signature; + unsigned int reg_idx = reg->idx[0].offset; - if (!s) + if (reg_idx >= ARRAY_SIZE(priv->output_map)) { - ERR("Shader has no output signature, unable to map register.\n"); + ERR("Invalid output index %u.\n", reg_idx); break; } - for (i = 0; i < s->element_count; ++i) - { - if (s->elements[i].register_idx == reg->idx[0].offset) - { - map_sysval(s->elements[i].sysval_semantic, reg); - break; - } - } + reg->type = priv->output_map[reg_idx].register_type; + reg->idx[0].offset = priv->output_map[reg_idx].register_idx; } break; @@ -399,14 +383,37 @@ static void *shader_sm4_init(const DWORD *byte_code, const struct wined3d_shader_signature *output_signature) { - struct wined3d_sm4_data *priv = HeapAlloc(GetProcessHeap(), 0, sizeof(*priv)); - if (!priv) + struct wined3d_sm4_data *priv; + unsigned int i, j; + + if (!(priv = HeapAlloc(GetProcessHeap(), 0, sizeof(*priv)))) { ERR("Failed to allocate private data\n"); return NULL; } - priv->output_signature = output_signature; + memset(priv->output_map, 0xff, sizeof(priv->output_map)); + for (i = 0; i < output_signature->element_count; ++i) + { + struct wined3d_shader_signature_element *e = &output_signature->elements[i]; + + if (e->register_idx >= ARRAY_SIZE(priv->output_map)) + { + WARN("Invalid output index %u.\n", e->register_idx); + continue; + } + + for (j = 0; j < ARRAY_SIZE(sysval_map); ++j) + { + if (e->sysval_semantic == sysval_map[j].sysval) + { + priv->output_map[e->register_idx].register_type = sysval_map[j].register_type; + priv->output_map[e->register_idx].register_idx = sysval_map[j].register_idx; + break; + } + } + } + list_init(&priv->src_free); list_init(&priv->src); diff -Nru wine1.7-1.7.28/dlls/wined3d/surface.c wine1.7-1.7.31/dlls/wined3d/surface.c --- wine1.7-1.7.28/dlls/wined3d/surface.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/surface.c 2014-11-14 13:28:17.000000000 +0000 @@ -588,22 +588,18 @@ static void surface_evict_sysmem(struct wined3d_surface *surface) { /* In some conditions the surface memory must not be freed: - * SFLAG_CONVERTED: Converting the data back would take too long - * SFLAG_DYNLOCK: Avoid freeing the data for performance + * WINED3D_TEXTURE_CONVERTED: Converting the data back would take too long + * WINED3D_TEXTURE_DYNAMIC_MAP: Avoid freeing the data for performance * SFLAG_CLIENT: OpenGL uses our memory as backup */ - if (surface->resource.map_count || surface->flags & (SFLAG_CONVERTED | SFLAG_DYNLOCK - | SFLAG_CLIENT | SFLAG_PIN_SYSMEM)) + if (surface->resource.map_count || surface->flags & SFLAG_CLIENT + || surface->container->flags & (WINED3D_TEXTURE_CONVERTED | WINED3D_TEXTURE_PIN_SYSMEM + | WINED3D_TEXTURE_DYNAMIC_MAP)) return; wined3d_resource_free_sysmem(&surface->resource); surface_invalidate_location(surface, WINED3D_LOCATION_SYSMEM); } -static void surface_force_reload(struct wined3d_surface *surface) -{ - surface->flags &= ~(SFLAG_ALLOCATED | SFLAG_SRGBALLOCATED); -} - static void surface_release_client_storage(struct wined3d_surface *surface) { struct wined3d_context *context = context_acquire(surface->resource.device, NULL); @@ -621,22 +617,22 @@ gl_info->gl_ops.gl.p_glTexImage2D(surface->texture_target, surface->texture_level, GL_RGB, 1, 1, 0, GL_RGB, GL_UNSIGNED_BYTE, NULL); } + wined3d_texture_force_reload(surface->container); context_release(context); - - surface_invalidate_location(surface, WINED3D_LOCATION_TEXTURE_RGB | WINED3D_LOCATION_TEXTURE_SRGB); - surface_force_reload(surface); } static BOOL surface_use_pbo(const struct wined3d_surface *surface) { const struct wined3d_gl_info *gl_info = &surface->resource.device->adapter->gl_info; + struct wined3d_texture *texture = surface->container; - return surface->resource.pool == WINED3D_POOL_DEFAULT + return texture->resource.pool == WINED3D_POOL_DEFAULT && surface->resource.access_flags & WINED3D_RESOURCE_ACCESS_CPU && gl_info->supported[ARB_PIXEL_BUFFER_OBJECT] - && !surface->resource.format->convert - && !(surface->flags & (SFLAG_NONPOW2 | SFLAG_PIN_SYSMEM)); + && !texture->resource.format->convert + && !(texture->flags & WINED3D_TEXTURE_PIN_SYSMEM) + && !(surface->flags & SFLAG_NONPOW2); } static HRESULT surface_private_setup(struct wined3d_surface *surface) @@ -1211,7 +1207,6 @@ surface_load_location(surface, surface->resource.map_binding); surface_invalidate_location(surface, ~surface->resource.map_binding); } - surface->flags &= ~(SFLAG_ALLOCATED | SFLAG_SRGBALLOCATED); context = context_acquire(device, NULL); gl_info = context->gl_info; @@ -1330,7 +1325,7 @@ struct wined3d_bo_address data; /* Only support read back of converted P8 surfaces. */ - if (surface->flags & SFLAG_CONVERTED && format->id != WINED3DFMT_P8_UINT) + if (surface->container->flags & WINED3D_TEXTURE_CONVERTED && format->id != WINED3DFMT_P8_UINT) { ERR("Trying to read back converted surface %p with format %s.\n", surface, debug_d3dformat(format->id)); return; @@ -1454,8 +1449,8 @@ * get a boxed texture with width pow2width and not a texture of width resource.width. * * Performance should not be an issue, because applications normally do not lock the surfaces when - * rendering. If an app does, the SFLAG_DYNLOCK flag will kick in and the memory copy won't be released, - * and doesn't have to be re-read. */ + * rendering. If an app does, the WINED3D_TEXTURE_DYNAMIC_MAP flag will kick in and the memory copy + * won't be released, and doesn't have to be re-read. */ src_data = mem; dst_data = data.addr; TRACE("(%p) : Repacking the surface data from pitch %d to pitch %d\n", surface, src_pitch, dst_pitch); @@ -1487,8 +1482,8 @@ if (surface->resource.map_count) { - WARN("Uploading a surface that is currently mapped, setting SFLAG_PIN_SYSMEM.\n"); - surface->flags |= SFLAG_PIN_SYSMEM; + WARN("Uploading a surface that is currently mapped, setting WINED3D_TEXTURE_PIN_SYSMEM.\n"); + surface->container->flags |= WINED3D_TEXTURE_PIN_SYSMEM; } if (format->flags & WINED3DFMT_FLAG_HEIGHT_SCALE) @@ -1585,78 +1580,6 @@ } } -static void d3dfmt_get_conv(const struct wined3d_texture *texture, BOOL need_alpha_ck, - struct wined3d_format *format, enum wined3d_conversion_type *conversion_type) -{ - BOOL colorkey_active = need_alpha_ck && (texture->color_key_flags & WINEDDSD_CKSRCBLT); - const struct wined3d_device *device = texture->resource.device; - const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; - const struct wined3d_format *dst_format; - enum wined3d_format_id dst_format_id; - unsigned int i; - - static const struct - { - enum wined3d_format_id src_format; - enum wined3d_conversion_type conversion_type; - enum wined3d_format_id dst_format; - } - color_key_info[] = - { - {WINED3DFMT_B5G6R5_UNORM, WINED3D_CT_CK_B5G6R5, WINED3DFMT_B5G5R5A1_UNORM}, - {WINED3DFMT_B5G5R5X1_UNORM, WINED3D_CT_CK_B5G5R5X1, WINED3DFMT_B5G5R5A1_UNORM}, - {WINED3DFMT_B8G8R8_UNORM, WINED3D_CT_CK_B8G8R8, WINED3DFMT_B8G8R8A8_UNORM}, - {WINED3DFMT_B8G8R8X8_UNORM, WINED3D_CT_CK_B8G8R8X8, WINED3DFMT_B8G8R8A8_UNORM}, - {WINED3DFMT_B8G8R8A8_UNORM, WINED3D_CT_CK_B8G8R8A8, WINED3DFMT_B8G8R8A8_UNORM}, - }; - - *format = *texture->resource.format; - *conversion_type = WINED3D_CT_NONE; - dst_format_id = format->id; - - if (colorkey_active) - { - for (i = 0; i < sizeof(color_key_info) / sizeof(*color_key_info); ++i) - { - if (color_key_info[i].src_format != texture->resource.format->id) - continue; - - *conversion_type = color_key_info[i].conversion_type; - dst_format_id = color_key_info[i].dst_format; - break; - } - } - - if (texture->resource.format->id == WINED3DFMT_P8_UINT) - { - /* FIXME: This should check if the blitter backend can do P8 - * conversion, instead of checking for ARB_fragment_program. */ - if (!((gl_info->supported[ARB_FRAGMENT_PROGRAM] && texture->swapchain - && texture == texture->swapchain->front_buffer)) || colorkey_active) - { - *conversion_type = WINED3D_CT_P8; - dst_format_id = WINED3DFMT_B8G8R8A8_UNORM; - } - } - else if (texture->resource.format->id == WINED3DFMT_B2G3R3_UNORM && colorkey_active) - { - /* This texture format will never be used... So do not care about - * color-keying up until the point in time it will be needed. */ - FIXME("Color-keying not supported with WINED3DFMT_B2G3R3_UNORM.\n"); - } - - if (*conversion_type != WINED3D_CT_NONE) - { - dst_format = wined3d_get_format(gl_info, dst_format_id); - format->glInternal = dst_format->glInternal; - format->glGammaInternal = format->glInternal; - format->rtInternal = format->glInternal; - format->glFormat = dst_format->glFormat; - format->glType = dst_format->glType; - format->conv_byte_count = dst_format->byte_count; - } -} - static BOOL surface_check_block_align(struct wined3d_surface *surface, const RECT *rect) { UINT width_mask, height_mask; @@ -1684,10 +1607,8 @@ const struct wined3d_format *src_format; const struct wined3d_format *dst_format; const struct wined3d_gl_info *gl_info; - enum wined3d_conversion_type convert; struct wined3d_context *context; struct wined3d_bo_address data; - struct wined3d_format format; UINT update_w, update_h; UINT dst_w, dst_h; RECT r, dst_rect; @@ -1761,8 +1682,7 @@ } /* Use wined3d_surface_blt() instead of uploading directly if we need conversion. */ - d3dfmt_get_conv(dst_surface->container, FALSE, &format, &convert); - if (convert != WINED3D_CT_NONE || format.convert) + if (dst_format->convert || wined3d_format_get_color_key_conversion(dst_surface->container, FALSE)) return wined3d_surface_blt(dst_surface, &dst_rect, src_surface, src_rect, 0, NULL, WINED3D_TEXF_POINT); context = context_acquire(dst_surface->resource.device, NULL); @@ -1772,7 +1692,7 @@ * the texture wouldn't be the current location, and we'd upload zeroes * just to overwrite them again. */ if (update_w == dst_w && update_h == dst_h) - surface_prepare_texture(dst_surface, context, FALSE); + wined3d_texture_prepare_texture(dst_surface->container, context, FALSE); else surface_load_location(dst_surface, WINED3D_LOCATION_TEXTURE_RGB); wined3d_texture_bind(dst_surface->container, context, FALSE); @@ -1792,83 +1712,6 @@ return WINED3D_OK; } -/* This call just allocates the texture, the caller is responsible for binding - * the correct texture. */ -/* Context activation is done by the caller. */ -static void surface_allocate_surface(struct wined3d_surface *surface, const struct wined3d_gl_info *gl_info, - const struct wined3d_format *format, BOOL srgb) -{ - BOOL disable_client_storage = FALSE; - GLsizei width = surface->pow2Width; - GLsizei height = surface->pow2Height; - const BYTE *mem = NULL; - GLenum internal; - - if (srgb) - internal = format->glGammaInternal; - else if (surface->resource.usage & WINED3DUSAGE_RENDERTARGET - && wined3d_resource_is_offscreen(&surface->container->resource)) - internal = format->rtInternal; - else - internal = format->glInternal; - - if (!internal) - FIXME("No GL internal format for format %s.\n", debug_d3dformat(format->id)); - - if (format->flags & WINED3DFMT_FLAG_HEIGHT_SCALE) - { - height *= format->height_scale.numerator; - height /= format->height_scale.denominator; - } - - TRACE("(%p) : Creating surface (target %#x) level %d, d3d format %s, internal format %#x, width %d, height %d, gl format %#x, gl type=%#x\n", - surface, surface->texture_target, surface->texture_level, debug_d3dformat(format->id), - internal, width, height, format->glFormat, format->glType); - - if (gl_info->supported[APPLE_CLIENT_STORAGE]) - { - if (surface->flags & (SFLAG_NONPOW2 | SFLAG_DIBSECTION | SFLAG_CONVERTED) - || !surface->resource.heap_memory) - { - /* In some cases we want to disable client storage. - * SFLAG_NONPOW2 has a bigger opengl texture than the client memory, and different pitches - * SFLAG_DIBSECTION: Dibsections may have read / write protections on the memory. Avoid issues... - * SFLAG_CONVERTED: The conversion destination memory is freed after loading the surface - * heap_memory == NULL: Not defined in the extension. Seems to disable client storage effectively - */ - surface->flags &= ~SFLAG_CLIENT; - } - else - { - surface->flags |= SFLAG_CLIENT; - mem = surface->resource.heap_memory; - - gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE); - checkGLcall("glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE)"); - disable_client_storage = TRUE; - } - } - - if (format->flags & WINED3DFMT_FLAG_COMPRESSED && mem) - { - GL_EXTCALL(glCompressedTexImage2DARB(surface->texture_target, surface->texture_level, - internal, width, height, 0, surface->resource.size, mem)); - checkGLcall("glCompressedTexImage2DARB"); - } - else - { - gl_info->gl_ops.gl.p_glTexImage2D(surface->texture_target, surface->texture_level, - internal, width, height, 0, format->glFormat, format->glType, mem); - checkGLcall("glTexImage2D"); - } - - if (disable_client_storage) - { - gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_FALSE); - checkGLcall("glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_FALSE)"); - } -} - /* In D3D the depth stencil dimensions have to be greater than or equal to the * render target dimensions. With FBOs, the dimensions have to be an exact match. */ /* TODO: We should synchronize the renderbuffer's content with the texture's content. */ @@ -1997,7 +1840,7 @@ surface_invalidate_location(surface, ~surface->resource.map_binding); /* Switching color keying on / off may change the internal format. */ if (ck_changed) - surface_force_reload(surface); + wined3d_texture_force_reload(surface->container); } else if (!(surface->locations & location)) { @@ -2773,13 +2616,15 @@ /* Performance optimization: Count how often a surface is mapped, if it is * mapped regularly do not throw away the system memory copy. This avoids * the need to download the surface from OpenGL all the time. The surface - * is still downloaded if the OpenGL texture is changed. */ - if (!(surface->flags & SFLAG_DYNLOCK) && surface->resource.map_binding == WINED3D_LOCATION_SYSMEM) + * is still downloaded if the OpenGL texture is changed. Note that this + * only really makes sense for managed textures.*/ + if (!(surface->container->flags & WINED3D_TEXTURE_DYNAMIC_MAP) + && surface->resource.map_binding == WINED3D_LOCATION_SYSMEM) { if (++surface->lockCount > MAXLOCKCOUNT) { TRACE("Surface is mapped regularly, not freeing the system memory copy any more.\n"); - surface->flags |= SFLAG_DYNLOCK; + surface->container->flags |= WINED3D_TEXTURE_DYNAMIC_MAP; } } @@ -2900,7 +2745,7 @@ if (FAILED(hr)) return WINED3DERR_INVALIDCALL; if (!(surface->resource.map_binding == WINED3D_LOCATION_USER_MEMORY - || surface->flags & SFLAG_PIN_SYSMEM + || surface->container->flags & WINED3D_TEXTURE_PIN_SYSMEM || surface->pbo)) surface->resource.map_binding = WINED3D_LOCATION_DIB; } @@ -2934,7 +2779,8 @@ surface->resource.map_count--; surface->flags &= ~SFLAG_DCINUSE; - if (surface->resource.map_binding == WINED3D_LOCATION_USER_MEMORY || (surface->flags & SFLAG_PIN_SYSMEM + if (surface->resource.map_binding == WINED3D_LOCATION_USER_MEMORY + || (surface->container->flags & WINED3D_TEXTURE_PIN_SYSMEM && surface->resource.map_binding != WINED3D_LOCATION_DIB)) { /* The game Salammbo modifies the surface contents without mapping the surface between @@ -3066,7 +2912,7 @@ gl_info = context->gl_info; device_invalidate_state(device, STATE_FRAMEBUFFER); - surface_prepare_texture(surface, context, srgb); + wined3d_texture_prepare_texture(surface->container, context, srgb); wined3d_texture_bind_and_dirtify(surface->container, context, srgb); TRACE("Reading back offscreen render target %p.\n", surface); @@ -3084,44 +2930,6 @@ context_release(context); } -/* Context activation is done by the caller. */ -static void surface_prepare_texture_internal(struct wined3d_surface *surface, - struct wined3d_context *context, BOOL srgb) -{ - DWORD alloc_flag = srgb ? SFLAG_SRGBALLOCATED : SFLAG_ALLOCATED; - enum wined3d_conversion_type convert; - struct wined3d_format format; - - if (surface->flags & alloc_flag) return; - - d3dfmt_get_conv(surface->container, TRUE, &format, &convert); - if (convert != WINED3D_CT_NONE || format.convert) - surface->flags |= SFLAG_CONVERTED; - else surface->flags &= ~SFLAG_CONVERTED; - - wined3d_texture_bind_and_dirtify(surface->container, context, srgb); - surface_allocate_surface(surface, context->gl_info, &format, srgb); - surface->flags |= alloc_flag; -} - -/* Context activation is done by the caller. */ -void surface_prepare_texture(struct wined3d_surface *surface, struct wined3d_context *context, BOOL srgb) -{ - struct wined3d_texture *texture = surface->container; - UINT sub_count = texture->level_count * texture->layer_count; - UINT i; - - TRACE("surface %p is a subresource of texture %p.\n", surface, texture); - - for (i = 0; i < sub_count; ++i) - { - struct wined3d_surface *s = surface_from_resource(texture->sub_resources[i]); - surface_prepare_texture_internal(s, context, srgb); - } - - return; -} - void surface_prepare_rb(struct wined3d_surface *surface, const struct wined3d_gl_info *gl_info, BOOL multisample) { if (multisample) @@ -3148,212 +2956,6 @@ } } -static BOOL color_in_range(const struct wined3d_color_key *color_key, DWORD color) -{ - /* FIXME: Is this really how color keys are supposed to work? I think it - * makes more sense to compare the individual channels. */ - return color >= color_key->color_space_low_value - && color <= color_key->color_space_high_value; -} - -static void convert_p8_uint_b8g8r8a8_unorm(const BYTE *src, unsigned int src_pitch, - BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, - const struct wined3d_palette *palette, const struct wined3d_color_key *color_key) -{ - const BYTE *src_row; - unsigned int x, y; - DWORD *dst_row; - - if (!palette) - { - /* FIXME: This should probably use the system palette. */ - FIXME("P8 surface loaded without a palette.\n"); - - for (y = 0; y < height; ++y) - { - memset(&dst[dst_pitch * y], 0, width * 4); - } - - return; - } - - for (y = 0; y < height; ++y) - { - src_row = &src[src_pitch * y]; - dst_row = (DWORD *)&dst[dst_pitch * y]; - for (x = 0; x < width; ++x) - { - BYTE src_color = src_row[x]; - dst_row[x] = 0xff000000 - | (palette->colors[src_color].rgbRed << 16) - | (palette->colors[src_color].rgbGreen << 8) - | palette->colors[src_color].rgbBlue; - } - } -} - -static void convert_b5g6r5_unorm_b5g5r5a1_unorm_color_key(const BYTE *src, unsigned int src_pitch, - BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, - const struct wined3d_color_key *color_key) -{ - const WORD *src_row; - unsigned int x, y; - WORD *dst_row; - - for (y = 0; y < height; ++y) - { - src_row = (WORD *)&src[src_pitch * y]; - dst_row = (WORD *)&dst[dst_pitch * y]; - for (x = 0; x < width; ++x) - { - WORD src_color = src_row[x]; - if (!color_in_range(color_key, src_color)) - dst_row[x] = 0x8000 | ((src_color & 0xffc0) >> 1) | (src_color & 0x1f); - else - dst_row[x] = ((src_color & 0xffc0) >> 1) | (src_color & 0x1f); - } - } -} - -static void convert_b5g5r5x1_unorm_b5g5r5a1_unorm_color_key(const BYTE *src, unsigned int src_pitch, - BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, - const struct wined3d_color_key *color_key) -{ - const WORD *src_row; - unsigned int x, y; - WORD *dst_row; - - for (y = 0; y < height; ++y) - { - src_row = (WORD *)&src[src_pitch * y]; - dst_row = (WORD *)&dst[dst_pitch * y]; - for (x = 0; x < width; ++x) - { - WORD src_color = src_row[x]; - if (color_in_range(color_key, src_color)) - dst_row[x] = src_color & ~0x8000; - else - dst_row[x] = src_color | 0x8000; - } - } -} - -static void convert_b8g8r8_unorm_b8g8r8a8_unorm_color_key(const BYTE *src, unsigned int src_pitch, - BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, - const struct wined3d_color_key *color_key) -{ - const BYTE *src_row; - unsigned int x, y; - DWORD *dst_row; - - for (y = 0; y < height; ++y) - { - src_row = &src[src_pitch * y]; - dst_row = (DWORD *)&dst[dst_pitch * y]; - for (x = 0; x < width; ++x) - { - DWORD src_color = (src_row[x * 3 + 2] << 16) | (src_row[x * 3 + 1] << 8) | src_row[x * 3]; - if (!color_in_range(color_key, src_color)) - dst_row[x] = src_color | 0xff000000; - } - } -} - -static void convert_b8g8r8x8_unorm_b8g8r8a8_unorm_color_key(const BYTE *src, unsigned int src_pitch, - BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, - const struct wined3d_color_key *color_key) -{ - const DWORD *src_row; - unsigned int x, y; - DWORD *dst_row; - - for (y = 0; y < height; ++y) - { - src_row = (DWORD *)&src[src_pitch * y]; - dst_row = (DWORD *)&dst[dst_pitch * y]; - for (x = 0; x < width; ++x) - { - DWORD src_color = src_row[x]; - if (color_in_range(color_key, src_color)) - dst_row[x] = src_color & ~0xff000000; - else - dst_row[x] = src_color | 0xff000000; - } - } -} - -static void convert_b8g8r8a8_unorm_b8g8r8a8_unorm_color_key(const BYTE *src, unsigned int src_pitch, - BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, - const struct wined3d_color_key *color_key) -{ - const DWORD *src_row; - unsigned int x, y; - DWORD *dst_row; - - for (y = 0; y < height; ++y) - { - src_row = (DWORD *)&src[src_pitch * y]; - dst_row = (DWORD *)&dst[dst_pitch * y]; - for (x = 0; x < width; ++x) - { - DWORD src_color = src_row[x]; - if (color_in_range(color_key, src_color)) - src_color &= ~0xff000000; - dst_row[x] = src_color; - } - } -} - -static HRESULT d3dfmt_convert_surface(const BYTE *src, BYTE *dst, UINT pitch, UINT width, UINT height, - UINT outpitch, enum wined3d_conversion_type conversion_type, struct wined3d_surface *surface) -{ - struct wined3d_palette *palette = NULL; - struct wined3d_texture *texture; - - TRACE("src %p, dst %p, pitch %u, width %u, height %u, outpitch %u, conversion_type %#x, surface %p.\n", - src, dst, pitch, width, height, outpitch, conversion_type, surface); - - texture = surface->container; - switch (conversion_type) - { - case WINED3D_CT_P8: - if (texture->swapchain && texture->swapchain->palette) - palette = texture->swapchain->palette; - convert_p8_uint_b8g8r8a8_unorm(src, pitch, dst, outpitch, - width, height, palette, &texture->src_blt_color_key); - break; - - case WINED3D_CT_CK_B5G6R5: - convert_b5g6r5_unorm_b5g5r5a1_unorm_color_key(src, pitch, dst, outpitch, - width, height, &texture->src_blt_color_key); - break; - - case WINED3D_CT_CK_B5G5R5X1: - convert_b5g5r5x1_unorm_b5g5r5a1_unorm_color_key(src, pitch, dst, outpitch, - width, height, &texture->src_blt_color_key); - break; - - case WINED3D_CT_CK_B8G8R8: - convert_b8g8r8_unorm_b8g8r8a8_unorm_color_key(src, pitch, dst, outpitch, - width, height, &texture->src_blt_color_key); - break; - - case WINED3D_CT_CK_B8G8R8X8: - convert_b8g8r8x8_unorm_b8g8r8a8_unorm_color_key(src, pitch, dst, outpitch, - width, height, &texture->src_blt_color_key); - break; - - case WINED3D_CT_CK_B8G8R8A8: - convert_b8g8r8a8_unorm_b8g8r8a8_unorm_color_key(src, pitch, dst, outpitch, - width, height, &texture->src_blt_color_key); - break; - - default: - ERR("Unsupported conversion type %#x.\n", conversion_type); - } - return WINED3D_OK; -} - void flip_surface(struct wined3d_surface *front, struct wined3d_surface *back) { if (front->container->level_count != 1 || front->container->layer_count != 1 @@ -3696,7 +3298,7 @@ bottom = src_surface->resource.height - src_rect->top; } - if (src_surface->flags & SFLAG_NORMCOORD) + if (src_surface->container->flags & WINED3D_TEXTURE_NORMALIZED_COORDS) { left /= src_surface->pow2Width; right /= src_surface->pow2Width; @@ -4229,7 +3831,7 @@ switch (location) { case WINED3D_LOCATION_TEXTURE_RGB: - surface_prepare_texture(surface, context, FALSE); + wined3d_texture_prepare_texture(surface->container, context, FALSE); break; case WINED3D_LOCATION_RB_MULTISAMPLE: surface_prepare_rb(surface, gl_info, TRUE); @@ -4487,7 +4089,8 @@ { RECT src_rect = {0, 0, surface->resource.width, surface->resource.height}; struct wined3d_device *device = surface->resource.device; - enum wined3d_conversion_type convert; + const struct wined3d_color_key_conversion *conversion; + struct wined3d_texture *texture = surface->container; struct wined3d_context *context; UINT width, src_pitch, dst_pitch; struct wined3d_bo_address data; @@ -4496,7 +4099,7 @@ BYTE *mem = NULL; if (wined3d_settings.offscreen_rendering_mode != ORM_FBO - && wined3d_resource_is_offscreen(&surface->container->resource) + && wined3d_resource_is_offscreen(&texture->resource) && (surface->locations & WINED3D_LOCATION_DRAWABLE)) { surface_load_fb_texture(surface, srgb); @@ -4539,8 +4142,6 @@ /* Upload from system memory */ - d3dfmt_get_conv(surface->container, TRUE /* We need color keying */, &format, &convert); - if (srgb) { if ((surface->locations & (WINED3D_LOCATION_TEXTURE_RGB | surface->resource.map_binding)) @@ -4575,23 +4176,27 @@ /* TODO: Use already acquired context when possible. */ context = context_acquire(device, NULL); - surface_prepare_texture(surface, context, srgb); - wined3d_texture_bind_and_dirtify(surface->container, context, srgb); + wined3d_texture_prepare_texture(texture, context, srgb); + wined3d_texture_bind_and_dirtify(texture, context, srgb); - if (surface->container->color_key_flags & WINEDDSD_CKSRCBLT) + if (texture->color_key_flags & WINEDDSD_CKSRCBLT) { surface->flags |= SFLAG_GLCKEY; - surface->gl_color_key = surface->container->src_blt_color_key; + surface->gl_color_key = texture->src_blt_color_key; } else surface->flags &= ~SFLAG_GLCKEY; width = surface->resource.width; src_pitch = wined3d_surface_get_pitch(surface); + format = *texture->resource.format; + if ((conversion = wined3d_format_get_color_key_conversion(texture, TRUE))) + format = *wined3d_get_format(gl_info, conversion->dst_format); + /* Don't use PBOs for converted surfaces. During PBO conversion we look at - * SFLAG_CONVERTED but it isn't set (yet) in all cases it is getting - * called. */ - if ((convert != WINED3D_CT_NONE || format.convert) && surface->pbo) + * WINED3D_TEXTURE_CONVERTED but it isn't set (yet) in all cases it is + * getting called. */ + if ((format.convert || conversion) && surface->pbo) { TRACE("Removing the pbo attached to surface %p.\n", surface); @@ -4611,8 +4216,8 @@ /* This code is entered for texture formats which need a fixup. */ UINT height = surface->resource.height; - /* Stick to the alignment for the converted surface too, makes it easier to load the surface */ - dst_pitch = width * format.conv_byte_count; + format.byte_count = format.conv_byte_count; + dst_pitch = wined3d_format_calculate_pitch(&format, width); dst_pitch = (dst_pitch + device->surface_alignment - 1) & ~(device->surface_alignment - 1); if (!(mem = HeapAlloc(GetProcessHeap(), 0, dst_pitch * height))) @@ -4623,17 +4228,16 @@ } format.convert(data.addr, mem, src_pitch, src_pitch * height, dst_pitch, dst_pitch * height, width, height, 1); - format.byte_count = format.conv_byte_count; src_pitch = dst_pitch; data.addr = mem; } - else if (convert != WINED3D_CT_NONE) + else if (conversion) { /* This code is only entered for color keying fixups */ + struct wined3d_palette *palette = NULL; UINT height = surface->resource.height; - /* Stick to the alignment for the converted surface too, makes it easier to load the surface */ - dst_pitch = width * format.conv_byte_count; + dst_pitch = wined3d_format_calculate_pitch(&format, width); dst_pitch = (dst_pitch + device->surface_alignment - 1) & ~(device->surface_alignment - 1); if (!(mem = HeapAlloc(GetProcessHeap(), 0, dst_pitch * height))) @@ -4642,9 +4246,10 @@ context_release(context); return E_OUTOFMEMORY; } - d3dfmt_convert_surface(data.addr, mem, src_pitch, - width, height, dst_pitch, convert, surface); - format.byte_count = format.conv_byte_count; + if (texture->swapchain && texture->swapchain->palette) + palette = texture->swapchain->palette; + conversion->convert(data.addr, src_pitch, mem, dst_pitch, + width, height, palette, &texture->src_blt_color_key); src_pitch = dst_pitch; data.addr = mem; } @@ -5571,8 +5176,6 @@ DWORD src_ds_flags, dst_ds_flags; RECT src_rect, dst_rect; BOOL scale, convert; - enum wined3d_conversion_type dst_convert_type; - struct wined3d_format dst_conv_fmt; static const DWORD simple_blit = WINEDDBLT_ASYNC | WINEDDBLT_COLORFILL @@ -5687,8 +5290,9 @@ /* We want to avoid invalidating the sysmem location for converted * surfaces, since otherwise we'd have to convert the data back when * locking them. */ - d3dfmt_get_conv(dst_surface->container, TRUE, &dst_conv_fmt, &dst_convert_type); - if (dst_convert_type != WINED3D_CT_NONE || dst_conv_fmt.convert || dst_surface->flags & SFLAG_CONVERTED) + if (dst_surface->container->flags & WINED3D_TEXTURE_CONVERTED + || dst_surface->container->resource.format->convert + || wined3d_format_get_color_key_conversion(dst_surface->container, TRUE)) { WARN_(d3d_perf)("Converted surface, using CPU blit.\n"); goto cpu; @@ -5942,12 +5546,8 @@ list_init(&surface->overlays); /* Flags */ - if (target != GL_TEXTURE_RECTANGLE_ARB) - surface->flags |= SFLAG_NORMCOORD; if (flags & WINED3D_SURFACE_DISCARD) surface->flags |= SFLAG_DISCARD; - if (flags & WINED3D_SURFACE_PIN_SYSMEM) - surface->flags |= SFLAG_PIN_SYSMEM; if (lockable || desc->format == WINED3DFMT_D16_LOCKABLE) surface->resource.access_flags |= WINED3D_RESOURCE_ACCESS_CPU; diff -Nru wine1.7-1.7.28/dlls/wined3d/swapchain.c wine1.7-1.7.31/dlls/wined3d/swapchain.c --- wine1.7-1.7.28/dlls/wined3d/swapchain.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/swapchain.c 2014-11-14 13:28:17.000000000 +0000 @@ -349,7 +349,7 @@ context2 = context_acquire(device, backbuffer); context_apply_blit_state(context2, device); - if (backbuffer->flags & SFLAG_NORMCOORD) + if (backbuffer->container->flags & WINED3D_TEXTURE_NORMALIZED_COORDS) { tex_left /= src_w; tex_right /= src_w; diff -Nru wine1.7-1.7.28/dlls/wined3d/texture.c wine1.7-1.7.31/dlls/wined3d/texture.c --- wine1.7-1.7.28/dlls/wined3d/texture.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/texture.c 2014-11-14 13:28:17.000000000 +0000 @@ -28,19 +28,20 @@ WINE_DECLARE_DEBUG_CHANNEL(winediag); static HRESULT wined3d_texture_init(struct wined3d_texture *texture, const struct wined3d_texture_ops *texture_ops, - UINT layer_count, UINT level_count, const struct wined3d_resource_desc *desc, struct wined3d_device *device, - void *parent, const struct wined3d_parent_ops *parent_ops, const struct wined3d_resource_ops *resource_ops) + UINT layer_count, UINT level_count, const struct wined3d_resource_desc *desc, DWORD surface_flags, + struct wined3d_device *device, void *parent, const struct wined3d_parent_ops *parent_ops, + const struct wined3d_resource_ops *resource_ops) { const struct wined3d_format *format = wined3d_get_format(&device->adapter->gl_info, desc->format); HRESULT hr; TRACE("texture %p, texture_ops %p, layer_count %u, level_count %u, resource_type %s, format %s, " "multisample_type %#x, multisample_quality %#x, usage %s, pool %s, width %u, height %u, depth %u, " - "device %p, parent %p, parent_ops %p, resource_ops %p.\n", + "surface_flags %#x, device %p, parent %p, parent_ops %p, resource_ops %p.\n", texture, texture_ops, layer_count, level_count, debug_d3dresourcetype(desc->resource_type), debug_d3dformat(desc->format), desc->multisample_type, desc->multisample_quality, debug_d3dusage(desc->usage), debug_d3dpool(desc->pool), desc->width, desc->height, desc->depth, - device, parent, parent_ops, resource_ops); + surface_flags, device, parent, parent_ops, resource_ops); if ((format->flags & (WINED3DFMT_FLAG_BLOCKS | WINED3DFMT_FLAG_BLOCKS_NO_VERIFY)) == WINED3DFMT_FLAG_BLOCKS) { @@ -80,7 +81,9 @@ texture->level_count = level_count; texture->filter_type = (desc->usage & WINED3DUSAGE_AUTOGENMIPMAP) ? WINED3D_TEXF_LINEAR : WINED3D_TEXF_NONE; texture->lod = 0; - texture->flags = WINED3D_TEXTURE_POW2_MAT_IDENT; + texture->flags = WINED3D_TEXTURE_POW2_MAT_IDENT | WINED3D_TEXTURE_NORMALIZED_COORDS; + if (surface_flags & WINED3D_SURFACE_PIN_SYSMEM) + texture->flags |= WINED3D_TEXTURE_PIN_SYSMEM; if (texture->resource.format->flags & WINED3DFMT_FLAG_FILTERING) { @@ -749,6 +752,30 @@ return wined3d_surface_update_desc(surface, gl_info, mem, pitch); } +void wined3d_texture_prepare_texture(struct wined3d_texture *texture, struct wined3d_context *context, BOOL srgb) +{ + DWORD alloc_flag = srgb ? WINED3D_TEXTURE_SRGB_ALLOCATED : WINED3D_TEXTURE_RGB_ALLOCATED; + + if (texture->flags & alloc_flag) + return; + + texture->texture_ops->texture_prepare_texture(texture, context, srgb); + texture->flags |= alloc_flag; +} + +void wined3d_texture_force_reload(struct wined3d_texture *texture) +{ + unsigned int sub_count = texture->level_count * texture->layer_count; + unsigned int i; + + texture->flags &= ~(WINED3D_TEXTURE_RGB_ALLOCATED | WINED3D_TEXTURE_SRGB_ALLOCATED | WINED3D_TEXTURE_CONVERTED); + for (i = 0; i < sub_count; ++i) + { + texture->texture_ops->texture_sub_resource_invalidate_location(texture->sub_resources[i], + WINED3D_LOCATION_TEXTURE_RGB | WINED3D_LOCATION_TEXTURE_SRGB); + } +} + void CDECL wined3d_texture_generate_mipmaps(struct wined3d_texture *texture) { /* TODO: Implement filters using GL_SGI_generate_mipmaps. */ @@ -812,11 +839,119 @@ wined3d_surface_destroy(surface); } +static void texture2d_sub_resource_invalidate_location(struct wined3d_resource *sub_resource, DWORD location) +{ + struct wined3d_surface *surface = surface_from_resource(sub_resource); + + surface_invalidate_location(surface, location); +} + +/* Context activation is done by the caller. */ +static void texture2d_prepare_texture(struct wined3d_texture *texture, struct wined3d_context *context, BOOL srgb) +{ + UINT sub_count = texture->level_count * texture->layer_count; + const struct wined3d_format *format = texture->resource.format; + const struct wined3d_gl_info *gl_info = context->gl_info; + const struct wined3d_color_key_conversion *conversion; + GLenum internal; + UINT i; + + TRACE("texture %p, format %s.\n", texture, debug_d3dformat(format->id)); + + if (format->convert) + { + texture->flags |= WINED3D_TEXTURE_CONVERTED; + } + else if ((conversion = wined3d_format_get_color_key_conversion(texture, TRUE))) + { + texture->flags |= WINED3D_TEXTURE_CONVERTED; + format = wined3d_get_format(gl_info, conversion->dst_format); + TRACE("Using format %s for color key conversion.\n", debug_d3dformat(format->id)); + } + + wined3d_texture_bind_and_dirtify(texture, context, srgb); + + if (srgb) + internal = format->glGammaInternal; + else if (texture->resource.usage & WINED3DUSAGE_RENDERTARGET + && wined3d_resource_is_offscreen(&texture->resource)) + internal = format->rtInternal; + else + internal = format->glInternal; + + if (!internal) + FIXME("No GL internal format for format %s.\n", debug_d3dformat(format->id)); + + TRACE("internal %#x, format %#x, type %#x.\n", internal, format->glFormat, format->glType); + + for (i = 0; i < sub_count; ++i) + { + struct wined3d_surface *surface = surface_from_resource(texture->sub_resources[i]); + GLsizei height = surface->pow2Height; + GLsizei width = surface->pow2Width; + const BYTE *mem = NULL; + + if (format->flags & WINED3DFMT_FLAG_HEIGHT_SCALE) + { + height *= format->height_scale.numerator; + height /= format->height_scale.denominator; + } + + TRACE("surface %p, target %#x, level %d, width %d, height %d.\n", + surface, surface->texture_target, surface->texture_level, width, height); + + if (gl_info->supported[APPLE_CLIENT_STORAGE]) + { + if (surface->flags & (SFLAG_NONPOW2 | SFLAG_DIBSECTION) + || texture->flags & WINED3D_TEXTURE_CONVERTED + || !surface->resource.heap_memory) + { + /* In some cases we want to disable client storage. + * SFLAG_NONPOW2 has a bigger opengl texture than the client memory, and different pitches + * SFLAG_DIBSECTION: Dibsections may have read / write protections on the memory. Avoid issues... + * WINED3D_TEXTURE_CONVERTED: The conversion destination memory is freed after loading the surface + * heap_memory == NULL: Not defined in the extension. Seems to disable client storage effectively + */ + surface->flags &= ~SFLAG_CLIENT; + } + else + { + surface->flags |= SFLAG_CLIENT; + mem = surface->resource.heap_memory; + + gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE); + checkGLcall("glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE)"); + } + } + + if (format->flags & WINED3DFMT_FLAG_COMPRESSED && mem) + { + GL_EXTCALL(glCompressedTexImage2DARB(surface->texture_target, surface->texture_level, + internal, width, height, 0, surface->resource.size, mem)); + checkGLcall("glCompressedTexImage2DARB"); + } + else + { + gl_info->gl_ops.gl.p_glTexImage2D(surface->texture_target, surface->texture_level, + internal, width, height, 0, format->glFormat, format->glType, mem); + checkGLcall("glTexImage2D"); + } + + if (mem) + { + gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_FALSE); + checkGLcall("glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_FALSE)"); + } + } +} + static const struct wined3d_texture_ops texture2d_ops = { texture2d_sub_resource_load, texture2d_sub_resource_add_dirty_region, texture2d_sub_resource_cleanup, + texture2d_sub_resource_invalidate_location, + texture2d_prepare_texture, }; static ULONG texture_resource_incref(struct wined3d_resource *resource) @@ -844,6 +979,7 @@ sub_resource->resource_ops->resource_unload(sub_resource); } + wined3d_texture_force_reload(texture); wined3d_texture_unload_gl_texture(texture); } @@ -921,8 +1057,8 @@ } } - if (FAILED(hr = wined3d_texture_init(texture, &texture2d_ops, 6, levels, - desc, device, parent, parent_ops, &texture_resource_ops))) + if (FAILED(hr = wined3d_texture_init(texture, &texture2d_ops, 6, levels, desc, + surface_flags, device, parent, parent_ops, &texture_resource_ops))) { WARN("Failed to initialize texture, returning %#x\n", hr); return hr; @@ -1046,8 +1182,8 @@ TRACE("Calculated levels = %u.\n", levels); } - if (FAILED(hr = wined3d_texture_init(texture, &texture2d_ops, 1, levels, - desc, device, parent, parent_ops, &texture_resource_ops))) + if (FAILED(hr = wined3d_texture_init(texture, &texture2d_ops, 1, levels, desc, + surface_flags, device, parent, parent_ops, &texture_resource_ops))) { WARN("Failed to initialize texture, returning %#x.\n", hr); return hr; @@ -1074,7 +1210,7 @@ texture->pow2_matrix[15] = 1.0f; texture->target = GL_TEXTURE_RECTANGLE_ARB; texture->flags |= WINED3D_TEXTURE_COND_NP2; - texture->flags &= ~WINED3D_TEXTURE_POW2_MAT_IDENT; + texture->flags &= ~(WINED3D_TEXTURE_POW2_MAT_IDENT | WINED3D_TEXTURE_NORMALIZED_COORDS); if (texture->resource.format->flags & WINED3DFMT_FLAG_FILTERING) texture->min_mip_lookup = minMipLookup_noMip; @@ -1145,11 +1281,58 @@ wined3d_volume_destroy(volume); } +static void texture3d_sub_resource_invalidate_location(struct wined3d_resource *sub_resource, DWORD location) +{ + struct wined3d_volume *volume = volume_from_resource(sub_resource); + + wined3d_volume_invalidate_location(volume, location); +} + +static void texture3d_prepare_texture(struct wined3d_texture *texture, struct wined3d_context *context, BOOL srgb) +{ + unsigned int sub_count = texture->level_count * texture->layer_count; + const struct wined3d_format *format = texture->resource.format; + const struct wined3d_gl_info *gl_info = context->gl_info; + unsigned int i; + + wined3d_texture_bind_and_dirtify(texture, context, srgb); + + for (i = 0; i < sub_count; ++i) + { + struct wined3d_volume *volume = volume_from_resource(texture->sub_resources[i]); + void *mem = NULL; + + if (gl_info->supported[APPLE_CLIENT_STORAGE] && !format->convert + && volume_prepare_system_memory(volume)) + { + TRACE("Enabling GL_UNPACK_CLIENT_STORAGE_APPLE for volume %p\n", volume); + gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE); + checkGLcall("glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE)"); + mem = volume->resource.heap_memory; + volume->flags |= WINED3D_VFLAG_CLIENT_STORAGE; + } + + GL_EXTCALL(glTexImage3DEXT(GL_TEXTURE_3D, volume->texture_level, + srgb ? format->glGammaInternal : format->glInternal, + volume->resource.width, volume->resource.height, volume->resource.depth, + 0, format->glFormat, format->glType, mem)); + checkGLcall("glTexImage3D"); + + if (mem) + { + gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_FALSE); + checkGLcall("glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_FALSE)"); + } + } +} + static const struct wined3d_texture_ops texture3d_ops = { texture3d_sub_resource_load, texture3d_sub_resource_add_dirty_region, texture3d_sub_resource_cleanup, + texture3d_sub_resource_invalidate_location, + texture3d_prepare_texture, }; static HRESULT volumetexture_init(struct wined3d_texture *texture, const struct wined3d_resource_desc *desc, @@ -1225,8 +1408,8 @@ } } - if (FAILED(hr = wined3d_texture_init(texture, &texture3d_ops, 1, levels, - desc, device, parent, parent_ops, &texture_resource_ops))) + if (FAILED(hr = wined3d_texture_init(texture, &texture3d_ops, 1, levels, desc, + 0, device, parent, parent_ops, &texture_resource_ops))) { WARN("Failed to initialize texture, returning %#x.\n", hr); return hr; diff -Nru wine1.7-1.7.28/dlls/wined3d/utils.c wine1.7-1.7.31/dlls/wined3d/utils.c --- wine1.7-1.7.28/dlls/wined3d/utils.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/utils.c 2014-11-14 13:28:17.000000000 +0000 @@ -129,6 +129,7 @@ {WINED3DFMT_R32G32B32A32_UINT, 32, 32, 32, 32, 0, 32, 64, 96, 16, 0, 0}, {WINED3DFMT_R16G16B16A16_SNORM, 16, 16, 16, 16, 0, 16, 32, 48, 8, 0, 0}, /* Vendor-specific formats */ + {WINED3DFMT_ATI1N, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, {WINED3DFMT_ATI2N, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0}, {WINED3DFMT_NVDB, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {WINED3DFMT_INST, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, @@ -175,6 +176,7 @@ {WINED3DFMT_B4G4R4X4_UNORM, WINED3DFMT_FLAG_GETDC}, {WINED3DFMT_R8G8B8A8_UNORM, WINED3DFMT_FLAG_GETDC}, {WINED3DFMT_R8G8B8X8_UNORM, WINED3DFMT_FLAG_GETDC}, + {WINED3DFMT_ATI1N, WINED3DFMT_FLAG_BROKEN_PITCH}, {WINED3DFMT_ATI2N, WINED3DFMT_FLAG_BROKEN_PITCH}, {WINED3DFMT_R32_FLOAT, WINED3DFMT_FLAG_FLOAT}, {WINED3DFMT_R32G32_FLOAT, WINED3DFMT_FLAG_FLOAT}, @@ -203,6 +205,7 @@ {WINED3DFMT_DXT3, 4, 4, 16, TRUE}, {WINED3DFMT_DXT4, 4, 4, 16, TRUE}, {WINED3DFMT_DXT5, 4, 4, 16, TRUE}, + {WINED3DFMT_ATI1N, 4, 4, 8, FALSE}, {WINED3DFMT_ATI2N, 4, 4, 16, FALSE}, {WINED3DFMT_YUY2, 2, 1, 4, FALSE}, {WINED3DFMT_UYVY, 2, 1, 4, FALSE}, @@ -612,6 +615,207 @@ } } +static BOOL color_in_range(const struct wined3d_color_key *color_key, DWORD color) +{ + /* FIXME: Is this really how color keys are supposed to work? I think it + * makes more sense to compare the individual channels. */ + return color >= color_key->color_space_low_value + && color <= color_key->color_space_high_value; +} + +static void convert_p8_uint_b8g8r8a8_unorm(const BYTE *src, unsigned int src_pitch, + BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, + const struct wined3d_palette *palette, const struct wined3d_color_key *color_key) +{ + const BYTE *src_row; + unsigned int x, y; + DWORD *dst_row; + + if (!palette) + { + /* FIXME: This should probably use the system palette. */ + FIXME("P8 surface loaded without a palette.\n"); + + for (y = 0; y < height; ++y) + { + memset(&dst[dst_pitch * y], 0, width * 4); + } + + return; + } + + for (y = 0; y < height; ++y) + { + src_row = &src[src_pitch * y]; + dst_row = (DWORD *)&dst[dst_pitch * y]; + for (x = 0; x < width; ++x) + { + BYTE src_color = src_row[x]; + dst_row[x] = 0xff000000 + | (palette->colors[src_color].rgbRed << 16) + | (palette->colors[src_color].rgbGreen << 8) + | palette->colors[src_color].rgbBlue; + } + } +} + +static void convert_b5g6r5_unorm_b5g5r5a1_unorm_color_key(const BYTE *src, unsigned int src_pitch, + BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, + const struct wined3d_palette *palette, const struct wined3d_color_key *color_key) +{ + const WORD *src_row; + unsigned int x, y; + WORD *dst_row; + + for (y = 0; y < height; ++y) + { + src_row = (WORD *)&src[src_pitch * y]; + dst_row = (WORD *)&dst[dst_pitch * y]; + for (x = 0; x < width; ++x) + { + WORD src_color = src_row[x]; + if (!color_in_range(color_key, src_color)) + dst_row[x] = 0x8000 | ((src_color & 0xffc0) >> 1) | (src_color & 0x1f); + else + dst_row[x] = ((src_color & 0xffc0) >> 1) | (src_color & 0x1f); + } + } +} + +static void convert_b5g5r5x1_unorm_b5g5r5a1_unorm_color_key(const BYTE *src, unsigned int src_pitch, + BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, + const struct wined3d_palette *palette, const struct wined3d_color_key *color_key) +{ + const WORD *src_row; + unsigned int x, y; + WORD *dst_row; + + for (y = 0; y < height; ++y) + { + src_row = (WORD *)&src[src_pitch * y]; + dst_row = (WORD *)&dst[dst_pitch * y]; + for (x = 0; x < width; ++x) + { + WORD src_color = src_row[x]; + if (color_in_range(color_key, src_color)) + dst_row[x] = src_color & ~0x8000; + else + dst_row[x] = src_color | 0x8000; + } + } +} + +static void convert_b8g8r8_unorm_b8g8r8a8_unorm_color_key(const BYTE *src, unsigned int src_pitch, + BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, + const struct wined3d_palette *palette, const struct wined3d_color_key *color_key) +{ + const BYTE *src_row; + unsigned int x, y; + DWORD *dst_row; + + for (y = 0; y < height; ++y) + { + src_row = &src[src_pitch * y]; + dst_row = (DWORD *)&dst[dst_pitch * y]; + for (x = 0; x < width; ++x) + { + DWORD src_color = (src_row[x * 3 + 2] << 16) | (src_row[x * 3 + 1] << 8) | src_row[x * 3]; + if (!color_in_range(color_key, src_color)) + dst_row[x] = src_color | 0xff000000; + } + } +} + +static void convert_b8g8r8x8_unorm_b8g8r8a8_unorm_color_key(const BYTE *src, unsigned int src_pitch, + BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, + const struct wined3d_palette *palette, const struct wined3d_color_key *color_key) +{ + const DWORD *src_row; + unsigned int x, y; + DWORD *dst_row; + + for (y = 0; y < height; ++y) + { + src_row = (DWORD *)&src[src_pitch * y]; + dst_row = (DWORD *)&dst[dst_pitch * y]; + for (x = 0; x < width; ++x) + { + DWORD src_color = src_row[x]; + if (color_in_range(color_key, src_color)) + dst_row[x] = src_color & ~0xff000000; + else + dst_row[x] = src_color | 0xff000000; + } + } +} + +static void convert_b8g8r8a8_unorm_b8g8r8a8_unorm_color_key(const BYTE *src, unsigned int src_pitch, + BYTE *dst, unsigned int dst_pitch, unsigned int width, unsigned int height, + const struct wined3d_palette *palette, const struct wined3d_color_key *color_key) +{ + const DWORD *src_row; + unsigned int x, y; + DWORD *dst_row; + + for (y = 0; y < height; ++y) + { + src_row = (DWORD *)&src[src_pitch * y]; + dst_row = (DWORD *)&dst[dst_pitch * y]; + for (x = 0; x < width; ++x) + { + DWORD src_color = src_row[x]; + if (color_in_range(color_key, src_color)) + src_color &= ~0xff000000; + dst_row[x] = src_color; + } + } +} + +const struct wined3d_color_key_conversion * wined3d_format_get_color_key_conversion( + const struct wined3d_texture *texture, BOOL need_alpha_ck) +{ + const struct wined3d_format *format = texture->resource.format; + unsigned int i; + + static const struct + { + enum wined3d_format_id src_format; + struct wined3d_color_key_conversion conversion; + } + color_key_info[] = + { + {WINED3DFMT_B5G6R5_UNORM, {WINED3DFMT_B5G5R5A1_UNORM, convert_b5g6r5_unorm_b5g5r5a1_unorm_color_key }}, + {WINED3DFMT_B5G5R5X1_UNORM, {WINED3DFMT_B5G5R5A1_UNORM, convert_b5g5r5x1_unorm_b5g5r5a1_unorm_color_key }}, + {WINED3DFMT_B8G8R8_UNORM, {WINED3DFMT_B8G8R8A8_UNORM, convert_b8g8r8_unorm_b8g8r8a8_unorm_color_key }}, + {WINED3DFMT_B8G8R8X8_UNORM, {WINED3DFMT_B8G8R8A8_UNORM, convert_b8g8r8x8_unorm_b8g8r8a8_unorm_color_key }}, + {WINED3DFMT_B8G8R8A8_UNORM, {WINED3DFMT_B8G8R8A8_UNORM, convert_b8g8r8a8_unorm_b8g8r8a8_unorm_color_key }}, + }; + static const struct wined3d_color_key_conversion convert_p8 = + { + WINED3DFMT_B8G8R8A8_UNORM, convert_p8_uint_b8g8r8a8_unorm + }; + + if (need_alpha_ck && (texture->color_key_flags & WINEDDSD_CKSRCBLT)) + { + for (i = 0; i < sizeof(color_key_info) / sizeof(*color_key_info); ++i) + { + if (color_key_info[i].src_format == format->id) + return &color_key_info[i].conversion; + } + + FIXME("Color-keying not supported with format %s.\n", debug_d3dformat(format->id)); + } + + /* FIXME: This should check if the blitter backend can do P8 conversion, + * instead of checking for ARB_fragment_program. */ + if (format->id == WINED3DFMT_P8_UINT + && !(texture->resource.device->adapter->gl_info.supported[ARB_FRAGMENT_PROGRAM] + && texture->swapchain && texture == texture->swapchain->front_buffer)) + return &convert_p8; + + return NULL; +} + /* The following formats explicitly don't have WINED3DFMT_FLAG_TEXTURE set: * * These are never supported on native. @@ -983,6 +1187,11 @@ WINED3DFMT_FLAG_TEXTURE | WINED3DFMT_FLAG_DEPTH | WINED3DFMT_FLAG_STENCIL | WINED3DFMT_FLAG_SHADOW, ARB_DEPTH_BUFFER_FLOAT, convert_s8_uint_d24_float}, /* Vendor-specific formats */ + {WINED3DFMT_ATI1N, GL_COMPRESSED_RED_RGTC1, GL_COMPRESSED_RED_RGTC1, 0, + GL_RED, GL_UNSIGNED_BYTE, 0, + WINED3DFMT_FLAG_TEXTURE | WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING | WINED3DFMT_FLAG_FILTERING + | WINED3DFMT_FLAG_COMPRESSED, + ARB_TEXTURE_COMPRESSION_RGTC, NULL}, {WINED3DFMT_ATI2N, GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI, GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI, 0, GL_LUMINANCE_ALPHA, GL_UNSIGNED_BYTE, 0, WINED3DFMT_FLAG_TEXTURE | WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING | WINED3DFMT_FLAG_FILTERING @@ -1817,8 +2026,12 @@ */ } - if (gl_info->supported[EXT_TEXTURE_COMPRESSION_RGTC]) + if (gl_info->supported[ARB_TEXTURE_COMPRESSION_RGTC]) { + idx = getFmtIdx(WINED3DFMT_ATI1N); + gl_info->formats[idx].color_fixup = create_color_fixup_desc( + 0, CHANNEL_SOURCE_X, 0, CHANNEL_SOURCE_X, 0, CHANNEL_SOURCE_X, 0, CHANNEL_SOURCE_X); + idx = getFmtIdx(WINED3DFMT_ATI2N); gl_info->formats[idx].color_fixup = create_color_fixup_desc( 0, CHANNEL_SOURCE_Y, 0, CHANNEL_SOURCE_X, 0, CHANNEL_SOURCE_ONE, 0, CHANNEL_SOURCE_ONE); @@ -2115,6 +2328,7 @@ FMT_TO_STR(WINED3DFMT_S8_UINT_D24_FLOAT); FMT_TO_STR(WINED3DFMT_VERTEXDATA); FMT_TO_STR(WINED3DFMT_R8G8_SNORM_Cx); + FMT_TO_STR(WINED3DFMT_ATI1N); FMT_TO_STR(WINED3DFMT_ATI2N); FMT_TO_STR(WINED3DFMT_NVDB); FMT_TO_STR(WINED3DFMT_NVHU); diff -Nru wine1.7-1.7.28/dlls/wined3d/volume.c wine1.7-1.7.31/dlls/wined3d/volume.c --- wine1.7-1.7.28/dlls/wined3d/volume.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/volume.c 2014-11-14 13:28:17.000000000 +0000 @@ -27,11 +27,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(d3d_surface); WINE_DECLARE_DEBUG_CHANNEL(d3d_perf); -#define WINED3D_VFLAG_ALLOCATED 0x00000001 -#define WINED3D_VFLAG_SRGB_ALLOCATED 0x00000002 -#define WINED3D_VFLAG_CLIENT_STORAGE 0x00000004 - -static BOOL volume_prepare_system_memory(struct wined3d_volume *volume) +BOOL volume_prepare_system_memory(struct wined3d_volume *volume) { if (volume->resource.heap_memory) return TRUE; @@ -44,37 +40,6 @@ return TRUE; } -/* Context activation is done by the caller. */ -static void wined3d_volume_allocate_texture(struct wined3d_volume *volume, - const struct wined3d_context *context, BOOL srgb) -{ - const struct wined3d_gl_info *gl_info = context->gl_info; - const struct wined3d_format *format = volume->resource.format; - void *mem = NULL; - - if (gl_info->supported[APPLE_CLIENT_STORAGE] && !format->convert - && volume_prepare_system_memory(volume)) - { - TRACE("Enabling GL_UNPACK_CLIENT_STORAGE_APPLE for volume %p\n", volume); - gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE); - checkGLcall("glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_TRUE)"); - mem = volume->resource.heap_memory; - volume->flags |= WINED3D_VFLAG_CLIENT_STORAGE; - } - - GL_EXTCALL(glTexImage3DEXT(GL_TEXTURE_3D, volume->texture_level, - srgb ? format->glGammaInternal : format->glInternal, - volume->resource.width, volume->resource.height, volume->resource.depth, - 0, format->glFormat, format->glType, mem)); - checkGLcall("glTexImage3D"); - - if (mem) - { - gl_info->gl_ops.gl.p_glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_FALSE); - checkGLcall("glPixelStorei(GL_UNPACK_CLIENT_STORAGE_APPLE, GL_FALSE)"); - } -} - static void wined3d_volume_get_pitch(const struct wined3d_volume *volume, UINT *row_pitch, UINT *slice_pitch) { @@ -297,9 +262,9 @@ case WINED3D_LOCATION_TEXTURE_RGB: case WINED3D_LOCATION_TEXTURE_SRGB: if ((location == WINED3D_LOCATION_TEXTURE_RGB - && !(volume->flags & WINED3D_VFLAG_ALLOCATED)) + && !(volume->container->flags & WINED3D_TEXTURE_RGB_ALLOCATED)) || (location == WINED3D_LOCATION_TEXTURE_SRGB - && !(volume->flags & WINED3D_VFLAG_SRGB_ALLOCATED))) + && !(volume->container->flags & WINED3D_TEXTURE_SRGB_ALLOCATED))) ERR("Trying to load (s)RGB texture without prior allocation.\n"); if (volume->locations & WINED3D_LOCATION_DISCARDED) @@ -405,28 +370,9 @@ /* Context activation is done by the caller. */ void wined3d_volume_load(struct wined3d_volume *volume, struct wined3d_context *context, BOOL srgb_mode) { - wined3d_texture_bind_and_dirtify(volume->container, context, srgb_mode); - - if (srgb_mode) - { - if (!(volume->flags & WINED3D_VFLAG_SRGB_ALLOCATED)) - { - wined3d_volume_allocate_texture(volume, context, TRUE); - volume->flags |= WINED3D_VFLAG_SRGB_ALLOCATED; - } - - wined3d_volume_load_location(volume, context, WINED3D_LOCATION_TEXTURE_SRGB); - } - else - { - if (!(volume->flags & WINED3D_VFLAG_ALLOCATED)) - { - wined3d_volume_allocate_texture(volume, context, FALSE); - volume->flags |= WINED3D_VFLAG_ALLOCATED; - } - - wined3d_volume_load_location(volume, context, WINED3D_LOCATION_TEXTURE_RGB); - } + wined3d_texture_prepare_texture(volume->container, context, srgb_mode); + wined3d_volume_load_location(volume, context, + srgb_mode ? WINED3D_LOCATION_TEXTURE_SRGB : WINED3D_LOCATION_TEXTURE_RGB); } /* Context activation is done by the caller. */ @@ -505,8 +451,7 @@ } /* The texture name is managed by the container. */ - volume->flags &= ~(WINED3D_VFLAG_ALLOCATED | WINED3D_VFLAG_SRGB_ALLOCATED - | WINED3D_VFLAG_CLIENT_STORAGE); + volume->flags &= ~WINED3D_VFLAG_CLIENT_STORAGE; resource_unload(resource); } diff -Nru wine1.7-1.7.28/dlls/wined3d/wined3d_private.h wine1.7-1.7.31/dlls/wined3d/wined3d_private.h --- wine1.7-1.7.28/dlls/wined3d/wined3d_private.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wined3d/wined3d_private.h 2014-11-14 13:28:17.000000000 +0000 @@ -52,6 +52,10 @@ #include "wine/rbtree.h" #include "wine/wgl_driver.h" +#ifndef ARRAY_SIZE +#define ARRAY_SIZE(array) (sizeof(array) / sizeof((array)[0])) +#endif + /* Driver quirks */ #define WINED3D_QUIRK_ARB_VS_OFFSET_LIMIT 0x00000001 #define WINED3D_QUIRK_SET_TEXCOORD_W 0x00000002 @@ -141,6 +145,14 @@ return fixup.x_source == CHANNEL_SOURCE_COMPLEX0 || fixup.x_source == CHANNEL_SOURCE_COMPLEX1; } +static inline BOOL is_same_fixup(struct color_fixup_desc f1, struct color_fixup_desc f2) +{ + return f1.x_sign_fixup == f2.x_sign_fixup && f1.x_source == f2.x_source + && f1.y_sign_fixup == f2.y_sign_fixup && f1.y_source == f2.y_source + && f1.z_sign_fixup == f2.z_sign_fixup && f1.z_source == f2.z_source + && f1.w_sign_fixup == f2.w_sign_fixup && f1.w_source == f2.w_source; +} + static inline enum complex_fixup get_complex_fixup(struct color_fixup_desc fixup) { enum complex_fixup complex_fixup = 0; @@ -1502,6 +1514,7 @@ CARD_NVIDIA_GEFORCE_GTX670 = 0x1189, CARD_NVIDIA_GEFORCE_GTX670MX = 0x11a1, CARD_NVIDIA_GEFORCE_GTX680 = 0x1180, + CARD_NVIDIA_GEFORCE_GT750M = 0x0fe9, CARD_NVIDIA_GEFORCE_GTX750 = 0x1381, CARD_NVIDIA_GEFORCE_GTX750TI = 0x1380, CARD_NVIDIA_GEFORCE_GTX760 = 0x1187, @@ -2116,13 +2129,22 @@ void (*texture_sub_resource_add_dirty_region)(struct wined3d_resource *sub_resource, const struct wined3d_box *dirty_region); void (*texture_sub_resource_cleanup)(struct wined3d_resource *sub_resource); + void (*texture_sub_resource_invalidate_location)(struct wined3d_resource *sub_resource, DWORD location); + void (*texture_prepare_texture)(struct wined3d_texture *texture, + struct wined3d_context *context, BOOL srgb); }; #define WINED3D_TEXTURE_COND_NP2 0x00000001 #define WINED3D_TEXTURE_POW2_MAT_IDENT 0x00000002 #define WINED3D_TEXTURE_IS_SRGB 0x00000004 -#define WINED3D_TEXTURE_RGB_VALID 0x00000008 -#define WINED3D_TEXTURE_SRGB_VALID 0x00000010 +#define WINED3D_TEXTURE_RGB_ALLOCATED 0x00000008 +#define WINED3D_TEXTURE_RGB_VALID 0x00000010 +#define WINED3D_TEXTURE_SRGB_ALLOCATED 0x00000020 +#define WINED3D_TEXTURE_SRGB_VALID 0x00000040 +#define WINED3D_TEXTURE_CONVERTED 0x00000080 +#define WINED3D_TEXTURE_PIN_SYSMEM 0x00000100 +#define WINED3D_TEXTURE_DYNAMIC_MAP 0x00000200 +#define WINED3D_TEXTURE_NORMALIZED_COORDS 0x00000400 struct wined3d_texture { @@ -2168,8 +2190,11 @@ struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; void wined3d_texture_bind_and_dirtify(struct wined3d_texture *texture, struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; +void wined3d_texture_force_reload(struct wined3d_texture *texture) DECLSPEC_HIDDEN; void wined3d_texture_load(struct wined3d_texture *texture, struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; +void wined3d_texture_prepare_texture(struct wined3d_texture *texture, + struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; void wined3d_texture_set_dirty(struct wined3d_texture *texture) DECLSPEC_HIDDEN; void wined3d_texture_set_swapchain(struct wined3d_texture *texture, struct wined3d_swapchain *swapchain) DECLSPEC_HIDDEN; @@ -2187,6 +2212,8 @@ const char *wined3d_debug_location(DWORD location) DECLSPEC_HIDDEN; +#define WINED3D_VFLAG_CLIENT_STORAGE 0x00000001 + struct wined3d_volume { struct wined3d_resource resource; @@ -2203,6 +2230,7 @@ return CONTAINING_RECORD(resource, struct wined3d_volume, resource); } +BOOL volume_prepare_system_memory(struct wined3d_volume *volume) DECLSPEC_HIDDEN; HRESULT wined3d_volume_create(struct wined3d_texture *container, const struct wined3d_resource_desc *desc, unsigned int level, struct wined3d_volume **volume) DECLSPEC_HIDDEN; void wined3d_volume_destroy(struct wined3d_volume *volume) DECLSPEC_HIDDEN; @@ -2314,8 +2342,6 @@ void surface_modify_ds_location(struct wined3d_surface *surface, DWORD location, UINT w, UINT h) DECLSPEC_HIDDEN; void surface_prepare_rb(struct wined3d_surface *surface, const struct wined3d_gl_info *gl_info, BOOL multisample) DECLSPEC_HIDDEN; -void surface_prepare_texture(struct wined3d_surface *surface, - struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; void surface_set_compatible_renderbuffer(struct wined3d_surface *surface, const struct wined3d_surface *rt) DECLSPEC_HIDDEN; void surface_set_texture_target(struct wined3d_surface *surface, GLenum target, GLint level) DECLSPEC_HIDDEN; @@ -2336,30 +2362,13 @@ void flip_surface(struct wined3d_surface *front, struct wined3d_surface *back) DECLSPEC_HIDDEN; /* Surface flags: */ -#define SFLAG_CONVERTED 0x00000001 /* Converted for color keying or palettized. */ +#define SFLAG_DIBSECTION 0x00000001 /* Has a DIB section attached for GetDC. */ #define SFLAG_DISCARD 0x00000002 /* ??? */ #define SFLAG_NONPOW2 0x00000004 /* Surface sizes are not a power of 2 */ -#define SFLAG_NORMCOORD 0x00000008 /* Set if GL texture coordinates are normalized (non-texture rectangle). */ -#define SFLAG_DYNLOCK 0x00000010 /* Surface is often locked by the application. */ -#define SFLAG_PIN_SYSMEM 0x00000020 /* Keep the surface in sysmem, at the same address. */ +#define SFLAG_LOST 0x00000008 /* Surface lost flag for ddraw. */ +#define SFLAG_GLCKEY 0x00000010 /* The GL texture was created with a color key. */ +#define SFLAG_CLIENT 0x00000020 /* GL_APPLE_client_storage is used with this surface. */ #define SFLAG_DCINUSE 0x00000040 /* Set between GetDC and ReleaseDC calls. */ -#define SFLAG_LOST 0x00000080 /* Surface lost flag for ddraw. */ -#define SFLAG_GLCKEY 0x00000100 /* The GL texture was created with a color key. */ -#define SFLAG_CLIENT 0x00000200 /* GL_APPLE_client_storage is used with this surface. */ -#define SFLAG_DIBSECTION 0x00000400 /* Has a DIB section attached for GetDC. */ -#define SFLAG_ALLOCATED 0x00000800 /* A GL texture is allocated for this surface. */ -#define SFLAG_SRGBALLOCATED 0x00001000 /* A sRGB GL texture is allocated for this surface. */ - -enum wined3d_conversion_type -{ - WINED3D_CT_NONE, - WINED3D_CT_P8, - WINED3D_CT_CK_B5G6R5, - WINED3D_CT_CK_B5G5R5X1, - WINED3D_CT_CK_B8G8R8, - WINED3D_CT_CK_B8G8R8X8, - WINED3D_CT_CK_B8G8R8A8, -}; struct wined3d_sampler { @@ -2860,7 +2869,7 @@ struct wined3d_shader { LONG ref; - struct wined3d_shader_limits limits; + const struct wined3d_shader_limits *limits; DWORD *function; UINT functionLength; BOOL load_local_constsF; @@ -2883,6 +2892,7 @@ struct wined3d_shader_signature_element input_signature[max(MAX_ATTRIBS, MAX_REG_INPUT)]; struct wined3d_shader_signature_element output_signature[MAX_REG_OUTPUT]; + char *signature_strings; /* Pointer to the parent device */ struct wined3d_device *device; @@ -3047,6 +3057,13 @@ UINT denominator; }; +struct wined3d_color_key_conversion +{ + enum wined3d_format_id dst_format; + void (*convert)(const BYTE *src, unsigned int src_pitch, BYTE *dst, unsigned int dst_pitch, unsigned int width, + unsigned int height, const struct wined3d_palette *palette, const struct wined3d_color_key *color_key); +}; + struct wined3d_format { enum wined3d_format_id id; @@ -3094,6 +3111,8 @@ UINT alignment, UINT width, UINT height, UINT depth) DECLSPEC_HIDDEN; DWORD wined3d_format_convert_from_float(const struct wined3d_surface *surface, const struct wined3d_color *color) DECLSPEC_HIDDEN; +const struct wined3d_color_key_conversion * wined3d_format_get_color_key_conversion( + const struct wined3d_texture *texture, BOOL need_alpha_ck) DECLSPEC_HIDDEN; static inline BOOL use_vs(const struct wined3d_state *state) { diff -Nru wine1.7-1.7.28/dlls/winemac.drv/cocoa_window.m wine1.7-1.7.31/dlls/winemac.drv/cocoa_window.m --- wine1.7-1.7.28/dlls/winemac.drv/cocoa_window.m 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/winemac.drv/cocoa_window.m 2014-11-14 13:28:17.000000000 +0000 @@ -374,6 +374,11 @@ return [[self window] contentView] == self; } + - (BOOL) mouseDownCanMoveWindow + { + return NO; + } + - (void) completeText:(NSString*)text { macdrv_event* event; diff -Nru wine1.7-1.7.28/dlls/winemac.drv/window.c wine1.7-1.7.31/dlls/winemac.drv/window.c --- wine1.7-1.7.28/dlls/winemac.drv/window.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/winemac.drv/window.c 2014-11-14 13:28:17.000000000 +0000 @@ -72,12 +72,12 @@ if (ex_style & WS_EX_TOOLWINDOW) wf->utility = TRUE; } } - if (ex_style & WS_EX_DLGMODALFRAME) wf->shadow = TRUE; - else if (style & WS_THICKFRAME) + if (style & WS_THICKFRAME) { wf->shadow = TRUE; if (!data->shaped) wf->resizable = TRUE; } + else if (ex_style & WS_EX_DLGMODALFRAME) wf->shadow = TRUE; else if ((style & (WS_DLGFRAME|WS_BORDER)) == WS_DLGFRAME) wf->shadow = TRUE; } diff -Nru wine1.7-1.7.28/dlls/winex11.drv/opengl.c wine1.7-1.7.31/dlls/winex11.drv/opengl.c --- wine1.7-1.7.28/dlls/winex11.drv/opengl.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/winex11.drv/opengl.c 2014-11-14 13:28:17.000000000 +0000 @@ -145,6 +145,10 @@ #define GLX_PBUFFER 0x8023 #define GLX_PBUFFER_HEIGHT 0x8040 #define GLX_PBUFFER_WIDTH 0x8041 +#define GLX_SWAP_METHOD_OML 0x8060 +#define GLX_SWAP_EXCHANGE_OML 0x8061 +#define GLX_SWAP_COPY_OML 0x8062 +#define GLX_SWAP_UNDEFINED_OML 0x8063 #define GLX_RGBA_BIT 0x00000001 #define GLX_COLOR_INDEX_BIT 0x00000002 #define GLX_PBUFFER_CLOBBER_MASK 0x08000000 @@ -285,6 +289,7 @@ static enum glx_swap_control_method swap_control_method = GLX_SWAP_CONTROL_NONE; /* Set when GLX_EXT_swap_control_tear is supported, requires GLX_SWAP_CONTROL_EXT */ static BOOL has_swap_control_tear = FALSE; +static BOOL has_swap_method = FALSE; static CRITICAL_SECTION context_section; static CRITICAL_SECTION_DEBUG critsect_debug = @@ -878,8 +883,30 @@ case WGL_SWAP_METHOD_ARB: pop = iWGLAttr[++cur]; - /* For now we ignore this and just return SWAP_EXCHANGE */ TRACE("pAttr[%d] = WGL_SWAP_METHOD_ARB: %#x\n", cur, pop); + if (has_swap_method) + { + switch (pop) + { + case WGL_SWAP_EXCHANGE_ARB: + pop = GLX_SWAP_EXCHANGE_OML; + break; + case WGL_SWAP_COPY_ARB: + pop = GLX_SWAP_COPY_OML; + break; + case WGL_SWAP_UNDEFINED_ARB: + pop = GLX_SWAP_UNDEFINED_OML; + break; + default: + ERR("Unexpected swap method %#x.\n", pop); + pop = GLX_DONT_CARE; + } + PUSH2(oGLXAttr, GLX_SWAP_METHOD_OML, pop); + } + else + { + WARN("GLX_OML_swap_method not supported, ignoring attribute.\n"); + } break; case WGL_PBUFFER_LARGEST_ARB: @@ -2737,12 +2764,31 @@ continue; case WGL_SWAP_METHOD_ARB: - /* For now return SWAP_EXCHANGE_ARB which is the best type of buffer switch available. - * Later on we can also use GLX_OML_swap_method on drivers which support this. At this - * point only ATI offers this. - */ - piValues[i] = WGL_SWAP_EXCHANGE_ARB; - break; + if (has_swap_method) + { + hTest = pglXGetFBConfigAttrib(gdi_display, fmt->fbconfig, GLX_DRAWABLE_TYPE, &tmp); + if (hTest) goto get_error; + switch (tmp) + { + case GLX_SWAP_EXCHANGE_OML: + piValues[i] = WGL_SWAP_EXCHANGE_ARB; + break; + case GLX_SWAP_COPY_OML: + piValues[i] = WGL_SWAP_COPY_ARB; + break; + case GLX_SWAP_UNDEFINED_OML: + piValues[i] = WGL_SWAP_UNDEFINED_ARB; + break; + default: + ERR("Unexpected swap method %x.\n", tmp); + } + } + else + { + WARN("GLX_OML_swap_method not supported, returning WGL_SWAP_EXCHANGE_ARB.\n"); + piValues[i] = WGL_SWAP_EXCHANGE_ARB; + } + continue; case WGL_PBUFFER_LARGEST_ARB: curGLXAttr = GLX_LARGEST_PBUFFER; @@ -3167,6 +3213,9 @@ opengl_funcs.ext.p_wglFreeMemoryNV = pglXFreeMemoryNV; } + if (has_extension(WineGLInfo.glxExtensions, "GLX_OML_swap_method")) + has_swap_method = TRUE; + /* WINE-specific WGL Extensions */ /* In WineD3D we need the ability to set the pixel format more than once (e.g. after a device reset). diff -Nru wine1.7-1.7.28/dlls/winhttp/tests/winhttp.c wine1.7-1.7.31/dlls/winhttp/tests/winhttp.c --- wine1.7-1.7.28/dlls/winhttp/tests/winhttp.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/winhttp/tests/winhttp.c 2014-11-14 13:28:17.000000000 +0000 @@ -876,12 +876,15 @@ ret = WinHttpQueryOption(req, WINHTTP_OPTION_SECURITY_CERTIFICATE_STRUCT, &info, &size ); ok(ret, "failed to retrieve certificate info %u\n", GetLastError()); - trace("lpszSubjectInfo %s\n", wine_dbgstr_w(info.lpszSubjectInfo)); - trace("lpszIssuerInfo %s\n", wine_dbgstr_w(info.lpszIssuerInfo)); - trace("lpszProtocolName %s\n", wine_dbgstr_w(info.lpszProtocolName)); - trace("lpszSignatureAlgName %s\n", wine_dbgstr_w(info.lpszSignatureAlgName)); - trace("lpszEncryptionAlgName %s\n", wine_dbgstr_w(info.lpszEncryptionAlgName)); - trace("dwKeySize %u\n", info.dwKeySize); + if (ret) + { + trace("lpszSubjectInfo %s\n", wine_dbgstr_w(info.lpszSubjectInfo)); + trace("lpszIssuerInfo %s\n", wine_dbgstr_w(info.lpszIssuerInfo)); + trace("lpszProtocolName %s\n", wine_dbgstr_w(info.lpszProtocolName)); + trace("lpszSignatureAlgName %s\n", wine_dbgstr_w(info.lpszSignatureAlgName)); + trace("lpszEncryptionAlgName %s\n", wine_dbgstr_w(info.lpszEncryptionAlgName)); + trace("dwKeySize %u\n", info.dwKeySize); + } ret = WinHttpReceiveResponse(req, NULL); ok(ret, "failed to receive response %u\n", GetLastError()); diff -Nru wine1.7-1.7.28/dlls/wininet/ftp.c wine1.7-1.7.31/dlls/wininet/ftp.c --- wine1.7-1.7.28/dlls/wininet/ftp.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wininet/ftp.c 2014-11-14 13:28:17.000000000 +0000 @@ -2496,7 +2496,7 @@ if(hIC->proxyBypass) FIXME("Proxy bypass is ignored.\n"); } - if (!lpszUserName || !strlenW(lpszUserName)) { + if (!lpszUserName || !lpszUserName[0]) { HKEY key; WCHAR szPassword[MAX_PATH]; DWORD len = sizeof(szPassword); diff -Nru wine1.7-1.7.28/dlls/wininet/http.c wine1.7-1.7.31/dlls/wininet/http.c --- wine1.7-1.7.28/dlls/wininet/http.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wininet/http.c 2014-11-14 13:28:17.000000000 +0000 @@ -809,7 +809,7 @@ LPWSTR str = start; LPWSTR end; - while (*str == ' ' && *str != '\0') + while (*str == ' ') str++; if (str != start) @@ -841,13 +841,13 @@ if (!token) return TRUE; realm = ptr; - while (*realm == ' ' && *realm != '\0') + while (*realm == ' ') realm++; if(!strncmpiW(realm, szRealm, ARRAYSIZE(szRealm)) && (realm[ARRAYSIZE(szRealm)] == ' ' || realm[ARRAYSIZE(szRealm)] == '=')) { token++; - while (*token == ' ' && *token != '\0') + while (*token == ' ') token++; if (*token == '\0') return TRUE; @@ -4173,20 +4173,9 @@ heap_free(session->hostName); - if(custom_port) { - int len; - static const WCHAR fmt[] = {'%','s',':','%','u',0}; - len = lstrlenW(hostName); - len += 7; /* 5 for strlen("65535") + 1 for ":" + 1 for '\0' */ - session->hostName = heap_alloc(len*sizeof(WCHAR)); - sprintfW(session->hostName, fmt, hostName, urlComponents.nPort); - } - else - session->hostName = heap_strdupW(hostName); + session->hostName = heap_strdupW(hostName); session->hostPort = urlComponents.nPort; - HTTP_ProcessHeader(request, hostW, session->hostName, HTTP_ADDREQ_FLAG_ADD | HTTP_ADDREQ_FLAG_REPLACE | HTTP_ADDHDR_FLAG_REQ); - heap_free(session->userName); session->userName = NULL; if (userName[0]) @@ -4201,6 +4190,11 @@ server_release(request->server); request->server = new_server; } + + if (custom_port) + HTTP_ProcessHeader(request, hostW, request->server->host_port, HTTP_ADDREQ_FLAG_ADD | HTTP_ADDREQ_FLAG_REPLACE | HTTP_ADDHDR_FLAG_REQ); + else + HTTP_ProcessHeader(request, hostW, request->server->name, HTTP_ADDREQ_FLAG_ADD | HTTP_ADDREQ_FLAG_REPLACE | HTTP_ADDHDR_FLAG_REQ); } heap_free(request->path); request->path=NULL; diff -Nru wine1.7-1.7.28/dlls/wininet/internet.c wine1.7-1.7.31/dlls/wininet/internet.c --- wine1.7-1.7.28/dlls/wininet/internet.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wininet/internet.c 2014-11-14 13:28:17.000000000 +0000 @@ -1276,13 +1276,21 @@ /* Must be zero */ if(dwReserved) - return FALSE; + return FALSE; if (lpdwStatus) { WARN("always returning LAN connection.\n"); *lpdwStatus = INTERNET_CONNECTION_LAN; } - return LoadStringW(WININET_hModule, IDS_LANCONNECTION, lpszConnectionName, dwNameLen) > 0; + + /* When the buffer size is zero LoadStringW fills the buffer with a pointer to + * the resource, avoid it as we must not change the buffer in this case */ + if(lpszConnectionName && dwNameLen) { + *lpszConnectionName = '\0'; + LoadStringW(WININET_hModule, IDS_LANCONNECTION, lpszConnectionName, dwNameLen); + } + + return TRUE; } diff -Nru wine1.7-1.7.28/dlls/wininet/tests/http.c wine1.7-1.7.31/dlls/wininet/tests/http.c --- wine1.7-1.7.28/dlls/wininet/tests/http.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wininet/tests/http.c 2014-11-14 13:28:17.000000000 +0000 @@ -4223,7 +4223,7 @@ ok(!info.lpszSignatureAlgName, "lpszSignatureAlgName = %s\n", info.lpszSignatureAlgName); ok(!info.lpszEncryptionAlgName, "lpszEncryptionAlgName = %s\n", info.lpszEncryptionAlgName); ok(!info.lpszProtocolName, "lpszProtocolName = %s\n", info.lpszProtocolName); - ok(info.dwKeySize == 128 || info.dwKeySize == 256, "dwKeySize = %u\n", info.dwKeySize); + ok(info.dwKeySize >= 128 && info.dwKeySize <= 256, "dwKeySize = %u\n", info.dwKeySize); release_cert_info(&info); } diff -Nru wine1.7-1.7.28/dlls/wininet/tests/internet.c wine1.7-1.7.31/dlls/wininet/tests/internet.c --- wine1.7-1.7.28/dlls/wininet/tests/internet.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wininet/tests/internet.c 2014-11-14 13:28:17.000000000 +0000 @@ -1525,19 +1525,16 @@ trace("Internet Connection: Flags 0x%02x - Name '%s'\n", flags, buffer); res = pInternetGetConnectedStateExA(NULL, NULL, 0, 0); -todo_wine ok(res == TRUE, "Expected TRUE, got %d\n", res); flags = 0; res = pInternetGetConnectedStateExA(&flags, NULL, 0, 0); -todo_wine ok(res == TRUE, "Expected TRUE, got %d\n", res); ok(flags, "Expected at least one flag set\n"); buffer[0] = 0; flags = 0; res = pInternetGetConnectedStateExA(&flags, buffer, 0, 0); -todo_wine ok(res == TRUE, "Expected TRUE, got %d\n", res); ok(flags, "Expected at least one flag set\n"); ok(!buffer[0], "Buffer must not change, got %02X\n", buffer[0]); @@ -1556,6 +1553,11 @@ sz = strlen(buffer); ok(sz > 0, "Expected a connection name\n"); + flags = 0; + res = pInternetGetConnectedStateExA(&flags, NULL, sizeof(buffer), 0); + ok(res == TRUE, "Expected TRUE, got %d\n", res); + ok(flags, "Expected at least one flag set\n"); + /* no space for complete string this time */ buffer[0] = 0; flags = 0; @@ -1566,11 +1568,31 @@ buffer[0] = 0; flags = 0; + res = pInternetGetConnectedStateExA(&flags, buffer, sz / 2, 0); + ok(res == TRUE, "Expected TRUE, got %d\n", res); + ok(flags, "Expected at least one flag set\n"); + ok(sz / 2 - 1 == strlen(buffer), "Expected %u bytes, got %u\n", sz / 2 - 1, lstrlenA(buffer)); + + buffer[0] = 0; + flags = 0; + res = pInternetGetConnectedStateExA(&flags, buffer, 1, 0); + ok(res == TRUE, "Expected TRUE, got %d\n", res); + ok(flags, "Expected at least one flag set\n"); + ok(!buffer[0], "Expected 0 bytes, got %u\n", lstrlenA(buffer)); + + buffer[0] = 0; + flags = 0; + res = pInternetGetConnectedStateExA(&flags, buffer, 2, 0); + ok(res == TRUE, "Expected TRUE, got %d\n", res); + ok(flags, "Expected at least one flag set\n"); + ok(strlen(buffer) == 1, "Expected 1 byte, got %u\n", lstrlenA(buffer)); + + flags = 0; + buffer[0] = 0xDE; res = pInternetGetConnectedStateExA(&flags, buffer, 1, 0); -todo_wine ok(res == TRUE, "Expected TRUE, got %d\n", res); ok(flags, "Expected at least one flag set\n"); - ok(strlen(buffer) == 0, "Expected 0 bytes, got %u\n", lstrlenA(buffer)); + ok(!buffer[0], "Expected 0 bytes, got %u\n", lstrlenA(buffer)); } static void test_InternetGetConnectedStateExW(void) @@ -1592,12 +1614,10 @@ trace("Internet Connection: Flags 0x%02x - Name '%s'\n", flags, wine_dbgstr_w(buffer)); res = pInternetGetConnectedStateExW(NULL, NULL, 0, 0); -todo_wine ok(res == TRUE, "Expected TRUE, got %d\n", res); flags = 0; res = pInternetGetConnectedStateExW(&flags, NULL, 0, 0); -todo_wine ok(res == TRUE, "Expected TRUE, got %d\n", res); ok(flags, "Expected at least one flag set\n"); @@ -1606,7 +1626,6 @@ res = pInternetGetConnectedStateExW(&flags, buffer, 0, 0); ok(res == TRUE, "Expected TRUE, got %d\n", res); ok(flags, "Expected at least one flag set\n"); -todo_wine ok(!buffer[0], "Buffer must not change, got %02X\n", buffer[0]); buffer[0] = 0; @@ -1623,6 +1642,11 @@ sz = lstrlenW(buffer); ok(sz > 0, "Expected a connection name\n"); + flags = 0; + res = pInternetGetConnectedStateExW(&flags, NULL, sizeof(buffer) / sizeof(buffer[0]), 0); + ok(res == TRUE, "Expected TRUE, got %d\n", res); + ok(flags, "Expected at least one flag set\n"); + /* no space for complete string this time */ buffer[0] = 0; flags = 0; @@ -1633,11 +1657,31 @@ buffer[0] = 0; flags = 0; + res = pInternetGetConnectedStateExW(&flags, buffer, sz / 2, 0); + ok(res == TRUE, "Expected TRUE, got %d\n", res); + ok(flags, "Expected at least one flag set\n"); + ok(sz / 2 - 1 == lstrlenW(buffer), "Expected %u bytes, got %u\n", sz / 2 - 1, lstrlenW(buffer)); + + buffer[0] = 0; + flags = 0; + res = pInternetGetConnectedStateExW(&flags, buffer, 1, 0); + ok(res == TRUE, "Expected TRUE, got %d\n", res); + ok(flags, "Expected at least one flag set\n"); + ok(!buffer[0], "Expected 0 bytes, got %u\n", lstrlenW(buffer)); + + buffer[0] = 0; + flags = 0; + res = pInternetGetConnectedStateExW(&flags, buffer, 2, 0); + ok(res == TRUE, "Expected TRUE, got %d\n", res); + ok(flags, "Expected at least one flag set\n"); + ok(lstrlenW(buffer) == 1, "Expected 1 byte, got %u\n", lstrlenW(buffer)); + + buffer[0] = 0xDEAD; + flags = 0; res = pInternetGetConnectedStateExW(&flags, buffer, 1, 0); -todo_wine ok(res == TRUE, "Expected TRUE, got %d\n", res); ok(flags, "Expected at least one flag set\n"); - ok(lstrlenW(buffer) == 0, "Expected 0 bytes, got %u\n", lstrlenW(buffer)); + ok(!buffer[0], "Expected 0 bytes, got %u\n", lstrlenW(buffer)); } /* ############################### */ diff -Nru wine1.7-1.7.28/dlls/ws2_32/socket.c wine1.7-1.7.31/dlls/ws2_32/socket.c --- wine1.7-1.7.28/dlls/ws2_32/socket.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ws2_32/socket.c 2014-11-14 13:28:17.000000000 +0000 @@ -2293,7 +2293,7 @@ struct ws2_async *wsa; NTSTATUS status; - TRACE("s %ld type %d\n", s, type); + TRACE("s %04lx type %d\n", s, type); wsa = HeapAlloc( GetProcessHeap(), 0, FIELD_OFFSET( struct ws2_async, iovec[1] )); if ( !wsa ) @@ -3744,7 +3744,7 @@ int fd; DWORD status = 0, total = 0; - TRACE("%ld, %s, %p, %d, %p, %d, %p, %p, %p\n", + TRACE("%04lx, %s, %p, %d, %p, %d, %p, %p, %p\n", s, debugstr_wsaioctl(code), in_buff, in_size, out_buff, out_size, ret_size, overlapped, completion); switch (code) @@ -3937,9 +3937,20 @@ return SOCKET_ERROR; } + if (out_size && out_size < FIELD_OFFSET(SOCKET_ADDRESS_LIST, Address[0])) + { + *ret_size = 0; + WSASetLastError(WSAEINVAL); + return SOCKET_ERROR; + } + if (GetAdaptersInfo(NULL, &size) == ERROR_BUFFER_OVERFLOW) { IP_ADAPTER_INFO *p, *table = HeapAlloc(GetProcessHeap(), 0, size); + SOCKET_ADDRESS_LIST *sa_list; + SOCKADDR_IN *sockaddr; + SOCKET_ADDRESS *sa; + unsigned int i; DWORD num; if (!table || GetAdaptersInfo(table, &size)) @@ -3952,39 +3963,31 @@ for (p = table, num = 0; p; p = p->Next) if (p->IpAddressList.IpAddress.String[0]) num++; - total = sizeof(SOCKET_ADDRESS_LIST) + sizeof(SOCKET_ADDRESS) * (num - 1); - total += sizeof(SOCKADDR) * num; - - if (total > out_size) + total = FIELD_OFFSET(SOCKET_ADDRESS_LIST, Address[num]) + num * sizeof(*sockaddr); + if (total > out_size || !out_buff) { + *ret_size = total; HeapFree(GetProcessHeap(), 0, table); status = WSAEFAULT; break; } - if (out_buff) - { - unsigned int i; - SOCKET_ADDRESS *sa; - SOCKET_ADDRESS_LIST *sa_list = out_buff; - SOCKADDR_IN *sockaddr; - - sa = sa_list->Address; - sockaddr = (SOCKADDR_IN *)((char *)sa + num * sizeof(SOCKET_ADDRESS)); - sa_list->iAddressCount = num; - - for (p = table, i = 0; p; p = p->Next) - { - if (!p->IpAddressList.IpAddress.String[0]) continue; - - sa[i].lpSockaddr = (SOCKADDR *)&sockaddr[i]; - sa[i].iSockaddrLength = sizeof(SOCKADDR); - - sockaddr[i].sin_family = AF_INET; - sockaddr[i].sin_port = 0; - sockaddr[i].sin_addr.WS_s_addr = inet_addr(p->IpAddressList.IpAddress.String); - i++; - } + sa_list = out_buff; + sa = sa_list->Address; + sockaddr = (SOCKADDR_IN *)&sa[num]; + sa_list->iAddressCount = num; + + for (p = table, i = 0; p; p = p->Next) + { + if (!p->IpAddressList.IpAddress.String[0]) continue; + + sa[i].lpSockaddr = (SOCKADDR *)&sockaddr[i]; + sa[i].iSockaddrLength = sizeof(SOCKADDR); + + sockaddr[i].sin_family = AF_INET; + sockaddr[i].sin_port = 0; + sockaddr[i].sin_addr.WS_s_addr = inet_addr(p->IpAddressList.IpAddress.String); + i++; } HeapFree(GetProcessHeap(), 0, table); @@ -6908,6 +6911,40 @@ } /*********************************************************************** +* inet_pton (WS2_32.@) +*/ +INT WINAPI WS_inet_pton( INT family, PCSTR addr, PVOID buffer) +{ +#ifdef HAVE_INET_PTON + int unixaf, ret; + + TRACE("family %d, addr '%s', buffer (%p)\n", family, addr ? addr : "(null)", buffer); + + if (!addr || !buffer) + { + SetLastError(WSAEFAULT); + return SOCKET_ERROR; + } + + unixaf = convert_af_w2u(family); + if (unixaf != AF_INET && unixaf != AF_INET6) + { + SetLastError(WSAEAFNOSUPPORT); + return SOCKET_ERROR; + } + + ret = inet_pton(unixaf, addr, buffer); + if (ret == -1) SetLastError(wsaErrno()); + return ret; +#else + FIXME( "not supported on this platform\n" ); + WSASetLastError( WSAEAFNOSUPPORT ); + return SOCKET_ERROR; +#endif +} + + +/*********************************************************************** * WSAStringToAddressA (WS2_32.80) */ INT WINAPI WSAStringToAddressA(LPSTR AddressString, diff -Nru wine1.7-1.7.28/dlls/ws2_32/tests/sock.c wine1.7-1.7.31/dlls/ws2_32/tests/sock.c --- wine1.7-1.7.28/dlls/ws2_32/tests/sock.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ws2_32/tests/sock.c 2014-11-14 13:28:17.000000000 +0000 @@ -67,6 +67,7 @@ static void (WINAPI *pFreeAddrInfoW)(PADDRINFOW); static int (WINAPI *pGetAddrInfoW)(LPCWSTR,LPCWSTR,const ADDRINFOW *,PADDRINFOW *); static PCSTR (WINAPI *pInetNtop)(INT,LPVOID,LPSTR,ULONG); +static int (WINAPI *pInetPton)(INT,LPSTR,LPVOID); static int (WINAPI *pWSALookupServiceBeginW)(LPWSAQUERYSETW,DWORD,LPHANDLE); static int (WINAPI *pWSALookupServiceEnd)(HANDLE); static int (WINAPI *pWSALookupServiceNextW)(HANDLE,DWORD,LPDWORD,LPWSAQUERYSETW); @@ -1139,6 +1140,7 @@ pFreeAddrInfoW = (void *)GetProcAddress(hws2_32, "FreeAddrInfoW"); pGetAddrInfoW = (void *)GetProcAddress(hws2_32, "GetAddrInfoW"); pInetNtop = (void *)GetProcAddress(hws2_32, "inet_ntop"); + pInetPton = (void *)GetProcAddress(hws2_32, "inet_pton"); pWSALookupServiceBeginW = (void *)GetProcAddress(hws2_32, "WSALookupServiceBeginW"); pWSALookupServiceEnd = (void *)GetProcAddress(hws2_32, "WSALookupServiceEnd"); pWSALookupServiceNextW = (void *)GetProcAddress(hws2_32, "WSALookupServiceNextW"); @@ -3987,6 +3989,117 @@ pdst = pInetNtop(AF_INET6, (void*)&in6.s6_addr, dst6, 18); ok(pdst != NULL, "The pointer should be returned (%p)\n", pdst); } +static void test_inet_pton(void) +{ + struct TEST_DATA + { + int family, ret; + DWORD err; + const char *printable, *collapsed, *raw_data; + } tests[] = { + {AF_UNSPEC, -1, WSAEFAULT, /* Test 0 */ + NULL, NULL, NULL}, + {AF_INET, -1, WSAEFAULT, + NULL, NULL, NULL}, + {AF_INET6, -1, WSAEFAULT, + NULL, NULL, NULL}, + {AF_UNSPEC, -1, WSAEAFNOSUPPORT, + "127.0.0.1", NULL, NULL}, + {AF_INET, 1, 0, + "127.0.0.1", "127.0.0.1", + "\x7f\x00\x00\x01"}, + {AF_INET6, 0, 0, + "127.0.0.1", "127.0.0.1", NULL}, + {AF_INET, 0, 0, + "::1/128", NULL, NULL}, + {AF_INET6, 0, 0, + "::1/128", NULL, NULL}, + {AF_UNSPEC, -1, WSAEAFNOSUPPORT, + "broken", NULL, NULL}, + {AF_INET, 0, 0, + "broken", NULL, NULL}, + {AF_INET6, 0, 0, /* Test 10 */ + "broken", NULL, NULL}, + {AF_UNSPEC, -1, WSAEAFNOSUPPORT, + "177.32.45.20", NULL, NULL}, + {AF_INET, 1, 0, + "177.32.45.20", "177.32.45.20", + "\xb1\x20\x2d\x14"}, + {AF_INET6, 0, 0, + "177.32.45.20", NULL, NULL}, + {AF_INET, 0, 0, + "2607:f0d0:1002:51::4", NULL, NULL}, + {AF_INET6, 1, 0, + "2607:f0d0:1002:51::4", "2607:f0d0:1002:51::4", + "\x26\x07\xf0\xd0\x10\x02\x00\x51\x00\x00\x00\x00\x00\x00\x00\x04"}, + {AF_INET, 0, 0, + "::177.32.45.20", NULL, NULL}, + {AF_INET6, 1, 0, + "::177.32.45.20", "::177.32.45.20", + "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xb1\x20\x2d\x14"}, + {AF_INET, 0, 0, + "fe80::0202:b3ff:fe1e:8329", NULL, NULL}, + {AF_INET6, 1, 0, + "fe80::0202:b3ff:fe1e:8329", "fe80::202:b3ff:fe1e:8329", + "\xfe\x80\x00\x00\x00\x00\x00\x00\x02\x02\xb3\xff\xfe\x1e\x83\x29"}, + {AF_INET6, 1, 0, /* Test 20 */ + "fe80::202:b3ff:fe1e:8329", "fe80::202:b3ff:fe1e:8329", + "\xfe\x80\x00\x00\x00\x00\x00\x00\x02\x02\xb3\xff\xfe\x1e\x83\x29"}, + {AF_INET, 0, 0, + "a", NULL, NULL}, + {AF_INET, 0, 0, + "a.b", NULL, NULL}, + {AF_INET, 0, 0, + "a.b.c", NULL, NULL}, + {AF_INET, 0, 0, + "a.b.c.d", NULL, NULL}, + {AF_INET6, 1, 0, + "2001:cdba:0000:0000:0000:0000:3257:9652", "2001:cdba::3257:9652", + "\x20\x01\xcd\xba\x00\x00\x00\x00\x00\x00\x00\x00\x32\x57\x96\x52"}, + {AF_INET6, 1, 0, + "2001:cdba::3257:9652", "2001:cdba::3257:9652", + "\x20\x01\xcd\xba\x00\x00\x00\x00\x00\x00\x00\x00\x32\x57\x96\x52"}, + {AF_INET6, 1, 0, + "2001:cdba:0:0:0:0:3257:9652", "2001:cdba::3257:9652", + "\x20\x01\xcd\xba\x00\x00\x00\x00\x00\x00\x00\x00\x32\x57\x96\x52"} + }; + int i, ret; + DWORD err; + char buffer[64],str[64]; + const char *ptr; + + /* InetNtop and InetPton became available in Vista and Win2008 */ + if (!pInetNtop || !pInetPton) + { + win_skip("InetNtop and/or InetPton not present, not executing tests\n"); + return; + } + + for (i = 0; i < sizeof(tests) / sizeof(tests[0]); i++) + { + WSASetLastError(0xdeadbeef); + ret = pInetPton(tests[i].family, (char *)tests[i].printable, buffer); + ok (ret == tests[i].ret, "Test [%d]: Expected %d, got %d\n", i, tests[i].ret, ret); + if (tests[i].ret == -1) + { + err = WSAGetLastError(); + ok (tests[i].err == err, "Test [%d]: Expected 0x%x, got 0x%x\n", i, tests[i].err, err); + } + if (tests[i].ret != 1) continue; + ok (memcmp(buffer, tests[i].raw_data, + tests[i].family == AF_INET ? sizeof(struct in_addr) : sizeof(struct in6_addr)) == 0, + "Test [%d]: Expected binary data differs\n", i); + + /* Test the result from Pton with Ntop */ + strcpy (str, "deadbeef"); + ptr = pInetNtop(tests[i].family, buffer, str, sizeof(str)); + ok (ptr != NULL, "Test [%d]: Failed with NULL\n", i); + ok (ptr == str, "Test [%d]: Pointers differ (%p != %p)\n", i, ptr, str); + if (!ptr) continue; + ok (strcmp(ptr, tests[i].collapsed) == 0, "Test [%d]: Expected '%s', got '%s'\n", + i, tests[i].collapsed, ptr); + } +} static void test_ioctlsocket(void) { @@ -7462,6 +7575,63 @@ CloseHandle(previous_port); } +static void test_address_list_query(void) +{ + SOCKET_ADDRESS_LIST *address_list; + DWORD bytes_returned, size; + unsigned int i; + SOCKET s; + int ret; + + s = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP); + ok(s != INVALID_SOCKET, "Failed to create socket, error %d.\n", WSAGetLastError()); + + bytes_returned = 0; + ret = WSAIoctl(s, SIO_ADDRESS_LIST_QUERY, NULL, 0, NULL, 0, &bytes_returned, NULL, NULL); + ok(ret == SOCKET_ERROR, "Got unexpected ret %d.\n", ret); + ok(WSAGetLastError() == WSAEFAULT, "Got unexpected error %d.\n", WSAGetLastError()); + ok(bytes_returned >= FIELD_OFFSET(SOCKET_ADDRESS_LIST, Address[0]), + "Got unexpected bytes_returned %u.\n", bytes_returned); + + size = bytes_returned; + bytes_returned = 0; + address_list = HeapAlloc(GetProcessHeap(), 0, size * 2); + ret = WSAIoctl(s, SIO_ADDRESS_LIST_QUERY, NULL, 0, address_list, size * 2, &bytes_returned, NULL, NULL); + ok(!ret, "Got unexpected ret %d, error %d.\n", ret, WSAGetLastError()); + ok(bytes_returned == size, "Got unexpected bytes_returned %u, expected %u.\n", bytes_returned, size); + + bytes_returned = FIELD_OFFSET(SOCKET_ADDRESS_LIST, Address[address_list->iAddressCount]); + for (i = 0; i < address_list->iAddressCount; ++i) + { + bytes_returned += address_list->Address[i].iSockaddrLength; + } + ok(size == bytes_returned, "Got unexpected size %u, expected %u.\n", size, bytes_returned); + + ret = WSAIoctl(s, SIO_ADDRESS_LIST_QUERY, NULL, 0, address_list, size, NULL, NULL, NULL); + ok(ret == SOCKET_ERROR, "Got unexpected ret %d.\n", ret); + ok(WSAGetLastError() == WSAEFAULT, "Got unexpected error %d.\n", WSAGetLastError()); + + bytes_returned = 0xdeadbeef; + ret = WSAIoctl(s, SIO_ADDRESS_LIST_QUERY, NULL, 0, NULL, size, &bytes_returned, NULL, NULL); + ok(ret == SOCKET_ERROR, "Got unexpected ret %d.\n", ret); + ok(WSAGetLastError() == WSAEFAULT, "Got unexpected error %d.\n", WSAGetLastError()); + ok(bytes_returned == size, "Got unexpected bytes_returned %u, expected %u.\n", bytes_returned, size); + + ret = WSAIoctl(s, SIO_ADDRESS_LIST_QUERY, NULL, 0, address_list, 1, &bytes_returned, NULL, NULL); + ok(ret == SOCKET_ERROR, "Got unexpected ret %d.\n", ret); + ok(WSAGetLastError() == WSAEINVAL, "Got unexpected error %d.\n", WSAGetLastError()); + ok(bytes_returned == 0, "Got unexpected bytes_returned %u.\n", bytes_returned); + + ret = WSAIoctl(s, SIO_ADDRESS_LIST_QUERY, NULL, 0, address_list, + FIELD_OFFSET(SOCKET_ADDRESS_LIST, Address[0]), &bytes_returned, NULL, NULL); + ok(ret == SOCKET_ERROR, "Got unexpected ret %d.\n", ret); + ok(WSAGetLastError() == WSAEFAULT, "Got unexpected error %d.\n", WSAGetLastError()); + ok(bytes_returned == size, "Got unexpected bytes_returned %u, expected %u.\n", bytes_returned, size); + + HeapFree(GetProcessHeap(), 0, address_list); + closesocket(s); +} + static DWORD WINAPI inet_ntoa_thread_proc(void *param) { ULONG addr; @@ -7682,6 +7852,7 @@ Init(); test_inet_ntoa(); + test_inet_pton(); test_set_getsockopt(); test_so_reuseaddr(); test_ip_pktinfo(); @@ -7739,6 +7910,7 @@ test_WSAAsyncGetServByName(); test_completion_port(); + test_address_list_query(); /* this is an io heavy test, do it at the end so the kernel doesn't start dropping packets */ test_send(); diff -Nru wine1.7-1.7.28/dlls/ws2_32/ws2_32.spec wine1.7-1.7.31/dlls/ws2_32/ws2_32.spec --- wine1.7-1.7.28/dlls/ws2_32/ws2_32.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/ws2_32/ws2_32.spec 2014-11-14 13:28:17.000000000 +0000 @@ -121,3 +121,4 @@ @ stdcall getaddrinfo(str str ptr ptr) WS_getaddrinfo @ stdcall getnameinfo(ptr long ptr long ptr long long) WS_getnameinfo @ stdcall inet_ntop(long ptr ptr long) WS_inet_ntop +@ stdcall inet_pton(long ptr ptr) WS_inet_pton diff -Nru wine1.7-1.7.28/dlls/wsnmp32/wsnmp32.c wine1.7-1.7.31/dlls/wsnmp32/wsnmp32.c --- wine1.7-1.7.28/dlls/wsnmp32/wsnmp32.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wsnmp32/wsnmp32.c 2014-11-14 13:28:17.000000000 +0000 @@ -45,6 +45,12 @@ return SNMPAPI_SUCCESS; } +HSNMP_SESSION WINAPI SnmpOpen( HWND hwnd, UINT msg ) +{ + FIXME( "%p %u\n", hwnd, msg ); + return SNMPAPI_FAILURE; +} + SNMPAPI_STATUS WINAPI SnmpSetRetransmitMode( smiUINT32 retransmit_mode ) { FIXME( "%u\n", retransmit_mode ); diff -Nru wine1.7-1.7.28/dlls/wsnmp32/wsnmp32.spec wine1.7-1.7.31/dlls/wsnmp32/wsnmp32.spec --- wine1.7-1.7.28/dlls/wsnmp32/wsnmp32.spec 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wsnmp32/wsnmp32.spec 2014-11-14 13:28:17.000000000 +0000 @@ -11,7 +11,7 @@ 120 stub SnmpGetVendorInfo 200 stdcall SnmpStartup(ptr ptr ptr ptr ptr) 201 stdcall SnmpCleanup() -202 stub SnmpOpen +202 stdcall SnmpOpen(ptr long) 203 stub SnmpClose 204 stub SnmpSendMsg 205 stub SnmpRecvMsg diff -Nru wine1.7-1.7.28/dlls/wsock32/protocol.c wine1.7-1.7.31/dlls/wsock32/protocol.c --- wine1.7-1.7.28/dlls/wsock32/protocol.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/wsock32/protocol.c 2014-11-14 13:28:17.000000000 +0000 @@ -191,7 +191,7 @@ pi[i].dwMessageSize = wsabuf[i].dwMessageSize; memcpy((char *)buffer + string_offset, wsabuf[i].szProtocol, string_size); - pi[i].lpProtocol = (WCHAR *)(char *)buffer + string_offset; + pi[i].lpProtocol = (WCHAR *)((char *)buffer + string_offset); string_offset += string_size; } HeapFree(GetProcessHeap(), 0, wsabuf); diff -Nru wine1.7-1.7.28/dlls/xmllite/tests/reader.c wine1.7-1.7.31/dlls/xmllite/tests/reader.c --- wine1.7-1.7.28/dlls/xmllite/tests/reader.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/dlls/xmllite/tests/reader.c 2014-11-14 13:28:17.000000000 +0000 @@ -758,7 +758,7 @@ ok(!lstrcmpW(name_val[i].val, val), "expected %s, got %s\n", wine_dbgstr_w(name_val[i].val), wine_dbgstr_w(val)); hr = IXmlReader_MoveToNextAttribute(reader); - ok(hr == (i < count - 1) ? S_OK : S_FALSE, "got %08x\n", hr); + ok(hr == ((i < count - 1) ? S_OK : S_FALSE), "got %08x\n", hr); } hr = IXmlReader_GetDepth(reader, &count); diff -Nru wine1.7-1.7.28/include/bcrypt.h wine1.7-1.7.31/include/bcrypt.h --- wine1.7-1.7.28/include/bcrypt.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/bcrypt.h 2014-11-14 13:28:17.000000000 +0000 @@ -48,6 +48,7 @@ } BCRYPT_ALGORITHM_IDENTIFIER; typedef PVOID BCRYPT_ALG_HANDLE; +typedef PVOID BCRYPT_HANDLE; #define BCRYPT_RNG_USE_ENTROPY_IN_BUFFER 0x00000001 #define BCRYPT_USE_SYSTEM_PREFERRED_RNG 0x00000002 diff -Nru wine1.7-1.7.28/include/d2d1.idl wine1.7-1.7.31/include/d2d1.idl --- wine1.7-1.7.28/include/d2d1.idl 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/d2d1.idl 2014-11-14 13:28:17.000000000 +0000 @@ -37,7 +37,10 @@ interface IWICBitmapSource; interface IWICBitmap; +cpp_quote("#ifndef __dwrite_h__") +/* already defined in dwrite.h but needed for WIDL */ typedef struct DWRITE_GLYPH_RUN DWRITE_GLYPH_RUN; +cpp_quote("#endif /* __dwrite_h__ */") typedef D2D_POINT_2F D2D1_POINT_2F; typedef D2D_MATRIX_3X2_F D2D1_MATRIX_3X2_F; diff -Nru wine1.7-1.7.28/include/d3d9.h wine1.7-1.7.31/include/d3d9.h --- wine1.7-1.7.28/include/d3d9.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/d3d9.h 2014-11-14 13:28:17.000000000 +0000 @@ -62,6 +62,8 @@ #define D3D_SDK_VERSION 32 #define D3DADAPTER_DEFAULT 0 #define D3DENUM_NO_WHQL_LEVEL __MSABI_LONG(0x00000002) +#define D3DPRESENT_DONOTWAIT __MSABI_LONG(1) +#define D3DPRESENT_LINEAR_CONTENT __MSABI_LONG(2) #define D3DPRESENT_BACK_BUFFERS_MAX __MSABI_LONG(3) #define D3DSGR_NO_CALIBRATION __MSABI_LONG(0x00000000) #define D3DSGR_CALIBRATE __MSABI_LONG(0x00000001) diff -Nru wine1.7-1.7.28/include/d3dx9shape.h wine1.7-1.7.31/include/d3dx9shape.h --- wine1.7-1.7.28/include/d3dx9shape.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/d3dx9shape.h 2014-11-14 13:28:17.000000000 +0000 @@ -29,6 +29,8 @@ float depth, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency); HRESULT WINAPI D3DXCreateCylinder(struct IDirect3DDevice9 *device, float radius1, float radius2, float length, UINT slices, UINT stacks, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency); +HRESULT WINAPI D3DXCreatePolygon(struct IDirect3DDevice9 *device, float length, UINT sides, struct ID3DXMesh **mesh, + ID3DXBuffer **adjacency); HRESULT WINAPI D3DXCreateSphere(struct IDirect3DDevice9 *device, float radius, UINT slices, UINT stacks, struct ID3DXMesh **mesh, struct ID3DXBuffer **adjacency); HRESULT WINAPI D3DXCreateTeapot(struct IDirect3DDevice9 *device, diff -Nru wine1.7-1.7.28/include/ddk/ntddk.h wine1.7-1.7.31/include/ddk/ntddk.h --- wine1.7-1.7.28/include/ddk/ntddk.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/ddk/ntddk.h 2014-11-14 13:28:17.000000000 +0000 @@ -127,11 +127,20 @@ ULONG ImageSectionNumber; } IMAGE_INFO, *PIMAGE_INFO; +typedef enum _IO_NOTIFICATION_EVENT_CATEGORY +{ + EventCategoryReserved, + EventCategoryHardwareProfileChange, + EventCategoryDeviceInterfaceChange, + EventCategoryTargetDeviceChange +} IO_NOTIFICATION_EVENT_CATEGORY; + typedef struct _FILE_VALID_DATA_LENGTH_INFORMATION { LARGE_INTEGER ValidDataLength; } FILE_VALID_DATA_LENGTH_INFORMATION, *PFILE_VALID_DATA_LENGTH_INFORMATION; +typedef VOID (WINAPI *PDRIVER_NOTIFICATION_CALLBACK_ROUTINE)(PVOID,PVOID); typedef VOID (WINAPI *PDRIVER_REINITIALIZE)(PDRIVER_OBJECT,PVOID,ULONG); typedef VOID (WINAPI *PLOAD_IMAGE_NOTIFY_ROUTINE)(PUNICODE_STRING,HANDLE,PIMAGE_INFO); typedef NTSTATUS (WINAPI *PIO_QUERY_DEVICE_ROUTINE)(PVOID,PUNICODE_STRING,INTERFACE_TYPE,ULONG, diff -Nru wine1.7-1.7.28/include/ddk/ntifs.h wine1.7-1.7.31/include/ddk/ntifs.h --- wine1.7-1.7.28/include/ddk/ntifs.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/ddk/ntifs.h 2014-11-14 13:28:17.000000000 +0000 @@ -28,4 +28,6 @@ LIST_ENTRY ThreadListHead; } KQUEUE, *PKQUEUE, *RESTRICTED_POINTER PRKQUEUE; +NTSTATUS WINAPI ObQueryNameString(PVOID,POBJECT_NAME_INFORMATION,ULONG,PULONG); + #endif diff -Nru wine1.7-1.7.28/include/dwrite_1.idl wine1.7-1.7.31/include/dwrite_1.idl --- wine1.7-1.7.28/include/dwrite_1.idl 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/dwrite_1.idl 2014-11-14 13:28:17.000000000 +0000 @@ -593,7 +593,7 @@ ] interface IDWriteFontFace1 : IDWriteFontFace { - HRESULT GetMetrics(DWRITE_FONT_METRICS1 *metrics); + void GetMetrics(DWRITE_FONT_METRICS1 *metrics); HRESULT GetGdiCompatibleMetrics(FLOAT em_size, FLOAT pixels_per_dip, const DWRITE_MATRIX *transform, diff -Nru wine1.7-1.7.28/include/dwrite.idl wine1.7-1.7.31/include/dwrite.idl --- wine1.7-1.7.28/include/dwrite.idl 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/dwrite.idl 2014-11-14 13:28:17.000000000 +0000 @@ -222,6 +222,12 @@ DWRITE_LINE_SPACING_METHOD_UNIFORM } DWRITE_LINE_SPACING_METHOD; +cpp_quote("#define DWRITE_MAKE_OPENTYPE_TAG(a,b,c,d) ( \\") +cpp_quote(" ((UINT32)(UINT8)(d) << 24) | \\") +cpp_quote(" ((UINT32)(UINT8)(c) << 16) | \\") +cpp_quote(" ((UINT32)(UINT8)(b) << 8) | \\") +cpp_quote(" (UINT32)(UINT8)(a))") + typedef enum DWRITE_FONT_FEATURE_TAG { DWRITE_FONT_FEATURE_TAG_ALTERNATIVE_FRACTIONS = 0x63726661, /* 'afrc' */ @@ -376,7 +382,11 @@ UINT32 delimiterCount; } DWRITE_TRIMMING; -typedef struct DWRITE_GLYPH_RUN +cpp_quote("#ifndef __d2d1_h__") +typedef struct DWRITE_GLYPH_RUN DWRITE_GLYPH_RUN; +cpp_quote("#endif /* __d2d1_h__ */") + +struct DWRITE_GLYPH_RUN { IDWriteFontFace* fontFace; FLOAT fontEmSize; @@ -386,7 +396,7 @@ DWRITE_GLYPH_OFFSET const* glyphOffsets; BOOL isSideways; UINT32 bidiLevel; -} DWRITE_GLYPH_RUN; +}; typedef struct DWRITE_GLYPH_RUN_DESCRIPTION { diff -Nru wine1.7-1.7.28/include/msvcrt/stdio.h wine1.7-1.7.31/include/msvcrt/stdio.h --- wine1.7-1.7.28/include/msvcrt/stdio.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/msvcrt/stdio.h 2014-11-14 13:28:17.000000000 +0000 @@ -127,6 +127,21 @@ int __cdecl _vsnprintf_s(char*,size_t,size_t,const char*,__ms_va_list); int __cdecl _vsprintf_p_l(char*,size_t,const char*,_locale_t,__ms_va_list); +size_t __cdecl _fread_nolock(void*,size_t,size_t,FILE*); +size_t __cdecl _fread_nolock_s(void*,size_t,size_t,size_t,FILE*); +size_t __cdecl _fwrite_nolock(const void*,size_t,size_t,FILE*); +int __cdecl _fclose_nolock(FILE*); +int __cdecl _fflush_nolock(FILE*); +int __cdecl _fgetc_nolock(FILE*); +int __cdecl _fputc_nolock(int,FILE*); +int __cdecl _fseek_nolock(FILE*,__msvcrt_long,int); +int __cdecl _fseeki64_nolock(FILE*,__int64,int); +__msvcrt_long __cdecl _ftell_nolock(FILE*); +__int64 __cdecl _ftelli64_nolock(FILE*); +int __cdecl _getc_nolock(FILE*); +int __cdecl _putc_nolock(int,FILE*); +int __cdecl _ungetc_nolock(int,FILE*); + void __cdecl clearerr(FILE*); int __cdecl fclose(FILE*); int __cdecl feof(FILE*); @@ -142,6 +157,7 @@ int __cdecl fputc(int,FILE*); int __cdecl fputs(const char*,FILE*); size_t __cdecl fread(void*,size_t,size_t,FILE*); +size_t __cdecl fread_s(void*,size_t,size_t,size_t,FILE*); FILE* __cdecl freopen(const char*,const char*,FILE*); int __cdecl fscanf(FILE*,const char*,...); int __cdecl fscanf_s(FILE*,const char*,...); @@ -186,13 +202,18 @@ #ifndef _WSTDIO_DEFINED #define _WSTDIO_DEFINED +wint_t __cdecl _fgetwc_nolock(FILE*); wint_t __cdecl _fgetwchar(void); +wint_t __cdecl _fputwc_nolock(wint_t,FILE*); wint_t __cdecl _fputwchar(wint_t); +wint_t __cdecl _getwc_nolock(FILE*); wchar_t* __cdecl _getws(wchar_t*); +wint_t __cdecl _putwc_nolock(wint_t,FILE*); int __cdecl _putws(const wchar_t*); int __cdecl _snwprintf(wchar_t*,size_t,const wchar_t*,...); int __cdecl _snwprintf_s(wchar_t*,size_t,size_t,const wchar_t*,...); int __cdecl _scwprintf(const wchar_t*,...); +wint_t __cdecl _ungetwc_nolock(wint_t,FILE*); int __cdecl _vscwprintf(const wchar_t*,__ms_va_list); int __cdecl _vscwprintf_p_l(const wchar_t*,_locale_t,__ms_va_list); int __cdecl _vsnwprintf(wchar_t*,size_t,const wchar_t*,__ms_va_list); diff -Nru wine1.7-1.7.28/include/msvcrt/wchar.h wine1.7-1.7.31/include/msvcrt/wchar.h --- wine1.7-1.7.28/include/msvcrt/wchar.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/msvcrt/wchar.h 2014-11-14 13:28:17.000000000 +0000 @@ -313,12 +313,18 @@ #ifndef _WSTDIO_DEFINED #define _WSTDIO_DEFINED +wint_t __cdecl _fgetwc_nolock(FILE*); wint_t __cdecl _fgetwchar(void); +wint_t __cdecl _fputwc_nolock(wint_t,FILE*); wint_t __cdecl _fputwchar(wint_t); +wint_t __cdecl _getwc_nolock(FILE*); wchar_t* __cdecl _getws(wchar_t*); +wint_t __cdecl _putwc_nolock(wint_t,FILE*); int __cdecl _putws(const wchar_t*); int __cdecl _snwprintf(wchar_t*,size_t,const wchar_t*,...); int __cdecl _snwprintf_s(wchar_t*,size_t,size_t,const wchar_t*,...); +int __cdecl _scwprintf(const wchar_t*,...); +wint_t __cdecl _ungetwc_nolock(wint_t,FILE*); int __cdecl _vscwprintf(const wchar_t*,__ms_va_list); int __cdecl _vscwprintf_p_l(const wchar_t*,_locale_t,__ms_va_list); int __cdecl _vsnwprintf(wchar_t*,size_t,const wchar_t*,__ms_va_list); diff -Nru wine1.7-1.7.28/include/slpublic.h wine1.7-1.7.31/include/slpublic.h --- wine1.7-1.7.28/include/slpublic.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/slpublic.h 2014-11-14 13:28:17.000000000 +0000 @@ -29,7 +29,18 @@ #define SLCAPI DECLSPEC_IMPORT #endif -SLCAPI DWORD WINAPI SLGetWindowsInformationDWORD(LPCWSTR lpszValueName, LPDWORD pdwValue); +typedef enum _tagSLDATATYPE +{ + SL_DATA_NONE = REG_NONE, + SL_DATA_SZ = REG_SZ, + SL_DATA_DWORD = REG_DWORD, + SL_DATA_BINARY = REG_BINARY, + SL_DATA_MULTI_SZ = REG_MULTI_SZ, + SL_DATA_SUM = 100, +} SLDATATYPE; + +SLCAPI HRESULT WINAPI SLGetWindowsInformation(LPCWSTR, SLDATATYPE*, UINT*, LPBYTE*); +SLCAPI HRESULT WINAPI SLGetWindowsInformationDWORD(LPCWSTR, LPDWORD); #ifdef __cplusplus diff -Nru wine1.7-1.7.28/include/winbase.h wine1.7-1.7.31/include/winbase.h --- wine1.7-1.7.28/include/winbase.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/winbase.h 2014-11-14 13:28:17.000000000 +0000 @@ -1449,6 +1449,9 @@ OptOut = 3 } DEP_SYSTEM_POLICY_TYPE; +#define PROCESS_DEP_ENABLE 1 +#define PROCESS_DEP_DISABLE_ATL_THUNK_EMULATION 2 + /* Event Logging */ #define EVENTLOG_FULL_INFO 0 diff -Nru wine1.7-1.7.28/include/wine/server_protocol.h wine1.7-1.7.31/include/wine/server_protocol.h --- wine1.7-1.7.28/include/wine/server_protocol.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/wine/server_protocol.h 2014-11-14 13:28:17.000000000 +0000 @@ -2960,7 +2960,7 @@ struct request_header __header; unsigned int hw_id; int remove; - user_handle_t new_win; + char __pad_20[4]; }; struct accept_hardware_message_reply { @@ -3146,17 +3146,15 @@ struct request_header __header; unsigned int access; unsigned int attributes; - obj_handle_t rootdir; unsigned int options; unsigned int sharing; unsigned int maxinstances; unsigned int outsize; unsigned int insize; - char __pad_44[4]; timeout_t timeout; unsigned int flags; - /* VARARG(name,unicode_str); */ - char __pad_60[4]; + /* VARARG(objattr,object_attributes); */ + char __pad_52[4]; }; struct create_named_pipe_reply { @@ -5849,6 +5847,6 @@ struct set_suspend_context_reply set_suspend_context_reply; }; -#define SERVER_PROTOCOL_VERSION 457 +#define SERVER_PROTOCOL_VERSION 458 #endif /* __WINE_WINE_SERVER_PROTOCOL_H */ diff -Nru wine1.7-1.7.28/include/wine/wined3d.h wine1.7-1.7.31/include/wine/wined3d.h --- wine1.7-1.7.28/include/wine/wined3d.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/wine/wined3d.h 2014-11-14 13:28:17.000000000 +0000 @@ -241,6 +241,7 @@ WINED3DFMT_MULTI2_ARGB8 = WINEMAKEFOURCC('M','E','T','1'), WINED3DFMT_G8R8_G8B8 = WINEMAKEFOURCC('G','R','G','B'), WINED3DFMT_R8G8_B8G8 = WINEMAKEFOURCC('R','G','B','G'), + WINED3DFMT_ATI1N = WINEMAKEFOURCC('A','T','I','1'), WINED3DFMT_ATI2N = WINEMAKEFOURCC('A','T','I','2'), WINED3DFMT_INST = WINEMAKEFOURCC('I','N','S','T'), WINED3DFMT_NVDB = WINEMAKEFOURCC('N','V','D','B'), @@ -933,6 +934,12 @@ #define WINED3DCREATE_MIXED_VERTEXPROCESSING 0x00000080 #define WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT 0x00000100 #define WINED3DCREATE_ADAPTERGROUP_DEVICE 0x00000200 +#define WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT_EX 0x00000400 +#define WINED3DCREATE_NOWINDOWCHANGES 0x00000800 +#define WINED3DCREATE_DISABLE_PSGP_THREADING 0x00002000 +#define WINED3DCREATE_ENABLE_PRESENTSTATS 0x00004000 +#define WINED3DCREATE_DISABLE_PRINTSCREEN 0x00008000 +#define WINED3DCREATE_SCREENSAVER 0x10000000 /* VTF defines */ #define WINED3DDMAPSAMPLER 0x100 @@ -1970,7 +1977,14 @@ { UINT element_count; struct wined3d_shader_signature_element *elements; - char *string_data; +}; + +struct wined3d_shader_desc +{ + const DWORD *byte_code; + const struct wined3d_shader_signature *input_signature; + const struct wined3d_shader_signature *output_signature; + unsigned int max_version; }; struct wined3d_parent_ops @@ -2412,15 +2426,12 @@ void * __cdecl wined3d_sampler_get_parent(const struct wined3d_sampler *sampler); ULONG __cdecl wined3d_sampler_incref(struct wined3d_sampler *sampler); -HRESULT __cdecl wined3d_shader_create_gs(struct wined3d_device *device, const DWORD *byte_code, - const struct wined3d_shader_signature *output_signature, void *parent, - const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader, unsigned int max_version); -HRESULT __cdecl wined3d_shader_create_ps(struct wined3d_device *device, const DWORD *byte_code, - const struct wined3d_shader_signature *output_signature, void *parent, - const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader, unsigned int max_version); -HRESULT __cdecl wined3d_shader_create_vs(struct wined3d_device *device, const DWORD *byte_code, - const struct wined3d_shader_signature *output_signature, void *parent, - const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader, unsigned int max_version); +HRESULT __cdecl wined3d_shader_create_gs(struct wined3d_device *device, const struct wined3d_shader_desc *desc, + void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader); +HRESULT __cdecl wined3d_shader_create_ps(struct wined3d_device *device, const struct wined3d_shader_desc *desc, + void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader); +HRESULT __cdecl wined3d_shader_create_vs(struct wined3d_device *device, const struct wined3d_shader_desc *desc, + void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader); ULONG __cdecl wined3d_shader_decref(struct wined3d_shader *shader); HRESULT __cdecl wined3d_shader_get_byte_code(const struct wined3d_shader *shader, void *byte_code, UINT *byte_code_size); diff -Nru wine1.7-1.7.28/include/winnls.h wine1.7-1.7.31/include/winnls.h --- wine1.7-1.7.28/include/winnls.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/winnls.h 2014-11-14 13:28:17.000000000 +0000 @@ -835,6 +835,7 @@ WINBASEAPI INT WINAPI GetLocaleInfoA(LCID,LCTYPE,LPSTR,INT); WINBASEAPI INT WINAPI GetLocaleInfoW(LCID,LCTYPE,LPWSTR,INT); #define GetLocaleInfo WINELIB_NAME_AW(GetLocaleInfo) +WINBASEAPI INT WINAPI GetLocaleInfoEx(LPCWSTR,LCTYPE,LPWSTR,INT); WINBASEAPI INT WINAPI GetNumberFormatA(LCID,DWORD,LPCSTR,const NUMBERFMTA*,LPSTR,INT); WINBASEAPI INT WINAPI GetNumberFormatW(LCID,DWORD,LPCWSTR,const NUMBERFMTW*,LPWSTR,INT); #define GetNumberFormat WINELIB_NAME_AW(GetNumberFormat) diff -Nru wine1.7-1.7.28/include/winsnmp.h wine1.7-1.7.31/include/winsnmp.h --- wine1.7-1.7.28/include/winsnmp.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/winsnmp.h 2014-11-14 13:28:17.000000000 +0000 @@ -27,6 +27,7 @@ typedef smiINT smiINT32, *smiLPINT32; typedef unsigned int smiUINT32, *smiLPUINT32; typedef smiUINT32 SNMPAPI_STATUS; +typedef HANDLE HSNMP_SESSION; #define SNMPAPI_NO_SUPPORT 0 #define SNMPAPI_V1_SUPPORT 1 @@ -44,6 +45,7 @@ #define SNMPAPI_SUCCESS 1 SNMPAPI_STATUS WINAPI SnmpCleanup(void); +HSNMP_SESSION WINAPI SnmpOpen(HWND,UINT); SNMPAPI_STATUS WINAPI SnmpSetRetransmitMode(smiUINT32); SNMPAPI_STATUS WINAPI SnmpSetTranslateMode(smiUINT32); SNMPAPI_STATUS WINAPI SnmpStartup(smiLPUINT32,smiLPUINT32,smiLPUINT32,smiLPUINT32,smiLPUINT32); diff -Nru wine1.7-1.7.28/include/winternl.h wine1.7-1.7.31/include/winternl.h --- wine1.7-1.7.28/include/winternl.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/winternl.h 2014-11-14 13:28:17.000000000 +0000 @@ -728,6 +728,7 @@ #define MEM_EXECUTE_OPTION_DISABLE 0x01 #define MEM_EXECUTE_OPTION_ENABLE 0x02 +#define MEM_EXECUTE_OPTION_DISABLE_THUNK_EMULATION 0x04 #define MEM_EXECUTE_OPTION_PERMANENT 0x08 typedef enum _SECTION_INHERIT { diff -Nru wine1.7-1.7.28/include/wpcapi.idl wine1.7-1.7.31/include/wpcapi.idl --- wine1.7-1.7.28/include/wpcapi.idl 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/include/wpcapi.idl 2014-11-14 13:28:17.000000000 +0000 @@ -19,6 +19,15 @@ import "oaidl.idl"; import "ocidl.idl"; +typedef [v1_enum] enum tagWPCFLAG_RESTRICTION { + WPCFLAG_NO_RESTRICTION = 0x0000, + WPCFLAG_LOGGING_REQUIRED = 0x0001, + WPCFLAG_WEB_FILTERED = 0x0002, + WPCFLAG_HOURS_RESTRICTED = 0x0004, + WPCFLAG_GAMES_BLOCKED = 0x0008, + WPCFLAG_APPS_RESTRICTED = 0x0010 +} WPCFLAG_RESTRICTION; + [ uuid(8fdf6ca1-0189-47e4-b670-1a8a4636e340), object diff -Nru wine1.7-1.7.28/loader/wine.inf.in wine1.7-1.7.31/loader/wine.inf.in --- wine1.7-1.7.28/loader/wine.inf.in 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/loader/wine.inf.in 2014-11-14 13:28:17.000000000 +0000 @@ -2490,6 +2490,7 @@ 11,,iexplore.exe 11,,winetest.exe,- 12,,mountmgr.sys,- +12,,ndis.sys,- ; skip .NET fake dlls in Wine Mono package 11,,aspnet_regiis.exe,- 11,,ngen.exe,- @@ -2527,6 +2528,7 @@ 11,,notepad.exe 11,,winetest.exe,- 12,,mountmgr.sys +12,,ndis.sys ; skip .NET fake dlls in Wine Mono package 11,,aspnet_regiis.exe,- 11,,ngen.exe,- diff -Nru wine1.7-1.7.28/po/de.po wine1.7-1.7.31/po/de.po --- wine1.7-1.7.28/po/de.po 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/po/de.po 2014-11-14 13:28:17.000000000 +0000 @@ -5,7 +5,7 @@ "Project-Id-Version: Wine\n" "Report-Msgid-Bugs-To: http://bugs.winehq.org\n" "POT-Creation-Date: N/A\n" -"PO-Revision-Date: 2014-08-13 01:33+0200\n" +"PO-Revision-Date: 2014-10-06 21:51+0200\n" "Last-Translator: Julian Rüger\n" "Language-Team: none\n" "Language: German\n" @@ -850,7 +850,7 @@ #: comdlg32.rc:40 msgid "The selection contains a non-folder object" -msgstr "" +msgstr "Die Auswahl enthält ein Objekt, das kein Ordner ist" #: comdlg32.rc:45 msgid "Up One Level" @@ -3547,16 +3547,12 @@ msgstr "')' erwartet" #: jscript.rc:40 -#, fuzzy -#| msgid "Subject Key Identifier" msgid "Expected identifier" -msgstr "Schlüsselkennung des Antragstellers" +msgstr "Bezeichner erwartet" #: jscript.rc:41 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '='" -msgstr "';' erwartet" +msgstr "'=' erwartet" #: jscript.rc:42 msgid "Invalid character" @@ -3587,20 +3583,16 @@ msgstr "Label nicht gefunden" #: jscript.rc:49 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '@end'" -msgstr "';' erwartet" +msgstr "'@end' erwartet" #: jscript.rc:50 msgid "Conditional compilation is turned off" msgstr "Bedingte Kompilierung ist ausgeschaltet" #: jscript.rc:51 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '@'" -msgstr "';' erwartet" +msgstr "'@' erwartet" #: jscript.rc:54 msgid "Number expected" diff -Nru wine1.7-1.7.28/po/lt.po wine1.7-1.7.31/po/lt.po --- wine1.7-1.7.28/po/lt.po 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/po/lt.po 2014-11-14 13:28:17.000000000 +0000 @@ -5,7 +5,7 @@ "Project-Id-Version: Wine\n" "Report-Msgid-Bugs-To: http://bugs.winehq.org\n" "POT-Creation-Date: N/A\n" -"PO-Revision-Date: 2014-08-05 21:59+0300\n" +"PO-Revision-Date: 2014-10-04 10:00+0300\n" "Last-Translator: Aurimas Fišeras \n" "Language-Team: komp_lt@konf.lt\n" "Language: Lithuanian\n" @@ -3543,16 +3543,12 @@ msgstr "Tikėtasi „)“" #: jscript.rc:40 -#, fuzzy -#| msgid "Subject Key Identifier" msgid "Expected identifier" -msgstr "Subjekto rakto identifikatorius" +msgstr "Tikėtasi identifikatoriaus" #: jscript.rc:41 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '='" -msgstr "Tikėtasi „;“" +msgstr "Tikėtasi „=“" #: jscript.rc:42 msgid "Invalid character" @@ -3583,20 +3579,16 @@ msgstr "Žymė nerasta" #: jscript.rc:49 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '@end'" -msgstr "Tikėtasi „;“" +msgstr "Tikėtasi „@end“" #: jscript.rc:50 msgid "Conditional compilation is turned off" msgstr "Sąlyginis kompiliavimas išjungtas" #: jscript.rc:51 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '@'" -msgstr "Tikėtasi „;“" +msgstr "Tikėtasi „@“" #: jscript.rc:54 msgid "Number expected" diff -Nru wine1.7-1.7.28/po/pt_BR.po wine1.7-1.7.31/po/pt_BR.po --- wine1.7-1.7.28/po/pt_BR.po 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/po/pt_BR.po 2014-11-14 13:28:17.000000000 +0000 @@ -1043,10 +1043,8 @@ msgstr "Abrir Arquivo" #: comdlg32.rc:147 -#, fuzzy -#| msgid "New Folder" msgid "Select Folder" -msgstr "Nova Pasta" +msgstr "Selecionar pasta" #: comdlg32.rc:83 oleview.rc:98 msgid "Ready" @@ -3554,16 +3552,12 @@ msgstr "')' esperado" #: jscript.rc:40 -#, fuzzy -#| msgid "Subject Key Identifier" msgid "Expected identifier" -msgstr "Identificador da Chave" +msgstr "Identificador esperado" #: jscript.rc:41 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '='" -msgstr "';' esperado" +msgstr "'=' esperado" #: jscript.rc:42 msgid "Invalid character" @@ -3594,20 +3588,16 @@ msgstr "Rótulo não encontrado" #: jscript.rc:49 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '@end'" -msgstr "';' esperado" +msgstr "'@end' esperado" #: jscript.rc:50 msgid "Conditional compilation is turned off" msgstr "Compilação condicional está desligada" #: jscript.rc:51 -#, fuzzy -#| msgid "Expected ';'" msgid "Expected '@'" -msgstr "';' esperado" +msgstr "'@' esperado" #: jscript.rc:54 msgid "Number expected" @@ -6635,10 +6625,8 @@ msgstr "Esta conexão de rede não existe.\n" #: winerror.mc:3746 -#, fuzzy -#| msgid "Connection refused.\n" msgid "Connection reset by peer.\n" -msgstr "Conexão recusada.\n" +msgstr "Conexão redefinida pelo cliente.\n" #: localspl.rc:31 localui.rc:31 winspool.rc:30 msgid "Local Port" @@ -7173,39 +7161,29 @@ msgstr "botão de contorno" #: oleacc.rc:97 -#, fuzzy -#| msgid "Normal" msgctxt "object state" msgid "normal" -msgstr "Normal" +msgstr "normal" #: oleacc.rc:98 -#, fuzzy -#| msgid "Unavailable" msgctxt "object state" msgid "unavailable" -msgstr "Indisponível" +msgstr "indisponível" #: oleacc.rc:99 -#, fuzzy -#| msgid "Select" msgctxt "object state" msgid "selected" -msgstr "Selecionar" +msgstr "selecionado" #: oleacc.rc:100 -#, fuzzy -#| msgid "Paused" msgctxt "object state" msgid "focused" -msgstr "Pausado" +msgstr "focado" #: oleacc.rc:101 -#, fuzzy -#| msgid "&Compressed" msgctxt "object state" msgid "pressed" -msgstr "&Comprimido" +msgstr "pressionado" #: oleacc.rc:102 msgctxt "object state" @@ -7213,32 +7191,24 @@ msgstr "" #: oleacc.rc:103 -#, fuzzy -#| msgid "Mixed" msgctxt "object state" msgid "mixed" -msgstr "Misturado" +msgstr "misturado" #: oleacc.rc:104 -#, fuzzy -#| msgid "&Read Only" msgctxt "object state" msgid "read only" -msgstr "&Apenas leitura" +msgstr "somente leitura" #: oleacc.rc:105 -#, fuzzy -#| msgid "Hot Tracked Item" msgctxt "object state" msgid "hot tracked" -msgstr "Elemento Ativo" +msgstr "elemento ativo" #: oleacc.rc:106 -#, fuzzy -#| msgid "Defaults" msgctxt "object state" msgid "default" -msgstr "Dispositivos Padrões" +msgstr "padrão" #: oleacc.rc:107 msgctxt "object state" @@ -7266,11 +7236,9 @@ msgstr "" #: oleacc.rc:112 -#, fuzzy -#| msgid "animation" msgctxt "object state" msgid "animated" -msgstr "animação" +msgstr "animado" #: oleacc.rc:113 msgctxt "object state" @@ -7283,18 +7251,14 @@ msgstr "" #: oleacc.rc:115 -#, fuzzy -#| msgid "&enable" msgctxt "object state" msgid "sizeable" -msgstr "&habilitar" +msgstr "expansível" #: oleacc.rc:116 -#, fuzzy -#| msgid "&enable" msgctxt "object state" msgid "moveable" -msgstr "&habilitar" +msgstr "movível" #: oleacc.rc:117 msgctxt "object state" @@ -7302,25 +7266,19 @@ msgstr "" #: oleacc.rc:118 -#, fuzzy -#| msgid "Paused" msgctxt "object state" msgid "focusable" -msgstr "Pausado" +msgstr "focável" #: oleacc.rc:119 -#, fuzzy -#| msgid "table" msgctxt "object state" msgid "selectable" -msgstr "tabela" +msgstr "selecionável" #: oleacc.rc:120 -#, fuzzy -#| msgid "link" msgctxt "object state" msgid "linked" -msgstr "atalho" +msgstr "ligado" #: oleacc.rc:121 msgctxt "object state" @@ -7328,46 +7286,34 @@ msgstr "" #: oleacc.rc:122 -#, fuzzy -#| msgid "table" msgctxt "object state" msgid "multi selectable" -msgstr "tabela" +msgstr "multi selecionável" #: oleacc.rc:123 -#, fuzzy -#| msgid "Please select a file." msgctxt "object state" msgid "extended selectable" -msgstr "Por favor, selecione um arquivo." +msgstr "seleção estendível" #: oleacc.rc:124 -#, fuzzy -#| msgid "alert" msgctxt "object state" msgid "alert low" -msgstr "alerta" +msgstr "alerta baixo" #: oleacc.rc:125 -#, fuzzy -#| msgid "alert" msgctxt "object state" msgid "alert medium" -msgstr "alerta" +msgstr "alerta médio" #: oleacc.rc:126 -#, fuzzy -#| msgid "alert" msgctxt "object state" msgid "alert high" -msgstr "alerta" +msgstr "alerta alto" #: oleacc.rc:127 -#, fuzzy -#| msgid "Write protected.\n" msgctxt "object state" msgid "protected" -msgstr "Protegido contra escrita.\n" +msgstr "protegido" #: oleacc.rc:128 msgctxt "object state" diff -Nru wine1.7-1.7.28/programs/cmd/builtins.c wine1.7-1.7.31/programs/cmd/builtins.c --- wine1.7-1.7.28/programs/cmd/builtins.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/cmd/builtins.c 2014-11-14 13:28:17.000000000 +0000 @@ -798,12 +798,12 @@ /* If parameter is a directory, ensure it ends in \ */ attributes = GetFileAttributesW(destname); - if ((destname[strlenW(destname) - 1] == '\\') || + if (ends_with_backslash( destname ) || ((attributes != INVALID_FILE_ATTRIBUTES) && (attributes & FILE_ATTRIBUTE_DIRECTORY))) { destisdirectory = TRUE; - if (!(destname[strlenW(destname) - 1] == '\\')) strcatW(destname, slashW); + if (!ends_with_backslash( destname )) strcatW(destname, slashW); WINE_TRACE("Directory, so full name is now '%s'\n", wine_dbgstr_w(destname)); } } @@ -880,7 +880,7 @@ /* If parameter is a directory, ensure it ends in \* */ attributes = GetFileAttributesW(srcpath); - if (srcpath[strlenW(srcpath) - 1] == '\\') { + if (ends_with_backslash( srcpath )) { /* We need to know where the filename part starts, so append * and recalculate the full resulting path */ diff -Nru wine1.7-1.7.28/programs/cmd/directory.c wine1.7-1.7.31/programs/cmd/directory.c --- wine1.7-1.7.28/programs/cmd/directory.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/cmd/directory.c 2014-11-14 13:28:17.000000000 +0000 @@ -833,13 +833,8 @@ if ((strchrW(path, '*') == NULL) && (strchrW(path, '%') == NULL)) { status = GetFileAttributesW(path); if ((status != INVALID_FILE_ATTRIBUTES) && (status & FILE_ATTRIBUTE_DIRECTORY)) { - if (path[strlenW(path)-1] == '\\') { - strcatW (path, starW); - } - else { - static const WCHAR slashStarW[] = {'\\','*','\0'}; - strcatW (path, slashStarW); - } + if (!ends_with_backslash( path )) strcatW( path, slashW ); + strcatW (path, starW); } } else { /* Special case wildcard search with no extension (ie parameters ending in '.') as diff -Nru wine1.7-1.7.28/programs/cmd/wcmd.h wine1.7-1.7.31/programs/cmd/wcmd.h --- wine1.7-1.7.28/programs/cmd/wcmd.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/cmd/wcmd.h 2014-11-14 13:28:17.000000000 +0000 @@ -148,6 +148,11 @@ return ret; } +static inline BOOL ends_with_backslash( const WCHAR *path ) +{ + return path[0] && path[strlenW(path) - 1] == '\\'; +} + /* Data structure to hold context when executing batch files */ typedef struct _BATCH_CONTEXT { diff -Nru wine1.7-1.7.28/programs/reg/tests/reg.c wine1.7-1.7.31/programs/reg/tests/reg.c --- wine1.7-1.7.28/programs/reg/tests/reg.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/reg/tests/reg.c 2014-11-14 13:28:17.000000000 +0000 @@ -88,9 +88,10 @@ static void test_add(void) { - HKEY hkey; + HKEY hkey, subkey; LONG err; DWORD r, dword, type, size; + char buffer[22]; run_reg_exe("reg add", &r); ok(r == REG_EXIT_FAILURE, "got exit code %d, expected 1\n", r); @@ -107,6 +108,49 @@ err = RegOpenKeyExA(HKEY_CURRENT_USER, KEY_BASE, 0, KEY_READ, &hkey); ok(err == ERROR_SUCCESS, "key creation failed, got %d\n", err); + /* Test empty type */ + run_reg_exe("reg add HKCU\\" KEY_BASE " /v emptyType /t \"\" /d WineTest /f", &r); + todo_wine ok(r == REG_EXIT_SUCCESS || broken(r == REG_EXIT_FAILURE /* WinXP */), + "got exit code %u\n", r); + if (r == REG_EXIT_SUCCESS) + todo_wine verify_reg(hkey, "emptyType", REG_SZ, "", 1, 0); + else + todo_wine win_skip("broken reg.exe detected\n"); + + /* Test input key formats */ + run_reg_exe("reg add \\HKCU\\" KEY_BASE "\\keytest0 /f", &r); + ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + err = RegDeleteKeyA(HKEY_CURRENT_USER, KEY_BASE "\\keytest0"); + ok(err == ERROR_FILE_NOT_FOUND, "got exit code %d\n", r); + + run_reg_exe("reg add \\\\HKCU\\" KEY_BASE "\\keytest1 /f", &r); + ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + err = RegDeleteKeyA(HKEY_CURRENT_USER, KEY_BASE "\\keytest1"); + ok(err == ERROR_FILE_NOT_FOUND, "got exit code %d\n", r); + + run_reg_exe("reg add HKCU\\" KEY_BASE "\\keytest2\\\\ /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS /* WinXP */), + "got exit code %u\n", r); + err = RegDeleteKeyA(HKEY_CURRENT_USER, KEY_BASE "\\keytest2"); + todo_wine ok(err == ERROR_FILE_NOT_FOUND || broken(err == ERROR_SUCCESS /* WinXP */), + "got exit code %d\n", r); + + run_reg_exe("reg add HKCU\\" KEY_BASE "\\keytest3\\ /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + err = RegOpenKeyExA(HKEY_CURRENT_USER, KEY_BASE "\\keytest3", 0, KEY_READ, &subkey); + ok(err == ERROR_SUCCESS, "key creation failed, got %d\n", err); + RegCloseKey(subkey); + err = RegDeleteKeyA(HKEY_CURRENT_USER, KEY_BASE "\\keytest3"); + ok(err == ERROR_SUCCESS, "got exit code %d\n", r); + + run_reg_exe("reg add HKCU\\" KEY_BASE "\\keytest4 /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + err = RegOpenKeyExA(HKEY_CURRENT_USER, KEY_BASE "\\keytest4", 0, KEY_READ, &subkey); + ok(err == ERROR_SUCCESS, "key creation failed, got %d\n", err); + RegCloseKey(subkey); + err = RegDeleteKeyA(HKEY_CURRENT_USER, KEY_BASE "\\keytest4"); + ok(err == ERROR_SUCCESS, "got exit code %d\n", r); + /* REG_SZ */ run_reg_exe("reg add HKCU\\" KEY_BASE " /d WineTest /f", &r); ok(r == REG_EXIT_SUCCESS || broken(r == REG_EXIT_FAILURE /* WinXP */), @@ -136,6 +180,64 @@ ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); verify_reg(hkey, "test3", REG_SZ, "", 1, 0); + /* REG_EXPAND_SZ */ + run_reg_exe("reg add HKCU\\" KEY_BASE " /v expand0 /t REG_EXpand_sz /d \"dead%PATH%beef\" /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "expand0", REG_EXPAND_SZ, "dead%PATH%beef", 15, TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /v expand1 /t REG_EXpand_sz /d \"dead^%PATH^%beef\" /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "expand1", REG_EXPAND_SZ, "dead^%PATH^%beef", 17, TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_EXPAND_SZ /v expand2 /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "expand2", REG_EXPAND_SZ, "", 1, TODO_REG_SIZE); + + run_reg_exe("reg add HKEY_CURRENT_USER\\" KEY_BASE " /ve /t REG_EXPAND_SZ /d WineTEST /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "", REG_EXPAND_SZ, "WineTEST", 9, TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_EXPAND_SZ /v expand3 /f /d \"\"", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "expand3", REG_EXPAND_SZ, "", 1, TODO_REG_SIZE); + + /* REG_BINARY */ + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_BINARY /v bin0 /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "bin0", REG_BINARY, buffer, 0, 0); + + run_reg_exe("reg add HKEY_CURRENT_USER\\" KEY_BASE " /ve /t REG_BINARY /d deadbeef /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + dword = 0xefbeadde; + verify_reg(hkey, "", REG_BINARY, &dword, sizeof(DWORD), TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_BINARY /v bin1 /f /d 0xDeAdBeEf", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_BINARY /v bin2 /f /d x01", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_BINARY /v bin3 /f /d 01x", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_BINARY /v bin4 /f /d DeAdBeEf0DD", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + /* Remaining nibble prefixed */ + buffer[0] = 0x0d; buffer[1] = 0xea; buffer[2] = 0xdb; + buffer[3] = 0xee; buffer[4] = 0xf0; buffer[5] = 0xdd; + /* Remaining nibble suffixed on winXP */ + buffer[6] = 0xde; buffer[7] = 0xad; buffer[8] = 0xbe; + buffer[9] = 0xef; buffer[10] = 0x0d; buffer[11] = 0xd0; + size = 6; + err = RegQueryValueExA(hkey, "bin4", NULL, &type, (void *) (buffer+12), &size); + ok(err == ERROR_SUCCESS, "RegQueryValueEx failed: got %d\n", err); + ok(type == REG_BINARY, "got wrong type %u\n", type); + todo_wine ok(size == 6, "got wrong size %u\n", size); + todo_wine ok(memcmp(buffer, buffer+12, 6) == 0 || + broken(memcmp(buffer+6, buffer+12, 6) == 0 /* WinXP */), "got wrong data\n"); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_BINARY /v bin5 /d \"\" /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "bin5", REG_BINARY, buffer, 0, 0); + /* REG_DWORD */ run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_DWORD /f /d 12345678", &r); ok(r == REG_EXIT_SUCCESS || broken(r == REG_EXIT_FAILURE /* WinXP */), @@ -180,12 +282,65 @@ verify_reg(hkey, "dword8", REG_DWORD, &dword, sizeof(dword), (sizeof(long) > sizeof(DWORD)) ? 0 : TODO_REG_DATA); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_DWORD /v dword9 /f /d -1", &r); + todo_wine ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS /* WinXP */), "got exit code %u\n", r); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_DWORD /v dword10 /f /d -0x1", &r); + todo_wine ok(r == REG_EXIT_FAILURE || broken(r == REG_EXIT_SUCCESS /* WinXP */), "got exit code %u\n", r); + /* REG_DWORD_LITTLE_ENDIAN */ run_reg_exe("reg add HKCU\\" KEY_BASE " /v DWORD_LE /t REG_DWORD_LITTLE_ENDIAN /d 456 /f", &r); ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); dword = 456; verify_reg(hkey, "DWORD_LE", REG_DWORD_LITTLE_ENDIAN, &dword, sizeof(dword), 0); + /* REG_DWORD_BIG_ENDIAN */ + run_reg_exe("reg add HKCU\\" KEY_BASE " /v DWORD_BE /t REG_DWORD_BIG_ENDIAN /d 456 /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + dword = 456; + verify_reg(hkey, "DWORD_BE", REG_DWORD_BIG_ENDIAN, &dword, sizeof(dword), TODO_REG_SIZE); + /* REG_DWORD_BIG_ENDIAN is broken in every version of windows. It behaves like + * an ordinary REG_DWORD - that is little endian. GG */ + + /* REG_MULTI_SZ */ + run_reg_exe("reg add HKCU\\" KEY_BASE " /v multi0 /t REG_MULTI_SZ /d \"three\\0little\\0strings\" /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + memcpy(buffer, "three\0little\0strings\0", 22); + verify_reg(hkey, "multi0", REG_MULTI_SZ, buffer, 22, TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi1 /s \"#\" /d \"three#little#strings\" /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "multi1", REG_MULTI_SZ, buffer, 22, TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi2 /d \"\" /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "multi2", REG_MULTI_SZ, &buffer[21], 1, TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi3 /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "multi3", REG_MULTI_SZ, &buffer[21], 1, TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi4 /s \"#\" /d \"threelittlestrings\" /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + verify_reg(hkey, "multi4", REG_MULTI_SZ, "threelittlestrings\0", 20, TODO_REG_SIZE); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi5 /s \"#randomgibberish\" /d \"three#little#strings\" /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi6 /s \"\\0\" /d \"three\\0little\\0strings\" /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi7 /s \"\" /d \"three#little#strings\" /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi8 /s \"#\" /d \"##\" /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi9 /s \"#\" /d \"two##strings\" /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi10 /s \"#\" /d \"#a\" /f", &r); + todo_wine ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); + + run_reg_exe("reg add HKCU\\" KEY_BASE " /t REG_MULTI_SZ /v multi11 /s \"#\" /d \"a#\" /f", &r); + ok(r == REG_EXIT_SUCCESS, "got exit code %u\n", r); + buffer[0]='a'; buffer[1]=0; buffer[2]=0; + verify_reg(hkey, "multi11", REG_MULTI_SZ, buffer, 3, TODO_REG_SIZE); + RegCloseKey(hkey); err = RegDeleteKeyA(HKEY_CURRENT_USER, KEY_BASE); @@ -241,6 +396,9 @@ ok(r == REG_EXIT_SUCCESS, "got exit code %d, expected 0\n", r); err = RegOpenKeyExA(HKEY_CURRENT_USER, KEY_BASE, 0, KEY_READ, &hkey); ok(err == ERROR_FILE_NOT_FOUND, "got %d\n", err); + + run_reg_exe("reg delete HKCU\\" KEY_BASE " /f", &r); + ok(r == REG_EXIT_FAILURE, "got exit code %u\n", r); } static void test_query(void) diff -Nru wine1.7-1.7.28/programs/regedit/regproc.c wine1.7-1.7.31/programs/regedit/regproc.c --- wine1.7-1.7.28/programs/regedit/regproc.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/regedit/regproc.c 2014-11-14 13:28:17.000000000 +0000 @@ -255,7 +255,7 @@ /****************************************************************************** * Replaces escape sequences with the characters. */ -static void REGPROC_unescape_string(WCHAR* str) +static int REGPROC_unescape_string(WCHAR* str) { int str_idx = 0; /* current character under analysis */ int val_idx = 0; /* the last character of the unescaped string */ @@ -267,6 +267,12 @@ case 'n': str[val_idx] = '\n'; break; + case 'r': + str[val_idx] = '\r'; + break; + case '0': + str[val_idx] = '\0'; + break; case '\\': case '"': str[val_idx] = str[str_idx]; @@ -282,6 +288,7 @@ } } str[val_idx] = '\0'; + return val_idx; } static BOOL parseKeyName(LPWSTR lpKeyName, HKEY *hKey, LPWSTR *lpKeyPath) @@ -364,19 +371,10 @@ if (dwParseType == REG_SZ) /* no conversion for string */ { - REGPROC_unescape_string(val_data); - /* Compute dwLen after REGPROC_unescape_string because it may - * have changed the string length and we don't want to store - * the extra garbage in the registry. - */ - dwLen = lstrlenW(val_data); - if(val_data[dwLen-1] != '"') + dwLen = REGPROC_unescape_string(val_data); + if(!dwLen || val_data[dwLen-1] != '"') return ERROR_INVALID_DATA; - if (dwLen>0 && val_data[dwLen-1]=='"') - { - dwLen--; - val_data[dwLen]='\0'; - } + val_data[dwLen-1] = '\0'; /* remove last quotes */ lpbData = (BYTE*) val_data; dwLen++; /* include terminating null */ dwLen = dwLen * sizeof(WCHAR); /* size is in bytes */ @@ -968,6 +966,13 @@ (*line_buf)[pos++] = 'n'; break; + case '\r': + extra++; + REGPROC_resize_char_buffer(line_buf, line_buf_size, *line_len + str_len + extra); + (*line_buf)[pos++] = '\\'; + (*line_buf)[pos++] = 'r'; + break; + case '\\': case '"': extra++; @@ -1180,10 +1185,7 @@ lstrcpyW(*line_buf + line_len, start); line_len += len; - /* At this point we know wstr is '\0'-terminated - * so we can subtract 1 from the size - */ - REGPROC_export_string(line_buf, line_buf_size, &line_len, wstr, val_size1 / sizeof(WCHAR) - 1); + REGPROC_export_string(line_buf, line_buf_size, &line_len, wstr, lstrlenW(wstr)); REGPROC_resize_char_buffer(line_buf, line_buf_size, line_len + lstrlenW(end)); lstrcpyW(*line_buf + line_len, end); diff -Nru wine1.7-1.7.28/programs/systeminfo/main.c wine1.7-1.7.31/programs/systeminfo/main.c --- wine1.7-1.7.28/programs/systeminfo/main.c 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/programs/systeminfo/main.c 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,33 @@ +/* + * Copyright 2014 Austin English + * + * 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 "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(systeminfo); + +int wmain(int argc, WCHAR *argv[]) +{ + int i; + + WINE_FIXME("stub:"); + for (i = 0; i < argc; i++) + WINE_FIXME(" %s", wine_dbgstr_w(argv[i])); + WINE_FIXME("\n"); + + return 0; +} diff -Nru wine1.7-1.7.28/programs/systeminfo/Makefile.in wine1.7-1.7.31/programs/systeminfo/Makefile.in --- wine1.7-1.7.28/programs/systeminfo/Makefile.in 1970-01-01 00:00:00.000000000 +0000 +++ wine1.7-1.7.31/programs/systeminfo/Makefile.in 2014-11-14 13:28:17.000000000 +0000 @@ -0,0 +1,5 @@ +MODULE = systeminfo.exe +APPMODE = -mconsole -municode + +C_SRCS = \ + main.c diff -Nru wine1.7-1.7.28/programs/taskmgr/graph.c wine1.7-1.7.31/programs/taskmgr/graph.c --- wine1.7-1.7.28/programs/taskmgr/graph.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/taskmgr/graph.c 2014-11-14 13:28:17.000000000 +0000 @@ -265,8 +265,8 @@ * So first find out how many bars we can fit */ nBars = ((rcClient.bottom - rcClient.top) - 25) / 3; - if (CommitChargeLimit) - nBarsUsed = (nBars * (int)((CommitChargeTotal * 100) / CommitChargeLimit)) / 100; + if (CommitChargeLimit) + nBarsUsed = (nBars * (int)((CommitChargeTotal * 100) / CommitChargeLimit)) / 100; nBarsFree = nBars - nBarsUsed; if (nBarsUsed < 0) nBarsUsed = 0; diff -Nru wine1.7-1.7.28/programs/winecfg/appdefaults.c wine1.7-1.7.31/programs/winecfg/appdefaults.c --- wine1.7-1.7.28/programs/winecfg/appdefaults.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/winecfg/appdefaults.c 2014-11-14 13:28:17.000000000 +0000 @@ -49,6 +49,7 @@ const char *szProductType; } win_versions[] = { + { "win81", "Windows 8.1", 6, 3, 0x2580,VER_PLATFORM_WIN32_NT, " ", 0, 0, "WinNT"}, { "win8", "Windows 8", 6, 2, 0x23F0,VER_PLATFORM_WIN32_NT, " ", 0, 0, "WinNT"}, { "win2008r2", "Windows 2008 R2", 6, 1, 0x1DB1,VER_PLATFORM_WIN32_NT, "Service Pack 1", 1, 0, "ServerNT"}, { "win7", "Windows 7", 6, 1, 0x1DB1,VER_PLATFORM_WIN32_NT, "Service Pack 1", 1, 0, "WinNT"}, @@ -376,19 +377,17 @@ { HWND listview = GetDlgItem(dialog, IDC_APP_LISTVIEW); int selection = get_listview_selection(listview); - char *section = keypath(""); /* AppDefaults\\whatever.exe\\ */ LVITEMW item; item.iItem = selection; item.iSubItem = 0; item.mask = LVIF_PARAM; - WINE_TRACE("selection=%d, section=%s\n", selection, section); - + WINE_TRACE("selection=%d\n", selection); + assert( selection != 0 ); /* user cannot click this button when "default settings" is selected */ - section[strlen(section)] = '\0'; /* remove last backslash */ - set_reg_key(config_key, section, NULL, NULL); /* delete the section */ + set_reg_key(config_key, keypath(""), NULL, NULL); /* delete the section */ SendMessageW(listview, LVM_GETITEMW, 0, (LPARAM) &item); HeapFree (GetProcessHeap(), 0, (void*)item.lParam); SendMessageW(listview, LVM_DELETEITEM, selection, 0); diff -Nru wine1.7-1.7.28/programs/winetest/main.c wine1.7-1.7.31/programs/winetest/main.c --- wine1.7-1.7.28/programs/winetest/main.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/winetest/main.c 2014-11-14 13:28:17.000000000 +0000 @@ -32,6 +32,7 @@ #include #include #include +#include #include #include "winetest.h" @@ -323,11 +324,14 @@ # error CPU unknown #endif OSVERSIONINFOEXA ver; + RTL_OSVERSIONINFOEXW rtlver; BOOL ext; int is_win2k3_r2, is_admin, is_elevated; const char *(CDECL *wine_get_build_id)(void); + HMODULE hntdll = GetModuleHandleA("ntdll.dll"); void (CDECL *wine_get_host_version)( const char **sysname, const char **release ); BOOL (WINAPI *pGetProductInfo)(DWORD, DWORD, DWORD, DWORD, DWORD *); + NTSTATUS (WINAPI *pRtlGetVersion)(RTL_OSVERSIONINFOEXW *); ver.dwOSVersionInfoSize = sizeof(ver); if (!(ext = GetVersionExA ((OSVERSIONINFOA *) &ver))) @@ -336,6 +340,27 @@ if (!GetVersionExA ((OSVERSIONINFOA *) &ver)) report (R_FATAL, "Can't get OS version."); } + + /* try to get non-faked values */ + if (ver.dwMajorVersion == 6 && ver.dwMinorVersion == 2) + { + rtlver.dwOSVersionInfoSize = sizeof(RTL_OSVERSIONINFOEXW); + + pRtlGetVersion = (void *)GetProcAddress(hntdll, "RtlGetVersion"); + pRtlGetVersion(&rtlver); + + ver.dwMajorVersion = rtlver.dwMajorVersion; + ver.dwMinorVersion = rtlver.dwMinorVersion; + ver.dwBuildNumber = rtlver.dwBuildNumber; + ver.dwPlatformId = rtlver.dwPlatformId; + ver.wServicePackMajor = rtlver.wServicePackMajor; + ver.wServicePackMinor = rtlver.wServicePackMinor; + ver.wSuiteMask = rtlver.wSuiteMask; + ver.wProductType = rtlver.wProductType; + + WideCharToMultiByte(CP_ACP, 0, rtlver.szCSDVersion, -1, ver.szCSDVersion, sizeof(ver.szCSDVersion), NULL, NULL); + } + xprintf (" Platform=%s%s\n", platform, is_wow64 ? " (WOW64)" : ""); xprintf (" bRunningUnderWine=%d\n", running_under_wine ()); xprintf (" bRunningOnVisibleDesktop=%d\n", running_on_visible_desktop ()); @@ -358,8 +383,8 @@ ver.dwMajorVersion, ver.dwMinorVersion, ver.dwBuildNumber, ver.dwPlatformId, ver.szCSDVersion); - wine_get_build_id = (void *)GetProcAddress(GetModuleHandleA("ntdll.dll"), "wine_get_build_id"); - wine_get_host_version = (void *)GetProcAddress(GetModuleHandleA("ntdll.dll"), "wine_get_host_version"); + wine_get_build_id = (void *)GetProcAddress(hntdll, "wine_get_build_id"); + wine_get_host_version = (void *)GetProcAddress(hntdll, "wine_get_host_version"); if (wine_get_build_id) xprintf( " WineBuild=%s\n", wine_get_build_id() ); if (wine_get_host_version) { diff -Nru wine1.7-1.7.28/programs/write/write.c wine1.7-1.7.31/programs/write/write.c --- wine1.7-1.7.28/programs/write/write.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/write/write.c 2014-11-14 13:28:17.000000000 +0000 @@ -25,8 +25,7 @@ #include #include "resources.h" -static const WCHAR SZ_BACKSLASH[] = {'\\',0}; -static const WCHAR SZ_WORDPAD[] = {'w','o','r','d','p','a','d','.','e','x','e',0}; +static const WCHAR SZ_WORDPAD[] = {'\\','w','o','r','d','p','a','d','.','e','x','e',0}; int CALLBACK WinMain(HINSTANCE hInstance, HINSTANCE hOldInstance, LPSTR szCmdParagraph, int res) { @@ -36,8 +35,6 @@ if (!GetSystemDirectoryW(path, MAX_PATH - 1 - lstrlenW(SZ_WORDPAD))) goto failed; - if (path[lstrlenW(path) - 1] != '\\') - lstrcatW(path, SZ_BACKSLASH); lstrcatW(path, SZ_WORDPAD); stinf.cb = sizeof(STARTUPINFOW); diff -Nru wine1.7-1.7.28/programs/xcopy/xcopy.c wine1.7-1.7.31/programs/xcopy/xcopy.c --- wine1.7-1.7.28/programs/xcopy/xcopy.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/programs/xcopy/xcopy.c 2014-11-14 13:28:17.000000000 +0000 @@ -271,11 +271,9 @@ EXCLUDELIST *thisEntry; int length = lstrlenW(buffer); - /* Strip CRLF */ - buffer[length-1] = 0x00; - /* If more than CRLF */ if (length > 1) { + buffer[length-1] = 0; /* strip CRLF */ thisEntry = HeapAlloc(GetProcessHeap(), 0, sizeof(EXCLUDELIST)); thisEntry->next = excludeList; excludeList = thisEntry; diff -Nru wine1.7-1.7.28/server/named_pipe.c wine1.7-1.7.31/server/named_pipe.c --- wine1.7-1.7.28/server/named_pipe.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/named_pipe.c 2014-11-14 13:28:17.000000000 +0000 @@ -52,6 +52,7 @@ #include "handle.h" #include "thread.h" #include "request.h" +#include "security.h" enum pipe_state { @@ -689,7 +690,7 @@ } static struct named_pipe *create_named_pipe( struct directory *root, const struct unicode_str *name, - unsigned int attr ) + unsigned int attr, const struct security_descriptor *sd ) { struct object *obj; struct named_pipe *pipe = NULL; @@ -954,6 +955,8 @@ struct pipe_server *server; struct unicode_str name; struct directory *root = NULL; + const struct object_attributes *objattr = get_req_data(); + const struct security_descriptor *sd; if (!req->sharing || (req->sharing & ~(FILE_SHARE_READ | FILE_SHARE_WRITE)) || (!(req->flags & NAMED_PIPE_MESSAGE_STREAM_WRITE) && (req->flags & NAMED_PIPE_MESSAGE_STREAM_READ))) @@ -963,11 +966,17 @@ } reply->handle = 0; - get_req_unicode_str( &name ); - if (req->rootdir && !(root = get_directory_obj( current->process, req->rootdir, 0 ))) + + if (!objattr_is_valid( objattr, get_req_data_size() )) + return; + + sd = objattr->sd_len ? (const struct security_descriptor *)(objattr + 1) : NULL; + objattr_get_name( objattr, &name ); + + if (objattr->rootdir && !(root = get_directory_obj( current->process, objattr->rootdir, 0 ))) return; - pipe = create_named_pipe( root, &name, req->attributes | OBJ_OPENIF ); + pipe = create_named_pipe( root, &name, req->attributes | OBJ_OPENIF, sd ); if (root) release_object( root ); if (!pipe) return; @@ -1007,6 +1016,10 @@ { reply->handle = alloc_handle( current->process, server, req->access, req->attributes ); server->pipe->instances++; + if (sd) default_set_sd( &server->obj, sd, OWNER_SECURITY_INFORMATION | + GROUP_SECURITY_INFORMATION | + DACL_SECURITY_INFORMATION | + SACL_SECURITY_INFORMATION ); release_object( server ); } diff -Nru wine1.7-1.7.28/server/protocol.def wine1.7-1.7.31/server/protocol.def --- wine1.7-1.7.28/server/protocol.def 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/protocol.def 2014-11-14 13:28:17.000000000 +0000 @@ -2156,7 +2156,6 @@ @REQ(accept_hardware_message) unsigned int hw_id; /* id of the hardware message */ int remove; /* should we remove the message? */ - user_handle_t new_win; /* new destination window for current message */ @END @@ -2275,7 +2274,6 @@ @REQ(create_named_pipe) unsigned int access; unsigned int attributes; /* object attributes */ - obj_handle_t rootdir; /* root directory */ unsigned int options; unsigned int sharing; unsigned int maxinstances; @@ -2283,7 +2281,7 @@ unsigned int insize; timeout_t timeout; unsigned int flags; - VARARG(name,unicode_str); /* pipe name */ + VARARG(objattr,object_attributes); /* object attributes */ @REPLY obj_handle_t handle; /* handle to the pipe */ @END diff -Nru wine1.7-1.7.28/server/queue.c wine1.7-1.7.31/server/queue.c --- wine1.7-1.7.28/server/queue.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/queue.c 2014-11-14 13:28:17.000000000 +0000 @@ -1281,7 +1281,7 @@ /* release the hardware message currently being processed by the given thread */ static void release_hardware_message( struct msg_queue *queue, unsigned int hw_id, - int remove, user_handle_t new_win ) + int remove ) { struct thread_input *input = queue->input; struct message *msg; @@ -1293,7 +1293,7 @@ if (&msg->entry == &input->msg_list) return; /* not found */ /* clear the queue bit for that message */ - if (remove || new_win) + if (remove) { struct message *other; int clr_bit; @@ -1308,32 +1308,7 @@ } } if (clr_bit) clear_queue_bits( queue, clr_bit ); - } - if (new_win) /* set the new window */ - { - struct thread *owner = get_window_thread( new_win ); - if (owner) - { - msg->win = new_win; - if (owner->queue->input != input) - { - list_remove( &msg->entry ); - if (merge_message( owner->queue->input, msg )) - { - free_message( msg ); - release_object( owner ); - return; - } - list_add_tail( &owner->queue->input->msg_list, &msg->entry ); - } - set_queue_bits( owner->queue, get_hardware_msg_bit( msg )); - remove = 0; - release_object( owner ); - } - } - if (remove) - { update_input_key_state( input->desktop, input->keystate, msg ); list_remove( &msg->entry ); free_message( msg ); @@ -1379,11 +1354,13 @@ /* find the window that should receive a given hardware message */ static user_handle_t find_hardware_message_window( struct desktop *desktop, struct thread_input *input, - struct message *msg, unsigned int *msg_code ) + struct message *msg, unsigned int *msg_code, + struct thread **thread ) { struct hardware_msg_data *data = msg->data; user_handle_t win = 0; + *thread = NULL; *msg_code = msg->msg; if (msg->msg == WM_INPUT) { @@ -1397,14 +1374,16 @@ if (*msg_code < WM_SYSKEYDOWN) *msg_code += WM_SYSKEYDOWN - WM_KEYDOWN; } } - else /* mouse message */ + else if (!input || !(win = input->capture)) /* mouse message */ { - if (!input || !(win = input->capture)) - { - if (!(win = msg->win) || !is_window_visible( win ) || is_window_transparent( win )) - win = window_from_point( desktop, data->x, data->y ); - } + if (is_window_visible( msg->win ) && !is_window_transparent( msg->win )) win = msg->win; + else win = shallow_window_from_point( desktop, data->x, data->y ); + + *thread = window_thread_from_point( win, data->x, data->y ); } + + if (!*thread) + *thread = get_window_thread( win ); return win; } @@ -1491,8 +1470,8 @@ } else input = desktop->foreground_input; - win = find_hardware_message_window( desktop, input, msg, &msg_code ); - if (!win || !(thread = get_window_thread(win))) + win = find_hardware_message_window( desktop, input, msg, &msg_code, &thread ); + if (!win || !thread) { if (input) update_input_key_state( input->desktop, input->keystate, msg ); free_message( msg ); @@ -1928,8 +1907,8 @@ struct hardware_msg_data *data = msg->data; ptr = list_next( &input->msg_list, ptr ); - win = find_hardware_message_window( input->desktop, input, msg, &msg_code ); - if (!win || !(win_thread = get_window_thread( win ))) + win = find_hardware_message_window( input->desktop, input, msg, &msg_code, &win_thread ); + if (!win || !win_thread) { /* no window at all, remove it */ update_input_key_state( input->desktop, input->keystate, msg ); @@ -1976,7 +1955,7 @@ data->hw_id = msg->unique_id; set_reply_data( msg->data, msg->data_size ); if (msg->msg == WM_INPUT && (flags & PM_REMOVE)) - release_hardware_message( current->queue, data->hw_id, 1, 0 ); + release_hardware_message( current->queue, data->hw_id, 1 ); return 1; } /* nothing found, clear the hardware queue bits */ @@ -2467,7 +2446,7 @@ DECL_HANDLER(accept_hardware_message) { if (current->queue) - release_hardware_message( current->queue, req->hw_id, req->remove, req->new_win ); + release_hardware_message( current->queue, req->hw_id, req->remove ); else set_error( STATUS_ACCESS_DENIED ); } diff -Nru wine1.7-1.7.28/server/registry.c wine1.7-1.7.31/server/registry.c --- wine1.7-1.7.28/server/registry.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/registry.c 2014-11-14 13:28:17.000000000 +0000 @@ -864,10 +864,12 @@ static void enum_key( const struct key *key, int index, int info_class, struct enum_key_reply *reply ) { + static const WCHAR backslash[] = { '\\' }; int i; data_size_t len, namelen, classlen; data_size_t max_subkey = 0, max_class = 0; data_size_t max_value = 0, max_data = 0; + const struct key *k; char *data; if (index != -1) /* -1 means use the specified key directly */ @@ -885,8 +887,14 @@ switch(info_class) { - case KeyBasicInformation: case KeyNameInformation: + namelen = 0; + for (k = key; k != root_key; k = k->parent) + namelen += k->namelen + sizeof(backslash); + if (!namelen) return; + namelen += sizeof(root_name) - sizeof(backslash); + /* fall through */ + case KeyBasicInformation: classlen = 0; /* only return the name */ /* fall through */ case KeyNodeInformation: @@ -935,6 +943,21 @@ memcpy( data, key->name, namelen ); memcpy( data + namelen, key->class, len - namelen ); } + else if (info_class == KeyNameInformation) + { + data_size_t pos = namelen; + reply->namelen = namelen; + for (k = key; k != root_key; k = k->parent) + { + pos -= k->namelen; + if (pos < len) memcpy( data + pos, k->name, + min( k->namelen, len - pos ) ); + pos -= sizeof(backslash); + if (pos < len) memcpy( data + pos, backslash, + min( sizeof(backslash), len - pos ) ); + } + memcpy( data, root_name, min( sizeof(root_name) - sizeof(backslash), len ) ); + } else { reply->namelen = len; diff -Nru wine1.7-1.7.28/server/request.h wine1.7-1.7.31/server/request.h --- wine1.7-1.7.28/server/request.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/request.h 2014-11-14 13:28:17.000000000 +0000 @@ -1454,7 +1454,6 @@ C_ASSERT( sizeof(struct reply_message_request) == 24 ); C_ASSERT( FIELD_OFFSET(struct accept_hardware_message_request, hw_id) == 12 ); C_ASSERT( FIELD_OFFSET(struct accept_hardware_message_request, remove) == 16 ); -C_ASSERT( FIELD_OFFSET(struct accept_hardware_message_request, new_win) == 20 ); C_ASSERT( sizeof(struct accept_hardware_message_request) == 24 ); C_ASSERT( FIELD_OFFSET(struct get_message_reply_request, cancel) == 12 ); C_ASSERT( sizeof(struct get_message_reply_request) == 16 ); @@ -1518,15 +1517,14 @@ C_ASSERT( sizeof(struct get_ioctl_result_reply) == 8 ); C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, access) == 12 ); C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, attributes) == 16 ); -C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, rootdir) == 20 ); -C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, options) == 24 ); -C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, sharing) == 28 ); -C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, maxinstances) == 32 ); -C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, outsize) == 36 ); -C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, insize) == 40 ); -C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, timeout) == 48 ); -C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, flags) == 56 ); -C_ASSERT( sizeof(struct create_named_pipe_request) == 64 ); +C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, options) == 20 ); +C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, sharing) == 24 ); +C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, maxinstances) == 28 ); +C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, outsize) == 32 ); +C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, insize) == 36 ); +C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, timeout) == 40 ); +C_ASSERT( FIELD_OFFSET(struct create_named_pipe_request, flags) == 48 ); +C_ASSERT( sizeof(struct create_named_pipe_request) == 56 ); C_ASSERT( FIELD_OFFSET(struct create_named_pipe_reply, handle) == 8 ); C_ASSERT( sizeof(struct create_named_pipe_reply) == 16 ); C_ASSERT( FIELD_OFFSET(struct get_named_pipe_info_request, handle) == 12 ); diff -Nru wine1.7-1.7.28/server/sock.c wine1.7-1.7.31/server/sock.c --- wine1.7-1.7.28/server/sock.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/sock.c 2014-11-14 13:28:17.000000000 +0000 @@ -107,6 +107,7 @@ unsigned int message; /* message to send */ obj_handle_t wparam; /* message wparam (socket handle) */ int errors[FD_MAX_EVENTS]; /* event errors */ + timeout_t connect_time;/* time the socket was connected */ struct sock *deferred; /* socket that waits for a deferred accept */ struct async_queue *read_q; /* queue for asynchronous reads */ struct async_queue *write_q; /* queue for asynchronous writes */ @@ -401,6 +402,7 @@ /* we got connected */ sock->state |= FD_WINE_CONNECTED|FD_READ|FD_WRITE; sock->state &= ~FD_CONNECT; + sock->connect_time = current_time; } } else if (sock->state & FD_WINE_LISTENING) @@ -618,6 +620,7 @@ sock->window = 0; sock->message = 0; sock->wparam = 0; + sock->connect_time = 0; sock->deferred = NULL; sock->read_q = NULL; sock->write_q = NULL; @@ -725,6 +728,7 @@ acceptsock->family = sock->family; acceptsock->window = sock->window; acceptsock->message = sock->message; + acceptsock->connect_time = current_time; if (sock->event) acceptsock->event = (struct event *)grab_object( sock->event ); acceptsock->flags = sock->flags; if (!(acceptsock->fd = create_anonymous_fd( &sock_fd_ops, acceptfd, &acceptsock->obj, @@ -773,10 +777,12 @@ acceptsock->hmask = 0; acceptsock->pmask = 0; acceptsock->polling = 0; + acceptsock->proto = sock->proto; acceptsock->type = sock->type; acceptsock->family = sock->family; acceptsock->wparam = 0; acceptsock->deferred = NULL; + acceptsock->connect_time = current_time; release_object( acceptsock->fd ); acceptsock->fd = newfd; diff -Nru wine1.7-1.7.28/server/trace.c wine1.7-1.7.31/server/trace.c --- wine1.7-1.7.28/server/trace.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/trace.c 2014-11-14 13:28:17.000000000 +0000 @@ -127,6 +127,8 @@ CASE(x86); CASE(x86_64); CASE(POWERPC); + CASE(ARM); + CASE(ARM64); default: fprintf( stderr, "%s%u", prefix, *code ); break; #undef CASE } @@ -2626,7 +2628,6 @@ { fprintf( stderr, " hw_id=%08x", req->hw_id ); fprintf( stderr, ", remove=%d", req->remove ); - fprintf( stderr, ", new_win=%08x", req->new_win ); } static void dump_get_message_reply_request( const struct get_message_reply_request *req ) @@ -2745,7 +2746,6 @@ { fprintf( stderr, " access=%08x", req->access ); fprintf( stderr, ", attributes=%08x", req->attributes ); - fprintf( stderr, ", rootdir=%04x", req->rootdir ); fprintf( stderr, ", options=%08x", req->options ); fprintf( stderr, ", sharing=%08x", req->sharing ); fprintf( stderr, ", maxinstances=%08x", req->maxinstances ); @@ -2753,7 +2753,7 @@ fprintf( stderr, ", insize=%08x", req->insize ); dump_timeout( ", timeout=", &req->timeout ); fprintf( stderr, ", flags=%08x", req->flags ); - dump_varargs_unicode_str( ", name=", cur_size ); + dump_varargs_object_attributes( ", objattr=", cur_size ); } static void dump_create_named_pipe_reply( const struct create_named_pipe_reply *req ) diff -Nru wine1.7-1.7.28/server/user.h wine1.7-1.7.31/server/user.h --- wine1.7-1.7.28/server/user.h 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/user.h 2014-11-14 13:28:17.000000000 +0000 @@ -157,7 +157,8 @@ extern int is_window_transparent( user_handle_t window ); extern int make_window_active( user_handle_t window ); extern struct thread *get_window_thread( user_handle_t handle ); -extern user_handle_t window_from_point( struct desktop *desktop, int x, int y ); +extern user_handle_t shallow_window_from_point( struct desktop *desktop, int x, int y ); +extern struct thread *window_thread_from_point( user_handle_t scope, int x, int y ); extern user_handle_t find_window_to_repaint( user_handle_t parent, struct thread *thread ); extern struct window_class *get_window_class( user_handle_t window ); diff -Nru wine1.7-1.7.28/server/window.c wine1.7-1.7.31/server/window.c --- wine1.7-1.7.28/server/window.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/server/window.c 2014-11-14 13:28:17.000000000 +0000 @@ -727,14 +727,38 @@ return 1; } -/* find window containing point (in absolute coords) */ -user_handle_t window_from_point( struct desktop *desktop, int x, int y ) +/* get handle of root of top-most window containing point */ +user_handle_t shallow_window_from_point( struct desktop *desktop, int x, int y ) { - struct window *ret; + struct window *ptr; if (!desktop->top_window) return 0; - ret = child_window_from_point( desktop->top_window, x, y ); - return ret->handle; + + LIST_FOR_EACH_ENTRY( ptr, &desktop->top_window->children, struct window, entry ) + { + if (!is_point_in_window( ptr, x, y )) continue; /* skip it */ + return ptr->handle; + } + return desktop->top_window->handle; +} + +/* return thread of top-most window containing point (in absolute coords) */ +struct thread *window_thread_from_point( user_handle_t scope, int x, int y ) +{ + struct window *win = get_user_object( scope, USER_WINDOW ); + struct window *ptr; + + if (!win) return NULL; + + for (ptr = win; ptr && !is_desktop_window(ptr); ptr = ptr->parent) + { + x -= ptr->client_rect.left; + y -= ptr->client_rect.top; + } + + ptr = child_window_from_point( win, x, y ); + if (!ptr->thread) return NULL; + return (struct thread *)grab_object( ptr->thread ); } /* return list of all windows containing point (in absolute coords) */ diff -Nru wine1.7-1.7.28/tools/make_specfiles wine1.7-1.7.31/tools/make_specfiles --- wine1.7-1.7.28/tools/make_specfiles 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/tools/make_specfiles 2014-11-14 13:28:17.000000000 +0000 @@ -39,6 +39,7 @@ "msvcp90", "msvcp100", "msvcp110", + "msvcp120", "msvcp71", "msvcp80", "msvcp70", diff -Nru wine1.7-1.7.28/tools/make_unicode wine1.7-1.7.31/tools/make_unicode --- wine1.7-1.7.28/tools/make_unicode 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/tools/make_unicode 2014-11-14 13:28:17.000000000 +0000 @@ -2383,6 +2383,7 @@ DUMP_COMPOSE_TABLES( "libs/wine/compose.c" ); DUMP_CTYPE_TABLES( "libs/wine/wctype.c" ); dump_mirroring( "dlls/usp10/mirror.c" ); +dump_mirroring( "dlls/dwrite/mirror.c" ); dump_bracket( "dlls/usp10/bracket.c" ); dump_bracket( "dlls/dwrite/bracket.c" ); dump_shaping( "dlls/usp10/shaping.c" ); diff -Nru wine1.7-1.7.28/tools/widl/header.c wine1.7-1.7.31/tools/widl/header.c --- wine1.7-1.7.28/tools/widl/header.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/tools/widl/header.c 2014-11-14 13:28:17.000000000 +0000 @@ -828,6 +828,32 @@ return 0; } +static int is_override_method(const type_t *iface, const type_t *child, const var_t *func) +{ + if (iface == child) + return 0; + + do + { + const statement_t *stmt; + STATEMENTS_FOR_EACH_FUNC(stmt, type_iface_get_stmts(child)) + { + const var_t *funccmp = stmt->u.var; + + if (!is_callas(func->attrs)) + { + char inherit_name[256]; + /* compare full name including property prefix */ + strcpy(inherit_name, get_name(funccmp)); + if (!strcmp(inherit_name, get_name(func))) return 1; + } + } + } + while ((child = type_iface_get_inherit(child)) && child != iface); + + return 0; +} + static int is_aggregate_return(const var_t *func) { enum type_type type = type_get_type(type_function_get_rettype(func->type)); @@ -835,13 +861,23 @@ type == TYPE_COCLASS || type == TYPE_INTERFACE; } -static void write_method_macro(FILE *header, const type_t *iface, const char *name) +static char *get_vtbl_entry_name(const type_t *iface, const var_t *func) +{ + static char buff[255]; + if (is_inherited_method(iface, func)) + sprintf(buff, "%s_%s", iface->name, get_name(func)); + else + sprintf(buff, "%s", get_name(func)); + return buff; +} + +static void write_method_macro(FILE *header, const type_t *iface, const type_t *child, const char *name) { const statement_t *stmt; int first_iface = 1; if (type_iface_get_inherit(iface)) - write_method_macro(header, type_iface_get_inherit(iface), name); + write_method_macro(header, type_iface_get_inherit(iface), child, name); STATEMENTS_FOR_EACH_FUNC(stmt, type_iface_get_stmts(iface)) { @@ -853,8 +889,10 @@ first_iface = 0; } - if (!is_callas(func->attrs) && !is_inherited_method(iface, func) && - !is_aggregate_return(func)) { + if (is_override_method(iface, child, func)) + continue; + + if (!is_callas(func->attrs) && !is_aggregate_return(func)) { const var_t *arg; fprintf(header, "#define %s_%s(This", name, get_name(func)); @@ -863,7 +901,7 @@ fprintf(header, ",%s", arg->name); fprintf(header, ") "); - fprintf(header, "(This)->lpVtbl->%s(This", get_name(func)); + fprintf(header, "(This)->lpVtbl->%s(This", get_vtbl_entry_name(iface, func)); if (type_get_function_args(func->type)) LIST_FOR_EACH_ENTRY( arg, type_get_function_args(func->type), const var_t, entry ) fprintf(header, ",%s", arg->name); @@ -929,13 +967,13 @@ } } -static void write_inline_wrappers(FILE *header, const type_t *iface, const char *name) +static void write_inline_wrappers(FILE *header, const type_t *iface, const type_t *child, const char *name) { const statement_t *stmt; int first_iface = 1; if (type_iface_get_inherit(iface)) - write_inline_wrappers(header, type_iface_get_inherit(iface), name); + write_inline_wrappers(header, type_iface_get_inherit(iface), child, name); STATEMENTS_FOR_EACH_FUNC(stmt, type_iface_get_stmts(iface)) { @@ -947,7 +985,10 @@ first_iface = 0; } - if (!is_callas(func->attrs) && !is_inherited_method(iface, func)) { + if (is_override_method(iface, child, func)) + continue; + + if (!is_callas(func->attrs)) { const var_t *arg; fprintf(header, "static FORCEINLINE "); @@ -960,13 +1001,13 @@ indent(header, 0); fprintf(header, "%sThis->lpVtbl->%s(This", is_void(type_function_get_rettype(func->type)) ? "" : "return ", - get_name(func)); + get_vtbl_entry_name(iface, func)); } else { indent(header, 0); write_type_decl_left(header, type_function_get_rettype(func->type)); fprintf(header, " __ret;\n"); indent(header, 0); - fprintf(header, "return *This->lpVtbl->%s(This,&__ret", get_name(func)); + fprintf(header, "return *This->lpVtbl->%s(This,&__ret", get_vtbl_entry_name(iface, func)); } if (type_get_function_args(func->type)) LIST_FOR_EACH_ENTRY( arg, type_get_function_args(func->type), const var_t, entry ) @@ -1188,6 +1229,7 @@ { int dispinterface = is_attr(iface->attrs, ATTR_DISPINTERFACE); const UUID *uuid = get_attrp(iface->attrs, ATTR_UUID); + type_t *type; if (uuid) write_guid(header, dispinterface ? "DIID" : "IID", iface->name, uuid); @@ -1245,9 +1287,10 @@ /* dispinterfaces don't have real functions, so don't write macros for them, * only for the interface this interface inherits from, i.e. IDispatch */ fprintf(header, "#ifndef WIDL_C_INLINE_WRAPPERS\n"); - write_method_macro(header, dispinterface ? type_iface_get_inherit(iface) : iface, iface->name); + type = dispinterface ? type_iface_get_inherit(iface) : iface; + write_method_macro(header, type, type, iface->name); fprintf(header, "#else\n"); - write_inline_wrappers(header, dispinterface ? type_iface_get_inherit(iface) : iface, iface->name); + write_inline_wrappers(header, type, type, iface->name); fprintf(header, "#endif\n"); fprintf(header, "#endif\n"); fprintf(header, "\n"); diff -Nru wine1.7-1.7.28/tools/winedump/minidump.c wine1.7-1.7.31/tools/winedump/minidump.c --- wine1.7-1.7.28/tools/winedump/minidump.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/tools/winedump/minidump.c 2014-11-14 13:28:17.000000000 +0000 @@ -342,10 +342,19 @@ break; case 1: if (msi->u.s.ProductType == 1) str = "Win7"; - else if (msi->u.s.ProductType == 3) str = "Server 2008"; + else if (msi->u.s.ProductType == 3) str = "Server 2008 R2"; + else str = "6-????"; + break; + case 2: + if (msi->u.s.ProductType == 1) str = "Win8"; + else if (msi->u.s.ProductType == 3) str = "Server 2012"; + else str = "6-????"; + break; + case 3: + if (msi->u.s.ProductType == 1) str = "Win8.1"; + else if (msi->u.s.ProductType == 3) str = "Server 2012 R2"; else str = "6-????"; break; - case 2: str = "Win8"; break; default: str = "6-????"; break; } break; diff -Nru wine1.7-1.7.28/tools/winedump/pe.c wine1.7-1.7.31/tools/winedump/pe.c --- wine1.7-1.7.28/tools/winedump/pe.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/tools/winedump/pe.c 2014-11-14 13:28:17.000000000 +0000 @@ -600,10 +600,28 @@ struct unwind_info_armnt { - WORD function_length; - WORD unknown1 : 7; - WORD count : 5; - WORD unknown2 : 4; + DWORD function_length : 18; + DWORD version : 2; + DWORD x : 1; + DWORD e : 1; + DWORD f : 1; + DWORD count : 5; + DWORD words : 4; +}; + +struct unwind_info_ext_armnt +{ + WORD excount; + BYTE exwords; + BYTE reserved; +}; + +struct unwind_info_epilogue_armnt +{ + DWORD offset : 18; + DWORD res : 2; + DWORD cond : 4; + DWORD index : 8; }; #define UWOP_PUSH_NONVOL 0 @@ -725,35 +743,421 @@ (ULONG)(function->UnwindData + (const char *)(&handler_data->handler + 1) - (const char *)info )); } -static void dump_armnt_unwind_info( const struct runtime_function_armnt *function ) +static void dump_armnt_unwind_info( const struct runtime_function_armnt *fnc ) { const struct unwind_info_armnt *info; - if (function->u.s.Flag) + const struct unwind_info_ext_armnt *infoex; + const struct unwind_info_epilogue_armnt *infoepi; + unsigned int rva; + WORD i, count = 0, words = 0; + + if (fnc->u.s.Flag) { - printf( "\nFunction %08x-%08x:\n", function->BeginAddress & ~1, - (function->BeginAddress & ~1) + function->u.s.FunctionLength * 2 ); - printf( " Flag %x\n", function->u.s.Flag ); - printf( " FunctionLength %x\n", function->u.s.FunctionLength ); - printf( " Ret %x\n", function->u.s.Ret ); - printf( " H %x\n", function->u.s.H ); - printf( " Reg %x\n", function->u.s.Reg ); - printf( " R %x\n", function->u.s.R ); - printf( " L %x\n", function->u.s.L ); - printf( " C %x\n", function->u.s.C ); - printf( " StackAdjust %x\n", function->u.s.StackAdjust ); + char intregs[32] = {0}, intregspop[32] = {0}, vfpregs[32] = {0}; + WORD pf = 0, ef = 0, sc = 0; + + printf( "\nFunction %08x-%08x:\n", fnc->BeginAddress & ~1, + (fnc->BeginAddress & ~1) + fnc->u.s.FunctionLength * 2 ); + printf( " Flag %x\n", fnc->u.s.Flag ); + printf( " FunctionLength %x\n", fnc->u.s.FunctionLength ); + printf( " Ret %x\n", fnc->u.s.Ret ); + printf( " H %x\n", fnc->u.s.H ); + printf( " Reg %x\n", fnc->u.s.Reg ); + printf( " R %x\n", fnc->u.s.R ); + printf( " L %x\n", fnc->u.s.L ); + printf( " C %x\n", fnc->u.s.C ); + printf( " StackAdjust %x\n", fnc->u.s.StackAdjust ); + + if (fnc->u.s.StackAdjust >= 0x03f4) + { + pf = fnc->u.s.StackAdjust & 0x04; + ef = fnc->u.s.StackAdjust & 0x08; + } + + if (!fnc->u.s.R && !pf) + { + if (fnc->u.s.Reg) + { + sprintf(intregs, "r4-r%u", fnc->u.s.Reg + 4); + sprintf(intregspop, "r4-r%u", fnc->u.s.Reg + 4); + } + else + { + strcpy(intregs, "r4"); + strcpy(intregspop, "r4"); + } + sc = fnc->u.s.Reg + 1; + if (fnc->u.s.C || fnc->u.s.L) + { + strcat(intregs, ", "); + if (fnc->u.s.C || (fnc->u.s.L && !fnc->u.s.H)) + strcat(intregspop, ", "); + } + } + else if (fnc->u.s.R && pf) + { + if (((~fnc->u.s.StackAdjust) & 3) != 3) + { + sprintf(intregs, "r%u-r3", (~fnc->u.s.StackAdjust) & 3); + sprintf(intregspop, "r%u-r3", (~fnc->u.s.StackAdjust) & 3); + } + else + { + sprintf(intregs, "r3"); + sprintf(intregspop, "r3"); + } + sc = 4 - ((~fnc->u.s.StackAdjust) & 3); + if (fnc->u.s.C || fnc->u.s.L) + { + strcat(intregs, ", "); + if (fnc->u.s.C || (fnc->u.s.L && !fnc->u.s.H)) + strcat(intregspop, ", "); + } + } + else if (!fnc->u.s.R && pf) + { + sprintf(intregs, "r%u-r%u", (~fnc->u.s.StackAdjust) & 3, fnc->u.s.Reg + 4); + sprintf(intregspop, "r%u-r%u", (~fnc->u.s.StackAdjust) & 3, fnc->u.s.Reg + 4); + sc = fnc->u.s.Reg + 5 - ((~fnc->u.s.StackAdjust) & 3); + if (fnc->u.s.C || fnc->u.s.L) + { + strcat(intregs, ", "); + if (fnc->u.s.C || (fnc->u.s.L && !fnc->u.s.H)) + strcat(intregspop, ", "); + } + } + else if (fnc->u.s.R && !pf) + { + if (!fnc->u.s.C && !fnc->u.s.L) + { + strcpy(intregs, "none"); + strcpy(intregspop, "none"); + } + } + + if (fnc->u.s.C && !fnc->u.s.L) + { + strcat(intregs, "r11"); + strcat(intregspop, "r11"); + } + else if (fnc->u.s.C && fnc->u.s.L) + { + strcat(intregs, "r11, lr"); + if (fnc->u.s.H) + strcat(intregspop, "r11"); + else + strcat(intregspop, "r11, pc"); + } + else if (!fnc->u.s.C && fnc->u.s.L) + { + strcat(intregs, "lr"); + if (!fnc->u.s.H) + strcat(intregspop, "pc"); + } + + if (fnc->u.s.R) + { + if (fnc->u.s.Reg) + sprintf(vfpregs, "d8-d%u", fnc->u.s.Reg + 8); + else + strcpy(vfpregs, "d8"); + } + else + strcpy(vfpregs, "none"); + + if (fnc->u.s.H) + printf( " Unwind Code\tpush {r0-r3}\n" ); + + if (fnc->u.s.R || fnc->u.s.L || fnc->u.s.C || pf) + printf( " Unwind Code\tpush {%s}\n", intregs ); + + if (fnc->u.s.C && fnc->u.s.R && !fnc->u.s.L && !pf) + printf( " Unwind Code\tmov r11, sp\n" ); + else if (fnc->u.s.C && (!fnc->u.s.R || fnc->u.s.L || pf)) + { + if (fnc->u.s.StackAdjust >= 0x03f4 && !sc) + printf( " Unwind Code\tadd r11, sp, #\n"); + else if (fnc->u.s.StackAdjust >= 0x03f4) + printf( " Unwind Code\tadd r11, sp, #%d\n", sc * 4 ); + else + printf( " Unwind Code\tadd r11, sp, #%d\n", fnc->u.s.StackAdjust * 4 ); + } + + if (fnc->u.s.R && fnc->u.s.Reg != 0x07) + printf( " Unwind Code\tvpush {%s}\n", vfpregs ); + + if (fnc->u.s.StackAdjust < 0x03f4 && !pf) + printf( " Unwind Code\tsub sp, sp, #%d\n", fnc->u.s.StackAdjust * 4 ); + + + if (fnc->u.s.StackAdjust < 0x03f4 && !ef) + printf( " Unwind Code\tadd sp, sp, #%d\n", fnc->u.s.StackAdjust * 4 ); + + if (fnc->u.s.R && fnc->u.s.Reg != 0x07) + printf( " Unwind Code\tvpop {%s}\n", vfpregs ); + + if (fnc->u.s.C || !fnc->u.s.R || ef || (fnc->u.s.L && !fnc->u.s.H)) + printf( " Unwind Code\tpop {%s}\n", intregspop ); + + if (fnc->u.s.H && !fnc->u.s.L) + printf( " Unwind Code\tadd sp, sp, #16\n" ); + else if (fnc->u.s.H && fnc->u.s.L) + printf( " Unwind Code\tldr pc, [sp], #20\n" ); + + if (fnc->u.s.Ret == 1) + printf( " Unwind Code\tbx \n" ); + else if (fnc->u.s.Ret == 2) + printf( " Unwind Code\tb
\n" ); + return; } - info = RVA( function->u.UnwindData, sizeof(*info) ); - - printf( "\nFunction %08x-%08x:\n", function->BeginAddress & ~1, - (function->BeginAddress & ~1) + info->function_length * 2 ); - printf( " unwind info at %08x\n", function->u.UnwindData ); - printf( " Flag %x\n", function->u.s.Flag ); + info = RVA( fnc->u.UnwindData, sizeof(*info) ); + rva = fnc->u.UnwindData + sizeof(*info); + count = info->count; + words = info->words; + + printf( "\nFunction %08x-%08x:\n", fnc->BeginAddress & ~1, + (fnc->BeginAddress & ~1) + info->function_length * 2 ); + printf( " unwind info at %08x\n", fnc->u.UnwindData ); + printf( " Flag %x\n", fnc->u.s.Flag ); printf( " FunctionLength %x\n", info->function_length ); - printf( " Unknown1 %x\n", info->unknown1 ); - printf( " Count %x\n", info->count ); - printf( " Unknown2 %x\n", info->unknown2 ); + printf( " Version %x\n", info->version ); + printf( " X %x\n", info->x ); + printf( " E %x\n", info->e ); + printf( " F %x\n", info->f ); + printf( " Count %x\n", count ); + printf( " Words %x\n", words ); + + if (!info->count && !info->words) + { + infoex = RVA( rva, sizeof(*infoex) ); + rva = rva + sizeof(*infoex); + count = infoex->excount; + words = infoex->exwords; + printf( " ExtCount %x\n", count ); + printf( " ExtWords %x\n", words ); + } + + if (!info->e) + { + infoepi = RVA( rva, count * sizeof(*infoepi) ); + rva = rva + count * sizeof(*infoepi); + + for (i = 0; i < count; i++) + { + printf( " Epilogue Scope %x\n", i ); + printf( " Offset %x\n", infoepi[i].offset ); + printf( " Reserved %x\n", infoepi[i].res ); + printf( " Condition %x\n", infoepi[i].cond ); + printf( " Index %x\n", infoepi[i].index ); + } + } + else + infoepi = NULL; + + if (words) + { + const unsigned int *codes; + BYTE b, *bytes; + BOOL inepilogue = FALSE; + + codes = RVA( rva, words * sizeof(*codes) ); + rva = rva + words * sizeof(*codes); + bytes = (BYTE*)codes; + + for (b = 0; b < words * sizeof(*codes); b++) + { + BYTE code = bytes[b]; + + if (info->e && b == count) + { + printf( "Epilogue:\n" ); + inepilogue = TRUE; + } + else if (!info->e && infoepi) + { + for (i = 0; i < count; i++) + if (b == infoepi[i].index) + { + printf( "Epilogue from Scope %x at %08x:\n", i, + (fnc->BeginAddress & ~1) + infoepi[i].offset * 2 ); + inepilogue = TRUE; + } + } + + printf( " Unwind Code %x\t", code ); + + if (code == 0x00) + printf( "\n" ); + else if (code <= 0x7f) + printf( "%s sp, sp, #%u\n", inepilogue ? "add" : "sub", code * 4 ); + else if (code <= 0xbf) + { + WORD excode, f; + BOOL first = TRUE; + BYTE excodes = bytes[++b]; + + excode = (code << 8) | excodes; + printf( "%s {", inepilogue ? "pop" : "push" ); + + for (f = 0; f <= 12; f++) + { + if ((excode >> f) & 1) + { + printf( "%sr%u", first ? "" : ", ", f ); + first = FALSE; + } + } + + if (excode & 0x2000) + printf( "%s%s", first ? "" : ", ", inepilogue ? "pc" : "lr" ); + + printf( "}\n" ); + } + else if (code <= 0xcf) + if (inepilogue) + printf( "mov sp, r%u\n", code & 0x0f ); + else + printf( "mov r%u, sp\n", code & 0x0f ); + else if (code <= 0xd7) + if (inepilogue) + printf( "pop {r4-r%u%s}\n", (code & 0x03) + 4, (code & 0x04) ? ", pc" : "" ); + else + printf( "push {r4-r%u%s}\n", (code & 0x03) + 4, (code & 0x04) ? ", lr" : "" ); + else if (code <= 0xdf) + if (inepilogue) + printf( "pop {r4-r%u%s}\n", (code & 0x03) + 8, (code & 0x04) ? ", pc" : "" ); + else + printf( "push {r4-r%u%s}\n", (code & 0x03) + 8, (code & 0x04) ? ", lr" : "" ); + else if (code <= 0xe7) + printf( "%s {d8-d%u}\n", inepilogue ? "vpop" : "vpush", (code & 0x07) + 8 ); + else if (code <= 0xeb) + { + WORD excode; + BYTE excodes = bytes[++b]; + + excode = (code << 8) | excodes; + printf( "%s sp, sp, #%u\n", inepilogue ? "addw" : "subw", (excode & 0x03ff) *4 ); + } + else if (code <= 0xed) + { + WORD excode, f; + BOOL first = TRUE; + BYTE excodes = bytes[++b]; + + excode = (code << 8) | excodes; + printf( "%s {", inepilogue ? "pop" : "push" ); + + for (f = 0; f < 8; f++) + { + if ((excode >> f) & 1) + { + printf( "%sr%u", first ? "" : ", ", f ); + first = FALSE; + } + } + + if (excode & 0x0100) + printf( "%s%s", first ? "" : ", ", inepilogue ? "pc" : "lr" ); + + printf( "}\n" ); + } + else if (code == 0xee) + printf( "unknown 16\n" ); + else if (code == 0xef) + { + WORD excode; + BYTE excodes = bytes[++b]; + + if (excodes <= 0x0f) + { + excode = (code << 8) | excodes; + if (inepilogue) + printf( "ldr lr, [sp], #%u\n", (excode & 0x0f) * 4 ); + else + printf( "unknown 32\n" ); + } + else + printf( "unknown 32\n" ); + } + else if (code <= 0xf4) + printf( "unknown\n" ); + else if (code <= 0xf6) + { + WORD excode, offset = (code == 0xf6) ? 16 : 0; + BYTE excodes = bytes[++b]; + + excode = (code << 8) | excodes; + printf( "%s {d%u-d%u}\n", inepilogue ? "vpop" : "vpush", + ((excode & 0x00f0) >> 4) + offset, (excode & 0x0f) + offset ); + } + else if (code <= 0xf7) + { + unsigned int excode; + BYTE excodes[2]; + + excodes[0] = bytes[++b]; + excodes[1] = bytes[++b]; + excode = (code << 16) | (excodes[0] << 8) | excodes[1]; + printf( "%s sp, sp, #%u\n", inepilogue ? "add" : "sub", (excode & 0xffff) *4 ); + } + else if (code <= 0xf8) + { + unsigned int excode; + BYTE excodes[3]; + + excodes[0] = bytes[++b]; + excodes[1] = bytes[++b]; + excodes[2] = bytes[++b]; + excode = (code << 24) | (excodes[0] << 16) | (excodes[1] << 8) | excodes[2]; + printf( "%s sp, sp, #%u\n", inepilogue ? "add" : "sub", (excode & 0xffffff) * 4 ); + } + else if (code <= 0xf9) + { + unsigned int excode; + BYTE excodes[2]; + + excodes[0] = bytes[++b]; + excodes[1] = bytes[++b]; + excode = (code << 16) | (excodes[0] << 8) | excodes[1]; + printf( "%s sp, sp, #%u\n", inepilogue ? "add" : "sub", (excode & 0xffff) *4 ); + } + else if (code <= 0xfa) + { + unsigned int excode; + BYTE excodes[3]; + + excodes[0] = bytes[++b]; + excodes[1] = bytes[++b]; + excodes[2] = bytes[++b]; + excode = (code << 24) | (excodes[0] << 16) | (excodes[1] << 8) | excodes[2]; + printf( "%s sp, sp, #%u\n", inepilogue ? "add" : "sub", (excode & 0xffffff) * 4 ); + } + else if (code <= 0xfc) + printf( "nop\n" ); + else if (code <= 0xfe) + { + printf( "(end) nop\n" ); + inepilogue = TRUE; + } + else + { + printf( "end\n" ); + inepilogue = TRUE; + } + } + } + + if (info->x) + { + const unsigned int *handler; + + handler = RVA( rva, sizeof(*handler) ); + rva = rva + sizeof(*handler); + + printf( " handler %08x data at %08x\n", *handler, rva); + } } static void dump_dir_exceptions(void) diff -Nru wine1.7-1.7.28/tools/winedump/tlb.c wine1.7-1.7.31/tools/winedump/tlb.c --- wine1.7-1.7.28/tools/winedump/tlb.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/tools/winedump/tlb.c 2014-11-14 13:28:17.000000000 +0000 @@ -647,7 +647,8 @@ break; default: printf(": %x ", n); - printf("\\%2.2x \\%2.2x\n", tlb_read_byte(), tlb_read_byte()); + printf("\\%2.2x ", tlb_read_byte()); + printf("\\%2.2x\n", tlb_read_byte()); } } diff -Nru wine1.7-1.7.28/tools/wrc/genres.c wine1.7-1.7.31/tools/wrc/genres.c --- wine1.7-1.7.28/tools/wrc/genres.c 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/tools/wrc/genres.c 2014-11-14 13:28:17.000000000 +0000 @@ -960,86 +960,48 @@ res = new_res(); restag = put_res_header(res, WRC_RT_GROUP_CURSOR, NULL, name, curg->memopt, &(curg->lvc)); - if(win32) - { - put_word(res, 0); /* Reserved */ - /* FIXME: The ResType in the NEWHEADER structure should - * contain 14 according to the MS win32 doc. This is - * not the case with the BRC compiler and I really doubt - * the latter. Putting one here is compliant to win16 spec, - * but who knows the true value? - */ - put_word(res, 2); /* ResType */ - put_word(res, curg->ncursor); -#if 0 - for(cur = curg->cursorlist; cur; cur = cur->next) -#else - cur = curg->cursorlist; - while(cur->next) - cur = cur->next; - for(; cur; cur = cur->prev) -#endif - { - put_word(res, cur->width); - /* FIXME: The height of a cursor is half the size of - * the bitmap's height. BRC puts the height from the - * BITMAPINFOHEADER here instead of the cursorfile's - * height. MS doesn't seem to care... - */ - put_word(res, cur->height); - /* FIXME: The next two are reversed in BRC and I don't - * know why. Probably a bug. But, we can safely ignore - * it because win16 does not support color cursors. - * A warning should have been generated by the parser. - */ - put_word(res, cur->planes); - put_word(res, cur->bits); - /* FIXME: The +4 is the hotspot in the cursor resource. - * However, I could not find this in the documentation. - * The hotspot bytes must either be included or MS - * doesn't care. - */ - put_dword(res, cur->data->size +4); - put_word(res, cur->id); - } - } - else /* win16 */ - { - put_word(res, 0); /* Reserved */ - put_word(res, 2); /* ResType */ - put_word(res, curg->ncursor); + + put_word(res, 0); /* Reserved */ + /* FIXME: The ResType in the NEWHEADER structure should + * contain 14 according to the MS win32 doc. This is + * not the case with the BRC compiler and I really doubt + * the latter. Putting one here is compliant to win16 spec, + * but who knows the true value? + */ + put_word(res, 2); /* ResType */ + put_word(res, curg->ncursor); #if 0 - for(cur = curg->cursorlist; cur; cur = cur->next) + for(cur = curg->cursorlist; cur; cur = cur->next) #else - cur = curg->cursorlist; - while(cur->next) - cur = cur->next; - for(; cur; cur = cur->prev) + cur = curg->cursorlist; + while(cur->next) + cur = cur->next; + for(; cur; cur = cur->prev) #endif - { - put_word(res, cur->width); - /* FIXME: The height of a cursor is half the size of - * the bitmap's height. BRC puts the height from the - * BITMAPINFOHEADER here instead of the cursorfile's - * height. MS doesn't seem to care... - */ - put_word(res, cur->height); - /* FIXME: The next two are reversed in BRC and I don't - * know why. Probably a bug. But, we can safely ignore - * it because win16 does not support color cursors. - * A warning should have been generated by the parser. - */ - put_word(res, cur->planes); - put_word(res, cur->bits); - /* FIXME: The +4 is the hotspot in the cursor resource. - * However, I could not find this in the documentation. - * The hotspot bytes must either be included or MS - * doesn't care. - */ - put_dword(res, cur->data->size +4); - put_word(res, cur->id); - } - } + { + put_word(res, cur->width); + /* FIXME: The height of a cursor is half the size of + * the bitmap's height. BRC puts the height from the + * BITMAPINFOHEADER here instead of the cursorfile's + * height. MS doesn't seem to care... + */ + put_word(res, cur->height); + /* FIXME: The next two are reversed in BRC and I don't + * know why. Probably a bug. But, we can safely ignore + * it because win16 does not support color cursors. + * A warning should have been generated by the parser. + */ + put_word(res, cur->planes); + put_word(res, cur->bits); + /* FIXME: The +4 is the hotspot in the cursor resource. + * However, I could not find this in the documentation. + * The hotspot bytes must either be included or MS + * doesn't care. + */ + put_dword(res, cur->data->size +4); + put_word(res, cur->id); + } + SetResSize(res, restag); /* Set ResourceSize */ if(win32) put_pad(res); @@ -1103,46 +1065,28 @@ res = new_res(); restag = put_res_header(res, WRC_RT_GROUP_ICON, NULL, name, icog->memopt, &(icog->lvc)); - if(win32) - { - put_word(res, 0); /* Reserved */ - /* FIXME: The ResType in the NEWHEADER structure should - * contain 14 according to the MS win32 doc. This is - * not the case with the BRC compiler and I really doubt - * the latter. Putting one here is compliant to win16 spec, - * but who knows the true value? - */ - put_word(res, 1); /* ResType */ - put_word(res, icog->nicon); - for(ico = icog->iconlist; ico; ico = ico->next) - { - put_byte(res, ico->width); - put_byte(res, ico->height); - put_byte(res, ico->nclr); - put_byte(res, 0); /* Reserved */ - put_word(res, ico->planes); - put_word(res, ico->bits); - put_dword(res, ico->data->size); - put_word(res, ico->id); - } - } - else /* win16 */ - { - put_word(res, 0); /* Reserved */ - put_word(res, 1); /* ResType */ - put_word(res, icog->nicon); - for(ico = icog->iconlist; ico; ico = ico->next) - { - put_byte(res, ico->width); - put_byte(res, ico->height); - put_byte(res, ico->nclr); - put_byte(res, 0); /* Reserved */ - put_word(res, ico->planes); - put_word(res, ico->bits); - put_dword(res, ico->data->size); - put_word(res, ico->id); - } - } + + put_word(res, 0); /* Reserved */ + /* FIXME: The ResType in the NEWHEADER structure should + * contain 14 according to the MS win32 doc. This is + * not the case with the BRC compiler and I really doubt + * the latter. Putting one here is compliant to win16 spec, + * but who knows the true value? + */ + put_word(res, 1); /* ResType */ + put_word(res, icog->nicon); + for(ico = icog->iconlist; ico; ico = ico->next) + { + put_byte(res, ico->width); + put_byte(res, ico->height); + put_byte(res, ico->nclr); + put_byte(res, 0); /* Reserved */ + put_word(res, ico->planes); + put_word(res, ico->bits); + put_dword(res, ico->data->size); + put_word(res, ico->id); + } + SetResSize(res, restag); /* Set ResourceSize */ if(win32) put_pad(res); diff -Nru wine1.7-1.7.28/VERSION wine1.7-1.7.31/VERSION --- wine1.7-1.7.28/VERSION 2014-10-03 07:55:56.000000000 +0000 +++ wine1.7-1.7.31/VERSION 2014-11-14 13:28:17.000000000 +0000 @@ -1 +1 @@ -Wine version 1.7.28 +Wine version 1.7.31