良好的旧重叠菜单,如何对ActiveX进行Z索引 [英] The good old overlapping menu, how to z-index an activeX

查看:79
本文介绍了良好的旧重叠菜单,如何对ActiveX进行Z索引的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在页面上有一个ActiveX ...我知道... ActiveX ...哎呀!



出于某种逻辑上的业务原因,我们不得不使用ActiveX,但问题是我不能使ActiveX < object> 处于其他任何问题之下……



这太不可思议了!




我可以想到两种潜在的解决方案。您可以尝试 iframe抠图解决方案 ,这说明您可以使用iframe将插件的一部分切出以显示下面的HTML。



第二种解决方案是绘制弹出窗口弹出对象中的菜单。这些是单独的窗口,它们呈现在网页的前面,甚至可以超出文档的边界—有一些限制—主要缺点是它们没有阴影,因此这可能会使您的样式有点不舒服。


I have an ActiveX on a page... I know ... ActiveX ... blarghhh!

That for some logic business reason we had to go with ActiveX, but the problem is that I can't make the ActiveX <object> to be beneath anything else ...

it's extremely weird!

Live plain example and Live example with iframe wrapper

You can try the example, but remember that the ActiveX only work in Internet Explorer, and no matter what version for the ActiveX, it will always run.

This problem I'm facing is the overlapping one:

Playing with position and z-index does nothing and I have no more ideas :-(

解决方案

ActiveX controls are rendered as "windowed" elements in Internet Explorer, whereas most other elements (particularly in newer versions of IE) are "windowless". Flash has a wmode option for whether it draws windowless or windowed but, in my experience, this is very difficult to achieve, especially if the object is written in .NET and not C++.

All windowed elements paint themselves on top of all windowless elements, despite the wishes of their container. However, windowed elements do follow the z-index attribute with respect to each other, just as windowless elements follow the z-index attribute with respect to each other.

All windowless elements are rendered on the same MSHTML plane, and windowed elements draw on a separate MSHTML plane. You can use z-index to manipulate elements on the same plane but not to mix and match with elements in different planes. You can rearrange the z-indexing of the elements on each plane, but the windowed plane always draws on the top of the windowless plane.

> http://support.microsoft.com/kb/177378

There are two potential solutions I can think of. You could try the iframe "cutout" solution, which explains that you can use iframes to "cut out" part of the plug-in for the HTML below to show through.

The second solution is to draw your popup menus in a popup object. These are separate windows that render in front of your web page and can even exceed the boundaries of the document — with some limitations — the major downside being that they don't have shadows so this might uglify your styling a little.

这篇关于良好的旧重叠菜单,如何对ActiveX进行Z索引的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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