testdriverai 7.5.11 → 7.5.12
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/CHANGELOG.md +6 -0
- package/agent/lib/system.js +5 -3
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/agent/lib/system.js
CHANGED
|
@@ -164,9 +164,11 @@ const createSystem = (emitter, sandbox, config) => {
|
|
|
164
164
|
const cursorPath = path.join(__dirname, "resources", "cursor-2.png");
|
|
165
165
|
const mousePos = await getMousePosition();
|
|
166
166
|
|
|
167
|
-
// Load and composite the mouse cursor image
|
|
168
|
-
|
|
169
|
-
|
|
167
|
+
// Load and composite the mouse cursor image if we have valid coordinates
|
|
168
|
+
if (mousePos && typeof mousePos.x === "number" && typeof mousePos.y === "number") {
|
|
169
|
+
const cursorImage = await Jimp.read(cursorPath);
|
|
170
|
+
image.composite(cursorImage, mousePos.x, mousePos.y);
|
|
171
|
+
}
|
|
170
172
|
}
|
|
171
173
|
|
|
172
174
|
await image.writeAsync(step2);
|