Commit 8e5665c2 authored by dickelbeck's avatar dickelbeck

added calls to bool EDA_Rect::Intersects()

parent c6cee52c
......@@ -5,6 +5,16 @@ Started 2007-June-11
Please add newer entries at the top, list the date and your name with
email address.
2008-Mar-13 UPDATE Dick Hollenbeck <dick@softplc.com>
================================================================================
+all
Added bool EDA_Rect::Intersects().
+eeschema
Added provisionary calls to eeschema/eeredraw.cpp for
if( panel->m_ClipBox.Intersects( item->GetBoundingBox() ) )
2008-Mar-11 UPDATE Per Uddén <p.udden@telia.com>
================================================================================
+3d-viewer
......
......@@ -158,24 +158,14 @@ void WinEDA_DrawPanel::PrintPage( wxDC* DC, bool Print_Sheet_Ref, int PrintMask
void RedrawStructList( WinEDA_DrawPanel* panel, wxDC* DC,
EDA_BaseStruct* Structs, int DrawMode, int Color )
{
#if 0
// enable this when we have virtual GetBoundingBox():
wxRegion upd = panel->GetUpdateRegion(); // get the update rect list
// get the union of all rectangles in the update region, 'upd'
wxRect dirtyRects = upd.GetBox();
EDA_Rect boxtest;
#endif
while( Structs )
{
if( Structs->Type() == DRAW_PICK_ITEM_STRUCT_TYPE )
{
EDA_BaseStruct* item = ( (DrawPickedStruct*) Structs )->m_PickedStruct;
// if( dirtyRects.Intersects( item->GetBoundingBox() ) )
// uncomment line below when there is a virtual EDA_BaseStruct::GetBoundingBox()
// if( panel->m_ClipBox.Intersects( item->GetBoundingBox() ) )
{
RedrawOneStruct( panel, DC, item, DrawMode, Color );
}
......@@ -184,7 +174,8 @@ void RedrawStructList( WinEDA_DrawPanel* panel, wxDC* DC,
{
if( !(Structs->m_Flags & IS_MOVED) )
{
// if( dirtyRects.Intersects( Structs->GetBoundingBox() ) )
// uncomment line below when there is a virtual EDA_BaseStruct::GetBoundingBox()
// if( panel->m_ClipBox.Intersects( Structs->GetBoundingBox() ) )
RedrawOneStruct( panel, DC, Structs, DrawMode, Color );
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment