ReactOS 0.4.16-dev-125-g798ea90
CreateBitmapIndirect.c File Reference
#include "precomp.h"
Include dependency graph for CreateBitmapIndirect.c:

Go to the source code of this file.

Functions

void Test_CreateBitmapIndirect ()
 
 START_TEST (CreateBitmapIndirect)
 

Function Documentation

◆ START_TEST()

START_TEST ( CreateBitmapIndirect  )

Definition at line 74 of file CreateBitmapIndirect.c.

75{
77}
void Test_CreateBitmapIndirect()

◆ Test_CreateBitmapIndirect()

void Test_CreateBitmapIndirect ( )

Definition at line 10 of file CreateBitmapIndirect.c.

11{
12 HBITMAP win_hBmp;
13 BITMAP win_bitmap;
14
15 win_bitmap.bmBits = 0;
16 win_bitmap.bmBitsPixel = 1;
17 win_bitmap.bmHeight = 0;
18 win_bitmap.bmPlanes = 1;
19 win_bitmap.bmType = 1;
20 win_bitmap.bmWidth = 0;
21 win_bitmap.bmWidthBytes = 2;
22 win_hBmp = CreateBitmapIndirect(&win_bitmap);
23 ok(win_hBmp != 0, "CreateBitmapIndirect failed\n");
24
25 DeleteObject(win_hBmp);
26
27 RtlZeroMemory(&win_bitmap,sizeof(BITMAP));
28 win_bitmap.bmBits = 0;
29 win_bitmap.bmBitsPixel = 1;
30 win_bitmap.bmHeight = 0;
31 win_bitmap.bmPlanes = 1;
32 win_bitmap.bmType = 1;
33 win_bitmap.bmWidth = 0;
34 win_bitmap.bmWidthBytes = 1;
35 win_hBmp = CreateBitmapIndirect(&win_bitmap);
36 ok(win_hBmp == 0, "CreateBitmapIndirect succeeded\n");
37
38 RtlZeroMemory(&win_bitmap,sizeof(BITMAP));
39 win_bitmap.bmBits = 0;
40 win_bitmap.bmBitsPixel = 1;
41 win_bitmap.bmHeight = 0;
42 win_bitmap.bmPlanes = 1;
43 win_bitmap.bmType = 1;
44 win_bitmap.bmWidth = 0;
45 win_bitmap.bmWidthBytes = 3;
46 win_hBmp = CreateBitmapIndirect(&win_bitmap);
47 ok(win_hBmp == 0, "CreateBitmapIndirect succeeded\n");
48
49 RtlZeroMemory(&win_bitmap,sizeof(BITMAP));
50 win_bitmap.bmBits = 0;
51 win_bitmap.bmBitsPixel = 1;
52 win_bitmap.bmHeight = 0;
53 win_bitmap.bmPlanes = 1;
54 win_bitmap.bmType = 1;
55 win_bitmap.bmWidth = 0;
56 win_bitmap.bmWidthBytes = 4;
57 win_hBmp = CreateBitmapIndirect(&win_bitmap);
58 ok(win_hBmp != 0, "CreateBitmapIndirect failed\n");
59
60 RtlZeroMemory(&win_bitmap,sizeof(BITMAP));
61 win_bitmap.bmBits = 0;
62 win_bitmap.bmBitsPixel = 8;
63 win_bitmap.bmHeight = 0xF000;
64 win_bitmap.bmPlanes = 1;
65 win_bitmap.bmType = 1;
66 win_bitmap.bmWidth = 0x8000;
67 win_bitmap.bmWidthBytes = win_bitmap.bmWidth;
68 win_hBmp = CreateBitmapIndirect(&win_bitmap);
69 //ok(win_hBmp != 0, "CreateBitmapIndirect failed\n"); // fails on win 2003
70
71 DeleteObject(win_hBmp);
72}
#define ok(value,...)
Definition: atltest.h:57
pKey DeleteObject()
static HBITMAP
Definition: button.c:44
Definition: bl.h:1331
#define RtlZeroMemory(Destination, Length)
Definition: typedefs.h:262
HBITMAP WINAPI CreateBitmapIndirect(_In_ const BITMAP *pbm)

Referenced by START_TEST().