Hi,
How do I track the containment relationship of the ports associated
with frames from within an extension? That probably makes no sense, so
an example might help :)
Chrome loads a page ("http://example.com") and this page contains an
iframe. The URLs for both the main page and the contents of the iframe
cause content scripts to load which are marked to "run_at"
"document_end". The content scripts connect back to the background
page, which will therefore receive two calls to "onConnect". The
"port" sent back doesn't give a lot of information, particularly since
the "tab" property for both the main content and the iframe is
identical.
How do I know which port refers to the iframe, and which refers to the
main content? In a way which avoid having to execute JS (potentially)
across domains?
This is for the chrome version of webdriver. One of the APIs allows a
user to select which frame is considered "active", and in order to do
this we need to understand which port is associated with which frame.
In addition, if a user opens a page that contains frames, we can't
currently tell which port is the main content and which is the
iframe's.
Regards,
Simon
--
Chromium Developers mailing list: [email protected]
View archives, change email options, or unsubscribe:
http://groups.google.com/group/chromium-dev