-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpreload.js
More file actions
44 lines (42 loc) · 1.16 KB
/
Copy pathpreload.js
File metadata and controls
44 lines (42 loc) · 1.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
function show(payload) {
localStorage.setItem("brokenclient", payload);
let img = new Image();
img.src = payload;
img.onload = () => {
let win = utools.createBrowserWindow(
"ruler.html",
{
title: "ruler",
x: null,
y: null,
width: img.width,
height: img.height,
useContentSize: false,
skipTaskbar: true,
frame: false,
minimizable: false,
maximizable: false,
fullscreenable: false,
alwaysOnTop: true,
},
() => {
// win.webContents.openDevTools();
}
);
};
}
window.exports = {
"main": {
mode: "none",
args: {
enter: (action) => {
utools.hideMainWindow();
utools.screenCapture((base64Str) => {
utools.copyImage(base64Str);
show(base64Str);
utools.outPlugin();
});
},
},
},
};