title: QML TextInput : How to detect user has completed typing on the text field
body: <p>I am new to Qt &amp; QML. I am using QtQuick 2.4. I have <code>TextInput</code> item with a signal defined in a <code>qml</code> file like below:</p>
  
  <pre><code>import QtQuick 2.4
  
  TextInput {
    text: "Text"
    cursorVisible: true
  
    signal qmlSignal(string msg)
  }
  </code></pre>
  
  <p>I also have a slot tied to the <code>qmlSignal</code>. I want to trigger the signal when user completes typing on the <code>TextInput</code> field or closes my qml page to go to another page in the application. </p>
  
  <p><em>What is the correct way to acheive this desired functionality ? Is there something like <code>onFocusChanged false</code> that I can detect, &amp; fire the qml signal ?</em></p>
  
  <p>I tried searching but couldn't get a sample of how to do this in qml</p>