Flame chart - jumpTo called before scroll position offsets have new size
- Ngôn ngữ chính
- Dart
- Star
- 1.7k
- Fork
- 404
- Merge trung bình
- 6 ngày 17 giờ
- Pull request đã merge (30 ngày)
- 18
Mô tả
In flame_chart.dart, we call
```
linkedHorizontalScrollControllerGroup.jumpTo(newScrollOffset);
```
to update the scroll offset as we zoom. We call this inside of an animation controller listener `zoomController.addListener(() { ... })`. At times when we call this, `scrollController.position.maxScrollOffset` is not updated for the new zoom level and layout size, causing `jumpTo` to fire BallisticScrollActivities to bounce the scroll offset back to what it thinks is the `maxScrollOffset`.
We need to have a way to call `jumpTo` when we can guarantee that the min / max scroll offsets are updated for the new zoom value.
I attempted to set these offsets manually using `scrollController.position.applyContentDimensions(minScrollOffset, maxScrollOffset)` but this results in an error regarding gesture detectors: `The replaceGestureRecognizers() method can only be called during the layout phase.`
Hướng dẫn đóng góp
Hướng nghiên cứu
Bắt đầu trong flame_chart.dart, tại listener của zoomController và lệnh gọi linkedHorizontalScrollControllerGroup.jumpTo(newScrollOffset). Tái hiện việc thu phóng gần một ranh giới cuộn, sau đó xác minh rằng jumpTo chỉ chạy sau khi các offset cuộn tối thiểu/tối đa mới khả dụng, mà không kích hoạt hiện tượng nảy đạn đạo hoặc lỗi layout của bộ phát hiện cử chỉ.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- dart, flutter
- Lĩnh vực
- data-visualization, frontend
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100