Remove unused function

This commit is contained in:
Mikkel Oscar Lyderik 2016-04-24 22:04:26 +02:00
parent 5a22c0f1c0
commit 856ac7d5cc
2 changed files with 2 additions and 11 deletions

View file

@ -251,11 +251,6 @@ bool swayc_is_parent_of(swayc_t *parent, swayc_t *child);
*/ */
bool swayc_is_child_of(swayc_t *child, swayc_t *parent); bool swayc_is_child_of(swayc_t *child, swayc_t *parent);
/**
* Returns true if view is stacked or tabbed.
*/
bool swayc_is_tabbed_stacked(swayc_t *view);
/** /**
* Returns the top most tabbed or stacked parent container. Returns NULL if * Returns the top most tabbed or stacked parent container. Returns NULL if
* view is not in a tabbed/stacked layout. * view is not in a tabbed/stacked layout.

View file

@ -725,7 +725,8 @@ void update_visibility_output(swayc_t *container, wlc_handle output) {
swayc_t *parent = container->parent; swayc_t *parent = container->parent;
container->visible = parent->visible; container->visible = parent->visible;
// special cases where visibility depends on focus // special cases where visibility depends on focus
if (parent->type == C_OUTPUT || swayc_is_tabbed_stacked(container)) { if (parent->type == C_OUTPUT || parent->layout == L_TABBED ||
parent->layout == L_STACKED) {
container->visible = parent->focused == container && parent->visible; container->visible = parent->focused == container && parent->visible;
} }
// Set visibility and output for view // Set visibility and output for view
@ -813,11 +814,6 @@ void close_views(swayc_t *container) {
container_map(container, close_view, NULL); container_map(container, close_view, NULL);
} }
bool swayc_is_tabbed_stacked(swayc_t *view) {
return (view->parent->layout == L_TABBED
|| view->parent->layout == L_STACKED);
}
swayc_t *swayc_tabbed_stacked_parent(swayc_t *view) { swayc_t *swayc_tabbed_stacked_parent(swayc_t *view) {
swayc_t *parent = NULL; swayc_t *parent = NULL;
if (!ASSERT_NONNULL(view)) { if (!ASSERT_NONNULL(view)) {