mirror of
https://github.com/motajs/template.git
synced 2026-11-19 10:44:30 +08:00
fix(08-05): expose MapTileBase.restoreDefaultEvents and use it in toStatic
- MapTileBase.restoreDefaultEvents: protected -> public; declare on ITileBase with jsDoc
- MapLayer.toStatic(keepEvent=false): reset reused static tile via restoreDefaultEvents() instead of loadState({})
This commit is contained in:
1 parent
0d41abdaf6
commit
58def1809d
3 files changed
+7
-2
No files matched your search
@@ -43,7 +43,7 @@ export abstract class MapTileBase<TSave extends IMapBlockSaveBase>
|
||||
/**
|
||||
* 根据当前图块原始数据恢复默认事件并建立干净基准
|
||||
*/
|
||||
protected restoreDefaultEvents(): void {
|
||||
restoreDefaultEvents(): void {
|
||||
const eventView = this.tileEvent();
|
||||
eventView.clear();
|
||||
const data = this.raw();
|
||||
|
||||
Reference in new issue
Block a user