From ac778163ab273e2c741bacc618c58b533653f39a Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Thu, 31 Aug 2023 14:05:05 +0100 Subject: [PATCH] Support net queries in PNS_LOG_PLAYER_KICAD_IFACE. --- qa/tools/pns/pns_log_player.cpp | 18 ++++++++++++++++++ qa/tools/pns/pns_log_player.h | 3 +++ 2 files changed, 21 insertions(+) diff --git a/qa/tools/pns/pns_log_player.cpp b/qa/tools/pns/pns_log_player.cpp index 5b65c9490b..d93f771e0d 100644 --- a/qa/tools/pns/pns_log_player.cpp +++ b/qa/tools/pns/pns_log_player.cpp @@ -285,6 +285,24 @@ void PNS_LOG_PLAYER_KICAD_IFACE::DisplayItem( const PNS::ITEM* aItem, int aClear } +int PNS_LOG_PLAYER_KICAD_IFACE::GetNetCode( PNS::NET_HANDLE aNet ) const +{ + if( aNet ) + return static_cast( aNet )->GetNetCode(); + else + return -1; +} + + +wxString PNS_LOG_PLAYER_KICAD_IFACE::GetNetName( PNS::NET_HANDLE aNet ) const +{ + if( aNet ) + return static_cast( aNet )->GetNetname(); + else + return wxEmptyString; +} + + PNS_LOG_VIEW_TRACKER::PNS_LOG_VIEW_TRACKER() { } diff --git a/qa/tools/pns/pns_log_player.h b/qa/tools/pns/pns_log_player.h index 8c381b21ec..7f39ee6cc0 100644 --- a/qa/tools/pns/pns_log_player.h +++ b/qa/tools/pns/pns_log_player.h @@ -71,6 +71,9 @@ public: void HideItem( PNS::ITEM* aItem ) override; void DisplayItem( const PNS::ITEM* aItem, int aClearance, bool aEdit = false, bool aIsHeadTrace = false ) override; + int GetNetCode( PNS::NET_HANDLE aNet ) const override; + wxString GetNetName( PNS::NET_HANDLE aNet ) const override; + private: PNS_LOG_VIEW_TRACKER *m_viewTracker; };