Fixed GAL canvas freeze when ordered twice to change to the same GAL canvas (e.g. double F11).

This commit is contained in:
Maciej Suminski 2014-04-04 12:01:30 +02:00
parent ba275918e3
commit 024bf9dd84
1 changed files with 4 additions and 4 deletions

View File

@ -194,14 +194,14 @@ void EDA_DRAW_PANEL_GAL::StopDrawing()
void EDA_DRAW_PANEL_GAL::SwitchBackend( GalType aGalType )
{
// Protect from refreshing during backend switch
m_pendingRefresh = true;
m_refreshTimer.Stop();
// Do not do anything if the currently used GAL is correct
if( aGalType == m_currentGal && m_gal != NULL )
return;
// Prevent refreshing canvas during backend switch
m_pendingRefresh = true;
m_refreshTimer.Stop();
delete m_gal;
switch( aGalType )