From c277f85ad2e109661aba02cd37fb770f7b985273 Mon Sep 17 00:00:00 2001 From: harveyshao Date: Sat, 9 Apr 2022 23:28:24 +0800 Subject: [PATCH] opt some --- frame.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/frame.js b/frame.js index 0c2c3752..cf4cc051 100644 --- a/frame.js +++ b/frame.js @@ -861,6 +861,13 @@ Volcanos("onmotion", {help: "动态特效", list: [], _init: function(can, targe }, }) Volcanos("onkeymap", {help: "键盘交互", list: [], _focus: [], _init: function(can, target) { + document.body.onclick = function(event) { + if (window.webview) { + if (event.target.tagName == "A") { + window.open(event.target.href) + } + } + } can.onkeymap._build(can), document.body.onkeydown = function(event) { if (event.metaKey) { if (window.webview) { switch (event.key) {