From: Jamie Gadd Date: Thu, 13 Jul 2006 00:41:55 +0000 (+0000) Subject: Don't set background of wxMemoryDC before selecting bitmap into it. X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/90d05e9b6efd5ffd7f61eac0b365924fa7419ba4 Don't set background of wxMemoryDC before selecting bitmap into it. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40080 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/samples/controls/controls.cpp b/samples/controls/controls.cpp index c0b9d7924e..63c92a6883 100644 --- a/samples/controls/controls.cpp +++ b/samples/controls/controls.cpp @@ -960,9 +960,9 @@ MyPanel::MyPanel( wxFrame *frame, int x, int y, int w, int h ) wxBitmap bitmap( 100, 100 ); wxMemoryDC dc; - dc.SetBackground(*wxGREEN); dc.SelectObject( bitmap ); - dc.SetPen(*wxGREEN_PEN); + dc.SetBackground(*wxGREEN); + dc.SetPen(*wxRED_PEN); dc.Clear(); dc.DrawEllipse(5, 5, 90, 90); dc.DrawText(_T("Bitmap"), 30, 40);