mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
FileTemplatesLoader — do not use Project.DIRECTORY_STORE_FOLDER
This commit is contained in:
@@ -25,6 +25,7 @@ import com.intellij.openapi.extensions.PluginDescriptor;
|
||||
import com.intellij.openapi.fileTypes.ex.FileTypeManagerEx;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.openapi.util.io.FileUtil;
|
||||
import com.intellij.project.ProjectKt;
|
||||
import com.intellij.util.lang.UrlClassLoader;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
@@ -71,7 +72,7 @@ public class FileTemplatesLoader {
|
||||
myTypeManager = typeManager;
|
||||
File configDir = project == null
|
||||
? new File(PathManager.getConfigPath(), TEMPLATES_DIR)
|
||||
: new File(project.getBasePath(), Project.DIRECTORY_STORE_FOLDER + "/" + TEMPLATES_DIR);
|
||||
: new File(ProjectKt.getStateStore(project).getDirectoryStorePath(true) + "/" + TEMPLATES_DIR);
|
||||
myDefaultTemplatesManager = new FTManager(FileTemplateManager.DEFAULT_TEMPLATES_CATEGORY, configDir);
|
||||
myInternalTemplatesManager = new FTManager(FileTemplateManager.INTERNAL_TEMPLATES_CATEGORY, new File(configDir, INTERNAL_DIR), true);
|
||||
myPatternsManager = new FTManager(FileTemplateManager.INCLUDES_TEMPLATES_CATEGORY, new File(configDir, INCLUDES_DIR));
|
||||
|
||||
Reference in New Issue
Block a user