mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-16 13:09:20 +02:00
CodeTools/SourceEditor: code completion, indicate if the returned value is void
git-svn-id: trunk@21026 -
This commit is contained in:
parent
dbfbbff04f
commit
974cdf9067
@ -4014,7 +4014,7 @@ Begin
|
|||||||
// insert value plus special chars like brackets, semicolons, ...
|
// insert value plus special chars like brackets, semicolons, ...
|
||||||
SrcEdit:=GetActiveSE;
|
SrcEdit:=GetActiveSE;
|
||||||
Editor:=SrcEdit.EditorComponent;
|
Editor:=SrcEdit.EditorComponent;
|
||||||
if NewValue <> '' then
|
if ValueType <> icvNone then
|
||||||
Editor.TextBetweenPoints[SourceStart, SourceEnd] := NewValue;
|
Editor.TextBetweenPoints[SourceStart, SourceEnd] := NewValue;
|
||||||
if CursorToLeft>0 then
|
if CursorToLeft>0 then
|
||||||
begin
|
begin
|
||||||
|
@ -76,7 +76,8 @@ type
|
|||||||
icvProcWithParams,
|
icvProcWithParams,
|
||||||
icvIndexedProp,
|
icvIndexedProp,
|
||||||
icvCompleteProcDeclaration,
|
icvCompleteProcDeclaration,
|
||||||
icvUnitName
|
icvUnitName,
|
||||||
|
icvNone
|
||||||
);
|
);
|
||||||
|
|
||||||
// completion form and functions
|
// completion form and functions
|
||||||
@ -477,9 +478,13 @@ begin
|
|||||||
CanAddComma:=(AddChar<>',');
|
CanAddComma:=(AddChar<>',');
|
||||||
|
|
||||||
IdentItem:=IdentList.FilteredItems[Index];
|
IdentItem:=IdentList.FilteredItems[Index];
|
||||||
if IdentItem=nil then exit;
|
if IdentItem=nil then begin
|
||||||
|
ValueType := icvNone;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
|
|
||||||
if not CodeToolBoss.IdentItemCheckHasChilds(IdentItem) then begin
|
if not CodeToolBoss.IdentItemCheckHasChilds(IdentItem) then begin
|
||||||
|
ValueType := icvNone;
|
||||||
MainIDEInterface.DoJumpToCodeToolBossError;
|
MainIDEInterface.DoJumpToCodeToolBossError;
|
||||||
exit;
|
exit;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user