Commit 59f25e7f authored by jean-pierre charras's avatar jean-pierre charras

fixed bugs 639774 and 639586

parent e66a007e
...@@ -323,7 +323,6 @@ bool SCH_PRINTOUT::OnBeginDocument( int startPage, int endPage ) ...@@ -323,7 +323,6 @@ bool SCH_PRINTOUT::OnBeginDocument( int startPage, int endPage )
#ifdef __WXDEBUG__ #ifdef __WXDEBUG__
WinEDA_SchematicFrame* parent = m_Parent->GetParent(); WinEDA_SchematicFrame* parent = m_Parent->GetParent();
#endif
wxLogDebug( wxT( "Printer name: " ) + wxLogDebug( wxT( "Printer name: " ) +
parent->GetPageSetupData().GetPrintData().GetPrinterName() ); parent->GetPageSetupData().GetPrintData().GetPrinterName() );
wxLogDebug( wxT( "Paper ID: %d" ), wxLogDebug( wxT( "Paper ID: %d" ),
...@@ -335,6 +334,7 @@ bool SCH_PRINTOUT::OnBeginDocument( int startPage, int endPage ) ...@@ -335,6 +334,7 @@ bool SCH_PRINTOUT::OnBeginDocument( int startPage, int endPage )
parent->GetPageSetupData().GetPrintData().GetOrientation() ); parent->GetPageSetupData().GetPrintData().GetOrientation() );
wxLogDebug( wxT( "Quality: %d"), wxLogDebug( wxT( "Quality: %d"),
parent->GetPageSetupData().GetPrintData().GetQuality() ); parent->GetPageSetupData().GetPrintData().GetQuality() );
#endif
return true; return true;
} }
......
...@@ -603,6 +603,8 @@ void WinEDA_PcbFrame::Process_Special_Functions( wxCommandEvent& event ) ...@@ -603,6 +603,8 @@ void WinEDA_PcbFrame::Process_Special_Functions( wxCommandEvent& event )
g_Drag_Pistes_On = true; g_Drag_Pistes_On = true;
case ID_POPUP_PCB_MOVE_MODULE_REQUEST: case ID_POPUP_PCB_MOVE_MODULE_REQUEST:
if( GetCurItem() == NULL )
break;
// If the current Item is a pad, text module ...: Get its parent // If the current Item is a pad, text module ...: Get its parent
if( GetCurItem()->Type() != TYPE_MODULE ) if( GetCurItem()->Type() != TYPE_MODULE )
SetCurItem( GetCurItem()->GetParent() ); SetCurItem( GetCurItem()->GetParent() );
...@@ -628,6 +630,8 @@ void WinEDA_PcbFrame::Process_Special_Functions( wxCommandEvent& event ) ...@@ -628,6 +630,8 @@ void WinEDA_PcbFrame::Process_Special_Functions( wxCommandEvent& event )
case ID_POPUP_PCB_GET_AND_MOVE_MODULE_REQUEST: /* get module by name and move it */ case ID_POPUP_PCB_GET_AND_MOVE_MODULE_REQUEST: /* get module by name and move it */
SetCurItem( GetModuleByName() ); SetCurItem( GetModuleByName() );
module = (MODULE*) GetCurItem(); module = (MODULE*) GetCurItem();
if( module == NULL )
break;
if( module->IsLocked() ) if( module->IsLocked() )
{ {
wxString msg; wxString msg;
...@@ -636,11 +640,8 @@ void WinEDA_PcbFrame::Process_Special_Functions( wxCommandEvent& event ) ...@@ -636,11 +640,8 @@ void WinEDA_PcbFrame::Process_Special_Functions( wxCommandEvent& event )
DisplayInfoMessage( this, msg ); DisplayInfoMessage( this, msg );
break; break;
} }
if( GetCurItem() ) DrawPanel->MouseToCursorSchema();
{ StartMove_Module( module, &dc );
DrawPanel->MouseToCursorSchema();
StartMove_Module( (MODULE*) GetCurItem(), &dc );
}
break; break;
case ID_POPUP_PCB_DELETE_MODULE: case ID_POPUP_PCB_DELETE_MODULE:
......
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