-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
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
IE9+、jQuery1.8.X~1.10.Xで、ポップアップウィンドウ内の要素をターゲットにインジケータを出そうとするとエラーが発生する #310
Comments
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 12, 2014
(IE9+ jQuery1.8.X~1.10.Xでポップアップウィンドウについてスタイルを取得しようとするとエラーになるので、その回避のため) fadeIn(),fadeOut()も同様にjQueryの内部でエラーが起きてしまうため、自分で実装しました。
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 12, 2014
iframe内のwindowにインジケータを表示するテストを追加しました。 hifive#310 テストコードで、ポップアップウィンドウ内の要素のスタイルを取得するコードをcss()メソッドを使わないよう修正しました。 (style.displayを取得するように変更したことで、computedStyleは取得できていませんが、現時点での実装ではインジケータはインジケータ要素のdisplayをblockにして表示しているため、style.displayで確認しています。)
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 12, 2014
getStyle -> getComputedStyleWrapper
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 12, 2014
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 12, 2014
getComputedStyleWrapper -> getComputedStyleObject
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 12, 2014
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 12, 2014
getWidth,getHeightは、jQueryのwidth(),height()と同じでoffsetWidth/Heightからpaddingを引いた数値を返すように修正。 [inner,outer]Height/Widthについても、jQueryの対応するメソッドと同じ結果が返るように修正。 インジケータのコンテンツの縦位置計算がおかしかったので修正。
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 13, 2014
getComputedStyleがあるかどうかの判定は、そのエレメントが属するwindowを使って判定するようにしました。 elm→elemにリネームしました。
fukudayasuo
pushed a commit
to hifive-labs/hifivemain
that referenced
this issue
May 13, 2014
(widthi()メソッドで設定すると、IE9+、jQuery1.8.X~1.10.XでgetComputedStyleバグが起きてしまうため)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
jQuery1.8.X~1.10.Xには、ポップアップウィンドウ内の要素のスタイルを取得できないバグがある。(iframe内の要素なら問題ない)
それが原因で、ポップアップウィンドウにインジケータを表示しようとすると、jQuery内部でエラーが発生する。
エラーの原因は、getComputedStyleが常にjQueryを読んでいるwindowのものが呼ばれていることが原因で、回避するためにjQueryを使わずにスタイルを取得するようにする。
なお、IE8-は、jQueryのスタイル値取得コードで問題なく取得できる。
The text was updated successfully, but these errors were encountered: