mirror of
https://github.com/bevyengine/bevy
synced 2024-11-10 15:14:50 +00:00
correctly set up background color in mobile example (#12384)
# Objective - Since #11165, the button in the mobile example doesn't visually react to touches ## Solution - Correctly set up the background color
This commit is contained in:
parent
879b170f28
commit
40732148da
1 changed files with 14 additions and 10 deletions
|
@ -104,7 +104,8 @@ fn setup_scene(
|
||||||
|
|
||||||
// Test ui
|
// Test ui
|
||||||
commands
|
commands
|
||||||
.spawn(ButtonBundle {
|
.spawn((
|
||||||
|
ButtonBundle {
|
||||||
style: Style {
|
style: Style {
|
||||||
justify_content: JustifyContent::Center,
|
justify_content: JustifyContent::Center,
|
||||||
align_items: AlignItems::Center,
|
align_items: AlignItems::Center,
|
||||||
|
@ -114,8 +115,11 @@ fn setup_scene(
|
||||||
bottom: Val::Px(50.0),
|
bottom: Val::Px(50.0),
|
||||||
..default()
|
..default()
|
||||||
},
|
},
|
||||||
|
image: UiImage::default().with_color(Color::NONE),
|
||||||
..default()
|
..default()
|
||||||
})
|
},
|
||||||
|
BackgroundColor(Color::WHITE),
|
||||||
|
))
|
||||||
.with_children(|b| {
|
.with_children(|b| {
|
||||||
b.spawn(
|
b.spawn(
|
||||||
TextBundle::from_section(
|
TextBundle::from_section(
|
||||||
|
|
Loading…
Reference in a new issue