Skip to content

Commit

Permalink
Revert "fix build bug and fix bug" (#308)
Browse files Browse the repository at this point in the history
  • Loading branch information
AkaneTan authored Oct 25, 2024
1 parent d84bcf4 commit ed3183a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,6 @@ import org.akanework.gramophone.logic.utils.LrcUtils.loadAndParseLyricsFile
import org.akanework.gramophone.logic.utils.LrcUtils.loadAndParseLyricsFileLegacy
import org.akanework.gramophone.logic.utils.MediaStoreUtils
import org.akanework.gramophone.logic.utils.SemanticLyrics
import org.akanework.gramophone.logic.utils.convertForLegacy
import org.akanework.gramophone.logic.utils.exoplayer.EndedWorkaroundPlayer
import org.akanework.gramophone.logic.utils.exoplayer.GramophoneMediaSourceFactory
import org.akanework.gramophone.logic.utils.exoplayer.GramophoneRenderFactory
Expand Down Expand Up @@ -796,8 +795,8 @@ class GramophonePlaybackService : MediaLibraryService(), MediaSessionService.Lis

fun updateLyrics(parsedLyrics: MutableList<MediaStoreUtils.Lyric>?, parsedLyricsa: SemanticLyrics?) {
if ( parsedLyrics.toString() == "null" ){
lyrics = parsedLyricsa
adapter?.updateLyrics(lyrics.convertForLegacy())
lyricsLegacy = SemanticLyrics.convertForLegacy(parsedLyricsa)
adapter?.updateLyrics(lyricsLegacy)
newView?.updateLyrics(null)
} else {
lyricsLegacy = parsedLyrics
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,6 @@ class ExperimentalSettingsTopFragment : BasePreferenceFragment() {

private fun checkAndRequestNotificationPermission() {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
if (!isAdded) {
// Fragment 未附着,推迟操作或记录日志
Log.e("Fragment", "Fragment not attached to context yet")
return
}
when {
ActivityCompat.checkSelfPermission(
requireContext(),
Expand Down

0 comments on commit ed3183a

Please sign in to comment.