Skip to content

Commit 8087ad2

Browse files
authored
Merge pull request #308 from Automattic/fix/discover-artwork-scaling
Hotfix for Chromecast and discover image scaling
2 parents 5583fa7 + 0a758aa commit 8087ad2

File tree

3 files changed

+16
-4
lines changed

3 files changed

+16
-4
lines changed

CHANGELOG.md

+8
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# Release notes
22

3+
### 7.21.1
4+
5+
* Bug Fixes:
6+
* Fix Chromecast not taking over playback after connection.
7+
([#308](https://github.com/Automattic/pocket-casts-android/pull/308)).
8+
* Fix the discover artwork scaling issue.
9+
([#308](https://github.com/Automattic/pocket-casts-android/pull/308)).
10+
311
### 7.21.0
412

513
* Bug Fixes:

dependencies.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ project.ext {
2626
applicationId = 'au.com.shiftyjelly.pocketcasts'
2727

2828
versionCode = getVersionCode()
29-
versionName = '7.21.0' + getVersionNameSuffix()
29+
versionName = '7.21.1' + getVersionNameSuffix()
3030

3131
// Android
3232
minSdkVersion = 23
@@ -153,8 +153,8 @@ project.ext {
153153
glide: "com.github.bumptech.glide:glide:$versionGlide",
154154
glideOkHttp: "com.github.bumptech.glide:okhttp3-integration:$versionGlide",
155155
glideCompile: "com.github.bumptech.glide:compiler:$versionGlide",
156-
coil: "io.coil-kt:coil:2.2.0",
157-
coilCompose: "io.coil-kt:coil-compose:2.2.0",
156+
coil: "io.coil-kt:coil:2.2.1",
157+
coilCompose: "io.coil-kt:coil-compose:2.2.1",
158158
// OkHttp (http client) - https://github.com/square/okhttp
159159
okHttp: "com.squareup.okhttp3:okhttp:4.9.3",
160160
okHttpLogging: "com.squareup.okhttp3:logging-interceptor:4.9.3",

modules/services/repositories/src/main/java/au/com/shiftyjelly/pocketcasts/repositories/chromecast/CastManagerImpl.kt

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package au.com.shiftyjelly.pocketcasts.repositories.chromecast
22

33
import android.content.Context
4+
import androidx.core.content.ContextCompat
45
import au.com.shiftyjelly.pocketcasts.utils.log.LogBuffer
56
import com.google.android.gms.cast.framework.CastContext
67
import com.google.android.gms.cast.framework.Session
@@ -23,7 +24,10 @@ class CastManagerImpl @Inject constructor(@ApplicationContext private val contex
2324
override val isConnectedObservable = BehaviorRelay.create<Boolean>().apply { accept(false) }
2425

2526
init {
26-
getSessionManager()?.addSessionManagerListener(sessionManagerListener)
27+
val executor = ContextCompat.getMainExecutor(context)
28+
CastContext.getSharedInstance(context, executor)
29+
.addOnFailureListener { e -> LogBuffer.e(LogBuffer.TAG_PLAYBACK, "Failed to init CastContext shared instance ${e.message}") }
30+
.addOnSuccessListener { castContext -> castContext.sessionManager.addSessionManagerListener(sessionManagerListener) }
2731
}
2832

2933
override suspend fun isAvailable(): Boolean {

0 commit comments

Comments
 (0)