The div:last-child rule from lockscreen makes unnecessary restyle when appendChild() to #windows div

RESOLVED FIXED in 2.1 S9 (21Nov)

Status

defect
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: ting, Assigned: ting)

Tracking

unspecified
2.1 S9 (21Nov)
ARM
Gonk (Firefox OS)
Dependency tree / graph

Firefox Tracking Flags

(b2g-v2.2 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

46 bytes, text/x-github-pull-request
gweng
: review+
Details | Review
There's another unnecessary restyle when appendChild() to #windows, it's because #windows has NODE_HAS_EDGE_CHILD_SELECTOR flag set from lockscreen/style/notifications.css:

  #notifications-lockscreen-container > div:last-child::after

Since lockscreen.html now is integrated to system app (#lockscreen-frame-placeholder), import the CSS with limited scope can avoid this.
Summary: The last-child rule from lockscreen makes #windows → The div:last-child rule from lockscreen makes unnecessary restyle when appendChild() to #windows div
Posted file PR (obsolete) —
Assignee: nobody → tchou
Status: NEW → ASSIGNED
Attachment #8520360 - Flags: review?(gweng)
Comment on attachment 8520360 [details] [review]
PR

OK. I've tested this on my device. It looks fine and thanks for your patch.
Attachment #8520360 - Flags: review?(gweng) → review+
Passcode input pad is not shown with the patch:

  TEST-UNEXPECTED-ERROR | test_lockscreen_unlock_to_homescreen_with_passcode.py TestLockScreen.test_unlock_to_homescreen_with_passcode | TimeoutException: TimeoutException: Timed out after 10.0 seconds

Also from logcat I see:

  W/GeckoConsole(20502): [JavaScript Warning: "Property contained reference to invalid variable.  Error in parsing value for 'transition-duration'.  Falling back to 'initial'." {file: "app://system.gaiamobile.org/lockscreen/style/lockscreen.css" line: 263 column: 5464 source: " opacity var(--panel-transition-secs) ease"}]

I'll check those.
Comment on attachment 8520360 [details] [review]
PR

OK. I've re-flash it completely and the error occur. It looks like the old code (I now pull it directly from device to check it) has been pushed into the device, I should using make reset-gaia instead of make install-gaia. Please set the flag again if you fixed the issue.
Attachment #8520360 - Flags: review+
Posted file PR v2
Addressed the issues of comment 3.
Attachment #8520360 - Attachment is obsolete: true
Attachment #8521277 - Flags: review?(gweng)
Comment on attachment 8521277 [details] [review]
PR v2

OK. I now flash it twice to check if the patch is fine. Thanks.
Attachment #8521277 - Flags: review?(gweng) → review+
Keywords: checkin-needed
Master: https://github.com/mozilla-b2g/gaia/commit/6c4c07fe539a004810f314cf7d3c6ee2d5465c78
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → 2.1 S9 (21Nov)
Blocks: AppStartup
You need to log in before you can comment on or make changes to this bug.