aboutsummaryrefslogtreecommitdiff
path: root/src/yuzu/applets/qt_web_browser_scripts.h
diff options
context:
space:
mode:
authorMorph <39850852+Morph1984@users.noreply.github.com>2021-07-27 22:46:27 -0400
committerGitHub <noreply@github.com>2021-07-27 22:46:27 -0400
commit5593a3716e918c36e9e9f4b0709f2f85e083b6bd (patch)
treebfcb19aed0cfd114210fdc85f197d8f6828065a1 /src/yuzu/applets/qt_web_browser_scripts.h
parentd923ec5805e6cecde138559515ec5920f45fc452 (diff)
parentef29ed75b0f849b8eb5beeac3064557762e0c82b (diff)
Merge pull request #6671 from jls47/master
applets/web: Addressing QT Navigation issues in Linux
Diffstat (limited to 'src/yuzu/applets/qt_web_browser_scripts.h')
-rw-r--r--src/yuzu/applets/qt_web_browser_scripts.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/yuzu/applets/qt_web_browser_scripts.h b/src/yuzu/applets/qt_web_browser_scripts.h
index 992837a85..c4ba8d40f 100644
--- a/src/yuzu/applets/qt_web_browser_scripts.h
+++ b/src/yuzu/applets/qt_web_browser_scripts.h
@@ -73,6 +73,12 @@ constexpr char LOAD_NX_FONT[] = R"(
})();
)";
+constexpr char FOCUS_LINK_ELEMENT_SCRIPT[] = R"(
+if (document.getElementsByTagName("a").length > 0) {
+ document.getElementsByTagName("a")[0].focus();
+}
+)";
+
constexpr char GAMEPAD_SCRIPT[] = R"(
window.addEventListener("gamepadconnected", function(e) {
console.log("Gamepad connected at index %d: %s. %d buttons, %d axes.",