@@ -2125,7 +2125,6 @@ class EditableTextState extends State<EditableText> with AutomaticKeepAliveClien
2125
2125
late final Simulation _iosBlinkCursorSimulation = _DiscreteKeyFrameSimulation .iOSBlinkingCaret ();
2126
2126
2127
2127
final ValueNotifier <bool > _cursorVisibilityNotifier = ValueNotifier <bool >(true );
2128
- final ValueNotifier <bool > _debugCursorNotifier = ValueNotifier <bool >(true );
2129
2128
final GlobalKey _editableKey = GlobalKey ();
2130
2129
2131
2130
/// Detects whether the clipboard can paste.
@@ -2803,8 +2802,6 @@ class EditableTextState extends State<EditableText> with AutomaticKeepAliveClien
2803
2802
void didChangeDependencies () {
2804
2803
super .didChangeDependencies ();
2805
2804
2806
- _debugCursorNotifier.value = widget.showCursor;
2807
-
2808
2805
_style = MediaQuery .boldTextOf (context)
2809
2806
? widget.style.merge (const TextStyle (fontWeight: FontWeight .bold))
2810
2807
: widget.style;
@@ -2959,7 +2956,6 @@ class EditableTextState extends State<EditableText> with AutomaticKeepAliveClien
2959
2956
clipboardStatus.removeListener (_onChangedClipboardStatus);
2960
2957
clipboardStatus.dispose ();
2961
2958
_cursorVisibilityNotifier.dispose ();
2962
- _debugCursorNotifier.dispose ();
2963
2959
FocusManager .instance.removeListener (_unflagInternalFocus);
2964
2960
super .dispose ();
2965
2961
assert (_batchEditDepth <= 0 , 'unfinished batch edits: $_batchEditDepth ' );
@@ -3879,7 +3875,7 @@ class EditableTextState extends State<EditableText> with AutomaticKeepAliveClien
3879
3875
void _onCursorColorTick () {
3880
3876
final double effectiveOpacity = math.min (widget.cursorColor.alpha / 255.0 , _cursorBlinkOpacityController.value);
3881
3877
renderEditable.cursorColor = widget.cursorColor.withOpacity (effectiveOpacity);
3882
- _cursorVisibilityNotifier.value = widget.showCursor && _cursorBlinkOpacityController.value > 0 ;
3878
+ _cursorVisibilityNotifier.value = widget.showCursor && ( EditableText .debugDeterministicCursor || _cursorBlinkOpacityController.value > 0 ) ;
3883
3879
}
3884
3880
3885
3881
bool get _showBlinkingCursor => _hasFocus && _value.selection.isCollapsed && widget.showCursor && _tickersEnabled;
@@ -4860,9 +4856,7 @@ class EditableTextState extends State<EditableText> with AutomaticKeepAliveClien
4860
4856
value: _value,
4861
4857
cursorColor: _cursorColor,
4862
4858
backgroundCursorColor: widget.backgroundCursorColor,
4863
- showCursor: EditableText .debugDeterministicCursor
4864
- ? _debugCursorNotifier
4865
- : _cursorVisibilityNotifier,
4859
+ showCursor: _cursorVisibilityNotifier,
4866
4860
forceLine: widget.forceLine,
4867
4861
readOnly: widget.readOnly,
4868
4862
hasFocus: _hasFocus,
0 commit comments