Removed unneeded can_blur_xray field
This commit is contained in:
parent
8b9add0641
commit
aa65f2e77c
4 changed files with 6 additions and 11 deletions
|
@ -33,7 +33,6 @@ struct decoration_data {
|
||||||
float *dim_color;
|
float *dim_color;
|
||||||
bool has_titlebar;
|
bool has_titlebar;
|
||||||
bool blur;
|
bool blur;
|
||||||
bool can_blur_xray;
|
|
||||||
bool shadow;
|
bool shadow;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -45,8 +45,7 @@ struct decoration_data get_undecorated_decoration_data() {
|
||||||
.saturation = 1.0f,
|
.saturation = 1.0f,
|
||||||
.has_titlebar = false,
|
.has_titlebar = false,
|
||||||
.blur = false,
|
.blur = false,
|
||||||
.can_blur_xray = false, \
|
.shadow = false,
|
||||||
.shadow = false, \
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -24,8 +24,6 @@ static void layer_parse_criteria(struct sway_layer_surface *sway_layer) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
sway_layer->deco_data.can_blur_xray = layer != ZWLR_LAYER_SHELL_V1_LAYER_BOTTOM;
|
|
||||||
|
|
||||||
list_t *criterias = layer_criterias_for_sway_layer_surface(sway_layer);
|
list_t *criterias = layer_criterias_for_sway_layer_surface(sway_layer);
|
||||||
for (int i = 0; i < criterias->length; i++) {
|
for (int i = 0; i < criterias->length; i++) {
|
||||||
struct layer_criteria *criteria = criterias->items[i];
|
struct layer_criteria *criteria = criterias->items[i];
|
||||||
|
|
|
@ -443,13 +443,17 @@ static void render_surface_iterator(struct sway_output *output,
|
||||||
|
|
||||||
// render blur (view->surface == surface excludes blurring subsurfaces)
|
// render blur (view->surface == surface excludes blurring subsurfaces)
|
||||||
bool is_subsurface = false;
|
bool is_subsurface = false;
|
||||||
bool should_optimize_blur = deco_data.can_blur_xray && config->blur_xray;
|
bool should_optimize_blur = false;
|
||||||
if (view) {
|
if (view) {
|
||||||
is_subsurface = view->surface != surface;
|
is_subsurface = view->surface != surface;
|
||||||
should_optimize_blur = !container_is_floating(view->container) || config->blur_xray;
|
should_optimize_blur = !container_is_floating(view->container) || config->blur_xray;
|
||||||
}
|
}
|
||||||
if (data->sway_layer) {
|
if (data->sway_layer) {
|
||||||
is_subsurface = data->sway_layer->layer_surface->surface != surface;
|
is_subsurface = data->sway_layer->layer_surface->surface != surface;
|
||||||
|
enum zwlr_layer_shell_v1_layer layer = data->sway_layer->layer;
|
||||||
|
should_optimize_blur = config->blur_xray
|
||||||
|
&& layer != ZWLR_LAYER_SHELL_V1_LAYER_BOTTOM
|
||||||
|
&& layer != ZWLR_LAYER_SHELL_V1_LAYER_BACKGROUND;
|
||||||
}
|
}
|
||||||
if (deco_data.blur && should_parameters_blur() && !is_subsurface) {
|
if (deco_data.blur && should_parameters_blur() && !is_subsurface) {
|
||||||
pixman_region32_t opaque_region;
|
pixman_region32_t opaque_region;
|
||||||
|
@ -1413,7 +1417,6 @@ static void render_containers_linear(struct sway_output *output,
|
||||||
.saturation = child->saturation,
|
.saturation = child->saturation,
|
||||||
.has_titlebar = has_titlebar,
|
.has_titlebar = has_titlebar,
|
||||||
.blur = child->blur_enabled,
|
.blur = child->blur_enabled,
|
||||||
.can_blur_xray = true,
|
|
||||||
.shadow = child->shadow_enabled,
|
.shadow = child->shadow_enabled,
|
||||||
};
|
};
|
||||||
render_view(output, damage, child, colors, deco_data);
|
render_view(output, damage, child, colors, deco_data);
|
||||||
|
@ -1464,7 +1467,6 @@ static void render_containers_tabbed(struct sway_output *output,
|
||||||
.saturation = current->saturation,
|
.saturation = current->saturation,
|
||||||
.has_titlebar = true,
|
.has_titlebar = true,
|
||||||
.blur = current->blur_enabled,
|
.blur = current->blur_enabled,
|
||||||
.can_blur_xray = true,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
// Render tabs
|
// Render tabs
|
||||||
|
@ -1560,7 +1562,6 @@ static void render_containers_stacked(struct sway_output *output,
|
||||||
? 0 : current->corner_radius,
|
? 0 : current->corner_radius,
|
||||||
.has_titlebar = true,
|
.has_titlebar = true,
|
||||||
.blur = current->blur_enabled,
|
.blur = current->blur_enabled,
|
||||||
.can_blur_xray = true,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
// Render titles
|
// Render titles
|
||||||
|
@ -1708,7 +1709,6 @@ static void render_floating_container(struct sway_output *soutput,
|
||||||
.corner_radius = con->corner_radius,
|
.corner_radius = con->corner_radius,
|
||||||
.has_titlebar = has_titlebar,
|
.has_titlebar = has_titlebar,
|
||||||
.blur = con->blur_enabled,
|
.blur = con->blur_enabled,
|
||||||
.can_blur_xray = true,
|
|
||||||
.shadow = con->shadow_enabled,
|
.shadow = con->shadow_enabled,
|
||||||
};
|
};
|
||||||
render_view(soutput, damage, con, colors, deco_data);
|
render_view(soutput, damage, con, colors, deco_data);
|
||||||
|
@ -1936,7 +1936,6 @@ void output_render(struct sway_output *output, struct timespec *when,
|
||||||
.saturation = focus->saturation,
|
.saturation = focus->saturation,
|
||||||
.has_titlebar = false,
|
.has_titlebar = false,
|
||||||
.blur = false,
|
.blur = false,
|
||||||
.can_blur_xray = false,
|
|
||||||
.shadow = false,
|
.shadow = false,
|
||||||
};
|
};
|
||||||
render_view_popups(focus->view, output, damage, deco_data);
|
render_view_popups(focus->view, output, damage, deco_data);
|
||||||
|
|
Loading…
Add table
Reference in a new issue