From d58427a519134ebba63433844c1f04d3b55d0622 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Tue, 22 Feb 2022 22:46:12 +0000 Subject: [PATCH] Don't kill entire OpenGL cache on undo. The comment regarding bitmaps was true for one more month in 2018, but hasn't been true for the last 3 years, and clearing the cache is a huge performance hit. --- eeschema/schematic_undo_redo.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/eeschema/schematic_undo_redo.cpp b/eeschema/schematic_undo_redo.cpp index 1ef5fdf4a3..faf4d204c8 100644 --- a/eeschema/schematic_undo_redo.cpp +++ b/eeschema/schematic_undo_redo.cpp @@ -350,9 +350,6 @@ void SCH_EDIT_FRAME::PutDataInPreviousState( PICKED_ITEMS_LIST* aList ) } } - // Bitmaps are cached in Opengl: clear the cache, because - // the cache data can be invalid - GetCanvas()->GetView()->RecacheAllItems(); GetCanvas()->GetView()->ClearHiddenFlags(); } @@ -383,7 +380,6 @@ void SCH_EDIT_FRAME::RollbackSchematicFromUndo() m_toolManager->GetTool()->RebuildSelection(); } - SyncView(); GetCanvas()->Refresh(); }