Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit badab61a authored by Tony Wickham's avatar Tony Wickham
Browse files

Clean up AppWindowAnimationHelper and TransformParams

AppWindowAnimationHelper and TransformParams were being very tightly
intertwined, to the point that you really had to understand subtle
nuances of both in order to get a desired behavior. This makes making
changes really difficult, because there are lots of "traps" to know
about and navigate. To help alleviate this burden, cleaned up some of
these traps and give AWAH and TP distinct roles:
- A caller who needs to animate an app window needs both AWAH and TP.
  TP defines specific parameters of how the app window should be
  controlled, and AWAH simply reads from TP in order to provide the
  desired behavior.
- Only the caller should write to TP; AWAH should no longer change
  anything in a TP that is passed to it. For instance, instead of
  repurposing TP.currentRect, AWAH now has its own mCurrentRect to
  update based on passed parameters.
- TP is a very basic class that just holds various values that callers
  can set one at a time. The order should not matter (setting one value
  will never set another one), and defaults make sense.
- Commented the setter methods in TP so developers shouldn't have to
  follow the code to see how they are used.

Bug: 149870691
Change-Id: Ia48f4453c29549271a3fc6538128a1a77439e015
parent f240ef2a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment