🐛 SDA-3450 - Remove title bar on fullscreen (#1304)

This commit is contained in:
Kiran Niranjan 2021-12-02 13:36:28 +05:30 committed by GitHub
parent bf2f43da93
commit c59efaefbe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1074,6 +1074,7 @@ export const loadBrowserViews = async (
setTimeout(() => {
const [width, height] = mainWindow.getSize();
titleBarView.setBounds({ x: 0, y: 0, width, height: 0 });
mainWindow.removeBrowserView(titleBarView);
if (!mainView || !viewExists(mainView)) {
return;
@ -1100,6 +1101,7 @@ export const loadBrowserViews = async (
// to get updated window bounds
setTimeout(() => {
const [width, height] = mainWindow.getSize();
mainWindow.addBrowserView(titleBarView);
titleBarView.setBounds({ x: 0, y: 0, width, height: TITLE_BAR_HEIGHT });
if (!mainView || !viewExists(mainView)) {
return;