Commit 67894dd3 authored by jean-pierre charras's avatar jean-pierre charras

Gerbview: remove useless calls to SetToolbar() which create horizontal toolbar...

Gerbview: remove useless calls to SetToolbar() which create horizontal toolbar flicker under Windows.
parent a8d5e068
......@@ -110,6 +110,5 @@ void WinEDA_GerberFrame::GeneralControle( wxDC* DC, wxPoint Mouse )
wxSafeYield();
}
SetToolbars();
UpdateStatusBar();
}
......@@ -217,6 +217,7 @@ WinEDA_GerberFrame::WinEDA_GerberFrame( wxWindow* father,
ReFillLayerWidget(); // this is near end because contents establish size
SetToolbars();
m_auimgr.Update();
}
......
......@@ -47,6 +47,7 @@ bool WinEDA_GerberFrame::Clear_Pcb( bool query )
SetBaseScreen( ActiveScreen = ScreenPcb );
GetScreen()->Init();
setActiveLayer(LAYER_N_BACK);
syncLayerBox();
return TRUE;
}
......@@ -81,4 +82,5 @@ void WinEDA_GerberFrame::Erase_Current_Layer( bool query )
ScreenPcb->SetModify();
ScreenPcb->SetRefreshReq();
syncLayerBox();
}
......@@ -17,9 +17,8 @@
bool WinEDA_GerberFrame::Read_GERBER_File( const wxString& GERBER_FullFileName,
const wxString& D_Code_FullFileName )
{
int G_commande = 0,
D_commande = 0; /* command number for G or D commands
* (like G04 or D02) */
int G_commande = 0; // command number for G commands like G04
int D_commande = 0; // command number for D commands like D02
char line[GERBER_BUFZ];
......@@ -57,7 +56,7 @@ bool WinEDA_GerberFrame::Read_GERBER_File( const wxString& GERBER_FullFileName,
SetLocaleTo_C_standard();
while( TRUE )
while( true )
{
if( fgets( line, sizeof(line), gerber->m_Current_File ) == NULL )
{
......
......@@ -224,17 +224,6 @@ void WinEDA_GerberFrame::SetToolbars()
if( m_HToolBar == NULL )
return;
if( GetScreen()->m_BlockLocate.m_Command == BLOCK_MOVE )
{
m_HToolBar->EnableTool( wxID_CUT, true );
m_HToolBar->EnableTool( wxID_COPY, true );
}
else
{
m_HToolBar->EnableTool( wxID_CUT, false );
m_HToolBar->EnableTool( wxID_COPY, false );
}
if( m_SelLayerBox && (m_SelLayerBox->GetSelection() != screen->m_Active_Layer) )
{
m_SelLayerBox->SetSelection( screen->m_Active_Layer );
......
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