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

ENYO-5623: Fix ui/Marquee to stop when blurred during restart timer #1935

Merged
merged 2 commits into from
Sep 7, 2018

Conversation

ryanjduffy
Copy link
Contributor

Checklist

  • I have read and understand the contribution guide

  • A CHANGELOG entry is included

  • At least one test case is included for this feature or bug fix

  • Documentation was added or is not needed

  • This is an API breaking change

Issue Resolved / Feature Added

In #1301, we added a Job to manage cancelling marquee instances in MarqueeController to allow synchronized marquees to continue when a stop event (e.g. blurring) was immediately followed by a start event (focusing, pointer enter). As a result, it became possible (either through impeccable timing or sluggishness on lower powered hardware) to blur a synchronized marquee during the restart timer causing the job to be scheduled but then reset by the "complete" trigger before it fires.

Resolution

  • Remove the call to stop the cancel job on "complete"

Additional Considerations

I couldn't come up with a reason that the "complete" trigger would stop the cancel job. The purpose of the complete trigger is to inform the controller that one instance is done in order to coordinate restarting all instances at the same time. It isn't a trigger to initiate marquee and so shouldn't prevent cancelling (as far as i can tell).

Ryan Duffy added 2 commits September 7, 2018 09:04
Signed-off-by: Ryan Duffy <ryan.duffy@lge.com>
Signed-off-by: Ryan Duffy <ryan.duffy@lge.com>
@@ -230,7 +230,6 @@ const MarqueeController = hoc(defaultConfig, (config, Wrapped) => {
handleComplete = (component) => {
const complete = this.markReady(component);
if (complete) {
this.cancelJob.stop();
Copy link
Contributor

@webOS101 webOS101 Sep 7, 2018

Choose a reason for hiding this comment

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

Seems like this is safe enough. I think the thought process was that any time we were going to issue a start, we should prevent cancel from stopping it. But, I think in this instance, it makes sense that if we have a cancel pending, we would want to allow it to prevent the restart. In theory, you could check to see if the cancel was pending and not issue the restart.

Copy link
Contributor

@viodragon2 viodragon2 left a comment

Choose a reason for hiding this comment

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

LGTM

@viodragon2 viodragon2 merged commit 9cbf712 into develop Sep 7, 2018
@viodragon2 viodragon2 deleted the feature/ENYO-5623 branch September 7, 2018 19:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants