@24i/smartapps-bigscreen-rnv-build-engine 0.17.27-alpha.2792 → 0.17.27-alpha.2796
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/dist/templates/platforms/androidtv/project/app/build.gradle +1 -1
- package/dist/templates/platforms/androidtv/project/app/src/main/java/com/twentyfouri/tvbridge/global/di/ApplicationModule.kt +1 -1
- package/dist/templates/platforms/androidtv/project/app/src/main/java/com/twentyfouri/tvbridge/global/utils/PlayerFactoryBitmovinCustomized.kt +12 -2
- package/dist/templates/platforms/androidtv/project/app/src/main/java/com/twentyfouri/tvbridge/global/utils/PlayerFactoryConfigured.kt +5 -4
- package/dist/templates/platforms/androidtv/project/app/src/main/java/com/twentyfouri/tvbridge/webview/viewmodel/WebViewModel.kt +4 -3
- package/package.json +1 -1
|
@@ -10,7 +10,7 @@ def npawAccountCode = '{{NPAW_ACCOUNT_CODE}}'
|
|
|
10
10
|
def useNpawPlugin = npawAccountCode != ''
|
|
11
11
|
def useImaSdk = {{ENABLE_IMA_SDK}}
|
|
12
12
|
|
|
13
|
-
def player_version = '0.8.0-alpha.
|
|
13
|
+
def player_version = '0.8.0-alpha.21'
|
|
14
14
|
|
|
15
15
|
android {
|
|
16
16
|
namespace = 'com.twentyfouri.tvbridge'
|
|
@@ -1,7 +1,17 @@
|
|
|
1
1
|
package com.twentyfouri.tvbridge.global.utils
|
|
2
2
|
|
|
3
|
+
import android.app.Application
|
|
4
|
+
import com.twentyfouri.player.bitmovin.NpawConfig
|
|
3
5
|
import com.twentyfouri.player.bitmovin.PlayerFactoryBitmovin
|
|
4
6
|
import com.twentyfouri.tvbridge.configuration.BridgeConfig
|
|
5
7
|
|
|
6
|
-
class PlayerFactoryBitmovinCustomized(config: BridgeConfig) :
|
|
7
|
-
PlayerFactoryBitmovin(
|
|
8
|
+
class PlayerFactoryBitmovinCustomized(config: BridgeConfig, application: Application) :
|
|
9
|
+
PlayerFactoryBitmovin(
|
|
10
|
+
config.bitmovinLicense,
|
|
11
|
+
if (config.npawAccount.isNotEmpty()) {
|
|
12
|
+
NpawConfig(config.npawAccount, application)
|
|
13
|
+
} else {
|
|
14
|
+
null
|
|
15
|
+
}
|
|
16
|
+
),
|
|
17
|
+
PlayerFactoryVersion
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
package com.twentyfouri.tvbridge.global.utils
|
|
2
2
|
|
|
3
|
+
import android.app.Application
|
|
3
4
|
import com.twentyfouri.player.base.PlayerFactoryBase
|
|
4
5
|
import com.twentyfouri.tvbridge.configuration.BridgeConfig
|
|
5
6
|
|
|
6
7
|
object PlayerFactoryConfigured {
|
|
7
|
-
fun buildFactory(bridgeConfig: BridgeConfig): PlayerFactoryBase {
|
|
8
|
+
fun buildFactory(bridgeConfig: BridgeConfig, application: Application): PlayerFactoryBase {
|
|
8
9
|
var factory: PlayerFactoryBase? = null
|
|
9
10
|
if (bridgeConfig.bitmovinLicense.isNotEmpty()) {
|
|
10
|
-
factory = factory ?: buildBitmovinFactory(bridgeConfig)
|
|
11
|
+
factory = factory ?: buildBitmovinFactory(bridgeConfig, application)
|
|
11
12
|
}
|
|
12
13
|
if (bridgeConfig.npawAccount.isNotEmpty()) {
|
|
13
14
|
factory = factory ?: buildNpawFactory(bridgeConfig)
|
|
@@ -28,8 +29,8 @@ object PlayerFactoryConfigured {
|
|
|
28
29
|
null
|
|
29
30
|
}
|
|
30
31
|
|
|
31
|
-
private fun buildBitmovinFactory(bridgeConfig: BridgeConfig) = try {
|
|
32
|
-
PlayerFactoryBitmovinCustomized(bridgeConfig)
|
|
32
|
+
private fun buildBitmovinFactory(bridgeConfig: BridgeConfig, application: Application) = try {
|
|
33
|
+
PlayerFactoryBitmovinCustomized(bridgeConfig, application)
|
|
33
34
|
} catch (e: NoClassDefFoundError) {
|
|
34
35
|
null
|
|
35
36
|
}
|
|
@@ -37,6 +37,7 @@ import com.twentyfouri.tvbridge.webview.view.PlayerCache
|
|
|
37
37
|
import org.json.JSONArray
|
|
38
38
|
import org.json.JSONException
|
|
39
39
|
import org.json.JSONObject
|
|
40
|
+
import java.io.IOException
|
|
40
41
|
import java.net.NetworkInterface
|
|
41
42
|
import java.util.Locale
|
|
42
43
|
import javax.inject.Inject
|
|
@@ -607,7 +608,7 @@ class WebViewModel @Inject constructor(
|
|
|
607
608
|
val adId get() = try {
|
|
608
609
|
// Let's try Google first
|
|
609
610
|
AdvertisingIdClient.getAdvertisingIdInfo(context).id
|
|
610
|
-
} catch (e:
|
|
611
|
+
} catch (e: IOException) {
|
|
611
612
|
// Probably Amazon
|
|
612
613
|
try {
|
|
613
614
|
Settings.Secure.getString(context.contentResolver, "advertising_id")
|
|
@@ -619,12 +620,12 @@ class WebViewModel @Inject constructor(
|
|
|
619
620
|
val limitAdTracking get() = try {
|
|
620
621
|
// Let's try Google first
|
|
621
622
|
AdvertisingIdClient.getAdvertisingIdInfo(context).isLimitAdTrackingEnabled
|
|
622
|
-
} catch (e:
|
|
623
|
+
} catch (e: IOException) {
|
|
623
624
|
// Probably Amazon
|
|
624
625
|
try {
|
|
625
626
|
Settings.Secure.getInt(context.contentResolver, "limit_ad_tracking") != 0
|
|
626
627
|
} catch (snfe: Settings.SettingNotFoundException) {
|
|
627
|
-
|
|
628
|
+
true
|
|
628
629
|
}
|
|
629
630
|
}
|
|
630
631
|
|
package/package.json
CHANGED