在IE中缓慢'onclick'响应 [英] Slow 'onclick' response in IE

查看:52
本文介绍了在IE中缓慢'onclick'响应的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

伙计。


我最近做了一些简单的测试和实验。结果,

我注意到,在处理''onclick''时,IE似乎不如支持快速点击一样。事实上,无论我点击多快,Firefox似乎都可以跟上我,但是IE ......好吧,不是!


下面的代码片段演示了这个(在我的机器上它确实是

):


< html>

< body onload =" valueElement = document.getElementById(''value'')">

< p id =" value"> 0< / p>

< p>< input type =" button" onclick =" valueElement.innerHTML ++"

value =" Increment">< / input>< / p>

< / body>

< / html>


其他人可以确认IE无法跟上快速点击

按钮在这段代码中,我的

机器上的问题不仅仅是错误的吗?有没有人有任何关于让IE更快回应的建议?


提前感谢任何信息。


A.

Hi, folks.

I''ve recently been doing a few simple tests and experiments. As a result,
I''ve noticed that, in dealing with ''onclick'', IE seems less able than
Firefox to keep up with rapid clicking. In fact, Firefox seems to be able to
keep up with me no matter how rapidly I click, whereas IE... well, doesn''t!

The following snippet of code demonstrates this (on my machine it does
anyway):

<html>
<body onload="valueElement = document.getElementById(''value'')">
<p id="value">0</p>
<p><input type="button" onclick="valueElement.innerHTML++"
value="Increment"></input></p>
</body>
</html>

Can anyone else confirm that IE is unable to keep up with rapid clicking of
the button in this code, and that it''s not just something wrong on my
machine? Does anyone have any suggestions on making IE respond more quickly?

Thanks in advance for any info.

A.

推荐答案




11月6日下午12:03,Andrew C < nonse ... @ totally.made.upwrote:


On Nov 6, 12:03 pm, "Andrew C" <nonse...@totally.made.upwrote:

伙计。


我最近做了一些简单的测试和实验。结果,

我注意到,在处理''onclick''时,IE似乎不如支持快速点击一样。事实上,无论我点击多快,Firefox似乎都可以跟上我,但是IE ......好吧,不是!


下面的代码片段演示了这个(在我的机器上它确实是

):


< html>

< body onload =" valueElement = document.getElementById(''value'')">

< p id =" value"> 0< / p>

< p>< input type =" button" onclick =" valueElement.innerHTML ++"

value =" Increment">< / input>< / p>

< / body>

< / html>


其他人可以确认IE无法跟上快速点击

按钮在这段代码中,我的

机器上的问题不仅仅是错误的吗?有没有人有任何关于让IE更快回应的建议?


提前感谢任何信息。


A.
Hi, folks.

I''ve recently been doing a few simple tests and experiments. As a result,
I''ve noticed that, in dealing with ''onclick'', IE seems less able than
Firefox to keep up with rapid clicking. In fact, Firefox seems to be able to
keep up with me no matter how rapidly I click, whereas IE... well, doesn''t!

The following snippet of code demonstrates this (on my machine it does
anyway):

<html>
<body onload="valueElement = document.getElementById(''value'')">
<p id="value">0</p>
<p><input type="button" onclick="valueElement.innerHTML++"
value="Increment"></input></p>
</body>
</html>

Can anyone else confirm that IE is unable to keep up with rapid clicking of
the button in this code, and that it''s not just something wrong on my
machine? Does anyone have any suggestions on making IE respond more quickly?

Thanks in advance for any info.

A.



我不是这方面的专家,但似乎在双击时事件它

在IE上触发它不会触发单击。


添加:

ondblclick = valueElement.innerHTML ++
按钮的
允许IE跟上你的点击次数。


但是这会增加FireFox的问题,因为双击将触发

ondblclick和onclick,因此计算两次。


我建议搜索跨浏览器解决此问题的方法,也许

在没有IE的情况下禁用双击。

I''m no expert on this, but it seems that when a "Double Click" event it
fired on IE it won''t trigger the "Single Click".

Adding:
ondblclick="valueElement.innerHTML++"
to the Button allows IE to keep up with your clicks.

But this adds a problem with FireFox, as a Double Click would trigger
both the ondblclick and onclick, hence counting twice.

I''d suggest searching on cross browser ways of solving this, maybe
disabling the doubleclick when not IE.




" [on]" < sw ******** @ gmail.com写信息

新闻:11 ********************** @ k70g2000cwa.googlegr oups.com ...

"[on]" <sw********@gmail.comwrote in message
news:11**********************@k70g2000cwa.googlegr oups.com...

>

11月6日下午12:03,Andrew C < nonse ... @ totally.made.upwrote:
>
On Nov 6, 12:03 pm, "Andrew C" <nonse...@totally.made.upwrote:

>大家。

我最近一直在做一些简单的测试和实验。结果,
我注意到,在处理''onclick''时,IE似乎不像Firefox那样能够跟上快速点击的速度。事实上,无论我点击多快,Firefox似乎都能够跟上我,而IE ......好吧,
不是!
):

< html>
< body onload =" valueElement = document.getElementById (''value'')">
< p id =" value"> 0< / p>
< p>< input type =" button" onclick =" valueElement.innerHTML ++"
value =" Increment">< / input>< / p>
< / body>
< / html> ;

其他任何人都可以确认IE无法跟上这段代码中按钮的快速点击,并且这不仅仅是我的错误
机器?有没有人有任何关于让IE快速响应的建议?

提前感谢任何信息。

A.
>Hi, folks.

I''ve recently been doing a few simple tests and experiments. As a result,
I''ve noticed that, in dealing with ''onclick'', IE seems less able than
Firefox to keep up with rapid clicking. In fact, Firefox seems to be able
to
keep up with me no matter how rapidly I click, whereas IE... well,
doesn''t!

The following snippet of code demonstrates this (on my machine it does
anyway):

<html>
<body onload="valueElement = document.getElementById(''value'')">
<p id="value">0</p>
<p><input type="button" onclick="valueElement.innerHTML++"
value="Increment"></input></p>
</body>
</html>

Can anyone else confirm that IE is unable to keep up with rapid clicking
of
the button in this code, and that it''s not just something wrong on my
machine? Does anyone have any suggestions on making IE respond more
quickly?

Thanks in advance for any info.

A.



我不是这方面的专家,但似乎在双击时事件它

在IE上触发它不会触发单击。


添加:

ondblclick = valueElement.innerHTML ++
按钮的
允许IE跟上你的点击次数。


但是这会增加FireFox的问题,因为双击将触发

ondblclick和onclick,因此计算两次。


我建议搜索跨浏览器解决此问题的方法,也许

在没有IE的情况下禁用双击。


I''m no expert on this, but it seems that when a "Double Click" event it
fired on IE it won''t trigger the "Single Click".

Adding:
ondblclick="valueElement.innerHTML++"
to the Button allows IE to keep up with your clicks.

But this adds a problem with FireFox, as a Double Click would trigger
both the ondblclick and onclick, hence counting twice.

I''d suggest searching on cross browser ways of solving this, maybe
disabling the doubleclick when not IE.



谢谢!这似乎是它。


我现在抓住''ondblclick''事件并检查''navigator.appName''

确定是否浏览器是''Microsoft Internet Explorer''。如果是,我

复制''onclick''的行为;如果它不是IE,我什么都不做。它是好的。
工作正常。


任何想法是IE'或FF是'正在做''正确'的事情(或者至少

最常见的事情)?为IE设置一组行为是安全的,对于所有其他浏览器来说,还有其他的东西,或者FF是奇怪的吗?任何线索?


再次感谢。


A.

Thank you! That seems to be it.

I now catch the ''ondblclick'' event and check ''navigator.appName'' to
determine if the browser is ''Microsoft Internet Explorer''. If it is, I
duplicate the ''onclick'' behaviour for it; if it''s not IE, I do nothing. It
works fine.

Any idea whether it''s IE or FF that''s doing the ''right'' thing (or at least
the most common thing)? Is it safe to have one set of behaviour for IE, and
something else for all other browsers, or is FF the odd one out? Any clue?

Thanks again.

A.



Andrew C写道:

Andrew C wrote:

大家好。


我最近做了一些简单的测试和实验。结果,

我注意到,在处理''onclick''时,IE似乎不如支持快速点击一样。事实上,无论我点击多快,Firefox似乎都能够跟上我,但是IE ......好吧,不是!
Hi, folks.

I''ve recently been doing a few simple tests and experiments. As a result,
I''ve noticed that, in dealing with ''onclick'', IE seems less able than
Firefox to keep up with rapid clicking. In fact, Firefox seems to be able to
keep up with me no matter how rapidly I click, whereas IE... well, doesn''t!



它与IE无关,但与Windows操作系统无关。它有特殊选项

检测意外双击默认开启。这意味着对于每个

两次点击可以解释为一次双击(同一个地方,

足够短的间隔)系统应用相当复杂的神经元

试图猜测它确实是双击或错误。你经常在桌面上看到这个

神奇的行为:当通过网络习惯时,你需要双击桌面上的图标,但只有一个应用程序实例

已推出。


这也意味着你不应该使用doubleclick事件处理程序来为你的Web解决方案提供
:* never *。要查看您的样本正在工作你可以

更改你的注册表设置。如果您没有安装TweakUI,请参阅

< http://www.winguides.com/registry/display.php/965/for manual

设置改变。


当然,它对你未来的用户没什么帮助。

It is not relevant to IE but to Windows OS. It has special option
"Detect accidental double clicks" on by default. It means that for each
two clicks that can be interpreted as one double click (same place,
short enough interval) the system applies rather complicated neuristic
trying to guess was it indeed double click or an error. You see this
neuristic in action rather often on your desktop: when "by web-habit"
you double click an icon on the desk but only one application instance
is launched.

It also means that you should not use doubleclick event handler for
your Web solutions: *never*. To see your sample "working" you can
change your registry settings. If you don''t have TweakUI installed, see
<http://www.winguides.com/registry/display.php/965/for manual
settings change.

Naturally it doesn''t help much to your future users.


这篇关于在IE中缓慢'onclick'响应的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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