Skip to content

Commit d73b657

Browse files
authored
Remove RenderAligningShiftedBox.mixin (no longer needed) (#105177)
1 parent 82ae612 commit d73b657

File tree

2 files changed

+8
-15
lines changed

2 files changed

+8
-15
lines changed

packages/flutter/lib/src/rendering/debug_overflow_indicator.dart

+4-4
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,10 @@ class _OverflowRegionData {
5353
/// ```dart
5454
/// class MyRenderObject extends RenderAligningShiftedBox with DebugOverflowIndicatorMixin {
5555
/// MyRenderObject({
56-
/// AlignmentGeometry alignment = Alignment.center,
57-
/// TextDirection? textDirection,
58-
/// RenderBox? child,
59-
/// }) : super.mixin(alignment, textDirection, child);
56+
/// super.alignment = Alignment.center,
57+
/// required super.textDirection,
58+
/// super.child,
59+
/// });
6060
///
6161
/// late Rect _containerRect;
6262
/// late Rect _childRect;

packages/flutter/lib/src/rendering/shifted_box.dart

+4-11
Original file line numberDiff line numberDiff line change
@@ -291,12 +291,6 @@ abstract class RenderAligningShiftedBox extends RenderShiftedBox {
291291
_textDirection = textDirection,
292292
super(child);
293293

294-
/// A constructor to be used only when the extending class also has a mixin.
295-
// TODO(gspencer): Remove this constructor once https://github.com/dart-lang/sdk/issues/31543 is fixed.
296-
@protected
297-
RenderAligningShiftedBox.mixin(AlignmentGeometry alignment, TextDirection? textDirection, RenderBox? child)
298-
: this(alignment: alignment, textDirection: textDirection, child: child);
299-
300294
Alignment? _resolvedAlignment;
301295

302296
void _resolve() {
@@ -707,17 +701,16 @@ class RenderConstraintsTransformBox extends RenderAligningShiftedBox with DebugO
707701
///
708702
/// The [alignment] and [clipBehavior] must not be null.
709703
RenderConstraintsTransformBox({
710-
required AlignmentGeometry alignment,
711-
required TextDirection? textDirection,
704+
required super.alignment,
705+
required super.textDirection,
712706
required BoxConstraintsTransform constraintsTransform,
713-
RenderBox? child,
707+
super.child,
714708
Clip clipBehavior = Clip.none,
715709
}) : assert(alignment != null),
716710
assert(clipBehavior != null),
717711
assert(constraintsTransform != null),
718712
_constraintsTransform = constraintsTransform,
719-
_clipBehavior = clipBehavior,
720-
super.mixin(alignment, textDirection, child);
713+
_clipBehavior = clipBehavior;
721714

722715
/// {@macro flutter.widgets.constraintsTransform}
723716
BoxConstraintsTransform get constraintsTransform => _constraintsTransform;

0 commit comments

Comments
 (0)