mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-07 11:36:18 +02:00
added comments
git-svn-id: trunk@16457 -
This commit is contained in:
parent
3b6072d877
commit
61bf784792
@ -482,21 +482,24 @@ begin
|
||||
end;
|
||||
|
||||
procedure TCustomComboBox.KeyUp(var Key: Word; Shift: TShiftState);
|
||||
var iSelStart: Integer;
|
||||
sCompleteText, sPrefixText, sResultText: string;
|
||||
var
|
||||
iSelStart: Integer; // byte position
|
||||
sCompleteText, sPrefixText, sResultText: string;
|
||||
begin
|
||||
inherited KeyUp(Key, Shift);
|
||||
if ((cbactEnabled in FAutoCompleteText) and (Style <> csDropDownList)) then
|
||||
begin
|
||||
//Only happens with alpha-numeric keys and return key and editable Style
|
||||
if (IsEditableTextKey(Key) or (Key = VK_RETURN) or (ssShift in Shift)) then
|
||||
begin
|
||||
begin
|
||||
if (Key = VK_RETURN) then
|
||||
SelectAll else
|
||||
begin
|
||||
SelectAll
|
||||
else begin
|
||||
iSelStart := SelStart;//Capture original cursor position
|
||||
//End of line completion
|
||||
if ((iSelStart < Length(Text)) and (cbactEndOfLineComplete in FAutoCompleteText)) then Exit;
|
||||
if ((iSelStart < Length(Text))
|
||||
and (cbactEndOfLineComplete in FAutoCompleteText)) then
|
||||
Exit;
|
||||
sPrefixText := LeftStr(Text, iSelStart);
|
||||
sCompleteText := GetCompleteText(Text, iSelStart,
|
||||
(cbactSearchCaseSensitive in FAutoCompleteText),
|
||||
|
@ -378,8 +378,8 @@ type
|
||||
property Items: TStrings read FItems write SetItems;
|
||||
property ItemIndex: integer read GetItemIndex write SetItemIndex default -1;
|
||||
property ReadOnly: Boolean read FReadOnly write SetReadOnly stored IsReadOnlyStored;
|
||||
property SelLength: integer read GetSelLength write SetSelLength;
|
||||
property SelStart: integer read GetSelStart write SetSelStart;
|
||||
property SelLength: integer read GetSelLength write SetSelLength;// byte length
|
||||
property SelStart: integer read GetSelStart write SetSelStart;// byte position
|
||||
property SelText: String read GetSelText write SetSelText;
|
||||
property Style: TComboBoxStyle read FStyle write SetStyle;
|
||||
property Text;
|
||||
|
Loading…
Reference in New Issue
Block a user