JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
vanilla ckeditor-3.2.1
[ckeditor.git] / _source / plugins / htmldataprocessor / plugin.js
index b449355..264f504 100644 (file)
@@ -41,7 +41,12 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
        function blockNeedsExtension( block )\r
        {\r
                var lastChild = lastNoneSpaceChild( block );\r
-               return !lastChild || lastChild.type == CKEDITOR.NODE_ELEMENT && lastChild.name == 'br';\r
+\r
+               return !lastChild\r
+                       || lastChild.type == CKEDITOR.NODE_ELEMENT && lastChild.name == 'br'\r
+                       // Some of the controls in form needs extension too,\r
+                       // to move cursor at the end of the form. (#4791)\r
+                       || block.name == 'form' && lastChild.name == 'input';\r
        }\r
 \r
        function extendBlockForDisplay( block )\r