RAD Studio VCL Reference
TCustomActionList.IsShortCut Method

Evaluates an input key combination to determine whether it is a shortcut for one of the actions in the list.

function IsShortCut(var Message: TWMKey): Boolean;
__fastcall Boolean IsShortCut(TWMKey Message);

Typically, applications do not need to call IsShortCut. When the form's IsShortCut method does not evaluate a shortcut key by some other means (such as an event handler), it calls IsShortCut for every associated action list until it finds one that can handle the shortcut. 

The action list's IsShortCut method, in turn, checks the specified keystroke against the ShortCut property and SecondaryShortCuts properties of each action in the list. If it finds a match, it tells the action to handle the shortcut, and then returns true. If IsShortCut can't find an action to handle the shortcut, it returns false. 

Message encapsulates the Windows keystroke message that is to be checked to see if it is a shortcut.  

Key is the key code for the potential shortcut key.  

Shift specifies the state of the Shift, Alt, and Ctrl keys that may be combined with Key.  

KeyText is the string representation of the potential shortcut key. 


Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!