From 7b5daab623437fe58f7aee059623235fd6d8161f Mon Sep 17 00:00:00 2001 From: hkaikai <617760820@qq.com> Date: Sat, 19 Oct 2024 19:19:37 +0800 Subject: [PATCH] =?UTF-8?q?disabled=20=E5=8A=9F=E8=83=BD=E6=94=AF=E6=8C=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../lib/src/components/rate/td_rate.dart | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tdesign-component/lib/src/components/rate/td_rate.dart b/tdesign-component/lib/src/components/rate/td_rate.dart index bd5bf8606..06dc1e567 100644 --- a/tdesign-component/lib/src/components/rate/td_rate.dart +++ b/tdesign-component/lib/src/components/rate/td_rate.dart @@ -197,17 +197,29 @@ class _TDRateState extends State with TickerProviderStateMixin { children: [ GestureDetector( onTapDown: (event) { + if (widget.disabled == true) { + return; + } _isClick = true; }, onTapUp: (details) { + if (widget.disabled == true) { + return; + } _changeSelect(details.globalPosition, true); _hideTip(); }, onHorizontalDragUpdate: (details) { + if (widget.disabled == true) { + return; + } _isClick = false; _changeSelect(details.globalPosition); }, onHorizontalDragEnd: (details) { + if (widget.disabled == true) { + return; + } _hideTip(); }, child: Row(