From fac5057e9398d478ed4f5730306132b4ad095aa3 Mon Sep 17 00:00:00 2001 From: Regis Cosnier Date: Thu, 14 Mar 2019 23:19:48 +0100 Subject: [PATCH] - Fix the red and blue color inversion 2. --- app/src/main/cpp/win32-layer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/cpp/win32-layer.c b/app/src/main/cpp/win32-layer.c index 15b6718..5237dd8 100644 --- a/app/src/main/cpp/win32-layer.c +++ b/app/src/main/cpp/win32-layer.c @@ -1583,9 +1583,9 @@ UINT SetDIBColorTable(HDC hdc, UINT iStart, UINT cEntries, CONST RGBQUAD *prgbq && hdc->realizedPalette->paletteLog->palNumEntries > 0 && iStart < hdc->realizedPalette->paletteLog->palNumEntries) { PALETTEENTRY * palPalEntry = hdc->realizedPalette->paletteLog->palPalEntry; for (int i = iStart, j = 0; i < cEntries; i++, j++) { - palPalEntry[i].peRed = prgbq[j].rgbBlue; + palPalEntry[i].peRed = prgbq[j].rgbRed; palPalEntry[i].peGreen = prgbq[j].rgbGreen; - palPalEntry[i].peBlue = prgbq[j].rgbRed; + palPalEntry[i].peBlue = prgbq[j].rgbBlue; palPalEntry[i].peFlags = 0; } }