X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/925e9792d32e353233985f53a4845f154e455a58..48ac3cf8e054db7db5a6d8342427a6d56756b524:/samples/dragimag/dragimag.cpp diff --git a/samples/dragimag/dragimag.cpp b/samples/dragimag/dragimag.cpp index 974ffe9339..187c696f8a 100644 --- a/samples/dragimag/dragimag.cpp +++ b/samples/dragimag/dragimag.cpp @@ -188,15 +188,7 @@ void MyCanvas::OnMouseEvent(wxMouseEvent& event) } case SHAPE_DRAG_ICON: { - // Can anyone explain why this test is necessary, - // to prevent a gcc error? -#if defined(__WXMOTIF__) || defined(__WXX11__) - wxIcon icon(dragicon_xpm); -#else - wxIcon icon(wxICON(dragicon)); -#endif - - m_dragImage = new wxDragImage(icon, wxCursor(wxCURSOR_HAND)); + m_dragImage = new wxDragImage(wxICON(dragicon), wxCursor(wxCURSOR_HAND)); break; } } @@ -476,7 +468,7 @@ DragShape::DragShape(const wxBitmap& bitmap) bool DragShape::HitTest(const wxPoint& pt) const { wxRect rect(GetRect()); - return rect.Inside(pt.x, pt.y); + return rect.Contains(pt.x, pt.y); } bool DragShape::Draw(wxDC& dc, int op)