MouseBinding Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Initializes a new instance of the MouseBinding class.
Overloads
MouseBinding() |
Initializes a new instance of the MouseBinding class. |
MouseBinding(ICommand, MouseGesture) |
Initializes a new instance of the MouseBinding class, using the specified command and mouse gesture. |
MouseBinding()
Initializes a new instance of the MouseBinding class.
public:
MouseBinding();
public MouseBinding ();
Public Sub New ()
See also
Applies to
MouseBinding(ICommand, MouseGesture)
Initializes a new instance of the MouseBinding class, using the specified command and mouse gesture.
public:
MouseBinding(System::Windows::Input::ICommand ^ command, System::Windows::Input::MouseGesture ^ gesture);
public MouseBinding (System.Windows.Input.ICommand command, System.Windows.Input.MouseGesture gesture);
new System.Windows.Input.MouseBinding : System.Windows.Input.ICommand * System.Windows.Input.MouseGesture -> System.Windows.Input.MouseBinding
Public Sub New (command As ICommand, gesture As MouseGesture)
Parameters
- command
- ICommand
The command associated with the gesture.
- gesture
- MouseGesture
The gesture associated with the command.
Examples
The following example shows how to bind an ICommand with a MouseGesture using a MouseAction.
MouseGesture PasteCmdMouseGesture = new MouseGesture(
MouseAction.MiddleClick, ModifierKeys.Alt);
ApplicationCommands.Paste.InputGestures.Add(PasteCmdMouseGesture);
Dim PasteCmdMouseGesture As New MouseGesture(MouseAction.MiddleClick, ModifierKeys.Alt)
ApplicationCommands.Paste.InputGestures.Add(PasteCmdMouseGesture)
See also
Applies to
Обратна връзка
https://aka.ms/ContentUserFeedback.
Очаквайте скоро: През цялата 2024 г. постепенно ще отстраняваме проблемите в GitHub като механизъм за обратна връзка за съдържание и ще го заменим с нова система за обратна връзка. За повече информация вижте:Подаване и преглед на обратна връзка за