Disable context menu for markdown comps

This commit is contained in:
crschnick 2024-02-28 08:53:41 +00:00
parent d86925c1a3
commit e56c159e0e

View file

@ -46,6 +46,8 @@ public class MarkdownComp extends Comp<CompStructure<StackPane>> {
@SneakyThrows
private WebView createWebView() {
var wv = new WebView();
wv.getEngine().setJavaScriptEnabled(false);
wv.setContextMenuEnabled(false);
wv.getEngine()
.setUserDataDirectory(
AppProperties.get().getDataDir().resolve("webview").toFile());