X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/272ebf16f85536aced3277ebd69e0c70eabf8d0a..9894cc01c98b0d6fa960d57e9a6155bbb07ed67b:/src/os2/pen.cpp diff --git a/src/os2/pen.cpp b/src/os2/pen.cpp index 975a8f96f6..a19f195160 100644 --- a/src/os2/pen.cpp +++ b/src/os2/pen.cpp @@ -19,6 +19,7 @@ #include "wx/utils.h" #include "wx/app.h" #include "wx/pen.h" +#include "wx/log.h" #endif #include "wx/os2/private.h" @@ -150,16 +151,16 @@ bool wxPen::RealizeResource() { vError = ::WinGetLastError(vHabmain); sError = wxPMErrorToStr(vError); - wxLogError("Unable to set current color table to RGB mode. Error: %s\n", sError); + wxLogError(_T("Unable to set current color table to RGB mode. Error: %s\n"), sError.c_str()); return FALSE; } if (M_PENDATA->m_nStyle == wxTRANSPARENT) { - return TRUE; + return true; } - COLORREF vPmColour = 0L; - USHORT uLineType = wx2os2PenStyle(M_PENDATA->m_nStyle); + COLORREF vPmColour = 0L; + USHORT uLineType = (USHORT)wx2os2PenStyle(M_PENDATA->m_nStyle); vPmColour = M_PENDATA->m_vColour.GetPixel(); @@ -214,7 +215,7 @@ bool wxPen::RealizeResource() { vError = ::WinGetLastError(vHabmain); sError = wxPMErrorToStr(vError); - wxLogError("Can't set Gpi attributes for a LINEBUNDLE. Error: %s\n", sError); + wxLogError(_T("Can't set Gpi attributes for a LINEBUNDLE. Error: %s\n"), sError.c_str()); return FALSE; } @@ -299,11 +300,12 @@ bool wxPen::RealizeResource() { vError = ::WinGetLastError(vHabmain); sError = wxPMErrorToStr(vError); - wxLogError("Can't set Gpi attributes for an AREABUNDLE. Error: %s\n", sError); + wxLogError(_T("Can't set Gpi attributes for an AREABUNDLE. Error: %s\n"), sError.c_str()); } - return bOk; + + return (bool)bOk; } - return FALSE; + return false; } // end of wxPen::RealizeResource WXHANDLE wxPen::GetResourceHandle() @@ -314,16 +316,14 @@ WXHANDLE wxPen::GetResourceHandle() return (WXHANDLE)M_PENDATA->m_hPen; } // end of wxPen::GetResourceHandle -bool wxPen::FreeResource( - bool bForce -) +bool wxPen::FreeResource( bool WXUNUSED(bForce) ) { if (M_PENDATA && (M_PENDATA->m_hPen != 0)) { M_PENDATA->m_hPen = 0; - return TRUE; + return true; } - else return FALSE; + else return false; } // end of wxPen::FreeResource bool wxPen::IsFree() const @@ -405,10 +405,8 @@ void wxPen::SetStipple( RealizeResource(); } // end of wxPen::SetStipple -void wxPen::SetDashes( - int nNbDashes -, const wxDash* pDash -) +void wxPen::SetDashes( int WXUNUSED(nNbDashes), + const wxDash* WXUNUSED(pDash) ) { // // Does nothing under OS/2 @@ -472,5 +470,3 @@ int wx2os2PenStyle( } return nPMStyle; } // end of wx2os2PenStyle - -