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

Focus events #7985

Closed
wants to merge 6 commits into from
Closed

Focus events #7985

wants to merge 6 commits into from

Conversation

@j3parker
Copy link
Contributor

j3parker commented Oct 12, 2015

This is my first pass at #7981

Looking for some early feedback. I'm not sure that what I'm doing in commit_focus_transaction is 100% correct and I'm still trying to wrap my head around the spec (focusing/unfocusing/focus update steps.) I'm only doing focus/focusout at the moment while I try to understand what's going on.

When I combine this with what I have in #7757 things seem to work. What would be the best way of adding tests for something like this independent of that other issue?

Review on Reviewable

@mbrubeck
Copy link
Contributor

mbrubeck commented Oct 12, 2015

Review status: 0 of 5 files reviewed at latest revision, 1 unresolved discussion, some commit checks pending.


components/script/dom/document.rs, line 523 [r2] (raw file):
This TODO comment should be updated.


Comments from the review on Reviewable.io

@j3parker
Copy link
Contributor Author

j3parker commented Oct 12, 2015

Review status: 0 of 5 files reviewed at latest revision, 1 unresolved discussion, some commit checks pending.


components/script/dom/document.rs, line 523 [r2] (raw file):
Got it - thanks!


Comments from the review on Reviewable.io

@Manishearth Manishearth assigned mbrubeck and Manishearth and unassigned mbrubeck Oct 12, 2015
@Manishearth
Copy link
Member

Manishearth commented Oct 13, 2015

Reviewed 4 of 5 files at r1.
Review status: 3 of 5 files reviewed at latest revision, 3 unresolved discussions, all commit checks successful.


components/script/dom/document.rs, line 989 [r3] (raw file):
We should leave comments here with a FIXME that this is incomplete (doesn't handle related targets)

ditto to where its called


components/script/dom/document.rs, line 999 [r3] (raw file):
spec says "to not bubble"

https://html.spec.whatwg.org/multipage/interaction.html#fire-a-focus-event


Comments from the review on Reviewable.io

@Manishearth
Copy link
Member

Manishearth commented Oct 13, 2015

Reviewed 1 of 5 files at r1, 1 of 1 files at r3.
Review status: all files reviewed at latest revision, 3 unresolved discussions, all commit checks successful.


Comments from the review on Reviewable.io

@Manishearth
Copy link
Member

Manishearth commented Oct 13, 2015

Looks good so far.

I think web-platform-tests should already have tests for this, really. Try running ./mach test-wpt --log-raw tmp.log (this takes a long time, adding --processes 4 makes it faster), followed by ./mach update-wpt tmp.log will update test expectations.

@j3parker
Copy link
Contributor Author

j3parker commented Oct 13, 2015

Review status: 4 of 5 files reviewed at latest revision, 3 unresolved discussions, some commit checks pending.


components/script/dom/document.rs, line 989 [r3] (raw file):
Done - I pre-emptively made it an argument on fire_focus_event.
It seems to me we'd have to be careful implementing this because of iframe security etc. (not wanting to pass a node from a different-origin iframe on a focus event up to the parent when focus leaves the iframe.) Does that sound right?


components/script/dom/document.rs, line 999 [r3] (raw file):
D'oh, thanks


Comments from the review on Reviewable.io

@Manishearth
Copy link
Member

Manishearth commented Oct 13, 2015

Still needs a lot of the other things from the issue being implemented. Though I am fine with landing this as-is so we can work on it incrementally. (@jdm ?)

Also needs test expectation updates to land.


Reviewed 1 of 1 files at r4.
Review status: all files reviewed at latest revision, 3 unresolved discussions, some commit checks pending.


Comments from the review on Reviewable.io

@Manishearth
Copy link
Member

Manishearth commented Oct 13, 2015

Review status: all files reviewed at latest revision, 2 unresolved discussions, some commit checks pending.


components/script/dom/document.rs, line 989 [r3] (raw file):
Yes, that does. The spec should have a provision for that, though.


Comments from the review on Reviewable.io

@j3parker j3parker force-pushed the j3parker:focus-events branch from 8dec242 to 620c5d5 Oct 13, 2015
@j3parker
Copy link
Contributor Author

j3parker commented Oct 13, 2015

There were some more changes to WPT expectations that don't seem relevant that I split over here: j3parker@061c799

I haven't had time to triage them yet - hopefully tonight after work.

@j3parker j3parker force-pushed the j3parker:focus-events branch from 620c5d5 to 284813a Oct 13, 2015
@Manishearth
Copy link
Member

Manishearth commented Oct 13, 2015

One of those failures is related, we should add FocusEvent to https://github.com/servo/servo/blob/master/tests/wpt/mozilla/tests/mozilla/interfaces.html#L72

@j3parker j3parker force-pushed the j3parker:focus-events branch from b456ef4 to 594429a Oct 14, 2015
@j3parker
Copy link
Contributor Author

j3parker commented Oct 14, 2015

Thanks - I'll look through the rest tonight (EST)

@bors-servo
Copy link
Contributor

bors-servo commented Oct 14, 2015

The latest upstream changes (presumably #7984) made this pull request unmergeable. Please resolve the merge conflicts.

@Manishearth
Copy link
Member

Manishearth commented Nov 2, 2015

Any updates?

@frewsxcv
Copy link
Member

frewsxcv commented Dec 2, 2015

@j3parker have any ideas how close this is to completion? No problem if you're too busy, just let us know

@paulrouget
Copy link
Contributor

paulrouget commented Feb 2, 2016

@j3parker are you still working on this bug?

@jdm
Copy link
Member

jdm commented Feb 2, 2016

@paulrouget Seems safe to say no, given the multiple months with no reply after previous queries.

@frewsxcv
Copy link
Member

frewsxcv commented Feb 2, 2016

@j3parker Thanks for the effort! Feel free to reopen if you want to want to work on it again and it's not already done!

@frewsxcv frewsxcv closed this Feb 2, 2016
bors-servo added a commit that referenced this pull request Feb 4, 2016
Implement focus, blur, focusin and focusout events

Don't review just yet. Need a try.

Based on #7985

Fixes #7981
@j3parker
Copy link
Contributor Author

j3parker commented Feb 5, 2016

Oh wow I'm sorry!

I set up email filtering on Github (because we've been using it at my workplace more) and long story short these didn't get to my email and I forgot otherwise.

Happy to see it's been picked up though :) Cheers.

bors-servo added a commit that referenced this pull request Feb 17, 2016
Implement focus, blur, focusin and focusout events

Based on #7985

Fixes #7981

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9529)
<!-- Reviewable:end -->
bors-servo added a commit that referenced this pull request Feb 18, 2016
Implement focus, blur, focusin and focusout events

Based on #7985

Fixes #7981

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9529)
<!-- Reviewable:end -->
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 1, 2019
…ts (from paulrouget:focusEvents); r=asajeffrey

Based on servo/servo#7985

Fixes servo/servo#7981

Source-Repo: https://github.com/servo/servo
Source-Revision: d8ffa3d0b85815a5ff62491f9f3bc7445834fc0e

UltraBlame original commit: 69a79a86d8bc72b4a6862af8729811b9e9cdaa2a
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 1, 2019
…ts (from paulrouget:focusEvents); r=asajeffrey

Based on servo/servo#7985

Fixes servo/servo#7981

Source-Repo: https://github.com/servo/servo
Source-Revision: d8ffa3d0b85815a5ff62491f9f3bc7445834fc0e

UltraBlame original commit: 69a79a86d8bc72b4a6862af8729811b9e9cdaa2a
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 1, 2019
…ts (from paulrouget:focusEvents); r=asajeffrey

Based on servo/servo#7985

Fixes servo/servo#7981

Source-Repo: https://github.com/servo/servo
Source-Revision: d8ffa3d0b85815a5ff62491f9f3bc7445834fc0e

UltraBlame original commit: 69a79a86d8bc72b4a6862af8729811b9e9cdaa2a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

8 participants
You can’t perform that action at this time.