diff --git a/androidApp/src/main/res/xml-v31/widget_info.xml b/androidApp/src/main/res/xml-v31/widget_info.xml new file mode 100644 index 00000000..96ef429a --- /dev/null +++ b/androidApp/src/main/res/xml-v31/widget_info.xml @@ -0,0 +1,9 @@ + \ No newline at end of file diff --git a/androidApp/src/main/res/xml/widget_info.xml b/androidApp/src/main/res/xml/widget_info.xml index 55edf5c7..a060eb29 100644 --- a/androidApp/src/main/res/xml/widget_info.xml +++ b/androidApp/src/main/res/xml/widget_info.xml @@ -1,8 +1,6 @@ - \ No newline at end of file + android:minWidth="240dp" + android:previewImage="@drawable/baseline_history_toggle_off_24" + android:resizeMode="vertical" + android:widgetCategory="home_screen" /> \ No newline at end of file diff --git a/data/src/main/java/com/m3u/data/service/internal/PlayerManagerImpl.kt b/data/src/main/java/com/m3u/data/service/internal/PlayerManagerImpl.kt index 0572d024..7be9d46e 100644 --- a/data/src/main/java/com/m3u/data/service/internal/PlayerManagerImpl.kt +++ b/data/src/main/java/com/m3u/data/service/internal/PlayerManagerImpl.kt @@ -37,7 +37,6 @@ import androidx.media3.exoplayer.trackselection.TrackSelector import androidx.media3.extractor.DefaultExtractorsFactory import androidx.media3.extractor.ts.DefaultTsPayloadReaderFactory.FLAG_ALLOW_NON_IDR_KEYFRAMES import androidx.media3.extractor.ts.DefaultTsPayloadReaderFactory.FLAG_DETECT_ACCESS_UNITS -import androidx.media3.extractor.ts.DefaultTsPayloadReaderFactory.FLAG_ENABLE_HDMV_DTS_AUDIO_STREAMS import androidx.media3.session.MediaSession import com.m3u.codec.Codecs import com.m3u.core.architecture.dispatcher.Dispatcher @@ -513,14 +512,14 @@ class PlayerManagerImpl @Inject constructor( * * https://kodi.wiki/view/HTTP */ - private fun String.readKodiUrlOptions(): Map { + private fun String.readKodiUrlOptions(): Map { val options = this.drop(this.indexOf("|") + 1).split("&") return options .filter { it.isNotBlank() } .associate { val pair = it.split("=") val key = pair.getOrNull(0).orEmpty() - val value = pair.getOrNull(1).orEmpty() + val value = pair.getOrNull(1) key to value } }