Index: /CKEditor/trunk/CHANGES.html
===================================================================
--- /CKEditor/trunk/CHANGES.html	(revision 6288)
+++ /CKEditor/trunk/CHANGES.html	(revision 6289)
@@ -68,4 +68,5 @@
 		<li><a href="http://dev.ckeditor.com/ticket/6645">#6645</a> : Allow to configure if &quot; (double quotes) should be encoded in the contents.</li>
 		<li><a href="http://dev.ckeditor.com/ticket/6336">#6336</a> : IE: clicking in an input type="submit" button submitted the form.</li>
+		<li><a href="http://dev.ckeditor.com/ticket/6646">#6646</a> : Context menu wasn't working for text inputs present in the initial content.</li>
 	</ul>
 	<h3>
Index: /CKEditor/trunk/_source/core/dom/node.js
===================================================================
--- /CKEditor/trunk/_source/core/dom/node.js	(revision 6288)
+++ /CKEditor/trunk/_source/core/dom/node.js	(revision 6289)
@@ -680,5 +680,5 @@
 				if ( current.type == CKEDITOR.NODE_ELEMENT )
 				{
-					if ( current.is( 'body' ) || current.getCustomData( '_cke_notReadOnly' ) )
+					if ( current.is( 'body' ) || !!current.data( 'cke-editable' ) )
 						break;
 
Index: /CKEditor/trunk/_source/plugins/htmldataprocessor/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/htmldataprocessor/plugin.js	(revision 6288)
+++ /CKEditor/trunk/_source/plugins/htmldataprocessor/plugin.js	(revision 6289)
@@ -261,9 +261,21 @@
 	function protectReadOnly( element )
 	{
-		element.attributes.contenteditable = "false";
+		var attrs = element.attributes;
+
+		// We should flag that the element was locked by our code so
+		// it'll be editable by the editor functions (#6046).
+		if ( attrs.contenteditable != "false" )
+			attrs[ 'data-cke-editable' ] = attrs.contenteditable ? 'true' : 1;
+
+		attrs.contenteditable = "false";
 	}
 	function unprotectReadyOnly( element )
 	{
-		delete element.attributes.contenteditable;
+		var attrs = element.attributes;
+		switch( attrs[ 'data-cke-editable' ] )
+		{
+			case 'true':	attrs.contenteditable = 'true';	break;
+			case '1':		delete attrs.contenteditable;	break;
+		}
 	}
 	// Disable form elements editing mode provided by some browers. (#5746)
Index: /CKEditor/trunk/_source/plugins/wysiwygarea/plugin.js
===================================================================
--- /CKEditor/trunk/_source/plugins/wysiwygarea/plugin.js	(revision 6288)
+++ /CKEditor/trunk/_source/plugins/wysiwygarea/plugin.js	(revision 6289)
@@ -1138,11 +1138,9 @@
 						&& ( element.is( 'input' ) || element.is( 'textarea' ) ) )
 				{
+					// We should flag that the element was locked by our code so
+					// it'll be editable by the editor functions (#6046).
 					if ( !element.isReadOnly() )
-					{
-						element.setAttribute( 'contentEditable', false );
-						// We should flag that the element was locked by our code so
-						// it'll be editable by the editor functions (#6046).
-						element.setCustomData( '_cke_notReadOnly', 1 );
-					}
+						element.data( 'cke-editable', element.hasAttribute( 'contenteditable' ) ? 'true' : '1' );
+					element.setAttribute( 'contentEditable', false );
 				}
 			});
