Fix assert in initial call to wxPostScriptDC::SetPen().
Attempt to use wxPen::GetStyle() on the initially invalid pen resulted in an assert, so don't do it and test for pen validity explicitly. Closes #13524. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69243 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1135,7 +1135,7 @@ void wxPostScriptDCImpl::SetPen( const wxPen& pen )
|
|||||||
|
|
||||||
if (!pen.IsOk()) return;
|
if (!pen.IsOk()) return;
|
||||||
|
|
||||||
int oldStyle = m_pen.GetStyle();
|
int oldStyle = m_pen.IsOk() ? m_pen.GetStyle() : wxPENSTYLE_INVALID;
|
||||||
|
|
||||||
m_pen = pen;
|
m_pen = pen;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user