pyret-embed 0.0.26 → 0.0.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/build/web/js/beforePyret.js +4 -1
- package/dist/build/web/js/cpo-main.jarr +11 -5
- package/dist/build/web/js/cpo-main.jarr.gz.js +0 -0
- package/dist/build/web/js/cpo-main.jarr.js +11 -5
- package/dist/build/web/js/cpo-main.jarr.min +1 -1
- package/dist/build/web/js/cpo-main.js +11 -5
- package/package.json +1 -1
|
@@ -666,11 +666,17 @@
|
|
|
666
666
|
|
|
667
667
|
// save
|
|
668
668
|
// On Mac mod ends up mapping to command+s whereas on Windows and Linux it maps to ctrl+s.
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
669
|
+
// Saving has a special condition: when embedded we want the Ctrl-S to
|
|
670
|
+
// propagate up. We could fire a special “save” event, but for contexts
|
|
671
|
+
// like VScode it is nice to have the “real” Cmd-S event fire to get
|
|
672
|
+
// good default behavior
|
|
673
|
+
if(!PYRET_IS_EMBEDDED) {
|
|
674
|
+
Mousetrap.bindGlobal('mod+s', function(e) {
|
|
675
|
+
CPO.save();
|
|
676
|
+
e.stopImmediatePropagation();
|
|
677
|
+
e.preventDefault();
|
|
678
|
+
});
|
|
679
|
+
}
|
|
674
680
|
|
|
675
681
|
// resize, Toggle sizing of the editor window between 50% and last resize
|
|
676
682
|
Mousetrap.bindGlobal('ctrl+m', function(e){
|