From 8879fb55deb0eb73dfe626113f4df3f09bbb6876 Mon Sep 17 00:00:00 2001 From: Karsten Hassel Date: Sun, 29 Aug 2021 22:12:14 +0200 Subject: [PATCH] disable black cursor on start --- .github/CONTRIBUTING.md | 2 +- .github/ISSUE_TEMPLATE.md | 2 +- CHANGELOG.md | 1 + js/electron.js | 5 +++++ 4 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index d66290d4..d3912283 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -34,7 +34,7 @@ When submitting a new issue, please supply the following information: **Node Version**: Make sure it's version 12 or later (recommended is 14). -**MagicMirror Version**: Please let us now which version of MagicMirror you are running. It can be found in the `package.json` file. +**MagicMirror Version**: Please let us know which version of MagicMirror you are running. It can be found in the `package.json` file. **Description**: Provide a detailed description about the issue and include specific details to help us understand the problem. Adding screenshots will help describing the problem. diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md index 69e08a6c..d343534a 100644 --- a/.github/ISSUE_TEMPLATE.md +++ b/.github/ISSUE_TEMPLATE.md @@ -34,7 +34,7 @@ When submitting a new issue, please supply the following information: **Node Version**: Make sure it's version 12 or later (recommended is 14). -**MagicMirror Version**: Please let us now which version of MagicMirror you are running. It can be found in the `package.json` file. +**MagicMirror Version**: Please let us know which version of MagicMirror you are running. It can be found in the `package.json` file. **Description**: Provide a detailed description about the issue and include specific details to help us understand the problem. Adding screenshots will help describing the problem. diff --git a/CHANGELOG.md b/CHANGELOG.md index 5939c003..ecd019c5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,7 @@ _This release is scheduled to be released on 2021-10-01._ - Fix undefined error with ignoreToday option in weather module (#2620). - Fix time zone correction in calendar module when the date hour is equal to the time zone correction value (#2632). +- Fix black cursor on startup when using electron. ## [2.16.0] - 2021-07-01 diff --git a/js/electron.js b/js/electron.js index 36b3d352..3f9e53f9 100644 --- a/js/electron.js +++ b/js/electron.js @@ -71,6 +71,11 @@ function createWindow() { mainWindow.webContents.openDevTools(); } + // simulate mouse move to hide black cursor on start + mainWindow.webContents.on('dom-ready', (event)=> { + mainWindow.webContents.sendInputEvent({type: "mouseMove", x: 0, y: 0}); + }); + // Set responders for window events. mainWindow.on("closed", function () { mainWindow = null;