Add Eeschema replace code.

* Enable replace toolbar button and menu entry.
* Improve find replace logging granularity.
* Fix find and replace dialog control hiding and disabling.
* Minor improvements to the SCH_FIND_REPLACE_DATA object.
* Move find collector list iterator into the collector object.
* Add visibility override flag to EDA_ITEM to temporarily show items that
  are hidden during find and replace.
This commit is contained in:
Wayne Stambaugh
2011-12-13 10:37:33 -05:00
parent 5f4acdee0e
commit 4f982ee3d1
25 changed files with 434 additions and 103 deletions
+10
View File
@@ -194,6 +194,16 @@ bool EDA_ITEM::Matches( const wxString& aText, wxFindReplaceData& aSearchData )
}
bool EDA_ITEM::Replace( wxFindReplaceData& aSearchData, wxString& aText )
{
wxCHECK_MSG( IsReplaceable(), false,
wxT( "Attempt to replace text in <" ) + GetClass() + wxT( "> item." ) );
return aText.Replace( aSearchData.GetFindString(),
aSearchData.GetReplaceString(), false ) != 0;
}
bool EDA_ITEM::operator<( const EDA_ITEM& aItem ) const
{
wxFAIL_MSG( wxString::Format( wxT( "Less than operator not defined for item type %s." ),