add unique IDs to containers

This commit is contained in:
Zandr Martin 2016-09-21 21:05:09 -05:00
parent d98c26d0ed
commit 7d947fdb95
No known key found for this signature in database
GPG key ID: AA2BB8EF77F7BBDC
4 changed files with 13 additions and 2 deletions

View file

@ -2,6 +2,7 @@
#define _SWAY_CONTAINER_H
#include <sys/types.h>
#include <wlc/wlc.h>
#include <stdint.h>
#include "list.h"
@ -58,6 +59,12 @@ struct sway_container {
*/
wlc_handle handle;
/**
* A unique ID to identify this container. Primarily used in the
* get_tree JSON output.
*/
size_t id;
enum swayc_types type;
enum swayc_layouts layout;
enum swayc_layouts prev_layout;