summaryrefslogtreecommitdiff
path: root/src/koopatlas
diff options
context:
space:
mode:
authorTreeki <treeki@gmail.com>2013-05-06 05:41:04 +0200
committerTreeki <treeki@gmail.com>2013-05-06 05:41:04 +0200
commitd49bbad1a8fe6f57e0a4ae706e7788d5b0d643e2 (patch)
treebbe4808c6939033cc6ff7fa1e4a837fffb440078 /src/koopatlas
parenteb2790d40381a2348a53f4341ec4d879eea2d872 (diff)
downloadkamek-d49bbad1a8fe6f57e0a4ae706e7788d5b0d643e2.tar.gz
kamek-d49bbad1a8fe6f57e0a4ae706e7788d5b0d643e2.zip
hide/show the HUD smoothly when in a menu
Diffstat (limited to '')
-rw-r--r--src/koopatlas/hud.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/koopatlas/hud.cpp b/src/koopatlas/hud.cpp
index 592d3b2..ff9a0e2 100644
--- a/src/koopatlas/hud.cpp
+++ b/src/koopatlas/hud.cpp
@@ -183,10 +183,14 @@ int dWMHud_c::onDraw() {
void dWMHud_c::hideAll() {
- layout.enableNonLoopAnim(HIDE_ALL);
+ if (!layout.isAnimOn(HIDE_ALL))
+ layout.enableNonLoopAnim(HIDE_ALL);
+ layout.grpHandlers[HIDE_ALL].frameCtrl.flags = 1; // NO_LOOP
}
void dWMHud_c::unhideAll() {
- layout.enableNonLoopAnim(UNHIDE_ALL);
+ if (!layout.isAnimOn(HIDE_ALL))
+ layout.enableNonLoopAnim(HIDE_ALL, true);
+ layout.grpHandlers[HIDE_ALL].frameCtrl.flags = 3; // NO_LOOP | REVERSE
}