HandyControl icon indicating copy to clipboard operation
HandyControl copied to clipboard

Bug 动态切换主题后,Carousel的PageIndex未更新

Open flydream3618 opened this issue 5 months ago • 0 comments

Describe the bug

Carousel控件UpdateItemsPosition()方法:动态切换主题时,Items.Count>0,但PageIndex未更新,闪退

Steps to reproduce the bug

动态切换主题后,当Items.Count=1,此时PageIndex并未更新,依然为-1,闪退,临时方案:额外的检查Items.Count大于0时:PageIndex = PageIndex < 0 ? 0 : PageIndex;

Expected behavior

No response

Screenshots

No response

NuGet package version

None

IDE

No response

Framework type

No response

Windows version

No response

Additional context

No response

flydream3618 avatar Jul 24 '25 06:07 flydream3618