@miniben90/x-win 1.3.1 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -1
- package/index.js +29 -0
- package/package.json +11 -11
package/README.md
CHANGED
|
@@ -96,12 +96,15 @@ console.log(windows);
|
|
|
96
96
|
|
|
97
97
|
# Linux
|
|
98
98
|
|
|
99
|
-
|
|
99
|
+
Dependencies are required to be installed for development purposes.
|
|
100
100
|
|
|
101
101
|
```sh
|
|
102
102
|
sudo apt install libxcb1-dev libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libxcb-shm0-dev
|
|
103
103
|
```
|
|
104
104
|
|
|
105
|
+
> ⚠️**Warning**
|
|
106
|
+
> Recovery url is not available for linux dist
|
|
107
|
+
|
|
105
108
|
# Darwin
|
|
106
109
|
|
|
107
110
|
## Screen recording permission introduced in macOS 10.15 Catalina
|
|
@@ -164,6 +167,11 @@ It will use AppleScript to get informations for chromium browsers and safari
|
|
|
164
167
|
| opera software - OperaGX | ✅ |
|
|
165
168
|
| Vivaldi | |
|
|
166
169
|
|
|
170
|
+
## Electron
|
|
171
|
+
|
|
172
|
+
* To prevent potential crashes and issues, it's recommended to execute recovery operations within a worker thread ([https://nodejs.org/api/worker_threads.html](https://nodejs.org/api/worker_threads.html))
|
|
173
|
+
* For macOS, you can utilize functions to check and request screen permissions ([https://www.electronjs.org/fr/docs/latest/api/system-preferences](https://www.electronjs.org/fr/docs/latest/api/system-preferences))
|
|
174
|
+
|
|
167
175
|
<hr class="padding-top: 30px;padding-bottom:30px">
|
|
168
176
|
|
|
169
177
|
# Project References
|
package/index.js
CHANGED
|
@@ -237,6 +237,35 @@ switch (platform) {
|
|
|
237
237
|
loadError = e
|
|
238
238
|
}
|
|
239
239
|
break
|
|
240
|
+
case 'riscv64':
|
|
241
|
+
if (isMusl()) {
|
|
242
|
+
localFileExisted = existsSync(
|
|
243
|
+
join(__dirname, 'x-win.linux-riscv64-musl.node')
|
|
244
|
+
)
|
|
245
|
+
try {
|
|
246
|
+
if (localFileExisted) {
|
|
247
|
+
nativeBinding = require('./x-win.linux-riscv64-musl.node')
|
|
248
|
+
} else {
|
|
249
|
+
nativeBinding = require('@miniben90/x-win-linux-riscv64-musl')
|
|
250
|
+
}
|
|
251
|
+
} catch (e) {
|
|
252
|
+
loadError = e
|
|
253
|
+
}
|
|
254
|
+
} else {
|
|
255
|
+
localFileExisted = existsSync(
|
|
256
|
+
join(__dirname, 'x-win.linux-riscv64-gnu.node')
|
|
257
|
+
)
|
|
258
|
+
try {
|
|
259
|
+
if (localFileExisted) {
|
|
260
|
+
nativeBinding = require('./x-win.linux-riscv64-gnu.node')
|
|
261
|
+
} else {
|
|
262
|
+
nativeBinding = require('@miniben90/x-win-linux-riscv64-gnu')
|
|
263
|
+
}
|
|
264
|
+
} catch (e) {
|
|
265
|
+
loadError = e
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
break
|
|
240
269
|
default:
|
|
241
270
|
throw new Error(`Unsupported architecture on Linux: ${arch}`)
|
|
242
271
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@miniben90/x-win",
|
|
3
3
|
"description": "This package allows you to retrieve precise information about active and open windows on Windows, MacOS, and Linux. You can obtain the position, size, title, and other memory of windows.",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.4.0",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.d.ts",
|
|
7
7
|
"files": [
|
|
@@ -41,8 +41,8 @@
|
|
|
41
41
|
"open"
|
|
42
42
|
],
|
|
43
43
|
"devDependencies": {
|
|
44
|
-
"@napi-rs/cli": "^2.
|
|
45
|
-
"ava": "^
|
|
44
|
+
"@napi-rs/cli": "^2.17.0",
|
|
45
|
+
"ava": "^6.0.1"
|
|
46
46
|
},
|
|
47
47
|
"ava": {
|
|
48
48
|
"timeout": "3m"
|
|
@@ -59,14 +59,14 @@
|
|
|
59
59
|
"universal": "napi universal",
|
|
60
60
|
"version": "napi version"
|
|
61
61
|
},
|
|
62
|
-
"packageManager": "yarn@
|
|
62
|
+
"packageManager": "yarn@4.0.2",
|
|
63
63
|
"optionalDependencies": {
|
|
64
|
-
"@miniben90/x-win-win32-x64-msvc": "1.
|
|
65
|
-
"@miniben90/x-win-darwin-x64": "1.
|
|
66
|
-
"@miniben90/x-win-linux-x64-gnu": "1.
|
|
67
|
-
"@miniben90/x-win-darwin-arm64": "1.
|
|
68
|
-
"@miniben90/x-win-win32-arm64-msvc": "1.
|
|
69
|
-
"@miniben90/x-win-win32-ia32-msvc": "1.
|
|
70
|
-
"@miniben90/x-win-darwin-universal": "1.
|
|
64
|
+
"@miniben90/x-win-win32-x64-msvc": "1.4.0",
|
|
65
|
+
"@miniben90/x-win-darwin-x64": "1.4.0",
|
|
66
|
+
"@miniben90/x-win-linux-x64-gnu": "1.4.0",
|
|
67
|
+
"@miniben90/x-win-darwin-arm64": "1.4.0",
|
|
68
|
+
"@miniben90/x-win-win32-arm64-msvc": "1.4.0",
|
|
69
|
+
"@miniben90/x-win-win32-ia32-msvc": "1.4.0",
|
|
70
|
+
"@miniben90/x-win-darwin-universal": "1.4.0"
|
|
71
71
|
}
|
|
72
72
|
}
|