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

Implementing activation behavior for <label> #8260

Merged
merged 1 commit into from
Oct 31, 2015

Conversation

martiansideofthemoon
Copy link
Contributor

Attempt to resolve #8179
@Manishearth , could you give me some resources having more information about what each function in Activatable does? The code compiles on my machine but I guess a lot more is needed

Review on Reviewable

@highfive highfive added the S-awaiting-review There is new code that needs to be reviewed. label Oct 30, 2015
@ManishBot
Copy link

@bors-servo try

(ignore me, and ignore the test failure that's going to happen below, that will be caused by me canceling the build)

@bors-servo
Copy link
Contributor

⌛ Trying commit 19e1a0d with merge ce764be...

bors-servo pushed a commit that referenced this pull request Oct 30, 2015
Implementing activation behavior for <label>

Attempt to resolve #8179 
@Manishearth , could you give me some resources having more information about what each function in `Activatable` does? The code compiles on my machine but I guess a lot more is needed

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8260)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

💔 Test failed - mac-dev-ref-unit

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Oct 30, 2015

// https://html.spec.whatwg.org/multipage/#implicit-submission
fn implicit_submission(&self, ctrlKey: bool, shiftKey: bool, altKey: bool, metaKey: bool) {

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a FIXME here and file an issue for investigation

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What would be the appropriate FIXME message / issue title?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

File one, "Investigate and implement implicit submission for label elements"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Manishearth
Copy link
Member

Does this change any tests?

@Manishearth
Copy link
Member

could you give me some resources having more information about what each function in Activatable does?

See the spec links 😄

Basically, form controls, buttons, and links can be "activated". This happens when they get clicked, or sometimes when you hit the space/enter key when they are in focus. There's a lot of complications in the spec around this, and the Activatable trait abstracts it away. Anything implementing this just needs to fill in the compulsory methods, and it's good to go. In the case of label there was no mention of canceled/post-activation steps (unlike, say, checkbox input), so it's empty.

@martiansideofthemoon
Copy link
Contributor Author

@Manishearth ./mach test-ref, ./mach test-unitpassed all tests. Which test has failed? How could I see the same? Didn't find it on pressing the "Details" link

@Manishearth
Copy link
Member

No, there weren't test failures, that was an induced failure (I was testing some new infrastructure). I was talking about the wpt tests.

@martiansideofthemoon
Copy link
Contributor Author

What would be the correct way of checking this? I am currently running mach test-wpt and it looks like it's going to take a really long time to complete.

@Manishearth
Copy link
Member

You can pass --processes 4 or something to it.

(Also, use the --log-raw parameter as described in tests/wpt/README.md so you don't need to rerun it to update expectations)

@eefriedman
Copy link
Contributor

You probably need to change

pub fn as_maybe_activatable(&self) -> Option<&Activatable> {
before this will actually do anything.

@Manishearth
Copy link
Member

Good point, forgot to check for that.

@eefriedman eefriedman removed the S-tests-failed The changes caused existing tests to fail. label Oct 30, 2015
@martiansideofthemoon
Copy link
Contributor Author

@Manishearth What change will be needed in that file?

@Manishearth
Copy link
Member

Add a case to HTMLLabelElement to that match


// https://html.spec.whatwg.org/multipage/#implicit-submission
fn implicit_submission(&self, ctrlKey: bool, shiftKey: bool, altKey: bool, metaKey: bool) {
//FIXME: Investigate and implement implicit submission for label elements
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you file a bug for this and refer to the bug number here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I mean update the fixme comment here to point to that

@Manishearth
Copy link
Member

@bors-servo try

Let's see if there are test issues

@bors-servo
Copy link
Contributor

⌛ Trying commit c763010 with merge 3331e0a...

bors-servo pushed a commit that referenced this pull request Oct 31, 2015
Implementing activation behavior for <label>

Attempt to resolve #8179 
@Manishearth , could you give me some resources having more information about what each function in `Activatable` does? The code compiles on my machine but I guess a lot more is needed

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8260)
<!-- Reviewable:end -->
@Manishearth
Copy link
Member

Small nit, then r=me unless there are test failures

@bors-servo
Copy link
Contributor

💔 Test failed - mac-rel-wpt

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Oct 31, 2015
@Ms2ger Ms2ger added S-fails-tidy `./mach test-tidy` reported errors. and removed S-tests-failed The changes caused existing tests to fail. labels Oct 31, 2015
@Ms2ger
Copy link
Contributor

Ms2ger commented Oct 31, 2015

./components/script/dom/element.rs:1726: trailing whitespace

@jdm
Copy link
Member

jdm commented Oct 31, 2015

@bors-servo: r=Manishearth

@bors-servo
Copy link
Contributor

📌 Commit af91c98 has been approved by Manishearth

@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-awaiting-review There is new code that needs to be reviewed. labels Oct 31, 2015
@bors-servo
Copy link
Contributor

⌛ Testing commit af91c98 with merge 53d8f04...

bors-servo pushed a commit that referenced this pull request Oct 31, 2015
Implementing activation behavior for <label>

Attempt to resolve #8179 
@Manishearth , could you give me some resources having more information about what each function in `Activatable` does? The code compiles on my machine but I guess a lot more is needed

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8260)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

☀️ Test successful - android, gonk, linux-dev, linux-rel, mac-dev-ref-unit, mac-rel-css, mac-rel-wpt

@bors-servo bors-servo merged commit af91c98 into servo:master Oct 31, 2015
@martiansideofthemoon martiansideofthemoon deleted the my-code-fix branch October 31, 2015 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. S-fails-tidy `./mach test-tidy` reported errors.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement 'activation behavior' for <label> elements
8 participants