🔧 Don't set scale on non-Windows
This commit is contained in:
parent
334a52b238
commit
8b3117689e
2
src/.github/issue_template.md
vendored
2
src/.github/issue_template.md
vendored
|
@ -1,3 +1,3 @@
|
|||
⚠️ Thank you for reporting an issue!
|
||||
|
||||
Before we go any further, understand that I probably won't fullfil feature requests. I will however _gladly_ help you make a pull request if you're willing to play with Javascript!
|
||||
Before we go any further, understand that I probably won't fullfil feature requests. I will however _gladly_ help you make a pull request if you're willing to play with Javascript!
|
|
@ -35,10 +35,12 @@ async function main (id) {
|
|||
|
||||
// New v86 instance
|
||||
window.emulator = new V86Starter(opts)
|
||||
|
||||
//high-dpi support
|
||||
var scale = window.devicePixelRatio;
|
||||
window.emulator.screen_adapter.set_scale(scale,scale);
|
||||
|
||||
// High DPI support
|
||||
if (navigator.userAgent.includes('Windows')) {
|
||||
var scale = window.devicePixelRatio;
|
||||
window.emulator.screen_adapter.set_scale(scale,scale);
|
||||
}
|
||||
|
||||
// Restore state. We can't do this right away.
|
||||
setTimeout(async () => {
|
||||
|
|
Loading…
Reference in a new issue