mirror of
https://gitee.com/openharmony/arkui_ace_engine
synced 2025-03-01 21:07:25 +00:00
!37013 finishAnimation停止动画后布局偏移问题修复
Merge pull request !37013 from LiYi/branch0704
This commit is contained in:
commit
9adced65e0
@ -4810,10 +4810,6 @@ void SwiperPattern::ResetAndUpdateIndexOnAnimationEnd(int32_t nextIndex)
|
||||
preTargetIndex_.reset();
|
||||
}
|
||||
|
||||
if (currentIndex_ == nextIndex) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (isFinishAnimation_) {
|
||||
currentDelta_ = 0.0f;
|
||||
itemPosition_.clear();
|
||||
@ -4825,7 +4821,7 @@ void SwiperPattern::ResetAndUpdateIndexOnAnimationEnd(int32_t nextIndex)
|
||||
pipeline->FlushUITasks();
|
||||
}
|
||||
isFinishAnimation_ = false;
|
||||
} else {
|
||||
} else if (currentIndex_ != nextIndex) {
|
||||
UpdateCurrentIndex(nextIndex);
|
||||
if (currentFocusIndex_ < currentIndex_ || currentFocusIndex_ >= currentIndex_ + GetDisplayCount()) {
|
||||
currentFocusIndex_ = currentIndex_;
|
||||
|
Loading…
x
Reference in New Issue
Block a user