1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
8 #include "ash/system/tray/system_tray_notifier.h"
9 #include "remoting/host/client_session_control.h"
10 #include "remoting/host/host_window.h"
16 class DisconnectWindowAura
: public HostWindow
{
18 DisconnectWindowAura();
19 ~DisconnectWindowAura() override
;
21 // HostWindow interface.
22 void Start(const base::WeakPtr
<ClientSessionControl
>& client_session_control
)
26 DISALLOW_COPY_AND_ASSIGN(DisconnectWindowAura
);
29 DisconnectWindowAura::DisconnectWindowAura() {
32 DisconnectWindowAura::~DisconnectWindowAura() {
33 ash::Shell::GetInstance()->system_tray_notifier()->NotifyScreenShareStop();
36 void DisconnectWindowAura::Start(
37 const base::WeakPtr
<ClientSessionControl
>& client_session_control
) {
38 // TODO(kelvinp): Clean up the NotifyScreenShareStart interface when we
39 // completely retire Hangout Remote Desktop v1.
40 base::string16 helper_name
;
41 ash::Shell::GetInstance()->system_tray_notifier()->NotifyScreenShareStart(
42 base::Bind(&ClientSessionControl::DisconnectSession
,
43 client_session_control
),
50 scoped_ptr
<HostWindow
> HostWindow::CreateDisconnectWindow() {
51 return make_scoped_ptr(new DisconnectWindowAura());
54 } // namespace remoting