提交 eb9d146d 编写于 作者: B Benjamin Pasero

Revert "Markdown/HTML Preview: I can open links within VS Code (fixes #2362)"

This reverts commit f8ad5c52.
上级 e44dc204
...@@ -197,11 +197,7 @@ export class IFrameEditor extends BaseEditor { ...@@ -197,11 +197,7 @@ export class IFrameEditor extends BaseEditor {
'window.document.body.addEventListener("drop", function (e) {', 'window.document.body.addEventListener("drop", function (e) {',
' e.preventDefault();', ' e.preventDefault();',
'});', '});',
'</script>'
// disable navigating to some URL!
'window.onbeforeunload = function () {',
' return false;',
'};'
].join('\n'); ].join('\n');
} }
...@@ -214,7 +210,7 @@ export class IFrameEditor extends BaseEditor { ...@@ -214,7 +210,7 @@ export class IFrameEditor extends BaseEditor {
} }
private clearIFrame(): void { private clearIFrame(): void {
this.setFrameContents(null, '', true); this.iframeBuilder.src('about:blank');
this.iframeBuilder.removeProperty(IFrameEditor.RESOURCE_PROPERTY); this.iframeBuilder.removeProperty(IFrameEditor.RESOURCE_PROPERTY);
} }
......
...@@ -262,12 +262,7 @@ namespace Integration { ...@@ -262,12 +262,7 @@ namespace Integration {
'});', '});',
'window.document.body.addEventListener("drop", function (e) {', 'window.document.body.addEventListener("drop", function (e) {',
' e.preventDefault();', ' e.preventDefault();',
'});', '});'
// disable navigating to some URL!
'window.onbeforeunload = function () {',
' return false;',
'};'
]; ];
export function defaultHtml() { export function defaultHtml() {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册