title: android 4.0.3 and JavaScript get selection returns empty string
body: <p>I'm trying to get selected text in android 4.0.3 web browser. Here is my code:</p>
  
  <pre><code>     $(document).on('selectionchange', function(e) {
             log ('Text is: ' + getSelectedText());
        });
  </code></pre>
  
  <p>And getSelectedText is:</p>
  
  <pre><code>function getSelectedText() {
   var text;
     if (typeof window.getSelection !== "undefined") {
       text = window.getSelection().toString();
     } else if (typeof document.selection !== "undefined") {
       text = document.selection.createRange().text;
   }
   return text;
  }
  </code></pre>
  
  <p>It works on Android 4.3, but doesn't on 4.0.3. What's wrong here?</p>