fixed: caret color

This commit is contained in:
daboe01 committed 2026-02-18 17:29:36 +01:00
1 parent ac52d32c29
commit 836698f8d2
1 file changed
+5 -4
+5 -4
View File
@@ -862,6 +862,11 @@ var kDelegateRespondsTo_textShouldBeginEditing
- (void)drawInsertionPointInRect:(CGRect)aRect color:(CPColor)aColor turnedOn:(BOOL)flag
{
[_caret setRect:aRect];
#if PLATFORM(DOM)
_caret._caretDOM.style.backgroundColor = [_insertionPointColor cssString] || "black";
#endif
[_caret setVisibility:flag stop:NO];
}
@@ -2698,10 +2703,6 @@ var CPTextViewAllowsUndoKey = @"CPTextViewAllowsUndoKey",
if (aLoc >= [_textView._layoutManager numberOfCharacters])
rect.origin.x = CGRectGetMaxX(rect);
#if PLATFORM(DOM)
_caretDOM.style.backgroundColor = [_textView._insertionPointColor cssString] || "black";
#endif
[self setRect:rect];
}