wxDC::GetHandle support for wxGTK
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72226 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -136,6 +136,7 @@ public:
|
||||
virtual void EndPage() { }
|
||||
|
||||
virtual GdkWindow* GetGDKWindow() const { return NULL; }
|
||||
virtual void* GetHandle() const { return GetGDKWindow(); }
|
||||
|
||||
// base class pure virtuals implemented here
|
||||
virtual void DoSetClippingRegion(wxCoord x, wxCoord y, wxCoord width, wxCoord height);
|
||||
|
@@ -39,6 +39,7 @@ public:
|
||||
// overridden from wxDCImpl
|
||||
virtual void DoGetSize( int *width, int *height ) const;
|
||||
virtual wxBitmap DoGetAsBitmap(const wxRect *subrect) const;
|
||||
virtual void* GetHandle() const;
|
||||
|
||||
// overridden for wxMemoryDC Impl
|
||||
virtual void DoSelect(const wxBitmap& bitmap);
|
||||
|
@@ -227,6 +227,7 @@ public:
|
||||
bool IsOk() const;
|
||||
|
||||
virtual void* GetCairoContext() const;
|
||||
virtual void* GetHandle() const;
|
||||
|
||||
bool CanDrawBitmap() const { return true; }
|
||||
void Clear();
|
||||
|
@@ -164,3 +164,8 @@ wxBitmap& wxMemoryDCImpl::GetSelectedBitmap()
|
||||
return m_selected;
|
||||
}
|
||||
|
||||
void* wxMemoryDCImpl::GetHandle() const
|
||||
{
|
||||
const wxBitmap& bmp = GetSelectedBitmap();
|
||||
return bmp.GetPixmap();
|
||||
}
|
||||
|
@@ -1216,6 +1216,11 @@ void* wxGtkPrinterDCImpl::GetCairoContext() const
|
||||
return (void*) cairo_reference( m_cairo );
|
||||
}
|
||||
|
||||
void* wxGtkPrinterDCImpl::GetHandle() const
|
||||
{
|
||||
return GetCairoContext();
|
||||
}
|
||||
|
||||
bool wxGtkPrinterDCImpl::DoFloodFill(wxCoord WXUNUSED(x1),
|
||||
wxCoord WXUNUSED(y1),
|
||||
const wxColour& WXUNUSED(col),
|
||||
|
Reference in New Issue
Block a user