[Webkit-unassigned] [Bug 51382] [Chromium] Fix popup menu re-positioning when the menu is opened upward, above the corresponding form field.
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri Jan 7 00:00:55 PST 2011
https://bugs.webkit.org/show_bug.cgi?id=51382
--- Comment #33 from Ilya Sherman <isherman at chromium.org> 2011-01-07 00:00:53 PST ---
Apologies for the delay in responding.
(In reply to comment #24)
> (From update of attachment 77302 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=77302&action=review
>
> Yes, "calculateWidgetRect()" has side effect. Because the function uses "layout()". So do you imply I should make "calculateWidgetRect()" have no side effect?
I think either it should have no side effect, or it should have a name that makes it clearer that there will be a side effect.
> > WebCore/platform/chromium/PopupMenuChromium.cpp:369
> > + widgetRect = chromeClient->windowToScreen(windowRect);
>
> I need more investigation. Because "layout()" has side effect and widgetRect might be change according to "layout()" call. The original code also recalculate here, so that's why I remained this line.
I also didn't investigate closely -- it just looked rather surprising when reading the code. If you find that you need to leave this in place, please add a brief comment explaining why it's needed =)
> > WebCore/platform/chromium/PopupMenuChromium.h:215
> > };
>
> m_popupRect is different from frameRect().
> Because frameRect() is variable according to setFrameRect().
> But this m_popupRect is saved as the first original position and rect of input text position.
>
> Or do you mean other problem?
Again, I didn't try making this change, but it strikes me as odd that we need to cache the input text field's position. It seems like we should be able to query the position directly from the input text field when we need it, though it might be that there's no (clean/easy) way to do that.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list