cordova-plugin-media3 1.1.20 → 1.1.23
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/package.json +1 -1
- package/plugin.xml +8 -8
- package/src/android/CallbackResponse.java +1 -1
- package/src/android/Configuration.java +1 -1
- package/src/android/LayoutProvider.java +1 -1
- package/src/android/Payload.java +1 -1
- package/src/android/Player.java +8 -8
- package/src/android/Plugin.java +1 -1
package/package.json
CHANGED
package/plugin.xml
CHANGED
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
|
|
36
36
|
<config-file target="res/xml/config.xml" parent="/*">
|
|
37
37
|
<feature name="ExoPlayer">
|
|
38
|
-
<param name="android-package" value="
|
|
38
|
+
<param name="android-package" value="com.naja7host.cordova.plugin.exoplayer.Plugin"/>
|
|
39
39
|
</feature>
|
|
40
40
|
</config-file>
|
|
41
41
|
|
|
@@ -54,12 +54,12 @@
|
|
|
54
54
|
<source-file src="src/res/drawable/previous.png" target-dir="res/drawable/"/>
|
|
55
55
|
<source-file src="src/res/drawable/rewind.png" target-dir="res/drawable/"/> -->
|
|
56
56
|
|
|
57
|
-
<source-file src="src/android/CallbackResponse.java" target-dir="src/
|
|
58
|
-
<source-file src="src/android/Configuration.java" target-dir="src/
|
|
59
|
-
<source-file src="src/android/LayoutProvider.java" target-dir="src/
|
|
60
|
-
<source-file src="src/android/Payload.java" target-dir="src/
|
|
61
|
-
<source-file src="src/android/Player.java" target-dir="src/
|
|
62
|
-
<source-file src="src/android/Plugin.java" target-dir="src/
|
|
63
|
-
<!-- <source-file src="src/android/DeviceDetector.java" target-dir="src/
|
|
57
|
+
<source-file src="src/android/CallbackResponse.java" target-dir="src/com/naja7host/cordova/plugin/exoplayer/"/>
|
|
58
|
+
<source-file src="src/android/Configuration.java" target-dir="src/com/naja7host/cordova/plugin/exoplayer/"/>
|
|
59
|
+
<source-file src="src/android/LayoutProvider.java" target-dir="src/com/naja7host/cordova/plugin/exoplayer/"/>
|
|
60
|
+
<source-file src="src/android/Payload.java" target-dir="src/com/naja7host/cordova/plugin/exoplayer/"/>
|
|
61
|
+
<source-file src="src/android/Player.java" target-dir="src/com/naja7host/cordova/plugin/exoplayer/"/>
|
|
62
|
+
<source-file src="src/android/Plugin.java" target-dir="src/com/naja7host/cordova/plugin/exoplayer/"/>
|
|
63
|
+
<!-- <source-file src="src/android/DeviceDetector.java" target-dir="src/com/naja7host/cordova/plugin/exoplayer/"/> -->
|
|
64
64
|
</platform>
|
|
65
65
|
</plugin>
|
package/src/android/Payload.java
CHANGED
package/src/android/Player.java
CHANGED
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
22
22
|
SOFTWARE.
|
|
23
23
|
*/
|
|
24
|
-
package
|
|
24
|
+
package com.naja7host.cordova.plugin.exoplayer;
|
|
25
25
|
|
|
26
26
|
import android.graphics.Color;
|
|
27
27
|
import android.util.Log;
|
|
@@ -231,8 +231,8 @@ public class Player {
|
|
|
231
231
|
public void createPlayer() {
|
|
232
232
|
Log.i(TAG, "Playing " + config.getUri());
|
|
233
233
|
|
|
234
|
-
String mediaUrl = config.getUri(); // Your method to get the URL
|
|
235
|
-
if (mediaUrl != null && URLUtil.isValidUrl(mediaUrl)) {
|
|
234
|
+
// String mediaUrl = config.getUri().toString(); // Your method to get the URL
|
|
235
|
+
// if (mediaUrl != null && android.webkit.URLUtil.isValidUrl(mediaUrl)) {
|
|
236
236
|
// Proceed with ExoPlayer setup using mediaUrl
|
|
237
237
|
if (config.useInlineView()) {
|
|
238
238
|
// Using a dialog doesn't work for us, as controls are drawn in HTML view (cordova ui)
|
|
@@ -247,11 +247,11 @@ public class Player {
|
|
|
247
247
|
if (config.useInlineView()) {
|
|
248
248
|
setController(config.getController());
|
|
249
249
|
}
|
|
250
|
-
} else {
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
}
|
|
250
|
+
// } else {
|
|
251
|
+
// // Handle invalid or null URL: e.g., show an error message, log the issue, or use a placeholder.
|
|
252
|
+
// Log.e("ExoPlayerDebug", "Invalid media URL: " + mediaUrl);
|
|
253
|
+
// sendError("Invalid media URL: " + mediaUrl);
|
|
254
|
+
// }
|
|
255
255
|
}
|
|
256
256
|
|
|
257
257
|
public void createDialog() {
|
package/src/android/Plugin.java
CHANGED
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
22
22
|
SOFTWARE.
|
|
23
23
|
*/
|
|
24
|
-
package
|
|
24
|
+
package com.naja7host.cordova.plugin.exoplayer;
|
|
25
25
|
|
|
26
26
|
import android.graphics.Color;
|
|
27
27
|
import android.net.*;
|