Skip to content

Commit 58501ab

Browse files
committed
Fix dropdown menu position when window changes horizontally
1 parent dd278eb commit 58501ab

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

packages/dropdown_button2/lib/src/dropdown_button2.dart

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -535,12 +535,7 @@ class _DropdownButton2State<T> extends State<DropdownButton2<T>>
535535
if (_rect.value == null) {
536536
return;
537537
}
538-
final Rect newRect = _getRect();
539-
//This avoid unnecessary rebuilds if _rect position hasn't changed
540-
if (_rect.value!.top == newRect.top) {
541-
return;
542-
}
543-
_rect.value = newRect;
538+
_rect.value = _getRect();
544539
}
545540

546541
TextStyle? get _textStyle =>

0 commit comments

Comments
 (0)