mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 22:52:11 +02:00
2004-11-02 Tanya Wolff
Fixed content assist extensibility for 77482 - changed context condition for addProposalsFromCompletionContributors() & fixed cursor position * src/org/eclipse/cdt/internal/ui/text/contentassist/CCompletionProcessor.java
This commit is contained in:
parent
762fd380d3
commit
872a34e811
2 changed files with 8 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2004-11-02 Tanya Wolff
|
||||||
|
Fixed content assist extensibility for 77482 - changed context condition
|
||||||
|
for addProposalsFromCompletionContributors() & fixed cursor position
|
||||||
|
* src/org/eclipse/cdt/internal/ui/text/contentassist/CCompletionProcessor.java
|
||||||
|
|
||||||
2004-11-01 Alain Magloire
|
2004-11-01 Alain Magloire
|
||||||
Patch from Mikhail Voronin to implement 71240.
|
Patch from Mikhail Voronin to implement 71240.
|
||||||
Too many changes to enumerate refer to PR:
|
Too many changes to enumerate refer to PR:
|
||||||
|
|
|
@ -445,8 +445,7 @@ public class CCompletionProcessor implements IContentAssistProcessor {
|
||||||
int length = prefix.length();
|
int length = prefix.length();
|
||||||
|
|
||||||
// calling functions should happen only within the context of a code body
|
// calling functions should happen only within the context of a code body
|
||||||
if( (completionNode.getCompletionContext() != IASTCompletionNode.CompletionKind.SINGLE_NAME_REFERENCE)
|
if (completionNode.getCompletionContext() != null)
|
||||||
&& (completionNode.getCompletionContext() != IASTCompletionNode.CompletionKind.SINGLE_NAME_REFERENCE))
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
IFunctionSummary[] summary;
|
IFunctionSummary[] summary;
|
||||||
|
@ -487,6 +486,8 @@ public class CCompletionProcessor implements IContentAssistProcessor {
|
||||||
|
|
||||||
if(fargs != null && fargs.length() > 0) {
|
if(fargs != null && fargs.length() > 0) {
|
||||||
proposal.setContextInformation(new ContextInformation(fname, fargs));
|
proposal.setContextInformation(new ContextInformation(fname, fargs));
|
||||||
|
// set the cursor before the closing bracket
|
||||||
|
proposal.setCursorPosition(fname.length() - 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
completions.add(proposal);
|
completions.add(proposal);
|
||||||
|
|
Loading…
Add table
Reference in a new issue