Thursday, 1 June 2017

Disable windows key in Electron

I'm making an electron desktop app. I want to disable windows key and function keys while the app is on

I tried using the following code ... it registers the event but the windows menu opens anyways

$(document).keydown(function(e){

    if (e.keyCode == 37) { 
       alert( "windows key pressed" );
       return false;
    }
});

Any help?



via Sushil Sudhakaran

No comments:

Post a Comment