Merge branch 'wlroots' into client-cursors

This commit is contained in:
emersion 2018-03-30 19:04:06 -04:00
commit 9665642765
No known key found for this signature in database
GPG key ID: 0FDE7BE0E88F5E48
26 changed files with 578 additions and 290 deletions

View file

@ -95,6 +95,7 @@ sway_cmd cmd_commands;
sway_cmd cmd_debuglog;
sway_cmd cmd_default_border;
sway_cmd cmd_default_floating_border;
sway_cmd cmd_default_orientation;
sway_cmd cmd_exec;
sway_cmd cmd_exec_always;
sway_cmd cmd_exit;
@ -125,7 +126,6 @@ sway_cmd cmd_move;
sway_cmd cmd_new_float;
sway_cmd cmd_new_window;
sway_cmd cmd_no_focus;
sway_cmd cmd_orientation;
sway_cmd cmd_output;
sway_cmd cmd_permit;
sway_cmd cmd_reject;

View file

@ -5,6 +5,7 @@
#include <wayland-server.h>
#include <wlr/types/wlr_box.h>
#include <wlr/types/wlr_output.h>
#include "sway/tree/view.h"
struct sway_server;
struct sway_container;
@ -13,17 +14,26 @@ struct sway_output {
struct wlr_output *wlr_output;
struct sway_container *swayc;
struct sway_server *server;
struct timespec last_frame;
struct wl_list layers[4]; // sway_layer_surface::link
struct wlr_box usable_area;
struct wl_listener frame;
struct timespec last_frame;
struct wlr_output_damage *damage;
struct wl_listener destroy;
struct wl_listener mode;
struct wl_listener transform;
struct wl_listener damage_destroy;
struct wl_listener damage_frame;
pid_t bg_pid;
};
void output_damage_whole(struct sway_output *output);
void output_damage_whole_view(struct sway_output *output,
struct sway_view *view);
#endif

View file

@ -18,7 +18,6 @@ struct sway_server {
const char *socket;
struct wlr_backend *backend;
struct wlr_renderer *renderer;
struct wlr_compositor *compositor;
struct wlr_data_device_manager *data_device_manager;
@ -26,7 +25,6 @@ struct sway_server {
struct sway_input_manager *input;
struct wl_listener new_output;
struct wl_listener output_frame;
struct wlr_layer_shell *layer_shell;
struct wl_listener layer_shell_surface;

View file

@ -99,8 +99,13 @@ struct sway_container *container_view_create(
struct sway_container *container_output_destroy(struct sway_container *output);
struct sway_container *container_workspace_destroy(
struct sway_container *workspace);
struct sway_container *container_view_destroy(struct sway_container *view);
struct sway_container *container_destroy(struct sway_container *cont);
struct sway_container *container_set_layout(struct sway_container *container,
enum sway_container_layout layout);
@ -140,4 +145,7 @@ void container_for_each_descendant_bfs(struct sway_container *container,
void container_for_each_descendant_dfs(struct sway_container *container,
void (*f)(struct sway_container *container, void *data), void *data);
bool container_has_anscestor(struct sway_container *descendant,
struct sway_container *anscestor);
#endif

View file

@ -39,6 +39,11 @@ struct sway_container *container_add_sibling(struct sway_container *parent,
struct sway_container *container_remove_child(struct sway_container *child);
struct sway_container *container_reap_empty(struct sway_container *container);
void container_move_to(struct sway_container* container,
struct sway_container* destination);
enum sway_container_layout container_get_default_layout(struct sway_container *output);
void container_sort_workspaces(struct sway_container *output);

View file

@ -15,6 +15,8 @@ struct sway_xdg_surface_v6 {
struct wl_listener request_move;
struct wl_listener request_resize;
struct wl_listener request_maximize;
struct wl_listener map;
struct wl_listener unmap;
struct wl_listener destroy;
int pending_width, pending_height;
@ -28,8 +30,8 @@ struct sway_xwayland_surface {
struct wl_listener request_resize;
struct wl_listener request_maximize;
struct wl_listener request_configure;
struct wl_listener unmap_notify;
struct wl_listener map_notify;
struct wl_listener map;
struct wl_listener unmap;
struct wl_listener destroy;
int pending_width, pending_height;
@ -113,4 +115,8 @@ void view_close(struct sway_view *view);
void view_update_outputs(struct sway_view *view, const struct wlr_box *before);
void view_damage_whole(struct sway_view *view);
void view_damage_from(struct sway_view *view);
#endif

View file

@ -23,4 +23,6 @@ struct sway_container *workspace_output_prev(struct sway_container *current);
struct sway_container *workspace_prev(struct sway_container *current);
bool workspace_is_visible(struct sway_container *ws);
#endif