Skip to content
Snippets Groups Projects
Commit 2746adde authored by Jan Kožusznik's avatar Jan Kožusznik
Browse files

solved Petr Bainar discusion

parent 4e62addf
No related branches found
No related tags found
1 merge request!10Jfxrefactoring
......@@ -38,14 +38,18 @@ public interface CloseableControl extends Closeable {
}
});
fxmlLoader.setRoot(parent);
// fxmlLoader.setController(parent);
try {
fxmlLoader.load();
} catch (IOException exception) {
throw new RuntimeException(exception);
}
Object explicitController = null;
do {
fxmlLoader.setController(explicitController);
try {
fxmlLoader.load();
} catch (IOException exception) {
throw new RuntimeException(exception);
}
if(fxmlLoader.getController() == null) {
explicitController = parent;
}
} while(fxmlLoader.getController() == null);
}
static public <V> void executeAsync(Executor executor, Callable<V> action, Consumer<V> postAction) {
......@@ -73,8 +77,6 @@ public interface CloseableControl extends Closeable {
Function<U, V> mapper) {
((TableColumn<T, V>) tableView.getColumns().get(index))
.setCellValueFactory(f -> new ObservableValueAdapter<U, V>(f.getValue(), mapper));
// ((TableColumn<T, String>)
// tableView.getColumns().get(index)).setCellFactory(f->f.set);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment