CommandManager.RegisterClassInputBinding(Type, InputBinding) 方法

定義

以指定的型別註冊指定的 InputBindingRegisters the specified InputBinding with the specified type.

public:
 static void RegisterClassInputBinding(Type ^ type, System::Windows::Input::InputBinding ^ inputBinding);
public static void RegisterClassInputBinding (Type type, System.Windows.Input.InputBinding inputBinding);
static member RegisterClassInputBinding : Type * System.Windows.Input.InputBinding -> unit
Public Shared Sub RegisterClassInputBinding (type As Type, inputBinding As InputBinding)

參數

type
Type

註冊 inputBinding 所使用的型別。The type to register inputBinding with.

inputBinding
InputBinding

要註冊的輸入繫結。The input binding to register.

例外狀況

typeinputBindingnulltype or inputBinding is null.

備註

這個方法可讓 InputBinding 與型別相關聯,而不是類別的實例。This method enables an InputBinding to be associated with a type instead of an instance of a class.

適用於