(ctor)
| 2012 | // Add on and off methods to a constructor's prototype, to make |
| 2013 | // registering events on such objects more convenient. |
| 2014 | function eventMixin(ctor) { |
| 2015 | ctor.prototype.on = function (type, f) { |
| 2016 | on(this, type, f) |
| 2017 | } |
| 2018 | ctor.prototype.off = function (type, f) { |
| 2019 | off(this, type, f) |
| 2020 | } |
| 2021 | } |
| 2022 | |
| 2023 | // Due to the fact that we still support jurassic IE versions, some |
| 2024 | // compatibility wrappers are needed. |
no test coverage detected