react-native-audio-browser 0.2.0-next.4 → 0.2.0-next.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/src/main/java/com/audiobrowser/model/PlayerUpdateOptions.kt +11 -11
- package/android/src/main/java/com/audiobrowser/player/CapabilityControls.kt +111 -58
- package/android/src/main/java/com/audiobrowser/player/MediaSessionCallback.kt +9 -5
- package/android/src/main/java/com/audiobrowser/player/MediaSessionCommandManager.kt +218 -252
- package/android/src/main/java/com/audiobrowser/player/Player.kt +19 -8
- package/android/src/test/java/com/audiobrowser/player/CapabilityControlsTest.kt +100 -56
- package/android/src/test/java/com/audiobrowser/player/MediaSessionSlotMappingTest.kt +45 -0
- package/lib/commonjs/features/player/options.js +45 -15
- package/lib/commonjs/features/player/options.js.map +1 -1
- package/lib/commonjs/features/player/setup.js +13 -6
- package/lib/commonjs/features/player/setup.js.map +1 -1
- package/lib/module/features/player/options.js +45 -15
- package/lib/module/features/player/options.js.map +1 -1
- package/lib/module/features/player/setup.js +13 -6
- package/lib/module/features/player/setup.js.map +1 -1
- package/lib/typescript/src/features/player/options.d.ts +86 -36
- package/lib/typescript/src/features/player/options.d.ts.map +1 -1
- package/lib/typescript/src/features/player/setup.d.ts +10 -3
- package/lib/typescript/src/features/player/setup.d.ts.map +1 -1
- package/nitrogen/generated/android/AudioBrowser+autolinking.cmake +1 -1
- package/nitrogen/generated/android/c++/JAndroidOptions.hpp +10 -10
- package/nitrogen/generated/android/c++/JFunc_void_Options.hpp +5 -5
- package/nitrogen/generated/android/c++/JHybridAudioBrowserSpec.cpp +9 -9
- package/nitrogen/generated/android/c++/JNativeSetupPlayerOptions.hpp +5 -5
- package/nitrogen/generated/android/c++/JNativeUpdateOptions.hpp +5 -5
- package/nitrogen/generated/android/c++/JNitroAndroidUpdateOptions.hpp +10 -10
- package/nitrogen/generated/android/c++/JOptions.hpp +5 -5
- package/nitrogen/generated/android/c++/{JNotificationButton.hpp → JRemoteButton.hpp} +19 -19
- package/nitrogen/generated/android/c++/JRemoteButtonLayout.hpp +86 -0
- package/nitrogen/generated/android/c++/JVariant_NullType_RemoteButtonLayout.cpp +26 -0
- package/nitrogen/generated/android/c++/JVariant_NullType_RemoteButtonLayout.hpp +75 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/audiobrowser/AndroidOptions.kt +3 -3
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/audiobrowser/NitroAndroidUpdateOptions.kt +3 -3
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/audiobrowser/{NotificationButton.kt → RemoteButton.kt} +3 -3
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/audiobrowser/RemoteButtonLayout.kt +44 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/audiobrowser/{Variant_NullType_NotificationButtonLayout.kt → Variant_NullType_RemoteButtonLayout.kt} +9 -9
- package/nitrogen/generated/ios/AudioBrowser-Swift-Cxx-Bridge.hpp +36 -51
- package/nitrogen/generated/ios/AudioBrowser-Swift-Cxx-Umbrella.hpp +6 -6
- package/nitrogen/generated/ios/c++/HybridAudioBrowserSpecSwift.hpp +6 -6
- package/nitrogen/generated/ios/swift/AndroidOptions.swift +12 -12
- package/nitrogen/generated/ios/swift/NitroAndroidUpdateOptions.swift +12 -12
- package/nitrogen/generated/ios/swift/{NotificationButton.swift → RemoteButton.swift} +6 -6
- package/nitrogen/generated/ios/swift/RemoteButtonLayout.swift +57 -0
- package/nitrogen/generated/ios/swift/{Variant_NullType_NotificationButtonLayout.swift → Variant_NullType_RemoteButtonLayout.swift} +3 -3
- package/nitrogen/generated/shared/c++/AndroidOptions.hpp +8 -8
- package/nitrogen/generated/shared/c++/NitroAndroidUpdateOptions.hpp +8 -8
- package/nitrogen/generated/shared/c++/{NotificationButton.hpp → RemoteButton.hpp} +19 -19
- package/nitrogen/generated/shared/c++/RemoteButtonLayout.hpp +94 -0
- package/package.json +1 -1
- package/src/features/player/options.ts +97 -37
- package/src/features/player/setup.test.ts +12 -4
- package/src/features/player/setup.ts +14 -7
- package/nitrogen/generated/android/c++/JNotificationButtonLayout.hpp +0 -94
- package/nitrogen/generated/android/c++/JVariant_NullType_NotificationButtonLayout.cpp +0 -26
- package/nitrogen/generated/android/c++/JVariant_NullType_NotificationButtonLayout.hpp +0 -75
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/audiobrowser/NotificationButtonLayout.kt +0 -50
- package/nitrogen/generated/ios/swift/NotificationButtonLayout.swift +0 -92
- package/nitrogen/generated/shared/c++/NotificationButtonLayout.hpp +0 -102
|
@@ -220,7 +220,7 @@ import { validateIOSUpdateOptions } from './options';
|
|
|
220
220
|
|
|
221
221
|
/**
|
|
222
222
|
* Android setup options: the engine-construction fields plus the Android runtime options
|
|
223
|
-
* ({@link AndroidUpdateOptions} — `
|
|
223
|
+
* ({@link AndroidUpdateOptions} — `remoteButtonLayout`, `skipSilence`, …), all expressible at
|
|
224
224
|
* launch. The consumer never has to know which is which; `setupPlayer` routes each field to
|
|
225
225
|
* where it's applied.
|
|
226
226
|
*/
|
|
@@ -287,7 +287,7 @@ function wrapNowPlayingFormatter(formatter) {
|
|
|
287
287
|
|
|
288
288
|
/**
|
|
289
289
|
* The object's entries whose values aren't `undefined`. `null` stays: it's meaningful on some
|
|
290
|
-
* fields (`progressUpdateEventInterval: null` disables progress events, `
|
|
290
|
+
* fields (`progressUpdateEventInterval: null` disables progress events, `remoteButtonLayout:
|
|
291
291
|
* null` empties the layout), so only `undefined` means "not provided".
|
|
292
292
|
*/
|
|
293
293
|
function definedFields(obj) {
|
|
@@ -308,7 +308,7 @@ function nonEmpty(key, value) {
|
|
|
308
308
|
/**
|
|
309
309
|
* Initializes the player with the specified options — the full launch description in one
|
|
310
310
|
* declarative, atomic call. Runtime options (`capabilities`, jump intervals,
|
|
311
|
-
* `
|
|
311
|
+
* `remoteButtonLayout`, …) and the initial `playWhenReady` / `repeatMode` are applied
|
|
312
312
|
* natively as part of setup itself, so there is no setup-then-command ordering for consumers
|
|
313
313
|
* to know about, and no window where the player exists without its options.
|
|
314
314
|
*
|
|
@@ -325,7 +325,14 @@ function nonEmpty(key, value) {
|
|
|
325
325
|
* playWhenReady: true,
|
|
326
326
|
* repeatMode: 'queue',
|
|
327
327
|
* capabilities: { favorite: true },
|
|
328
|
-
* android: {
|
|
328
|
+
* android: {
|
|
329
|
+
* audioContentType: 'music',
|
|
330
|
+
* remoteButtonLayout: {
|
|
331
|
+
* back: 'jump-backward',
|
|
332
|
+
* forward: 'jump-forward',
|
|
333
|
+
* overflow: ['favorite']
|
|
334
|
+
* }
|
|
335
|
+
* },
|
|
329
336
|
* ios: { category: 'playback' }
|
|
330
337
|
* })
|
|
331
338
|
* ```
|
|
@@ -348,7 +355,7 @@ export async function setupPlayer(options = {}) {
|
|
|
348
355
|
const {
|
|
349
356
|
appKilledPlaybackBehavior,
|
|
350
357
|
skipSilence,
|
|
351
|
-
|
|
358
|
+
remoteButtonLayout,
|
|
352
359
|
...androidSetup
|
|
353
360
|
} = android;
|
|
354
361
|
const {
|
|
@@ -371,7 +378,7 @@ export async function setupPlayer(options = {}) {
|
|
|
371
378
|
...nonEmpty('android', definedFields({
|
|
372
379
|
appKilledPlaybackBehavior,
|
|
373
380
|
skipSilence,
|
|
374
|
-
|
|
381
|
+
remoteButtonLayout
|
|
375
382
|
})),
|
|
376
383
|
...nonEmpty('ios', iosUpdate)
|
|
377
384
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["nativeBrowser","validateIOSUpdateOptions","resolveNowPlaying","value","autoUpdateNowPlayingMetadata","nowPlayingMetadataFormatter","wrapNowPlayingFormatter","undefined","formatter","params","definedFields","obj","out","key","nonEmpty","Object","keys","length","setupPlayer","options","nowPlaying","capabilities","forwardJumpInterval","backwardJumpInterval","progressUpdateEventInterval","android","ios","nativeSetup","appKilledPlaybackBehavior","skipSilence","
|
|
1
|
+
{"version":3,"names":["nativeBrowser","validateIOSUpdateOptions","resolveNowPlaying","value","autoUpdateNowPlayingMetadata","nowPlayingMetadataFormatter","wrapNowPlayingFormatter","undefined","formatter","params","definedFields","obj","out","key","nonEmpty","Object","keys","length","setupPlayer","options","nowPlaying","capabilities","forwardJumpInterval","backwardJumpInterval","progressUpdateEventInterval","android","ios","nativeSetup","appKilledPlaybackBehavior","skipSilence","remoteButtonLayout","androidSetup","playbackRates","carPlayUpNextButton","carPlayNowPlayingButtons","iosSetup","iosUpdate","updates"],"sourceRoot":"../../../../src","sources":["features/player/setup.ts"],"mappings":";;AAAA;;AAYA,SAASA,aAAa,QAAQ,cAAc;AAC5C,SAASC,wBAAwB,QAAQ,WAAW;;AAEpD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAsBA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAQA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AASA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAYA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAUA;AACA;AACA;AACA;AACA;AACA;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,CAACyB,QAAQ,CAAC,CAAC;IAC3C,GAAGjC,iBAAiB,CAACkB,UAAU,CAAC;IAChC,GAAGN,QAAQ,CAAC,SAAS,EAAEuB,OAAO;EAChC,CAAC,CAAC;AACJ","ignoreList":[]}
|
|
@@ -65,7 +65,8 @@ export interface PlayerCapabilities {
|
|
|
65
65
|
*
|
|
66
66
|
* Turns on the favorite/like heart across all surfaces:
|
|
67
67
|
* - iOS: Control Center + CarPlay now-playing.
|
|
68
|
-
* - Android:
|
|
68
|
+
* - Android: a place in the {@link RemoteButtonLayout} — the notification,
|
|
69
|
+
* Android Auto and the Android 13+ system media controls — and an
|
|
69
70
|
* (empty or filled) heart on playable browse rows.
|
|
70
71
|
*
|
|
71
72
|
* `match` controls how the ids from `setFavorites` are
|
|
@@ -111,48 +112,77 @@ export interface PlayerCapabilities {
|
|
|
111
112
|
playbackRate?: boolean;
|
|
112
113
|
}
|
|
113
114
|
/**
|
|
114
|
-
* Buttons that can be
|
|
115
|
-
*
|
|
115
|
+
* Buttons that can be placed in the Android button layout — the interactive
|
|
116
|
+
* controls a listener taps in the notification, on the Android Auto Now Playing
|
|
117
|
+
* screen, and in the Android 13+ system media controls.
|
|
116
118
|
*/
|
|
117
|
-
export type
|
|
119
|
+
export type RemoteButton = 'skip-to-previous' | 'skip-to-next' | 'jump-backward' | 'jump-forward' | 'favorite';
|
|
118
120
|
/**
|
|
119
|
-
*
|
|
120
|
-
* Allows explicit control over which buttons appear in which slots.
|
|
121
|
+
* Where each button sits on Android.
|
|
121
122
|
*
|
|
122
|
-
*
|
|
123
|
-
*
|
|
124
|
-
*
|
|
125
|
-
*
|
|
123
|
+
* Android offers exactly three positions, and play/pause always occupies the
|
|
124
|
+
* centre — you cannot move it, and you cannot put two buttons on the same side
|
|
125
|
+
* of it:
|
|
126
|
+
*
|
|
127
|
+
* ```
|
|
128
|
+
* back │ ▶ play/pause │ forward overflow ⋯
|
|
129
|
+
* ```
|
|
130
|
+
*
|
|
131
|
+
* - **`back`** — the single position left of play/pause
|
|
132
|
+
* - **`forward`** — the single position right of play/pause
|
|
133
|
+
* - **`overflow`** — everything else, in priority order
|
|
134
|
+
*
|
|
135
|
+
* **A layout describes the whole arrangement.** All three fields are required —
|
|
136
|
+
* there is no per-field merge with the capability defaults, so what you write is
|
|
137
|
+
* exactly what renders. Use `undefined` for an empty position and `[]` for no
|
|
138
|
+
* overflow. To go back to the derived defaults, omit `remoteButtonLayout`
|
|
139
|
+
* entirely (or set it to `null`); that is the only switch.
|
|
140
|
+
*
|
|
141
|
+
* **Overflow order is priority, not coordinates.** Each surface renders as many
|
|
142
|
+
* buttons as it has room for, taking them from the front — a phone
|
|
143
|
+
* notification, the Android 13+ system media controls, and a car head unit all
|
|
144
|
+
* have different budgets. A head unit with a spare slot may promote the first
|
|
145
|
+
* overflow entry onto the main row, and a long list gets truncated by whichever
|
|
146
|
+
* surface is showing it. Put what matters most first.
|
|
147
|
+
*
|
|
148
|
+
* Placement never changes what a control *can* do: a button left out entirely
|
|
149
|
+
* still responds to a Bluetooth remote or headset, as long as its
|
|
150
|
+
* {@link PlayerCapabilities} entry is enabled.
|
|
126
151
|
*
|
|
127
152
|
* @example
|
|
128
153
|
* ```typescript
|
|
129
|
-
* // Podcast-style: jump
|
|
130
|
-
*
|
|
154
|
+
* // Podcast-style: jump either side of play/pause
|
|
155
|
+
* remoteButtonLayout: {
|
|
131
156
|
* back: 'jump-backward',
|
|
132
157
|
* forward: 'jump-forward',
|
|
133
|
-
* overflow: ['favorite']
|
|
158
|
+
* overflow: ['skip-to-previous', 'skip-to-next', 'favorite']
|
|
134
159
|
* }
|
|
135
160
|
*
|
|
136
|
-
* // Music-style: skip
|
|
137
|
-
*
|
|
161
|
+
* // Music-style: skip either side of play/pause
|
|
162
|
+
* remoteButtonLayout: {
|
|
138
163
|
* back: 'skip-to-previous',
|
|
139
164
|
* forward: 'skip-to-next',
|
|
140
|
-
*
|
|
141
|
-
*
|
|
165
|
+
* overflow: ['favorite']
|
|
166
|
+
* }
|
|
167
|
+
*
|
|
168
|
+
* // Live radio: forward only, nothing to the left
|
|
169
|
+
* remoteButtonLayout: {
|
|
170
|
+
* back: undefined,
|
|
171
|
+
* forward: 'skip-to-next',
|
|
172
|
+
* overflow: []
|
|
142
173
|
* }
|
|
143
174
|
* ```
|
|
144
175
|
*/
|
|
145
|
-
export type
|
|
146
|
-
/**
|
|
147
|
-
back
|
|
148
|
-
/**
|
|
149
|
-
forward
|
|
150
|
-
/**
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
overflow?: NotificationButton[];
|
|
176
|
+
export type RemoteButtonLayout = {
|
|
177
|
+
/** The single position left of play/pause. `undefined` leaves it empty. */
|
|
178
|
+
back: RemoteButton | undefined;
|
|
179
|
+
/** The single position right of play/pause. `undefined` leaves it empty. */
|
|
180
|
+
forward: RemoteButton | undefined;
|
|
181
|
+
/**
|
|
182
|
+
* Everything else, most important first — surfaces promote and truncate from
|
|
183
|
+
* the front. `[]` for none.
|
|
184
|
+
*/
|
|
185
|
+
overflow: RemoteButton[];
|
|
156
186
|
};
|
|
157
187
|
/**
|
|
158
188
|
* AppKilledPlaybackBehavior options:
|
|
@@ -186,11 +216,21 @@ export interface Options {
|
|
|
186
216
|
android?: AndroidOptions;
|
|
187
217
|
/**
|
|
188
218
|
* Jump forward interval in seconds when using jump forward controls.
|
|
219
|
+
*
|
|
220
|
+
* On Android, an interval of exactly 5, 10, 15 or 30 seconds gets an icon
|
|
221
|
+
* showing that number; any other interval gets an icon without one. Other
|
|
222
|
+
* values are perfectly valid — the interval also sets the seek distance.
|
|
223
|
+
*
|
|
189
224
|
* @default 15
|
|
190
225
|
*/
|
|
191
226
|
forwardJumpInterval: number;
|
|
192
227
|
/**
|
|
193
228
|
* Jump backward interval in seconds when using jump backward controls.
|
|
229
|
+
*
|
|
230
|
+
* On Android, an interval of exactly 5, 10, 15 or 30 seconds gets an icon
|
|
231
|
+
* showing that number; any other interval gets an icon without one. Other
|
|
232
|
+
* values are perfectly valid — the interval also sets the seek distance.
|
|
233
|
+
*
|
|
194
234
|
* @default 15
|
|
195
235
|
*/
|
|
196
236
|
backwardJumpInterval: number;
|
|
@@ -245,14 +285,14 @@ export interface AndroidOptions {
|
|
|
245
285
|
*/
|
|
246
286
|
skipSilence: boolean;
|
|
247
287
|
/**
|
|
248
|
-
*
|
|
249
|
-
*
|
|
288
|
+
* Ordered button layout, applied to the notification, Android Auto, and the
|
|
289
|
+
* Android 13+ system media controls. See {@link RemoteButtonLayout}.
|
|
250
290
|
*
|
|
251
|
-
* When not specified,
|
|
291
|
+
* When not specified, the layout is derived from capabilities.
|
|
252
292
|
*
|
|
253
293
|
* @platform android
|
|
254
294
|
*/
|
|
255
|
-
|
|
295
|
+
remoteButtonLayout: RemoteButtonLayout | null;
|
|
256
296
|
}
|
|
257
297
|
export interface AndroidUpdateOptions {
|
|
258
298
|
/**
|
|
@@ -269,14 +309,14 @@ export interface AndroidUpdateOptions {
|
|
|
269
309
|
*/
|
|
270
310
|
skipSilence?: boolean;
|
|
271
311
|
/**
|
|
272
|
-
*
|
|
273
|
-
*
|
|
312
|
+
* Ordered button layout, applied to the notification, Android Auto, and the
|
|
313
|
+
* Android 13+ system media controls. See {@link RemoteButtonLayout}.
|
|
274
314
|
*
|
|
275
|
-
* When not specified,
|
|
315
|
+
* When not specified, the layout is derived from capabilities.
|
|
276
316
|
*
|
|
277
317
|
* @platform android
|
|
278
318
|
*/
|
|
279
|
-
|
|
319
|
+
remoteButtonLayout?: RemoteButtonLayout | null;
|
|
280
320
|
}
|
|
281
321
|
/**
|
|
282
322
|
* iOS-specific player options that can be changed at runtime via {@link updateOptions}.
|
|
@@ -337,11 +377,21 @@ export interface UpdateOptions {
|
|
|
337
377
|
ios?: IOSUpdateOptions;
|
|
338
378
|
/**
|
|
339
379
|
* Jump forward interval in seconds when using jump forward controls.
|
|
380
|
+
*
|
|
381
|
+
* On Android, an interval of exactly 5, 10, 15 or 30 seconds gets an icon
|
|
382
|
+
* showing that number; any other interval gets an icon without one. Other
|
|
383
|
+
* values are perfectly valid — the interval also sets the seek distance.
|
|
384
|
+
*
|
|
340
385
|
* @default 15
|
|
341
386
|
*/
|
|
342
387
|
forwardJumpInterval?: number;
|
|
343
388
|
/**
|
|
344
389
|
* Jump backward interval in seconds when using jump backward controls.
|
|
390
|
+
*
|
|
391
|
+
* On Android, an interval of exactly 5, 10, 15 or 30 seconds gets an icon
|
|
392
|
+
* showing that number; any other interval gets an icon without one. Other
|
|
393
|
+
* values are perfectly valid — the interval also sets the seek distance.
|
|
394
|
+
*
|
|
345
395
|
* @default 15
|
|
346
396
|
*/
|
|
347
397
|
backwardJumpInterval?: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../../../../../src/features/player/options.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAA;AACjD,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAA;AAElE,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAA;AAKnE;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,kBAAkB;IACjC;;;OAGG;IACH,IAAI,CAAC,EAAE,OAAO,CAAA;IACd;;;OAGG;IACH,KAAK,CAAC,EAAE,OAAO,CAAA;IACf;;;OAGG;IACH,IAAI,CAAC,EAAE,OAAO,CAAA;IACd;;;OAGG;IACH,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB;;;OAGG;IACH,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB;;;OAGG;IACH,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB;;;;OAIG;IACH,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB;;;;OAIG;IACH,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB
|
|
1
|
+
{"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../../../../../src/features/player/options.ts"],"names":[],"mapp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,EAAE,OAAO,CAAA;IAE7B;;;;;;;;;OASG;IACH,wBAAwB,CAAC,EAAE,uBAAuB,EAAE,CAAA;CACrD;AAYD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,WAAW,aAAa;IAC5B,6CAA6C;IAC7C,OAAO,CAAC,EAAE,oBAAoB,CAAA;IAE9B,yCAAyC;IACzC,GAAG,CAAC,EAAE,gBAAgB,CAAA;IAEtB;;;;;;;;OAQG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAA;IAE5B;;;;;;;;OAQG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAA;IAE7B;;;;OAIG;IACH,2BAA2B,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAE3C;;;;;;;;;;;;;;OAcG;IACH,YAAY,CAAC,EAAE,kBAAkB,CAAA;CAClC;AAkED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,aAAa,GAAG,IAAI,CAG1D;AAID;;;;;;;;;;;;GAYG;AACH,wBAAgB,UAAU,IAAI,OAAO,CAEpC;AAID;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,6BAE5B,CAAA;AAID;;;GAGG;AACH,wBAAgB,UAAU,IAAI,OAAO,CAEpC"}
|
|
@@ -273,7 +273,7 @@ export type RetryConfig = {
|
|
|
273
273
|
export type AndroidPlayerWakeMode = 'none' | 'local' | 'network';
|
|
274
274
|
/**
|
|
275
275
|
* Android setup options: the engine-construction fields plus the Android runtime options
|
|
276
|
-
* ({@link AndroidUpdateOptions} — `
|
|
276
|
+
* ({@link AndroidUpdateOptions} — `remoteButtonLayout`, `skipSilence`, …), all expressible at
|
|
277
277
|
* launch. The consumer never has to know which is which; `setupPlayer` routes each field to
|
|
278
278
|
* where it's applied.
|
|
279
279
|
*/
|
|
@@ -484,7 +484,7 @@ export type SetupPlayerOptions = Pick<UpdateOptions, 'capabilities' | 'forwardJu
|
|
|
484
484
|
/**
|
|
485
485
|
* Initializes the player with the specified options — the full launch description in one
|
|
486
486
|
* declarative, atomic call. Runtime options (`capabilities`, jump intervals,
|
|
487
|
-
* `
|
|
487
|
+
* `remoteButtonLayout`, …) and the initial `playWhenReady` / `repeatMode` are applied
|
|
488
488
|
* natively as part of setup itself, so there is no setup-then-command ordering for consumers
|
|
489
489
|
* to know about, and no window where the player exists without its options.
|
|
490
490
|
*
|
|
@@ -501,7 +501,14 @@ export type SetupPlayerOptions = Pick<UpdateOptions, 'capabilities' | 'forwardJu
|
|
|
501
501
|
* playWhenReady: true,
|
|
502
502
|
* repeatMode: 'queue',
|
|
503
503
|
* capabilities: { favorite: true },
|
|
504
|
-
* android: {
|
|
504
|
+
* android: {
|
|
505
|
+
* audioContentType: 'music',
|
|
506
|
+
* remoteButtonLayout: {
|
|
507
|
+
* back: 'jump-backward',
|
|
508
|
+
* forward: 'jump-forward',
|
|
509
|
+
* overflow: ['favorite']
|
|
510
|
+
* }
|
|
511
|
+
* },
|
|
505
512
|
* ios: { category: 'playback' }
|
|
506
513
|
* })
|
|
507
514
|
* ```
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setup.d.ts","sourceRoot":"","sources":["../../../../../src/features/player/setup.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,aAAa,CAAA;AACxC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,WAAW,CAAA;AAC9C,OAAO,KAAK,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAClE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAA;AACrD,OAAO,KAAK,EACV,oBAAoB,EACpB,gBAAgB,EAEhB,aAAa,EACd,MAAM,WAAW,CAAA;AAIlB;;;;;;;;GAQG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC,mCAAmC;IACnC,KAAK,EAAE,KAAK,CAAA;IACZ,sFAAsF;IACtF,aAAa,CAAC,EAAE,aAAa,CAAA;IAC7B,kH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C;;;OAGG;IACH,cAAc,CAAC,EAAE,iBAAiB,CAAA;CACnC;AA0DD;;;;;;GAMG;AACH,MAAM,MAAM,kBAAkB,GAAG,IAAI,CACnC,aAAa,EACX,cAAc,GACd,qBAAqB,GACrB,sBAAsB,GACtB,6BAA6B,CAChC,GAAG;IACF;;;;;;;;OAQG;IACH,aAAa,CAAC,EAAE,OAAO,CAAA;IAEvB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,UAAU,CAAA;IAEvB;;;;;;;;;;;;OAYG;IACH,KAAK,CAAC,EAAE,OAAO,GAAG,WAAW,CAAA;IAE7B;;;;;;;;;;OAUG;IACH,uBAAuB,CAAC,EAAE,OAAO,CAAA;IAEjC,yEAAyE;IACzE,OAAO,CAAC,EAAE,mBAAmB,CAAA;IAC7B,+DAA+D;IAC/D,GAAG,CAAC,EAAE,eAAe,CAAA;IACrB;;;;;;;;;;;OAWG;IACH,UAAU,CAAC,EAAE,OAAO,GAAG,wBAAwB,CAAA;CAChD,CAAA;AAiED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAsB,WAAW,CAC/B,OAAO,GAAE,kBAAuB,GAC/B,OAAO,CAAC,IAAI,CAAC,CAyDf"}
|
|
@@ -40,7 +40,7 @@ target_sources(
|
|
|
40
40
|
../nitrogen/generated/android/c++/JVariant_ResolvedTrack_BrowseError_Promise_BrowseResult_.cpp
|
|
41
41
|
../nitrogen/generated/android/c++/JBrowseResult.cpp
|
|
42
42
|
../nitrogen/generated/android/c++/JSleepTimer.cpp
|
|
43
|
-
../nitrogen/generated/android/c++/
|
|
43
|
+
../nitrogen/generated/android/c++/JVariant_NullType_RemoteButtonLayout.cpp
|
|
44
44
|
../nitrogen/generated/android/c++/JVariant_NullType_Double.cpp
|
|
45
45
|
../nitrogen/generated/android/c++/JVariant_Boolean_FavoriteConfig.cpp
|
|
46
46
|
../nitrogen/generated/android/c++/JVariant_Boolean_AndroidAudioOffloadSettings.cpp
|
|
@@ -12,11 +12,11 @@
|
|
|
12
12
|
|
|
13
13
|
#include "AppKilledPlaybackBehavior.hpp"
|
|
14
14
|
#include "JAppKilledPlaybackBehavior.hpp"
|
|
15
|
-
#include "
|
|
16
|
-
#include "
|
|
17
|
-
#include "
|
|
18
|
-
#include "
|
|
19
|
-
#include "
|
|
15
|
+
#include "JRemoteButton.hpp"
|
|
16
|
+
#include "JRemoteButtonLayout.hpp"
|
|
17
|
+
#include "JVariant_NullType_RemoteButtonLayout.hpp"
|
|
18
|
+
#include "RemoteButton.hpp"
|
|
19
|
+
#include "RemoteButtonLayout.hpp"
|
|
20
20
|
#include <NitroModules/JNull.hpp>
|
|
21
21
|
#include <NitroModules/Null.hpp>
|
|
22
22
|
#include <optional>
|
|
@@ -46,12 +46,12 @@ namespace margelo::nitro::audiobrowser {
|
|
|
46
46
|
jni::local_ref<JAppKilledPlaybackBehavior> appKilledPlaybackBehavior = this->getFieldValue(fieldAppKilledPlaybackBehavior);
|
|
47
47
|
static const auto fieldSkipSilence = clazz->getField<jboolean>("skipSilence");
|
|
48
48
|
jboolean skipSilence = this->getFieldValue(fieldSkipSilence);
|
|
49
|
-
static const auto
|
|
50
|
-
jni::local_ref<
|
|
49
|
+
static const auto fieldRemoteButtonLayout = clazz->getField<JVariant_NullType_RemoteButtonLayout>("remoteButtonLayout");
|
|
50
|
+
jni::local_ref<JVariant_NullType_RemoteButtonLayout> remoteButtonLayout = this->getFieldValue(fieldRemoteButtonLayout);
|
|
51
51
|
return AndroidOptions(
|
|
52
52
|
appKilledPlaybackBehavior->toCpp(),
|
|
53
53
|
static_cast<bool>(skipSilence),
|
|
54
|
-
|
|
54
|
+
remoteButtonLayout != nullptr ? std::make_optional(remoteButtonLayout->toCpp()) : std::nullopt
|
|
55
55
|
);
|
|
56
56
|
}
|
|
57
57
|
|
|
@@ -61,14 +61,14 @@ namespace margelo::nitro::audiobrowser {
|
|
|
61
61
|
*/
|
|
62
62
|
[[maybe_unused]]
|
|
63
63
|
static jni::local_ref<JAndroidOptions::javaobject> fromCpp(const AndroidOptions& value) {
|
|
64
|
-
using JSignature = JAndroidOptions(jni::alias_ref<JAppKilledPlaybackBehavior>, jboolean, jni::alias_ref<
|
|
64
|
+
using JSignature = JAndroidOptions(jni::alias_ref<JAppKilledPlaybackBehavior>, jboolean, jni::alias_ref<JVariant_NullType_RemoteButtonLayout>);
|
|
65
65
|
static const auto clazz = javaClassStatic();
|
|
66
66
|
static const auto create = clazz->getStaticMethod<JSignature>("fromCpp");
|
|
67
67
|
return create(
|
|
68
68
|
clazz,
|
|
69
69
|
JAppKilledPlaybackBehavior::fromCpp(value.appKilledPlaybackBehavior),
|
|
70
70
|
value.skipSilence,
|
|
71
|
-
value.
|
|
71
|
+
value.remoteButtonLayout.has_value() ? JVariant_NullType_RemoteButtonLayout::fromCpp(value.remoteButtonLayout.value()) : nullptr
|
|
72
72
|
);
|
|
73
73
|
}
|
|
74
74
|
};
|
|
@@ -20,13 +20,13 @@
|
|
|
20
20
|
#include "AppKilledPlaybackBehavior.hpp"
|
|
21
21
|
#include "JAppKilledPlaybackBehavior.hpp"
|
|
22
22
|
#include <NitroModules/Null.hpp>
|
|
23
|
-
#include "
|
|
23
|
+
#include "RemoteButtonLayout.hpp"
|
|
24
24
|
#include <variant>
|
|
25
|
-
#include "
|
|
25
|
+
#include "JVariant_NullType_RemoteButtonLayout.hpp"
|
|
26
26
|
#include <NitroModules/JNull.hpp>
|
|
27
|
-
#include "
|
|
28
|
-
#include "
|
|
29
|
-
#include "
|
|
27
|
+
#include "JRemoteButtonLayout.hpp"
|
|
28
|
+
#include "RemoteButton.hpp"
|
|
29
|
+
#include "JRemoteButton.hpp"
|
|
30
30
|
#include <vector>
|
|
31
31
|
#include "JVariant_NullType_Double.hpp"
|
|
32
32
|
#include "PlayerCapabilities.hpp"
|
|
@@ -127,10 +127,10 @@ namespace margelo::nitro::audiobrowser { struct Options; }
|
|
|
127
127
|
namespace margelo::nitro::audiobrowser { struct AndroidOptions; }
|
|
128
128
|
// Forward declaration of `AppKilledPlaybackBehavior` to properly resolve imports.
|
|
129
129
|
namespace margelo::nitro::audiobrowser { enum class AppKilledPlaybackBehavior; }
|
|
130
|
-
// Forward declaration of `
|
|
131
|
-
namespace margelo::nitro::audiobrowser { struct
|
|
132
|
-
// Forward declaration of `
|
|
133
|
-
namespace margelo::nitro::audiobrowser { enum class
|
|
130
|
+
// Forward declaration of `RemoteButtonLayout` to properly resolve imports.
|
|
131
|
+
namespace margelo::nitro::audiobrowser { struct RemoteButtonLayout; }
|
|
132
|
+
// Forward declaration of `RemoteButton` to properly resolve imports.
|
|
133
|
+
namespace margelo::nitro::audiobrowser { enum class RemoteButton; }
|
|
134
134
|
// Forward declaration of `PlayerCapabilities` to properly resolve imports.
|
|
135
135
|
namespace margelo::nitro::audiobrowser { struct PlayerCapabilities; }
|
|
136
136
|
// Forward declaration of `FavoriteConfig` to properly resolve imports.
|
|
@@ -370,11 +370,11 @@ namespace margelo::nitro::audiobrowser { struct RetryConfig; }
|
|
|
370
370
|
#include "JAndroidOptions.hpp"
|
|
371
371
|
#include "AppKilledPlaybackBehavior.hpp"
|
|
372
372
|
#include "JAppKilledPlaybackBehavior.hpp"
|
|
373
|
-
#include "
|
|
374
|
-
#include "
|
|
375
|
-
#include "
|
|
376
|
-
#include "
|
|
377
|
-
#include "
|
|
373
|
+
#include "RemoteButtonLayout.hpp"
|
|
374
|
+
#include "JVariant_NullType_RemoteButtonLayout.hpp"
|
|
375
|
+
#include "JRemoteButtonLayout.hpp"
|
|
376
|
+
#include "RemoteButton.hpp"
|
|
377
|
+
#include "JRemoteButton.hpp"
|
|
378
378
|
#include "JVariant_NullType_Double.hpp"
|
|
379
379
|
#include "PlayerCapabilities.hpp"
|
|
380
380
|
#include "JPlayerCapabilities.hpp"
|
|
@@ -48,12 +48,12 @@
|
|
|
48
48
|
#include "JNativeUpdateOptions.hpp"
|
|
49
49
|
#include "JNitroAndroidUpdateOptions.hpp"
|
|
50
50
|
#include "JNitroIOSUpdateOptions.hpp"
|
|
51
|
-
#include "JNotificationButton.hpp"
|
|
52
|
-
#include "JNotificationButtonLayout.hpp"
|
|
53
51
|
#include "JNowPlayingUpdate.hpp"
|
|
54
52
|
#include "JPlaybackError.hpp"
|
|
55
53
|
#include "JPlaybackErrorKind.hpp"
|
|
56
54
|
#include "JPlayerCapabilities.hpp"
|
|
55
|
+
#include "JRemoteButton.hpp"
|
|
56
|
+
#include "JRemoteButtonLayout.hpp"
|
|
57
57
|
#include "JRepeatMode.hpp"
|
|
58
58
|
#include "JRetryConfig.hpp"
|
|
59
59
|
#include "JStallReason.hpp"
|
|
@@ -65,19 +65,19 @@
|
|
|
65
65
|
#include "JVariant_Boolean_FavoriteConfig.hpp"
|
|
66
66
|
#include "JVariant_Boolean_RetryConfig.hpp"
|
|
67
67
|
#include "JVariant_NullType_Double.hpp"
|
|
68
|
-
#include "
|
|
68
|
+
#include "JVariant_NullType_RemoteButtonLayout.hpp"
|
|
69
69
|
#include "JVariant_String_ArtworkVariants.hpp"
|
|
70
70
|
#include "NativeAndroidSetupOptions.hpp"
|
|
71
71
|
#include "NativeIOSSetupOptions.hpp"
|
|
72
72
|
#include "NativeUpdateOptions.hpp"
|
|
73
73
|
#include "NitroAndroidUpdateOptions.hpp"
|
|
74
74
|
#include "NitroIOSUpdateOptions.hpp"
|
|
75
|
-
#include "NotificationButton.hpp"
|
|
76
|
-
#include "NotificationButtonLayout.hpp"
|
|
77
75
|
#include "NowPlayingUpdate.hpp"
|
|
78
76
|
#include "PlaybackError.hpp"
|
|
79
77
|
#include "PlaybackErrorKind.hpp"
|
|
80
78
|
#include "PlayerCapabilities.hpp"
|
|
79
|
+
#include "RemoteButton.hpp"
|
|
80
|
+
#include "RemoteButtonLayout.hpp"
|
|
81
81
|
#include "RepeatMode.hpp"
|
|
82
82
|
#include "RetryConfig.hpp"
|
|
83
83
|
#include "StallReason.hpp"
|
|
@@ -20,17 +20,17 @@
|
|
|
20
20
|
#include "JFavoritesMatchMode.hpp"
|
|
21
21
|
#include "JNitroAndroidUpdateOptions.hpp"
|
|
22
22
|
#include "JNitroIOSUpdateOptions.hpp"
|
|
23
|
-
#include "JNotificationButton.hpp"
|
|
24
|
-
#include "JNotificationButtonLayout.hpp"
|
|
25
23
|
#include "JPlayerCapabilities.hpp"
|
|
24
|
+
#include "JRemoteButton.hpp"
|
|
25
|
+
#include "JRemoteButtonLayout.hpp"
|
|
26
26
|
#include "JVariant_Boolean_FavoriteConfig.hpp"
|
|
27
27
|
#include "JVariant_NullType_Double.hpp"
|
|
28
|
-
#include "
|
|
28
|
+
#include "JVariant_NullType_RemoteButtonLayout.hpp"
|
|
29
29
|
#include "NitroAndroidUpdateOptions.hpp"
|
|
30
30
|
#include "NitroIOSUpdateOptions.hpp"
|
|
31
|
-
#include "NotificationButton.hpp"
|
|
32
|
-
#include "NotificationButtonLayout.hpp"
|
|
33
31
|
#include "PlayerCapabilities.hpp"
|
|
32
|
+
#include "RemoteButton.hpp"
|
|
33
|
+
#include "RemoteButtonLayout.hpp"
|
|
34
34
|
#include <NitroModules/JNull.hpp>
|
|
35
35
|
#include <NitroModules/Null.hpp>
|
|
36
36
|
#include <optional>
|
|
@@ -12,11 +12,11 @@
|
|
|
12
12
|
|
|
13
13
|
#include "AppKilledPlaybackBehavior.hpp"
|
|
14
14
|
#include "JAppKilledPlaybackBehavior.hpp"
|
|
15
|
-
#include "
|
|
16
|
-
#include "
|
|
17
|
-
#include "
|
|
18
|
-
#include "
|
|
19
|
-
#include "
|
|
15
|
+
#include "JRemoteButton.hpp"
|
|
16
|
+
#include "JRemoteButtonLayout.hpp"
|
|
17
|
+
#include "JVariant_NullType_RemoteButtonLayout.hpp"
|
|
18
|
+
#include "RemoteButton.hpp"
|
|
19
|
+
#include "RemoteButtonLayout.hpp"
|
|
20
20
|
#include <NitroModules/JNull.hpp>
|
|
21
21
|
#include <NitroModules/Null.hpp>
|
|
22
22
|
#include <optional>
|
|
@@ -46,12 +46,12 @@ namespace margelo::nitro::audiobrowser {
|
|
|
46
46
|
jni::local_ref<JAppKilledPlaybackBehavior> appKilledPlaybackBehavior = this->getFieldValue(fieldAppKilledPlaybackBehavior);
|
|
47
47
|
static const auto fieldSkipSilence = clazz->getField<jni::JBoolean>("skipSilence");
|
|
48
48
|
jni::local_ref<jni::JBoolean> skipSilence = this->getFieldValue(fieldSkipSilence);
|
|
49
|
-
static const auto
|
|
50
|
-
jni::local_ref<
|
|
49
|
+
static const auto fieldRemoteButtonLayout = clazz->getField<JVariant_NullType_RemoteButtonLayout>("remoteButtonLayout");
|
|
50
|
+
jni::local_ref<JVariant_NullType_RemoteButtonLayout> remoteButtonLayout = this->getFieldValue(fieldRemoteButtonLayout);
|
|
51
51
|
return NitroAndroidUpdateOptions(
|
|
52
52
|
appKilledPlaybackBehavior != nullptr ? std::make_optional(appKilledPlaybackBehavior->toCpp()) : std::nullopt,
|
|
53
53
|
skipSilence != nullptr ? std::make_optional(static_cast<bool>(skipSilence->value())) : std::nullopt,
|
|
54
|
-
|
|
54
|
+
remoteButtonLayout != nullptr ? std::make_optional(remoteButtonLayout->toCpp()) : std::nullopt
|
|
55
55
|
);
|
|
56
56
|
}
|
|
57
57
|
|
|
@@ -61,14 +61,14 @@ namespace margelo::nitro::audiobrowser {
|
|
|
61
61
|
*/
|
|
62
62
|
[[maybe_unused]]
|
|
63
63
|
static jni::local_ref<JNitroAndroidUpdateOptions::javaobject> fromCpp(const NitroAndroidUpdateOptions& value) {
|
|
64
|
-
using JSignature = JNitroAndroidUpdateOptions(jni::alias_ref<JAppKilledPlaybackBehavior>, jni::alias_ref<jni::JBoolean>, jni::alias_ref<
|
|
64
|
+
using JSignature = JNitroAndroidUpdateOptions(jni::alias_ref<JAppKilledPlaybackBehavior>, jni::alias_ref<jni::JBoolean>, jni::alias_ref<JVariant_NullType_RemoteButtonLayout>);
|
|
65
65
|
static const auto clazz = javaClassStatic();
|
|
66
66
|
static const auto create = clazz->getStaticMethod<JSignature>("fromCpp");
|
|
67
67
|
return create(
|
|
68
68
|
clazz,
|
|
69
69
|
value.appKilledPlaybackBehavior.has_value() ? JAppKilledPlaybackBehavior::fromCpp(value.appKilledPlaybackBehavior.value()) : nullptr,
|
|
70
70
|
value.skipSilence.has_value() ? jni::JBoolean::valueOf(value.skipSilence.value()) : nullptr,
|
|
71
|
-
value.
|
|
71
|
+
value.remoteButtonLayout.has_value() ? JVariant_NullType_RemoteButtonLayout::fromCpp(value.remoteButtonLayout.value()) : nullptr
|
|
72
72
|
);
|
|
73
73
|
}
|
|
74
74
|
};
|
|
@@ -22,15 +22,15 @@
|
|
|
22
22
|
#include "JFavoriteConfig.hpp"
|
|
23
23
|
#include "JFavoritesMatchMode.hpp"
|
|
24
24
|
#include "JIOSOptions.hpp"
|
|
25
|
-
#include "JNotificationButton.hpp"
|
|
26
|
-
#include "JNotificationButtonLayout.hpp"
|
|
27
25
|
#include "JPlayerCapabilities.hpp"
|
|
26
|
+
#include "JRemoteButton.hpp"
|
|
27
|
+
#include "JRemoteButtonLayout.hpp"
|
|
28
28
|
#include "JVariant_Boolean_FavoriteConfig.hpp"
|
|
29
29
|
#include "JVariant_NullType_Double.hpp"
|
|
30
|
-
#include "
|
|
31
|
-
#include "NotificationButton.hpp"
|
|
32
|
-
#include "NotificationButtonLayout.hpp"
|
|
30
|
+
#include "JVariant_NullType_RemoteButtonLayout.hpp"
|
|
33
31
|
#include "PlayerCapabilities.hpp"
|
|
32
|
+
#include "RemoteButton.hpp"
|
|
33
|
+
#include "RemoteButtonLayout.hpp"
|
|
34
34
|
#include <NitroModules/JNull.hpp>
|
|
35
35
|
#include <NitroModules/Null.hpp>
|
|
36
36
|
#include <optional>
|