Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(640)

Side by Side Diff: third_party/WebKit/Source/modules/webaudio/OfflineAudioContext.h

Issue 2345693002: Move close() from BaseAudioContext to AudioContext (Closed)
Patch Set: Update expected results Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 29 matching lines...) Expand all
40 static OfflineAudioContext* create(ExecutionContext*, unsigned numberOfChann els, unsigned numberOfFrames, float sampleRate, ExceptionState&); 40 static OfflineAudioContext* create(ExecutionContext*, unsigned numberOfChann els, unsigned numberOfFrames, float sampleRate, ExceptionState&);
41 41
42 ~OfflineAudioContext() override; 42 ~OfflineAudioContext() override;
43 43
44 DECLARE_VIRTUAL_TRACE(); 44 DECLARE_VIRTUAL_TRACE();
45 45
46 unsigned length() const { return m_totalRenderFrames; } 46 unsigned length() const { return m_totalRenderFrames; }
47 47
48 ScriptPromise startOfflineRendering(ScriptState*); 48 ScriptPromise startOfflineRendering(ScriptState*);
49 49
50 ScriptPromise closeContext(ScriptState*) final;
51 ScriptPromise suspendContext(ScriptState*, double); 50 ScriptPromise suspendContext(ScriptState*, double);
52 ScriptPromise resumeContext(ScriptState*) final; 51 ScriptPromise resumeContext(ScriptState*) final;
53 52
54 // This is to implement the pure virtual method from BaseAudioContext. 53 // This is to implement the pure virtual method from BaseAudioContext.
55 // CANNOT be called from an OfflineAudioContext. 54 // CANNOT be called from an OfflineAudioContext.
56 ScriptPromise suspendContext(ScriptState*) final; 55 ScriptPromise suspendContext(ScriptState*) final;
57 56
58 void rejectPendingResolvers() override; 57 void rejectPendingResolvers() override;
59 58
60 bool hasRealtimeConstraint() final { return false; } 59 bool hasRealtimeConstraint() final { return false; }
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 // state when the context is suspended. 112 // state when the context is suspended.
114 bool m_isRenderingStarted; 113 bool m_isRenderingStarted;
115 114
116 // Total render sample length. 115 // Total render sample length.
117 size_t m_totalRenderFrames; 116 size_t m_totalRenderFrames;
118 }; 117 };
119 118
120 } // namespace blink 119 } // namespace blink
121 120
122 #endif // OfflineAudioContext_h 121 #endif // OfflineAudioContext_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698