Skip to content
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

After Chrome's print dialog shows, reflowed event listener is detached from the table #327

Closed
DannyJJK opened this issue Sep 26, 2016 · 3 comments
Labels

Comments

@DannyJJK
Copy link

DannyJJK commented Sep 26, 2016

Browser: Chrome
OS: macOS Sierra

Steps to reproduce:

  1. Create table and apply floatThead to it
  2. Assign an event listener for the reflowed event
  3. View the page in Google Chrome. Currently the reflowed event works. Now if you open the print dialog, and close it with the cancel button, you'll notice that the reflowed event no longer fires. Viewing in the browser's dev tools it seems that the reflowed event still exists but the listener for the event becomes unbound from the table. Rebinding the event solves the issue.

https://jsfiddle.net/jstfgjan/

On this JSfiddle I have created a button which reflows the table and has a "reflowed" listener which creates an alert dialog. After opening Chrome's print dialog and then closing it, the button now does nothing

@DannyJJK DannyJJK changed the title After Chrome's print dialog shows, reflowed event is unbound After Chrome's print dialog shows, reflowed event listener is detached from the table Sep 26, 2016
@mkoryak
Copy link
Owner

mkoryak commented Sep 26, 2016

I understand why this would happen. thanks for the report

@mkoryak mkoryak added the bug label Sep 26, 2016
@mkoryak
Copy link
Owner

mkoryak commented Sep 29, 2016

I dont know why I was destroying the table on print. All I needed to do was unfloat the header and refloat it afterwards. I had all the secret sauce but didnt use it.

This should make printing much less magical

@lock
Copy link

lock bot commented Dec 10, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Dec 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants