Add setContents to textSelection impl of CodeEditor

Change-Id: I0a5434b9d40d8945b6b801e2aa2b4b23466ea71c