mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-63305 IDEA WebModule
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
package com.intellij.openapi.module;
|
||||
|
||||
import com.intellij.ide.util.projectWizard.EmptyModuleBuilder;
|
||||
import com.intellij.openapi.application.ApplicationInfo;
|
||||
import com.intellij.openapi.application.ex.ApplicationInfoEx;
|
||||
import com.intellij.openapi.project.ProjectBundle;
|
||||
import com.intellij.openapi.util.IconLoader;
|
||||
import org.jetbrains.annotations.NonNls;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import javax.swing.*;
|
||||
|
||||
/**
|
||||
* @author yole
|
||||
*/
|
||||
public class PlatformWebModuleType extends ModuleType<EmptyModuleBuilder> {
|
||||
@NonNls public static final String WEB_MODULE = "WEB_MODULE";
|
||||
|
||||
public PlatformWebModuleType() {
|
||||
super(WEB_MODULE);
|
||||
}
|
||||
|
||||
@NotNull
|
||||
public static PlatformWebModuleType getInstance() {
|
||||
return (PlatformWebModuleType)ModuleTypeManager.getInstance().findByID(WEB_MODULE);
|
||||
}
|
||||
|
||||
public EmptyModuleBuilder createModuleBuilder() {
|
||||
return new EmptyModuleBuilder() {
|
||||
@Override
|
||||
public ModuleType getModuleType() {
|
||||
return getInstance();
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return ProjectBundle.message("module.web.title");
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return ProjectBundle.message("module.web.description");
|
||||
}
|
||||
|
||||
public Icon getBigIcon() {
|
||||
return IconLoader.getIcon(((ApplicationInfoEx)ApplicationInfo.getInstance()).getSmallIconUrl());
|
||||
}
|
||||
|
||||
public Icon getNodeIcon(boolean isOpened) {
|
||||
return getBigIcon();
|
||||
}
|
||||
}
|
||||
@@ -253,6 +253,8 @@ module.corrupted.data.error=Corrupted module data at: {0}
|
||||
module.unknown.type.single.error=Cannot determine module type for the following module:\n\"{0}\"\nThe module will be treated as a Unknown module.
|
||||
module.unknown.type.multiple.error=Cannot determine module type for the following modules:\n{0}\nAll mentioned modules will be treated as Unknown modules.
|
||||
module.unknown.type.title=Unknown Module Type
|
||||
module.web.title=Web Module
|
||||
module.web.description=Provides facilities for developing web applications.
|
||||
module.remove.from.project.confirmation=Would you like to remove module ''{0}'' from the project?
|
||||
element.kind.name.module=module
|
||||
module.file.does.not.exist.error=File {0} does not exist
|
||||
|
||||
Reference in New Issue
Block a user