Mir
shell_report.h
Go to the documentation of this file.
1 /*
2  * Copyright © 2015 Canonical Ltd.
3  *
4  * This program is free software: you can redistribute it and/or modify it
5  * under the terms of the GNU General Public License version 3,
6  * as published by the Free Software Foundation.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU General Public License for more details.
12  *
13  * You should have received a copy of the GNU General Public License
14  * along with this program. If not, see <http://www.gnu.org/licenses/>.
15  *
16  * Authored by: Alan Griffiths <alan@octopull.co.uk>
17  */
18 
19 #ifndef MIR_SHELL_SHELL_REPORT_H
20 #define MIR_SHELL_SHELL_REPORT_H
21 
23 #include "mir_toolkit/common.h"
24 
25 #include <memory>
26 #include <set>
27 
28 namespace mir
29 {
30 namespace geometry { struct Rectangle; }
31 namespace scene { class PromptSession; class Session; class Surface; struct SurfaceCreationParameters; }
32 
33 namespace shell
34 {
35 struct SurfaceSpecification;
36 using SurfaceSet = std::set<std::weak_ptr<scene::Surface>, std::owner_less<std::weak_ptr<scene::Surface>>>;
37 
39 {
40 public:
41 
42  virtual void opened_session(scene::Session const& session) = 0;
43 
44  virtual void closing_session(scene::Session const& session) = 0;
45 
46  virtual void created_surface(
47  scene::Session const& session, frontend::SurfaceId surface_id) = 0;
48 
49  virtual void update_surface(
50  scene::Session const& session, scene::Surface const& surface,
51  SurfaceSpecification const& modifications) = 0;
52 
53  virtual void update_surface(
54  scene::Session const& session, scene::Surface const& surface,
55  MirSurfaceAttrib attrib, int value) = 0;
56 
57  virtual void destroying_surface(
58  scene::Session const& session, frontend::SurfaceId surface) = 0;
59 
60  virtual void started_prompt_session(
61  scene::PromptSession const& prompt_session,
62  scene::Session const& session) = 0;
63 
64  virtual void added_prompt_provider(
65  scene::PromptSession const& prompt_session,
66  scene::Session const& session) = 0;
67 
68  virtual void stopping_prompt_session(
69  scene::PromptSession const& prompt_session) = 0;
70 
71  virtual void adding_display(geometry::Rectangle const& area) = 0;
72 
73  virtual void removing_display(geometry::Rectangle const& area) = 0;
74 
75  virtual void input_focus_set_to(
76  scene::Session const* focus_session,
77  scene::Surface const* focus_surface) = 0;
78 
79  virtual void surfaces_raised(SurfaceSet const& surfaces) = 0;
80 
81  ShellReport() = default;
82  virtual ~ShellReport() = default;
83  ShellReport(ShellReport const&) = delete;
84  ShellReport& operator=(ShellReport const&) = delete;
85 };
86 }
87 }
88 
89 #endif //MIR_SHELL_SHELL_REPORT_H
All things Mir.
Definition: atomic_callback.h:25
Definition: prompt_session.h:30
Definition: session.h:38
std::set< std::weak_ptr< scene::Surface >, std::owner_less< std::weak_ptr< scene::Surface >>> SurfaceSet
Definition: focus_controller.h:32
MirSurfaceAttrib
Attributes of a surface that the client and server/shell may wish to get or set over the wire...
Definition: common.h:34
Definition: shell_report.h:38
Definition: rectangle.h:33
Specification of surface properties requested by client.
Definition: surface_specification.h:49
Definition: surface.h:47

Copyright © 2012-2015 Canonical Ltd.
Generated on Wed Mar 30 00:29:56 UTC 2016