mirror of
https://github.com/rommapp/romm.git
synced 2026-02-19 07:50:57 +01:00
Merge pull request #2405 from rommapp/emujs-threads-console-mode
Remove PSP and DOS support in console mode
This commit is contained in:
@@ -39,8 +39,8 @@ async function goToPlayer(rom: SimpleRom) {
|
||||
name: ROUTES.EMULATORJS,
|
||||
params: { rom: rom.id },
|
||||
});
|
||||
// Force full reload to retrieve COEP/COOP headers from nginx, needed to enable multi-threading
|
||||
// in EmulatorJS.
|
||||
// Force full reload to retrieve COEP/COOP headers from nginx
|
||||
// Required to enable multi-threading in EmulatorJS.
|
||||
router.go(0);
|
||||
} else if (
|
||||
isRuffleEmulationSupported(rom.platform_slug, heartbeat.value, config.value)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<script setup lang="ts">
|
||||
import { useIdle, useSessionStorage } from "@vueuse/core";
|
||||
import { useIdle } from "@vueuse/core";
|
||||
import { onMounted, onUnmounted, provide } from "vue";
|
||||
import { type RouteLocationNormalized } from "vue-router";
|
||||
import { useRouter } from "vue-router";
|
||||
@@ -14,11 +14,6 @@ const bus = new InputBus();
|
||||
const themeStore = useConsoleTheme();
|
||||
provide(InputBusSymbol, bus);
|
||||
|
||||
const fullScreenPostPlay = useSessionStorage(
|
||||
"emulation.fullScreenPostPlay",
|
||||
false,
|
||||
);
|
||||
|
||||
// Define route hierarchy for transition direction logic
|
||||
const routeHierarchy = {
|
||||
[ROUTES.CONSOLE_HOME]: 0,
|
||||
@@ -65,14 +60,6 @@ onMounted(() => {
|
||||
bus.pushScope();
|
||||
detachKeyboard = attachKeyboard(bus);
|
||||
detachGamepad = attachGamepad(bus);
|
||||
|
||||
// Re-enable fullscreen if it was enabled after exiting the game
|
||||
if (fullScreenPostPlay.value) {
|
||||
document.documentElement.requestFullscreen?.().catch((error) => {
|
||||
console.error("Error requesting fullscreen", error);
|
||||
});
|
||||
fullScreenPostPlay.value = false;
|
||||
}
|
||||
});
|
||||
|
||||
onUnmounted(() => {
|
||||
|
||||
@@ -16,12 +16,12 @@ const _SUPPORTED_PLATFORMS: Record<string, SupportedPlatform> = {
|
||||
accent: "#33b1ff",
|
||||
},
|
||||
arcade: {
|
||||
label: "Arcade / MAME",
|
||||
label: "Arcade/MAME",
|
||||
background: "linear-gradient(135deg,#d73266,#8b1538)",
|
||||
accent: "#d73266",
|
||||
},
|
||||
mame: {
|
||||
label: "Arcade / MAME",
|
||||
label: "Arcade/MAME",
|
||||
background: "linear-gradient(135deg,#d73266,#8b1538)",
|
||||
accent: "#d73266",
|
||||
},
|
||||
@@ -75,23 +75,18 @@ const _SUPPORTED_PLATFORMS: Record<string, SupportedPlatform> = {
|
||||
background: "linear-gradient(135deg,#42275a,#734b6d)",
|
||||
accent: "#b667d0",
|
||||
},
|
||||
dos: {
|
||||
label: "MS-DOS",
|
||||
background: "linear-gradient(135deg,#203a43,#2c5364)",
|
||||
accent: "#3fa7d6",
|
||||
},
|
||||
n64: {
|
||||
label: "Nintendo 64",
|
||||
background: "linear-gradient(135deg,#ffd700,#ff8c00)",
|
||||
accent: "#ffd700",
|
||||
},
|
||||
nes: {
|
||||
label: "Nintendo Entertainment System (NES)",
|
||||
label: "NES",
|
||||
background: "linear-gradient(135deg,#cc2936,#8b1538)",
|
||||
accent: "#cc2936",
|
||||
},
|
||||
famicom: {
|
||||
label: "Nintendo Family Computer (Famicom)",
|
||||
label: "Famicom",
|
||||
background: "linear-gradient(135deg,#cc2936,#8b1538)",
|
||||
accent: "#cc2936",
|
||||
},
|
||||
@@ -121,7 +116,7 @@ const _SUPPORTED_PLATFORMS: Record<string, SupportedPlatform> = {
|
||||
accent: "#b44cff",
|
||||
},
|
||||
psx: {
|
||||
label: "PlayStation (PS)",
|
||||
label: "PlayStation",
|
||||
background: "linear-gradient(135deg,#4169e1,#191970)",
|
||||
accent: "#4169e1",
|
||||
},
|
||||
@@ -146,7 +141,7 @@ const _SUPPORTED_PLATFORMS: Record<string, SupportedPlatform> = {
|
||||
accent: "#ff6347",
|
||||
},
|
||||
genesis: {
|
||||
label: "Sega Genesis / Megadrive",
|
||||
label: "Sega Genesis/Megadrive",
|
||||
background: "linear-gradient(135deg,#1e90ff,#0f4c75)",
|
||||
accent: "#1e90ff",
|
||||
},
|
||||
@@ -156,7 +151,7 @@ const _SUPPORTED_PLATFORMS: Record<string, SupportedPlatform> = {
|
||||
accent: "#4f7fbf",
|
||||
},
|
||||
snes: {
|
||||
label: "Super Nintendo Entertainment System (SNES)",
|
||||
label: "SNES",
|
||||
background: "linear-gradient(135deg,#e22828,#f81414)",
|
||||
accent: "#e22828",
|
||||
},
|
||||
@@ -166,7 +161,7 @@ const _SUPPORTED_PLATFORMS: Record<string, SupportedPlatform> = {
|
||||
accent: "#e22828",
|
||||
},
|
||||
tg16: {
|
||||
label: "TurboGrafx-16 / PC Engine",
|
||||
label: "TurboGrafx-16/PC Engine",
|
||||
background: "linear-gradient(135deg,#ff9966,#ff5e62)",
|
||||
accent: "#ff7b54",
|
||||
},
|
||||
|
||||
@@ -661,15 +661,6 @@ onBeforeUnmount(() => {
|
||||
detachKey?.();
|
||||
detachPad?.();
|
||||
});
|
||||
|
||||
onUnmounted(() => {
|
||||
if (document.fullscreenElement) {
|
||||
// Remember to re-enable fullscreen after exiting the game
|
||||
sessionStorage.setItem("emulation.fullScreenPostPlay", "true");
|
||||
}
|
||||
// Force full reload to reset COEP/COOP, so cross-origin isolation is turned off.
|
||||
window.location.reload();
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
||||
Reference in New Issue
Block a user