Changeset 252 for trunk/NewView/MainForm.pas
- Timestamp:
- Sep 21, 2007, 5:57:18 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/NewView/MainForm.pas
r236 r252 2384 2384 Filename := THelpFile( CurrentOpenFiles[ 0 ] ).Filename; 2385 2385 NamePart := ExtractFileName( Filename ); 2386 Result := StrStartsWithIgnoringCase( 'newview', NamePart);2386 Result := StrStartsWithIgnoringCase(NamePart, 'newview'); 2387 2387 end; 2388 2388 … … 4487 4487 End; 4488 4488 4489 Procedure TMainForm.IndexSearchEditOnScan (Sender: TObject; 4490 Var KeyCode: TKeyCode); 4489 Procedure TMainForm.IndexSearchEditOnScan (Sender: TObject; Var KeyCode: TKeyCode); 4491 4490 Begin 4492 4491 case KeyCode of … … 4515 4514 Procedure TMainForm.IndexSearchEditOnChange (Sender: TObject); 4516 4515 var 4517 MatchIndex: longint;4518 IndexINdex: longint;4519 SearchText: string;4516 tmpMatchIndex : longint; 4517 tmpSearchText: string; 4518 i : longint; 4520 4519 Begin 4521 4520 if InIndexSearch then 4522 4521 exit; 4523 4522 4524 MatchIndex:= -1; 4525 SearchText:= trim( IndexSearchEdit.Text ); 4526 for IndexIndex:= 0 to DisplayedIndex.Count - 1 do 4527 begin 4528 if StrStartsWithIgnoringCase( SearchText, DisplayedIndex[ IndexIndex ] ) then //IndexEntry ) then 4523 tmpMatchIndex := -1; 4524 tmpSearchText := trim(IndexSearchEdit.Text); 4525 4526 for i := 0 to DisplayedIndex.Count - 1 do 4527 begin 4528 if StrStartsWithIgnoringCase(DisplayedIndex[i], tmpSearchText) then 4529 4529 begin 4530 MatchIndex:= IndexIndex;4530 tmpMatchIndex := i; 4531 4531 break; 4532 4532 end; 4533 4533 end; 4534 4534 4535 if MatchIndex = -1 then4535 if tmpMatchIndex = -1 then 4536 4536 exit; 4537 4537 4538 4538 InIndexSearch:= true; 4539 4539 4540 if IndexListBox.ItemIndex <> MatchIndex then4541 IndexListBox.ItemIndex:= MatchIndex;4540 if IndexListBox.ItemIndex <> tmpMatchIndex then 4541 IndexListBox.ItemIndex:= tmpMatchIndex; 4542 4542 4543 4543 InIndexSearch:= false;
Note:
See TracChangeset
for help on using the changeset viewer.