fix: improve doc link navigation and tree display
- Fix link resolution with proper relative/absolute path handling - Improve link styling with underline decoration - Hide leaf nodes from tree, only show directories - Fix log file path for packaged app
This commit is contained in:
26
docs/api/resources/resourcemanager/unloadunused.md
Normal file
26
docs/api/resources/resourcemanager/unloadunused.md
Normal file
@@ -0,0 +1,26 @@
|
||||
# ResourceManager::UnloadUnused
|
||||
|
||||
```cpp
|
||||
void UnloadUnused()
|
||||
```
|
||||
|
||||
卸载所有无引用的资源。遍历资源缓存,将引用计数为零的资源全部释放。常在场景切换或内存紧张时调用。
|
||||
|
||||
**参数:** 无
|
||||
|
||||
**返回:** 无
|
||||
|
||||
**复杂度:** O(n)
|
||||
|
||||
**示例:**
|
||||
|
||||
```cpp
|
||||
// 切换场景时清理无用资源
|
||||
void OnSceneUnload() {
|
||||
ResourceManager::Get().UnloadUnused();
|
||||
}
|
||||
```
|
||||
|
||||
## 相关文档
|
||||
|
||||
- [ResourceManager 总览](resourcemanager.md) - 返回类总览
|
||||
Reference in New Issue
Block a user