mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-12-23 06:51:49 +01:00
Decode notification logo in background thread. Set max bitmap size to 2048
This commit is contained in:
parent
69baaac27e
commit
a31c6ff875
@ -165,16 +165,16 @@ class LibraryUpdateService : Service() {
|
|||||||
override fun onStartCommand(intent: Intent?, flags: Int, startId: Int): Int {
|
override fun onStartCommand(intent: Intent?, flags: Int, startId: Int): Int {
|
||||||
if (intent == null) return Service.START_NOT_STICKY
|
if (intent == null) return Service.START_NOT_STICKY
|
||||||
|
|
||||||
if (notificationBitmap == null) {
|
|
||||||
notificationBitmap = BitmapFactory.decodeResource(resources, R.mipmap.ic_launcher)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Unsubscribe from any previous subscription if needed.
|
// Unsubscribe from any previous subscription if needed.
|
||||||
subscription?.unsubscribe()
|
subscription?.unsubscribe()
|
||||||
|
|
||||||
// Update favorite manga. Destroy service when completed or in case of an error.
|
// Update favorite manga. Destroy service when completed or in case of an error.
|
||||||
subscription = Observable
|
subscription = Observable
|
||||||
.defer {
|
.defer {
|
||||||
|
if (notificationBitmap == null) {
|
||||||
|
notificationBitmap = BitmapFactory.decodeResource(resources, R.mipmap.ic_launcher)
|
||||||
|
}
|
||||||
|
|
||||||
val mangaList = getMangaToUpdate(intent)
|
val mangaList = getMangaToUpdate(intent)
|
||||||
|
|
||||||
// Update either chapter list or manga details.
|
// Update either chapter list or manga details.
|
||||||
|
@ -110,7 +110,7 @@ class ReaderActivity : BaseRxActivity<ReaderPresenter>() {
|
|||||||
|
|
||||||
setMenuVisibility(menuVisible)
|
setMenuVisibility(menuVisible)
|
||||||
|
|
||||||
maxBitmapSize = GLUtil.getMaxTextureSize()
|
maxBitmapSize = Math.min(2048, GLUtil.getMaxTextureSize())
|
||||||
|
|
||||||
left_chapter.setOnClickListener {
|
left_chapter.setOnClickListener {
|
||||||
if (viewer != null) {
|
if (viewer != null) {
|
||||||
|
Loading…
Reference in New Issue
Block a user