mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 895274 part.155 Rename NS_QUERY_EDITOR_RECT to eQueryEditorRect r=smaug
This commit is contained in:
parent
fbd749e023
commit
bf019a5307
@ -1939,7 +1939,7 @@ nsDOMWindowUtils::SendQueryContentEvent(uint32_t aType,
|
||||
message = NS_QUERY_TEXT_RECT;
|
||||
break;
|
||||
case QUERY_EDITOR_RECT:
|
||||
message = NS_QUERY_EDITOR_RECT;
|
||||
message = eQueryEditorRect;
|
||||
break;
|
||||
case QUERY_CHARACTER_AT_POINT:
|
||||
message = NS_QUERY_CHARACTER_AT_POINT;
|
||||
|
@ -59,7 +59,7 @@ static bool IsRectEnabled(EventMessage aEventMessage)
|
||||
{
|
||||
return aEventMessage == eQueryCaretRect ||
|
||||
aEventMessage == NS_QUERY_TEXT_RECT ||
|
||||
aEventMessage == NS_QUERY_EDITOR_RECT ||
|
||||
aEventMessage == eQueryEditorRect ||
|
||||
aEventMessage == NS_QUERY_CHARACTER_AT_POINT;
|
||||
}
|
||||
|
||||
|
@ -804,7 +804,7 @@ ContentEventHandler::HandleQueryContentEvent(WidgetQueryContentEvent* aEvent)
|
||||
return OnQueryCaretRect(aEvent);
|
||||
case NS_QUERY_TEXT_RECT:
|
||||
return OnQueryTextRect(aEvent);
|
||||
case NS_QUERY_EDITOR_RECT:
|
||||
case eQueryEditorRect:
|
||||
return OnQueryEditorRect(aEvent);
|
||||
case NS_QUERY_CONTENT_STATE:
|
||||
return OnQueryContentState(aEvent);
|
||||
|
@ -50,7 +50,7 @@ public:
|
||||
nsresult OnQueryCaretRect(WidgetQueryContentEvent* aEvent);
|
||||
// NS_QUERY_TEXT_RECT event handler
|
||||
nsresult OnQueryTextRect(WidgetQueryContentEvent* aEvent);
|
||||
// NS_QUERY_EDITOR_RECT event handler
|
||||
// eQueryEditorRect event handler
|
||||
nsresult OnQueryEditorRect(WidgetQueryContentEvent* aEvent);
|
||||
// NS_QUERY_CONTENT_STATE event handler
|
||||
nsresult OnQueryContentState(WidgetQueryContentEvent* aEvent);
|
||||
|
@ -789,7 +789,7 @@ EventStateManager::HandleQueryContentEvent(WidgetQueryContentEvent* aEvent)
|
||||
case eQueryTextContent:
|
||||
case eQueryCaretRect:
|
||||
case NS_QUERY_TEXT_RECT:
|
||||
case NS_QUERY_EDITOR_RECT:
|
||||
case eQueryEditorRect:
|
||||
if (!IsTargetCrossProcess(aEvent)) {
|
||||
break;
|
||||
}
|
||||
|
@ -59,8 +59,8 @@ ToChar(EventMessage aEventMessage)
|
||||
return "eQueryCaretRect";
|
||||
case NS_QUERY_TEXT_RECT:
|
||||
return "NS_QUERY_TEXT_RECT";
|
||||
case NS_QUERY_EDITOR_RECT:
|
||||
return "NS_QUERY_EDITOR_RECT";
|
||||
case eQueryEditorRect:
|
||||
return "eQueryEditorRect";
|
||||
case NS_QUERY_CONTENT_STATE:
|
||||
return "NS_QUERY_CONTENT_STATE";
|
||||
case eQuerySelectionAsTransferable:
|
||||
|
@ -2371,7 +2371,7 @@ TabParent::HandleQueryContentEvent(WidgetQueryContentEvent& aEvent)
|
||||
switch (aEvent.mMessage) {
|
||||
case NS_QUERY_TEXT_RECT:
|
||||
case eQueryCaretRect:
|
||||
case NS_QUERY_EDITOR_RECT:
|
||||
case eQueryEditorRect:
|
||||
aEvent.mReply.mRect -= GetChildProcessOffset();
|
||||
break;
|
||||
default:
|
||||
|
@ -251,7 +251,7 @@ ContentCacheInChild::CacheEditorRect(nsIWidget* aWidget,
|
||||
this, aWidget, GetNotificationName(aNotification)));
|
||||
|
||||
nsEventStatus status = nsEventStatus_eIgnore;
|
||||
WidgetQueryContentEvent editorRectEvent(true, NS_QUERY_EDITOR_RECT, aWidget);
|
||||
WidgetQueryContentEvent editorRectEvent(true, eQueryEditorRect, aWidget);
|
||||
aWidget->DispatchEvent(&editorRectEvent, status);
|
||||
if (NS_WARN_IF(!editorRectEvent.mSucceeded)) {
|
||||
MOZ_LOG(sContentCacheLog, LogLevel::Error,
|
||||
@ -665,10 +665,10 @@ ContentCacheInParent::HandleQueryContentEvent(WidgetQueryContentEvent& aEvent,
|
||||
"Succeeded, aEvent={ mReply={ mOffset=%u, mRect=%s } }",
|
||||
this, aEvent.mReply.mOffset, GetRectText(aEvent.mReply.mRect).get()));
|
||||
break;
|
||||
case NS_QUERY_EDITOR_RECT:
|
||||
case eQueryEditorRect:
|
||||
MOZ_LOG(sContentCacheLog, LogLevel::Info,
|
||||
("ContentCacheInParent: 0x%p HandleQueryContentEvent("
|
||||
"aEvent={ mMessage=NS_QUERY_EDITOR_RECT }, aWidget=0x%p)",
|
||||
"aEvent={ mMessage=eQueryEditorRect }, aWidget=0x%p)",
|
||||
this, aWidget));
|
||||
aEvent.mReply.mRect = mEditorRect;
|
||||
MOZ_LOG(sContentCacheLog, LogLevel::Info,
|
||||
|
@ -298,7 +298,7 @@ public:
|
||||
*
|
||||
* For eQueryCaretRect, fail if cached offset isn't equals to input
|
||||
*
|
||||
* For NS_QUERY_EDITOR_RECT, always success
|
||||
* For eQueryEditorRect, always success
|
||||
*/
|
||||
bool HandleQueryContentEvent(WidgetQueryContentEvent& aEvent,
|
||||
nsIWidget* aWidget) const;
|
||||
|
@ -229,7 +229,7 @@ NS_EVENT_MESSAGE(eQueryCaretRect, eQueryContentEventFirst + 3)
|
||||
NS_EVENT_MESSAGE(NS_QUERY_TEXT_RECT, eQueryContentEventFirst + 4)
|
||||
// Query for the bounding rect of the current focused frame. Result is relative
|
||||
// to top level widget coordinates
|
||||
NS_EVENT_MESSAGE(NS_QUERY_EDITOR_RECT, eQueryContentEventFirst + 5)
|
||||
NS_EVENT_MESSAGE(eQueryEditorRect, eQueryContentEventFirst + 5)
|
||||
// Query for the current state of the content. The particular members of
|
||||
// mReply that are set for each query content event will be valid on success.
|
||||
NS_EVENT_MESSAGE(NS_QUERY_CONTENT_STATE, eQueryContentEventFirst + 6)
|
||||
|
@ -1654,12 +1654,12 @@ IMMHandler::HandleQueryCharPosition(nsWindow* aWindow,
|
||||
|
||||
pCharPosition->cLineHeight = r.height;
|
||||
|
||||
WidgetQueryContentEvent editorRect(true, NS_QUERY_EDITOR_RECT, aWindow);
|
||||
WidgetQueryContentEvent editorRect(true, eQueryEditorRect, aWindow);
|
||||
aWindow->InitEvent(editorRect);
|
||||
aWindow->DispatchWindowEvent(&editorRect);
|
||||
if (NS_WARN_IF(!editorRect.mSucceeded)) {
|
||||
MOZ_LOG(gIMMLog, LogLevel::Error,
|
||||
("IMM: HandleQueryCharPosition, NS_QUERY_EDITOR_RECT failed"));
|
||||
("IMM: HandleQueryCharPosition, eQueryEditorRect failed"));
|
||||
::GetWindowRect(aWindow->GetWindowHandle(), &pCharPosition->rcDocument);
|
||||
} else {
|
||||
nsIntRect editorRectInWindow =
|
||||
@ -2376,13 +2376,13 @@ void
|
||||
IMMHandler::SetIMERelatedWindowsPosOnPlugin(nsWindow* aWindow,
|
||||
const IMEContext& aContext)
|
||||
{
|
||||
WidgetQueryContentEvent editorRectEvent(true, NS_QUERY_EDITOR_RECT, aWindow);
|
||||
WidgetQueryContentEvent editorRectEvent(true, eQueryEditorRect, aWindow);
|
||||
aWindow->InitEvent(editorRectEvent);
|
||||
aWindow->DispatchWindowEvent(&editorRectEvent);
|
||||
if (!editorRectEvent.mSucceeded) {
|
||||
MOZ_LOG(gIMMLog, LogLevel::Info,
|
||||
("IMM: SetIMERelatedWindowsPosOnPlugin, "
|
||||
"FAILED, due to NS_QUERY_EDITOR_RECT failure"));
|
||||
"FAILED, due to eQueryEditorRect failure"));
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -3695,13 +3695,13 @@ TSFTextStore::GetScreenExtInternal(RECT& aScreenExt)
|
||||
("TSF: 0x%p TSFTextStore::GetScreenExtInternal()", this));
|
||||
|
||||
// use NS_QUERY_EDITOR_RECT to get rect in system, screen coordinates
|
||||
WidgetQueryContentEvent event(true, NS_QUERY_EDITOR_RECT, mWidget);
|
||||
WidgetQueryContentEvent event(true, eQueryEditorRect, mWidget);
|
||||
mWidget->InitEvent(event);
|
||||
DispatchEvent(event);
|
||||
if (!event.mSucceeded) {
|
||||
MOZ_LOG(sTextStoreLog, LogLevel::Error,
|
||||
("TSF: 0x%p TSFTextStore::GetScreenExtInternal() FAILED due to "
|
||||
"NS_QUERY_EDITOR_RECT failure", this));
|
||||
"eQueryEditorRect failure", this));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user