Move aspect_ratio from Con to Window.

relates to #665
This commit is contained in:
Ingo Bürk
2015-08-30 23:07:25 +02:00
parent f43a15acde
commit 344514bca5
5 changed files with 13 additions and 12 deletions

View File

@ -39,15 +39,16 @@ Con *con_new_skeleton(Con *parent, i3Window *window) {
Con *new = scalloc(1, sizeof(Con));
new->on_remove_child = con_on_remove_child;
TAILQ_INSERT_TAIL(&all_cons, new, all_cons);
new->aspect_ratio = 0.0;
new->type = CT_CON;
new->window = window;
new->border_style = config.default_border;
new->current_border_width = -1;
if (window)
if (window) {
new->depth = window->depth;
else
new->window->aspect_ratio = 0.0;
} else {
new->depth = XCB_COPY_FROM_PARENT;
}
DLOG("opening window\n");
TAILQ_INIT(&(new->floating_head));