mirror of
https://github.com/amnezia-vpn/amnezia-client.git
synced 2026-06-21 02:01:03 +07:00
6f119cd083
* fix: fixed dns processing * fix: fixed proceesed index/id selection * refactor: stop using the server index as state * fix: fixed autostart and start minimized * fix: fixed typo * fix: add socks5 extractConfigFromContainer * fix: remove unused currentContainerUpdated * fix: fixed clear cached profile order
38 lines
875 B
QML
38 lines
875 B
QML
import QtQuick
|
|
import QtGamepadLegacy
|
|
|
|
Item {
|
|
id: root
|
|
|
|
property alias gamepad: gamepad
|
|
property alias gamepadKeyNav: gamepadKeyNav
|
|
|
|
Gamepad {
|
|
id: gamepad
|
|
deviceId: GamepadManager.connectedGamepads.length > 0 ? GamepadManager.connectedGamepads[0] : -1
|
|
|
|
onButtonStartChanged: {
|
|
if (buttonStart) {
|
|
ConnectionController.connectButtonClicked()
|
|
}
|
|
}
|
|
}
|
|
|
|
GamepadKeyNavigation {
|
|
id: gamepadKeyNav
|
|
gamepad: gamepad
|
|
active: true
|
|
}
|
|
|
|
Connections {
|
|
target: GamepadManager
|
|
function onConnectedGamepadsChanged() {
|
|
if (GamepadManager.connectedGamepads.length > 0) {
|
|
gamepad.deviceId = GamepadManager.connectedGamepads[0]
|
|
} else {
|
|
gamepad.deviceId = -1
|
|
}
|
|
}
|
|
}
|
|
}
|