fix: WCO crash on bad titlebarStyle (#34140)

fix: WCO crash on bad titlebarStyle
This commit is contained in:
Shelley Vohr
2022-05-17 17:50:27 +02:00
committed by GitHub
parent 4e3587c7c6
commit 97c9451efc
2 changed files with 25 additions and 6 deletions

View File

@@ -55,8 +55,8 @@ SkColor WinFrameView::GetReadableFeatureColor(SkColor background_color) {
}
void WinFrameView::InvalidateCaptionButtons() {
// Ensure that the caption buttons container exists
DCHECK(caption_button_container_);
if (!caption_button_container_)
return;
caption_button_container_->InvalidateLayout();
caption_button_container_->SchedulePaint();