TCMP: notification controls may not work after TC kill

Support for Android version of Total Commander

Moderators: sheep, Hacker, Stefan2, white

Post Reply
User avatar
Power Member
Power Member
Posts: 1580
Joined: 2006-11-03, 22:26 UTC
Location: Kyiv, 68/262

TCMP: notification controls may not work after TC kill

Post by *DrShark »

Christian couldn't reproduce it on own devices, so I'll describe the issue here.

On my Android device which has not that much of RAM, sometimes when TC player plays song in background, and I am using an app which uses a lot of RAM, Android may stop playback and kill player's notification. Then player's notofication may appear again, but controls won't work. It seems that it's possible to get same or similar behavior using new TC's killprocess Exit internal command (155).

To reproduce:
1. Start TC.
2. Start Mediaplayer using 137 internal command (it may be required to have 2 or more tracks in queue playlist to reproduce this, although I'm not sure about it.)
3. Start playback of some random track in a player.
4. Return to TC using Android Back button.
5. Exit from TC using killprocess Exit button (internal command 155).
TC and player will be closed, player's notification disappears from notification area and bar.
6. Start TC again.
6.1 Wrong behavior 1: player's notification will auto-appear in a notification area on top of a screen,
with a title of the track we played in step 3 (altough player won't play anything).
7. Swith to a notification bar using a down swipe from top of a screen.
In TC Player's notificaton you will see the track we played in step 3 too.
8. Wrong behavior 2: Try pause/next/prev buttons in player's notification: they won't work.
9. Tap in the middle of player's notification. Player will be opened.
9.1 Wrong behavior 3: in the player, none of tracks will be selected,
even though the notification in steps 6.1 and 7 mentioned the track we played in step 3,
so it should be currently playing track.
Of course, in such situation a tap on "Play" button in a player will start a playback of playlist track #1.

Sometimes Android itself may unload the player in similar way, and when then player's notification re-appears again, it may look like a situation described above starting from step 6.1.

For user it looks like player played the song, Android unloaded a player, then when some memory if free Android returns the player to a notification, and user expects that player will continue a playback because in the notification the name of a track is the same as when player was unloaded for Android. Instead, player just re-appears in a notification playing nothing, player's controls in the notification don't work, and after a manual switch to a player no track is selected, so user will have to manually scroll down to the playlist to play a track which is mentioned in a notification but didn't get a selection after user returned to a player.
Android 4.3.1 no root, kernel 08.09.2016; Win7 Home Premium SP1 rus 32 bit
TC #149847 Personal licence

Cuz we're all in this together, We're here to make it right

Post Reply