git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@9575
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
wxMemoryDC::~wxMemoryDC()
{
wxMemoryDC::~wxMemoryDC()
{
+ m_vSelectedBitmap.SetSelectedInto(NULL);
if (m_hPS != NULLHANDLE)
::GpiDestroyPS(m_hPS);
if (m_hDC != NULLHANDLE)
if (m_hPS != NULLHANDLE)
::GpiDestroyPS(m_hPS);
if (m_hDC != NULLHANDLE)
wxString sStr = wxStripMenuCodes(m_strName);
wxString sStr = wxStripMenuCodes(m_strName);
-#if 0
- wxString sTgt = "\t";
- size_t nIndex;
-
- nIndex = sStr.Find(sTgt.c_str());
- if (nIndex != -1)
- sStr.Remove(nIndex);
- sTgt = "~";
- nIndex = sStr.Find(sTgt.c_str());
- if (nIndex != -1)
- sStr.Replace(sTgt.c_str(), "", TRUE);
-#endif
vDC.GetTextExtent( sStr
,(long *)pWidth
,(long *)pHeight
vDC.GetTextExtent( sStr
,(long *)pWidth
,(long *)pHeight
wxColour vColText;
COLORREF vRef;
RECTL vRect = {rRect.x + 4, rRect.y + 1, rRect.x + (rRect.width - 2), rRect.y + rRect.height};
wxColour vColText;
COLORREF vRef;
RECTL vRect = {rRect.x + 4, rRect.y + 1, rRect.x + (rRect.width - 2), rRect.y + rRect.height};
//
// Use default font if no font set
//
// Use default font if no font set
vRect.xLeft = rRect.x;
vRect.xRight = rRect.x + GetMarginWidth();
vRect.yBottom = rRect.y;
vRect.xLeft = rRect.x;
vRect.xRight = rRect.x + GetMarginWidth();
vRect.yBottom = rRect.y;
- vRect.yTop = rRect.y + m_nHeight;
+ vRect.yTop = rRect.y + m_nHeight - 3;
::WinDrawBitmap( hPS // PS for this menuitem
,hBmpCheck // system checkmark
::WinDrawBitmap( hPS // PS for this menuitem
,hBmpCheck // system checkmark
,rRect.x + GetMarginWidth()
,rRect.y + m_nHeight
};
,rRect.x + GetMarginWidth()
,rRect.y + m_nHeight
};
+ POINTL vPnt1 = {2, 4}; // Leave a little background border
+ POINTL vPnt2 = {rRect.x + GetMarginWidth(), rRect.y + m_nHeight - 3};
LINEBUNDLE vLine;
vLine.lColor = vColBack.GetPixel();
LINEBUNDLE vLine;
vLine.lColor = vColBack.GetPixel();
+ ::GpiMove(hPS, &vPnt1);
::GpiBox( hPS
,DRO_OUTLINE
::GpiBox( hPS
,DRO_OUTLINE