Skip to content

Commit

Permalink
Merge pull request #7033 from RocketChat/fix-ctrl-message
Browse files Browse the repository at this point in the history
[FIX] Prevent Ctrl key on message field from reloading messages list
  • Loading branch information
engelgabriel authored May 24, 2017
2 parents 08e33dd + 2b7b28a commit caeea79
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/rocketchat-ui/client/lib/chatMessages.js
Original file line number Diff line number Diff line change
Expand Up @@ -477,9 +477,11 @@ this.ChatMessages = class ChatMessages {
return false;

// ctrl (command) + shift + k -> clear room messages
} else if (k === 75 && navigator && navigator.platform && event.shiftKey && (navigator.platform.indexOf('Mac') !== -1 && event.metaKey) || event.ctrlKey) {
return RoomHistoryManager.clear(rid);
}
// TODO
// else if (k === 75 && navigator && navigator.platform && event.shiftKey && (navigator.platform.indexOf('Mac') !== -1 ? event.metaKey : event.ctrlKey)) {
// return RoomHistoryManager.clear(rid);
// }
}

valueChanged(/*rid, event*/) {
Expand Down

0 comments on commit caeea79

Please sign in to comment.