зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1176954 part.1 Child process should notify its parent process when it dispatches composition or selection event into the DOM tree r=smaug
This commit is contained in:
Родитель
6834ce768e
Коммит
0f0144595d
|
@ -265,6 +265,13 @@ parent:
|
|||
prio(urgent) sync EndIMEComposition(bool cancel)
|
||||
returns (bool noCompositionEvent, nsString composition);
|
||||
|
||||
/**
|
||||
* OnEventNeedingAckReceived() is called when a child process dispatches a
|
||||
* composition event or a selection event which is sent from the parent
|
||||
* process.
|
||||
*/
|
||||
prio(urgent) async OnEventNeedingAckReceived();
|
||||
|
||||
/**
|
||||
* Tells chrome to start plugin IME. If this results in a string getting
|
||||
* committed, the result is in aCommitted (otherwise aCommitted is empty).
|
||||
|
|
|
@ -2659,6 +2659,7 @@ TabChild::RecvKeyEvent(const nsString& aType,
|
|||
bool
|
||||
TabChild::RecvCompositionEvent(const WidgetCompositionEvent& event)
|
||||
{
|
||||
unused << SendOnEventNeedingAckReceived();
|
||||
WidgetCompositionEvent localEvent(event);
|
||||
localEvent.widget = mPuppetWidget;
|
||||
APZCCallbackHelper::DispatchWidgetEvent(localEvent);
|
||||
|
@ -2668,6 +2669,7 @@ TabChild::RecvCompositionEvent(const WidgetCompositionEvent& event)
|
|||
bool
|
||||
TabChild::RecvSelectionEvent(const WidgetSelectionEvent& event)
|
||||
{
|
||||
unused << SendOnEventNeedingAckReceived();
|
||||
WidgetSelectionEvent localEvent(event);
|
||||
localEvent.widget = mPuppetWidget;
|
||||
APZCCallbackHelper::DispatchWidgetEvent(localEvent);
|
||||
|
|
|
@ -2087,6 +2087,14 @@ TabParent::RecvNotifyIMEPositionChange(const ContentCache& aContentCache)
|
|||
return true;
|
||||
}
|
||||
|
||||
bool
|
||||
TabParent::RecvOnEventNeedingAckReceived()
|
||||
{
|
||||
// This is called when the child process receives WidgetCompositionEvent or
|
||||
// WidgetSelectionEvent.
|
||||
return true;
|
||||
}
|
||||
|
||||
bool
|
||||
TabParent::RecvRequestFocus(const bool& aCanRaise)
|
||||
{
|
||||
|
|
|
@ -177,6 +177,7 @@ public:
|
|||
virtual bool RecvNotifyIMEMouseButtonEvent(const widget::IMENotification& aEventMessage,
|
||||
bool* aConsumedByIME) override;
|
||||
virtual bool RecvNotifyIMEPositionChange(const ContentCache& aContentCache) override;
|
||||
virtual bool RecvOnEventNeedingAckReceived() override;
|
||||
virtual bool RecvEndIMEComposition(const bool& aCancel,
|
||||
bool* aNoCompositionEvent,
|
||||
nsString* aComposition) override;
|
||||
|
|
Загрузка…
Ссылка в новой задаче