docs: rebuild Input API content
This commit is contained in:
@@ -1,30 +1,26 @@
|
||||
# InputManager::GetTouchCount
|
||||
|
||||
获取相关状态或对象。
|
||||
读取当前已保存的触点数量。
|
||||
|
||||
```cpp
|
||||
int GetTouchCount() const;
|
||||
```
|
||||
|
||||
该方法声明于 `XCEngine/Input/InputManager.h`,当前页面用于固定 `InputManager` 类目录下的方法级 canonical 路径。
|
||||
## 行为说明
|
||||
|
||||
**参数:** 无。
|
||||
当前实现直接返回 `m_touches.size()`。因为现有公开代码路径没有填充触摸状态,所以在当前版本里它通常为 `0`。
|
||||
|
||||
**返回:** `int` - 返回值语义详见头文件声明。
|
||||
## 返回值
|
||||
|
||||
**示例:**
|
||||
- `int` - 当前触点数量。
|
||||
|
||||
## 示例
|
||||
|
||||
```cpp
|
||||
#include <XCEngine/Input/InputManager.h>
|
||||
|
||||
void Example() {
|
||||
XCEngine::Input::InputManager object;
|
||||
// 根据上下文补齐参数后调用 InputManager::GetTouchCount(...)。
|
||||
(void)object;
|
||||
}
|
||||
int count = XCEngine::Input::InputManager::Get().GetTouchCount();
|
||||
```
|
||||
|
||||
## 相关文档
|
||||
|
||||
- [返回类总览](InputManager.md)
|
||||
- [返回模块目录](../Input.md)
|
||||
- [返回类型总览](InputManager.md)
|
||||
- [GetTouch](GetTouch.md)
|
||||
|
||||
Reference in New Issue
Block a user