Skip to content

Commit

Permalink
Improve save data when on stop
Browse files Browse the repository at this point in the history
  • Loading branch information
fgl27 committed Oct 28, 2024
1 parent 79d62ae commit 603e7b7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
6 changes: 3 additions & 3 deletions app/specific/OSInterface.js
Original file line number Diff line number Diff line change
Expand Up @@ -1144,6 +1144,6 @@ function OSInterface_SetLanguage(lang) {
//public boolean getPlaybackState()
//Android specific: true
//return the playback state
// function OSInterface_getPlaybackState() {//Not be used
// return Android.getPlaybackState();
// }
function OSInterface_getPlaybackState() {
return Main_IsOn_OSInterface ? Android.getPlaybackState() : true;
}
5 changes: 4 additions & 1 deletion app/specific/PlayEtc.js
Original file line number Diff line number Diff line change
Expand Up @@ -1446,7 +1446,10 @@ function Play_KeyReturnSetExit() {

function Play_CheckPreview() {
if (Play_isOn && Play_data.data.length > 0 && !Play_isEndDialogVisible() && !Play_StayDialogVisible()) {
if (!Play_StayDialogVisible()) Main_Set_history('live', Play_data.data);
if (!Play_StayDialogVisible()) {
//skip update the date if not playing, this can an scenario the live has ended during Java onStop
Main_Set_history('live', Play_data.data, !OSInterface_getPlaybackState());
}

if (Main_IsOn_OSInterface && Play_CheckPreviewLive()) {
Play_PreviewURL = Play_data.AutoUrl;
Expand Down

0 comments on commit 603e7b7

Please sign in to comment.