wxGLCanvas works again

added GTK 1.2 logical functions


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2268 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling 1999-04-24 10:18:09 +00:00
parent 9f06bcb3b8
commit c96faa7c9b
3 changed files with 31 additions and 6 deletions

View File

@ -1036,8 +1036,21 @@ void wxWindowDC::SetLogicalFunction( int function )
GdkFunction mode = GDK_COPY;
switch (function)
{
case wxXOR: mode = GDK_INVERT; break;
case wxINVERT: mode = GDK_INVERT; break;
case wxXOR: mode = GDK_INVERT; break;
case wxINVERT: mode = GDK_INVERT; break;
#if (GDK_MINOR_VERSION > 0)
case wxOR_REVERSE: mode = GDK_OR_REVERSE; break;
case wxAND_REVERSE: mode = GDK_AND_REVERSE; break;
case wxCLEAR: mode = GDK_CLEAR; break;
case wxSET: mode = GDK_SET; break;
case wxOR_INVERT: mode = GDK_OR_INVERT; break;
case wxAND: mode = GDK_AND; break;
case wxOR: mode = GDK_OR; break;
case wxEQUIV: mode = GDK_EQUIV; break;
case wxNAND: mode = GDK_NAND; break;
case wxAND_INVERT: mode = GDK_AND_INVERT; break;
/* ? wxSRC_INVERT GDK_AND_REVERSE, GDK_OR_REVERSE, GDK_OR_INVERT */
#endif
default: break;
}

View File

@ -1036,8 +1036,21 @@ void wxWindowDC::SetLogicalFunction( int function )
GdkFunction mode = GDK_COPY;
switch (function)
{
case wxXOR: mode = GDK_INVERT; break;
case wxINVERT: mode = GDK_INVERT; break;
case wxXOR: mode = GDK_INVERT; break;
case wxINVERT: mode = GDK_INVERT; break;
#if (GDK_MINOR_VERSION > 0)
case wxOR_REVERSE: mode = GDK_OR_REVERSE; break;
case wxAND_REVERSE: mode = GDK_AND_REVERSE; break;
case wxCLEAR: mode = GDK_CLEAR; break;
case wxSET: mode = GDK_SET; break;
case wxOR_INVERT: mode = GDK_OR_INVERT; break;
case wxAND: mode = GDK_AND; break;
case wxOR: mode = GDK_OR; break;
case wxEQUIV: mode = GDK_EQUIV; break;
case wxNAND: mode = GDK_NAND; break;
case wxAND_INVERT: mode = GDK_AND_INVERT; break;
/* ? wxSRC_INVERT GDK_AND_REVERSE, GDK_OR_REVERSE, GDK_OR_INVERT */
#endif
default: break;
}

View File

@ -326,8 +326,7 @@ void wxGLCanvas::DoSetSize( int x, int y, int width, int height, int sizeFlags )
if ((m_maxWidth != -1) && (m_width > m_maxWidth)) m_width = m_maxWidth;
if ((m_maxHeight != -1) && (m_height > m_maxHeight)) m_height = m_maxHeight;
wxPoint pt( m_parent->GetClientAreaOrigin() );
gtk_myfixed_move( GTK_MYFIXED(m_parent->m_wxwindow), m_widget, m_x+pt.x, m_y+pt.y );
gtk_myfixed_move( GTK_MYFIXED(m_parent->m_wxwindow), m_widget, m_x, m_y );
if ((old_width != m_width) || (old_height != m_height))
{