#4325 closed defect (fixed)
Safari/Webkit: Wrong dojo._abs behavior
Reported by: | haysmark | Owned by: | sjmiles |
---|---|---|---|
Priority: | high | Milestone: | 1.0.1 |
Component: | HTML | Version: | 0.9 |
Keywords: | 4dijit | Cc: | |
Blocked By: | Blocking: |
Description (last modified by )
Refer to: http://archive.dojotoolkit.org/nightly/dojotoolkit/dijit/tests/form/test_ComboBox.html
When you first load test_ComboBox and open a menu, it works fine. However, if you scroll the whole page down a little and open a menu, the menu appears too high and covers the ComboBox?. Specifically, the document's scroll position is not being added to the position the popup should appear. This only affects Safari.
There seems to be a logic problem in dojo._abs. According to a console.debug I added, in FireFox? and IE, hasScroll is false and everything displays correctly. In Safari, hasScroll becomes true, which seems to trigger the wrong math at this section:
var scroll = dojo._docScroll(); var m = hasScroll ? (!includeScroll ? -1 : 0) : 1; ret.y += m*scroll.y; ret.x += m*scroll.x;
The dojo.coords call is in place.js in dijit:
var aroundNodePos = dojo.coords(aroundNode, true);
Attachments (1)
Change History (11)
comment:1 Changed 13 years ago by
Status: | new → assigned |
---|
comment:2 Changed 13 years ago by
Description: | modified (diff) |
---|---|
Keywords: | 4dijit added |
Owner: | changed from haysmark to sjmiles |
Status: | assigned → new |
Summary: | Safari/Webkit: Strange ComboBox popup positioning → Safari/Webkit: Wrong dojo._abs behavior |
comment:3 Changed 13 years ago by
Component: | Dijit → HTML |
---|
comment:4 Changed 13 years ago by
Changed 13 years ago by
Attachment: | dojo.coords.patch added |
---|
comment:5 Changed 13 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:6 Changed 13 years ago by
Milestone: | 1.0 → 1.0.1 |
---|---|
Resolution: | fixed |
Status: | closed → reopened |
I just tried the test case on safari (see bug description) and it isn't working. Same for webkit, btw.
comment:7 Changed 13 years ago by
Perhaps the problem is just that the above patch has the line
dojo.isSafari >= 5
, whereas actually safari's is version 3 (and indeed on Safari version 3, dojo.isSafari == 3)
comment:9 Changed 13 years ago by
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
Hi all
I'm gathering from the following comment in dojo.js.uncompressed.js that this could have something to do with a change in behaviour in Safari.
I'm attaching a patch that fixes the problem for me.
cheers
Hannes