Chromium Code Reviews| Index: components/exo/notification_surface.cc |
| diff --git a/components/exo/notification_surface.cc b/components/exo/notification_surface.cc |
| index cb41a194dc8d1a515a5da46dfcbd6a6f9d39a3c0..aa741e96450485050ebf2ef866d20d53f71a8807 100644 |
| --- a/components/exo/notification_surface.cc |
| +++ b/components/exo/notification_surface.cc |
| @@ -88,8 +88,6 @@ NotificationSurface::NotificationSurface(NotificationSurfaceManager* manager, |
| // TODO(xiyuan): Fix after Surface no longer has an auar::Window. |
|
reveman
2016/07/20 18:58:02
nit: aura::Window
xiyuan
2016/07/20 23:19:03
Done.
|
| window_->AddChild(surface_->window()); |
| surface_->window()->Show(); |
| - |
| - manager_->AddSurface(this); |
| } |
| NotificationSurface::~NotificationSurface() { |
| @@ -113,6 +111,11 @@ void NotificationSurface::OnSurfaceCommit() { |
| bounds.set_size(surface_->content_size()); |
| window_->SetBounds(bounds); |
|
reveman
2016/07/20 18:58:02
as the bounds can change here, doesn't the manager
xiyuan
2016/07/20 19:52:41
The hosting ArcCustomNotificationView is based on
reveman
2016/07/20 20:57:30
I'm not suggesting we should show it unless bounds
xiyuan
2016/07/20 22:01:20
I prefer not doing remove-then-add on bounds chang
|
| } |
| + |
| + if (!added_to_manager_) { |
| + added_to_manager_ = true; |
| + manager_->AddSurface(this); |
| + } |
| } |
| bool NotificationSurface::IsSurfaceSynchronized() const { |