Skip to content
This repository was archived by the owner on Jun 5, 2019. It is now read-only.

Commit ebf07d5

Browse files
authored
Merge branch 'master' into upgrade-popmotion
2 parents 631c202 + a87060d commit ebf07d5

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/renderer/index.tsx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,15 @@
11
import * as React from "react"
22
import * as ReactDOM from "react-dom"
33
import { App } from "./features"
4+
import { webFrame } from "electron"
45

56
ReactDOM.render(<App />, document.getElementById("root"))
67

8+
// prevent pinch-to-zoom
9+
webFrame.setVisualZoomLevelLimits(1, 1)
10+
// if you want to set the zoom factor, delete this
11+
webFrame.setLayoutZoomLevelLimits(0, 0)
12+
713
// prevent drag & drop replacing the whole browser window
814
document.addEventListener("dragover", event => event.preventDefault())
915
document.addEventListener("drop", event => event.preventDefault())

0 commit comments

Comments
 (0)