Opened 14 years ago
Closed 12 years ago
#429 closed defect (fixed)
IE9 Beta:Toolbar ( Main Menu) in TB Web doesn't display
Reported by: | yangte | Owned by: | Ted Yang |
---|---|---|---|
Priority: | P2 | Milestone: | 2.3 |
Component: | MapGuide | Version: | 2.0 |
Severity: | Major | Keywords: | |
Cc: | Browser: | Other | |
External ID: | 1377082 | Operating System: | Windows |
state: | New |
Description
Now the IE9 beta, Safari, Firefox and Chrome all support the script onload event (see the funsion.js line423 and 503), but the IE9 beta will trigger the event synchronously, so the "aLoadingScripts" which stores the scripts to be loaded will be changed before the "for loop sentence" is finished, that means once the onload event is triggered the execution will go to the event handler code, and the codes manipulated the same array, which caused half of the scripts not be loaded.
Attachments (1)
Change History (5)
by , 14 years ago
Attachment: | ticket429.patch added |
---|
comment:1 by , 14 years ago
follow-up: 3 comment:2 by , 14 years ago
That is interesting (the 'synchronous' behaviour) and actually seems like a bug (in IE9 beta) to me - its actually more multi-threaded than synchronous as the execution stack moves to an event handler before the current scope has completed. I don't think any other javascript engine interrupts the current execution stack to process events like this (i.e. multi-threaded javascript execution). It is actually one of the features of javascript engines that actually makes it possible to handle asynchronous execution without resorting to traditional multi-threaded techniques. In any case, the patch looks like a great way to handle this problem. I just worry about other code not being thread safe now ;)
comment:3 by , 14 years ago
Replying to pagameba:
That is interesting (the 'synchronous' behaviour) and actually seems like a bug (in IE9 beta) to me ....
I totally agree with you that it is a defect in IE9 beta, because it makes the code execution unpredictable. I have tested this code on latest released versions of Firefox, Safari and Chrome; none of them interrupts the current execution stack to process events.
comment:4 by , 12 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
the attachment is my solution: create a temp collection to store the loading script.