Condividi tramite


IVsWindowPane.TranslateAccelerator(MSG[]) Method

Definition

Handles the translation of special navigation keys.

public:
 int TranslateAccelerator(cli::array <Microsoft::VisualStudio::OLE::Interop::MSG> ^ lpmsg);
int TranslateAccelerator(std::Array <Microsoft::VisualStudio::OLE::Interop::MSG> const & lpmsg);
public int TranslateAccelerator (Microsoft.VisualStudio.OLE.Interop.MSG[] lpmsg);
abstract member TranslateAccelerator : Microsoft.VisualStudio.OLE.Interop.MSG[] -> int
Public Function TranslateAccelerator (lpmsg As MSG()) As Integer

Parameters

lpmsg
MSG[]

[in] Keyboard character or character combination to be handled.

Returns

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsWindowPane::TranslateAccelerator(  
   LPMSG lpmsg  
);  

This method is identical to the TranslateAccelerator. This provides you the opportunity to handle keyboard messages before they are dispatched to the window that has focus. For example, your window might have controls where the TAB key navigates from one to the next. To handle the TAB key properly, you need to intercept it before it is dispatched to the window. Often, there is no requirement to implement this method.

Applies to