Mercurial > projects > dwt-win
comparison dwt/dnd/ImageTransfer.d @ 237:e2affbeb686d
Making tango.sys.win32.Types and dwt.internal.win32.WINTYPES to match common declaration. Make ansi charactars of type ubyte.
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Thu, 19 Jun 2008 03:25:36 +0200 |
parents | 36f5cb12e1a2 |
children | fd9c62a2998e |
comparison
equal
deleted
inserted
replaced
236:9c1bb90eba13 | 237:e2affbeb686d |
---|---|
180 if (bmiHeader.biHeight < 0) { | 180 if (bmiHeader.biHeight < 0) { |
181 OS.MoveMemory(pBits, bits, bmiHeader.biSizeImage); | 181 OS.MoveMemory(pBits, bits, bmiHeader.biSizeImage); |
182 } else { | 182 } else { |
183 DIBSECTION dib; | 183 DIBSECTION dib; |
184 OS.GetObject(memDib, DIBSECTION.sizeof, &dib); | 184 OS.GetObject(memDib, DIBSECTION.sizeof, &dib); |
185 int biHeight = dib.biHeight; | 185 int biHeight = dib.dsBmih.biHeight; |
186 int scanline = dib.biSizeImage / biHeight; | 186 int scanline = dib.dsBmih.biSizeImage / biHeight; |
187 auto pDestBits = pBits; | 187 auto pDestBits = pBits; |
188 auto pSourceBits = bits + scanline * (biHeight - 1); | 188 auto pSourceBits = bits + scanline * (biHeight - 1); |
189 for (int i = 0; i < biHeight; i++) { | 189 for (int i = 0; i < biHeight; i++) { |
190 OS.MoveMemory(pDestBits, pSourceBits, scanline); | 190 OS.MoveMemory(pDestBits, pSourceBits, scanline); |
191 pDestBits += scanline; | 191 pDestBits += scanline; |