EESchema improvements and other minor fixes.
* Remove base screen methods from draw frame object and correct current screen methods in derived objects. * Move restore old wires function code into schematic screen object. * Make add junction method use current screen position instead of store position. * Move poly line ghosting function into the delete current segment method as that was the only place is was being used. * Add method to base schematic object of testing if object has a label that can be incremented. * Simplified the schematic hierarchy traversing code. * PCBNew Doxygen warning fixes.
This commit is contained in:
@@ -166,17 +166,16 @@ void BLOCK_SELECTOR::PushItem( ITEM_PICKER& aItem )
|
||||
*/
|
||||
bool EDA_DRAW_FRAME::HandleBlockBegin( wxDC* DC, int key, const wxPoint& startpos )
|
||||
{
|
||||
BLOCK_SELECTOR* Block = &GetBaseScreen()->m_BlockLocate;
|
||||
BLOCK_SELECTOR* Block = &GetScreen()->m_BlockLocate;
|
||||
|
||||
if( ( Block->m_Command != BLOCK_IDLE )
|
||||
|| ( Block->m_State != STATE_NO_BLOCK ) )
|
||||
return FALSE;
|
||||
if( ( Block->m_Command != BLOCK_IDLE ) || ( Block->m_State != STATE_NO_BLOCK ) )
|
||||
return false;
|
||||
|
||||
Block->m_Flags = 0;
|
||||
Block->m_Command = (CmdBlockType) ReturnBlockCommand( key );
|
||||
|
||||
if( Block->m_Command == 0 )
|
||||
return FALSE;
|
||||
return false;
|
||||
|
||||
switch( Block->m_Command )
|
||||
{
|
||||
@@ -205,19 +204,19 @@ bool EDA_DRAW_FRAME::HandleBlockBegin( wxDC* DC, int key, const wxPoint& startpo
|
||||
if( Block->m_ItemsSelection.GetCount() == 0 ) /* No data to paste */
|
||||
{
|
||||
DisplayError( this, wxT( "No Block to paste" ), 20 );
|
||||
GetBaseScreen()->m_BlockLocate.m_Command = BLOCK_IDLE;
|
||||
GetScreen()->m_BlockLocate.m_Command = BLOCK_IDLE;
|
||||
DrawPanel->ManageCurseur = NULL;
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
if( DrawPanel->ManageCurseur == NULL )
|
||||
{
|
||||
Block->m_ItemsSelection.ClearItemsList();
|
||||
DisplayError( this,
|
||||
wxT( "EDA_DRAW_FRAME::HandleBlockBegin() Err: ManageCurseur NULL" ) );
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
Block->m_State = STATE_BLOCK_MOVE;
|
||||
DrawPanel->ManageCurseur( DrawPanel, DC, startpos, FALSE );
|
||||
DrawPanel->ManageCurseur( DrawPanel, DC, startpos, false );
|
||||
break;
|
||||
|
||||
default:
|
||||
@@ -231,7 +230,7 @@ bool EDA_DRAW_FRAME::HandleBlockBegin( wxDC* DC, int key, const wxPoint& startpo
|
||||
}
|
||||
|
||||
Block->SetMessageBlock( this );
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user