fix setting of build cache extent when not init

This commit is contained in:
2025-08-24 14:31:50 +00:00
parent 1028468c3f
commit 244433c9be
+3 -1
View File
@@ -115,7 +115,9 @@ class LazyCanvasController with ChangeNotifier {
/// Applied on the next build /// Applied on the next build
void setBuildCacheExtent(Offset extent) { void setBuildCacheExtent(Offset extent) {
_buildCacheExtent = extent + _kBuildCacheBuffer; _buildCacheExtent = extent + _kBuildCacheBuffer;
_buildExtent = Offset(_canvasSize.width, _canvasSize.height) + _buildCacheExtent!; if (_init) {
_buildExtent = Offset(_canvasSize.width, _canvasSize.height) + _buildCacheExtent!;
}
} }
// ==================== Utils ==================== // ==================== Utils ====================