Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Fix/tab close fixed width animation jump #14516

Merged
merged 3 commits into from
Jun 22, 2018

Conversation

petemill
Copy link
Member

@petemill petemill commented Jun 22, 2018

Address feedback in #14477 (comment) which is really a regression report of #7001 via #11438, concerning jumpiness of tab fixed-width restore animation by:

  • waiting a frame before animating tab width from forced width back to normal after closing tabs
  • not forcing tab width when closing the last item (didn't make sense anyway since the mouse cursor cannot often still be at the close tab icon after closing the last tab in the strip, and the issue was caused by the mouse becoming in a window-draggable area which behaves erratically with mouse-leave)
  • stopping to force tab width once a new tab is created (avoids tabs becoming too wide if a user closes some tabs with the mouse and then opens 1 or more new tabs, without moving the mouse away from the tabs toolbar.

Submitter Checklist:

  • Submitted a ticket for my issue if one did not already exist.
  • Used Github auto-closing keywords in the commit message.
  • Added/updated tests for this change (for new code or code which already has tests).
  • Ran git rebase -i to squash commits (if needed).
  • Tagged reviewers and labelled the pull request as needed.
  • Request a security/privacy review as needed. (Ask a Brave employee to help if you cannot access this document.)

Test Plan:

Reviewer Checklist:

  • Request a security/privacy review as needed if one was not already requested.

Tests

  • Adequate test coverage exists to prevent regressions
  • Tests should be independent and work correctly when run individually or as a suite ref
  • New files have MPL2 license header

petemill added 3 commits June 22, 2018 00:28
…ip with the mouse

This went against the purpose of fixing the tab width, which is to keep the close button under the mouse pointer as much as possible, as it does not apply if the mouse is beyond the boundaries of the last tab (since the previous last tab was closed)
This caused display issues when closing tabs then creating new tabs without moving the mouse cursor away from the tabs toolbar
Copy link
Member

@bsclifton bsclifton left a comment

Choose a reason for hiding this comment

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

Tested quite a few scenarios- this is working great 😄 Code changes look good too!

@bsclifton bsclifton merged commit d5ed260 into master Jun 22, 2018
@bsclifton bsclifton deleted the fix/tab-close-fixed-width-animation-jump branch June 22, 2018 20:00
bsclifton added a commit that referenced this pull request Jun 22, 2018
…ion-jump

Fix/tab close fixed width animation jump
@bsclifton
Copy link
Member

bsclifton commented Jun 22, 2018

master d5ed260
0.24.x 6781909
0.23.x fc75570 @petemill can you help me merge this one to 0.23.x?

petemill pushed a commit that referenced this pull request Jun 22, 2018
…ion-jump

Fix/tab close fixed width animation jump
@petemill
Copy link
Member Author

There was a conflict with 0.23.x which was in a weird state, almost as if it hadn't had a previous cherry-pick correctly.... fixed now though @bsclifton

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants