[Webkit-unassigned] [Bug 35125] [Qt] Web Inspector Does Not Highlight Elements
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Jan 19 07:38:38 PST 2011
https://bugs.webkit.org/show_bug.cgi?id=35125
Simon Hausmann <hausmann at webkit.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #74311|review? |review-
Flag| |
--- Comment #18 from Simon Hausmann <hausmann at webkit.org> 2011-01-19 07:38:37 PST ---
(From update of attachment 74311)
View in context: https://bugs.webkit.org/attachment.cgi?id=74311&action=review
r- because of the rect issue Antonio pointed out and because of the save() / restore() that should be optimized to not be executed in the common case when there is no highlighted node. Otherwise the patch is going in the right direction I'd say :)
> WebKit/qt/Api/qwebframe.cpp:415
> +#if ENABLE(INSPECTOR)
> + context->save();
> + frame->page()->inspectorController()->drawNodeHighlight(*context);
> + context->restore();
> +#endif
It appears that this code is in QWebFramePrivate::renderRelativeCoords. In the _common_ case we would now end up calling save() and restore() on the graphics context each time we render content, where _most_ of the time drawNodeHighlight() returns immediately. save() and restore() are expensive operations we should avoid if necessary.
I suggest to either add a function tin InspectorController that allows us to perform a check here to see if we need to call drawNodeHighlight() and only then do save() / restore() or alternatively change the implementation of drawNodeHighligh() to do the save() / restore() pair.
--
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