Collapse conditional and please clippy
This commit is contained in:
parent
2097a56b58
commit
17a4d817c4
2 changed files with 6 additions and 5 deletions
|
|
@ -137,17 +137,17 @@ impl Backend {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if !layer.text.is_empty() {
|
if !layer.text.is_empty()
|
||||||
if !self.text_pipeline.prepare(
|
&& !self.text_pipeline.prepare(
|
||||||
device,
|
device,
|
||||||
queue,
|
queue,
|
||||||
&layer.text,
|
&layer.text,
|
||||||
layer.bounds,
|
layer.bounds,
|
||||||
scale_factor,
|
scale_factor,
|
||||||
target_size,
|
target_size,
|
||||||
) {
|
)
|
||||||
return false;
|
{
|
||||||
}
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -187,6 +187,7 @@ impl Pipeline {
|
||||||
Err(glyphon::PrepareError::AtlasFull(content_type)) => {
|
Err(glyphon::PrepareError::AtlasFull(content_type)) => {
|
||||||
self.prepare_layer = 0;
|
self.prepare_layer = 0;
|
||||||
|
|
||||||
|
#[allow(clippy::needless_bool)]
|
||||||
if self.atlas.grow(device, content_type) {
|
if self.atlas.grow(device, content_type) {
|
||||||
false
|
false
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue