如果这个问题显而易见,请道歉。我在OSX上的intellij中构建了一个JAVAFX项目。当我在仍然在intellij中的Windows机器上打开这个项目时,编译器无法找到任何导入的类。
如果我删除导入然后alt-enter,intellij会立即找到它们,但在编译时仍然找不到它们。
这是因为项目是使用OSX SDK和库构建的吗?
Java FX\JavaFX-Events-
Continued-Source-code\src\sample\Main.java
Error:(3, 26) java: package javafx.application does not exist
Error:(4, 19) java: package javafx.fxml does not exist
Error:(5, 20) java: package javafx.scene does not exist
Error:(6, 20) java: package javafx.scene does not exist
Error:(7, 20) java: package javafx.stage does not exist
Error:(9, 27) java: cannot find symbol
symbol: class Application
Error:(12, 23) java: cannot find symbol
symbol: class Stage
location: class sample.Main
Error:(11, 5) java: method does not override or implement a method from a supertype
Error:(13, 9) java: cannot find symbol
symbol: class Parent
location: class sample.Main
Error:(13, 39) java: cannot find symbol
symbol: method getClass()
location: class sample.Main
Error:(13, 23) java: cannot find symbol
symbol: variable FXMLLoader
location: class sample.Main
Error:(15, 35) java: cannot find symbol
symbol: class Scene
location: class sample.Main
Error:(21, 9) java: cannot find symbol
symbol: method launch(java.lang.String[])
location: class sample.Main