WebView Kotlin
WebView Kotlin
მთავარი აქტივობა (Main Activity)
package com.example.livecaller_integration
import android.os.Bundle
import androidx.activity.ComponentActivity
import androidx.activity.compose.setContent
import androidx.activity.enableEdgeToEdge
import androidx.compose.runtime.*
import com.example.livecaller_integration.ui.theme.LiveCallerTheme
class MainActivity : ComponentActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
enableEdgeToEdge()
setContent {
LiveCallerTheme {
AppContent()
}
}
}
}
@Composable
fun AppContent() {
var currentScreen by remember { mutableStateOf("home") }
when (currentScreen) {
"home" -> HomeScreen { currentScreen = "chat" }
"chat" -> ChatScreen { currentScreen = "home" }
}
}
მთავარი ეკრანი (Home Screen)
Chat Screen with WebView
WebView Configuration Extension
ჩათის ვიჯეტის ჩატვირთვა
საჭირო იმპორტები
Last updated