diff --git a/web/common-function.js b/web/common-function.js index 00f86a52f..34c11abd6 100644 --- a/web/common-function.js +++ b/web/common-function.js @@ -380,8 +380,10 @@ function selectAll() { function clearAll() { if (the.editor) { the.editor.setValue(''); + the.editor.focus(); } else { $('#source').val(''); + $('#source').focus(); } }