1 #include <wayland-client-protocol.hpp>
3 using namespace wayland;
4 using namespace detail;
6 const wl_interface* display_interface_sync_request[1] = {
10 const wl_interface* display_interface_get_registry_request[1] = {
14 const wl_interface* display_interface_error_event[3] = {
20 const wl_interface* display_interface_delete_id_event[1] = {
24 const wl_message display_interface_requests[2] = {
28 display_interface_sync_request,
33 display_interface_get_registry_request,
37 const wl_message display_interface_events[2] = {
41 display_interface_error_event,
46 display_interface_delete_id_event,
50 const wl_interface wayland::detail::display_interface =
55 display_interface_requests,
57 display_interface_events,
60 const wl_interface* registry_interface_bind_request[2] = {
65 const wl_interface* registry_interface_global_event[3] = {
71 const wl_interface* registry_interface_global_remove_event[1] = {
75 const wl_message registry_interface_requests[1] = {
79 registry_interface_bind_request,
83 const wl_message registry_interface_events[2] = {
87 registry_interface_global_event,
92 registry_interface_global_remove_event,
96 const wl_interface wayland::detail::registry_interface =
101 registry_interface_requests,
103 registry_interface_events,
106 const wl_interface* callback_interface_done_event[1] = {
110 const wl_message callback_interface_requests[0] = {
113 const wl_message callback_interface_events[1] = {
117 callback_interface_done_event,
121 const wl_interface wayland::detail::callback_interface =
126 callback_interface_requests,
128 callback_interface_events,
131 const wl_interface* compositor_interface_create_surface_request[1] = {
135 const wl_interface* compositor_interface_create_region_request[1] = {
139 const wl_message compositor_interface_requests[2] = {
143 compositor_interface_create_surface_request,
148 compositor_interface_create_region_request,
152 const wl_message compositor_interface_events[0] = {
155 const wl_interface wayland::detail::compositor_interface =
160 compositor_interface_requests,
162 compositor_interface_events,
165 const wl_interface* shm_pool_interface_create_buffer_request[6] = {
174 const wl_interface* shm_pool_interface_destroy_request[0] = {
177 const wl_interface* shm_pool_interface_resize_request[1] = {
181 const wl_message shm_pool_interface_requests[3] = {
185 shm_pool_interface_create_buffer_request,
190 shm_pool_interface_destroy_request,
195 shm_pool_interface_resize_request,
199 const wl_message shm_pool_interface_events[0] = {
202 const wl_interface wayland::detail::shm_pool_interface =
207 shm_pool_interface_requests,
209 shm_pool_interface_events,
212 const wl_interface* shm_interface_create_pool_request[3] = {
218 const wl_interface* shm_interface_format_event[1] = {
222 const wl_message shm_interface_requests[1] = {
226 shm_interface_create_pool_request,
230 const wl_message shm_interface_events[1] = {
234 shm_interface_format_event,
238 const wl_interface wayland::detail::shm_interface =
243 shm_interface_requests,
245 shm_interface_events,
248 const wl_interface* buffer_interface_destroy_request[0] = {
251 const wl_interface* buffer_interface_release_event[0] = {
254 const wl_message buffer_interface_requests[1] = {
258 buffer_interface_destroy_request,
262 const wl_message buffer_interface_events[1] = {
266 buffer_interface_release_event,
270 const wl_interface wayland::detail::buffer_interface =
275 buffer_interface_requests,
277 buffer_interface_events,
280 const wl_interface* data_offer_interface_accept_request[2] = {
285 const wl_interface* data_offer_interface_receive_request[2] = {
290 const wl_interface* data_offer_interface_destroy_request[0] = {
293 const wl_interface* data_offer_interface_finish_request[0] = {
296 const wl_interface* data_offer_interface_set_actions_request[2] = {
301 const wl_interface* data_offer_interface_offer_event[1] = {
305 const wl_interface* data_offer_interface_source_actions_event[1] = {
309 const wl_interface* data_offer_interface_action_event[1] = {
313 const wl_message data_offer_interface_requests[5] = {
317 data_offer_interface_accept_request,
322 data_offer_interface_receive_request,
327 data_offer_interface_destroy_request,
332 data_offer_interface_finish_request,
337 data_offer_interface_set_actions_request,
341 const wl_message data_offer_interface_events[3] = {
345 data_offer_interface_offer_event,
350 data_offer_interface_source_actions_event,
355 data_offer_interface_action_event,
359 const wl_interface wayland::detail::data_offer_interface =
364 data_offer_interface_requests,
366 data_offer_interface_events,
369 const wl_interface* data_source_interface_offer_request[1] = {
373 const wl_interface* data_source_interface_destroy_request[0] = {
376 const wl_interface* data_source_interface_set_actions_request[1] = {
380 const wl_interface* data_source_interface_target_event[1] = {
384 const wl_interface* data_source_interface_send_event[2] = {
389 const wl_interface* data_source_interface_cancelled_event[0] = {
392 const wl_interface* data_source_interface_dnd_drop_performed_event[0] = {
395 const wl_interface* data_source_interface_dnd_finished_event[0] = {
398 const wl_interface* data_source_interface_action_event[1] = {
402 const wl_message data_source_interface_requests[3] = {
406 data_source_interface_offer_request,
411 data_source_interface_destroy_request,
416 data_source_interface_set_actions_request,
420 const wl_message data_source_interface_events[6] = {
424 data_source_interface_target_event,
429 data_source_interface_send_event,
434 data_source_interface_cancelled_event,
437 "dnd_drop_performed",
439 data_source_interface_dnd_drop_performed_event,
444 data_source_interface_dnd_finished_event,
449 data_source_interface_action_event,
453 const wl_interface wayland::detail::data_source_interface =
458 data_source_interface_requests,
460 data_source_interface_events,
463 const wl_interface* data_device_interface_start_drag_request[4] = {
464 &data_source_interface,
470 const wl_interface* data_device_interface_set_selection_request[2] = {
471 &data_source_interface,
475 const wl_interface* data_device_interface_release_request[0] = {
478 const wl_interface* data_device_interface_data_offer_event[1] = {
479 &data_offer_interface,
482 const wl_interface* data_device_interface_enter_event[5] = {
487 &data_offer_interface,
490 const wl_interface* data_device_interface_leave_event[0] = {
493 const wl_interface* data_device_interface_motion_event[3] = {
499 const wl_interface* data_device_interface_drop_event[0] = {
502 const wl_interface* data_device_interface_selection_event[1] = {
503 &data_offer_interface,
506 const wl_message data_device_interface_requests[3] = {
510 data_device_interface_start_drag_request,
515 data_device_interface_set_selection_request,
520 data_device_interface_release_request,
524 const wl_message data_device_interface_events[6] = {
528 data_device_interface_data_offer_event,
533 data_device_interface_enter_event,
538 data_device_interface_leave_event,
543 data_device_interface_motion_event,
548 data_device_interface_drop_event,
553 data_device_interface_selection_event,
557 const wl_interface wayland::detail::data_device_interface =
562 data_device_interface_requests,
564 data_device_interface_events,
567 const wl_interface* data_device_manager_interface_create_data_source_request[1] = {
568 &data_source_interface,
571 const wl_interface* data_device_manager_interface_get_data_device_request[2] = {
572 &data_device_interface,
576 const wl_message data_device_manager_interface_requests[2] = {
578 "create_data_source",
580 data_device_manager_interface_create_data_source_request,
585 data_device_manager_interface_get_data_device_request,
589 const wl_message data_device_manager_interface_events[0] = {
592 const wl_interface wayland::detail::data_device_manager_interface =
594 "wl_data_device_manager",
597 data_device_manager_interface_requests,
599 data_device_manager_interface_events,
602 const wl_interface* shell_interface_get_shell_surface_request[2] = {
603 &shell_surface_interface,
607 const wl_message shell_interface_requests[1] = {
611 shell_interface_get_shell_surface_request,
615 const wl_message shell_interface_events[0] = {
618 const wl_interface wayland::detail::shell_interface =
623 shell_interface_requests,
625 shell_interface_events,
628 const wl_interface* shell_surface_interface_pong_request[1] = {
632 const wl_interface* shell_surface_interface_move_request[2] = {
637 const wl_interface* shell_surface_interface_resize_request[3] = {
643 const wl_interface* shell_surface_interface_set_toplevel_request[0] = {
646 const wl_interface* shell_surface_interface_set_transient_request[4] = {
653 const wl_interface* shell_surface_interface_set_fullscreen_request[3] = {
659 const wl_interface* shell_surface_interface_set_popup_request[6] = {
668 const wl_interface* shell_surface_interface_set_maximized_request[1] = {
672 const wl_interface* shell_surface_interface_set_title_request[1] = {
676 const wl_interface* shell_surface_interface_set_class_request[1] = {
680 const wl_interface* shell_surface_interface_ping_event[1] = {
684 const wl_interface* shell_surface_interface_configure_event[3] = {
690 const wl_interface* shell_surface_interface_popup_done_event[0] = {
693 const wl_message shell_surface_interface_requests[10] = {
697 shell_surface_interface_pong_request,
702 shell_surface_interface_move_request,
707 shell_surface_interface_resize_request,
712 shell_surface_interface_set_toplevel_request,
717 shell_surface_interface_set_transient_request,
722 shell_surface_interface_set_fullscreen_request,
727 shell_surface_interface_set_popup_request,
732 shell_surface_interface_set_maximized_request,
737 shell_surface_interface_set_title_request,
742 shell_surface_interface_set_class_request,
746 const wl_message shell_surface_interface_events[3] = {
750 shell_surface_interface_ping_event,
755 shell_surface_interface_configure_event,
760 shell_surface_interface_popup_done_event,
764 const wl_interface wayland::detail::shell_surface_interface =
769 shell_surface_interface_requests,
771 shell_surface_interface_events,
774 const wl_interface* surface_interface_destroy_request[0] = {
777 const wl_interface* surface_interface_attach_request[3] = {
783 const wl_interface* surface_interface_damage_request[4] = {
790 const wl_interface* surface_interface_frame_request[1] = {
794 const wl_interface* surface_interface_set_opaque_region_request[1] = {
798 const wl_interface* surface_interface_set_input_region_request[1] = {
802 const wl_interface* surface_interface_commit_request[0] = {
805 const wl_interface* surface_interface_set_buffer_transform_request[1] = {
809 const wl_interface* surface_interface_set_buffer_scale_request[1] = {
813 const wl_interface* surface_interface_damage_buffer_request[4] = {
820 const wl_interface* surface_interface_enter_event[1] = {
824 const wl_interface* surface_interface_leave_event[1] = {
828 const wl_message surface_interface_requests[10] = {
832 surface_interface_destroy_request,
837 surface_interface_attach_request,
842 surface_interface_damage_request,
847 surface_interface_frame_request,
852 surface_interface_set_opaque_region_request,
857 surface_interface_set_input_region_request,
862 surface_interface_commit_request,
865 "set_buffer_transform",
867 surface_interface_set_buffer_transform_request,
872 surface_interface_set_buffer_scale_request,
877 surface_interface_damage_buffer_request,
881 const wl_message surface_interface_events[2] = {
885 surface_interface_enter_event,
890 surface_interface_leave_event,
894 const wl_interface wayland::detail::surface_interface =
899 surface_interface_requests,
901 surface_interface_events,
904 const wl_interface* seat_interface_get_pointer_request[1] = {
908 const wl_interface* seat_interface_get_keyboard_request[1] = {
912 const wl_interface* seat_interface_get_touch_request[1] = {
916 const wl_interface* seat_interface_release_request[0] = {
919 const wl_interface* seat_interface_capabilities_event[1] = {
923 const wl_interface* seat_interface_name_event[1] = {
927 const wl_message seat_interface_requests[4] = {
931 seat_interface_get_pointer_request,
936 seat_interface_get_keyboard_request,
941 seat_interface_get_touch_request,
946 seat_interface_release_request,
950 const wl_message seat_interface_events[2] = {
954 seat_interface_capabilities_event,
959 seat_interface_name_event,
963 const wl_interface wayland::detail::seat_interface =
968 seat_interface_requests,
970 seat_interface_events,
973 const wl_interface* pointer_interface_set_cursor_request[4] = {
980 const wl_interface* pointer_interface_release_request[0] = {
983 const wl_interface* pointer_interface_enter_event[4] = {
990 const wl_interface* pointer_interface_leave_event[2] = {
995 const wl_interface* pointer_interface_motion_event[3] = {
1001 const wl_interface* pointer_interface_button_event[4] = {
1008 const wl_interface* pointer_interface_axis_event[3] = {
1014 const wl_interface* pointer_interface_frame_event[0] = {
1017 const wl_interface* pointer_interface_axis_source_event[1] = {
1021 const wl_interface* pointer_interface_axis_stop_event[2] = {
1026 const wl_interface* pointer_interface_axis_discrete_event[2] = {
1031 const wl_message pointer_interface_requests[2] = {
1035 pointer_interface_set_cursor_request,
1040 pointer_interface_release_request,
1044 const wl_message pointer_interface_events[9] = {
1048 pointer_interface_enter_event,
1053 pointer_interface_leave_event,
1058 pointer_interface_motion_event,
1063 pointer_interface_button_event,
1068 pointer_interface_axis_event,
1073 pointer_interface_frame_event,
1078 pointer_interface_axis_source_event,
1083 pointer_interface_axis_stop_event,
1088 pointer_interface_axis_discrete_event,
1092 const wl_interface wayland::detail::pointer_interface =
1097 pointer_interface_requests,
1099 pointer_interface_events,
1102 const wl_interface* keyboard_interface_release_request[0] = {
1105 const wl_interface* keyboard_interface_keymap_event[3] = {
1111 const wl_interface* keyboard_interface_enter_event[3] = {
1117 const wl_interface* keyboard_interface_leave_event[2] = {
1122 const wl_interface* keyboard_interface_key_event[4] = {
1129 const wl_interface* keyboard_interface_modifiers_event[5] = {
1137 const wl_interface* keyboard_interface_repeat_info_event[2] = {
1142 const wl_message keyboard_interface_requests[1] = {
1146 keyboard_interface_release_request,
1150 const wl_message keyboard_interface_events[6] = {
1154 keyboard_interface_keymap_event,
1159 keyboard_interface_enter_event,
1164 keyboard_interface_leave_event,
1169 keyboard_interface_key_event,
1174 keyboard_interface_modifiers_event,
1179 keyboard_interface_repeat_info_event,
1183 const wl_interface wayland::detail::keyboard_interface =
1188 keyboard_interface_requests,
1190 keyboard_interface_events,
1193 const wl_interface* touch_interface_release_request[0] = {
1196 const wl_interface* touch_interface_down_event[6] = {
1205 const wl_interface* touch_interface_up_event[3] = {
1211 const wl_interface* touch_interface_motion_event[4] = {
1218 const wl_interface* touch_interface_frame_event[0] = {
1221 const wl_interface* touch_interface_cancel_event[0] = {
1224 const wl_interface* touch_interface_shape_event[3] = {
1230 const wl_interface* touch_interface_orientation_event[2] = {
1235 const wl_message touch_interface_requests[1] = {
1239 touch_interface_release_request,
1243 const wl_message touch_interface_events[7] = {
1247 touch_interface_down_event,
1252 touch_interface_up_event,
1257 touch_interface_motion_event,
1262 touch_interface_frame_event,
1267 touch_interface_cancel_event,
1272 touch_interface_shape_event,
1277 touch_interface_orientation_event,
1281 const wl_interface wayland::detail::touch_interface =
1286 touch_interface_requests,
1288 touch_interface_events,
1291 const wl_interface* output_interface_release_request[0] = {
1294 const wl_interface* output_interface_geometry_event[8] = {
1305 const wl_interface* output_interface_mode_event[4] = {
1312 const wl_interface* output_interface_done_event[0] = {
1315 const wl_interface* output_interface_scale_event[1] = {
1319 const wl_message output_interface_requests[1] = {
1323 output_interface_release_request,
1327 const wl_message output_interface_events[4] = {
1331 output_interface_geometry_event,
1336 output_interface_mode_event,
1341 output_interface_done_event,
1346 output_interface_scale_event,
1350 const wl_interface wayland::detail::output_interface =
1355 output_interface_requests,
1357 output_interface_events,
1360 const wl_interface* region_interface_destroy_request[0] = {
1363 const wl_interface* region_interface_add_request[4] = {
1370 const wl_interface* region_interface_subtract_request[4] = {
1377 const wl_message region_interface_requests[3] = {
1381 region_interface_destroy_request,
1386 region_interface_add_request,
1391 region_interface_subtract_request,
1395 const wl_message region_interface_events[0] = {
1398 const wl_interface wayland::detail::region_interface =
1403 region_interface_requests,
1405 region_interface_events,
1408 const wl_interface* subcompositor_interface_destroy_request[0] = {
1411 const wl_interface* subcompositor_interface_get_subsurface_request[3] = {
1412 &subsurface_interface,
1417 const wl_message subcompositor_interface_requests[2] = {
1421 subcompositor_interface_destroy_request,
1426 subcompositor_interface_get_subsurface_request,
1430 const wl_message subcompositor_interface_events[0] = {
1433 const wl_interface wayland::detail::subcompositor_interface =
1438 subcompositor_interface_requests,
1440 subcompositor_interface_events,
1443 const wl_interface* subsurface_interface_destroy_request[0] = {
1446 const wl_interface* subsurface_interface_set_position_request[2] = {
1451 const wl_interface* subsurface_interface_place_above_request[1] = {
1455 const wl_interface* subsurface_interface_place_below_request[1] = {
1459 const wl_interface* subsurface_interface_set_sync_request[0] = {
1462 const wl_interface* subsurface_interface_set_desync_request[0] = {
1465 const wl_message subsurface_interface_requests[6] = {
1469 subsurface_interface_destroy_request,
1474 subsurface_interface_set_position_request,
1479 subsurface_interface_place_above_request,
1484 subsurface_interface_place_below_request,
1489 subsurface_interface_set_sync_request,
1494 subsurface_interface_set_desync_request,
1498 const wl_message subsurface_interface_events[0] = {
1501 const wl_interface wayland::detail::subsurface_interface =
1506 subsurface_interface_requests,
1508 subsurface_interface_events,
1511 registry_t::registry_t(
const proxy_t &p)
1516 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1518 interface = ®istry_interface;
1523 registry_t::registry_t()
1525 interface = ®istry_interface;
1530 registry_t::registry_t(wl_registry *p, wrapper_type t)
1531 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1534 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1536 interface = ®istry_interface;
1541 registry_t::registry_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
1542 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1543 interface = ®istry_interface;
1548 registry_t registry_t::proxy_create_wrapper()
1550 return {*
this, construct_proxy_wrapper_tag()};
1553 const std::string registry_t::interface_name =
"wl_registry";
1555 registry_t::operator wl_registry*()
const
1557 return reinterpret_cast<wl_registry*> (c_ptr());
1562 proxy_t p = marshal_constructor_versioned(0u, interface.interface, version, name, std::string(interface.interface->name), version,
nullptr);
1563 interface = interface.copy_constructor(p);
1569 return std::static_pointer_cast<events_t>(get_events())->global;
1574 return std::static_pointer_cast<events_t>(get_events())->global_remove;
1577 int registry_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1579 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
1583 if(events->global) events->global(args[0].get<uint32_t>(), args[1].get<std::string>(), args[2].get<uint32_t>());
1586 if(events->global_remove) events->global_remove(args[0].get<uint32_t>());
1592 callback_t::callback_t(
const proxy_t &p)
1597 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1599 interface = &callback_interface;
1604 callback_t::callback_t()
1606 interface = &callback_interface;
1611 callback_t::callback_t(wl_callback *p, wrapper_type t)
1612 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1615 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1617 interface = &callback_interface;
1622 callback_t::callback_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
1623 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1624 interface = &callback_interface;
1629 callback_t callback_t::proxy_create_wrapper()
1631 return {*
this, construct_proxy_wrapper_tag()};
1634 const std::string callback_t::interface_name =
"wl_callback";
1636 callback_t::operator wl_callback*()
const
1638 return reinterpret_cast<wl_callback*> (c_ptr());
1643 return std::static_pointer_cast<events_t>(get_events())->done;
1646 int callback_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1648 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
1652 if(events->done) events->done(args[0].get<uint32_t>());
1658 compositor_t::compositor_t(
const proxy_t &p)
1663 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1665 interface = &compositor_interface;
1670 compositor_t::compositor_t()
1672 interface = &compositor_interface;
1677 compositor_t::compositor_t(wl_compositor *p, wrapper_type t)
1678 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1681 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1683 interface = &compositor_interface;
1688 compositor_t::compositor_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
1689 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1690 interface = &compositor_interface;
1697 return {*
this, construct_proxy_wrapper_tag()};
1700 const std::string compositor_t::interface_name =
"wl_compositor";
1702 compositor_t::operator wl_compositor*()
const
1704 return reinterpret_cast<wl_compositor*> (c_ptr());
1709 proxy_t p = marshal_constructor(0u, &surface_interface,
nullptr);
1715 proxy_t p = marshal_constructor(1u, ®ion_interface,
nullptr);
1719 int compositor_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1724 shm_pool_t::shm_pool_t(
const proxy_t &p)
1729 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1730 set_destroy_opcode(1u);
1732 interface = &shm_pool_interface;
1737 shm_pool_t::shm_pool_t()
1739 interface = &shm_pool_interface;
1744 shm_pool_t::shm_pool_t(wl_shm_pool *p, wrapper_type t)
1745 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1748 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1749 set_destroy_opcode(1u);
1751 interface = &shm_pool_interface;
1756 shm_pool_t::shm_pool_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
1757 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1758 interface = &shm_pool_interface;
1763 shm_pool_t shm_pool_t::proxy_create_wrapper()
1765 return {*
this, construct_proxy_wrapper_tag()};
1768 const std::string shm_pool_t::interface_name =
"wl_shm_pool";
1770 shm_pool_t::operator wl_shm_pool*()
const
1772 return reinterpret_cast<wl_shm_pool*> (c_ptr());
1777 proxy_t p = marshal_constructor(0u, &buffer_interface,
nullptr, offset, width, height, stride, static_cast<uint32_t>(format));
1786 int shm_pool_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1791 shm_t::shm_t(
const proxy_t &p)
1796 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1798 interface = &shm_interface;
1800 {
return shm_t(p); };
1805 interface = &shm_interface;
1807 {
return shm_t(p); };
1810 shm_t::shm_t(wl_shm *p, wrapper_type t)
1811 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1814 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1816 interface = &shm_interface;
1818 {
return shm_t(p); };
1821 shm_t::shm_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
1822 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1823 interface = &shm_interface;
1825 {
return shm_t(p); };
1828 shm_t shm_t::proxy_create_wrapper()
1830 return {*
this, construct_proxy_wrapper_tag()};
1833 const std::string shm_t::interface_name =
"wl_shm";
1835 shm_t::operator wl_shm*()
const
1837 return reinterpret_cast<wl_shm*> (c_ptr());
1842 proxy_t p = marshal_constructor(0u, &shm_pool_interface,
nullptr, argument_t::fd(fd), size);
1848 return std::static_pointer_cast<events_t>(get_events())->format;
1851 int shm_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1853 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
1857 if(events->format) events->format(shm_format(args[0].get<uint32_t>()));
1865 buffer_t::buffer_t(
const proxy_t &p)
1870 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1871 set_destroy_opcode(0u);
1873 interface = &buffer_interface;
1878 buffer_t::buffer_t()
1880 interface = &buffer_interface;
1885 buffer_t::buffer_t(wl_buffer *p, wrapper_type t)
1886 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1889 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1890 set_destroy_opcode(0u);
1892 interface = &buffer_interface;
1897 buffer_t::buffer_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
1898 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1899 interface = &buffer_interface;
1904 buffer_t buffer_t::proxy_create_wrapper()
1906 return {*
this, construct_proxy_wrapper_tag()};
1909 const std::string buffer_t::interface_name =
"wl_buffer";
1911 buffer_t::operator wl_buffer*()
const
1913 return reinterpret_cast<wl_buffer*> (c_ptr());
1918 return std::static_pointer_cast<events_t>(get_events())->release;
1921 int buffer_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
1923 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
1927 if(events->release) events->release();
1933 data_offer_t::data_offer_t(
const proxy_t &p)
1938 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1939 set_destroy_opcode(2u);
1941 interface = &data_offer_interface;
1946 data_offer_t::data_offer_t()
1948 interface = &data_offer_interface;
1953 data_offer_t::data_offer_t(wl_data_offer *p, wrapper_type t)
1954 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
1957 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
1958 set_destroy_opcode(2u);
1960 interface = &data_offer_interface;
1965 data_offer_t::data_offer_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
1966 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
1967 interface = &data_offer_interface;
1974 return {*
this, construct_proxy_wrapper_tag()};
1977 const std::string data_offer_t::interface_name =
"wl_data_offer";
1979 data_offer_t::operator wl_data_offer*()
const
1981 return reinterpret_cast<wl_data_offer*> (c_ptr());
1986 marshal(0u, serial, mime_type);
1991 marshal(1u, mime_type, argument_t::fd(fd));
2005 marshal(4u, static_cast<uint32_t>(dnd_actions), static_cast<uint32_t>(preferred_action));
2014 return std::static_pointer_cast<events_t>(get_events())->offer;
2019 return std::static_pointer_cast<events_t>(get_events())->source_actions;
2024 return std::static_pointer_cast<events_t>(get_events())->action;
2027 int data_offer_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2029 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
2033 if(events->offer) events->offer(args[0].get<std::string>());
2046 data_source_t::data_source_t(
const proxy_t &p)
2051 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2052 set_destroy_opcode(1u);
2054 interface = &data_source_interface;
2059 data_source_t::data_source_t()
2061 interface = &data_source_interface;
2066 data_source_t::data_source_t(wl_data_source *p, wrapper_type t)
2067 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2070 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2071 set_destroy_opcode(1u);
2073 interface = &data_source_interface;
2078 data_source_t::data_source_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2079 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2080 interface = &data_source_interface;
2087 return {*
this, construct_proxy_wrapper_tag()};
2090 const std::string data_source_t::interface_name =
"wl_data_source";
2092 data_source_t::operator wl_data_source*()
const
2094 return reinterpret_cast<wl_data_source*> (c_ptr());
2099 marshal(0u, mime_type);
2104 marshal(2u, static_cast<uint32_t>(dnd_actions));
2113 return std::static_pointer_cast<events_t>(get_events())->target;
2118 return std::static_pointer_cast<events_t>(get_events())->send;
2123 return std::static_pointer_cast<events_t>(get_events())->cancelled;
2128 return std::static_pointer_cast<events_t>(get_events())->dnd_drop_performed;
2133 return std::static_pointer_cast<events_t>(get_events())->dnd_finished;
2138 return std::static_pointer_cast<events_t>(get_events())->action;
2141 int data_source_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2143 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
2147 if(events->target) events->target(args[0].get<std::string>());
2150 if(events->send) events->send(args[0].get<std::string>(), args[1].get<int>());
2153 if(events->cancelled) events->cancelled();
2156 if(events->dnd_drop_performed) events->dnd_drop_performed();
2159 if(events->dnd_finished) events->dnd_finished();
2169 data_device_t::data_device_t(
const proxy_t &p)
2174 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2176 interface = &data_device_interface;
2181 data_device_t::data_device_t()
2183 interface = &data_device_interface;
2188 data_device_t::data_device_t(wl_data_device *p, wrapper_type t)
2189 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2192 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2194 interface = &data_device_interface;
2199 data_device_t::data_device_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2200 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2201 interface = &data_device_interface;
2208 return {*
this, construct_proxy_wrapper_tag()};
2211 const std::string data_device_t::interface_name =
"wl_data_device";
2213 data_device_t::operator wl_data_device*()
const
2215 return reinterpret_cast<wl_data_device*> (c_ptr());
2225 marshal(1u, source.
proxy_has_object() ? reinterpret_cast<wl_object*>(source.
c_ptr()) :
nullptr, serial);
2239 return std::static_pointer_cast<events_t>(get_events())->data_offer;
2244 return std::static_pointer_cast<events_t>(get_events())->enter;
2249 return std::static_pointer_cast<events_t>(get_events())->leave;
2254 return std::static_pointer_cast<events_t>(get_events())->motion;
2259 return std::static_pointer_cast<events_t>(get_events())->drop;
2264 return std::static_pointer_cast<events_t>(get_events())->selection;
2267 int data_device_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2269 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
2273 if(events->data_offer) events->data_offer(
data_offer_t(args[0].get<proxy_t>()));
2276 if(events->enter) events->enter(args[0].get<uint32_t>(),
surface_t(args[1].get<proxy_t>()), args[2].get<double>(), args[3].get<double>(),
data_offer_t(args[4].get<proxy_t>()));
2279 if(events->leave) events->leave();
2282 if(events->motion) events->motion(args[0].get<uint32_t>(), args[1].get<double>(), args[2].get<double>());
2285 if(events->drop) events->drop();
2288 if(events->selection) events->selection(
data_offer_t(args[0].get<proxy_t>()));
2295 data_device_manager_t::data_device_manager_t(
const proxy_t &p)
2300 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2302 interface = &data_device_manager_interface;
2307 data_device_manager_t::data_device_manager_t()
2309 interface = &data_device_manager_interface;
2314 data_device_manager_t::data_device_manager_t(wl_data_device_manager *p, wrapper_type t)
2315 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2318 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2320 interface = &data_device_manager_interface;
2325 data_device_manager_t::data_device_manager_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2326 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2327 interface = &data_device_manager_interface;
2334 return {*
this, construct_proxy_wrapper_tag()};
2337 const std::string data_device_manager_t::interface_name =
"wl_data_device_manager";
2339 data_device_manager_t::operator wl_data_device_manager*()
const
2341 return reinterpret_cast<wl_data_device_manager*> (c_ptr());
2346 proxy_t p = marshal_constructor(0u, &data_source_interface,
nullptr);
2352 proxy_t p = marshal_constructor(1u, &data_device_interface,
nullptr, seat.
proxy_has_object() ? reinterpret_cast<wl_object*>(seat.
c_ptr()) :
nullptr);
2356 int data_device_manager_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2366 shell_t::shell_t(
const proxy_t &p)
2371 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2373 interface = &shell_interface;
2380 interface = &shell_interface;
2385 shell_t::shell_t(wl_shell *p, wrapper_type t)
2386 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2389 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2391 interface = &shell_interface;
2396 shell_t::shell_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2397 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2398 interface = &shell_interface;
2403 shell_t shell_t::proxy_create_wrapper()
2405 return {*
this, construct_proxy_wrapper_tag()};
2408 const std::string shell_t::interface_name =
"wl_shell";
2410 shell_t::operator wl_shell*()
const
2412 return reinterpret_cast<wl_shell*> (c_ptr());
2417 proxy_t p = marshal_constructor(0u, &shell_surface_interface,
nullptr, surface.
proxy_has_object() ? reinterpret_cast<wl_object*>(surface.
c_ptr()) :
nullptr);
2421 int shell_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2427 shell_surface_t::shell_surface_t(
const proxy_t &p)
2432 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2434 interface = &shell_surface_interface;
2439 shell_surface_t::shell_surface_t()
2441 interface = &shell_surface_interface;
2446 shell_surface_t::shell_surface_t(wl_shell_surface *p, wrapper_type t)
2447 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2450 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2452 interface = &shell_surface_interface;
2457 shell_surface_t::shell_surface_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2458 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2459 interface = &shell_surface_interface;
2466 return {*
this, construct_proxy_wrapper_tag()};
2469 const std::string shell_surface_t::interface_name =
"wl_shell_surface";
2471 shell_surface_t::operator wl_shell_surface*()
const
2473 return reinterpret_cast<wl_shell_surface*> (c_ptr());
2478 marshal(0u, serial);
2483 marshal(1u, seat.
proxy_has_object() ? reinterpret_cast<wl_object*>(seat.
c_ptr()) :
nullptr, serial);
2488 marshal(2u, seat.
proxy_has_object() ? reinterpret_cast<wl_object*>(seat.
c_ptr()) :
nullptr, serial, static_cast<uint32_t>(edges));
2498 marshal(4u, parent.
proxy_has_object() ? reinterpret_cast<wl_object*>(parent.
c_ptr()) :
nullptr, x, y, static_cast<uint32_t>(flags));
2503 marshal(5u, static_cast<uint32_t>(method), framerate, output.
proxy_has_object() ? reinterpret_cast<wl_object*>(output.
c_ptr()) :
nullptr);
2508 marshal(6u, seat.
proxy_has_object() ? reinterpret_cast<wl_object*>(seat.
c_ptr()) :
nullptr, serial, parent.
proxy_has_object() ? reinterpret_cast<wl_object*>(parent.
c_ptr()) :
nullptr, x, y, static_cast<uint32_t>(flags));
2523 marshal(9u, class_);
2528 return std::static_pointer_cast<events_t>(get_events())->ping;
2533 return std::static_pointer_cast<events_t>(get_events())->configure;
2538 return std::static_pointer_cast<events_t>(get_events())->popup_done;
2541 int shell_surface_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2543 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
2547 if(events->ping) events->ping(args[0].get<uint32_t>());
2550 if(events->configure) events->configure(
shell_surface_resize(args[0].get<uint32_t>()), args[1].get<int32_t>(), args[2].get<int32_t>());
2553 if(events->popup_done) events->popup_done();
2572 surface_t::surface_t(
const proxy_t &p)
2577 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2578 set_destroy_opcode(0u);
2580 interface = &surface_interface;
2585 surface_t::surface_t()
2587 interface = &surface_interface;
2592 surface_t::surface_t(wl_surface *p, wrapper_type t)
2593 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2596 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2597 set_destroy_opcode(0u);
2599 interface = &surface_interface;
2604 surface_t::surface_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2605 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2606 interface = &surface_interface;
2611 surface_t surface_t::proxy_create_wrapper()
2613 return {*
this, construct_proxy_wrapper_tag()};
2616 const std::string surface_t::interface_name =
"wl_surface";
2618 surface_t::operator wl_surface*()
const
2620 return reinterpret_cast<wl_surface*> (c_ptr());
2625 marshal(1u, buffer.
proxy_has_object() ? reinterpret_cast<wl_object*>(buffer.
c_ptr()) :
nullptr, x, y);
2630 marshal(2u, x, y, width, height);
2635 proxy_t p = marshal_constructor(3u, &callback_interface,
nullptr);
2656 marshal(7u, static_cast<int32_t>(transform));
2674 marshal(9u, x, y, width, height);
2683 return std::static_pointer_cast<events_t>(get_events())->enter;
2688 return std::static_pointer_cast<events_t>(get_events())->leave;
2691 int surface_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2693 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
2697 if(events->enter) events->enter(
output_t(args[0].get<proxy_t>()));
2700 if(events->leave) events->leave(
output_t(args[0].get<proxy_t>()));
2707 seat_t::seat_t(
const proxy_t &p)
2712 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2714 interface = &seat_interface;
2721 interface = &seat_interface;
2726 seat_t::seat_t(wl_seat *p, wrapper_type t)
2727 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2730 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2732 interface = &seat_interface;
2737 seat_t::seat_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2738 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2739 interface = &seat_interface;
2744 seat_t seat_t::proxy_create_wrapper()
2746 return {*
this, construct_proxy_wrapper_tag()};
2749 const std::string seat_t::interface_name =
"wl_seat";
2751 seat_t::operator wl_seat*()
const
2753 return reinterpret_cast<wl_seat*> (c_ptr());
2758 proxy_t p = marshal_constructor(0u, &pointer_interface,
nullptr);
2764 proxy_t p = marshal_constructor(1u, &keyboard_interface,
nullptr);
2770 proxy_t p = marshal_constructor(2u, &touch_interface,
nullptr);
2785 return std::static_pointer_cast<events_t>(get_events())->capabilities;
2790 return std::static_pointer_cast<events_t>(get_events())->name;
2793 int seat_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2795 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
2799 if(events->capabilities) events->capabilities(
seat_capability(args[0].get<uint32_t>()));
2802 if(events->name) events->name(args[0].get<std::string>());
2812 pointer_t::pointer_t(
const proxy_t &p)
2817 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2819 interface = &pointer_interface;
2824 pointer_t::pointer_t()
2826 interface = &pointer_interface;
2831 pointer_t::pointer_t(wl_pointer *p, wrapper_type t)
2832 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2835 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2837 interface = &pointer_interface;
2842 pointer_t::pointer_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2843 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2844 interface = &pointer_interface;
2849 pointer_t pointer_t::proxy_create_wrapper()
2851 return {*
this, construct_proxy_wrapper_tag()};
2854 const std::string pointer_t::interface_name =
"wl_pointer";
2856 pointer_t::operator wl_pointer*()
const
2858 return reinterpret_cast<wl_pointer*> (c_ptr());
2863 marshal(0u, serial, surface.
proxy_has_object() ? reinterpret_cast<wl_object*>(surface.
c_ptr()) :
nullptr, hotspot_x, hotspot_y);
2877 return std::static_pointer_cast<events_t>(get_events())->enter;
2882 return std::static_pointer_cast<events_t>(get_events())->leave;
2887 return std::static_pointer_cast<events_t>(get_events())->motion;
2892 return std::static_pointer_cast<events_t>(get_events())->button;
2897 return std::static_pointer_cast<events_t>(get_events())->axis;
2902 return std::static_pointer_cast<events_t>(get_events())->frame;
2907 return std::static_pointer_cast<events_t>(get_events())->axis_source;
2912 return std::static_pointer_cast<events_t>(get_events())->axis_stop;
2917 return std::static_pointer_cast<events_t>(get_events())->axis_discrete;
2920 int pointer_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
2922 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
2926 if(events->enter) events->enter(args[0].get<uint32_t>(),
surface_t(args[1].get<proxy_t>()), args[2].get<double>(), args[3].get<double>());
2929 if(events->leave) events->leave(args[0].get<uint32_t>(),
surface_t(args[1].get<proxy_t>()));
2932 if(events->motion) events->motion(args[0].get<uint32_t>(), args[1].get<double>(), args[2].get<double>());
2935 if(events->button) events->button(args[0].get<uint32_t>(), args[1].get<uint32_t>(), args[2].get<uint32_t>(), pointer_button_state(args[3].get<uint32_t>()));
2938 if(events->axis) events->axis(args[0].get<uint32_t>(), pointer_axis(args[1].get<uint32_t>()), args[2].get<double>());
2941 if(events->frame) events->frame();
2944 if(events->axis_source) events->axis_source(pointer_axis_source(args[0].get<uint32_t>()));
2947 if(events->axis_stop) events->axis_stop(args[0].get<uint32_t>(), pointer_axis(args[1].get<uint32_t>()));
2950 if(events->axis_discrete) events->axis_discrete(pointer_axis(args[0].get<uint32_t>()), args[1].get<int32_t>());
2960 keyboard_t::keyboard_t(
const proxy_t &p)
2965 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2967 interface = &keyboard_interface;
2972 keyboard_t::keyboard_t()
2974 interface = &keyboard_interface;
2979 keyboard_t::keyboard_t(wl_keyboard *p, wrapper_type t)
2980 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
2983 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
2985 interface = &keyboard_interface;
2990 keyboard_t::keyboard_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
2991 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
2992 interface = &keyboard_interface;
2997 keyboard_t keyboard_t::proxy_create_wrapper()
2999 return {*
this, construct_proxy_wrapper_tag()};
3002 const std::string keyboard_t::interface_name =
"wl_keyboard";
3004 keyboard_t::operator wl_keyboard*()
const
3006 return reinterpret_cast<wl_keyboard*> (c_ptr());
3020 return std::static_pointer_cast<events_t>(get_events())->keymap;
3025 return std::static_pointer_cast<events_t>(get_events())->enter;
3030 return std::static_pointer_cast<events_t>(get_events())->leave;
3035 return std::static_pointer_cast<events_t>(get_events())->key;
3040 return std::static_pointer_cast<events_t>(get_events())->modifiers;
3045 return std::static_pointer_cast<events_t>(get_events())->repeat_info;
3048 int keyboard_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
3050 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
3054 if(events->keymap) events->keymap(keyboard_keymap_format(args[0].get<uint32_t>()), args[1].get<int>(), args[2].get<uint32_t>());
3057 if(events->enter) events->enter(args[0].get<uint32_t>(),
surface_t(args[1].get<proxy_t>()), args[2].get<array_t>());
3060 if(events->leave) events->leave(args[0].get<uint32_t>(),
surface_t(args[1].get<proxy_t>()));
3063 if(events->key) events->key(args[0].get<uint32_t>(), args[1].get<uint32_t>(), args[2].get<uint32_t>(), keyboard_key_state(args[3].get<uint32_t>()));
3066 if(events->modifiers) events->modifiers(args[0].get<uint32_t>(), args[1].get<uint32_t>(), args[2].get<uint32_t>(), args[3].get<uint32_t>(), args[4].get<uint32_t>());
3069 if(events->repeat_info) events->repeat_info(args[0].get<int32_t>(), args[1].get<int32_t>());
3077 touch_t::touch_t(
const proxy_t &p)
3082 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3084 interface = &touch_interface;
3091 interface = &touch_interface;
3096 touch_t::touch_t(wl_touch *p, wrapper_type t)
3097 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
3100 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3102 interface = &touch_interface;
3107 touch_t::touch_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
3108 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
3109 interface = &touch_interface;
3114 touch_t touch_t::proxy_create_wrapper()
3116 return {*
this, construct_proxy_wrapper_tag()};
3119 const std::string touch_t::interface_name =
"wl_touch";
3121 touch_t::operator wl_touch*()
const
3123 return reinterpret_cast<wl_touch*> (c_ptr());
3137 return std::static_pointer_cast<events_t>(get_events())->down;
3142 return std::static_pointer_cast<events_t>(get_events())->up;
3147 return std::static_pointer_cast<events_t>(get_events())->motion;
3152 return std::static_pointer_cast<events_t>(get_events())->frame;
3157 return std::static_pointer_cast<events_t>(get_events())->cancel;
3162 return std::static_pointer_cast<events_t>(get_events())->shape;
3167 return std::static_pointer_cast<events_t>(get_events())->orientation;
3170 int touch_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
3172 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
3176 if(events->down) events->down(args[0].get<uint32_t>(), args[1].get<uint32_t>(),
surface_t(args[2].get<proxy_t>()), args[3].get<int32_t>(), args[4].get<double>(), args[5].get<double>());
3179 if(events->up) events->up(args[0].get<uint32_t>(), args[1].get<uint32_t>(), args[2].get<int32_t>());
3182 if(events->motion) events->motion(args[0].get<uint32_t>(), args[1].get<int32_t>(), args[2].get<double>(), args[3].get<double>());
3185 if(events->frame) events->frame();
3188 if(events->cancel) events->cancel();
3191 if(events->shape) events->shape(args[0].get<int32_t>(), args[1].get<double>(), args[2].get<double>());
3194 if(events->orientation) events->orientation(args[0].get<int32_t>(), args[1].get<double>());
3200 output_t::output_t(
const proxy_t &p)
3205 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3207 interface = &output_interface;
3212 output_t::output_t()
3214 interface = &output_interface;
3219 output_t::output_t(wl_output *p, wrapper_type t)
3220 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
3223 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3225 interface = &output_interface;
3230 output_t::output_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
3231 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
3232 interface = &output_interface;
3237 output_t output_t::proxy_create_wrapper()
3239 return {*
this, construct_proxy_wrapper_tag()};
3242 const std::string output_t::interface_name =
"wl_output";
3244 output_t::operator wl_output*()
const
3246 return reinterpret_cast<wl_output*> (c_ptr());
3260 return std::static_pointer_cast<events_t>(get_events())->geometry;
3265 return std::static_pointer_cast<events_t>(get_events())->mode;
3270 return std::static_pointer_cast<events_t>(get_events())->done;
3275 return std::static_pointer_cast<events_t>(get_events())->scale;
3278 int output_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
3280 std::shared_ptr<events_t> events = std::static_pointer_cast<events_t>(e);
3284 if(events->geometry) events->geometry(args[0].get<int32_t>(), args[1].get<int32_t>(), args[2].get<int32_t>(), args[3].get<int32_t>(), output_subpixel(args[4].get<int32_t>()), args[5].get<std::string>(), args[6].get<std::string>(),
output_transform(args[7].get<int32_t>()));
3287 if(events->mode) events->mode(
output_mode(args[0].get<uint32_t>()), args[1].get<int32_t>(), args[2].get<int32_t>(), args[3].get<int32_t>());
3290 if(events->done) events->done();
3293 if(events->scale) events->scale(args[0].get<int32_t>());
3312 region_t::region_t(
const proxy_t &p)
3317 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3318 set_destroy_opcode(0u);
3320 interface = ®ion_interface;
3325 region_t::region_t()
3327 interface = ®ion_interface;
3332 region_t::region_t(wl_region *p, wrapper_type t)
3333 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
3336 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3337 set_destroy_opcode(0u);
3339 interface = ®ion_interface;
3344 region_t::region_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
3345 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
3346 interface = ®ion_interface;
3351 region_t region_t::proxy_create_wrapper()
3353 return {*
this, construct_proxy_wrapper_tag()};
3356 const std::string region_t::interface_name =
"wl_region";
3358 region_t::operator wl_region*()
const
3360 return reinterpret_cast<wl_region*> (c_ptr());
3365 marshal(1u, x, y, width, height);
3370 marshal(2u, x, y, width, height);
3373 int region_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
3378 subcompositor_t::subcompositor_t(
const proxy_t &p)
3383 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3384 set_destroy_opcode(0u);
3386 interface = &subcompositor_interface;
3391 subcompositor_t::subcompositor_t()
3393 interface = &subcompositor_interface;
3398 subcompositor_t::subcompositor_t(wl_subcompositor *p, wrapper_type t)
3399 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
3402 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3403 set_destroy_opcode(0u);
3405 interface = &subcompositor_interface;
3410 subcompositor_t::subcompositor_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
3411 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
3412 interface = &subcompositor_interface;
3419 return {*
this, construct_proxy_wrapper_tag()};
3422 const std::string subcompositor_t::interface_name =
"wl_subcompositor";
3424 subcompositor_t::operator wl_subcompositor*()
const
3426 return reinterpret_cast<wl_subcompositor*> (c_ptr());
3435 int subcompositor_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)
3441 subsurface_t::subsurface_t(
const proxy_t &p)
3446 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3447 set_destroy_opcode(0u);
3449 interface = &subsurface_interface;
3454 subsurface_t::subsurface_t()
3456 interface = &subsurface_interface;
3461 subsurface_t::subsurface_t(wl_subsurface *p, wrapper_type t)
3462 :
proxy_t(reinterpret_cast<wl_proxy*> (p), t){
3465 set_events(std::shared_ptr<detail::events_base_t>(
new events_t), dispatcher);
3466 set_destroy_opcode(0u);
3468 interface = &subsurface_interface;
3473 subsurface_t::subsurface_t(
proxy_t const &wrapped_proxy, construct_proxy_wrapper_tag )
3474 :
proxy_t(wrapped_proxy, construct_proxy_wrapper_tag()){
3475 interface = &subsurface_interface;
3482 return {*
this, construct_proxy_wrapper_tag()};
3485 const std::string subsurface_t::interface_name =
"wl_subsurface";
3487 subsurface_t::operator wl_subsurface*()
const
3489 return reinterpret_cast<wl_subsurface*> (c_ptr());
3517 int subsurface_t::dispatcher(uint32_t opcode, std::vector<any> args, std::shared_ptr<detail::events_base_t> e)