163 references to Right
System.Windows.Forms (26)
System\Windows\Forms\Control.cs (5)
2550
buttons |= MouseButtons.
Right
;
11538
if (button == MouseButtons.
Right
)
12423
WmMouseDown(ref m, MouseButtons.
Right
, 2);
12432
WmMouseDown(ref m, MouseButtons.
Right
, 1);
12436
WmMouseUp(ref m, MouseButtons.
Right
, 1);
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (3)
1627
OnMouseDown(new MouseEventArgs(MouseButtons.
Right
, 1, Ptrc.X, Ptrc.Y, 0));
1703
OnMouseDown(new MouseEventArgs(MouseButtons.
Right
, 1, Pt.X, Pt.Y, 0));
1723
OnMouseUp(new MouseEventArgs(MouseButtons.
Right
, 1, ptRBtnUp.X, ptRBtnUp.Y, 0));
System\Windows\Forms\Controls\ListView\ListView.cs (5)
6518
OnItemDrag(new ItemDragEventArgs(MouseButtons.
Right
, item));
6645
MouseButtons button = nmhdr->code == PInvoke.NM_CLICK ? MouseButtons.Left : MouseButtons.
Right
;
7004
WmMouseDown(ref m, MouseButtons.
Right
, 2);
7007
WmMouseDown(ref m, MouseButtons.
Right
, 1);
7008
_downButton = MouseButtons.
Right
;
System\Windows\Forms\Controls\RichTextBox\RichTextBox.OleCallback.cs (2)
102
if ((mouseButtons & MouseButtons.
Right
) == MouseButtons.
Right
)
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (1)
2581
if (e.Button == MouseButtons.Left || (e.Button == MouseButtons.
Right
&& _state[s_stateSupportsRightClick]))
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (1)
872
(e.Button == MouseButtons.
Right
&& SupportsRightClick))
System\Windows\Forms\Controls\TreeView\TreeView.cs (5)
3017
TvnBeginDrag(MouseButtons.
Right
, nmtv);
3037
button = nmtv->hdr.code == PInvoke.NM_CLICK ? MouseButtons.Left : MouseButtons.
Right
;
3372
WmMouseDown(ref m, MouseButtons.
Right
, 2);
3395
WmMouseDown(ref m, MouseButtons.
Right
, 1);
3396
_downButton = MouseButtons.
Right
;
System\Windows\Forms\Controls\WebBrowser\HtmlElementEventArgs.cs (1)
37
buttons |= MouseButtons.
Right
;
System\Windows\Forms\NotifyIcon.cs (3)
756
WmMouseDown(MouseButtons.
Right
, 2);
759
WmMouseDown(MouseButtons.
Right
, 1);
767
WmMouseUp(MouseButtons.
Right
);
System.Windows.Forms.Design (13)
System\Drawing\Design\ColorEditor.ColorPalette.cs (1)
347
else if (me.Button == MouseButtons.
Right
)
System\Windows\Forms\Design\Behavior\BehaviorService.AdornerWindow.cs (3)
358
if (_behaviorService.OnMouseDown(MouseButtons.
Right
, mouseLoc))
382
if (_behaviorService.OnMouseUp(MouseButtons.
Right
))
406
if (_behaviorService.OnMouseDoubleClick(MouseButtons.
Right
, mouseLoc))
System\Windows\Forms\Design\ControlDesigner.cs (5)
1849
? MouseButtons.
Right
1872
? MouseButtons.
Right
1927
else if (button == MouseButtons.
Right
)
1948
button = MouseButtons.
Right
;
1995
? MouseButtons.
Right
System\Windows\Forms\Design\SelectionUIService.cs (1)
735
if (me.Button == MouseButtons.
Right
&& oldContainerDrag is not null && !oldDragMoved)
System\Windows\Forms\Design\ToolStripItemBehavior.cs (1)
457
if (glyph is not null && button == MouseButtons.
Right
)
System\Windows\Forms\Design\ToolStripTemplateNode.cs (2)
461
if (e.Button == MouseButtons.
Right
)
1152
if (e.Button == MouseButtons.
Right
)
System.Windows.Forms.Tests (118)
System\Windows\Forms\ButtonBaseTests.cs (44)
6098
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0) };
6100
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0) };
6102
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0) };
6104
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0) };
6147
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0), 0 };
6149
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0), 0 };
6151
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0), 0 };
6153
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0), 0 };
6511
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0) };
6513
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0) };
6515
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0) };
6517
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0) };
6518
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, -1, 0, 0) };
6519
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, -1, 0) };
6625
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0), 0 };
6627
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0), 0 };
6629
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0), 0 };
6631
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0), 0 };
6632
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, -1, 0, 0), 0 };
6633
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, -1, 0), 0 };
6689
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0), 0 };
6691
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0), 0 };
6693
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0), 0 };
6695
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0), 0 };
6696
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, -1, 0, 0), 1 };
6697
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, -1, 0), 1 };
6698
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, -1, -1, 0), 1 };
6699
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, int.MaxValue, int.MaxValue, 0), 1 };
6756
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0), 1 };
6758
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0), 1 };
6760
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0), 1 };
6762
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0), 1 };
6763
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, -1, 0, 0), 0 };
6764
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, -1, 0), 0 };
6765
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, -1, -1, 0), 0 };
6766
yield return new object[] { flatStyle, enabled, new MouseEventArgs(MouseButtons.
Right
, 3, int.MaxValue, int.MaxValue, 0), 0 };
6831
yield return new object[] { flatStyle, new MouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4) };
6835
yield return new object[] { flatStyle, new HandledMouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4) };
8840
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONUP, IntPtr.Zero, IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, 0, 0 };
8841
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONUP, PARAM.FromLowHigh(1, 2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, 1, 2 };
8842
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONUP, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, -1, -2 };
8843
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONUP, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, 0, 0 };
8844
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONUP, PARAM.FromLowHigh(1, 2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, 1, 2 };
8845
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONUP, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, -1, -2 };
System\Windows\Forms\ButtonTests.cs (14)
2252
yield return new object[] { enabled, new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0) };
2254
yield return new object[] { enabled, new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0) };
2256
yield return new object[] { enabled, new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0) };
2258
yield return new object[] { enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0) };
2297
yield return new object[] { enabled, new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0), 0 };
2299
yield return new object[] { enabled, new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0), 0 };
2301
yield return new object[] { enabled, new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0), 0 };
2303
yield return new object[] { enabled, new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0), 0 };
2646
yield return new object[] { flatStyle, new MouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4) };
2650
yield return new object[] { flatStyle, new HandledMouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4) };
2698
yield return new object[] { flatStyle, new MouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4), false };
2702
yield return new object[] { flatStyle, new HandledMouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4), false };
2802
yield return new object[] { flatStyle, new MouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4), 0 };
2806
yield return new object[] { flatStyle, new HandledMouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4), 0 };
System\Windows\Forms\ControlTests.Methods.cs (18)
13407
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDOWN, IntPtr.Zero, IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, 0, 0 };
13408
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDOWN, PARAM.FromLowHigh(1, 2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, 1, 2 };
13409
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDOWN, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, -1, -2 };
13410
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDOWN, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, 0, 0 };
13411
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDOWN, PARAM.FromLowHigh(1, 2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, 1, 2 };
13412
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDOWN, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, -1, -2 };
13414
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDBLCLK, IntPtr.Zero, IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 2, 0, 0 };
13415
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDBLCLK, PARAM.FromLowHigh(1, 2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 2, 1, 2 };
13416
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDBLCLK, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 2, -1, -2 };
13417
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDBLCLK, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 2, 0, 0 };
13418
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDBLCLK, PARAM.FromLowHigh(1, 2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 2, 1, 2 };
13419
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDBLCLK, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 2, -1, -2 };
13770
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONUP, IntPtr.Zero, IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, 0, 0 };
13771
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONUP, PARAM.FromLowHigh(1, 2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, 1, 2 };
13772
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONUP, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, -1, -2 };
13773
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONUP, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, 0, 0 };
13774
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONUP, PARAM.FromLowHigh(1, 2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, 1, 2 };
13775
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONUP, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, -1, -2 };
System\Windows\Forms\ControlTests.Properties.cs (2)
9263
[InlineData(0, 0, byte.MaxValue, 0, 0, MouseButtons.
Right
)]
9266
[InlineData(byte.MaxValue, byte.MaxValue, byte.MaxValue, byte.MaxValue, byte.MaxValue, MouseButtons.Left | MouseButtons.Middle | MouseButtons.
Right
| MouseButtons.XButton1 | MouseButtons.XButton2)]
System\Windows\Forms\PropertyGridTests.cs (8)
3703
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0), false };
3705
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0), false };
3707
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0), false };
3709
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0), false };
3804
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0) };
3806
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0) };
3808
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0) };
3810
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0) };
System\Windows\Forms\RadioButtonTests.cs (6)
1051
yield return new object[] { flatStyle, new MouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4) };
1055
yield return new object[] { flatStyle, new HandledMouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4) };
1104
yield return new object[] { flatStyle, new MouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4), false };
1108
yield return new object[] { flatStyle, new HandledMouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4), false };
1207
yield return new object[] { flatStyle, new MouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4) };
1211
yield return new object[] { flatStyle, new HandledMouseEventArgs(MouseButtons.
Right
, 1, 2, 3, 4) };
System\Windows\Forms\TreeViewTests.cs (2)
5701
yield return new object[] { new ItemDragEventArgs(MouseButtons.
Right
, new object()) };
6418
yield return new object[] { new TreeNodeMouseClickEventArgs(new TreeNode(), MouseButtons.
Right
, 1, 2, 3) };
System\Windows\Forms\UpDownBaseTests.cs (4)
2004
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0) };
2006
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0) };
2008
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0) };
2010
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0) };
TextBoxBaseTests.cs (16)
5587
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0) };
5589
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0) };
5591
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0) };
5593
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0) };
7195
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDOWN, IntPtr.Zero, IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, 0, 0 };
7196
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDOWN, PARAM.FromLowHigh(1, 2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, 1, 2 };
7197
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDOWN, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 1, -1, -2 };
7198
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDOWN, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, 0, 0 };
7199
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDOWN, PARAM.FromLowHigh(1, 2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, 1, 2 };
7200
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDOWN, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 1, -1, -2 };
7202
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDBLCLK, IntPtr.Zero, IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 2, 0, 0 };
7203
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDBLCLK, PARAM.FromLowHigh(1, 2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 2, 1, 2 };
7204
yield return new object[] { true, (int)PInvokeCore.WM_RBUTTONDBLCLK, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, (IntPtr)250, MouseButtons.
Right
, 2, -1, -2 };
7205
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDBLCLK, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 2, 0, 0 };
7206
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDBLCLK, PARAM.FromLowHigh(1, 2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 2, 1, 2 };
7207
yield return new object[] { false, (int)PInvokeCore.WM_RBUTTONDBLCLK, PARAM.FromLowHigh(-1, -2), IntPtr.Zero, IntPtr.Zero, MouseButtons.
Right
, 2, -1, -2 };
TrackBarTests.cs (4)
2542
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 0, 0, 0, 0) };
2544
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 1, 0, 0, 0) };
2546
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 2, 0, 0, 0) };
2548
yield return new object[] { new MouseEventArgs(MouseButtons.
Right
, 3, 0, 0, 0) };
System.Windows.Forms.UI.IntegrationTests (6)
Input\InputBuilder.cs (2)
87
MouseButtons.
Right
=> MOUSE_EVENT_FLAGS.MOUSEEVENTF_RIGHTDOWN,
109
MouseButtons.
Right
=> MOUSE_EVENT_FLAGS.MOUSEEVENTF_RIGHTUP,
Input\MouseSimulator.cs (4)
63
return ButtonDown(MouseButtons.
Right
);
68
return ButtonUp(MouseButtons.
Right
);
73
return ButtonClick(MouseButtons.
Right
);
78
return ButtonDoubleClick(MouseButtons.
Right
);