1822 references to Keys
System.Web.Mobile (10)
UI\MobileControls\Design\StylesEditorDialog.cs (5)
902
case
Keys
.F2:
910
case (
Keys
.Control |
Keys
.Home):
918
case (
Keys
.Control |
Keys
.End):
UI\MobileControls\Design\Util\EditableTreeList.cs (5)
234
case
Keys
.F2:
243
case (
Keys
.Control |
Keys
.Home):
251
case (
Keys
.Control |
Keys
.End):
System.Windows.Forms (1722)
winforms\Managed\System\WinForms\AxHost.cs (1)
1997
protected override bool ProcessDialogKey(
Keys
keyData)
winforms\Managed\System\WinForms\BindingNavigator.cs (2)
704
case
Keys
.Enter:
707
case
Keys
.Escape:
winforms\Managed\System\WinForms\ButtonBase.cs (3)
1072
if (kevent.KeyData ==
Keys
.Space) {
1111
if (kevent.KeyCode ==
Keys
.Enter || kevent.KeyCode ==
Keys
.Space) {
winforms\Managed\System\WinForms\CheckedListBox.cs (9)
1057
switch ((
Keys
)keycode) {
1058
case
Keys
.Up:
1059
case
Keys
.Down:
1060
case
Keys
.PageUp:
1061
case
Keys
.PageDown:
1062
case
Keys
.Home:
1063
case
Keys
.End:
1064
case
Keys
.Left:
1065
case
Keys
.Right:
winforms\Managed\System\WinForms\ComboBox.cs (20)
1666
if (keyChar == (char)(int)
Keys
.Escape) {
1669
else if (keyChar == (char)(int)
Keys
.Return && this.DroppedDown) {
2224
Debug.Assert((ModifierKeys &
Keys
.Alt) == 0);
2226
if ((
Keys
)unchecked( (int) (long)m.WParam) ==
Keys
.Delete) {
2237
Debug.Assert((ModifierKeys &
Keys
.Alt) == 0);
2239
if (keyChar == (char)
Keys
.Back) {
2256
else if (keyChar == (char)
Keys
.Escape) {
2261
if (keyChar != (char)
Keys
.Escape && keyChar != (char)
Keys
.Return && !DroppedDown
2308
protected override bool IsInputKey(
Keys
keyData) {
2310
Keys
keyCode = keyData & (
Keys
.KeyCode |
Keys
.Alt);
2311
if (keyCode ==
Keys
.Return || keyCode ==
Keys
.Escape) {
2579
if (e.KeyCode ==
Keys
.Return) {
2583
else if ((e.KeyCode ==
Keys
.Escape) && autoCompleteDroppedDown) {
2605
if (!e.Handled && (e.KeyChar == (char)(int)
Keys
.Return || e.KeyChar == (char)(int)
Keys
.Escape)
winforms\Managed\System\WinForms\ContainerControl.cs (17)
1184
protected override bool ProcessDialogKey(
Keys
keyData) {
1188
if ((keyData & (
Keys
.Alt |
Keys
.Control)) ==
Keys
.None) {
1189
Keys
keyCode = (
Keys
)keyData &
Keys
.KeyCode;
1191
case
Keys
.Tab:
1192
if (ProcessTabKey((keyData &
Keys
.Shift) ==
Keys
.None)) return true;
1194
case
Keys
.Left:
1195
case
Keys
.Right:
1196
case
Keys
.Up:
1197
case
Keys
.Down:
1198
if (ProcessArrowKey(keyCode ==
Keys
.Right ||
1199
keyCode ==
Keys
.Down)) return true;
1212
protected override bool ProcessCmdKey(ref Message msg,
Keys
keyData) {
winforms\Managed\System\WinForms\ContextMenu.cs (1)
172
protected internal virtual bool ProcessCmdKey(ref Message msg,
Keys
keyData, Control control) {
winforms\Managed\System\WinForms\Control.cs (64)
3338
public static
Keys
ModifierKeys {
3340
Keys
modifiers = 0;
3343
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.ShiftKey) < 0) modifiers |=
Keys
.Shift;
3344
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.ControlKey) < 0) modifiers |=
Keys
.Control;
3345
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.Menu) < 0) modifiers |=
Keys
.Alt;
3360
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.LButton) < 0) buttons |= MouseButtons.Left;
3361
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.RButton) < 0) buttons |= MouseButtons.Right;
3362
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.MButton) < 0) buttons |= MouseButtons.Middle;
3363
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.XButton1) < 0) buttons |= MouseButtons.XButton1;
3364
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.XButton2) < 0) buttons |= MouseButtons.XButton2;
7571
public static bool IsKeyLocked(
Keys
keyVal) {
7572
if (keyVal ==
Keys
.Insert || keyVal ==
Keys
.NumLock || keyVal ==
Keys
.CapsLock || keyVal ==
Keys
.Scroll) {
7582
if( keyVal ==
Keys
.Insert || keyVal ==
Keys
.CapsLock )
7616
if (charCode == (char)(int)
Keys
.Tab) {
7641
protected virtual bool IsInputKey(
Keys
keyData) {
7644
if ((keyData &
Keys
.Alt) ==
Keys
.Alt) return false;
7646
switch (keyData &
Keys
.KeyCode) {
7647
case
Keys
.Tab:
7650
case
Keys
.Left:
7651
case
Keys
.Right:
7652
case
Keys
.Up:
7653
case
Keys
.Down:
10162
Keys
keyData = (
Keys
)(unchecked((int)(long)msg.WParam) | (int)ModifierKeys);
10244
Keys
keyData = (
Keys
)(unchecked((int)(long)msg.WParam) | (int)ModifierKeys);
10323
protected virtual bool ProcessCmdKey(ref Message msg,
Keys
keyData) {
10481
protected virtual bool ProcessDialogKey(
Keys
keyData) {
10647
ke = new KeyEventArgs((
Keys
)(unchecked((int)(long)m.WParam)) | ModifierKeys);
10770
Keys
keyCode = (
Keys
)((int)msg.WParam) &
Keys
.KeyCode;
10772
if (keyCode !=
Keys
.F10 && keyCode !=
Keys
.Menu && keyCode !=
Keys
.Tab) {
10793
if (keyCode ==
Keys
.F10 || keyCode ==
Keys
.Menu) {
10800
if (keyCode ==
Keys
.Tab) {
14411
Keys
keyState =
Keys
.None;
14412
keyState |= (
Keys
)((UnsafeNativeMethods.GetKeyState((int)
Keys
.ControlKey) < 0) ? NativeMethods.MK_CONTROL : 0);
14413
keyState |= (
Keys
)((UnsafeNativeMethods.GetKeyState((int)
Keys
.ShiftKey) < 0) ? NativeMethods.MK_SHIFT : 0);
15282
if (IsInputKey(
Keys
.Return)) {
15285
if (IsInputKey(
Keys
.Escape)) {
16206
private static bool IsKeyDown(
Keys
key) {
16215
return IsKeyDown(
Keys
.Tab)
16216
|| IsKeyDown(
Keys
.Up)
16217
|| IsKeyDown(
Keys
.Down)
16218
|| IsKeyDown(
Keys
.Left)
16219
|| IsKeyDown(
Keys
.Right)
16221
|| IsKeyDown(
Keys
.Menu)
16222
|| IsKeyDown(
Keys
.F10)
16223
|| IsKeyDown(
Keys
.Escape);
16599
target.SelectNextControl(null, Control.ModifierKeys !=
Keys
.Shift, true, true, true);
winforms\Managed\System\WinForms\DataGrid.cs (102)
3996
Debug.WriteLineIf(CompModSwitches.DataGridKeys.TraceVerbose, "DataGridKeys: OnKeyPress " + TypeDescriptor.GetConverter(typeof(
Keys
)).ConvertToString(kpe.KeyChar));
4021
Keys
nModifier = ModifierKeys;
4022
bool isControlDown = (nModifier &
Keys
.Control) ==
Keys
.Control && (nModifier &
Keys
.Alt) == 0;
4023
bool isShiftDown = (nModifier &
Keys
.Shift) ==
Keys
.Shift;
4263
&& !(((Control.ModifierKeys &
Keys
.Control) ==
Keys
.Control) && (Control.ModifierKeys &
Keys
.Alt) == 0)){
4366
if ((ModifierKeys &
Keys
.Control) != 0)
7472
protected override bool ProcessDialogKey(
Keys
keyData) {
7473
Debug.WriteLineIf(CompModSwitches.DataGridKeys.TraceVerbose, "DataGridKeys: ProcessDialogKey " + TypeDescriptor.GetConverter(typeof(
Keys
)).ConvertToString(keyData));
7480
switch (keyData &
Keys
.KeyCode) {
7481
case
Keys
.Tab:
7482
case
Keys
.Up:
7483
case
Keys
.Down:
7484
case
Keys
.Left:
7485
case
Keys
.Right:
7486
case
Keys
.Next:
7487
case
Keys
.Prior:
7488
case
Keys
.Enter:
7489
case
Keys
.Escape:
7490
case
Keys
.Oemplus:
7491
case
Keys
.Add:
7492
case
Keys
.OemMinus:
7493
case
Keys
.Subtract:
7494
case
Keys
.Space:
7495
case
Keys
.Delete:
7496
case
Keys
.A:
7502
case
Keys
.C:
7503
if ((keyData &
Keys
.Control) != 0 && (keyData &
Keys
.Alt) == 0)
7658
Debug.WriteLineIf(CompModSwitches.DataGridKeys.TraceVerbose, "DataGridKeys: ProcessGridKey "+ TypeDescriptor.GetConverter(typeof(
Keys
)).ConvertToString(ke.KeyCode));
7669
case
Keys
.Left:
7670
biDiKe = new KeyEventArgs((
Keys
.Right | ke.Modifiers));
7672
case
Keys
.Right:
7673
biDiKe = new KeyEventArgs((
Keys
.Left | ke.Modifiers));
7698
case
Keys
.Tab:
7700
case
Keys
.Up:
7778
case
Keys
.Down:
7861
case
Keys
.OemMinus:
7862
case
Keys
.Subtract:
7870
case
Keys
.Oemplus:
7871
case
Keys
.Add:
7882
case
Keys
.Space:
7899
case
Keys
.Next:
7933
case
Keys
.Prior:
7968
case
Keys
.Left:
7971
if ((biDiKe.Modifiers &
Keys
.Modifiers) ==
Keys
.Alt)
7978
if ((biDiKe.Modifiers &
Keys
.Control) ==
Keys
.Control)
8007
case
Keys
.Right:
8010
if ((biDiKe.Modifiers &
Keys
.Control) ==
Keys
.Control && !biDiKe.Alt)
8036
case
Keys
.F2:
8047
case
Keys
.Home:
8076
case
Keys
.Delete:
8099
case
Keys
.End:
8131
case
Keys
.Enter:
8140
if ((biDiKe.Modifiers &
Keys
.Control) != 0 && !biDiKe.Alt)
8157
case
Keys
.A:
8172
case
Keys
.Escape:
8211
KeyEventArgs ke = new KeyEventArgs((
Keys
)(unchecked((int)(long)m.WParam)) | ModifierKeys);
8213
case
Keys
.Up:
8214
case
Keys
.Down:
8215
case
Keys
.Prior:
8216
case
Keys
.Next:
8217
case
Keys
.Right:
8218
case
Keys
.Left:
8219
case
Keys
.Tab:
8220
case
Keys
.Escape:
8221
case
Keys
.Enter:
8222
case
Keys
.OemMinus:
8223
case
Keys
.Subtract:
8224
case
Keys
.Oemplus:
8225
case
Keys
.Add:
8226
case
Keys
.Space:
8227
case
Keys
.Home:
8228
case
Keys
.End:
8229
case
Keys
.F2:
8230
case
Keys
.Delete:
8231
case
Keys
.A:
8237
KeyEventArgs ke = new KeyEventArgs((
Keys
)(unchecked((int)(long)m.WParam)) | ModifierKeys);
8238
if (ke.KeyCode ==
Keys
.Tab)
8252
protected bool ProcessTabKey(
Keys
keyData) {
8270
if ((keyData &
Keys
.Control) ==
Keys
.Control)
8273
if ((keyData &
Keys
.Alt) ==
Keys
.Alt)
8277
Keys
ke = keyData & ~(
Keys
.Control);
8346
if (gridState[GRIDSTATE_childLinkFocused] || (!gridState[GRIDSTATE_childLinkFocused] && (keyData &
Keys
.Shift) !=
Keys
.Shift)) {
8362
if ((this.currentRow == this.DataGridRowsLength -1) && ((keyData &
Keys
.Shift) == 0)) {
8389
if (CurrentRow != 0 && (keyData &
Keys
.Shift) ==
Keys
.Shift)
8418
if (this.currentRow == 0 && ((keyData &
Keys
.Shift) ==
Keys
.Shift)) {
8439
if ((keyData &
Keys
.Shift) !=
Keys
.Shift) {
winforms\Managed\System\WinForms\DataGridAddNewRow.cs (1)
70
internal override bool ProcessTabKey(
Keys
keyData, Rectangle rowHeaders, bool alignToRight)
winforms\Managed\System\WinForms\DataGridBoolColumn.cs (3)
308
internal override bool KeyPress(int rowNum,
Keys
keyData) {
310
if ((keyData &
Keys
.KeyCode) ==
Keys
.Space) {
winforms\Managed\System\WinForms\DataGridColumn.cs (5)
1043
internal virtual bool KeyPress(int rowNum,
Keys
keyData) {
1047
if (keyData == (
Keys
.Control |
Keys
.NumPad0) || keyData == (
Keys
.Control|
Keys
.D0)) {
winforms\Managed\System\WinForms\DataGridRelationshipRow.cs (17)
384
public override bool OnKeyPress(
Keys
keyData) {
386
if ((keyData &
Keys
.Modifiers) ==
Keys
.Shift && (keyData &
Keys
.KeyCode) !=
Keys
.Tab)
389
switch (keyData &
Keys
.KeyCode) {
390
case
Keys
.F5:
402
case
Keys
.NumLock:
407
case
Keys
.Enter:
420
case
Keys
.Tab:
453
internal override bool ProcessTabKey(
Keys
keyData, Rectangle rowHeaders, bool alignToRight) {
454
Debug.Assert((keyData &
Keys
.Control) !=
Keys
.Control, "the DataGridRelationshipRow only handles TAB and TAB-SHIFT");
455
Debug.Assert((keyData &
Keys
.Alt) !=
Keys
.Alt, "the DataGridRelationshipRow only handles TAB and TAB-SHIFT");
466
if ((keyData &
Keys
.Shift) ==
Keys
.Shift) {
winforms\Managed\System\WinForms\DataGridRow.cs (2)
337
public virtual bool OnKeyPress(
Keys
keyData) {
410
internal abstract bool ProcessTabKey(
Keys
keyData, Rectangle rowHeaders, bool alignToRight);
winforms\Managed\System\WinForms\DataGridTextBox.cs (38)
79
if (e.KeyChar == ' ' && (Control.ModifierKeys &
Keys
.Shift) ==
Keys
.Shift)
88
if ((Control.ModifierKeys &
Keys
.Control) ==
Keys
.Control && ((Control.ModifierKeys &
Keys
.Alt) == 0))
103
Keys
key = (
Keys
)unchecked((int)(long)m.WParam);
104
Keys
modifierKeys = ModifierKeys;
106
if ((key | modifierKeys) ==
Keys
.Enter || (key | modifierKeys) ==
Keys
.Escape || ((key | modifierKeys) == (
Keys
.Enter |
Keys
.Control))
118
if (key ==
Keys
.LineFeed) // eat the LineFeed we get when the user presses Ctrl-Enter in a gridTextBox
129
Keys
keyData = key &
Keys
.KeyCode;
133
case
Keys
.Right:
142
case
Keys
.Left:
152
case
Keys
.Down:
161
case
Keys
.Up:
169
case
Keys
.Home:
170
case
Keys
.End:
175
case
Keys
.Prior:
176
case
Keys
.Next:
177
case
Keys
.Oemplus:
178
case
Keys
.Add:
179
case
Keys
.OemMinus:
180
case
Keys
.Subtract:
191
case
Keys
.Space:
192
if (IsInEditOrNavigateMode && (Control.ModifierKeys &
Keys
.Shift) ==
Keys
.Shift)
202
case
Keys
.A:
203
if (IsInEditOrNavigateMode && (Control.ModifierKeys &
Keys
.Control) ==
Keys
.Control)
213
case
Keys
.F2:
219
case
Keys
.Delete:
237
case
Keys
.Tab:
240
if ((ModifierKeys &
Keys
.Control) ==
Keys
.Control)
winforms\Managed\System\WinForms\DataGridTextBoxColumn.cs (1)
125
internal override bool KeyPress(int rowNum,
Keys
keyData) {
winforms\Managed\System\WinForms\DataGridViewButtonCell.cs (4)
473
return e.KeyCode ==
Keys
.Space && !e.Alt && !e.Control && !e.Shift;
479
return e.KeyCode ==
Keys
.Space;
513
if (e.KeyCode ==
Keys
.Space && !e.Alt && !e.Control && !e.Shift)
527
if (e.KeyCode ==
Keys
.Space)
winforms\Managed\System\WinForms\DataGridViewCell.cs (3)
1641
sb.Append((char)
Keys
.Return);
1642
sb.Append((char)
Keys
.LineFeed);
1647
sb.Append(csv ? ',' : (char)
Keys
.Tab);
winforms\Managed\System\WinForms\DataGridViewCheckBoxCell.cs (4)
868
return e.KeyCode ==
Keys
.Space && !e.Alt && !e.Control && !e.Shift;
874
return e.KeyCode ==
Keys
.Space;
944
if (e.KeyCode ==
Keys
.Space && !e.Alt && !e.Control && !e.Shift)
958
if (e.KeyCode ==
Keys
.Space)
winforms\Managed\System\WinForms\DataGridViewColumnHeaderCell.cs (3)
211
sb.Append((char)
Keys
.Return);
212
sb.Append((char)
Keys
.LineFeed);
217
sb.Append(csv ? ',' : (char)
Keys
.Tab);
winforms\Managed\System\WinForms\DataGridViewComboBoxCell.cs (12)
1758
if (((char.IsLetterOrDigit((char)e.KeyCode) && !(e.KeyCode >=
Keys
.F1 && e.KeyCode <=
Keys
.F24)) ||
1759
(e.KeyCode >=
Keys
.NumPad0 && e.KeyCode <=
Keys
.Divide) ||
1760
(e.KeyCode >=
Keys
.OemSemicolon && e.KeyCode <=
Keys
.Oem102) ||
1761
(e.KeyCode ==
Keys
.Space && !e.Shift) ||
1762
(e.KeyCode ==
Keys
.F4) ||
1763
((e.KeyCode ==
Keys
.Down || e.KeyCode ==
Keys
.Up) && e.Alt)) &&
1764
(!e.Alt || (e.KeyCode ==
Keys
.Down || e.KeyCode ==
Keys
.Up)) &&
winforms\Managed\System\WinForms\DataGridViewComboBoxEditingControl.cs (9)
147
public virtual bool EditingControlWantsInputKey(
Keys
keyData, bool dataGridViewWantsInputKey)
149
if ((keyData &
Keys
.KeyCode) ==
Keys
.Down ||
150
(keyData &
Keys
.KeyCode) ==
Keys
.Up ||
151
(this.DroppedDown && ((keyData &
Keys
.KeyCode) ==
Keys
.Escape) || (keyData &
Keys
.KeyCode) ==
Keys
.Enter))
winforms\Managed\System\WinForms\DataGridViewEditingControl.cs (1)
62
bool EditingControlWantsInputKey(
Keys
keyData, bool dataGridViewWantsInputKey);
winforms\Managed\System\WinForms\DataGridViewLinkCell.cs (2)
779
if (e.KeyCode ==
Keys
.Space && !e.Alt && !e.Control && !e.Shift)
834
if (e.KeyCode ==
Keys
.Space && !e.Alt && !e.Control && !e.Shift)
winforms\Managed\System\WinForms\DataGridViewMethods.cs (332)
10242
protected override bool IsInputKey(
Keys
keyData)
10244
if ((keyData &
Keys
.Alt) ==
Keys
.Alt)
10248
switch (keyData &
Keys
.KeyCode)
10250
case
Keys
.Escape:
10255
case
Keys
.Tab:
10257
return GetTabKeyEffective((keyData &
Keys
.Shift) ==
Keys
.Shift, (keyData &
Keys
.Control) ==
Keys
.Control);
10260
case
Keys
.A:
10262
if ((keyData & (
Keys
.Control |
Keys
.Shift |
Keys
.Alt)) ==
Keys
.Control)
10269
case
Keys
.C:
10270
case
Keys
.Insert:
10272
if ((keyData & (
Keys
.Control |
Keys
.Shift |
Keys
.Alt)) ==
Keys
.Control)
10279
case
Keys
.Space:
10281
if ((keyData & (
Keys
.Control |
Keys
.Shift |
Keys
.Alt)) ==
Keys
.Shift &&
10291
case
Keys
.Up:
10292
case
Keys
.Down:
10293
case
Keys
.Left:
10294
case
Keys
.Right:
10295
case
Keys
.Home:
10296
case
Keys
.End:
10297
case
Keys
.Next:
10298
case
Keys
.Prior:
10299
case
Keys
.Enter:
10300
case
Keys
.Delete:
10301
case
Keys
.D0:
10302
case
Keys
.NumPad0:
10303
case
Keys
.F2:
10304
case
Keys
.F3:
12271
Keys
nModifier = ModifierKeys;
12272
bool isControlDown = (nModifier &
Keys
.Control) ==
Keys
.Control && (nModifier &
Keys
.Alt) == 0;
12273
bool isShiftDown = (nModifier &
Keys
.Shift) ==
Keys
.Shift;
12274
bool isAltDown = (nModifier &
Keys
.Alt) ==
Keys
.Alt;
16159
switch (e.KeyData &
Keys
.KeyCode)
16161
case
Keys
.A:
16162
case
Keys
.C:
16163
case
Keys
.D0:
16164
case
Keys
.NumPad0:
16165
case
Keys
.Delete:
16166
case
Keys
.Down:
16167
case
Keys
.F2:
16168
case
Keys
.F3:
16169
case
Keys
.End:
16170
case
Keys
.Enter:
16171
case
Keys
.Escape:
16172
case
Keys
.Home:
16173
case
Keys
.Insert:
16174
case
Keys
.Left:
16175
case
Keys
.Next:
16176
case
Keys
.Prior:
16177
case
Keys
.Right:
16178
case
Keys
.Space:
16179
case
Keys
.Tab:
16180
case
Keys
.Up:
16226
if (this.dataGridViewOper[DATAGRIDVIEWOPER_trackKeyboardColResize] && (e.KeyData &
Keys
.Alt) !=
Keys
.Alt && AccessibilityImprovements.Level2)
16899
if ((ModifierKeys & (
Keys
.Shift |
Keys
.Alt)) != 0 || MouseButtons != MouseButtons.None)
16904
bool verticalScroll = ((ModifierKeys &
Keys
.Control) == 0);
20445
protected bool ProcessAKey(
Keys
keyData)
20447
if ((keyData & (
Keys
.Shift |
Keys
.Control |
Keys
.Alt)) ==
Keys
.Control &&
20461
protected bool ProcessDeleteKey(
Keys
keyData)
20591
protected override bool ProcessDialogKey(
Keys
keyData)
20593
Keys
key = (keyData &
Keys
.KeyCode);
20595
if (key ==
Keys
.Enter)
20602
else if (key ==
Keys
.Escape)
20623
else if (key ==
Keys
.D0 || key ==
Keys
.NumPad0)
20630
else if (key ==
Keys
.C || key ==
Keys
.Insert)
20637
else if (key ==
Keys
.Tab)
20664
keyData &= ~
Keys
.Control;
20698
protected bool ProcessDownKey(
Keys
keyData)
20704
private bool ProcessDownKeyInternal(
Keys
keyData, out bool moved)
20729
if ((keyData &
Keys
.Control) ==
Keys
.Control)
20731
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
20846
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
20958
if ((keyData &
Keys
.Control) ==
Keys
.Control)
20960
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21065
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21176
if ((keyData &
Keys
.Control) ==
Keys
.Control)
21178
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21311
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21454
if ((keyData &
Keys
.Control) ==
Keys
.Control)
21547
protected bool ProcessEndKey(
Keys
keyData)
21566
if ((keyData &
Keys
.Control) == 0)
21568
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
21580
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21610
if ((keyData &
Keys
.Control) == 0)
21612
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
21624
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21678
if ((keyData &
Keys
.Control) == 0)
21680
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
21693
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21715
if ((keyData &
Keys
.Control) == 0)
21717
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
21721
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21793
if ((keyData &
Keys
.Control) == 0)
21795
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
21808
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
21846
protected bool ProcessEnterKey(
Keys
keyData)
21853
if ((keyData &
Keys
.Control) == 0)
21857
keyData &= ~
Keys
.Shift;
21927
protected bool ProcessEscapeKey(
Keys
keyData)
21949
protected bool ProcessF2Key(
Keys
keyData)
21982
protected bool ProcessF3Key(
Keys
keyData)
22003
protected bool ProcessHomeKey(
Keys
keyData)
22020
if ((keyData &
Keys
.Control) == 0)
22022
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
22034
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
22064
if ((keyData &
Keys
.Control) == 0)
22066
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
22078
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
22132
if ((keyData &
Keys
.Control) == 0)
22134
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
22147
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
22173
if ((keyData &
Keys
.Control) == 0)
22175
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
22179
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
22251
if ((keyData &
Keys
.Control) == 0)
22253
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
22284
protected bool ProcessInsertKey(
Keys
keyData)
22286
if (((keyData & (
Keys
.Shift |
Keys
.Control |
Keys
.Alt)) ==
Keys
.Control ||
22287
((keyData & (
Keys
.Shift |
Keys
.Control |
Keys
.Alt)) == (
Keys
.Control |
Keys
.Shift) && (keyData &
Keys
.KeyCode) ==
Keys
.C)) &&
22318
KeyEventArgs ke = new KeyEventArgs((
Keys
)(unchecked((int)(long)m.WParam)) | ModifierKeys);
22319
if (ke.KeyCode !=
Keys
.ProcessKey || (int) m.LParam != 0x01) // Changing IME context does not trigger editing mode
22335
if (BeginEditInternal(!(ke.KeyCode ==
Keys
.F2 && ModifierKeys == 0 && this.EditMode == DataGridViewEditMode.EditOnKeystrokeOrF2) /*selectAll*/))
22371
KeyEventArgs ke = new KeyEventArgs((
Keys
)((int)m.WParam) | ModifierKeys);
22382
case
Keys
.Escape:
22383
case
Keys
.Space:
22396
case
Keys
.Delete:
22397
case
Keys
.Down:
22398
case
Keys
.End:
22399
case
Keys
.Enter:
22400
case
Keys
.Escape:
22401
case
Keys
.F2:
22402
case
Keys
.F3:
22403
case
Keys
.Home:
22404
case
Keys
.Left:
22405
case
Keys
.Next:
22406
case
Keys
.Prior:
22407
case
Keys
.Right:
22408
case
Keys
.Space:
22409
case
Keys
.Tab:
22410
case
Keys
.Up:
22452
private bool? ProcessColumnResize(
Keys
keyData, int step)
22454
if (AccessibilityImprovements.Level2 && (keyData &
Keys
.Alt) ==
Keys
.Alt && this.AllowUserToResizeColumns && this.ptCurrentCell.X != -1)
22486
protected bool ProcessLeftKey(
Keys
keyData)
22498
private bool ProcessLeftKeyPrivate(
Keys
keyData)
22533
if ((keyData &
Keys
.Control) ==
Keys
.Control)
22535
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
22539
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
22629
if ((keyData &
Keys
.Control) ==
Keys
.Control)
22631
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
22635
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
22727
if ((keyData &
Keys
.Control) ==
Keys
.Control)
22729
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
22733
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
22853
if ((keyData &
Keys
.Control) ==
Keys
.Control)
22855
return ProcessLeftMost((keyData &
Keys
.Shift) ==
Keys
.Shift, firstVisibleColumnIndex, firstVisibleRowIndex);
23242
protected bool ProcessNextKey(
Keys
keyData)
23349
if ((keyData &
Keys
.Shift) ==
Keys
.Shift && this.MultiSelect)
23380
if ((keyData &
Keys
.Shift) ==
Keys
.Shift && this.MultiSelect)
23413
if ((keyData &
Keys
.Shift) ==
Keys
.Shift && this.MultiSelect)
23482
protected bool ProcessPriorKey(
Keys
keyData)
23588
if ((keyData &
Keys
.Shift) ==
Keys
.Shift && this.MultiSelect)
23619
if ((keyData &
Keys
.Shift) ==
Keys
.Shift && this.MultiSelect)
23652
if ((keyData &
Keys
.Shift) ==
Keys
.Shift && this.MultiSelect)
23724
protected bool ProcessRightKey(
Keys
keyData)
23736
private bool ProcessRightKeyPrivate(
Keys
keyData)
23772
if ((keyData &
Keys
.Control) ==
Keys
.Control)
23774
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
23778
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
23867
if ((keyData &
Keys
.Control) ==
Keys
.Control)
23869
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
23873
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
23965
if ((keyData &
Keys
.Control) ==
Keys
.Control)
23967
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
23971
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
24094
if ((keyData &
Keys
.Control) ==
Keys
.Control)
24096
return ProcessRightMost((keyData &
Keys
.Shift) ==
Keys
.Shift, lastVisibleColumnIndex, firstVisibleRowIndex);
24464
protected bool ProcessSpaceKey(
Keys
keyData)
24466
if ((keyData & (
Keys
.Control |
Keys
.Shift |
Keys
.Alt)) ==
Keys
.Shift &&
24548
protected bool ProcessTabKey(
Keys
keyData)
24552
if ((keyData &
Keys
.Control) ==
Keys
.Control)
24554
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
24598
if ((keyData &
Keys
.Control) ==
Keys
.Control)
24614
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
24658
case
Keys
.Tab:
24662
case
Keys
.Up:
24666
case
Keys
.Down:
24670
case
Keys
.Next:
24674
case
Keys
.Prior:
24678
case
Keys
.Left:
24682
case
Keys
.Right:
24686
case
Keys
.F2:
24690
case
Keys
.F3:
24694
case
Keys
.Home:
24698
case
Keys
.D0:
24699
case
Keys
.NumPad0:
24703
case
Keys
.Delete:
24707
case
Keys
.End:
24711
case
Keys
.Enter:
24715
case
Keys
.Escape:
24719
case
Keys
.A:
24723
case
Keys
.C:
24724
case
Keys
.Insert:
24728
case
Keys
.Space:
24740
protected bool ProcessUpKey(
Keys
keyData)
24763
if ((keyData &
Keys
.Control) ==
Keys
.Control)
24765
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
24858
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
24948
if ((keyData &
Keys
.Control) ==
Keys
.Control)
24950
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
25035
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
25127
if ((keyData &
Keys
.Control) ==
Keys
.Control)
25129
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
25242
if ((keyData &
Keys
.Shift) ==
Keys
.Shift)
25362
if ((keyData &
Keys
.Control) ==
Keys
.Control)
25438
protected bool ProcessZeroKey(
Keys
keyData)
25458
if ((keyData & (
Keys
.Alt |
Keys
.Shift |
Keys
.Control)) ==
Keys
.Control &&
29916
Keys
modifierKeys = ModifierKeys;
29917
if (GetTabKeyEffective((modifierKeys &
Keys
.Shift) ==
Keys
.Shift, (modifierKeys &
Keys
.Control) ==
Keys
.Control))
winforms\Managed\System\WinForms\DataGridViewRowHeaderCell.cs (3)
286
sb.Append((char)
Keys
.Return);
287
sb.Append((char)
Keys
.LineFeed);
292
sb.Append(csv ? ',' : (char)
Keys
.Tab);
winforms\Managed\System\WinForms\DataGridViewTextBoxCell.cs (7)
560
if (((char.IsLetterOrDigit((char)e.KeyCode) && !(e.KeyCode >=
Keys
.F1 && e.KeyCode <=
Keys
.F24)) ||
561
(e.KeyCode >=
Keys
.NumPad0 && e.KeyCode <=
Keys
.Divide) ||
562
(e.KeyCode >=
Keys
.OemSemicolon && e.KeyCode <=
Keys
.Oem102) ||
563
(e.KeyCode ==
Keys
.Space && !e.Shift)) &&
winforms\Managed\System\WinForms\DataGridViewTextBoxEditingControl.cs (23)
155
public virtual bool EditingControlWantsInputKey(
Keys
keyData, bool dataGridViewWantsInputKey)
157
switch (keyData &
Keys
.KeyCode)
159
case
Keys
.Right:
169
case
Keys
.Left:
180
case
Keys
.Down:
190
case
Keys
.Up:
199
case
Keys
.Home:
200
case
Keys
.End:
207
case
Keys
.Prior:
208
case
Keys
.Next:
215
case
Keys
.Delete:
223
case
Keys
.Enter:
224
if ((keyData & (
Keys
.Control |
Keys
.Shift |
Keys
.Alt)) ==
Keys
.Shift && this.Multiline && this.AcceptsReturn)
291
switch ((
Keys
)(int) m.WParam)
293
case
Keys
.Enter:
295
!(ModifierKeys ==
Keys
.Shift && this.Multiline && this.AcceptsReturn))
304
case
Keys
.LineFeed:
306
ModifierKeys ==
Keys
.Control && this.Multiline && this.AcceptsReturn)
313
case
Keys
.A:
314
if (m.Msg == NativeMethods.WM_KEYDOWN && ModifierKeys ==
Keys
.Control)
winforms\Managed\System\WinForms\DateTimePicker.cs (8)
1202
protected override bool IsInputKey(
Keys
keyData) {
1203
if ((keyData &
Keys
.Alt) ==
Keys
.Alt) return false;
1204
switch (keyData &
Keys
.KeyCode) {
1205
case
Keys
.PageUp:
1206
case
Keys
.PageDown:
1207
case
Keys
.Home:
1208
case
Keys
.End:
winforms\Managed\System\WinForms\Form.cs (10)
5277
protected override bool ProcessCmdKey(ref Message msg,
Keys
keyData) {
5315
protected override bool ProcessDialogKey(
Keys
keyData) {
5316
if ((keyData & (
Keys
.Alt |
Keys
.Control)) ==
Keys
.None) {
5317
Keys
keyCode = (
Keys
)keyData &
Keys
.KeyCode;
5321
case
Keys
.Return:
5331
case
Keys
.Escape:
winforms\Managed\System\WinForms\KeyEvent.cs (17)
34
private readonly
Keys
keyData;
56
public KeyEventArgs(
Keys
keyData) {
68
return (keyData &
Keys
.Alt) ==
Keys
.Alt;
80
return (keyData &
Keys
.Control) ==
Keys
.Control;
109
public
Keys
KeyCode {
115
Keys
keyGenerated = keyData &
Keys
.KeyCode;
118
if (!Enum.IsDefined(typeof(
Keys
),(int)keyGenerated))
119
return
Keys
.None;
135
return (int)(keyData &
Keys
.KeyCode);
146
public
Keys
KeyData {
159
public
Keys
Modifiers {
161
return keyData &
Keys
.Modifiers;
174
return (keyData &
Keys
.Shift) ==
Keys
.Shift;
winforms\Managed\System\WinForms\KeysConverter.cs (66)
24
/// <para>Provides a type converter to convert <see cref='System.Windows.Forms.
Keys
'/> objects to and from various
32
private const
Keys
FirstDigit = System.Windows.Forms.
Keys
.D0;
33
private const
Keys
LastDigit = System.Windows.Forms.
Keys
.D9;
34
private const
Keys
FirstAscii = System.Windows.Forms.
Keys
.A;
35
private const
Keys
LastAscii = System.Windows.Forms.
Keys
.Z;
36
private const
Keys
FirstNumpadDigit = System.Windows.Forms.
Keys
.NumPad0;
37
private const
Keys
LastNumpadDigit = System.Windows.Forms.
Keys
.NumPad9;
39
private void AddKey(string key,
Keys
value ) {
48
AddKey(SR.GetString(SR.toStringEnter),
Keys
.Return);
49
AddKey("F12",
Keys
.F12);
50
AddKey("F11",
Keys
.F11);
51
AddKey("F10",
Keys
.F10);
52
AddKey(SR.GetString(SR.toStringEnd),
Keys
.End);
53
AddKey(SR.GetString(SR.toStringControl),
Keys
.Control);
54
AddKey("F8",
Keys
.F8);
55
AddKey("F9",
Keys
.F9);
56
AddKey(SR.GetString(SR.toStringAlt),
Keys
.Alt);
57
AddKey("F4",
Keys
.F4);
58
AddKey("F5",
Keys
.F5);
59
AddKey("F6",
Keys
.F6);
60
AddKey("F7",
Keys
.F7);
61
AddKey("F1",
Keys
.F1);
62
AddKey("F2",
Keys
.F2);
63
AddKey("F3",
Keys
.F3);
64
AddKey(SR.GetString(SR.toStringPageDown),
Keys
.Next);
65
AddKey(SR.GetString(SR.toStringInsert),
Keys
.Insert);
66
AddKey(SR.GetString(SR.toStringHome),
Keys
.Home);
67
AddKey(SR.GetString(SR.toStringDelete),
Keys
.Delete);
68
AddKey(SR.GetString(SR.toStringShift),
Keys
.Shift);
69
AddKey(SR.GetString(SR.toStringPageUp),
Keys
.Prior);
70
AddKey(SR.GetString(SR.toStringBack),
Keys
.Back);
75
AddKey("0",
Keys
.D0);
76
AddKey("1",
Keys
.D1);
77
AddKey("2",
Keys
.D2);
78
AddKey("3",
Keys
.D3);
79
AddKey("4",
Keys
.D4);
80
AddKey("5",
Keys
.D5);
81
AddKey("6",
Keys
.D6);
82
AddKey("7",
Keys
.D7);
83
AddKey("8",
Keys
.D8);
84
AddKey("9",
Keys
.D9);
170
Keys
key = (
Keys
)0;
181
obj = Enum.Parse(typeof(
Keys
), tokens[i]);
185
Keys
currentKey = (
Keys
)obj;
187
if ((currentKey &
Keys
.KeyCode) != 0) {
221
return Enum.ToObject(typeof(
Keys
), finalValue);
242
if (value is
Keys
|| value is int) {
247
Keys
key = (
Keys
)value;
250
Keys
modifiers = (key &
Keys
.Modifiers);
257
Keys
keyValue = (
Keys
)keyNames[keyString];
278
Keys
keyOnly = (key &
Keys
.KeyCode);
287
Keys
keyValue = (
Keys
)keyNames[keyString];
306
if (!foundKey && Enum.IsDefined(typeof(
Keys
), (int)keyOnly)) {
winforms\Managed\System\WinForms\LinkLabel.cs (14)
953
if (e.KeyCode ==
Keys
.Enter) {
1551
protected override bool ProcessDialogKey(
Keys
keyData) {
1552
if ((keyData & (
Keys
.Alt |
Keys
.Control)) !=
Keys
.Alt) {
1553
Keys
keyCode = keyData &
Keys
.KeyCode;
1555
case
Keys
.Tab:
1557
bool forward = (keyData &
Keys
.Shift) !=
Keys
.Shift;
1563
case
Keys
.Up:
1564
case
Keys
.Left:
1569
case
Keys
.Down:
1570
case
Keys
.Right:
winforms\Managed\System\WinForms\ListControl.cs (8)
609
protected override bool IsInputKey(
Keys
keyData) {
610
if ((keyData &
Keys
.Alt) ==
Keys
.Alt) return false;
611
switch (keyData &
Keys
.KeyCode) {
612
case
Keys
.PageUp:
613
case
Keys
.PageDown:
614
case
Keys
.Home:
615
case
Keys
.End:
winforms\Managed\System\WinForms\ListView.cs (12)
4000
protected override bool IsInputKey(
Keys
keyData) {
4001
if ((keyData &
Keys
.Alt) ==
Keys
.Alt) return false;
4002
switch (keyData &
Keys
.KeyCode) {
4003
case
Keys
.PageUp:
4004
case
Keys
.PageDown:
4005
case
Keys
.Home:
4006
case
Keys
.End:
4015
switch (keyData &
Keys
.KeyCode) {
4016
case
Keys
.Return:
4017
case
Keys
.Escape:
6011
if (lvkd.wVKey == (short)
Keys
.Space) {
winforms\Managed\System\WinForms\MaskedTextBox.cs (28)
589
protected override bool IsInputKey(
Keys
keyData)
591
if ((keyData &
Keys
.KeyCode) ==
Keys
.Return)
1330
Delete(
Keys
.Delete, 0, this.maskedTextProvider.Length);
1702
private void Delete(
Keys
keyCode, int startPosition, int selectionLen)
1705
Debug.Assert( keyCode ==
Keys
.Delete || keyCode ==
Keys
.Back, "Delete called with keyCode == " + keyCode.ToString() );
1715
if( keyCode ==
Keys
.Back )
1764
if( keyCode ==
Keys
.Delete )
1796
if( keyCode ==
Keys
.Back ) // Case 3.
2055
Keys
keyCode = e.KeyCode;
2058
if( keyCode ==
Keys
.Return || keyCode ==
Keys
.Escape )
2066
if (keyCode ==
Keys
.Insert && e.Modifiers ==
Keys
.None && this.insertMode == InsertKeyMode.Default)
2088
case
Keys
.H: // ctrl-h == Backspace == '\b'
2089
keyCode =
Keys
.Back; // handle it below.
2101
if ( keyCode ==
Keys
.Delete || keyCode ==
Keys
.Back ) // Deletion keys.
2112
case
Keys
.Shift:
2113
if( keyCode ==
Keys
.Delete )
2115
keyCode =
Keys
.Back;
2119
case
Keys
.Control:
2122
if( keyCode ==
Keys
.Delete ) // delete to the end of the string.
2520
Delete(
Keys
.Delete, selStart, selLength );
2679
protected override bool ProcessCmdKey(ref Message msg,
Keys
keyData)
2976
Delete(
Keys
.Delete, selStart, selLength);
3109
Delete(
Keys
.Delete, startEditPos, selectionLen);
winforms\Managed\System\WinForms\MDIControlStrip.cs (3)
78
system.ShortcutKeys =
Keys
.Alt |
Keys
.OemMinus;
236
protected internal override bool ProcessCmdKey(ref Message m,
Keys
keyData) {
winforms\Managed\System\WinForms\Menu.cs (1)
588
protected internal virtual bool ProcessCmdKey(ref Message msg,
Keys
keyData) {
winforms\Managed\System\WinForms\MenuItem.cs (2)
951
info.dwTypeData = data.caption + "\t" + TypeDescriptor.GetConverter(typeof(
Keys
)).ConvertToString((
Keys
)(int)data.shortcut);
winforms\Managed\System\WinForms\MenuStrip.cs (3)
239
protected override bool ProcessCmdKey(ref Message m,
Keys
keyData) {
243
if (keyData ==
Keys
.Space) {
252
UnsafeNativeMethods.PostMessage(WindowsFormsUtils.GetRootHWnd(this), NativeMethods.WM_SYSCOMMAND, NativeMethods.SC_KEYMENU, (int)
Keys
.Space);
winforms\Managed\System\WinForms\MonthCalendar.cs (8)
1610
protected override bool IsInputKey(
Keys
keyData) {
1611
if ((keyData &
Keys
.Alt) ==
Keys
.Alt) return false;
1612
switch (keyData &
Keys
.KeyCode) {
1613
case
Keys
.PageUp:
1614
case
Keys
.PageDown:
1615
case
Keys
.Home:
1616
case
Keys
.End:
winforms\Managed\System\WinForms\NumericUpDown.cs (6)
494
if (base.InterceptArrowKeys && (e.KeyCode ==
Keys
.Up || e.KeyCode ==
Keys
.Down) && !this.Spinning) {
505
if (base.InterceptArrowKeys && (e.KeyCode ==
Keys
.Up || e.KeyCode ==
Keys
.Down)) {
544
else if ((ModifierKeys & (
Keys
.Control |
Keys
.Alt)) != 0) {
winforms\Managed\System\WinForms\PreviewKeyDownEventArgs.cs (17)
23
private readonly
Keys
_keyData;
30
public PreviewKeyDownEventArgs(
Keys
keyData) {
42
return (_keyData &
Keys
.Alt) ==
Keys
.Alt;
54
return (_keyData &
Keys
.Control) ==
Keys
.Control;
66
public
Keys
KeyCode {
72
Keys
keyGenerated = _keyData &
Keys
.KeyCode;
75
if (!Enum.IsDefined(typeof(
Keys
),(int)keyGenerated))
76
return
Keys
.None;
92
return (int)(_keyData &
Keys
.KeyCode);
103
public
Keys
KeyData {
116
public
Keys
Modifiers {
118
return _keyData &
Keys
.Modifiers;
131
return (_keyData &
Keys
.Shift) ==
Keys
.Shift;
winforms\Managed\System\WinForms\Printing\PrintPreviewControl.cs (19)
811
Keys
keyData = (
Keys
)((int)msg.WParam | (int)ModifierKeys);
816
switch (keyData &
Keys
.KeyCode) {
817
case
Keys
.PageUp:
818
if ((keyData &
Keys
.Modifiers) ==
Keys
.Control)
835
case
Keys
.PageDown:
836
if ((keyData &
Keys
.Modifiers) ==
Keys
.Control)
854
case
Keys
.Home:
855
if ((keyData &
Keys
.Modifiers) ==
Keys
.Control)
858
case
Keys
.End:
859
if ((keyData &
Keys
.Modifiers) ==
Keys
.Control)
863
case
Keys
.Up:
875
case
Keys
.Down:
889
case
Keys
.Left:
901
case
Keys
.Right:
winforms\Managed\System\WinForms\Printing\PrintPreviewDialog.cs (11)
1611
protected override bool ProcessDialogKey(
Keys
keyData) {
1612
if ((keyData & (
Keys
.Alt |
Keys
.Control)) ==
Keys
.None) {
1613
Keys
keyCode = (
Keys
)keyData &
Keys
.KeyCode;
1615
case
Keys
.Left:
1616
case
Keys
.Right:
1617
case
Keys
.Up:
1618
case
Keys
.Down:
winforms\Managed\System\WinForms\PropertyGrid.cs (6)
3739
protected override bool ProcessDialogKey(
Keys
keyData)
3741
switch (keyData &
Keys
.KeyCode) {
3742
case
Keys
.Tab:
3743
if (((keyData &
Keys
.Control) != 0) ||
3744
((keyData &
Keys
.Alt) != 0)) {
3749
if ((keyData &
Keys
.Shift) != 0) {
winforms\Managed\System\WinForms\PropertyGridInternal\PropertyGridView.cs (131)
1790
if (dropDownHolder != null && dropDownHolder.Visible && m.Msg == NativeMethods.WM_KEYDOWN && (int)m.WParam != (int)
Keys
.Tab) {
1828
Keys
modifiers = ModifierKeys;
1829
if ((int)(modifiers & ~
Keys
.Shift) != 0) {
1844
case unchecked( (char)(int)(long)
Keys
.Tab):
2279
protected override bool IsInputKey(
Keys
keyData) {
2280
switch (keyData &
Keys
.KeyCode) {
2281
case
Keys
.Escape:
2282
case
Keys
.Tab:
2283
case
Keys
.F4:
2286
case
Keys
.Return:
2574
if (ke.KeyCode ==
Keys
.Return) {
2680
private bool ProcessEnumUpAndDown(GridEntry gridEntry,
Keys
keyCode, bool closeDropDown = true) {
2697
if (keyCode ==
Keys
.Up) {
2719
if (!fAlt && (ke.KeyCode ==
Keys
.Up || ke.KeyCode ==
Keys
.Down)) {
2732
else if ((ke.KeyCode ==
Keys
.Left || ke.KeyCode ==
Keys
.Right) &&
2733
(ke.Modifiers & ~
Keys
.Shift) != 0) {
2839
if ((ModifierKeys & (
Keys
.Alt |
Keys
.Control)) != 0) {
2913
Keys
keyCode = ke.KeyCode;
2921
if (keyCode ==
Keys
.Tab) {
2929
if (keyCode ==
Keys
.Down && fAlt && DropDownButton.Visible) {
2934
if (keyCode ==
Keys
.Up && fAlt && DropDownButton.Visible && (dropDownHolder != null) && dropDownHolder.Visible) {
2945
case
Keys
.Up:
2946
case
Keys
.Down:
2947
int pos = (keyCode ==
Keys
.Up ? selectedRow - 1 : selectedRow + 1);
2951
case
Keys
.Left:
2964
case
Keys
.Right:
2983
case
Keys
.Return:
2992
case
Keys
.Home:
2993
case
Keys
.End:
2995
int pos2 = (keyCode ==
Keys
.Home ? 0 : rgipes.Count-1);
2998
case
Keys
.Add:
2999
case
Keys
.Oemplus:
3000
case
Keys
.OemMinus:
3001
case
Keys
.Subtract:
3008
bool expand = (keyCode ==
Keys
.Add || keyCode ==
Keys
.Oemplus);
3015
case
Keys
.D8:
3017
goto case
Keys
.Multiply;
3020
case
Keys
.Multiply:
3028
case
Keys
.Prior: //PAGE_UP:
3029
case
Keys
.Next: //PAGE_DOWN
3031
bool next = (keyCode ==
Keys
.Next);
3062
case
Keys
.Insert:
3065
goto case
Keys
.V;
3067
goto case
Keys
.C;
3068
case
Keys
.C:
3075
case
Keys
.Delete:
3079
goto case
Keys
.X;
3082
case
Keys
.X:
3090
case
Keys
.V:
3096
case
Keys
.A:
3105
if (gridEntry != null && ke.KeyData == (
Keys
.C |
Keys
.Alt |
Keys
.Shift |
Keys
.Control)) {
3148
(keyCode ==
Keys
.Up || keyCode ==
Keys
.Down))
3317
if ((ModifierKeys & (
Keys
.Shift |
Keys
.Alt)) != 0 || MouseButtons != MouseButtons.None) {
3955
protected override bool ProcessDialogKey(
Keys
keyData) {
3958
Keys
keyCode = keyData &
Keys
.KeyCode;
3960
case
Keys
.F4:
3966
case
Keys
.Tab:
3968
if (((keyData &
Keys
.Control) != 0) ||
3969
((keyData &
Keys
.Alt) != 0)) {
3973
bool forward = (keyData &
Keys
.Shift) == 0;
4023
case
Keys
.Up:
4024
case
Keys
.Down:
4025
case
Keys
.Left:
4026
case
Keys
.Right:
4028
case
Keys
.Return:
5360
if ((ModifierKeys &
Keys
.Shift) == 0) {
5927
protected override bool ProcessDialogKey(
Keys
keyData) {
5928
if ((keyData & (
Keys
.Shift |
Keys
.Control |
Keys
.Alt)) == 0) {
5929
switch (keyData &
Keys
.KeyCode) {
5930
case
Keys
.Escape:
5933
case
Keys
.F4:
5936
case
Keys
.Return:
6660
protected override bool IsInputKey(
Keys
keyData) {
6661
switch (keyData &
Keys
.KeyCode) {
6662
case
Keys
.Escape:
6663
case
Keys
.Tab:
6664
case
Keys
.F4:
6665
case
Keys
.F1:
6666
case
Keys
.Return:
6680
switch ((
Keys
)(int)keyChar) {
6681
case
Keys
.Tab:
6682
case
Keys
.Return:
6729
protected override bool ProcessCmdKey(ref Message msg,
Keys
keyData) {
6732
switch (keyData &
Keys
.KeyCode) {
6733
case
Keys
.Z:
6734
case
Keys
.C:
6735
case
Keys
.X:
6736
case
Keys
.V:
6738
((keyData &
Keys
.Control) != 0) &&
6739
((keyData &
Keys
.Shift) == 0) &&
6740
((keyData &
Keys
.Alt) == 0)) {
6745
case
Keys
.A:
6747
((keyData &
Keys
.Control) != 0) &&
6748
((keyData &
Keys
.Shift) == 0) &&
6749
((keyData &
Keys
.Alt) == 0)) {
6756
case
Keys
.Insert:
6757
if (((keyData &
Keys
.Alt) == 0)) {
6758
if (((keyData &
Keys
.Control) != 0) ^ ((keyData &
Keys
.Shift) == 0)) {
6764
case
Keys
.Delete:
6766
((keyData &
Keys
.Control) == 0) &&
6767
((keyData &
Keys
.Shift) != 0) &&
6768
((keyData &
Keys
.Alt) == 0)) {
6772
((keyData &
Keys
.Control) == 0) &&
6773
((keyData &
Keys
.Shift) == 0) &&
6774
((keyData &
Keys
.Alt) == 0)
6799
protected override bool ProcessDialogKey(
Keys
keyData) {
6803
if ((keyData & (
Keys
.Shift |
Keys
.Control |
Keys
.Alt)) == 0) {
6804
switch (keyData &
Keys
.KeyCode) {
6805
case
Keys
.Return:
6811
case
Keys
.Escape:
6814
case
Keys
.F4:
6821
if ((keyData &
Keys
.KeyCode) ==
Keys
.Tab && ((keyData & (
Keys
.Control |
Keys
.Alt)) == 0)) {
6915
if (psheet.NeedsCommit || this.WantsTab((ModifierKeys &
Keys
.Shift) == 0)) {
winforms\Managed\System\WinForms\RadioButton.cs (1)
469
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.Tab) >= 0) {
winforms\Managed\System\WinForms\RichTextBox.cs (6)
2725
protected override bool ProcessCmdKey(ref Message m,
Keys
keyData) {
3873
Keys
k = Control.ModifierKeys;
3894
if ((k &
Keys
.Control) ==
Keys
.Control) {
3898
if ((k &
Keys
.Shift) ==
Keys
.Shift) {
winforms\Managed\System\WinForms\SendKeys.cs (81)
39
new KeywordVk("ENTER", (int)
Keys
.Return),
40
new KeywordVk("TAB", (int)
Keys
.Tab),
41
new KeywordVk("ESC", (int)
Keys
.Escape),
42
new KeywordVk("ESCAPE", (int)
Keys
.Escape),
43
new KeywordVk("HOME", (int)
Keys
.Home),
44
new KeywordVk("END", (int)
Keys
.End),
45
new KeywordVk("LEFT", (int)
Keys
.Left),
46
new KeywordVk("RIGHT", (int)
Keys
.Right),
47
new KeywordVk("UP", (int)
Keys
.Up),
48
new KeywordVk("DOWN", (int)
Keys
.Down),
49
new KeywordVk("PGUP", (int)
Keys
.Prior),
50
new KeywordVk("PGDN", (int)
Keys
.Next),
51
new KeywordVk("NUMLOCK", (int)
Keys
.NumLock),
52
new KeywordVk("SCROLLLOCK", (int)
Keys
.Scroll),
53
new KeywordVk("PRTSC", (int)
Keys
.PrintScreen),
54
new KeywordVk("BREAK", (int)
Keys
.Cancel),
55
new KeywordVk("BACKSPACE", (int)
Keys
.Back),
56
new KeywordVk("BKSP", (int)
Keys
.Back),
57
new KeywordVk("BS", (int)
Keys
.Back),
58
new KeywordVk("CLEAR", (int)
Keys
.Clear),
59
new KeywordVk("CAPSLOCK", (int)
Keys
.Capital),
60
new KeywordVk("INS", (int)
Keys
.Insert),
61
new KeywordVk("INSERT", (int)
Keys
.Insert),
62
new KeywordVk("DEL", (int)
Keys
.Delete),
63
new KeywordVk("DELETE", (int)
Keys
.Delete),
64
new KeywordVk("HELP", (int)
Keys
.Help),
65
new KeywordVk("F1", (int)
Keys
.F1),
66
new KeywordVk("F2", (int)
Keys
.F2),
67
new KeywordVk("F3", (int)
Keys
.F3),
68
new KeywordVk("F4", (int)
Keys
.F4),
69
new KeywordVk("F5", (int)
Keys
.F5),
70
new KeywordVk("F6", (int)
Keys
.F6),
71
new KeywordVk("F7", (int)
Keys
.F7),
72
new KeywordVk("F8", (int)
Keys
.F8),
73
new KeywordVk("F9", (int)
Keys
.F9),
74
new KeywordVk("F10", (int)
Keys
.F10),
75
new KeywordVk("F11", (int)
Keys
.F11),
76
new KeywordVk("F12", (int)
Keys
.F12),
77
new KeywordVk("F13", (int)
Keys
.F13),
78
new KeywordVk("F14", (int)
Keys
.F14),
79
new KeywordVk("F15", (int)
Keys
.F15),
80
new KeywordVk("F16", (int)
Keys
.F16),
81
new KeywordVk("MULTIPLY", (int)
Keys
.Multiply),
82
new KeywordVk("ADD", (int)
Keys
.Add),
83
new KeywordVk("SUBTRACT", (int)
Keys
.Subtract),
84
new KeywordVk("DIVIDE", (int)
Keys
.Divide),
85
new KeywordVk("+", (int)
Keys
.Add),
86
new KeywordVk("%", (int)(
Keys
.D5 |
Keys
.Shift)),
87
new KeywordVk("^", (int)(
Keys
.D6 |
Keys
.Shift)),
167
AddEvent(new SKEvent(NativeMethods.WM_KEYDOWN, (int)
Keys
.ShiftKey, fStartNewChar, hwnd));
173
AddEvent(new SKEvent(NativeMethods.WM_KEYDOWN, (int)
Keys
.ControlKey, fStartNewChar, hwnd));
179
AddEvent(new SKEvent(NativeMethods.WM_KEYDOWN, (int)
Keys
.Menu, fStartNewChar, hwnd));
217
AddEvent(new SKEvent(NativeMethods.WM_KEYUP, (int)
Keys
.ShiftKey, false, hwnd));
221
AddEvent(new SKEvent(NativeMethods.WM_KEYUP, (int)
Keys
.ControlKey, false, hwnd));
225
AddEvent(new SKEvent(NativeMethods.WM_SYSKEYUP, (int)
Keys
.Menu, false, hwnd));
334
keystate[(int)
Keys
.Capital] = 0;
335
keystate[(int)
Keys
.NumLock] = 0;
336
keystate[(int)
Keys
.Scroll] = 0;
470
if (haveKeys[HAVESHIFT] == 0 && (vk & (int)
Keys
.Shift) != 0) {
471
AddEvent(new SKEvent(NativeMethods.WM_KEYDOWN, (int)
Keys
.ShiftKey, fStartNewChar, hwnd));
476
if (haveKeys[HAVECTRL] == 0 && (vk & (int)
Keys
.Control) != 0) {
477
AddEvent(new SKEvent(NativeMethods.WM_KEYDOWN, (int)
Keys
.ControlKey, fStartNewChar, hwnd));
482
if (haveKeys[HAVEALT] == 0 && (vk & (int)
Keys
.Alt) != 0) {
483
AddEvent(new SKEvent(NativeMethods.WM_KEYDOWN, (int)
Keys
.Menu, fStartNewChar, hwnd));
504
AddEvent(new SKEvent(NativeMethods.WM_KEYDOWN, (int)
Keys
.ShiftKey, fStartNewChar, hwnd));
512
AddEvent(new SKEvent(NativeMethods.WM_KEYDOWN, (int)
Keys
.ControlKey, fStartNewChar, hwnd));
521
(int)
Keys
.Menu, fStartNewChar, hwnd));
547
vk = (int)
Keys
.Return;
726
if (skEvent.paramL == (int)
Keys
.ShiftKey)
730
else if (skEvent.paramL == (int)
Keys
.ControlKey)
734
else if (skEvent.paramL == (int)
Keys
.Menu)
742
AddEvent(new SKEvent(NativeMethods.WM_KEYUP, (int)
Keys
.ShiftKey, false, IntPtr.Zero));
746
AddEvent(new SKEvent(NativeMethods.WM_KEYUP, (int)
Keys
.ControlKey, false, IntPtr.Zero));
750
AddEvent(new SKEvent(NativeMethods.WM_SYSKEYUP, (int)
Keys
.Menu, false, IntPtr.Zero));
782
case (int)
Keys
.CapsLock:
785
case (int)
Keys
.NumLock:
788
case (int)
Keys
.Scroll:
791
case (int)
Keys
.KanaMode:
1064
if (UnsafeNativeMethods.GetAsyncKeyState((int)
Keys
.Pause) != 0) {
winforms\Managed\System\WinForms\Shortcut.cs (340)
36
CtrlA =
Keys
.Control +
Keys
.A,
43
CtrlB =
Keys
.Control +
Keys
.B,
50
CtrlC =
Keys
.Control +
Keys
.C,
57
CtrlD =
Keys
.Control +
Keys
.D,
64
CtrlE =
Keys
.Control +
Keys
.E,
71
CtrlF =
Keys
.Control +
Keys
.F,
78
CtrlG =
Keys
.Control +
Keys
.G,
85
CtrlH =
Keys
.Control +
Keys
.H,
92
CtrlI =
Keys
.Control +
Keys
.I,
99
CtrlJ =
Keys
.Control +
Keys
.J,
106
CtrlK =
Keys
.Control +
Keys
.K,
113
CtrlL =
Keys
.Control +
Keys
.L,
120
CtrlM =
Keys
.Control +
Keys
.M,
127
CtrlN =
Keys
.Control +
Keys
.N,
134
CtrlO =
Keys
.Control +
Keys
.O,
141
CtrlP =
Keys
.Control +
Keys
.P,
148
CtrlQ =
Keys
.Control +
Keys
.Q,
155
CtrlR =
Keys
.Control +
Keys
.R,
162
CtrlS =
Keys
.Control +
Keys
.S,
169
CtrlT =
Keys
.Control +
Keys
.T,
176
CtrlU =
Keys
.Control +
Keys
.U,
183
CtrlV =
Keys
.Control +
Keys
.V,
190
CtrlW =
Keys
.Control +
Keys
.W,
197
CtrlX =
Keys
.Control +
Keys
.X,
204
CtrlY =
Keys
.Control +
Keys
.Y,
211
CtrlZ =
Keys
.Control +
Keys
.Z,
218
CtrlShiftA =
Keys
.Control +
Keys
.Shift +
Keys
.A,
225
CtrlShiftB =
Keys
.Control +
Keys
.Shift +
Keys
.B,
232
CtrlShiftC =
Keys
.Control +
Keys
.Shift +
Keys
.C,
239
CtrlShiftD =
Keys
.Control +
Keys
.Shift +
Keys
.D,
246
CtrlShiftE =
Keys
.Control +
Keys
.Shift +
Keys
.E,
253
CtrlShiftF =
Keys
.Control +
Keys
.Shift +
Keys
.F,
260
CtrlShiftG =
Keys
.Control +
Keys
.Shift +
Keys
.G,
267
CtrlShiftH =
Keys
.Control +
Keys
.Shift +
Keys
.H,
274
CtrlShiftI =
Keys
.Control +
Keys
.Shift +
Keys
.I,
281
CtrlShiftJ =
Keys
.Control +
Keys
.Shift +
Keys
.J,
288
CtrlShiftK =
Keys
.Control +
Keys
.Shift +
Keys
.K,
295
CtrlShiftL =
Keys
.Control +
Keys
.Shift +
Keys
.L,
302
CtrlShiftM =
Keys
.Control +
Keys
.Shift +
Keys
.M,
309
CtrlShiftN =
Keys
.Control +
Keys
.Shift +
Keys
.N,
316
CtrlShiftO =
Keys
.Control +
Keys
.Shift +
Keys
.O,
323
CtrlShiftP =
Keys
.Control +
Keys
.Shift +
Keys
.P,
330
CtrlShiftQ =
Keys
.Control +
Keys
.Shift +
Keys
.Q,
337
CtrlShiftR =
Keys
.Control +
Keys
.Shift +
Keys
.R,
344
CtrlShiftS =
Keys
.Control +
Keys
.Shift +
Keys
.S,
351
CtrlShiftT =
Keys
.Control +
Keys
.Shift +
Keys
.T,
358
CtrlShiftU =
Keys
.Control +
Keys
.Shift +
Keys
.U,
365
CtrlShiftV =
Keys
.Control +
Keys
.Shift +
Keys
.V,
372
CtrlShiftW =
Keys
.Control +
Keys
.Shift +
Keys
.W,
379
CtrlShiftX =
Keys
.Control +
Keys
.Shift +
Keys
.X,
386
CtrlShiftY =
Keys
.Control +
Keys
.Shift +
Keys
.Y,
393
CtrlShiftZ =
Keys
.Control +
Keys
.Shift +
Keys
.Z,
400
F1 =
Keys
.F1,
407
F2 =
Keys
.F2,
414
F3 =
Keys
.F3,
421
F4 =
Keys
.F4,
428
F5 =
Keys
.F5,
435
F6 =
Keys
.F6,
442
F7 =
Keys
.F7,
447
F8 =
Keys
.F8,
454
F9 =
Keys
.F9,
461
F10 =
Keys
.F10,
468
F11 =
Keys
.F11,
475
F12 =
Keys
.F12,
482
ShiftF1 =
Keys
.Shift +
Keys
.F1,
489
ShiftF2 =
Keys
.Shift +
Keys
.F2,
496
ShiftF3 =
Keys
.Shift +
Keys
.F3,
503
ShiftF4 =
Keys
.Shift +
Keys
.F4,
510
ShiftF5 =
Keys
.Shift +
Keys
.F5,
517
ShiftF6 =
Keys
.Shift +
Keys
.F6,
524
ShiftF7 =
Keys
.Shift +
Keys
.F7,
531
ShiftF8 =
Keys
.Shift +
Keys
.F8,
538
ShiftF9 =
Keys
.Shift +
Keys
.F9,
545
ShiftF10 =
Keys
.Shift +
Keys
.F10,
552
ShiftF11 =
Keys
.Shift +
Keys
.F11,
559
ShiftF12 =
Keys
.Shift +
Keys
.F12,
566
CtrlF1 =
Keys
.Control +
Keys
.F1,
573
CtrlF2 =
Keys
.Control +
Keys
.F2,
580
CtrlF3 =
Keys
.Control +
Keys
.F3,
587
CtrlF4 =
Keys
.Control +
Keys
.F4,
594
CtrlF5 =
Keys
.Control +
Keys
.F5,
601
CtrlF6 =
Keys
.Control +
Keys
.F6,
608
CtrlF7 =
Keys
.Control +
Keys
.F7,
615
CtrlF8 =
Keys
.Control +
Keys
.F8,
622
CtrlF9 =
Keys
.Control +
Keys
.F9,
629
CtrlF10 =
Keys
.Control +
Keys
.F10,
636
CtrlF11 =
Keys
.Control +
Keys
.F11,
643
CtrlF12 =
Keys
.Control +
Keys
.F12,
650
CtrlShiftF1 =
Keys
.Control +
Keys
.Shift +
Keys
.F1,
657
CtrlShiftF2 =
Keys
.Control +
Keys
.Shift +
Keys
.F2,
664
CtrlShiftF3 =
Keys
.Control +
Keys
.Shift +
Keys
.F3,
671
CtrlShiftF4 =
Keys
.Control +
Keys
.Shift +
Keys
.F4,
678
CtrlShiftF5 =
Keys
.Control +
Keys
.Shift +
Keys
.F5,
685
CtrlShiftF6 =
Keys
.Control +
Keys
.Shift +
Keys
.F6,
692
CtrlShiftF7 =
Keys
.Control +
Keys
.Shift +
Keys
.F7,
699
CtrlShiftF8 =
Keys
.Control +
Keys
.Shift +
Keys
.F8,
706
CtrlShiftF9 =
Keys
.Control +
Keys
.Shift +
Keys
.F9,
713
CtrlShiftF10 =
Keys
.Control +
Keys
.Shift +
Keys
.F10,
720
CtrlShiftF11 =
Keys
.Control +
Keys
.Shift +
Keys
.F11,
727
CtrlShiftF12 =
Keys
.Control +
Keys
.Shift +
Keys
.F12,
734
Ins =
Keys
.Insert,
741
CtrlIns =
Keys
.Control +
Keys
.Insert,
748
ShiftIns =
Keys
.Shift +
Keys
.Insert,
755
Del =
Keys
.Delete,
762
CtrlDel =
Keys
.Control +
Keys
.Delete,
769
ShiftDel =
Keys
.Shift +
Keys
.Delete,
776
AltRightArrow =
Keys
.Alt +
Keys
.Right,
783
AltLeftArrow =
Keys
.Alt +
Keys
.Left,
790
AltUpArrow =
Keys
.Alt +
Keys
.Up,
797
AltDownArrow =
Keys
.Alt +
Keys
.Down,
804
AltBksp =
Keys
.Alt +
Keys
.Back,
811
AltF1 =
Keys
.Alt +
Keys
.F1,
818
AltF2 =
Keys
.Alt +
Keys
.F2,
825
AltF3 =
Keys
.Alt +
Keys
.F3,
832
AltF4 =
Keys
.Alt +
Keys
.F4,
839
AltF5 =
Keys
.Alt +
Keys
.F5,
846
AltF6 =
Keys
.Alt +
Keys
.F6,
853
AltF7 =
Keys
.Alt +
Keys
.F7,
860
AltF8 =
Keys
.Alt +
Keys
.F8,
867
AltF9 =
Keys
.Alt +
Keys
.F9,
874
AltF10 =
Keys
.Alt +
Keys
.F10,
881
AltF11 =
Keys
.Alt +
Keys
.F11,
888
AltF12 =
Keys
.Alt +
Keys
.F12,
896
Alt0 =
Keys
.Alt +
Keys
.D0,
904
Alt1 =
Keys
.Alt +
Keys
.D1,
912
Alt2 =
Keys
.Alt +
Keys
.D2,
920
Alt3 =
Keys
.Alt +
Keys
.D3,
928
Alt4 =
Keys
.Alt +
Keys
.D4,
936
Alt5 =
Keys
.Alt +
Keys
.D5,
944
Alt6 =
Keys
.Alt +
Keys
.D6,
952
Alt7 =
Keys
.Alt +
Keys
.D7,
960
Alt8 =
Keys
.Alt +
Keys
.D8,
968
Alt9 =
Keys
.Alt +
Keys
.D9,
976
Ctrl0 =
Keys
.Control +
Keys
.D0,
984
Ctrl1 =
Keys
.Control +
Keys
.D1,
992
Ctrl2 =
Keys
.Control +
Keys
.D2,
1000
Ctrl3 =
Keys
.Control +
Keys
.D3,
1008
Ctrl4 =
Keys
.Control +
Keys
.D4,
1016
Ctrl5 =
Keys
.Control +
Keys
.D5,
1024
Ctrl6 =
Keys
.Control +
Keys
.D6,
1032
Ctrl7 =
Keys
.Control +
Keys
.D7,
1040
Ctrl8 =
Keys
.Control +
Keys
.D8,
1048
Ctrl9 =
Keys
.Control +
Keys
.D9,
1056
CtrlShift0 =
Keys
.Control +
Keys
.Shift +
Keys
.D0,
1064
CtrlShift1 =
Keys
.Control +
Keys
.Shift +
Keys
.D1,
1072
CtrlShift2 =
Keys
.Control +
Keys
.Shift +
Keys
.D2,
1080
CtrlShift3 =
Keys
.Control +
Keys
.Shift +
Keys
.D3,
1088
CtrlShift4 =
Keys
.Control +
Keys
.Shift +
Keys
.D4,
1096
CtrlShift5 =
Keys
.Control +
Keys
.Shift +
Keys
.D5,
1104
CtrlShift6 =
Keys
.Control +
Keys
.Shift +
Keys
.D6,
1112
CtrlShift7 =
Keys
.Control +
Keys
.Shift +
Keys
.D7,
1120
CtrlShift8 =
Keys
.Control +
Keys
.Shift +
Keys
.D8,
1128
CtrlShift9 =
Keys
.Control +
Keys
.Shift +
Keys
.D9,
winforms\Managed\System\WinForms\SplitContainer.cs (30)
1137
if (e.KeyData ==
Keys
.Escape && splitBegin) {
1143
if (e.KeyData ==
Keys
.Right || e.KeyData ==
Keys
.Down ||
1144
e.KeyData ==
Keys
.Left || e.KeyData ==
Keys
.Up
1151
if (e.KeyData ==
Keys
.Left || e.KeyData ==
Keys
.Up && splitterFocused) {
1156
if (e.KeyData ==
Keys
.Right || e.KeyData ==
Keys
.Down && splitterFocused) {
1199
if (e.KeyData ==
Keys
.Right || e.KeyData ==
Keys
.Down ||
1200
e.KeyData ==
Keys
.Left || e.KeyData ==
Keys
.Up
2407
protected override bool ProcessDialogKey(
Keys
keyData) {
2411
if ((keyData & (
Keys
.Alt |
Keys
.Control)) ==
Keys
.None) {
2412
Keys
keyCode = (
Keys
)keyData &
Keys
.KeyCode;
2414
case
Keys
.Tab:
2415
if (ProcessTabKey((keyData &
Keys
.Shift) ==
Keys
.None)) return true;
2417
case
Keys
.Left:
2418
case
Keys
.Right:
2419
case
Keys
.Up:
2420
case
Keys
.Down:
2422
if (ProcessArrowKey(keyCode ==
Keys
.Right ||
2423
keyCode ==
Keys
.Down)) return true;
2550
if ((m.Msg == NativeMethods.WM_KEYDOWN && (int)m.WParam == (int)
Keys
.Escape)
winforms\Managed\System\WinForms\Splitter.cs (2)
868
if (splitTarget != null && e.KeyCode ==
Keys
.Escape) {
1086
if (m.Msg == NativeMethods.WM_KEYDOWN && unchecked((int)(long)m.WParam) == (int)
Keys
.Escape) {
winforms\Managed\System\WinForms\TabControl.cs (15)
1319
protected override bool IsInputKey(
Keys
keyData) {
1320
if ((keyData &
Keys
.Alt) ==
Keys
.Alt) return false;
1321
switch (keyData &
Keys
.KeyCode) {
1322
case
Keys
.PageUp:
1323
case
Keys
.PageDown:
1324
case
Keys
.Home:
1325
case
Keys
.End:
1477
if (ke.KeyCode ==
Keys
.Tab && (ke.KeyData &
Keys
.Control) !=0) {
1478
bool forward = (ke.KeyData &
Keys
.Shift) == 0;
1481
if (ke.KeyCode ==
Keys
.PageDown && (ke.KeyData &
Keys
.Control) !=0) {
1484
if (ke.KeyCode ==
Keys
.PageUp && (ke.KeyData &
Keys
.Control) !=0) {
winforms\Managed\System\WinForms\TextBox.cs (7)
585
protected override bool IsInputKey(
Keys
keyData) {
586
if (Multiline && (keyData &
Keys
.Alt) == 0) {
587
switch (keyData &
Keys
.KeyCode) {
588
case
Keys
.Return:
712
protected override bool ProcessCmdKey(ref Message m,
Keys
keyData) {
715
&& this.ShortcutsEnabled && (keyData == (
Keys
.Control |
Keys
.A))) {
winforms\Managed\System\WinForms\TextBoxBase.cs (23)
196
(int)Shortcut.CtrlE, (int)Shortcut.CtrlY, (int)
Keys
.Control + (int)
Keys
.Back,
208
protected override bool ProcessCmdKey(ref Message msg,
Keys
keyData) {
216
(int)keyData == (shortcutValue | (int)
Keys
.Shift)) {
1519
protected override bool IsInputKey(
Keys
keyData) {
1520
if ((keyData &
Keys
.Alt) !=
Keys
.Alt) {
1521
switch (keyData &
Keys
.KeyCode) {
1522
case
Keys
.Tab:
1525
return Multiline && textBoxFlags[acceptsTab] && ((keyData &
Keys
.Control) == 0);
1526
case
Keys
.Escape:
1530
case
Keys
.Back:
1534
case
Keys
.PageUp:
1535
case
Keys
.PageDown:
1536
case
Keys
.Home:
1537
case
Keys
.End:
1599
protected override bool ProcessDialogKey(
Keys
keyData) {
1601
Keys
keyCode = (
Keys
)keyData &
Keys
.KeyCode;
1603
if (keyCode ==
Keys
.Tab && this.AcceptsTab && (keyData &
Keys
.Control) != 0) {
1605
keyData &= ~
Keys
.Control;
winforms\Managed\System\WinForms\ToolStrip.cs (35)
2736
protected override bool IsInputKey(
Keys
keyData) {
2831
internal bool ProcessCmdKeyInternal(ref Message m,
Keys
keyData) {
2861
protected override bool ProcessCmdKey(ref Message m,
Keys
keyData) {
2894
(keyData &
Keys
.Control) ==
Keys
.Control && (keyData &
Keys
.KeyCode) ==
Keys
.Tab;
2898
if ((keyData &
Keys
.Shift) ==
Keys
.None) {
2923
protected override bool ProcessDialogKey(
Keys
keyData) {
2937
bool hasModifiers = ((keyData & (
Keys
.Alt |
Keys
.Control)) !=
Keys
.None);
2939
Keys
keyCode = (
Keys
)keyData &
Keys
.KeyCode;
2941
case
Keys
.Back:
2949
case
Keys
.Tab:
2952
retVal = ProcessTabKey((keyData &
Keys
.Shift) ==
Keys
.None);
2955
case
Keys
.Left:
2956
case
Keys
.Right:
2957
case
Keys
.Up:
2958
case
Keys
.Down:
2961
case
Keys
.Home:
2965
case
Keys
.End:
2969
case
Keys
.Escape: // escape and menu key should restore focus
3021
if (!inMenuMode && Control.ModifierKeys ==
Keys
.Alt) {
3179
internal virtual bool ProcessArrowKey(
Keys
keyCode) {
3186
case
Keys
.Left:
3187
case
Keys
.Right:
3188
retVal = ProcessLeftRightArrowKey(keyCode ==
Keys
.Right);
3190
case
Keys
.Up:
3191
case
Keys
.Down:
3194
if (keyCode ==
Keys
.Down) {
winforms\Managed\System\WinForms\ToolStripComboBox.cs (7)
749
protected override bool IsInputKey(
Keys
keyData) {
750
if ((keyData &
Keys
.Alt) ==
Keys
.Alt) {
751
if ((keyData &
Keys
.Down) ==
Keys
.Down || (keyData &
Keys
.Up) ==
Keys
.Up) {
winforms\Managed\System\WinForms\ToolStripControlHost.cs (2)
998
protected internal override bool ProcessCmdKey(ref Message m,
Keys
keyData) {
1016
protected internal override bool ProcessDialogKey(
Keys
keyData) {
winforms\Managed\System\WinForms\ToolStripDropDown.cs (8)
1517
internal override bool ProcessArrowKey(
Keys
keyCode) {
1523
if (keyCode ==
Keys
.Left || keyCode ==
Keys
.Right) {
1526
bool forward = (keyCode ==
Keys
.Left && rightAligned) || (keyCode ==
Keys
.Right && !rightAligned);
1577
protected override bool ProcessDialogKey(
Keys
keyData) {
1595
else if ((keyData &
Keys
.KeyCode) ==
Keys
.Escape) {
winforms\Managed\System\WinForms\ToolStripDropDownButton.cs (2)
126
if ((Control.ModifierKeys !=
Keys
.Alt) &&
142
if ((Control.ModifierKeys !=
Keys
.Alt) &&
winforms\Managed\System\WinForms\ToolStripDropDownItem.cs (15)
535
protected internal override bool ProcessCmdKey(ref Message m,
Keys
keyData) {
545
protected internal override bool ProcessDialogKey(
Keys
keyData) {
546
Keys
keyCode = (
Keys
)keyData &
Keys
.KeyCode;
554
if (isToplevel && (keyCode ==
Keys
.Down || keyCode ==
Keys
.Up || keyCode ==
Keys
.Enter || (SupportsSpaceKey && keyCode ==
Keys
.Space))) {
573
bool forward = ((keyCode ==
Keys
.Enter) || (SupportsSpaceKey && keyCode ==
Keys
.Space));
574
forward = (forward || (menusCascadeRight && keyCode ==
Keys
.Left) || (!menusCascadeRight && keyCode ==
Keys
.Right));
597
bool backward = ((menusCascadeRight && keyCode ==
Keys
.Right) || (!menusCascadeRight && keyCode ==
Keys
.Left));
winforms\Managed\System\WinForms\ToolStripGrip.cs (1)
129
return (Control.MouseButtons == MouseButtons.Left) && (Control.ModifierKeys ==
Keys
.None);
winforms\Managed\System\WinForms\ToolStripItem.cs (7)
2492
if (Control.ModifierKeys ==
Keys
.Alt) {
2787
protected internal virtual bool IsInputKey(
Keys
keyData) {
2855
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.LButton) < 0) {
3431
protected internal virtual bool ProcessDialogKey(
Keys
keyData) {
3433
if (keyData ==
Keys
.Enter || (state[stateSupportsSpaceKey] && keyData ==
Keys
.Space)) {
3450
protected internal virtual bool ProcessCmdKey(ref Message m,
Keys
keyData) {
winforms\Managed\System\WinForms\ToolStripManager.cs (32)
982
Keys
keyData = (
Keys
)(int)m.WParam;
1475
public static bool IsValidShortcut(
Keys
shortcut) {
1478
Keys
keyCode = (
Keys
)(shortcut &
Keys
.KeyCode);
1479
Keys
modifiers = (
Keys
)(shortcut &
Keys
.Modifiers);
1481
if (shortcut ==
Keys
.None) {
1484
else if ((keyCode ==
Keys
.Delete) || (keyCode ==
Keys
.Insert)) {
1487
else if (((int)keyCode >= (int)
Keys
.F1) && ((int)keyCode <= (int)
Keys
.F24)) {
1491
else if ((keyCode !=
Keys
.None) && (modifiers !=
Keys
.None)) {
1493
case
Keys
.Menu:
1494
case
Keys
.ControlKey:
1495
case
Keys
.ShiftKey:
1499
if (modifiers ==
Keys
.Shift) {
1510
internal static bool IsMenuKey(
Keys
keyData) {
1511
Keys
keyCode = keyData &
Keys
.KeyCode;
1512
return (
Keys
.Menu == keyCode ||
Keys
.F10 == keyCode);
1515
public static bool IsShortcutDefined(
Keys
shortcut) {
1529
internal static bool ProcessCmdKey(ref Message m,
Keys
keyData) {
1555
internal static bool ProcessShortcut(ref Message m,
Keys
shortcut) {
1698
Keys
keyData = (
Keys
)(int)m.LParam;
1734
if (UnsafeNativeMethods.GetKeyState((int)
Keys
.ShiftKey) < 0 && (keyData ==
Keys
.None)) {
winforms\Managed\System\WinForms\ToolStripMenuItem.cs (17)
95
public ToolStripMenuItem(string text, Image image, EventHandler onClick,
Keys
shortcutKeys):base(text,image,onClick) {
470
DefaultValue(
Keys
.None),
473
public
Keys
ShortcutKeys {
477
return (found) ? (
Keys
)shortcutKeys :
Keys
.None;
480
if ((value !=
Keys
.None) && !ToolStripManager.IsValidShortcut(value)){
482
throw new InvalidEnumArgumentException("value", (int)value, typeof(
Keys
));
484
Keys
originalShortcut = ShortcutKeys;
490
if (originalShortcut !=
Keys
.None) {
688
Keys
shortcut = this.ShortcutKeys;
689
if (shortcut !=
Keys
.None && lastOwner.Shortcuts.ContainsKey(shortcut)) {
1030
Keys
shortcut = this.ShortcutKeys;
1031
if (shortcut !=
Keys
.None) {
1149
protected internal override bool ProcessCmdKey(ref Message m,
Keys
keyData) {
1210
internal static string ShortcutToText(
Keys
shortcutKeys, string shortcutKeyDisplayString) {
1214
else if (shortcutKeys ==
Keys
.None) {
1218
return TypeDescriptor.GetConverter(typeof(
Keys
)).ConvertToString(shortcutKeys);
winforms\Managed\System\WinForms\ToolStripSplitButton.cs (3)
446
protected internal override bool ProcessDialogKey(
Keys
keyData) {
447
if (Enabled && (keyData ==
Keys
.Enter || (SupportsSpaceKey && keyData ==
Keys
.Space))) {
winforms\Managed\System\WinForms\TrackBar.cs (10)
905
protected override bool IsInputKey(
Keys
keyData) {
906
if ((keyData &
Keys
.Alt) ==
Keys
.Alt) return false;
907
switch (keyData &
Keys
.KeyCode) {
908
case
Keys
.PageUp:
909
case
Keys
.PageDown:
910
case
Keys
.Home:
911
case
Keys
.End:
980
if ((ModifierKeys & (
Keys
.Shift |
Keys
.Alt)) != 0 || MouseButtons != MouseButtons.None) {
winforms\Managed\System\WinForms\TreeView.cs (13)
1928
protected override bool IsInputKey(
Keys
keyData) {
1932
if (editNode != null && (keyData &
Keys
.Alt) == 0) {
1933
switch (keyData &
Keys
.KeyCode) {
1934
case
Keys
.Return:
1935
case
Keys
.Escape:
1936
case
Keys
.PageUp:
1937
case
Keys
.PageDown:
1938
case
Keys
.Home:
1939
case
Keys
.End:
2322
if (CheckBoxes && (e.KeyData &
Keys
.KeyCode) ==
Keys
.Space) {
2345
if ((e.KeyData &
Keys
.KeyCode) ==
Keys
.Space) {
winforms\Managed\System\WinForms\UpDownBase.cs (5)
870
if (e.KeyData ==
Keys
.Up) {
876
else if (e.KeyData ==
Keys
.Down) {
884
if (e.KeyCode ==
Keys
.Return && UserEdit) {
996
if ((ModifierKeys & (
Keys
.Shift |
Keys
.Alt)) != 0 || MouseButtons != MouseButtons.None) {
winforms\Managed\System\WinForms\WebBrowserBase.cs (1)
270
protected override bool ProcessDialogKey(
Keys
keyData)
System.Workflow.Activities (20)
Rules\Design\Dialogs\IntellisenseTextBox.cs (18)
107
IntellisenseTextBox_KeyDown(sender, new KeyEventArgs(
Keys
.Down)); // fake down arrow to select first item
132
IntellisenseTextBox_KeyDown(sender, new KeyEventArgs(
Keys
.Down)); // fake down arrow to select first item
155
if (e.KeyData == (
Keys
.Control |
Keys
.Space))
166
else if (e.KeyCode ==
Keys
.Back)
186
else if (e.KeyCode ==
Keys
.Up)
199
else if (e.KeyCode ==
Keys
.Down)
219
else if (e.KeyCode ==
Keys
.ShiftKey
220
|| e.KeyCode ==
Keys
.ControlKey
221
|| e.KeyCode ==
Keys
.OemPeriod)
226
e.KeyData != (
Keys
.Shift |
Keys
.OemMinus))
230
if (e.KeyCode ==
Keys
.Return || e.KeyCode ==
Keys
.Space)
609
protected override bool ProcessCmdKey(ref Message msg,
Keys
keyData)
616
case
Keys
.Enter:
617
case
Keys
.Tab:
621
case
Keys
.Escape:
Rules\Design\Dialogs\RuleSetDialog.cs (2)
537
protected override bool ProcessCmdKey(ref Message msg,
Keys
keyData)
539
if (keyData.Equals(
Keys
.Escape))
System.Workflow.ComponentModel (69)
AuthoringOM\Design\CommandSet.cs (15)
551
SendKeyDownCommand(
Keys
.Enter);
555
private bool SendKeyDownCommand(
Keys
key)
587
Keys
key =
Keys
.Left;
590
key =
Keys
.Down;
592
key =
Keys
.Up;
594
key =
Keys
.Left;
596
key =
Keys
.Right;
598
key =
Keys
.Tab;
600
{ key =
Keys
.Tab |
Keys
.Shift; }
702
SendKeyDownCommand(
Keys
.Escape);
708
SendKeyDownCommand((menuCommand.CommandID == WorkflowMenuCommands.PageUp) ?
Keys
.PageUp :
Keys
.PageDown);
967
SendKeyDownCommand(
Keys
.Delete);
AuthoringOM\Design\CompositeActivityDesigner.cs (6)
1359
if (e.KeyCode ==
Keys
.Down ||
1360
(e.KeyCode ==
Keys
.Tab && !e.Shift))
1387
else if (e.KeyCode ==
Keys
.Up ||
1388
(e.KeyCode ==
Keys
.Tab && e.Shift))
1420
else if (e.KeyCode ==
Keys
.Left)
1435
else if (e.KeyCode ==
Keys
.Right)
AuthoringOM\Design\DesignerWidgets.cs (6)
1128
if (e.KeyCode ==
Keys
.Enter)
1142
else if (e.KeyCode ==
Keys
.Escape)
1146
else if (e.KeyCode ==
Keys
.Up || e.KeyCode ==
Keys
.Down)
1156
if (e.KeyCode ==
Keys
.Up)
1158
else if (e.KeyCode ==
Keys
.Down)
AuthoringOM\Design\Dialogs\ActivityBindForm.cs (1)
961
if (e.KeyCode ==
Keys
.F2 && base.TreeView.SelectedNode != null)
AuthoringOM\Design\Dialogs\TypeBrowserDialog.cs (2)
525
protected override bool ProcessCmdKey(ref Message msg,
Keys
keyData)
527
if (keyData ==
Keys
.Enter)
AuthoringOM\Design\FreeFormDesigner.cs (9)
967
if (e.KeyCode ==
Keys
.Left || e.KeyCode ==
Keys
.Right || e.KeyCode ==
Keys
.Up || e.KeyCode ==
Keys
.Down)
972
if (e.KeyCode ==
Keys
.Left)
974
else if (e.KeyCode ==
Keys
.Right)
976
else if (e.KeyCode ==
Keys
.Up)
978
else if (e.KeyCode ==
Keys
.Down)
999
else if (e.KeyCode ==
Keys
.Delete)
AuthoringOM\Design\MessageFilters\ConnectionManager.cs (1)
219
if (EditingInProgress && eventArgs.KeyValue == (int)
Keys
.Escape)
AuthoringOM\Design\MessageFilters\DragDropManager.cs (1)
196
if (eventArgs.KeyValue == (int)
Keys
.Escape)
AuthoringOM\Design\MessageFilters\DragSelectionMessageFilter.cs (5)
109
if (eventArgs.KeyValue == (int)
Keys
.Escape)
187
if ((Control.ModifierKeys &
Keys
.Shift) > 0)
197
if ((Control.ModifierKeys &
Keys
.Shift) > 0)
207
if ((Control.ModifierKeys &
Keys
.Shift) > 0)
233
if ((Control.ModifierKeys &
Keys
.Shift) == 0)
AuthoringOM\Design\MessageFilters\PanningMessageFilter.cs (1)
97
if (eventArgs.KeyValue == (int)
Keys
.Escape)
AuthoringOM\Design\MessageFilters\ResizingMessageFilter.cs (1)
97
if (eventArgs.KeyValue == (int)
Keys
.Escape && this.designerToResize != null)
AuthoringOM\Design\MessageFilters\WindowManager.cs (15)
66
if (this.currentActiveDesigner != null && ((Control.ModifierKeys & (
Keys
.Control |
Keys
.Shift)) == 0))
224
if (eventArgs != null && (eventArgs.KeyCode ==
Keys
.PageUp || eventArgs.KeyCode ==
Keys
.PageDown))
225
UpdateViewOnPageUpDown(eventArgs.KeyCode ==
Keys
.PageUp);
229
if (eventArgs.KeyCode ==
Keys
.Enter)
239
else if (eventArgs.KeyCode ==
Keys
.Escape)
250
else if (eventArgs.KeyCode ==
Keys
.Delete)
295
else if (eventArgs.KeyCode ==
Keys
.Left || eventArgs.KeyCode ==
Keys
.Right || eventArgs.KeyCode ==
Keys
.Up || eventArgs.KeyCode ==
Keys
.Down || eventArgs.KeyCode ==
Keys
.Tab)
419
private void UpdateViewOnMouseWheel(MouseEventArgs eventArgs,
Keys
modifierKeys)
422
if (Control.ModifierKeys ==
Keys
.Control)
AuthoringOM\Design\MessageFilters\ZoomingMessageFilter.cs (5)
82
this.currentState = ((Control.ModifierKeys &
Keys
.Shift) != 0) ? ((this.initialState == ZoomState.In) ? ZoomState.Out : ZoomState.In) : this.initialState;
128
if (eventArgs.KeyValue == (int)
Keys
.Escape)
134
this.currentState = ((eventArgs.Modifiers &
Keys
.Shift) != 0) ? ((this.initialState == ZoomState.In) ? ZoomState.Out : ZoomState.In) : this.initialState;
142
this.currentState = ((eventArgs.Modifiers &
Keys
.Shift) != 0) ? ((this.initialState == ZoomState.In) ? ZoomState.Out : ZoomState.In) : this.initialState;
190
this.currentState = ((Control.ModifierKeys &
Keys
.Shift) != 0) ? ((this.initialState == ZoomState.In) ? ZoomState.Out : ZoomState.In) : this.initialState;
AuthoringOM\Design\WorkflowView.cs (1)
2230
KeyEventArgs eventArgs = new KeyEventArgs((
Keys
)(unchecked((int)(long)m.WParam)) | ModifierKeys);
System.WorkflowServices (1)
System\Workflow\Activities\Design\ServiceOperationDetailViewControl.cs (1)
399
if (e.KeyCode ==
Keys
.Delete && this.RemoveParameterButton.Enabled)