mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
fix: default to system accent color on invalid user color (#47684)
fix: default to system accent color on invalid user color" Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
This commit is contained in:
@@ -656,7 +656,7 @@ bool BaseWindow::IsTabletMode() const {
|
||||
}
|
||||
|
||||
void BaseWindow::SetBackgroundColor(const std::string& color_name) {
|
||||
SkColor color = ParseCSSColor(color_name);
|
||||
SkColor color = ParseCSSColor(color_name).value_or(SK_ColorWHITE);
|
||||
window_->SetBackgroundColor(color);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user