jQuery UI的自动完成在滚动条的z-index帮助 [英] jQuery UI Autocomplete with scrollbar z-index help

查看:210
本文介绍了jQuery UI的自动完成在滚动条的z-index帮助的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有我附上的jQuery UI的自动完成功能,一个文本框,我使用CSS通过例子来给它一个最大高度的此处。我的问题是,这样做会导致z-index的问题 bgiframe 解决了再来,但以不同的方式。最初的自动完成菜单上面是其下面所有的控制,但是当我开始滚动自动完成菜单落在他们后面。

I have a textbox that I am attaching jQuery UI's Autocomplete functionality to and I am using CSS to give it a max height via the example here. My problem is that doing this causes the z-index problem that bgiframe solves to come back again, but in a different way. The initial autocomplete menu is above all the controls underneath it, but when I begin to scroll the autocomplete menu falls behind them.

有什么建议?

编辑:

这纯粹是IE6的​​bug。

This is purely an IE6 bug.

正如你所看到的,向下滚动自动完成后落在其他控件的后面。

As you can see, after scrolling down the autocomplete falls behind the other controls.

推荐答案

我可以在下面的行替换的的offsetHeight 的通过的 scrollHeight属性的(从jquery.bgiframe解决问题.js文件):

I could solve the problem by replacing offsetHeight by scrollHeight in the following line (from jquery.bgiframe.js) :

<$c$c>height:'+(s.height=='auto'?'ex$p$pssion(this.parentNode.offsetHeight+\\'px\\')':prop(s.height))+';'+

这变化解决的bug与垂直滚动条的自动完成字段。我不能发现其他种类的对话框中的任何回归(但我没有跑了广泛的测试)。

This change solved the bug for the autocomplete fields with vertical scrollbars. I could not spot any regression in other kinds of dialogs (but I did not run extensive tests).

这篇关于jQuery UI的自动完成在滚动条的z-index帮助的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆