Null child action in group *** of class class com.intellij.openapi.actionSystem.DefaultActionGroup
程序员文章站
2024-02-02 23:09:46
...
初探intellij,记录个问题
出现下面的错误,并且菜单里面没有出现想要的按钮
java.lang.Throwable: Null child action in group Edit () of class class com.intellij.openapi.actionSystem.DefaultActionGroup, id=myTestPlugin
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:126)
at com.intellij.openapi.actionSystem.DefaultActionGroup.unStub(DefaultActionGroup.java:349)
at com.intellij.openapi.actionSystem.DefaultActionGroup.getChildren(DefaultActionGroup.java:305)
at com.intellij.openapi.actionSystem.impl.Utils.expandActionGroup(Utils.java:185)
at com.intellij.openapi.actionSystem.impl.Utils.fillMenu(Utils.java:350)
at com.intellij.openapi.actionSystem.impl.ActionMenu.fillMenu(ActionMenu.java:321)
at com.intellij.openapi.actionSystem.impl.ActionMenu.access$600(ActionMenu.java:42)
at com.intellij.openapi.actionSystem.impl.ActionMenu$MenuListenerImpl.menuSelected(ActionMenu.java:276)
at javax.swing.JMenu.fireMenuSelected(JMenu.java:1038)
at javax.swing.JMenu$MenuChangeListener.stateChanged(JMenu.java:1118)
at javax.swing.DefaultButtonModel.fireStateChanged(DefaultButtonModel.java:349)
at javax.swing.DefaultButtonModel.setSelected(DefaultButtonModel.java:232)
at javax.swing.JMenu.setSelected(JMenu.java:305)
at javax.swing.JMenu.menuSelectionChanged(JMenu.java:1187)
at com.intellij.openapi.actionSystem.impl.ActionMenu.menuSelectionChanged(ActionMenu.java:240)
at javax.swing.MenuSelectionManager.setSelectedPath(MenuSelectionManager.java:125)
at javax.swing.plaf.basic.BasicMenuUI$Handler.mouseEntered(BasicMenuUI.java:526)
at java.awt.Component.processMouseEvent(Component.java:6557)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3325)
at java.awt.Component.processEvent(Component.java:6313)
at java.awt.Container.processEvent(Container.java:2237)
at java.awt.Component.dispatchEventImpl(Component.java:4903)
at java.awt.Container.dispatchEventImpl(Container.java:2295)
at java.awt.Component.dispatchEvent(Component.java:4725)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4889)
at java.awt.LightweightDispatcher.retargetMouseEnterExit(Container.java:4677)
at java.awt.LightweightDispatcher.trackMouseEnterExit(Container.java:4655)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4506)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4467)
at java.awt.Container.dispatchEventImpl(Container.java:2281)
at java.awt.Window.dispatchEventImpl(Window.java:2746)
at java.awt.Component.dispatchEvent(Component.java:4725)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:764)
at java.awt.EventQueue.access$500(EventQueue.java:98)
at java.awt.EventQueue$3.run(EventQueue.java:715)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:90)
at java.awt.EventQueue$4.run(EventQueue.java:737)
at java.awt.EventQueue$4.run(EventQueue.java:735)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:734)
at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:817)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:754)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:394)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
我认为原因在于我的jdk的版本和intellij的版本对不上
解决办法:版本改成右边的这个,加上1.8的jdk,编出来的插件就没有上面那个问题了