aboutsummaryrefslogtreecommitdiff
path: root/include/sway/tree/view.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/sway/tree/view.h')
-rw-r--r--include/sway/tree/view.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/include/sway/tree/view.h b/include/sway/tree/view.h
index 0e7f166c..2747e7c4 100644
--- a/include/sway/tree/view.h
+++ b/include/sway/tree/view.h
@@ -38,7 +38,6 @@ struct sway_view_impl {
const char *(*get_string_prop)(struct sway_view *view,
enum sway_view_prop prop);
uint32_t (*get_int_prop)(struct sway_view *view, enum sway_view_prop prop);
- void (*get_geometry)(struct sway_view *view, struct wlr_box *box);
uint32_t (*configure)(struct sway_view *view, double lx, double ly,
int width, int height);
void (*set_activated)(struct sway_view *view, bool activated);
@@ -88,7 +87,14 @@ struct sway_view {
struct wlr_buffer *saved_buffer;
int saved_buffer_width, saved_buffer_height;
- struct wlr_box saved_geometry; // The "old" geometry during a transaction
+
+ // The geometry for whatever the client is committing, regardless of
+ // transaction state. Updated on every commit.
+ struct wlr_box geometry;
+
+ // The "old" geometry during a transaction. Used to damage the old location
+ // when a transaction is applied.
+ struct wlr_box saved_geometry;
bool destroying;
@@ -243,8 +249,6 @@ const char *view_get_shell(struct sway_view *view);
void view_get_constraints(struct sway_view *view, double *min_width,
double *max_width, double *min_height, double *max_height);
-void view_get_geometry(struct sway_view *view, struct wlr_box *box);
-
uint32_t view_configure(struct sway_view *view, double lx, double ly, int width,
int height);
@@ -289,6 +293,8 @@ void view_map(struct sway_view *view, struct wlr_surface *wlr_surface);
void view_unmap(struct sway_view *view);
+void view_update_size(struct sway_view *view, int width, int height);
+
void view_child_init(struct sway_view_child *child,
const struct sway_view_child_impl *impl, struct sway_view *view,
struct wlr_surface *surface);