Commit 8e9db5a7 authored by duminil's avatar duminil
Browse files

Deploying RegionChooser as stand-alone App.

parent dc73d98f
...@@ -212,8 +212,8 @@ private Path citygmlPath(String project, String citygml) { ...@@ -212,8 +212,8 @@ private Path citygmlPath(String project, String citygml) {
public void importNovaFactoryBoundingBoxes() throws IOException { public void importNovaFactoryBoundingBoxes() throws IOException {
JSObject novafactoryVectors = (JSObject) webEngine.executeScript("novafactory_vectors"); JSObject novafactoryVectors = (JSObject) webEngine.executeScript("novafactory_vectors");
BufferedReader nf_csv = Files.newBufferedReader(Paths BufferedReader nf_csv = new BufferedReader(new InputStreamReader(
.get("../RegionChooser/website/data/novafactory_products.csv")); RegionChooserFX.class.getResourceAsStream("website/data/novafactory_products.csv")));
nf_csv.readLine(); nf_csv.readLine();
String sCurrentLine; String sCurrentLine;
while ((sCurrentLine = nf_csv.readLine()) != null) { while ((sCurrentLine = nf_csv.readLine()) != null) {
...@@ -237,9 +237,8 @@ public void importNovaFactoryBoundingBoxes() throws IOException { ...@@ -237,9 +237,8 @@ public void importNovaFactoryBoundingBoxes() throws IOException {
public Browser() { public Browser() {
//apply the styles //apply the styles
getStyleClass().add("browser"); getStyleClass().add("browser");
// load the web page String url = RegionChooserFX.class.getResource("website/index.html").toExternalForm();
String url = Paths.get("../RegionChooser/website/index.html").toUri().toString(); webEngine.load(url); // load the web page
webEngine.load(url);
// process page loading // process page loading
webEngine.getLoadWorker().stateProperty().addListener( webEngine.getLoadWorker().stateProperty().addListener(
(ObservableValue<? extends State> ov, State oldState, State newState) -> { (ObservableValue<? extends State> ov, State oldState, State newState) -> {
......
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment