mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-10 04:57:26 +01:00
inpututil: Add comments
This commit is contained in:
parent
9d57350a42
commit
e33ca9a4c1
@ -225,6 +225,9 @@ func MouseButtonPressDuration(button ebiten.MouseButton) int {
|
|||||||
return s
|
return s
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// JustConnectedGamepadIDs returns gamepad IDs that are connected just in the current frame.
|
||||||
|
//
|
||||||
|
// JustConnectedGamepadIDs is concurrent safe.
|
||||||
func JustConnectedGamepadIDs() []int {
|
func JustConnectedGamepadIDs() []int {
|
||||||
ids := []int{}
|
ids := []int{}
|
||||||
theInputState.m.RLock()
|
theInputState.m.RLock()
|
||||||
@ -238,6 +241,9 @@ func JustConnectedGamepadIDs() []int {
|
|||||||
return ids
|
return ids
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// JustDisconnectedGamepadIDs returns gamepad IDs that are disconnected just in the current frame.
|
||||||
|
//
|
||||||
|
// JustDisconnectedGamepadIDs is concurrent safe.
|
||||||
func JustDisconnectedGamepadIDs() []int {
|
func JustDisconnectedGamepadIDs() []int {
|
||||||
ids := []int{}
|
ids := []int{}
|
||||||
theInputState.m.RLock()
|
theInputState.m.RLock()
|
||||||
|
Loading…
Reference in New Issue
Block a user