Summary: | forms cannot be accessed through implicit global variable definition | ||
---|---|---|---|
Product: | [Applications] konqueror | Reporter: | Oded Arbel <oded> |
Component: | khtml ecma | Assignee: | Maksim Orlovich <maksim> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | maksim |
Priority: | NOR | ||
Version: | 3.5 | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Attachments: |
testcase: cannot access form elements through implicitly defined global
testcase: can't override the implcit undefined reference patch Automateable testcase |
Description
Oded Arbel
2007-02-25 15:27:25 UTC
Created attachment 19812 [details]
testcase: cannot access form elements through implicitly defined global
Created attachment 19813 [details]
testcase: can't override the implcit undefined reference
The funny thing, is that I also can't override the implicit variable (that is
"undefined") - trying to set it to something (in this test case - to the
element itself) is futile and has no effect.
Thanks for the testcase, but, uhm, there are no w3c specs on window, so the behavior is as good as a reverse-engineering/emulation we can do of IE and FFox based on bug reports... You're right that something funny is happening here, though, will take a look.. Created attachment 19819 [details]
patch
This should fix it --- hasKey for HTMLDocument wasn't right for this case..
(And hence trunk shouldn't be affected). Not committing yet, since I can't
regtest this well atm..
Created attachment 19820 [details]
Automateable testcase
A TC likely suitable for regression testing --- does not require human
interaction..
Regarding comment #2 - this is an IE only emulation: Firefox/Gecko does not offer such a behavior. Additionally, while there isn't currently a W3 specification for window object, the working draft for Window 1.0 ( http://www.w3.org/TR/Window ) does not mention such a compatibility mode. Not that I'm saying it shouldn't be implemented, but it still shouldn't break valid scripts. Thanks for the patch, and I hope you can commit it to the 3.5 branch, as well as to the KDE 4 branch. Woops, still need to commit this... This is still reproducible in 3.5.9 but resolved in trunk r798768. Decided it's too invasive for 3.5.x. |