本文整理汇总了Java中com.intellij.navigation.ItemPresentation类的典型用法代码示例。如果您正苦于以下问题:Java ItemPresentation类的具体用法?Java ItemPresentation怎么用?Java ItemPresentation使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ItemPresentation类属于com.intellij.navigation包,在下文中一共展示了ItemPresentation类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
public static ItemPresentation getPresentation(final TSFnDeclStmt function) {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
if (function.getFunctionType() == TSFunctionType.GLOBAL) {
return function.getFunctionName();
} else {
return function.getNamespace() + "::" + function.getFunctionName();
}
}
@Nullable
@Override
public String getLocationString() {
return function.getContainingFile().getName();
}
@Nullable
@Override
public Icon getIcon(boolean unused) {
return TSIcons.FILE;
}
};
}
示例2: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Override
public String getPresentableText() {
return getName();
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Override
public Icon getIcon(boolean unused) {
return Icons.TYPE;
}
};
}
示例3: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return getName();
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Override
public Icon getIcon(boolean unused) {
return Icons.INCLUDE;
}
};
}
示例4: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return getName();
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Nullable
@Override
public Icon getIcon(boolean unused) {
return Icons.OPEN;
}
};
}
示例5: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return getName();
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Nullable
@Override
public Icon getIcon(boolean unused) {
return Icons.MODULE;
}
};
}
示例6: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return getName();
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Nullable
@Override
public Icon getIcon(boolean unused) {
return Icons.EXCEPTION;
}
};
}
示例7: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return getName();
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Nullable
@Override
public Icon getIcon(boolean unused) {
return Icons.VAL;
}
};
}
示例8: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@NotNull
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return element.getVirtualFile().getName().toString();
}
@Nullable
@Override
public String getLocationString() {
return element.getVirtualFile().getCanonicalPath();
}
@Nullable
@Override
public Icon getIcon(boolean b) {
return GCMIcons.GCM_ICON_16x16;
}
};
}
示例9: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@NotNull
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return simpleType;
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Nullable
@Override
public Icon getIcon(boolean b) {
return AllIcons.Actions.MoveUp;
}
};
}
示例10: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@NotNull
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return packageName;
}
@Nullable
@Override
public String getLocationString() {
return "";
}
@Nullable
@Override
public Icon getIcon(boolean b) {
return PlatformIcons.PACKAGE_ICON;
}
};
}
示例11: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@NotNull
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return attDecl.getAttributeName().getText() + " : " + simpleType;
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Nullable
@Override
public Icon getIcon(boolean b) {
return myIcon;
}
};
}
示例12: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@NotNull
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return presText;
}
@Nullable
@Override
public String getLocationString() {
return null;
}
@Nullable
@Override
public Icon getIcon(boolean b) {
return PlatformIcons.CLASS_ICON;
}
};
}
示例13: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
@Override
public ItemPresentation getPresentation() {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return getName();
}
@Nullable
@Override
public String getLocationString() {
return getNode().getPsi().getContainingFile().getName();
}
@Nullable
@Override
public Icon getIcon(boolean unused) {
return GCMIcons.GCM_ICON_16x16;
}
};
}
示例14: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
public static ItemPresentation getPresentation(final GCMTypeDeclaration element) {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return element.getName();
}
@Nullable
@Override
public String getLocationString() {
return element.getContainingFile().getName();
}
@Nullable
@Override
public Icon getIcon(boolean unused) {
return GCMIcons.GCM_ICON_16x16;
}
};
}
示例15: getPresentation
import com.intellij.navigation.ItemPresentation; //导入依赖的package包/类
public static ItemPresentation getPresentation(final CptTemplate element) {
return new ItemPresentation() {
@Nullable
@Override
public String getPresentableText() {
return element.getTemplateName();
}
@Nullable
@Override
public String getLocationString() {
PsiFile containingFile = element.getContainingFile();
return containingFile == null ? null : containingFile.getName();
}
@Nullable
@Override
public Icon getIcon(boolean unused) {
return CptIcons.FILE;
}
};
}