Skip to content

Commit

Permalink
add console rpc feature module
Browse files Browse the repository at this point in the history
  • Loading branch information
dead8309 committed May 9, 2023
1 parent 36e8f60 commit ad16e45
Show file tree
Hide file tree
Showing 15 changed files with 518 additions and 345 deletions.
1 change: 1 addition & 0 deletions .idea/compiler.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ dependencies {
implementation (projects.featureRpcBase)
implementation (projects.featureAppsRpc)
implementation (projects.featureMediaRpc)
implementation (projects.featureConsoleRpc)

debugImplementation(libs.compose.ui.tooling)
implementation(libs.compose.ui.tooling.preview)
Expand Down
13 changes: 8 additions & 5 deletions app/src/main/java/com/my/kizzy/MainActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ import com.my.kizzy.feature_about.about.About
import com.my.kizzy.feature_about.about.Credits
import com.my.kizzy.feature_about.about.CreditsScreenViewModel
import com.my.kizzy.feature_apps_rpc.AppsRPC
import com.my.kizzy.feature_console_rpc.GamesScreen
import com.my.kizzy.feature_console_rpc.GamesViewModel
import com.my.kizzy.feature_logs.LogScreen
import com.my.kizzy.feature_logs.LogsViewModel
import com.my.kizzy.feature_media_rpc.MediaRPC
Expand All @@ -40,8 +42,6 @@ import com.my.kizzy.preference.getLanguageConfig
import com.my.kizzy.ui.Routes
import com.my.kizzy.ui.animatedComposable
import com.my.kizzy.ui.screen.home.Home
import com.my.kizzy.ui.screen.home.console_games.GamesScreen
import com.my.kizzy.ui.screen.home.console_games.GamesViewModel
import com.my.kizzy.ui.screen.home.custom.CustomRPC
import com.my.kizzy.ui.screen.home.custom.CustomScreenViewModel
import com.my.kizzy.ui.theme.KizzyTheme
Expand Down Expand Up @@ -157,9 +157,12 @@ class MainActivity : AppCompatActivity() {
}
animatedComposable(Routes.CONSOLE_RPC) {
val viewModel: GamesViewModel by viewModels()
GamesScreen(onBackPressed = {
navController.popBackStack()
}, viewModel)
GamesScreen(
onBackPressed = { navController.popBackStack() },
onEvent = { viewModel.onUiEvent(it) },
isSearchBarVisible = viewModel.isSearchBarVisible.value,
state = viewModel.state.value
)
}
animatedComposable(Routes.LANGUAGES) {
Language(
Expand Down

This file was deleted.

1 change: 1 addition & 0 deletions feature_console_rpc/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/build
Loading

0 comments on commit ad16e45

Please sign in to comment.