Skip to content

Commit ddea353

Browse files
committed
Avoid flickering when updating the instrument list
1 parent 683e58b commit ddea353

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Source/MainFrm.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -954,12 +954,17 @@ void CMainFrame::NewInstrument(int ChipType)
954954

955955
void CMainFrame::UpdateInstrumentList()
956956
{
957+
// Avoid visible flickering when updating
958+
m_pInstrumentList->SetRedraw(FALSE);
959+
957960
// Rewrite the instrument list
958961
ClearInstrumentList();
959962

960963
for (int i = 0; i < MAX_INSTRUMENTS; ++i) {
961964
m_pInstrumentList->InsertInstrument(i);
962965
}
966+
967+
m_pInstrumentList->SetRedraw(TRUE);
963968
}
964969

965970
void CMainFrame::SelectInstrument(int Index)

0 commit comments

Comments
 (0)