From 52c6c5e83333fd2ea387cafee898696df938e3d6 Mon Sep 17 00:00:00 2001 From: Magnus Olsen Date: Thu, 14 Jun 2007 22:01:22 +0000 Subject: [PATCH] commit more test for setcooperlevel, not all test are in that we need. svn path=/trunk/; revision=27180 --- rostests/dxtest/ddraw/DDraw/create.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/rostests/dxtest/ddraw/DDraw/create.cpp b/rostests/dxtest/ddraw/DDraw/create.cpp index 01eb88b0b71..21ccd25c177 100644 --- a/rostests/dxtest/ddraw/DDraw/create.cpp +++ b/rostests/dxtest/ddraw/DDraw/create.cpp @@ -60,6 +60,11 @@ BOOL Test_SetCooperativeLevel (INT* passed, INT* failed) /* The Test */ TEST ( DirectDraw->SetCooperativeLevel (NULL, DDSCL_FULLSCREEN) == DDERR_INVALIDPARAMS ); TEST ( DirectDraw->SetCooperativeLevel (hwnd, DDSCL_FULLSCREEN) == DDERR_INVALIDPARAMS ); + + TEST ( DirectDraw->SetCooperativeLevel (hwnd, DDSCL_NORMAL) == DD_OK ); + TEST ( DirectDraw->Compact() == DDERR_NOEXCLUSIVEMODE ); + + TEST ( DirectDraw->SetCooperativeLevel (NULL, DDSCL_FULLSCREEN | DDSCL_EXCLUSIVE) == DDERR_INVALIDPARAMS ); TEST ( DirectDraw->SetCooperativeLevel (hwnd, DDSCL_FULLSCREEN) == DDERR_INVALIDPARAMS); TEST ( DirectDraw->SetCooperativeLevel (hwnd, DDSCL_NORMAL | DDSCL_ALLOWMODEX) == DDERR_INVALIDPARAMS ); @@ -68,7 +73,9 @@ BOOL Test_SetCooperativeLevel (INT* passed, INT* failed) TEST ( DirectDraw->SetCooperativeLevel (hwnd, DDSCL_FULLSCREEN | DDSCL_EXCLUSIVE) == DD_OK); TEST ( DirectDraw->Compact() == DD_OK ); TEST ( DirectDraw->SetCooperativeLevel (hwnd, DDSCL_FULLSCREEN | DDSCL_EXCLUSIVE | DDSCL_ALLOWMODEX) == DD_OK); + TEST ( DirectDraw->Compact() == DD_OK ); TEST ( DirectDraw->SetCooperativeLevel (NULL, DDSCL_NORMAL) == DD_OK ); + TEST ( DirectDraw->Compact() == DDERR_NOEXCLUSIVEMODE ); TEST ( DirectDraw->SetCooperativeLevel (hwnd, DDSCL_NORMAL) == DD_OK ); TEST ( DirectDraw->Compact() == DDERR_NOEXCLUSIVEMODE );