mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1234120 part.2 TSFTextStore should ignore unnecessary text and selection changes which are caused by composition r=m_kato
This commit is contained in:
parent
2cb5ab63e0
commit
d586464951
@ -4567,6 +4567,12 @@ TSFTextStore::OnTextChangeInternal(const IMENotification& aIMENotification)
|
||||
GetSinkMaskNameStr(mSinkMask).get(),
|
||||
GetBoolName(mComposition.IsComposing())));
|
||||
|
||||
if (textChangeData.mCausedByComposition) {
|
||||
// Ignore text change notifications caused by composition since it's
|
||||
// already been handled internally.
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
mDeferNotifyingTSF = false;
|
||||
|
||||
if (IsReadLocked()) {
|
||||
@ -4653,6 +4659,12 @@ TSFTextStore::OnSelectionChangeInternal(const IMENotification& aIMENotification)
|
||||
GetBoolName(mIsRecordingActionsWithoutLock),
|
||||
GetBoolName(mComposition.IsComposing())));
|
||||
|
||||
if (selectionChangeData.mCausedByComposition) {
|
||||
// Ignore selection change notifications caused by composition since it's
|
||||
// already been handled internally.
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
mDeferNotifyingTSF = false;
|
||||
|
||||
// A compositionstart event handler can change selection before actually
|
||||
|
Loading…
Reference in New Issue
Block a user