From fe7a7215f20fea36e2161a22db71acf784d643e9 Mon Sep 17 00:00:00 2001 From: Wayne Stambaugh Date: Sat, 5 Feb 2011 11:11:24 -0500 Subject: [PATCH] Fix junction drawn off grid on root sheet bug. --- eeschema/files-io.cpp | 1 + eeschema/schframe.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/eeschema/files-io.cpp b/eeschema/files-io.cpp index 62c7117bab..ac230abdd2 100644 --- a/eeschema/files-io.cpp +++ b/eeschema/files-io.cpp @@ -297,6 +297,7 @@ bool SCH_EDIT_FRAME::LoadOneEEProject( const wxString& FileName, bool IsNew ) // load the project. g_RootSheet->SetScreen( NULL ); bool diag = g_RootSheet->Load( this ); + SetScreen( m_CurrentSheet->LastScreen() ); /* Redraw base screen (ROOT) if necessary. */ GetScreen()->SetGrid( ID_POPUP_GRID_LEVEL_1000 + m_LastGridSizeId ); diff --git a/eeschema/schframe.cpp b/eeschema/schframe.cpp index bfbff46485..3f9cae4ca2 100644 --- a/eeschema/schframe.cpp +++ b/eeschema/schframe.cpp @@ -324,6 +324,7 @@ void SCH_EDIT_FRAME::CreateScreens() if( g_RootSheet->GetScreen() == NULL ) { g_RootSheet->SetScreen( new SCH_SCREEN() ); + SetScreen( g_RootSheet->GetScreen() ); } g_RootSheet->GetScreen()->SetFileName( m_DefaultSchematicFileName );