Skip to content

Prevent close doesn't work #136

Open
@nadavkaner

Description

@nadavkaner

I can't prevent from the window to close from the window red close button, I want to prevent the close and instead just hide the window.
this is the code I'm trying:

browserWindow.on('close', (event) => {
    event.preventDefault();
});

The event 'close' being fire but the window still being close.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions