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;
37 using SurfaceSet = std::set<std::weak_ptr<scene::Surface>, std::owner_less<std::weak_ptr<scene::Surface>>>;
39 
41 {
42 public:
43 
44  virtual void opened_session(scene::Session const& session) = 0;
45 
46  virtual void closing_session(scene::Session const& session) = 0;
47 
48  virtual void created_surface(
49  scene::Session const& session, frontend::SurfaceId surface_id) = 0;
50 
51  virtual void update_surface(
52  scene::Session const& session, scene::Surface const& surface,
53  SurfaceSpecification const& modifications) = 0;
54 
55  virtual void update_surface(
56  scene::Session const& session, scene::Surface const& surface,
57  MirWindowAttrib attrib, int value) = 0;
58 
59  virtual void destroying_surface(
60  scene::Session const& session, frontend::SurfaceId surface) = 0;
61 
62  virtual void started_prompt_session(
63  scene::PromptSession const& prompt_session,
64  scene::Session const& session) = 0;
65 
66  virtual void added_prompt_provider(
67  scene::PromptSession const& prompt_session,
68  scene::Session const& session) = 0;
69 
70  virtual void stopping_prompt_session(
71  scene::PromptSession const& prompt_session) = 0;
72 
73  virtual void adding_display(geometry::Rectangle const& area) = 0;
74 
75  virtual void removing_display(geometry::Rectangle const& area) = 0;
76 
77  virtual void input_focus_set_to(
78  scene::Session const* focus_session,
79  scene::Surface const* focus_surface) = 0;
80 
81  virtual void surfaces_raised(SurfaceSet const& surfaces) = 0;
82 
83  ShellReport() = default;
84  virtual ~ShellReport() = default;
85  ShellReport(ShellReport const&) = delete;
86  ShellReport& operator=(ShellReport const&) = delete;
87 };
88 }
89 }
90 
91 #endif //MIR_SHELL_SHELL_REPORT_H
Definition: as_render_target.h:27
Definition: prompt_session.h:30
MirWindowAttrib
Attributes of a window that the client and server/shell may wish to get or set over the wire...
Definition: common.h:76
Definition: session.h:37
std::set< std::weak_ptr< scene::Surface >, std::owner_less< std::weak_ptr< scene::Surface >>> SurfaceSet
Definition: focus_controller.h:32
Definition: shell_report.h:40
Definition: rectangle.h:33
Specification of surface properties requested by client.
Definition: surface_specification.h:57
Definition: surface.h:49

Copyright © 2012-2016 Canonical Ltd.
Generated on Mon Jun 5 11:05:03 UTC 2017