|
|
|
@ -33,9 +33,16 @@ function runEvery10Sec() {
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
// document.onkeydown = keyDown;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$(function(){
|
|
|
|
|
document.addEventListener('keydown', function(e){
|
|
|
|
|
if (e.keyCode == 83 && (navigator.platform.match("Mac") ? e.metaKey : e.ctrlKey)){
|
|
|
|
|
e.preventDefault();
|
|
|
|
|
console.log("点击了ctrl+s");
|
|
|
|
|
console.log("开始发送消息了ctrl+s");
|
|
|
|
|
window.parent.postMessage('jupytermessage','*');
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
})
|
|
|
|
|
$(function(){
|
|
|
|
|
window.addEventListener('message', (e) => {
|
|
|
|
|
console.log("触发了Parentwindow");
|
|
|
|
|