Fixed
Status Update
Comments
lp...@google.com <lp...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
https://android-review.googlesource.com/1123258
https://goto.google.com/android-sha1/b90079595f33f58fece04026a97faa0d243acdb1
Branch: androidx-master-dev
commit b90079595f33f58fece04026a97faa0d243acdb1
Author: Yuichi Araki <yaraki@google.com>
Date: Wed Sep 18 16:55:49 2019
Change the way to detect mismatch between POJO and query
This fixes cursor mismatch warnings with expandProjection.
Bug: 140759491
Test: QueryMethodProcessorTest
Change-Id: I7659002e5e0d1ef60fc1af2a625c0c36da0664d8
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
M room/compiler/src/test/kotlin/androidx/room/processor/QueryMethodProcessorTest.kt
M room/compiler/src/test/kotlin/androidx/room/testing/TestProcessor.kt
le...@google.com <le...@google.com>
le...@google.com <le...@google.com>
ap...@google.com <ap...@google.com> #3
ap...@google.com <ap...@google.com> #4
Project: platform/frameworks/support
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically ( b/140759491 ).
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
https://android-review.googlesource.com/1288456
Branch: androidx-master-dev
commit bdde5a1a970ddc9007b28de4aa29d60ffa588f08
Author: Yigit Boyar <yboyar@google.com>
Date: Thu Apr 16 16:47:05 2020
Re-factor how errors are dismissed when query is re-written
This CL changes how we handle errors/warnings if query is
re-written.
There was a bug in expandProjection where we would report warnings
for things that Room already fixes automatically (
The solution to that problem (I7659002e5e0d1ef60fc1af2a625c0c36da0664d8)
solved it by deferring validating of columns until after re-write
decision is made. Unfortunately, this required changing PojoRowAdapter
to have a dummy mapping until it is validating, make it hard to use
as it does have a non-null mapping which is not useful.
This CL partially reverts that change and instead rely on the log
deferring logic we have in Context. This way, we don't need to break
the stability of PojoRowAdapter while still having the ability to
drop warnings that room fixes. This will also play nicer when we
have different query re-writing options that can use more information
about the query results.
Bug: 153387066
Bug: 140759491
Test: existing tests pass
Change-Id: I2ec967c763d33d7a3ff02c1a13c6953b460d1e5f
M room/compiler/src/main/kotlin/androidx/room/log/RLog.kt
M room/compiler/src/main/kotlin/androidx/room/processor/QueryMethodProcessor.kt
M room/compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
M room/compiler/src/main/kotlin/androidx/room/solver/query/result/PojoRowAdapter.kt
ap...@google.com <ap...@google.com> #5
Project: platform/frameworks/support
Branch: androidx-main
commit 1885e977423a2c5c0ef6c539fc278330443ec2a2
Author: Shahd AbuDaghash <shahddaghash@google.com>
Date: Mon Sep 25 17:53:58 2023
Implementation of AbstractDraggableNode
An abstract class is added to the Draggable modifier that holds the dragging logic. The class will be implemented by both DraggableNode and Draggable2dNode. It will replace the logic in the DraggableNode when the changes are applied to Draggable.
Bug: 214412658
Test: N/A
Change-Id: I287f8323c1cbaff645691707d3b3ef9c8b99b728
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/gestures/Draggable.kt
https://android-review.googlesource.com/2759174
Branch: androidx-main
commit 1885e977423a2c5c0ef6c539fc278330443ec2a2
Author: Shahd AbuDaghash <shahddaghash@google.com>
Date: Mon Sep 25 17:53:58 2023
Implementation of AbstractDraggableNode
An abstract class is added to the Draggable modifier that holds the dragging logic. The class will be implemented by both DraggableNode and Draggable2dNode. It will replace the logic in the DraggableNode when the changes are applied to Draggable.
Bug: 214412658
Test: N/A
Change-Id: I287f8323c1cbaff645691707d3b3ef9c8b99b728
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/gestures/Draggable.kt
sh...@google.com <sh...@google.com>
ap...@google.com <ap...@google.com> #6
Project: platform/frameworks/support
Branch: androidx-main
commit 918e27aebdd1d9e1682846394ede9c4d5de23999
Author: Shahd AbuDaghash <shahddaghash@google.com>
Date: Wed Oct 04 12:10:51 2023
Rename draggable2d to draggable2D
Refactored Draggable2D.kt file and Draggable2DTest.kt to change the name of the API to Draggable2D. This includes renaming all parts associated with the modifier (state, node, etc).
Bug: 214412658
Test: Previous tests should pass
Change-Id: Ie13218b1466e8204b1d2adcbadd3a87f4b8c753e
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/Draggable2DTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/gestures/Draggable2D.kt
https://android-review.googlesource.com/2769523
Branch: androidx-main
commit 918e27aebdd1d9e1682846394ede9c4d5de23999
Author: Shahd AbuDaghash <shahddaghash@google.com>
Date: Wed Oct 04 12:10:51 2023
Rename draggable2d to draggable2D
Refactored Draggable2D.kt file and Draggable2DTest.kt to change the name of the API to Draggable2D. This includes renaming all parts associated with the modifier (state, node, etc).
Bug: 214412658
Test: Previous tests should pass
Change-Id: Ie13218b1466e8204b1d2adcbadd3a87f4b8c753e
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/Draggable2DTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/gestures/Draggable2D.kt
ap...@google.com <ap...@google.com> #7
Project: platform/frameworks/support
Branch: androidx-main
commit 421347e414e7ae8629d91296b47c11e28affb5cc
Author: Shahd AbuDaghash <shahddaghash@google.com>
Date: Wed Oct 04 10:49:18 2023
Draggable2d tests
Added tests for the Draggable2d modifier.
Bug: 214412658
Test: Added test for Draggable2d modifier
Change-Id: Iac49e9fd3d73a09421b1621a0e4ffefad1df903c
A compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/Draggable2DTest.kt
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/DraggableTest.kt
https://android-review.googlesource.com/2770276
Branch: androidx-main
commit 421347e414e7ae8629d91296b47c11e28affb5cc
Author: Shahd AbuDaghash <shahddaghash@google.com>
Date: Wed Oct 04 10:49:18 2023
Draggable2d tests
Added tests for the Draggable2d modifier.
Bug: 214412658
Test: Added test for Draggable2d modifier
Change-Id: Iac49e9fd3d73a09421b1621a0e4ffefad1df903c
A compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/Draggable2DTest.kt
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/DraggableTest.kt
ap...@google.com <ap...@google.com> #8
Project: platform/frameworks/support
Branch: androidx-main
commit 4f044d84db3002e838b4286e56b746695cb9fe4b
Author: Shahd AbuDaghash <shahddaghash@google.com>
Date: Fri Oct 06 12:02:15 2023
Publish Draggable2D in Foundation
Added a sample and a benchmark test for the draggable2D modifier. These are added after making the API public as an Experimental API.
Relnote: Introduced a new `Draggable2D` API in Foundation. It can be used to give the ability for components to be dragged across the screen in 2 dimensions. See [Sample](https://cs.android.com/androidx/platform/frameworks/support/+/androidx-main:compose/foundation/foundation/samples/src/main/java/androidx/compose/foundation/samples/Draggable2DSamples.kt )
Fixes: 214412658
Test: Existing tests should pass
Change-Id: Id95f5706cb31e2c0d4bbd17bb127f527a313df6f
M compose/foundation/foundation/api/current.txt
M compose/foundation/foundation/api/restricted_current.txt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/HighLevelGesturesDemo.kt
A compose/foundation/foundation/samples/src/main/java/androidx/compose/foundation/samples/Draggable2DSamples.kt
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/Draggable2DTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/gestures/Draggable2D.kt
M compose/ui/ui/benchmark/src/androidTest/java/androidx/compose/ui/benchmark/ModifiersBenchmark.kt
https://android-review.googlesource.com/2775138
Branch: androidx-main
commit 4f044d84db3002e838b4286e56b746695cb9fe4b
Author: Shahd AbuDaghash <shahddaghash@google.com>
Date: Fri Oct 06 12:02:15 2023
Publish Draggable2D in Foundation
Added a sample and a benchmark test for the draggable2D modifier. These are added after making the API public as an Experimental API.
Relnote: Introduced a new `Draggable2D` API in Foundation. It can be used to give the ability for components to be dragged across the screen in 2 dimensions. See [Sample](
Fixes: 214412658
Test: Existing tests should pass
Change-Id: Id95f5706cb31e2c0d4bbd17bb127f527a313df6f
M compose/foundation/foundation/api/current.txt
M compose/foundation/foundation/api/restricted_current.txt
M compose/foundation/foundation/integration-tests/foundation-demos/src/main/java/androidx/compose/foundation/demos/HighLevelGesturesDemo.kt
A compose/foundation/foundation/samples/src/main/java/androidx/compose/foundation/samples/Draggable2DSamples.kt
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/Draggable2DTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/gestures/Draggable2D.kt
M compose/ui/ui/benchmark/src/androidTest/java/androidx/compose/ui/benchmark/ModifiersBenchmark.kt
pr...@google.com <pr...@google.com> #9
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.compose.foundation:foundation:1.6.0-alpha08
androidx.compose.foundation:foundation-android:1.6.0-alpha08
androidx.compose.foundation:foundation-desktop:1.6.0-alpha08
androidx.compose.ui:ui:1.6.0-alpha08
androidx.compose.ui:ui-android:1.6.0-alpha08
androidx.compose.ui:ui-desktop:1.6.0-alpha08
Description
There's a long standing feature request of having a 2d drag, similar to the one we have for 1d Modifier.draggable.
Right now people use their own version using lower level building blocks, but a few features will be missing in their code: InteractionSource support or mutex-based priority dragging being a few to mention.
We need to expose the right building blocks for easy wiring or provide a ready to use modifier for such cases. Seems like this issue might be a good foundation for 2d scroll as well ( b/214410040 ).
Over to Levi to start building up his backlog, but feel free to reassign to me or foundation alias if there are any questions or concerns.