fixing reset clip

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42828 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor 2006-10-31 10:40:51 +00:00
parent 2986407b54
commit a7868cdf6a

View File

@ -1312,8 +1312,15 @@ void wxMacCoreGraphicsContext::ResetClip()
{
if ( m_cgContext )
{
// there is no way for clearing the clip, we can only revert to the stored
// state, but then we have to make sure everything else is NOT restored
CGAffineTransform transform = CGContextGetCTM( m_cgContext );
CGContextRestoreGState( m_cgContext );
CGContextSaveGState( m_cgContext );
CGAffineTransform transformNew = CGContextGetCTM( m_cgContext );
transformNew = CGAffineTransformInvert( transformNew ) ;
CGContextConcatCTM( m_cgContext, transformNew);
CGContextConcatCTM( m_cgContext, transform);
}
else
{