Use system colours for ownerdrawn highlighting (patch #1555426).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41749 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Neis
2006-10-08 21:30:36 +00:00
parent 7e0fff428f
commit 28206ce84e
2 changed files with 19 additions and 12 deletions

View File

@@ -2704,15 +2704,12 @@ typedef unsigned long HGLOBAL;
/* WIN32 graphics types for OS/2 GPI */
/* RGB under OS2 is more like a PALETTEENTRY struct under Windows so we need a real RGB def */
/* WARNING: The OS/2 headers typedef BYTE simply as 'char'; if the default is signed, all */
/* hell will break loose! */
/* #define OS2RGB(r,g,b) ((DWORD ((BYTE) (b) | ((WORD) (g) << 8)) | (((DWORD)(BYTE)(r)) << 16))) */
#define OS2RGB(r,g,b) ((DWORD)((unsigned char)(b) | ((unsigned char)(g) << 8)) | ((unsigned char)(r) << 16))
typedef unsigned long COLORREF;
#define GetBValue(rgb) ((BYTE)((rgb) >> 16))
#define GetGValue(rgb) ((BYTE)(((WORD)(rgb)) >> 8))
#define GetRValue(rgb) ((BYTE)(rgb))
#define GetRValue(rgb) ((unsigned char)((rgb) >> 16))
#define GetGValue(rgb) ((unsigned char)(((unsigned short)(rgb)) >> 8))
#define GetBValue(rgb) ((unsigned char)(rgb))
#define PALETTEINDEX(i) ((COLORREF)(0x01000000 | (DWORD)(WORD)(i)))
#define PALETTERGB(r,g,b) (0x02000000 | OS2RGB(r,g,b))
/* OS2's RGB/RGB2 is backwards from this */