overlays: fix trophy notification pop-up locations

This commit is contained in:
Megamouse 2021-10-29 20:15:25 +02:00
parent e9fe90244f
commit 244aa6879a

View File

@ -40,7 +40,6 @@ namespace rsx
frame.back_color.g = 0.250980f;
frame.back_color.b = 0.247059f;
frame.back_color.a = 0.88f;
image.set_pos(78, 64);
image.set_size(53, 53);
@ -54,9 +53,6 @@ namespace rsx
sliding_animation.duration = 1.5f;
sliding_animation.type = animation_type::ease_in_out_cubic;
sliding_animation.current = { -f32(frame.w), 0, 0 };
sliding_animation.end = { 0, 0, 0};
sliding_animation.active = true;
}
void trophy_notification::update()
@ -79,7 +75,7 @@ namespace rsx
{
if (!sliding_animation.active)
{
sliding_animation.end = { -f32(frame.w), 0, 0 };
sliding_animation.end = { -f32(frame.x + frame.w), 0, 0 };
sliding_animation.on_finish = [this]
{
s_trophy_semaphore.release();
@ -140,6 +136,10 @@ namespace rsx
u16 margin_sz = 9;
frame.w = margin_sz * 3 + image.w + text_view.w;
sliding_animation.current = { -f32(frame.x + frame.w), 0, 0 };
sliding_animation.end = { 0, 0, 0 };
sliding_animation.active = true;
visible = true;
return CELL_OK;
}