(DocumentType type, File document, boolean isBlank)
| 134 | Map<Option, Object> globalOptions = new EnumMap<>(Option.class); |
| 135 | |
| 136 | private Program createTab(DocumentType type, File document, boolean isBlank) { |
| 137 | WebView editor = new WebView(); |
| 138 | Program proxy = new Program(type, globalOptions); |
| 139 | proxy.initEditor(editor, document, isBlank); |
| 140 | Tab t = new Tab(proxy.getName(), editor); |
| 141 | tabPane.getTabs().add(t); |
| 142 | openDocuments.put(t, proxy); |
| 143 | t.setOnCloseRequest(this::handleCloseTabRequest); |
| 144 | return proxy; |
| 145 | } |
| 146 | |
| 147 | private void handleCloseTabRequest(Event e) { |
| 148 | Tab t = (Tab) e.getTarget(); |
no test coverage detected