Commit fd859422 authored by Gil Dekel's avatar Gil Dekel Committed by Commit Bot

Ash Tray: RemovePrivacyScreenToastController Obs in Dtor

This CL fixes a bug in which we do not remove
PrivacyScreenToastController as an observer of PrivacyScreenController
during destruction.

Bug: b:157775487, 1090385
Change-Id: I97f0740a2a97493750e2f751ae2eb390b743df2d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2225863Reviewed-by: default avatarTim Song <tengs@chromium.org>
Reviewed-by: default avatarAhmed Mehfooz <amehfooz@chromium.org>
Reviewed-by: default avatarDaniele Castagna <dcastagna@chromium.org>
Commit-Queue: Tim Song <tengs@chromium.org>
Cr-Commit-Position: refs/heads/master@{#774314}
parent 09ab2cfc
...@@ -26,6 +26,7 @@ PrivacyScreenToastController::~PrivacyScreenToastController() { ...@@ -26,6 +26,7 @@ PrivacyScreenToastController::~PrivacyScreenToastController() {
close_timer_.Stop(); close_timer_.Stop();
if (bubble_widget_ && !bubble_widget_->IsClosed()) if (bubble_widget_ && !bubble_widget_->IsClosed())
bubble_widget_->CloseNow(); bubble_widget_->CloseNow();
Shell::Get()->privacy_screen_controller()->RemoveObserver(this);
} }
void PrivacyScreenToastController::ShowToast() { void PrivacyScreenToastController::ShowToast() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment