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 mir
27 {
28 namespace scene
29 {
31 {
32 public:
34  std::function<void()> const& notify_scene_change,
35  std::function<void(int)> const& notify_buffer_change);
36 
37  void resized_to(geometry::Size const& /*size*/) override;
38  void moved_to(geometry::Point const& /*top_left*/) override;
39  void hidden_set_to(bool /*hide*/) override;
40  void frame_posted(int frames_available, geometry::Size const& size) override;
41  void alpha_set_to(float /*alpha*/) override;
42  void orientation_set_to(MirOrientation orientation) override;
43  void transformation_set_to(glm::mat4 const& /*t*/) override;
44  void attrib_changed(MirSurfaceAttrib, int) override;
46  void cursor_image_set_to(graphics::CursorImage const& image) override;
47  void client_surface_close_requested() override;
48  void keymap_changed(MirInputDeviceId id, std::string const& model, std::string const& layout,
49  std::string const& variant, std::string const& options) override;
50  void renamed(char const*) override;
51  void cursor_image_removed() override;
52 
53 private:
54  std::function<void()> const notify_scene_change;
55  std::function<void(int)> const notify_buffer_change;
56 };
57 }
58 }
59 
60 #endif // MIR_SCENE_LEGACY_SURFACE_CHANGE_NOTIFICATION_H_
Definition: size.h:30
All things Mir.
Definition: atomic_callback.h:25
void reception_mode_set_to(input::InputReceptionMode mode) override
Definition: legacy_surface_change_notification.cpp:83
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 renamed(char const *) override
Definition: legacy_surface_change_notification.cpp:99
void resized_to(geometry::Size const &) override
Definition: legacy_surface_change_notification.cpp:34
void cursor_image_removed() override
Definition: legacy_surface_change_notification.cpp:79
void hidden_set_to(bool) override
Definition: legacy_surface_change_notification.cpp:44
Definition: surface_observer.h:44
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:164
Definition: cursor_image.h:30
void keymap_changed(MirInputDeviceId id, std::string const &model, std::string const &layout, std::string const &variant, std::string const &options) override
Definition: legacy_surface_change_notification.cpp:94
int64_t MirInputDeviceId
Definition: input_event.h:35
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:34
Definition: legacy_surface_change_notification.h:30
void frame_posted(int frames_available, geometry::Size const &size) override
Definition: legacy_surface_change_notification.cpp:49
void moved_to(geometry::Point const &) override
Definition: legacy_surface_change_notification.cpp:39
InputReceptionMode
Definition: input_reception_mode.h:27
void cursor_image_set_to(graphics::CursorImage const &image) override
Definition: legacy_surface_change_notification.cpp:75
int const size
Definition: make_socket_rpc_channel.cpp:51
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:89

Copyright © 2012-2015 Canonical Ltd.
Generated on Thu Sep 8 14:50:19 UTC 2016