forked from Pissandshittium/pissandshittium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnew_window_controller.h
50 lines (38 loc) · 1.51 KB
/
new_window_controller.h
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
// 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.
#ifndef ASH_NEW_WINDOW_CONTROLLER_H_
#define ASH_NEW_WINDOW_CONTROLLER_H_
#include "ash/public/interfaces/new_window.mojom.h"
#include "base/macros.h"
#include "mojo/public/cpp/bindings/associated_binding.h"
#include "mojo/public/cpp/bindings/binding_set.h"
namespace ash {
// Provides the NewWindowController interface to the outside world. This lets a
// consumer of ash provide a NewWindowClient, which we will dispatch to if one
// has been provided to us.
class NewWindowController : public mojom::NewWindowController,
public mojom::NewWindowClient {
public:
NewWindowController();
~NewWindowController() override;
void BindRequest(mojom::NewWindowControllerRequest request);
// NewWindowClient:
void NewTab() override;
void NewWindow(bool incognito) override;
void OpenFileManager() override;
void OpenCrosh() override;
void OpenGetHelp() override;
void RestoreTab() override;
void ShowKeyboardOverlay() override;
void ShowTaskManager() override;
void OpenFeedbackPage() override;
private:
// NewWindowController:
void SetClient(mojom::NewWindowClientAssociatedPtrInfo client) override;
mojo::BindingSet<mojom::NewWindowController> bindings_;
mojom::NewWindowClientAssociatedPtr client_;
DISALLOW_COPY_AND_ASSIGN(NewWindowController);
};
} // namespace ash
#endif // ASH_NEW_WINDOW_CONTROLLER_H_