aboutsummaryrefslogtreecommitdiff
path: root/include/sway
diff options
context:
space:
mode:
Diffstat (limited to 'include/sway')
-rw-r--r--include/sway/commands.h9
-rw-r--r--include/sway/config.h13
-rw-r--r--include/sway/input/cursor.h4
-rw-r--r--include/sway/input/input-manager.h6
-rw-r--r--include/sway/input/seat.h6
5 files changed, 31 insertions, 7 deletions
diff --git a/include/sway/commands.h b/include/sway/commands.h
index 89e18c66..7d0ff838 100644
--- a/include/sway/commands.h
+++ b/include/sway/commands.h
@@ -133,7 +133,6 @@ sway_cmd cmd_force_display_urgency_hint;
sway_cmd cmd_force_focus_wrapping;
sway_cmd cmd_fullscreen;
sway_cmd cmd_gaps;
-sway_cmd cmd_hide_cursor;
sway_cmd cmd_hide_edge_borders;
sway_cmd cmd_include;
sway_cmd cmd_input;
@@ -173,6 +172,7 @@ sway_cmd cmd_swaybg_command;
sway_cmd cmd_swaynag_command;
sway_cmd cmd_swap;
sway_cmd cmd_tiling_drag;
+sway_cmd cmd_tiling_drag_threshold;
sway_cmd cmd_title_align;
sway_cmd cmd_title_format;
sway_cmd cmd_titlebar_border_thickness;
@@ -183,11 +183,9 @@ sway_cmd cmd_workspace;
sway_cmd cmd_ws_auto_back_and_forth;
sway_cmd cmd_workspace_layout;
-sway_cmd bar_cmd_activate_button;
sway_cmd bar_cmd_binding_mode_indicator;
sway_cmd bar_cmd_bindsym;
sway_cmd bar_cmd_colors;
-sway_cmd bar_cmd_context_button;
sway_cmd bar_cmd_font;
sway_cmd bar_cmd_gaps;
sway_cmd bar_cmd_mode;
@@ -198,13 +196,13 @@ sway_cmd bar_cmd_hidden_state;
sway_cmd bar_cmd_icon_theme;
sway_cmd bar_cmd_id;
sway_cmd bar_cmd_position;
-sway_cmd bar_cmd_secondary_button;
sway_cmd bar_cmd_separator_symbol;
sway_cmd bar_cmd_status_command;
sway_cmd bar_cmd_pango_markup;
sway_cmd bar_cmd_strip_workspace_numbers;
sway_cmd bar_cmd_strip_workspace_name;
sway_cmd bar_cmd_swaybar_command;
+sway_cmd bar_cmd_tray_bindsym;
sway_cmd bar_cmd_tray_output;
sway_cmd bar_cmd_tray_padding;
sway_cmd bar_cmd_wrap_scroll;
@@ -260,8 +258,9 @@ sway_cmd output_cmd_scale;
sway_cmd output_cmd_transform;
sway_cmd seat_cmd_attach;
-sway_cmd seat_cmd_fallback;
sway_cmd seat_cmd_cursor;
+sway_cmd seat_cmd_fallback;
+sway_cmd seat_cmd_hide_cursor;
sway_cmd cmd_ipc_cmd;
sway_cmd cmd_ipc_events;
diff --git a/include/sway/config.h b/include/sway/config.h
index 6610f009..ebf16e6a 100644
--- a/include/sway/config.h
+++ b/include/sway/config.h
@@ -6,6 +6,7 @@
#include <time.h>
#include <wlr/types/wlr_box.h>
#include <xkbcommon/xkbcommon.h>
+#include "../include/config.h"
#include "list.h"
#include "swaynag.h"
#include "tree/container.h"
@@ -140,6 +141,7 @@ struct seat_config {
char *name;
int fallback; // -1 means not set
list_t *attachments; // list of seat_attachment configs
+ int hide_cursor_timeout;
};
enum config_dpms {
@@ -252,6 +254,13 @@ struct bar_config {
char *binding_mode_bg;
char *binding_mode_text;
} colors;
+
+#if HAVE_TRAY
+ char *icon_theme;
+ const char *tray_bindings[10]; // mouse buttons 0-9
+ list_t *tray_outputs; // char *
+ int tray_padding;
+#endif
};
struct bar_binding {
@@ -417,7 +426,9 @@ struct sway_config {
bool auto_back_and_forth;
bool show_marks;
enum alignment title_align;
+
bool tiling_drag;
+ int tiling_drag_threshold;
bool smart_gaps;
int gaps_inner;
@@ -436,8 +447,6 @@ struct sway_config {
enum edge_border_types hide_edge_borders;
enum edge_border_types saved_edge_borders;
- int hide_cursor_timeout;
-
// border colors
struct {
struct border_colors focused;
diff --git a/include/sway/input/cursor.h b/include/sway/input/cursor.h
index 21a26f68..22e278b0 100644
--- a/include/sway/input/cursor.h
+++ b/include/sway/input/cursor.h
@@ -60,6 +60,10 @@ struct sway_cursor *sway_cursor_create(struct sway_seat *seat);
*/
void cursor_rebase(struct sway_cursor *cursor);
+void cursor_handle_activity(struct sway_cursor *cursor);
+void cursor_unhide(struct sway_cursor *cursor);
+int cursor_get_timeout(struct sway_cursor *cursor);
+
/**
* Like cursor_rebase, but also allows focus to change when the cursor enters a
* new container.
diff --git a/include/sway/input/input-manager.h b/include/sway/input/input-manager.h
index 219aa9ba..08e749dc 100644
--- a/include/sway/input/input-manager.h
+++ b/include/sway/input/input-manager.h
@@ -44,6 +44,12 @@ struct sway_seat *input_manager_get_default_seat(void);
struct sway_seat *input_manager_get_seat(const char *seat_name);
/**
+ * If none of the seat configs have a fallback setting (either true or false),
+ * create the default seat (if needed) and set it as the fallback
+ */
+void input_manager_verify_fallback_seat(void);
+
+/**
* Gets the last seat the user interacted with
*/
struct sway_seat *input_manager_current_seat(void);
diff --git a/include/sway/input/seat.h b/include/sway/input/seat.h
index bef2af77..a3c20346 100644
--- a/include/sway/input/seat.h
+++ b/include/sway/input/seat.h
@@ -39,6 +39,7 @@ enum sway_seat_operation {
OP_NONE,
OP_DOWN,
OP_MOVE_FLOATING,
+ OP_MOVE_TILING_THRESHOLD,
OP_MOVE_TILING,
OP_RESIZE_FLOATING,
OP_RESIZE_TILING,
@@ -174,6 +175,8 @@ void seat_apply_config(struct sway_seat *seat, struct seat_config *seat_config);
struct seat_config *seat_get_config(struct sway_seat *seat);
+struct seat_config *seat_get_config_by_name(const char *name);
+
bool seat_is_input_allowed(struct sway_seat *seat, struct wlr_surface *surface);
void drag_icon_update_position(struct sway_drag_icon *icon);
@@ -184,6 +187,9 @@ void seat_begin_down(struct sway_seat *seat, struct sway_container *con,
void seat_begin_move_floating(struct sway_seat *seat,
struct sway_container *con, uint32_t button);
+void seat_begin_move_tiling_threshold(struct sway_seat *seat,
+ struct sway_container *con, uint32_t button);
+
void seat_begin_move_tiling(struct sway_seat *seat,
struct sway_container *con, uint32_t button);