Access THIS inside Jquery listener : <p>I'm trying to achieve the task shown by the example code below, but get this error :</p>

<blockquote>
  <p>Uncaught TypeError: this.myFunction is not a function</p>
</blockquote>

<p>I know i'm doing something wrong but don't know the right way to do it : how can i access the 'this' object inside a Jquery listener ?</p>

<p>Thanks in advance !</p>

<pre><code>var MyClass = function () {
    return {
        myFunction: function () {
            console.log('Do something');
        },
        myOtherFunction: function() {
            $('#myButton').on('click', function () {
                this.myFunction(); // here i get the error
            });            
        }
    }
}
</code></pre>
