KeyboardDevice.GetKeyStates(Key) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
取得指定 Key的關鍵狀態集合。
public:
System::Windows::Input::KeyStates GetKeyStates(System::Windows::Input::Key key);
public System.Windows.Input.KeyStates GetKeyStates(System.Windows.Input.Key key);
member this.GetKeyStates : System.Windows.Input.Key -> System.Windows.Input.KeyStates
Public Function GetKeyStates (key As Key) As KeyStates
參數
- key
- Key
關鍵是要檢查。
傳回
指定金鑰的密鑰狀態集合。
例外狀況
key 不是有效的金鑰。