mirror of https://github.com/zulip/zulip.git
Respect enter-to-send in edit box
(imported from commit 6e3fc6495b7012aa12728a78b8bdd95701bb21e1)
This commit is contained in:
parent
d9dba41767
commit
c5183427f3
|
@ -54,7 +54,9 @@ function handle_edit_keydown(e) {
|
|||
var row, code = e.keyCode || e.which;
|
||||
|
||||
if (e.target.id === "message_edit_content" && code === 13 &&
|
||||
(e.metaKey || e.ctrlKey)) {
|
||||
(e.metaKey || e.ctrlKey || (page_params.enter_sends && !e.shiftKey))) {
|
||||
e.preventDefault();
|
||||
|
||||
row = $(".message_edit_content").filter(":focus").closest(".message_row");
|
||||
if (message_edit.save(row) === true) {
|
||||
message_edit.end(row);
|
||||
|
|
Loading…
Reference in New Issue