Fixed IE9 issue with event listener not being set up due to sync IE behavior

See for example http://stackoverflow.com/questions/11801711/show-event-doesnt-fire-in-ie9-using-twitter-bootstrap-modal-in-rails