summaryrefslogtreecommitdiff
path: root/cmds/bootanimation/BootAnimationUtil.h
diff options
context:
space:
mode:
authorEd Coyne <edcoyne@google.com>2018-04-10 13:39:09 -0700
committerEd Coyne <edcoyne@google.com>2018-05-31 11:50:47 -0700
commit33f4b7d63b511b145e3ce72580a52f3551358a61 (patch)
tree3231e0a33be92e7758f9e6b11b33172c3e89288e /cmds/bootanimation/BootAnimationUtil.h
parent3bb9562f198bbbdf2bf949203936b092903803f1 (diff)
Refactor audio code out of bootanimation_main.
So it can be shared with the iot/ variant I refactored it into the audioplay.h file. This keeps all of the audio code local, we could hide the functions and only expose the callback but that would make testing harder. Test: Ran a bootanimation.zip with audio.wav on Marlin, works as expected. Bug: 67051984 Change-Id: Ie31dc5f2cfaad5bb23134ef81be712afa6b3cd6f
Diffstat (limited to 'cmds/bootanimation/BootAnimationUtil.h')
-rw-r--r--cmds/bootanimation/BootAnimationUtil.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/cmds/bootanimation/BootAnimationUtil.h b/cmds/bootanimation/BootAnimationUtil.h
index 60987cd1ccd1..1e1140a51763 100644
--- a/cmds/bootanimation/BootAnimationUtil.h
+++ b/cmds/bootanimation/BootAnimationUtil.h
@@ -14,6 +14,9 @@
* limitations under the License.
*/
+#ifndef ANDROID_BOOTANIMATION_UTIL_H
+#define ANDROID_BOOTANIMATION_UTIL_H
+
namespace android {
// Returns true if boot animation is disabled.
@@ -22,4 +25,8 @@ bool bootAnimationDisabled();
// Waits until the surface flinger is up.
void waitForSurfaceFlinger();
+// Returns whether sounds should be played during current boot.
+bool playSoundsAllowed();
} // namespace android
+
+#endif // ANDROID_BOOTANIMATION_UTIL_H