File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -77,13 +77,15 @@ class Layer extends JSONAble(Eventable(Renderable(Class))) {
77
77
return this ;
78
78
}
79
79
if ( this . onLoad ( ) ) {
80
+ this . _initRenderer ( ) ;
80
81
const zIndex = this . getZIndex ( ) ;
81
82
if ( ! isNil ( zIndex ) ) {
82
83
this . _renderer . setZIndex ( zIndex ) ;
83
84
if ( ! this . isCanvasRender ( ) ) {
84
85
this . _renderer . render ( ) ;
85
86
}
86
87
}
88
+ this . onLoadEnd ( ) ;
87
89
}
88
90
return this ;
89
91
}
@@ -414,6 +416,9 @@ class Layer extends JSONAble(Eventable(Renderable(Class))) {
414
416
return true ;
415
417
}
416
418
419
+ onLoadEnd ( ) {
420
+ }
421
+
417
422
/**
418
423
* Whether the layer is loaded
419
424
* @return {Boolean }
@@ -448,7 +453,6 @@ class Layer extends JSONAble(Eventable(Renderable(Class))) {
448
453
this . setZIndex ( zIndex ) ;
449
454
}
450
455
this . _switchEvents ( 'on' , this ) ;
451
- this . _initRenderer ( ) ;
452
456
453
457
this . onAdd ( ) ;
454
458
You can’t perform that action at this time.
0 commit comments