[Webkit-unassigned] [Bug 36373] [Qt] Don't construct a QLineEdit every time when painting a text field

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Mar 21 15:40:43 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=36373


Simon Hausmann <hausmann at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #51163|review?                     |review-
               Flag|                            |




--- Comment #2 from Simon Hausmann <hausmann at webkit.org>  2010-03-21 15:40:43 PST ---
(From update of attachment 51163)
Good catch Jakub!!

It really sucks that we have to create a QLineEdit instance in the first place
:-(, but I understand that this is a flaw in the QStyle API.

Instead of creating a global QLineEdit that runs the risk of being destructed
after the QApplication destructor, how about assocating it with the
RenderTheme? Then it would be destroyed when the page dies.

Alternatively you could _cache_ the frame width in the RenderThemeQt as a
member variable and initialize it through a temporary QLineEdit instance the
first time it's queried.

It's not perfect as it wouldn't follow style changes, but it's a start :)

I'm going to say r- because I believe we should destroy the QLineEdit instance
earlier. But otherwise a great catch!

-- 
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