@ives_xxz/framework 2.0.6 → 2.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -381,8 +381,8 @@ export class FWAssetManager extends FWManager implements FW.AssetManager {
|
|
|
381
381
|
assetData.refCount--;
|
|
382
382
|
|
|
383
383
|
if (assetData.refCount <= 0) {
|
|
384
|
+
this.resMgr.getBundle(bundleName)?.release(path);
|
|
384
385
|
this.assetsMap.delete(key);
|
|
385
|
-
autoRelease && this.resMgr.getBundle(bundleName)?.release(path);
|
|
386
386
|
}
|
|
387
387
|
}
|
|
388
388
|
|
|
@@ -421,6 +421,9 @@ export class FWAssetManager extends FWManager implements FW.AssetManager {
|
|
|
421
421
|
}
|
|
422
422
|
|
|
423
423
|
public onDestroy(): void {
|
|
424
|
+
this.assetsMap.forEach((v) => {
|
|
425
|
+
this.release(v.assetProperty);
|
|
426
|
+
});
|
|
424
427
|
this.assetsMap.clear();
|
|
425
428
|
}
|
|
426
429
|
}
|
package/manager/FWResManager.ts
CHANGED