Skip to content

Commit 0079c5d

Browse files
committed
Fixed bug where you could not use Find in the variables configuration
1 parent 7c78118 commit 0079c5d

File tree

2 files changed

+16
-1
lines changed

2 files changed

+16
-1
lines changed

dialogs/world_prefs/prefspropertypages.cpp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7766,6 +7766,21 @@ void CPrefsP18::OnFindNext()
77667766
DoFind (true);
77677767
} // end of CPrefsP18::OnFindNext
77687768

7769+
CString CPrefsP18::GetFindText (CObject * pItem) const
7770+
{
7771+
CVariable * variable_item = (CVariable *) pItem;
7772+
7773+
ASSERT_VALID (variable_item);
7774+
ASSERT( variable_item->IsKindOf( RUNTIME_CLASS( CVariable ) ) );
7775+
7776+
7777+
CString strResult = variable_item->strContents;
7778+
7779+
strResult += "\t" + variable_item->strLabel;
7780+
7781+
return strResult;
7782+
7783+
} // end of CPrefsP18::GetFindText
77697784

77707785
BOOL CPrefsP18::OnInitDialog()
77717786
{

dialogs/world_prefs/prefspropertypages.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1535,7 +1535,7 @@ class CPrefsP18 : public CGenPropertyPage
15351535
virtual CString GetGroup (CObject * pItem) const { return ""; }; // get item group
15361536
virtual CString GetDescription (CObject * pItem) const { return ""; }; // get item description for tree control
15371537
virtual int GetSequence (CObject * pItem) const { return 0; }; // get item sequence for sorting
1538-
virtual CString GetFindText (CObject * pItem) const { return ""; }; // get text for searching on
1538+
virtual CString GetFindText (CObject * pItem) const; // get text for searching on
15391539

15401540
// list management - add the item to the list control
15411541
virtual int AddItem (CObject * pItem, // add one item to the list control

0 commit comments

Comments
 (0)