We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EventDispatcher.addEventListener()で、引数の長さが2つでなければエラーが投げられる。
var obj = {}; h5.mixin.eventDispatcher.mix(obj); obj.addEventListener('myevent', function(){}, false); // code: 16000; addEventListenerには、イベント名(文字列)、イベントリスナ(関数)を渡す必要があります。
jQueryのbindなどでイベントをバインドするときに第3引数が渡されるので、jQueryを使ってbindすることができない。
$(obj).bind('myevent', function(){}); // エラー
jQueryを使ってbindもできるように、addEventListenerの引数チェックは、第3引数以降があっても無視するようにする。
The text was updated successfully, but these errors were encountered:
hifive#341 EventDispatcher.addEventListener()は、第3引数以降は無視してエラーにしないようにし…
44af6d0
…ました。 第3引数を指定した時にエラーにならないことをチェックするテストケースを追加しました。 jQuery.bind()でイベントハンドラをバインドするテストケースを追加しました。 jQuery.trigger()でイベントハンドラを呼び出すテストケースを追加しました。
fukudayasuo
No branches or pull requests
EventDispatcher.addEventListener()で、引数の長さが2つでなければエラーが投げられる。
jQueryのbindなどでイベントをバインドするときに第3引数が渡されるので、jQueryを使ってbindすることができない。
jQueryを使ってbindもできるように、addEventListenerの引数チェックは、第3引数以降があっても無視するようにする。
The text was updated successfully, but these errors were encountered: