| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 // | 46 // |
| 47 // The state can only transition to the next state, except for the FINISHED_
STATE which can | 47 // The state can only transition to the next state, except for the FINISHED_
STATE which can |
| 48 // never be changed. | 48 // never be changed. |
| 49 enum PlaybackState { | 49 enum PlaybackState { |
| 50 // These must be defined with the same names and values as in the .idl f
ile. | 50 // These must be defined with the same names and values as in the .idl f
ile. |
| 51 UNSCHEDULED_STATE = 0, | 51 UNSCHEDULED_STATE = 0, |
| 52 SCHEDULED_STATE = 1, | 52 SCHEDULED_STATE = 1, |
| 53 PLAYING_STATE = 2, | 53 PLAYING_STATE = 2, |
| 54 FINISHED_STATE = 3 | 54 FINISHED_STATE = 3 |
| 55 }; | 55 }; |
| 56 | 56 |
| 57 AudioScheduledSourceNode(AudioContext*, float sampleRate); | 57 AudioScheduledSourceNode(AudioContext*, float sampleRate); |
| 58 | 58 |
| 59 // Scheduling. | 59 // Scheduling. |
| 60 void start(double when); | 60 void start(double when); |
| 61 void stop(double when); | 61 void stop(double when); |
| 62 | 62 |
| 63 void noteOn(double when); | 63 void noteOn(double when); |
| 64 void noteOff(double when); | 64 void noteOff(double when); |
| 65 | 65 |
| 66 unsigned short playbackState() const { return static_cast<unsigned short>(m_
playbackState); } | 66 unsigned short playbackState() const { return static_cast<unsigned short>(m_
playbackState); } |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 double m_endTime; // in seconds | 100 double m_endTime; // in seconds |
| 101 | 101 |
| 102 bool m_hasEndedListener; | 102 bool m_hasEndedListener; |
| 103 | 103 |
| 104 static const double UnknownTime; | 104 static const double UnknownTime; |
| 105 }; | 105 }; |
| 106 | 106 |
| 107 } // namespace WebCore | 107 } // namespace WebCore |
| 108 | 108 |
| 109 #endif // AudioScheduledSourceNode_h | 109 #endif // AudioScheduledSourceNode_h |
| OLD | NEW |