This MR ensures that document mode isn't updated on the wrong document when a DOMContentLoaded event occurs. This is done by always using the event target dispex (instead of the dispex associated with doc associated with the event listener).
This fixes the launcher for Swords of Legends Online.
-- v5: mshtml: Don't handle special case when doc != node->doc. mshtml: Always use the event target dispex. mshtml/tests: Add test for document mode after InitNew and Load. mshtml: Use generic event dispatcher for DOMContentLoaded. mshtml: Pass DOMEvent instead of nsIDOMEvent during handle_event.