cacheExtentStyle property

  1. @Deprecated('Use scrollCacheExtent instead. ' 'This feature was deprecated after v3.41.0-0.0.pre.')
CacheExtentStyle get cacheExtentStyle

Deprecated. Use scrollCacheExtent instead.

Implementation

@Deprecated(
  'Use scrollCacheExtent instead. '
  'This feature was deprecated after v3.41.0-0.0.pre.',
)
CacheExtentStyle get cacheExtentStyle => _scrollCacheExtent.style;
  1. @Deprecated('Use scrollCacheExtent instead. ' 'This feature was deprecated after v3.41.0-0.0.pre.')
set cacheExtentStyle (CacheExtentStyle? value)

Implementation

@Deprecated(
  'Use scrollCacheExtent instead. '
  'This feature was deprecated after v3.41.0-0.0.pre.',
)
set cacheExtentStyle(CacheExtentStyle? value) {
  if (value == cacheExtentStyle) {
    return;
  }
  if (value == null) {
    _scrollCacheExtent = ScrollCacheExtent.pixels(cacheExtent);
  } else {
    _scrollCacheExtent = switch (value) {
      CacheExtentStyle.pixel => ScrollCacheExtent.pixels(cacheExtent),
      CacheExtentStyle.viewport => ScrollCacheExtent.viewport(cacheExtent),
    };
  }
  markNeedsLayout();
}