Share via


IInputMethod3::InputContextChange (Compact 2013)

3/28/2014

This method handles notifications that the software-based input panel (SIP) sends when the input context changes.

Syntax

HRESULT InputContextChange(
  DWORD dwType,
  LPBYTE lpData,
    DWORD cbData
);

Parameters

  • dwType
    [in] Type of input context. An input context stores information about the status of the input environment. Accepted values are INPUTCONTEXT_INPUTSCOPES or INPUTCONTEXT_INPUTLANGUAGE (see Remarks).
  • lpData
    [in] Input context that the SIP driver specifies in the change notification. The value depends on dwType. If dwType is INPUTCONTEXT_INPUTSCOPES, lpData is a pointer to an InputScope array that contains the input scopes of the window currently in focus. If dwType is INPUTCONTEXT_INPUTLANGUAGE, lpData is a pointer to the locale identifier (LCID).
  • cbData
    [in] The size of information pointed to by lpData, in bytes. The value depends on dwType. If dwType is INPUTCONTEXT_INPUTSCOPES, cbData is the number of input scopes in the array that lpData points to multiplied by the size of InputScope. If dwType is INPUTCONTEXT_INPUTLANGUAGE, cbData equals the size of the LCID.

Return Value

Returns S_OK to indicate success; otherwise, returns the appropriate HRESULT value to indicate failure.

Remarks

The INPUTCONTEXT_INPUTSCOPES value indicates that the input context has changed to the input scopes of the window currently in focus. The INPUTCONTEXT_INPUTLANGUAGE value indicates that the input context change has changed to the input language.

The SIP driver calls this method only when the input context changes. If dwType is INPUTCONTEXT_INPUTSCOPES, the SIP sends the notification with updated input scopes when the focus changes to a different window. The SIP uses IIMCallback3::GetInputContext to get the current input context.

Requirements

Header

sip.h

Library

uuid.lib

sysgen

SYSGEN_SOFTKB

See Also

Reference

IInputMethod3