Mir
legacy_surface_change_notification.h
Go to the documentation of this file.
1 /*
2  * Copyright © 2014 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_SCENE_LEGACY_SURFACE_CHANGE_NOTIFICATION_H_
20 #define MIR_SCENE_LEGACY_SURFACE_CHANGE_NOTIFICATION_H_
21 
23 
24 #include <functional>
25 
26 namespace ms = mir::scene;
27 namespace geom = mir::geometry;
28 
29 namespace mir
30 {
31 namespace scene
32 {
34 {
35 public:
37  std::function<void()> const& notify_scene_change,
38  std::function<void(int)> const& notify_buffer_change);
39 
40  void resized_to(geometry::Size const& /*size*/) override;
41  void moved_to(geometry::Point const& /*top_left*/) override;
42  void hidden_set_to(bool /*hide*/) override;
43  void frame_posted(int frames_available) override;
44  void alpha_set_to(float /*alpha*/) override;
45  void orientation_set_to(MirOrientation orientation) override;
46  void transformation_set_to(glm::mat4 const& /*t*/) override;
47  void attrib_changed(MirSurfaceAttrib, int) override;
49  void cursor_image_set_to(graphics::CursorImage const& image) override;
50  void client_surface_close_requested() override;
51 
52 private:
53  std::function<void()> const notify_scene_change;
54  std::function<void(int)> const notify_buffer_change;
55 };
56 }
57 }
58 
59 #endif // MIR_SCENE_LEGACY_SURFACE_CHANGE_NOTIFICATION_H_
Definition: size.h:30
All things Mir.
Definition: buffer_stream.h:37
void reception_mode_set_to(input::InputReceptionMode mode) override
Definition: legacy_surface_change_notification.cpp:79
Management of Surface objects. Includes the model (SurfaceStack and Surface classes) and controller (...
Definition: default_server_configuration.h:86
Definition: point.h:30
LegacySurfaceChangeNotification(std::function< void()> const &notify_scene_change, std::function< void(int)> const &notify_buffer_change)
Definition: legacy_surface_change_notification.cpp:26
void attrib_changed(MirSurfaceAttrib, int) override
Definition: legacy_surface_change_notification.cpp:70
void resized_to(geometry::Size const &) override
Definition: legacy_surface_change_notification.cpp:34
void hidden_set_to(bool) override
Definition: legacy_surface_change_notification.cpp:44
Definition: surface_observer.h:42
void orientation_set_to(MirOrientation orientation) override
Definition: legacy_surface_change_notification.cpp:60
MirOrientation
Direction relative to the "natural" orientation of the display.
Definition: common.h:142
Definition: cursor_image.h:30
void frame_posted(int frames_available) override
Definition: legacy_surface_change_notification.cpp:49
void alpha_set_to(float) override
Definition: legacy_surface_change_notification.cpp:54
MirSurfaceAttrib
Attributes of a surface that the client and server/shell may wish to get or set over the wire...
Definition: common.h:36
Definition: legacy_surface_change_notification.h:33
void moved_to(geometry::Point const &) override
Definition: legacy_surface_change_notification.cpp:39
Basic geometry types. Types for dimensions, displacements, etc. and the operations that they support...
Definition: overlapping_output_grouping.h:27
InputReceptionMode
Definition: input_reception_mode.h:27
void cursor_image_set_to(graphics::CursorImage const &image) override
Definition: legacy_surface_change_notification.cpp:75
void transformation_set_to(glm::mat4 const &) override
Definition: legacy_surface_change_notification.cpp:64
void client_surface_close_requested() override
Definition: legacy_surface_change_notification.cpp:85

Copyright © 2012,2013 Canonical Ltd.
Generated on Tue Mar 24 16:15:19 UTC 2015