Changeset 9144 in josm


Ignore:
Timestamp:
2015-12-24T22:59:04+01:00 (9 years ago)
Author:
Don-vip
Message:

see #12229 - add unit tests for audio playback

Location:
trunk
Files:
6 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/AudioPlayer.java

    r9078 r9144  
    120120     * start at the beginning of the stream
    121121     * @param url The resource to play, which must be a WAV file or stream
    122      * @throws Exception audio fault exception, e.g. can't open stream,  unhandleable audio format
     122     * @throws Exception audio fault exception, e.g. can't open stream, unhandleable audio format
    123123     */
    124124    public static void play(URL url) throws Exception {
     
    130130     * @param url The resource to play, which must be a WAV file or stream
    131131     * @param seconds The number of seconds into the audio to start playing
    132      * @throws Exception audio fault exception, e.g. can't open stream,  unhandleable audio format
     132     * @throws Exception audio fault exception, e.g. can't open stream, unhandleable audio format
    133133     */
    134134    public static void play(URL url, double seconds) throws Exception {
  • trunk/src/org/openstreetmap/josm/tools/AudioUtil.java

    r7037 r9144  
    4141            return naturalLength / calibration;
    4242        } catch (UnsupportedAudioFileException | IOException e) {
     43            if (Main.isDebugEnabled()) {
     44                Main.debug(e.getMessage());
     45            }
    4346            return 0.0;
    4447        }
Note: See TracChangeset for help on using the changeset viewer.