gamepad.go (3114B)
1 // Copyright 2015 Hajime Hoshi 2 // 3 // Licensed under the Apache License, Version 2.0 (the "License"); 4 // you may not use this file except in compliance with the License. 5 // You may obtain a copy of the License at 6 // 7 // http://www.apache.org/licenses/LICENSE-2.0 8 // 9 // Unless required by applicable law or agreed to in writing, software 10 // distributed under the License is distributed on an "AS IS" BASIS, 11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 // See the License for the specific language governing permissions and 13 // limitations under the License. 14 15 package ebiten 16 17 import ( 18 "github.com/hajimehoshi/ebiten/v2/internal/driver" 19 ) 20 21 // A GamepadButton represents a gamepad button. 22 type GamepadButton int 23 24 // GamepadButtons 25 const ( 26 GamepadButton0 GamepadButton = GamepadButton(driver.GamepadButton0) 27 GamepadButton1 GamepadButton = GamepadButton(driver.GamepadButton1) 28 GamepadButton2 GamepadButton = GamepadButton(driver.GamepadButton2) 29 GamepadButton3 GamepadButton = GamepadButton(driver.GamepadButton3) 30 GamepadButton4 GamepadButton = GamepadButton(driver.GamepadButton4) 31 GamepadButton5 GamepadButton = GamepadButton(driver.GamepadButton5) 32 GamepadButton6 GamepadButton = GamepadButton(driver.GamepadButton6) 33 GamepadButton7 GamepadButton = GamepadButton(driver.GamepadButton7) 34 GamepadButton8 GamepadButton = GamepadButton(driver.GamepadButton8) 35 GamepadButton9 GamepadButton = GamepadButton(driver.GamepadButton9) 36 GamepadButton10 GamepadButton = GamepadButton(driver.GamepadButton10) 37 GamepadButton11 GamepadButton = GamepadButton(driver.GamepadButton11) 38 GamepadButton12 GamepadButton = GamepadButton(driver.GamepadButton12) 39 GamepadButton13 GamepadButton = GamepadButton(driver.GamepadButton13) 40 GamepadButton14 GamepadButton = GamepadButton(driver.GamepadButton14) 41 GamepadButton15 GamepadButton = GamepadButton(driver.GamepadButton15) 42 GamepadButton16 GamepadButton = GamepadButton(driver.GamepadButton16) 43 GamepadButton17 GamepadButton = GamepadButton(driver.GamepadButton17) 44 GamepadButton18 GamepadButton = GamepadButton(driver.GamepadButton18) 45 GamepadButton19 GamepadButton = GamepadButton(driver.GamepadButton19) 46 GamepadButton20 GamepadButton = GamepadButton(driver.GamepadButton20) 47 GamepadButton21 GamepadButton = GamepadButton(driver.GamepadButton21) 48 GamepadButton22 GamepadButton = GamepadButton(driver.GamepadButton22) 49 GamepadButton23 GamepadButton = GamepadButton(driver.GamepadButton23) 50 GamepadButton24 GamepadButton = GamepadButton(driver.GamepadButton24) 51 GamepadButton25 GamepadButton = GamepadButton(driver.GamepadButton25) 52 GamepadButton26 GamepadButton = GamepadButton(driver.GamepadButton26) 53 GamepadButton27 GamepadButton = GamepadButton(driver.GamepadButton27) 54 GamepadButton28 GamepadButton = GamepadButton(driver.GamepadButton28) 55 GamepadButton29 GamepadButton = GamepadButton(driver.GamepadButton29) 56 GamepadButton30 GamepadButton = GamepadButton(driver.GamepadButton30) 57 GamepadButton31 GamepadButton = GamepadButton(driver.GamepadButton31) 58 GamepadButtonMax GamepadButton = GamepadButton31 59 )