1 #if !defined(HIKARI_TILE_H) 2 #define HIKARI_TILE_H 3 4 #include <wlr/types/wlr_box.h> 5 6 struct hikari_layout; 7 struct hikari_view; 8 9 struct hikari_tile { 10 struct hikari_view *view; 11 struct hikari_layout *layout; 12 struct wlr_box view_geometry; 13 struct wlr_box tile_geometry; 14 15 struct wl_list layout_tiles; 16 }; 17 18 void 19 hikari_tile_init(struct hikari_tile *tile, 20 struct hikari_view *view, 21 struct hikari_layout *layout, 22 struct wlr_box *tile_geometry, 23 struct wlr_box *view_geometry); 24 25 struct hikari_view * 26 hikari_tile_next_view(struct hikari_tile *tile); 27 28 struct hikari_view * 29 hikari_tile_prev_view(struct hikari_tile *tile); 30 31 void 32 hikari_tile_detach(struct hikari_tile *tile); 33 34 static inline bool hikari_tile_is_attached(struct hikari_tile * tile)35hikari_tile_is_attached(struct hikari_tile *tile) 36 { 37 return tile->layout != NULL; 38 } 39 40 #endif 41