diff options
author | Ryan Dwyer <[email protected]> | 2018-10-31 21:27:38 +1000 |
---|---|---|
committer | Ryan Dwyer <[email protected]> | 2018-11-01 18:09:51 +1000 |
commit | 9fc736f4e1804b06538191786500f927ba0cda13 (patch) | |
tree | 8399de2ba00a8a0dd57f49dfc30455c330500b54 /sway/desktop/render.c | |
parent | 480b03b734e6d1d068859b254d8ace4fb07b2c54 (diff) |
Move view marks properties to container struct
Like border properties, this will be needed to implement layout saving
and restoring.
Diffstat (limited to 'sway/desktop/render.c')
-rw-r--r-- | sway/desktop/render.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/sway/desktop/render.c b/sway/desktop/render.c index 1a72f752..cf6da682 100644 --- a/sway/desktop/render.c +++ b/sway/desktop/render.c @@ -625,19 +625,19 @@ static void render_containers_linear(struct sway_output *output, if (view_is_urgent(view)) { colors = &config->border_colors.urgent; title_texture = child->title_urgent; - marks_texture = view->marks_urgent; + marks_texture = child->marks_urgent; } else if (state->focused || parent->focused) { colors = &config->border_colors.focused; title_texture = child->title_focused; - marks_texture = view->marks_focused; + marks_texture = child->marks_focused; } else if (child == parent->active_child) { colors = &config->border_colors.focused_inactive; title_texture = child->title_focused_inactive; - marks_texture = view->marks_focused_inactive; + marks_texture = child->marks_focused_inactive; } else { colors = &config->border_colors.unfocused; title_texture = child->title_unfocused; - marks_texture = view->marks_unfocused; + marks_texture = child->marks_unfocused; } if (state->border == B_NORMAL) { @@ -681,19 +681,19 @@ static void render_containers_tabbed(struct sway_output *output, if (urgent) { colors = &config->border_colors.urgent; title_texture = child->title_urgent; - marks_texture = view ? view->marks_urgent : NULL; + marks_texture = child->marks_urgent; } else if (cstate->focused || parent->focused) { colors = &config->border_colors.focused; title_texture = child->title_focused; - marks_texture = view ? view->marks_focused : NULL; + marks_texture = child->marks_focused; } else if (child == parent->active_child) { colors = &config->border_colors.focused_inactive; title_texture = child->title_focused_inactive; - marks_texture = view ? view->marks_focused_inactive : NULL; + marks_texture = child->marks_focused_inactive; } else { colors = &config->border_colors.unfocused; title_texture = child->title_unfocused; - marks_texture = view ? view->marks_unfocused : NULL; + marks_texture = child->marks_unfocused; } int x = cstate->con_x + tab_width * i; @@ -746,19 +746,19 @@ static void render_containers_stacked(struct sway_output *output, if (urgent) { colors = &config->border_colors.urgent; title_texture = child->title_urgent; - marks_texture = view ? view->marks_urgent : NULL; + marks_texture = child->marks_urgent; } else if (cstate->focused || parent->focused) { colors = &config->border_colors.focused; title_texture = child->title_focused; - marks_texture = view ? view->marks_focused : NULL; + marks_texture = child->marks_focused; } else if (child == parent->active_child) { colors = &config->border_colors.focused_inactive; title_texture = child->title_focused_inactive; - marks_texture = view ? view->marks_focused_inactive : NULL; + marks_texture = child->marks_focused_inactive; } else { colors = &config->border_colors.unfocused; title_texture = child->title_unfocused; - marks_texture = view ? view->marks_unfocused : NULL; + marks_texture = child->marks_unfocused; } int y = parent->box.y + titlebar_height * i; @@ -841,15 +841,15 @@ static void render_floating_container(struct sway_output *soutput, if (view_is_urgent(view)) { colors = &config->border_colors.urgent; title_texture = con->title_urgent; - marks_texture = view->marks_urgent; + marks_texture = con->marks_urgent; } else if (con->current.focused) { colors = &config->border_colors.focused; title_texture = con->title_focused; - marks_texture = view->marks_focused; + marks_texture = con->marks_focused; } else { colors = &config->border_colors.unfocused; title_texture = con->title_unfocused; - marks_texture = view->marks_unfocused; + marks_texture = con->marks_unfocused; } if (con->current.border == B_NORMAL) { |