本文整理汇总了Java中com.intellij.openapi.module.ModuleConfigurationEditor类的典型用法代码示例。如果您正苦于以下问题:Java ModuleConfigurationEditor类的具体用法?Java ModuleConfigurationEditor怎么用?Java ModuleConfigurationEditor使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ModuleConfigurationEditor类属于com.intellij.openapi.module包,在下文中一共展示了ModuleConfigurationEditor类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: dispose
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
public void dispose() {
try {
for (final ModuleConfigurationEditor myEditor : myEditors) {
myEditor.disposeUIResources();
}
myEditors.clear();
disposeCenterPanel();
if (myModifiableRootModel != null) {
myModifiableRootModel.dispose();
}
myGenericSettingsPanel = null;
}
finally {
myModifiableRootModel = null;
myModifiableRootModelProxy = null;
}
}
示例2: getEditor
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
@Nullable
public ModuleConfigurationEditor getEditor(@NotNull String displayName) {
ModuleConfigurationEditor singleEditor = getSingleEditor();
if (singleEditor != null) {
if (displayName.equals(singleEditor.getDisplayName())) {
return singleEditor;
}
else {
return null;
}
}
else {
return super.getEditor(displayName);
}
}
示例3: createCenterPanel
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
protected JComponent createCenterPanel() {
myTabbedPane = new TabbedPaneWrapper(this);
for (ModuleConfigurationEditor editor : myEditors) {
myTabbedPane.addTab(editor.getDisplayName(), editor.createComponent());
editor.reset();
}
restoreSelectedEditor();
myTabbedPane.addChangeListener(new javax.swing.event.ChangeListener() {
@Override
public void stateChanged(ChangeEvent e) {
saveSelectedEditor();
if (myHistory != null) {
myHistory.pushQueryPlace();
}
}
});
return myTabbedPane.getComponent();
}
示例4: createEditors
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
/**
* {@inheritDoc}
*/
@Override
public ModuleConfigurationEditor[] createEditors(final ModuleConfigurationState state) {
final Module module = state.getRootModel().getModule();
final ModuleType moduleType = ModuleType.get(module);
if (moduleType != this.metaborgModuleType) {
return ModuleConfigurationEditor.EMPTY;
}
final DefaultModuleConfigurationEditorFactory editorFactory
= DefaultModuleConfigurationEditorFactory.getInstance();
return new ModuleConfigurationEditor[]{
editorFactory.createModuleContentRootsEditor(state),
editorFactory.createOutputEditor(state),
editorFactory.createClasspathEditor(state)
// Add more editors here.
};
}
示例5: createEditors
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
public ModuleConfigurationEditor[] createEditors(ModuleConfigurationState state) {
final Module module = state.getRootModel().getModule();
final ModuleType moduleType = ModuleType.get(module);
if (!(moduleType instanceof NimModuleType)) {
return ModuleConfigurationEditor.EMPTY;
}
final DefaultModuleConfigurationEditorFactory editorFactory = DefaultModuleConfigurationEditorFactory.getInstance();
return new ModuleConfigurationEditor[] {
new NimModuleTypeEditor(state),
//editorFactory.createModuleContentRootsEditor(state),
//editorFactory.createOutputEditor(state),
editorFactory.createClasspathEditor(state)
};
}
示例6: createEditors
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
public ModuleConfigurationEditor[] createEditors(ModuleConfigurationState state) {
final Module module = state.getRootModel().getModule();
final ModuleType moduleType = ModuleType.get(module);
if (!(moduleType instanceof GaugeModuleType)) {
return ModuleConfigurationEditor.EMPTY;
}
final DefaultModuleConfigurationEditorFactory editorFactory = DefaultModuleConfigurationEditorFactory.getInstance();
List<ModuleConfigurationEditor> editors = new ArrayList<>();
editors.add(editorFactory.createModuleContentRootsEditor(state));
editors.add(editorFactory.createOutputEditor(state));
editors.add(editorFactory.createClasspathEditor(state));
return editors.toArray(new ModuleConfigurationEditor[editors.size()]);
}
示例7: createEditors
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
private void createEditors(Module module) {
ModuleConfigurationEditorProvider[] providers = collectProviders(module);
ModuleConfigurationState state = createModuleConfigurationState();
for (ModuleConfigurationEditorProvider provider : providers) {
ModuleConfigurationEditor[] editors = provider.createEditors(state);
if (editors.length > 0 && provider instanceof ModuleConfigurationEditorProviderEx &&
((ModuleConfigurationEditorProviderEx)provider).isCompleteEditorSet()) {
myEditors.clear();
ContainerUtil.addAll(myEditors, editors);
break;
}
else {
ContainerUtil.addAll(myEditors, editors);
}
}
for (final Configurable moduleConfigurable : myModule.getComponents(Configurable.class)) {
myEditors.add(new ModuleConfigurableWrapper(moduleConfigurable));
}
for(ModuleConfigurableEP extension : myModule.getExtensions(MODULE_CONFIGURABLES)) {
myEditors.add(new ModuleConfigurableWrapper(extension.createConfigurable()));
}
}
示例8: createEditors
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
public ModuleConfigurationEditor[] createEditors(ModuleConfigurationState moduleConfigurationState) {
final Module module = moduleConfigurationState.getRootModel().getModule();
if (ModuleType.get(module) != DojoToolkitModuleType.getInstance()) return ModuleConfigurationEditor.EMPTY;
final DefaultModuleConfigurationEditorFactory editorFactory = DefaultModuleConfigurationEditorFactory.getInstance();
List<ModuleConfigurationEditor> editors = new ArrayList<ModuleConfigurationEditor>();
//editors.add(editorFactory.createModuleContentRootsEditor(moduleConfigurationState));
for(Module theModule : ModuleManager.getInstance(moduleConfigurationState.getProject()).getModules())
{
ModuleType theType = ModuleType.get(theModule);
int i=0;
}
return editors.toArray(new ModuleConfigurationEditor[editors.size()]);
}
示例9: selectOrderEntry
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
public ActionCallback selectOrderEntry(@Nonnull final Module module, @Nullable final OrderEntry orderEntry) {
Place p = new Place();
p.putPath(ProjectStructureConfigurable.CATEGORY, this);
Runnable r = null;
final MasterDetailsComponent.MyNode node = findModuleNode(module);
if (node != null) {
p.putPath(TREE_OBJECT, module);
p.putPath(ModuleEditor.SELECTED_EDITOR_NAME, ClasspathEditor.NAME);
r = new Runnable() {
@Override
public void run() {
if (orderEntry != null) {
ModuleEditor moduleEditor = ((ModuleConfigurable)node.getConfigurable()).getModuleEditor();
ModuleConfigurationEditor editor = moduleEditor.getEditor(ClasspathEditor.NAME);
if (editor instanceof ClasspathEditor) {
((ClasspathEditor)editor).selectOrderEntry(orderEntry);
}
}
}
};
}
final ActionCallback result = ProjectStructureConfigurable.getInstance(myProject).navigateTo(p, true);
return r != null ? result.doWhenDone(r) : result;
}
示例10: getEditor
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
@Nullable
public ModuleConfigurationEditor getEditor(@Nonnull String displayName) {
ModuleConfigurationEditor singleEditor = getSingleEditor();
if (singleEditor != null) {
if (displayName.equals(singleEditor.getDisplayName())) {
return singleEditor;
}
else {
return null;
}
}
else {
return super.getEditor(displayName);
}
}
示例11: createEditors
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
public ModuleConfigurationEditor[] createEditors(@NotNull final ModuleConfigurationState state) {
final Module module = state.getRootModel().getModule();
if (!LuaModuleUtil.isLuaModule(module)) return ModuleConfigurationEditor.EMPTY;
final DefaultModuleConfigurationEditorFactory editorFactory = DefaultModuleConfigurationEditorFactory.getInstance();
final List<ModuleConfigurationEditor> editors = new ArrayList<ModuleConfigurationEditor>();
editors.add(editorFactory.createModuleContentRootsEditor(state));
editors.add(editorFactory.createClasspathEditor(state));
return editors.toArray(new ModuleConfigurationEditor[editors.size()]);
}
示例12: createModuleContentRootsEditor
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
public ModuleConfigurationEditor createModuleContentRootsEditor(ModuleConfigurationState state) {
final ModifiableRootModel rootModel = state.getRootModel();
final Module module = rootModel.getModule();
final String moduleName = module.getName();
return new ContentEntriesEditor(moduleName, state);
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:8,代码来源:DefaultModuleConfigurationEditorFactoryImpl.java
示例13: createEditors
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
@Override
public ModuleConfigurationEditor[] createEditors(ModuleConfigurationState state) {
ModifiableRootModel rootModel = state.getRootModel();
Module module = rootModel.getModule();
if (!(ModuleType.get(module) instanceof JavaModuleType)) {
return ModuleConfigurationEditor.EMPTY;
}
String moduleName = module.getName();
List<ModuleConfigurationEditor> editors = new ArrayList<ModuleConfigurationEditor>();
editors.add(new ContentEntriesEditor(moduleName, state));
editors.add(new OutputEditor(state));
editors.add(new ClasspathEditor(state));
return editors.toArray(new ModuleConfigurationEditor[editors.size()]);
}
示例14: init
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
public void init(History history) {
myHistory = history;
for (ModuleConfigurationEditor each : myEditors) {
if (each instanceof ModuleElementsEditor) {
((ModuleElementsEditor)each).setHistory(myHistory);
}
}
restoreSelectedEditor();
}
示例15: isModified
import com.intellij.openapi.module.ModuleConfigurationEditor; //导入依赖的package包/类
public boolean isModified() {
for (ModuleConfigurationEditor moduleElementsEditor : myEditors) {
if (moduleElementsEditor.isModified()) {
return true;
}
}
return false;
}