From ddb0ed69a947fdc330d5d8b5a1e7baee8b1b89ae Mon Sep 17 00:00:00 2001 From: Robert Roebling Date: Sat, 21 Oct 2006 17:22:07 +0000 Subject: [PATCH] Fix warning. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42212 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/dcgraph.h | 4 ++-- src/common/graphcmn.cpp | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/include/wx/dcgraph.h b/include/wx/dcgraph.h index 894e33ea56..9d1e4d7fb9 100755 --- a/include/wx/dcgraph.h +++ b/include/wx/dcgraph.h @@ -86,8 +86,8 @@ public: virtual void ComputeScaleAndOrigin(); wxGraphicsContext* GetGraphicContext() { return m_graphicContext; } - virtual void SetGraphicsContext( wxGraphicsContext* ctx ) - { delete m_graphicContext; m_graphicContext = ctx; } + virtual void SetGraphicsContext( wxGraphicsContext* ctx ); + protected: // the true implementations virtual bool DoFloodFill(wxCoord x, wxCoord y, const wxColour& col, diff --git a/src/common/graphcmn.cpp b/src/common/graphcmn.cpp index 0b9c6be864..b66531f910 100644 --- a/src/common/graphcmn.cpp +++ b/src/common/graphcmn.cpp @@ -274,6 +274,11 @@ wxGCDC::wxGCDC() Init(); } +void wxGCDC::SetGraphicsContext( wxGraphicsContext* ctx ) +{ + delete m_graphicContext; + m_graphicContext = ctx; +} wxGCDC::wxGCDC(const wxWindowDC& dc) { -- 2.45.2