共用方式為


Gamepad.GetButtonLabel(GamepadButtons) 方法

定義

擷取指定按鈕的按鈕標籤。

public:
 virtual GameControllerButtonLabel GetButtonLabel(GamepadButtons button) = GetButtonLabel;
GameControllerButtonLabel GetButtonLabel(GamepadButtons const& button);
public GameControllerButtonLabel GetButtonLabel(GamepadButtons button);
function getButtonLabel(button)
Public Function GetButtonLabel (button As GamepadButtons) As GameControllerButtonLabel

參數

button
GamepadButtons

要擷取標籤的按鈕。

傳回

指定按鈕的標籤。 如果按鈕標籤是空白的,或控制器的按鈕沒有已知的標籤,則會傳回 None

Windows 需求

裝置系列
Windows 10 Anniversary Edition (已於 10.0.14393.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v3.0 引進)

適用於

另請參閱