Small testing changes,
Small flicker reduction in wxGrid. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@6126 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2927,7 +2927,7 @@ void wxWindow::Clear()
|
||||
|
||||
if (m_wxwindow && m_wxwindow->window)
|
||||
{
|
||||
gdk_window_clear( m_wxwindow->window );
|
||||
// gdk_window_clear( m_wxwindow->window );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3435,61 +3435,5 @@ void wxWindow::ScrollWindow( int dx, int dy, const wxRect* WXUNUSED(rect) )
|
||||
|
||||
wxCHECK_RET( m_wxwindow != NULL, wxT("window needs client area for scrolling") );
|
||||
|
||||
/*
|
||||
printf( "ScrollWindow: %d %d\n", dx, dy );
|
||||
*/
|
||||
|
||||
gtk_pizza_scroll( GTK_PIZZA(m_wxwindow), -dx, -dy );
|
||||
|
||||
/*
|
||||
if (!m_scrollGC)
|
||||
{
|
||||
m_scrollGC = gdk_gc_new( m_wxwindow->window );
|
||||
gdk_gc_set_exposures( m_scrollGC, TRUE );
|
||||
}
|
||||
|
||||
wxNode *node = m_children.First();
|
||||
while (node)
|
||||
{
|
||||
wxWindow *child = (wxWindow*) node->Data();
|
||||
int sx = 0;
|
||||
int sy = 0;
|
||||
child->GetSize( &sx, &sy );
|
||||
child->SetSize( child->m_x + dx, child->m_y + dy, sx, sy, wxSIZE_ALLOW_MINUS_ONE );
|
||||
node = node->Next();
|
||||
}
|
||||
|
||||
int cw = 0;
|
||||
int ch = 0;
|
||||
GetClientSize( &cw, &ch );
|
||||
int w = cw - abs(dx);
|
||||
int h = ch - abs(dy);
|
||||
|
||||
if ((h < 0) || (w < 0))
|
||||
{
|
||||
Refresh();
|
||||
}
|
||||
else
|
||||
{
|
||||
int s_x = 0;
|
||||
int s_y = 0;
|
||||
if (dx < 0) s_x = -dx;
|
||||
if (dy < 0) s_y = -dy;
|
||||
int d_x = 0;
|
||||
int d_y = 0;
|
||||
if (dx > 0) d_x = dx;
|
||||
if (dy > 0) d_y = dy;
|
||||
|
||||
gdk_window_copy_area( m_wxwindow->window, m_scrollGC, d_x, d_y,
|
||||
m_wxwindow->window, s_x, s_y, w, h );
|
||||
|
||||
wxRect rect;
|
||||
if (dx < 0) rect.x = cw+dx; else rect.x = 0;
|
||||
if (dy < 0) rect.y = ch+dy; else rect.y = 0;
|
||||
if (dy != 0) rect.width = cw; else rect.width = abs(dx);
|
||||
if (dx != 0) rect.height = ch; else rect.height = abs(dy);
|
||||
|
||||
Refresh( TRUE, &rect );
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
Reference in New Issue
Block a user