Closed Bug 1665461 Opened 7 months ago Closed 5 months ago

Persist UI colors and sizes to registry so that the early skeleton UI can match them

Categories

(Firefox :: General, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
84 Branch
Tracking Status
firefox84 --- fixed

People

(Reporter: dthayer, Assigned: emalysz)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

At the very least, we want to be aware if the user is on anything other than the default theme, so that we can not show an unmatching skeleton UI. However, better would be to have the skeleton UI match whatever built-in theme you're using, and even better would be to have the skeleton UI match any lightweight theme the user has installed.

Please yes. Dark theme user here, and the skeleton is too bright for me :)
Maybe skeletonUI can solve this on Windows for me https://bugzilla.mozilla.org/show_bug.cgi?id=1458930

Assignee: nobody → emalysz

This patch supports a skeleton UI for default, light, and dark themes.
It is not enabled for apenglow or any custom themes.

This also takes into account the system theme. If the user has the default
theme selected and is in dark mode, we override the theme and present the
dark theme skeleton UI.

Pushed by emalysz@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/9c13c984601a
reflect the correct colors for default themes in the skeleton UI. r=dthayer
Backout by btara@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/ec4a8d302879
Backed out changeset 9c13c984601a for browser_preXULSkeletonUIRegistry.js failures CLOSED TREE

Backed out changeset 9c13c984601a (bug 1665461) for browser_preXULSkeletonUIRegistry.js failures.

Push with failures: https://treeherder.mozilla.org/jobs?repo=autoland&group_state=expanded&fromchange=a86cc0d29dc0320a41e093d65fd4f61533857290&searchStr=windows%2C10%2Cx64%2Copt%2Cmochitests%2Ctest-windows10-64%2Fopt-mochitest-browser-chrome-e10s%2Cbc1&tochange=ad4013a9048a702ea32c8d69b2888a5ef191e1a3&selectedTaskRun=EjDNRz6DQ_WxSDyWYOT9Ew.0

Backout link: https://hg.mozilla.org/integration/autoland/rev/ec4a8d30287916d698cdbd14bcfff7643174eab0

Failure log: https://treeherder.mozilla.org/logviewer?job_id=321587086&repo=autoland&lineNumber=1826

[task 2020-11-12T18:14:22.619Z] 18:14:22     INFO - TEST-START | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js
[task 2020-11-12T18:14:22.628Z] 18:14:22     INFO - GECKO(10716) | 1605204862626	Marionette	TRACE	Received observer notification toplevel-window-ready
[task 2020-11-12T18:14:23.072Z] 18:14:23     INFO - GECKO(10716) | 1605204863066	Marionette	TRACE	Received observer notification toplevel-window-ready
[task 2020-11-12T18:14:23.415Z] 18:14:23     INFO - TEST-INFO | started process screenshot
[task 2020-11-12T18:14:23.516Z] 18:14:23     INFO - TEST-INFO | screenshot: exit 0
[task 2020-11-12T18:14:23.517Z] 18:14:23     INFO - Buffered messages logged at 18:14:22
[task 2020-11-12T18:14:23.517Z] 18:14:23     INFO - Entering test bound testWritesEnabledOnPrefChange
[task 2020-11-12T18:14:23.517Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Pre-XUL skeleton UI is enabled in the Windows registry - 
[task 2020-11-12T18:14:23.518Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Pre-XUL skeleton UI is disabled in the Windows registry - 
[task 2020-11-12T18:14:23.518Z] 18:14:23     INFO - Buffered messages logged at 18:14:23
[task 2020-11-12T18:14:23.520Z] 18:14:23     INFO - Leaving test bound testWritesEnabledOnPrefChange
[task 2020-11-12T18:14:23.521Z] 18:14:23     INFO - Entering test bound testWritesSizeValuesOnChange
[task 2020-11-12T18:14:23.521Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for Width - 
[task 2020-11-12T18:14:23.521Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for Height - 
[task 2020-11-12T18:14:23.522Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for ScreenX - 
[task 2020-11-12T18:14:23.522Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for ScreenY - 
[task 2020-11-12T18:14:23.523Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for UrlbarCSSSpan - 
[task 2020-11-12T18:14:23.523Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Value should have non-zero components for UrlbarCSSSpan - 
[task 2020-11-12T18:14:23.523Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for CssToDevPixelScaling - 
[task 2020-11-12T18:14:23.523Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Value should have non-zero components for CssToDevPixelScaling - 
[task 2020-11-12T18:14:23.523Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for SpringsCSSSpan - 
[task 2020-11-12T18:14:23.523Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Value should have non-zero components for SpringsCSSSpan - 
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for SearchbarCSSSpan - 
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - TEST-PASS | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Value should have non-zero components for SearchbarCSSSpan - 
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - Buffered messages finished
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - TEST-UNEXPECTED-FAIL | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Skeleton UI registry values should have a non-zero value for Theme - 
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - Stack trace:
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - chrome://mochikit/content/browser-test.js:test_ok:1304
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - chrome://mochitests/content/browser/browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js:testWritesSizeValuesOnChange:112
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - Not taking screenshot here: see the one that was previously logged
[task 2020-11-12T18:14:23.524Z] 18:14:23     INFO - TEST-UNEXPECTED-FAIL | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Uncaught exception - at chrome://mochitests/content/browser/browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js:116 - TypeError: can't access property "length", value is undefined
[task 2020-11-12T18:14:23.525Z] 18:14:23     INFO - Stack trace:
[task 2020-11-12T18:14:23.525Z] 18:14:23     INFO - testWritesSizeValuesOnChange@chrome://mochitests/content/browser/browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js:116:9
[task 2020-11-12T18:14:23.525Z] 18:14:23     INFO - Leaving test bound testWritesSizeValuesOnChange
[task 2020-11-12T18:14:23.525Z] 18:14:23     INFO - GECKO(10716) | MEMORY STAT | vsize 2104246MB | vsizeMaxContiguous 66135632MB | residentFast 306MB | heapAllocated 109MB
[task 2020-11-12T18:14:23.525Z] 18:14:23     INFO - TEST-OK | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | took 859ms
[task 2020-11-12T18:14:23.525Z] 18:14:23     INFO - checking window state
[task 2020-11-12T18:14:23.525Z] 18:14:23     INFO - Not taking screenshot here: see the one that was previously logged
[task 2020-11-12T18:14:23.527Z] 18:14:23     INFO - TEST-UNEXPECTED-FAIL | browser/base/content/test/startup/browser_preXULSkeletonUIRegistry.js | Found an unexpected browser window at the end of test run - 
[task 2020-11-12T18:14:23.527Z] 18:14:23     INFO - GECKO(10716) | must wait for focus
[task 2020-11-12T18:14:23.580Z] 18:14:23     INFO - GECKO(10716) | Completed ShutdownLeaks collections in process 10348
[task 2020-11-12T18:14:23.581Z] 18:14:23     INFO - TEST-START | Shutdown
[task 2020-11-12T18:14:23.581Z] 18:14:23     INFO - Browser Chrome Test Summary
[task 2020-11-12T18:14:23.581Z] 18:14:23     INFO - Passed:  14
[task 2020-11-12T18:14:23.581Z] 18:14:23     INFO - Failed:  3
[task 2020-11-12T18:14:23.582Z] 18:14:23     INFO - Todo:    0
[task 2020-11-12T18:14:23.582Z] 18:14:23     INFO - Mode:    e10s
[task 2020-11-12T18:14:23.582Z] 18:14:23     INFO - *** End BrowserChrome Test Results ***
[task 2020-11-12T18:14:23.601Z] 18:14:23     INFO - GECKO(10716) | Exiting due to channel error.
[task 2020-11-12T18:14:23.601Z] 18:14:23     INFO - GECKO(10716) | Exiting due to channel error.
[task 2020-11-12T18:14:23.601Z] 18:14:23     INFO - GECKO(10716) | Exiting due to channel error.
[task 2020-11-12T18:14:23.601Z] 18:14:23     INFO - GECKO(10716) | Exiting due to channel error.
[task 2020-11-12T18:14:23.667Z] 18:14:23     INFO - TEST-INFO | Main app process: exit 0
[task 2020-11-12T18:14:23.667Z] 18:14:23     INFO - runtests.py | Application ran for: 0:00:05.213000
Flags: needinfo?(emalysz)
Pushed by emalysz@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/48953ffdc96d
reflect the correct colors for default themes in the skeleton UI. r=dthayer
Status: NEW → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → 84 Branch
Flags: needinfo?(emalysz)

Geobert, does bug 1665461 solve bug 1458930 (I use macOS so I can't tell) ? if so, could you duplicate the other bug to this one? Thanks!

Flags: needinfo?(geobert)
Duplicate of this bug: 1458930

(In reply to Tim Nguyen :ntim from comment #8)

Geobert, does bug 1665461 solve bug 1458930 (I use macOS so I can't tell) ? if so, could you duplicate the other bug to this one? Thanks!

Thanks for the head up!

Flags: needinfo?(geobert)
Regressions: 1686373
You need to log in before you can comment on or make changes to this bug.