From a9eb62880e45c166bdcd84811b6f33dac5cf6cef Mon Sep 17 00:00:00 2001
From: Toby Zerner <toby.zerner@gmail.com>
Date: Tue, 20 Oct 2015 12:49:19 +1030
Subject: [PATCH] Remove behaviour where backspace re-focuses on title field

---
 js/forum/src/components/DiscussionComposer.js | 17 -----------------
 1 file changed, 17 deletions(-)

diff --git a/js/forum/src/components/DiscussionComposer.js b/js/forum/src/components/DiscussionComposer.js
index f3efa8567..2b0743a44 100644
--- a/js/forum/src/components/DiscussionComposer.js
+++ b/js/forum/src/components/DiscussionComposer.js
@@ -65,23 +65,6 @@ export default class DiscussionComposer extends ComposerBody {
     m.redraw.strategy('none');
   }
 
-  config(isInitialized, context) {
-    super.config(isInitialized, context);
-
-    // If the user presses the backspace key in the text editor, and the cursor
-    // is already at the start, then we'll move the focus back into the title
-    // input.
-    this.editor.$('textarea').keydown((e) => {
-      if (e.which === 8 && e.target.selectionStart === 0 && e.target.selectionEnd === 0) {
-        e.preventDefault();
-
-        const $title = this.$(':input:enabled:visible:first')[0];
-        $title.focus();
-        $title.selectionStart = $title.selectionEnd = $title.value.length;
-      }
-    });
-  }
-
   preventExit() {
     return (this.title() || this.content()) && this.props.confirmExit;
   }