change all delegate method to on method (js)