Skip to content
This repository has been archived by the owner on Aug 4, 2022. It is now read-only.

Commit

Permalink
Bug 1377653 - part1: Get rid of WidgetKeyboardEvent::mInputMethodAppS…
Browse files Browse the repository at this point in the history
…tate r=smaug

WidgetKeyboardEvent::mInputMethodAppState was used by B2G for managing keyboard event propagation state between chrome process and IME process.  Therefore, we can remove it now.

MozReview-Commit-ID: 7BwvzE8VjIR
  • Loading branch information
masayuki-nakano committed Jul 1, 2017
1 parent b79f72b commit 021929c
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 19 deletions.
12 changes: 0 additions & 12 deletions widget/TextEvents.h
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,6 @@ class WidgetKeyboardEvent : public WidgetInputEvent
#endif // #ifdef XP_MACOSX
, mKeyNameIndex(KEY_NAME_INDEX_Unidentified)
, mCodeNameIndex(CODE_NAME_INDEX_UNKNOWN)
, mInputMethodAppState(eNotHandled)
, mIsRepeat(false)
, mIsComposing(false)
, mIsReserved(false)
Expand Down Expand Up @@ -183,7 +182,6 @@ class WidgetKeyboardEvent : public WidgetInputEvent
#endif // #ifdef XP_MACOSX
, mKeyNameIndex(KEY_NAME_INDEX_Unidentified)
, mCodeNameIndex(CODE_NAME_INDEX_UNKNOWN)
, mInputMethodAppState(eNotHandled)
, mIsRepeat(false)
, mIsComposing(false)
, mIsReserved(false)
Expand Down Expand Up @@ -290,15 +288,6 @@ class WidgetKeyboardEvent : public WidgetInputEvent
KeyNameIndex mKeyNameIndex;
// DOM KeyboardEvent.code
CodeNameIndex mCodeNameIndex;
// Indicates that the event is being handled by input method app
typedef uint8_t InputMethodAppStateType;
enum InputMethodAppState : InputMethodAppStateType
{
eNotHandled, // not yet handled by intput method app
eHandling, // being handled by intput method app
eHandled // handled by input method app
};
InputMethodAppState mInputMethodAppState;

// Indicates whether the event is generated by auto repeat or not.
// if this is keyup event, always false.
Expand Down Expand Up @@ -513,7 +502,6 @@ class WidgetKeyboardEvent : public WidgetInputEvent
Assign(aEvent.mNativeCharactersIgnoringModifiers);
mPluginTextEventString.Assign(aEvent.mPluginTextEventString);
#endif
mInputMethodAppState = aEvent.mInputMethodAppState;
mIsSynthesizedByTIP = aEvent.mIsSynthesizedByTIP;

// Don't copy mEditCommandsFor*Editor because it may require a lot of
Expand Down
7 changes: 0 additions & 7 deletions widget/nsGUIEventIPC.h
Original file line number Diff line number Diff line change
Expand Up @@ -446,9 +446,6 @@ struct ParamTraits<mozilla::WidgetKeyboardEvent>
WriteParam(aMsg, aParam.mLocation);
WriteParam(aMsg, aParam.mUniqueId);
WriteParam(aMsg, aParam.mIsSynthesizedByTIP);
WriteParam(aMsg,
static_cast<paramType::InputMethodAppStateType>
(aParam.mInputMethodAppState));
#ifdef XP_MACOSX
WriteParam(aMsg, aParam.mNativeKeyCode);
WriteParam(aMsg, aParam.mNativeModifierFlags);
Expand All @@ -472,7 +469,6 @@ struct ParamTraits<mozilla::WidgetKeyboardEvent>
{
mozilla::KeyNameIndexType keyNameIndex = 0;
mozilla::CodeNameIndexType codeNameIndex = 0;
paramType::InputMethodAppStateType inputMethodAppState = 0;
if (ReadParam(aMsg, aIter,
static_cast<mozilla::WidgetInputEvent*>(aResult)) &&
ReadParam(aMsg, aIter, &keyNameIndex) &&
Expand All @@ -489,7 +485,6 @@ struct ParamTraits<mozilla::WidgetKeyboardEvent>
ReadParam(aMsg, aIter, &aResult->mLocation) &&
ReadParam(aMsg, aIter, &aResult->mUniqueId) &&
ReadParam(aMsg, aIter, &aResult->mIsSynthesizedByTIP) &&
ReadParam(aMsg, aIter, &inputMethodAppState) &&
#ifdef XP_MACOSX
ReadParam(aMsg, aIter, &aResult->mNativeKeyCode) &&
ReadParam(aMsg, aIter, &aResult->mNativeModifierFlags) &&
Expand All @@ -510,8 +505,6 @@ struct ParamTraits<mozilla::WidgetKeyboardEvent>
aResult->mCodeNameIndex =
static_cast<mozilla::CodeNameIndex>(codeNameIndex);
aResult->mNativeKeyEvent = nullptr;
aResult->mInputMethodAppState =
static_cast<paramType::InputMethodAppState>(inputMethodAppState);
return true;
}
return false;
Expand Down

0 comments on commit 021929c

Please sign in to comment.