bool WndMain::OnPaint(LKSurface& Surface, const RECT& Rect) { if(ProgramStarted >= psFirstDrawDone) { Surface.Copy(Rect.left, Rect.top, Rect.right - Rect.left, Rect.bottom - Rect.top, BackBufferSurface, Rect.left, Rect.top); } else { } return true; }
void LKBitmapSurface::CopyTo(LKSurface &other) { assert(this != &other); #ifdef USE_GDI other.Copy(0,0, _Size.cx, _Size.cy, *this, 0, 0); #else if(IsDefined() && other.IsDefined()) { #if defined(ENABLE_OPENGL) static_cast<BufferCanvas*>(_pCanvas)->CopyTo(other); #else Canvas& dst = other; dst.Copy(*_pCanvas); #endif } #endif }