15d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// Copyright 2014 The Chromium Authors. All rights reserved.
25d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// Use of this source code is governed by a BSD-style license that can be
35d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// found in the LICENSE file.
45d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)
55d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)#ifndef ASH_AUDIO_SOUNDS_H_
65d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)#define ASH_AUDIO_SOUNDS_H_
75d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)
85d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)#include "ash/ash_export.h"
95d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)#include "media/audio/sounds/sounds_manager.h"
105d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)
115d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)namespace ash {
125d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)
13a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// A wrapper around media::SoundsManager::Play() method, which plays sound
14a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// identified by |key|. Returns true when sound is successfully played.
15a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)ASH_EXPORT bool PlaySystemSoundAlways(media::SoundsManager::SoundKey key);
16a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)
175d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// A wrapper around media::SoundsManager::Play() method, which plays
185d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// sound identified by |key| iff at least one of the following
195d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// conditions is true:
205d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)// * ash::switches::kAshEnableSystemSounds flag is set
21a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// * spoken feedback is enabled
22a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)// Returns true when sound is succesfully played.
23a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)ASH_EXPORT bool PlaySystemSoundIfSpokenFeedback(
24a1401311d1ab56c4ed0a474bd38c108f75cb0cd9Torne (Richard Coles)    media::SoundsManager::SoundKey key);
255d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)
265d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)}  // namespace ash
275d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)
285d1f7b1de12d16ceb2c938c56701a3e8bfa558f7Torne (Richard Coles)#endif  // ASH_AUDIO_SOUNDS_H_
29