Skip to content

Instantly share code, notes, and snippets.

View viveksoundrapandi's full-sized avatar

Vivek Soundrapandi viveksoundrapandi

View GitHub Profile
@viveksoundrapandi
viveksoundrapandi / native-window.js
Created September 20, 2012 09:17
Trigger native window of browser
$(function(){
var submitted = false;
//links having the below class will not trigger native widow
$(".cancel_submit").live('click',function (e){
submitted=true;
});
window.onkeydown = function(e){
var key = e.keyCode ? e.keyCode : e.charCode ? e.charCode : false;
if (((e.ctrlKey || e.metaKey)&&key==82 )||key==116)
{