mirror of
https://github.com/overte-org/overte.git
synced 2025-04-09 07:12:45 +02:00
No magic numbers!
This commit is contained in:
parent
653dda7000
commit
ff3a76f716
1 changed files with 5 additions and 3 deletions
|
@ -217,6 +217,8 @@ function showConfirmationMessage(selectedID, destination) {
|
|||
}
|
||||
|
||||
var opacity = 2.0,
|
||||
fadeRate = 0.05,
|
||||
timeBetweenFadesMS = 50,
|
||||
confirmationMessageContainer = document.createElement("div"),
|
||||
confirmationMessage = document.createElement("div");
|
||||
confirmationMessageContainer.className = "confirmationMessageContainer";
|
||||
|
@ -243,12 +245,12 @@ function showConfirmationMessage(selectedID, destination) {
|
|||
document.getElementById(selectedID).appendChild(confirmationMessageContainer);
|
||||
|
||||
setInterval(function () {
|
||||
if (opacity <= 0.05) {
|
||||
if (opacity <= fadeRate) {
|
||||
confirmationMessageContainer.remove();
|
||||
}
|
||||
opacity -= 0.05;
|
||||
opacity -= fadeRate;
|
||||
confirmationMessageContainer.style.opacity = opacity;
|
||||
}, 50);
|
||||
}, timeBetweenFadesMS);
|
||||
}
|
||||
function showUploadingMessage(selectedID, destination) {
|
||||
if (selectedID.id) {
|
||||
|
|
Loading…
Reference in a new issue