X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3454ecd508f3d5a2a31f1c1d9048de80763135d1..fbe2ca438b746a509ca04c456166b984650ecaac:/contrib/src/ogl/basic.cpp diff --git a/contrib/src/ogl/basic.cpp b/contrib/src/ogl/basic.cpp index 0e51bd54fa..77c69ff50a 100644 --- a/contrib/src/ogl/basic.cpp +++ b/contrib/src/ogl/basic.cpp @@ -1312,7 +1312,7 @@ void wxShape::OnDragLeft(bool draw, double x, double y, int keys, int attachment dc.SetLogicalFunction(OGLRBLF); - wxPen dottedPen(wxColour(0, 0, 0), 1, wxDOT); + wxPen dottedPen(*wxBLACK, 1, wxDOT); dc.SetPen(dottedPen); dc.SetBrush(* wxTRANSPARENT_BRUSH); @@ -1357,7 +1357,7 @@ void wxShape::OnBeginDragLeft(double x, double y, int keys, int attachment) // m_xpos = xx; m_ypos = yy; dc.SetLogicalFunction(OGLRBLF); - wxPen dottedPen(wxColour(0, 0, 0), 1, wxDOT); + wxPen dottedPen(*wxBLACK, 1, wxDOT); dc.SetPen(dottedPen); dc.SetBrush((* wxTRANSPARENT_BRUSH)); @@ -1369,6 +1369,8 @@ void wxShape::OnBeginDragLeft(double x, double y, int keys, int attachment) void wxShape::OnEndDragLeft(double x, double y, int keys, int attachment) { + if (!m_draggable) + return; m_canvas->ReleaseMouse(); if ((m_sensitivity & OP_DRAG_LEFT) != OP_DRAG_LEFT) { @@ -2711,7 +2713,9 @@ bool wxShape::GetAttachmentPosition(int attachment, double *x, double *y, double left = (double)(m_xpos - w/2.0); double right = (double)(m_xpos + w/2.0); +#if 0 /* bool isEnd = */ (line && line->IsEnd(this)); +#endif int physicalAttachment = LogicalToPhysicalAttachment(attachment);