本文整理汇总了Java中com.intellij.openapi.roots.ui.configuration.libraries.LibraryEditingUtil.getLibraryTablePresentation方法的典型用法代码示例。如果您正苦于以下问题:Java LibraryEditingUtil.getLibraryTablePresentation方法的具体用法?Java LibraryEditingUtil.getLibraryTablePresentation怎么用?Java LibraryEditingUtil.getLibraryTablePresentation使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.intellij.openapi.roots.ui.configuration.libraries.LibraryEditingUtil
的用法示例。
在下文中一共展示了LibraryEditingUtil.getLibraryTablePresentation方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: doEdit
import com.intellij.openapi.roots.ui.configuration.libraries.LibraryEditingUtil; //导入方法依赖的package包/类
private void doEdit() {
final OrderEntry entry = getSelectedEntry();
if (!(entry instanceof LibraryOrderEntry)) return;
final Library library = ((LibraryOrderEntry)entry).getLibrary();
if (library == null) {
return;
}
final LibraryTable table = library.getTable();
final String tableLevel = table != null ? table.getTableLevel() : LibraryTableImplUtil.MODULE_LEVEL;
final LibraryTablePresentation presentation = LibraryEditingUtil.getLibraryTablePresentation(getProject(), tableLevel);
final LibraryTableModifiableModelProvider provider = getModifiableModelProvider(tableLevel);
EditExistingLibraryDialog dialog = EditExistingLibraryDialog.createDialog(this, provider, library, myState.getProject(),
presentation, getStructureConfigurableContext());
dialog.setContextModule(getRootModel().getModule());
dialog.show();
myEntryTable.repaint();
ModuleStructureConfigurable.getInstance(myState.getProject()).getTree().repaint();
}
示例2: doEdit
import com.intellij.openapi.roots.ui.configuration.libraries.LibraryEditingUtil; //导入方法依赖的package包/类
@Override
public void doEdit(ClasspathPanelImpl panel) {
final Library library = getEntry().getLibrary();
if (library == null) {
return;
}
final LibraryTable table = library.getTable();
final String tableLevel = table != null ? table.getTableLevel() : LibraryTableImplUtil.MODULE_LEVEL;
final LibraryTablePresentation presentation = LibraryEditingUtil.getLibraryTablePresentation(myContext.getProject(), tableLevel);
final LibraryTableModifiableModelProvider provider = panel.getModifiableModelProvider(tableLevel);
EditExistingLibraryDialog dialog = EditExistingLibraryDialog.createDialog(panel, provider, library, myContext.getProject(), presentation, myContext);
dialog.setContextModule(getEntry().getOwnerModule());
dialog.show();
}
示例3: addChangeLibraryLevelAction
import com.intellij.openapi.roots.ui.configuration.libraries.LibraryEditingUtil; //导入方法依赖的package包/类
private void addChangeLibraryLevelAction(DefaultActionGroup actionGroup, String tableLevel) {
final LibraryTablePresentation presentation = LibraryEditingUtil.getLibraryTablePresentation(getProject(), tableLevel);
actionGroup.add(new ChangeLibraryLevelInClasspathAction(this, presentation.getDisplayName(true), tableLevel));
}