Tuesday, July 17, 2012

Re: Document.get().isOrHasChild(element) != isAttached() in CHrome ??

Thanks Thomas for ur feedback.
I am still using FF 6.0 (because of the plugin hassle)  ;)... I am just about to push a test release and then have planned to update FF and it's plugin....
I will test it again then... (also with  Document.get().getBody().isOrHasChild(widget.getElement()) )
To be continued...

On Tue, Jul 17, 2012 at 4:57 PM, Thomas Broyer <t.broyer@gmail.com> wrote:


On Tuesday, July 17, 2012 2:06:41 PM UTC+2, Ed wrote:
I show a widget in a popup: it's added to the RootPanel and then in a deferred command I noticed that in Chrome the Widget is attached (Widget.isAttached() method equals true) but when calling Document.get().isOrHasChild(widget.getElement()) it returns false.... I think this should be true also, just like I see in Firefox.

Any idea's why this is false in Chrome?


This is strange, isOrHasChild uses contains(), and document.contains(someElt) returns true for me in Chrome Dev Tools.
Note that Firefox uses a different code, based on http://www.quirksmode.org/blog/archives/2006/01/contains_for_mo.html (Node.contains has only been added in Firefox 9, according to the MDN https://developer.mozilla.org/en/DOM/Node.contains ), so it's not really a surprise that it returns a different value.

Have you tried Document.get().getBody().isOrHasChild(widget.getElement()) ?

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To view this discussion on the web visit https://groups.google.com/d/msg/google-web-toolkit/-/wkPFiXpViVUJ.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to google-web-toolkit+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to google-web-toolkit+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate