Status Update
Comments
ch...@google.com <ch...@google.com>
ch...@google.com <ch...@google.com> #2
It would also be nice to be able to set different maxLines
for the large and small titles. For example, setting maxLines = 2
for the large title and maxLines = 1
for the small title.
This functionality is something that would also be possible with TwoRowsTopAppBar
being publicly exposed.
ap...@google.com <ap...@google.com> #3
@Nick - Having the app bar adjust to its content height is quite tricky here, mainly when there are other constraints that involve the scroll behavior.
What we did at maxLines
will still be applied to the Text
, however, the height set up is going to be done programmatically on the top app bar you chose.
ap...@google.com <ap...@google.com> #4
@sgibly We don't really need the app bar to adjust to its content height. What we are asking for is a way to configure the title based on expanded/collapsed state. TwoRowsTopAppBar
provides a way to handle this, but is a private composable.
Our goal:
- use a slightly larger font size than the current default when in the expanded state
- allow the title to wrap 2 lines when in the expanded state
- confine the tile to a single line when in the collapsed state
As a workaround we have forked ExtraLargeTopAppBar
composable that we use throughout our application:
ap...@google.com <ap...@google.com> #5
Similar to this request, I would like to request just that the smallTitle
field of TwoRowsTopAppBar
is exposed in LargeTopAppBar
, defaulting to the title
composable. We currently are awkwardly manually handling the transition of large to small and back based on the collapsed fraction of the scroll state, but it seems like the title
/smalltitle
solution is already there and probably superior.
The problem that comes up with both rows of the TwoRowsTopAppBar
being set to a large title
is that on large font sizes/display sizes there is far too much white space for the invisible first app bar.
ap...@google.com <ap...@google.com> #6
ap...@google.com <ap...@google.com> #7
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.compose.material3:material3:1.4.0-alpha07
androidx.compose.material3:material3-android:1.4.0-alpha07
androidx.compose.material3:material3-jvmstubs:1.4.0-alpha07
androidx.compose.material3:material3-linuxx64stubs:1.4.0-alpha07
ap...@google.com <ap...@google.com> #8
Project: platform/frameworks/support
Branch: androidx-main
Author: Shalom Gibly <
Link:
Update the TwoRowsTopAppBar API
Expand for full commit details
Update the TwoRowsTopAppBar API
- Update the API to the feedback from the API council.
- Remove the `expanded` lambda parameter and have a separate params for
the expanded and collapsed heights.
Test: Updated
Bug: 306697446
Bug: 229134133
Bug: 268068946
Fixes: 394144086
Relnote: "Updates to the TowRowsTopAppBar API. We removed the `expanded`
lambda parameters and added separate parameters for the expanded and
collapsed heights."
Change-Id: Idd6777bc381871b9e77c040762c6bca7355cda8a
Files:
- M
compose/material3/material3/api/current.txt
- M
compose/material3/material3/api/restricted_current.txt
- M
compose/material3/material3/samples/src/main/java/androidx/compose/material3/samples/AppBarSamples.kt
- M
compose/material3/material3/src/androidInstrumentedTest/kotlin/androidx/compose/material3/AppBarTest.kt
- M
compose/material3/material3/src/commonMain/kotlin/androidx/compose/material3/AppBar.kt
Hash: e414ed68307128f55615f1e482bee2212677098c
Date: Thu Feb 06 13:54:36 2025
ap...@google.com <ap...@google.com> #9
Branch: 3.1
commit d283b6d419a2a7b5bc4d42648b9d86862df032bb
Author: Christoffer Quist Adamsen <christofferqa@google.com>
Date: Fri Jun 24 13:54:02 2022
Fix invalid switch generation in switch optimizer
Bug:
Change-Id: I06dc2405a9fefb1f7669fcdd65c4715cd4429036
M src/main/java/com/android/tools/r8/ir/optimize/CodeRewriter.java
ap...@google.com <ap...@google.com> #10
Branch: 3.3
commit 8c70ca559f60bb4144b21797a3ce2d47e7fc9502
Author: Christoffer Quist Adamsen <christofferqa@google.com>
Date: Fri Jun 24 13:49:57 2022
Fix invalid switch generation in switch optimizer
Bug:
Change-Id: I06dc2405a9fefb1f7669fcdd65c4715cd4429036
M src/main/java/com/android/tools/r8/ir/optimize/CodeRewriter.java
ap...@google.com <ap...@google.com> #11
Branch: 3.2
commit 8af601daca38f4d23cd3f50f90edcefe3fe4c363
Author: Christoffer Quist Adamsen <christofferqa@google.com>
Date: Fri Jun 24 13:52:58 2022
Fix invalid switch generation in switch optimizer
Bug:
Change-Id: I06dc2405a9fefb1f7669fcdd65c4715cd4429036
M src/main/java/com/android/tools/r8/ir/optimize/CodeRewriter.java
ap...@google.com <ap...@google.com> #12
Branch: 3.3
commit 8c70ca559f60bb4144b21797a3ce2d47e7fc9502
Author: Christoffer Quist Adamsen <christofferqa@google.com>
Date: Fri Jun 24 13:49:57 2022
Fix invalid switch generation in switch optimizer
Bug:
Change-Id: I06dc2405a9fefb1f7669fcdd65c4715cd4429036
M src/main/java/com/android/tools/r8/ir/optimize/CodeRewriter.java
ch...@google.com <ch...@google.com> #13
This should be fixed in R8 versions 3.1.81, 3.2.72, and 3.3.66.
da...@spotify.com <da...@spotify.com> #14
I can confirm the fix works in 3.2.72. I haven't tested the other branches, but I have no reason to think they work differently. Thank you!
ch...@google.com <ch...@google.com> #15
Thanks for the confirmation, let us know if you run into any other issues!
ap...@google.com <ap...@google.com> #16
Branch: main
commit edeccdd850f166818249f2958075049d4f323003
Author: Christoffer Quist Adamsen <christofferqa@google.com>
Date: Mon Jun 27 13:09:43 2022
Reproduce assertion failure from unresolvable method reference
Bug:
Change-Id: I04c5c84ebb448e4862570999a44d72e6241c70c6
A src/test/java/com/android/tools/r8/classmerging/horizontal/UnresolvableMethodWithClassMergingTest.java
ap...@google.com <ap...@google.com> #17
Branch: main
commit 48f4f5304b3e3e600f23d2b6f7ce82e28a5219e4
Author: Christoffer Quist Adamsen <christofferqa@google.com>
Date: Mon Jun 27 13:11:37 2022
Soft-pin types referenced from unresolvable methods
Bug:
Change-Id: I1d862f719172b1be6070308d101b7dca955a34ce
M src/main/java/com/android/tools/r8/shaking/Enqueuer.java
M src/test/java/com/android/tools/r8/classmerging/horizontal/UnresolvableMethodWithClassMergingTest.java
Description
Got this failure on R8 versions 3.1.80 (and 3.2.71). The same input works for R8 version 3.0.78.
I'm sharing a dump zip privately.