Skip to content

Commit

Permalink
feat(mobile-app): Updated main activity
Browse files Browse the repository at this point in the history
  • Loading branch information
marlonlom committed Mar 6, 2024
1 parent 5959a37 commit 8372ead
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

package dev.marlonlom.apps.cappajv.ui.main

import android.content.res.Configuration
import android.os.Bundle
import androidx.activity.ComponentActivity
import androidx.activity.compose.setContent
Expand All @@ -26,6 +27,7 @@ import androidx.lifecycle.lifecycleScope
import androidx.lifecycle.repeatOnLifecycle
import androidx.window.layout.FoldingFeature
import androidx.window.layout.WindowInfoTracker
import com.google.accompanist.pager.ExperimentalPagerApi
import dev.marlonlom.apps.cappajv.ui.layout.DevicePosture
import dev.marlonlom.apps.cappajv.ui.layout.DevicePostureDetector
import kotlinx.coroutines.ExperimentalCoroutinesApi
Expand All @@ -43,6 +45,7 @@ import kotlin.contracts.ExperimentalContracts
*
* @author marlonlom
*/
@ExperimentalPagerApi
@ExperimentalContracts
@ExperimentalFoundationApi
@ExperimentalLayoutApi
Expand Down Expand Up @@ -95,7 +98,8 @@ class MainActivity : ComponentActivity() {
val appState = rememberCappajvAppState(
windowSizeClass = calculateWindowSizeClass(this),
devicePosture = devicePosture,
screenWidthDp = LocalConfiguration.current.smallestScreenWidthDp
screenWidthDp = LocalConfiguration.current.smallestScreenWidthDp,
isLandscape = LocalConfiguration.current.orientation == Configuration.ORIENTATION_LANDSCAPE
)

AppContent(
Expand Down

0 comments on commit 8372ead

Please sign in to comment.