From 7125da8a453bf634abd77f1edca0f6039ac72fc5 Mon Sep 17 00:00:00 2001 From: Dick Hollenbeck Date: Mon, 23 Sep 2013 10:57:15 -0500 Subject: [PATCH] Set FPID on GITHUB_PLUGIN::FootprintLoad() --- pcbnew/github/github_plugin.cpp | 6 ++++++ pcbnew/io_mgr.cpp | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/pcbnew/github/github_plugin.cpp b/pcbnew/github/github_plugin.cpp index 9ef1448e4e..8da1683d15 100644 --- a/pcbnew/github/github_plugin.cpp +++ b/pcbnew/github/github_plugin.cpp @@ -52,6 +52,7 @@ #include #include #include +#include using namespace std; @@ -138,6 +139,11 @@ MODULE* GITHUB_PLUGIN::FootprintLoad( const wxString& aLibraryPath, MODULE* ret = (MODULE*) parser.Parse(); + // Dude, the footprint name comes from the file name in + // a github library. Zero out the library name, we don't know it here. + // Caller always has to set the library nickname if it knows it. + ret->SetFPID( fp_name ); + return ret; } } diff --git a/pcbnew/io_mgr.cpp b/pcbnew/io_mgr.cpp index fd1db3401c..a89e6c0da9 100644 --- a/pcbnew/io_mgr.cpp +++ b/pcbnew/io_mgr.cpp @@ -200,7 +200,7 @@ IO_MGR::PCB_FILE_T IO_MGR::GuessPluginTypeFromLibPath( const wxString& aLibPath ret = EAGLE; } - // Test this one anyways, even thought its the default guess, to avoid + // Test this one anyways, even though it's the default guess, to avoid // the wxURI instantiation below. // We default ret to KICAD above, because somebody might have // mistakenly put a pretty library into a directory other than