use of org.jetbrains.plugins.ruby.ruby.codeInsight.completion.RubyLookupElement in project intellij-plugins by JetBrains.
the class RubyMotionCompletionProvider method createLookupItem.
private static LookupElement createLookupItem(@NotNull final FunctionSymbol symbol, final boolean bold, final boolean isInsertHandlerCanBeApplied) {
final Symbol parent = symbol.getParentSymbol();
if (parent == null || !isInsertHandlerCanBeApplied)
return null;
final Function function = symbol.getFunction();
if (function.getArguments().size() < 2 || !function.getName().contains(":"))
return null;
return new RubyLookupElement(function.getName(), "", parent.getFQNWithNesting().getFullPath(), bold, AllIcons.Nodes.Method, null, new SelectorInsertHandler(function));
}
Aggregations