You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The problem is that the script code is racing with layout, which may not have finished yet. At minimum you'll need to call Node::wait_until_safe_to_modify_dom, which will block until any pending layout operations are complete.
@pcwalton@metajack@kmcallister Hi! Do you know how to extract the layout information from the layout task in the script? The query_layout can't return the things I want. I want display, content, border, padding, etc.
Activity
lpy commentedon Feb 20, 2014
I will work on this one.
lpy commentedon Mar 9, 2014
I have a question about the
get_css_select_results.The
get_css_select_resultsI implement inNodeThe
SharedLayoutDataI implement instyle.Then I change the
styleinPrivateLayoutDatatoshared_style: SharedLayoutDataThe problem is that the
get_ref()inget_css_select_resultswill returnNone.The test code is
I am still trying to figure it out. Any idea? Thank you.
Please see my patch here
lpy commentedon Mar 9, 2014
By the way, I did have one time that the code work.
lpy commentedon Mar 9, 2014
Also, the
alert(div.style)returnsundefined.jdm commentedon Mar 9, 2014
The problem is that the script code is racing with layout, which may not have finished yet. At minimum you'll need to call
Node::wait_until_safe_to_modify_dom, which will block until any pending layout operations are complete.jdm commentedon Mar 9, 2014
The unimplemented style property is tracked in #1721.
lpy commentedon Mar 9, 2014
It didn't work to me.
lpy commentedon Mar 9, 2014
Error message:
lpy commentedon Mar 9, 2014
I called
wait_until_safe_to_modify_dombefore theunsafeblock inget_css_select_results.jdm commentedon Mar 9, 2014
Can you push your code to a branch?
lpy commentedon Mar 9, 2014
Oh this one https://github.com/lpy/servo/commit/7bcf245f3f84c9efb2b41e8045eb45969c3533b9
lpy commentedon Mar 11, 2014
@pcwalton @metajack @kmcallister Hi! Do you know how to extract the layout information from the layout task in the script? The
query_layoutcan't return the things I want. I wantdisplay,content,border,padding, etc.jdm commentedon Mar 11, 2014
@lpy You can create a new message to send via query_layout and calculate whatever you need. You don't have to rely on existing message types.
jdm commentedon Apr 1, 2014
Are you still working on this, @lpy?
frewsxcv commentedon Jul 28, 2015
Was this completed in #6797?
/cc @glennw
jdm commentedon Jul 28, 2015
Yep!