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.
5 #include "remoting/host/continue_window.h"
7 #include "remoting/base/string_resources.h"
8 #include "remoting/host/chromeos/message_box.h"
9 #include "ui/base/l10n/l10n_util.h"
15 class ContinueWindowAura
: public ContinueWindow
{
18 ~ContinueWindowAura() override
;
20 void OnMessageBoxResult(MessageBox::Result result
);
23 // ContinueWindow interface.
24 void ShowUi() override
;
25 void HideUi() override
;
28 scoped_ptr
<MessageBox
> message_box_
;
29 DISALLOW_COPY_AND_ASSIGN(ContinueWindowAura
);
32 ContinueWindowAura::ContinueWindowAura() {
33 message_box_
.reset(new MessageBox(
34 l10n_util::GetStringUTF16(IDS_MODE_IT2ME
), // title
35 l10n_util::GetStringUTF16(IDS_CONTINUE_PROMPT
), // dialog label
36 l10n_util::GetStringUTF16(IDS_CONTINUE_BUTTON
), // ok label
37 l10n_util::GetStringUTF16(IDS_STOP_SHARING_BUTTON
), // cancel label
38 base::Bind(&ContinueWindowAura::OnMessageBoxResult
,
39 base::Unretained(this))));
42 ContinueWindowAura::~ContinueWindowAura() {
46 void ContinueWindowAura::OnMessageBoxResult(MessageBox::Result result
) {
47 if (result
== MessageBox::OK
) {
54 void ContinueWindowAura::ShowUi() {
58 void ContinueWindowAura::HideUi() {
65 scoped_ptr
<HostWindow
> HostWindow::CreateContinueWindow() {
66 return make_scoped_ptr(new ContinueWindowAura());
69 } // namespace remoting