Skip to content

Commit b7cabc8

Browse files
author
Vitaliy
authored
Merge pull request #33 from VitaliyBoyko/increasing-supported-version-of-idea
Increasing module version to support 2020.* IDE's, removed usage of the deprecated method
2 parents 2f33c83 + e82943a commit b7cabc8

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

META-INF/plugin.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<idea-plugin>
88
<id>com.magento.idea.magento2plugin</id>
99
<name>Magento PhpStorm</name>
10-
<version>0.3.0</version>
10+
<version>1.0.0</version>
1111
<vendor url="https://github.com/magento/magento2-phpstorm-plugin">Magento Inc.</vendor>
1212

1313
<description><![CDATA[
@@ -25,7 +25,7 @@
2525
</change-notes>
2626

2727
<!-- please see http://confluence.jetbrains.com/display/IDEADEV/Build+Number+Ranges for description -->
28-
<idea-version since-build="172"/>
28+
<idea-version since-build="193.4386.10"/>
2929

3030
<!-- please see http://confluence.jetbrains.com/display/IDEADEV/Plugin+Compatibility+with+IntelliJ+Platform+Products
3131
on how to target different products -->

src/com/magento/idea/magento2plugin/project/ProjectDetector.java

+10-10
Original file line numberDiff line numberDiff line change
@@ -29,23 +29,23 @@
2929

3030
public class ProjectDetector implements DirectoryProjectConfigurator {
3131
@Override
32-
public void configureProject(Project project, @NotNull VirtualFile virtualFile, Ref<Module> ref) {
32+
public void configureProject(@NotNull Project project, @NotNull VirtualFile baseDir, @NotNull Ref<Module> moduleRef, boolean newProject) {
3333
StartupManager.getInstance(project).runWhenProjectIsInitialized(() -> {
3434
DumbService.getInstance(project).smartInvokeLater(() -> {
3535
if (null == VfsUtil.findRelativeFile(project.getBaseDir(), "app", "etc", "di.xml")) {
3636
return;
3737
}
3838
Notification notification = new Notification("Magento", "Magento",
39-
"<a href='enable'>Enable</a> Magento support for this project?",
40-
NotificationType.INFORMATION, new NotificationListener.Adapter() {
41-
@Override
42-
public void hyperlinkActivated(@NotNull Notification notification, @NotNull HyperlinkEvent event) {
43-
Settings.getInstance(project).pluginEnabled = true;
44-
IndexManager.manualReindex();
45-
MagentoComponentManager.getInstance(project).flushModules();
46-
notification.expire();
47-
}
39+
"<a href='enable'>Enable</a> Magento support for this project?",
40+
NotificationType.INFORMATION, new NotificationListener.Adapter() {
41+
@Override
42+
public void hyperlinkActivated(@NotNull Notification notification, @NotNull HyperlinkEvent event) {
43+
Settings.getInstance(project).pluginEnabled = true;
44+
IndexManager.manualReindex();
45+
MagentoComponentManager.getInstance(project).flushModules();
46+
notification.expire();
4847
}
48+
}
4949
);
5050
Notifications.Bus.notify(notification, project);
5151
});

0 commit comments

Comments
 (0)