[MM-58001] Fix an issue where the window position has a decimal number (#3017)
* [MM-58001] Fix an issue where the window position has a decimal number * I accidentally a log
This commit is contained in:
@@ -155,8 +155,8 @@ function getNewWindowPosition(browserWindow: BrowserWindow) {
|
||||
const mainWindowPosition = mainWindow.getPosition();
|
||||
|
||||
return [
|
||||
mainWindowPosition[0] + ((mainWindowSize[0] - newWindowSize[0]) / 2),
|
||||
mainWindowPosition[1] + ((mainWindowSize[1] - newWindowSize[1]) / 2),
|
||||
Math.floor(mainWindowPosition[0] + ((mainWindowSize[0] - newWindowSize[0]) / 2)),
|
||||
Math.floor(mainWindowPosition[1] + ((mainWindowSize[1] - newWindowSize[1]) / 2)),
|
||||
];
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user