File tree Expand file tree Collapse file tree 2 files changed +8
-3
lines changed
java/dev/arkbuilders/sample Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -86,14 +86,20 @@ class ScoreActivity : AppCompatActivity() {
8686 )
8787 scoreWidgetController.init (scoreStorage)
8888
89- findViewById<ComposeView >(R .id.score_widget_horizontal).setContent {
89+ val horizontal = findViewById<ComposeView >(R .id.score_widget_horizontal)
90+ val vertical = findViewById<ComposeView >(R .id.score_widget_vertical)
91+
92+ horizontal.disposeComposition()
93+ horizontal.setContent {
9094 HorizontalScoreWidgetComposable (
95+ modifier = Modifier .padding(60 .dp),
9196 size = DpSize (200 .dp, 80 .dp),
9297 controller = scoreWidgetController
9398 )
9499 }
95100
96- findViewById<ComposeView >(R .id.score_widget_vertical).setContent {
101+ vertical.disposeComposition()
102+ vertical.setContent {
97103 VerticalScoreWidgetComposable (
98104 modifier = Modifier .padding(40 .dp),
99105 size = DpSize (50 .dp, 120 .dp),
Original file line number Diff line number Diff line change 2929 android : layout_width =" wrap_content"
3030 android : layout_height =" wrap_content"
3131 android : layout_marginTop =" 50dp"
32- android : padding =" 50dp"
3332 app : layout_constraintEnd_toEndOf =" parent"
3433 app : layout_constraintStart_toStartOf =" parent"
3534 app : layout_constraintTop_toBottomOf =" @id/btn_pick_resource" />
You can’t perform that action at this time.
0 commit comments