Formatting fixes
This commit is contained in:
parent
ce496284bc
commit
5253ac9826
@ -885,28 +885,28 @@ void Steam_Overlay::set_next_notification_pos(float width, float height, float e
|
|||||||
float animate_size = 0.f;
|
float animate_size = 0.f;
|
||||||
|
|
||||||
switch (pos) {
|
switch (pos) {
|
||||||
// top
|
// top
|
||||||
case Overlay_Appearance::NotificationPosition::top_left:
|
case Overlay_Appearance::NotificationPosition::top_left:
|
||||||
animate_size = animate_factor(elapsed) * noti_width;
|
animate_size = animate_factor(elapsed) * noti_width;
|
||||||
margin_y = anchor_margin * (idx.top_left + 1);
|
margin_y = anchor_margin * (idx.top_left + 1);
|
||||||
x = anchor_margin - animate_size;
|
x = anchor_margin - animate_size;
|
||||||
y = margin_y + noti_height * idx.top_left;
|
y = margin_y + noti_height * idx.top_left;
|
||||||
++idx.top_left;
|
++idx.top_left;
|
||||||
break;
|
break;
|
||||||
case Overlay_Appearance::NotificationPosition::top_center:
|
case Overlay_Appearance::NotificationPosition::top_center:
|
||||||
animate_size = animate_factor(elapsed) * noti_height;
|
animate_size = animate_factor(elapsed) * noti_height;
|
||||||
margin_y = anchor_margin * (idx.top_center + 1);
|
margin_y = anchor_margin * (idx.top_center + 1);
|
||||||
x = (width / 2) - (noti_width / 2);
|
x = (width / 2) - (noti_width / 2);
|
||||||
y = (margin_y + noti_height * idx.top_center) - animate_size;
|
y = (margin_y + noti_height * idx.top_center) - animate_size;
|
||||||
++idx.top_center;
|
++idx.top_center;
|
||||||
break;
|
break;
|
||||||
case Overlay_Appearance::NotificationPosition::top_right:
|
case Overlay_Appearance::NotificationPosition::top_right:
|
||||||
animate_size = animate_factor(elapsed) * noti_width;
|
animate_size = animate_factor(elapsed) * noti_width;
|
||||||
margin_y = anchor_margin * (idx.top_right + 1);
|
margin_y = anchor_margin * (idx.top_right + 1);
|
||||||
x = (width - noti_width - anchor_margin) + animate_size;
|
x = (width - noti_width - anchor_margin) + animate_size;
|
||||||
y = margin_y * (idx.top_center + 1) + noti_height * idx.top_right;
|
y = margin_y * (idx.top_center + 1) + noti_height * idx.top_right;
|
||||||
++idx.top_right;
|
++idx.top_right;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
// bot
|
// bot
|
||||||
case Overlay_Appearance::NotificationPosition::bot_left:
|
case Overlay_Appearance::NotificationPosition::bot_left:
|
||||||
@ -915,21 +915,21 @@ void Steam_Overlay::set_next_notification_pos(float width, float height, float e
|
|||||||
x = anchor_margin - animate_size;
|
x = anchor_margin - animate_size;
|
||||||
y = height - noti_height * (idx.bot_left + 1) - margin_y;
|
y = height - noti_height * (idx.bot_left + 1) - margin_y;
|
||||||
++idx.bot_left;
|
++idx.bot_left;
|
||||||
break;
|
break;
|
||||||
case Overlay_Appearance::NotificationPosition::bot_center:
|
case Overlay_Appearance::NotificationPosition::bot_center:
|
||||||
animate_size = animate_factor(elapsed) * noti_height;
|
animate_size = animate_factor(elapsed) * noti_height;
|
||||||
margin_y = anchor_margin * (idx.bot_center + 1);
|
margin_y = anchor_margin * (idx.bot_center + 1);
|
||||||
x = (width / 2) - (noti_width / 2);
|
x = (width / 2) - (noti_width / 2);
|
||||||
y = height - noti_height * (idx.bot_center + 1) - margin_y + animate_size;
|
y = height - noti_height * (idx.bot_center + 1) - margin_y + animate_size;
|
||||||
++idx.bot_center;
|
++idx.bot_center;
|
||||||
break;
|
break;
|
||||||
case Overlay_Appearance::NotificationPosition::bot_right:
|
case Overlay_Appearance::NotificationPosition::bot_right:
|
||||||
animate_size = animate_factor(elapsed) * noti_width;
|
animate_size = animate_factor(elapsed) * noti_width;
|
||||||
margin_y = anchor_margin * (idx.bot_right + 1);
|
margin_y = anchor_margin * (idx.bot_right + 1);
|
||||||
x = width - noti_width - anchor_margin + animate_size;
|
x = width - noti_width - anchor_margin + animate_size;
|
||||||
y = height - noti_height * (idx.bot_right + 1) - margin_y;
|
y = height - noti_height * (idx.bot_right + 1) - margin_y;
|
||||||
++idx.bot_right;
|
++idx.bot_right;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default: /* satisfy compiler warning */ break;
|
default: /* satisfy compiler warning */ break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user