X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fe2e43661ec454a020e57deda94db36ca26f8a1e..2b4f3c9f768c91d1927c263f5db644cc16fca0b9:/src/motif/dcclient.cpp diff --git a/src/motif/dcclient.cpp b/src/motif/dcclient.cpp index 2af3787acc..7c1602b346 100644 --- a/src/motif/dcclient.cpp +++ b/src/motif/dcclient.cpp @@ -45,6 +45,7 @@ #include "wx/window.h" #include "wx/app.h" #include "wx/image.h" +#include "wx/log.h" #include @@ -230,12 +231,15 @@ wxWindowDC::~wxWindowDC() m_userRegion = (WXRegion) 0; } -void wxWindowDC::DoFloodFill( wxCoord WXUNUSED(x1), wxCoord WXUNUSED(y1), - const wxColour& WXUNUSED(col), int WXUNUSED(style) ) +extern bool wxDoFloodFill(wxDC *dc, wxCoord x, wxCoord y, + const wxColour & col, int style); + +bool wxWindowDC::DoFloodFill(wxCoord x, wxCoord y, + const wxColour& col, int style) { - wxFAIL_MSG("not implemented"); + return wxDoFloodFill(this, x, y, col, style); } - + bool wxWindowDC::DoGetPixel( wxCoord x1, wxCoord y1, wxColour *col ) const { // Generic (and therefore rather inefficient) method. @@ -871,7 +875,8 @@ void wxWindowDC::DoDrawIcon( const wxIcon &icon, wxCoord x, wxCoord y) // TODO: use scaled Blit e.g. as per John Price's implementation in Contrib/Utilities bool wxWindowDC::DoBlit( wxCoord xdest, wxCoord ydest, wxCoord width, wxCoord height, - wxDC *source, wxCoord xsrc, wxCoord ysrc, int rop, bool useMask ) + wxDC *source, wxCoord xsrc, wxCoord ysrc, int rop, bool useMask, + wxCoord xsrcMask, wxCoord ysrcMask ) { wxCHECK_MSG( Ok(), FALSE, "invalid dc" ); @@ -894,6 +899,12 @@ bool wxWindowDC::DoBlit( wxCoord xdest, wxCoord ydest, wxCoord width, wxCoord he double scaleX, scaleY; GetUserScale(& scaleX, & scaleY); + /* TODO: use the mask origin when drawing transparently */ + if (xsrcMask == -1 && ysrcMask == -1) + { + xsrcMask = xsrc; ysrcMask = ysrc; + } + // Sorry, can't scale masks just yet if (!useMask && (scaleX != 1.0 || scaleY != 1.0) && sourceDC->IsKindOf(CLASSINFO(wxMemoryDC))) {