X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/655719367ac5e131d9642e5783f3ecf64d1a3385..ebe47451544561fbe6e57808d604641d24109359:/src/msw/colordlg.cpp diff --git a/src/msw/colordlg.cpp b/src/msw/colordlg.cpp index 53eed0cca9..92036a89af 100644 --- a/src/msw/colordlg.cpp +++ b/src/msw/colordlg.cpp @@ -128,7 +128,12 @@ int wxColourDialog::ShowModal() int i; for (i = 0; i < 16; i++) - custColours[i] = wxColourToRGB(m_colourData.m_custColours[i]); + { + if (m_colourData.m_custColours[i].Ok()) + custColours[i] = wxColourToRGB(m_colourData.m_custColours[i]); + else + custColours[i] = RGB(255,255,255); + } chooseColorStruct.lStructSize = sizeof(CHOOSECOLOR); if ( m_parent )