* @private
()
| 239 | * @private |
| 240 | */ |
| 241 | _initialize() { |
| 242 | // Before init plugin notification |
| 243 | this.notifyPlugins('beforeInit'); |
| 244 | |
| 245 | if (this.options.responsive) { |
| 246 | this.resize(); |
| 247 | } else { |
| 248 | retinaScale(this, this.options.devicePixelRatio); |
| 249 | } |
| 250 | |
| 251 | this.bindEvents(); |
| 252 | |
| 253 | // After init plugin notification |
| 254 | this.notifyPlugins('afterInit'); |
| 255 | |
| 256 | return this; |
| 257 | } |
| 258 | |
| 259 | clear() { |
| 260 | clearCanvas(this.canvas, this.ctx); |
no test coverage detected