Commit 3e5dd549 authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

d3dx9/tests: Use explicit A calls.

parent 90bd39c4
TESTDLL = d3dx9_36.dll TESTDLL = d3dx9_36.dll
IMPORTS = d3dx9 d3d9 user32 gdi32 IMPORTS = d3dx9 d3d9 user32 gdi32
EXTRADEFS = -U__WINESRC__ -DWINE_STRICT_PROTOTYPES -DWINE_NO_NAMELESS_EXTENSION -DWIDL_C_INLINE_WRAPPERS
C_SRCS = \ C_SRCS = \
asm.c \ asm.c \
......
...@@ -305,7 +305,7 @@ static void test_ID3DXSprite(IDirect3DDevice9 *device) ...@@ -305,7 +305,7 @@ static void test_ID3DXSprite(IDirect3DDevice9 *device)
static void test_ID3DXFont(IDirect3DDevice9 *device) static void test_ID3DXFont(IDirect3DDevice9 *device)
{ {
D3DXFONT_DESC desc; D3DXFONT_DESCA desc;
ID3DXFont *font; ID3DXFont *font;
HRESULT hr; HRESULT hr;
int ref; int ref;
...@@ -1225,13 +1225,13 @@ START_TEST(core) ...@@ -1225,13 +1225,13 @@ START_TEST(core)
D3DPRESENT_PARAMETERS d3dpp; D3DPRESENT_PARAMETERS d3dpp;
HRESULT hr; HRESULT hr;
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
d3d = Direct3DCreate9(D3D_SDK_VERSION); {
if (!wnd) {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
} }
if (!d3d) { if (!(d3d = Direct3DCreate9(D3D_SDK_VERSION)))
{
skip("Couldn't create IDirect3D9 object\n"); skip("Couldn't create IDirect3D9 object\n");
DestroyWindow(wnd); DestroyWindow(wnd);
return; return;
......
...@@ -2691,13 +2691,13 @@ START_TEST(effect) ...@@ -2691,13 +2691,13 @@ START_TEST(effect)
HRESULT hr; HRESULT hr;
ULONG count; ULONG count;
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
d3d = Direct3DCreate9(D3D_SDK_VERSION); {
if (!wnd) {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
} }
if (!d3d) { if (!(d3d = Direct3DCreate9(D3D_SDK_VERSION)))
{
skip("Couldn't create IDirect3D9 object\n"); skip("Couldn't create IDirect3D9 object\n");
DestroyWindow(wnd); DestroyWindow(wnd);
return; return;
......
...@@ -123,13 +123,13 @@ START_TEST(line) ...@@ -123,13 +123,13 @@ START_TEST(line)
D3DPRESENT_PARAMETERS d3dpp; D3DPRESENT_PARAMETERS d3dpp;
HRESULT hr; HRESULT hr;
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
d3d = Direct3DCreate9(D3D_SDK_VERSION); {
if (!wnd) {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
} }
if (!d3d) { if (!(d3d = Direct3DCreate9(D3D_SDK_VERSION)))
{
skip("Couldn't create IDirect3D9 object\n"); skip("Couldn't create IDirect3D9 object\n");
DestroyWindow(wnd); DestroyWindow(wnd);
return; return;
......
...@@ -1424,14 +1424,12 @@ static void test_setting_constants(void) ...@@ -1424,14 +1424,12 @@ static void test_setting_constants(void)
ULONG refcnt; ULONG refcnt;
/* Create the device to use for our tests */ /* Create the device to use for our tests */
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
d3d = Direct3DCreate9(D3D_SDK_VERSION);
if (!wnd)
{ {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
} }
if (!d3d) if (!(d3d = Direct3DCreate9(D3D_SDK_VERSION)))
{ {
skip("Couldn't create IDirect3D9 object\n"); skip("Couldn't create IDirect3D9 object\n");
DestroyWindow(wnd); DestroyWindow(wnd);
...@@ -6070,14 +6068,12 @@ static void test_registerset(void) ...@@ -6070,14 +6068,12 @@ static void test_registerset(void)
D3DCAPS9 caps; D3DCAPS9 caps;
/* Create the device to use for our tests */ /* Create the device to use for our tests */
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
d3d = Direct3DCreate9(D3D_SDK_VERSION);
if (!wnd)
{ {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
} }
if (!d3d) if (!(d3d = Direct3DCreate9(D3D_SDK_VERSION)))
{ {
skip("Couldn't create IDirect3D9 object\n"); skip("Couldn't create IDirect3D9 object\n");
DestroyWindow(wnd); DestroyWindow(wnd);
...@@ -6376,14 +6372,12 @@ static void test_registerset_defaults(void) ...@@ -6376,14 +6372,12 @@ static void test_registerset_defaults(void)
D3DCAPS9 caps; D3DCAPS9 caps;
/* Create the device to use for our tests */ /* Create the device to use for our tests */
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
d3d = Direct3DCreate9(D3D_SDK_VERSION);
if (!wnd)
{ {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
} }
if (!d3d) if (!(d3d = Direct3DCreate9(D3D_SDK_VERSION)))
{ {
skip("Couldn't create IDirect3D9 object\n"); skip("Couldn't create IDirect3D9 object\n");
DestroyWindow(wnd); DestroyWindow(wnd);
......
...@@ -665,19 +665,23 @@ static void test_D3DXLoadSurface(IDirect3DDevice9 *device) ...@@ -665,19 +665,23 @@ static void test_D3DXLoadSurface(IDirect3DDevice9 *device)
/* D3DXLoadSurfaceFromResource */ /* D3DXLoadSurfaceFromResource */
hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, MAKEINTRESOURCE(IDB_BITMAP_1x1), NULL, D3DX_DEFAULT, 0, NULL); hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL,
MAKEINTRESOURCEA(IDB_BITMAP_1x1), NULL, D3DX_DEFAULT, 0, NULL);
ok(hr == D3D_OK, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3D_OK); ok(hr == D3D_OK, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3D_OK);
hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, MAKEINTRESOURCE(IDD_BITMAPDATA_1x1), NULL, D3DX_DEFAULT, 0, NULL); hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL,
MAKEINTRESOURCEA(IDD_BITMAPDATA_1x1), NULL, D3DX_DEFAULT, 0, NULL);
ok(hr == D3D_OK, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3D_OK); ok(hr == D3D_OK, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3D_OK);
hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, NULL, NULL, D3DX_DEFAULT, 0, NULL); hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, NULL, NULL, D3DX_DEFAULT, 0, NULL);
ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA); ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA);
hr = D3DXLoadSurfaceFromResourceA(NULL, NULL, NULL, NULL, MAKEINTRESOURCE(IDB_BITMAP_1x1), NULL, D3DX_DEFAULT, 0, NULL); hr = D3DXLoadSurfaceFromResourceA(NULL, NULL, NULL, NULL,
MAKEINTRESOURCEA(IDB_BITMAP_1x1), NULL, D3DX_DEFAULT, 0, NULL);
ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL); ok(hr == D3DERR_INVALIDCALL, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DERR_INVALIDCALL);
hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL, MAKEINTRESOURCE(IDS_STRING), NULL, D3DX_DEFAULT, 0, NULL); hr = D3DXLoadSurfaceFromResourceA(surf, NULL, NULL, NULL,
MAKEINTRESOURCEA(IDS_STRING), NULL, D3DX_DEFAULT, 0, NULL);
ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA); ok(hr == D3DXERR_INVALIDDATA, "D3DXLoadSurfaceFromResource returned %#x, expected %#x\n", hr, D3DXERR_INVALIDDATA);
...@@ -1277,8 +1281,8 @@ START_TEST(surface) ...@@ -1277,8 +1281,8 @@ START_TEST(surface)
D3DPRESENT_PARAMETERS d3dpp; D3DPRESENT_PARAMETERS d3dpp;
HRESULT hr; HRESULT hr;
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
if (!wnd) { {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
} }
......
...@@ -1786,8 +1786,8 @@ START_TEST(texture) ...@@ -1786,8 +1786,8 @@ START_TEST(texture)
D3DPRESENT_PARAMETERS d3dpp; D3DPRESENT_PARAMETERS d3dpp;
HRESULT hr; HRESULT hr;
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
if (!wnd) { {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
} }
......
...@@ -267,8 +267,7 @@ START_TEST(volume) ...@@ -267,8 +267,7 @@ START_TEST(volume)
D3DPRESENT_PARAMETERS d3dpp; D3DPRESENT_PARAMETERS d3dpp;
HRESULT hr; HRESULT hr;
wnd = CreateWindow("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL); if (!(wnd = CreateWindowA("static", "d3dx9_test", 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL)))
if (!wnd)
{ {
skip("Couldn't create application window\n"); skip("Couldn't create application window\n");
return; return;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment