jQuery event.isPropagationStopped() 方法

jQuery 教程 · 2019-03-10 23:14:00

实例

检查 event.stopPropagation() 是否被调用:

$("div").click(function(event){
    event.stopPropagation();
    alert(event.isPropagationStopped());
});

定义和用法

event.isPropagationStopped() 方法检查指定的事件上是否调用了 event.stopPropagation()。

如果 event.stopPropagation() 被调用则该方法返回 true,否则返回 false。

语法


event.isPropagationStopped()

参数 描述
event 必需。event 参数来自事件绑定函数。

点击查看所有 jQuery 教程 文章: https://www.codercto.com/courses/l/35.html

查看所有标签

TED Talks Storytelling: 23 Storytelling Techniques from the Best

TED Talks Storytelling: 23 Storytelling Techniques from the Best

Akash Karia / CreateSpace Independent Publishing Platform / 2015-1-11 / USD 6.99

"Every speaker can put these ideas into practice immediately -- and they should!" ~ Dr. Richard C. Harris, Certified World Class Speaking Coach "An insightful read" ~Dennis Waller, Top 500 Revie......一起来看看 《TED Talks Storytelling: 23 Storytelling Techniques from the Best》 这本书的介绍吧!

随机密码生成器
随机密码生成器

多种字符组合密码

HTML 编码/解码
HTML 编码/解码

HTML 编码/解码

SHA 加密
SHA 加密

SHA 加密工具