Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
shirne committed Sep 23, 2023
1 parent 212d990 commit f686fa2
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions lib/src/controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ abstract class DialogController<T> extends ChangeNotifier
T _value;

bool get isClose;
bool _isClosed = false;

AnimationConfig animate;
AnimationConfig leaveAnimate;
Expand All @@ -33,6 +34,8 @@ abstract class DialogController<T> extends ChangeNotifier

set value(v) {
_value = v;
if (_isClosed) return;
_isClosed = isClose;
notifyListeners();
if (isClose) {
close();
Expand Down Expand Up @@ -144,11 +147,7 @@ class ProgressController extends OverlayController<double> {
super.remove();
}

bool completed = false;

void complete() {
if (completed) return;
completed = true;
value = 1;
}

Expand Down

0 comments on commit f686fa2

Please sign in to comment.