forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnew_window_controller.cc
82 lines (63 loc) · 1.82 KB
/
new_window_controller.cc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "ash/new_window_controller.h"
#include <utility>
namespace ash {
NewWindowController::NewWindowController() = default;
NewWindowController::~NewWindowController() = default;
void NewWindowController::BindRequest(
mojom::NewWindowControllerRequest request) {
bindings_.AddBinding(this, std::move(request));
}
void NewWindowController::SetClient(
mojom::NewWindowClientAssociatedPtrInfo client) {
client_.Bind(std::move(client));
}
// TODO(crbug.com/755448): Remove this when the new shortcut viewer is enabled.
void NewWindowController::ShowKeyboardOverlay() {
// TODO(estade): implement this here rather than passing off to |client_|.
if (client_)
client_->ShowKeyboardOverlay();
}
void NewWindowController::NewTabWithUrl(const GURL& url) {
if (client_)
client_->NewTabWithUrl(url);
}
void NewWindowController::NewTab() {
if (client_)
client_->NewTab();
}
void NewWindowController::NewWindow(bool incognito) {
if (client_)
client_->NewWindow(incognito);
}
void NewWindowController::OpenFileManager() {
if (client_)
client_->OpenFileManager();
}
void NewWindowController::OpenCrosh() {
if (client_)
client_->OpenCrosh();
}
void NewWindowController::OpenGetHelp() {
if (client_)
client_->OpenGetHelp();
}
void NewWindowController::RestoreTab() {
if (client_)
client_->RestoreTab();
}
void NewWindowController::ShowKeyboardShortcutViewer() {
if (client_)
client_->ShowKeyboardShortcutViewer();
}
void NewWindowController::ShowTaskManager() {
if (client_)
client_->ShowTaskManager();
}
void NewWindowController::OpenFeedbackPage() {
if (client_)
client_->OpenFeedbackPage();
}
} // namespace ash