Skip to content

Commit

Permalink
Merge pull request #7 from JioTV-Go/develop
Browse files Browse the repository at this point in the history
Release v1.0 - sync 4
  • Loading branch information
siddharthsky authored Nov 12, 2024
2 parents 0633fed + c02a582 commit 225e9f8
Show file tree
Hide file tree
Showing 5 changed files with 86 additions and 91 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/generate-apk-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: 🚀 Generate and Upload Release APK

env:
main_project_module: app
app_name: JGO-Server
app_name: JTV-GO-Server

on:
push:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@

3. **Using an IPTV Player**:
- To access channels via an IPTV player, add the IPTV playlist URL in your preferred IPTV player app.
- Format of URL for JTV-GO: `[http://<IP>:<port>/playlist.m3u]` (if set up locally).
- Format of URL for JTV-GO: `[http://<IP>:<port>/playlist.m3u]`
- Open the IPTV player and go to the section for adding playlists.
- Input the JTV-GO IPTV playlist URL and save it.
- Select the playlist to browse and play available channels.
Expand Down
37 changes: 20 additions & 17 deletions app/src/main/java/com/skylake/skytv/jgorunner/MainActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.text.font.Font
import androidx.compose.ui.text.font.FontFamily
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import androidx.compose.ui.window.DialogProperties
Expand Down Expand Up @@ -852,7 +853,7 @@ class MainActivity : ComponentActivity() {
isVisible: Boolean,
countdownTime: Int,
onDismiss: () -> Unit,
context: Context // Add context as a parameter to access PackageManager
context: Context
) {
var currentTime by remember { mutableIntStateOf(countdownTime) }
val appIPTV = preferenceManager.getKey("app_name") ?: "IPTV app"
Expand Down Expand Up @@ -886,26 +887,21 @@ class MainActivity : ComponentActivity() {

AlertDialog(
onDismissRequest = { onDismiss() },
// title = {
// Row(verticalAlignment = Alignment.CenterVertically) {
// Icon(
// imageVector = Icons.Filled.Flare,
// contentDescription = "Timer Icon",
// modifier = Modifier.padding(end = 8.dp)
// )
// Text("Redirecting")
// }
// },
text = {
Column(
horizontalAlignment = Alignment.CenterHorizontally,
modifier = Modifier.fillMaxWidth()
verticalArrangement = Arrangement.Center,
modifier = Modifier
.fillMaxWidth()
.padding(vertical = 16.dp)
) {
appIcon?.let {
Image(
bitmap = it.toBitmap().asImageBitmap(),
contentDescription = "App Icon",
modifier = Modifier.size(48.dp).padding(bottom = 8.dp)
modifier = Modifier
.size(48.dp)
.padding(bottom = 8.dp)
)
}

Expand All @@ -916,6 +912,7 @@ class MainActivity : ComponentActivity() {
fontWeight = FontWeight.Bold,
color = MaterialTheme.colorScheme.primary
),
textAlign = TextAlign.Center,
modifier = Modifier.padding(vertical = 8.dp)
)

Expand All @@ -926,14 +923,19 @@ class MainActivity : ComponentActivity() {
fontWeight = FontWeight.Medium,
color = MaterialTheme.colorScheme.secondary
),
modifier = Modifier.alpha(if (currentTime % 2 == 0) 1f else 0.7f) // subtle flicker effect
textAlign = TextAlign.Center,
modifier = Modifier
.alpha(if (currentTime % 2 == 0) 1f else 0.7f)
.padding(top = 8.dp)
)
}
},
confirmButton = {
Button(
onClick = { onDismiss() },
modifier = Modifier.fillMaxWidth().padding(top = 8.dp)
modifier = Modifier
.fillMaxWidth()
.padding(horizontal = 16.dp, vertical = 8.dp)
) {
Text("Dismiss")
}
Expand All @@ -950,10 +952,11 @@ class MainActivity : ComponentActivity() {




@Composable
fun CustPopup(isVisible: Boolean, xtitle: String, xsubtitle: String, xokbtn: String, xendbtn: String, onOk: () -> Unit, onDismiss: () -> Unit) {
if (isVisible) {
Log.d("CustPopup", "Popup is visible.")
Log.d("CustPopup", "CustPopup [$xtitle] is visible.")

AlertDialog(
onDismissRequest = { onDismiss() },
Expand All @@ -972,7 +975,7 @@ class MainActivity : ComponentActivity() {
properties = DialogProperties(dismissOnBackPress = false, dismissOnClickOutside = false)
)
} else {
Log.d("CustPopup", "CustPopup is NOT visible.")
Log.d("CustPopup", "CustPopup [$xtitle] is NOT visible.")
}
}

Expand Down
Loading

0 comments on commit 225e9f8

Please sign in to comment.