hide overlays after clicking on them

This commit is contained in:
Wayne Chen 2018-10-04 14:24:43 -07:00
parent c785efec84
commit 2e3566bc73

View file

@ -196,8 +196,22 @@
return;
}
if (tryAgainImageHover === overlayID) {
// hide try again overlays.
var properties = {
visible: false
};
Overlays.editOverlay(tryAgainImageNeutral, properties);
Overlays.editOverlay(tryAgainImageHover, properties);
Overlays.editOverlay(tryAgainText, properties);
location.goToLastAddress();
} else if (backImageHover === overlayID && location.canGoBack()) {
// hide back overlays.
var properties = {
visible: false
};
Overlays.editOverlay(backImageNeutral, properties);
Overlays.editOverlay(backImageHover, properties);
Overlays.editOverlay(backText, properties);
location.goBack();
}
}