Fixed PositionCursor IsInitialized

This commit is contained in:
Tig
2024-05-06 11:04:56 -06:00
parent efe6f1ec60
commit 2a00435c54

View File

@@ -870,7 +870,7 @@ public partial class View
/// <returns>Viewport-relative cursor position. Return <see langword="null"/> to ensure the cursor is not visible.</returns>
public virtual Point? PositionCursor ()
{
if (CanFocus && HasFocus && ContentSize.HasValue)
if (IsInitialized && CanFocus && HasFocus && ContentSize.HasValue)
{
// Base class will position the cursor at the end of the text.
Point location = Viewport.Location;