diff --git a/widget/entry.go b/widget/entry.go index 50cb20109f..9a88c9adfa 100644 --- a/widget/entry.go +++ b/widget/entry.go @@ -1158,17 +1158,23 @@ func (e *Entry) truncatePosition(row, col int) (int, int) { func (e *Entry) updateMousePointer(p fyne.Position, rightClick bool) { row, col := e.getRowCol(p) - e.setFieldsAndRefresh(func() { - if !rightClick || rightClick && !e.selecting { - e.CursorRow = row - e.CursorColumn = col - } + e.propertyLock.Lock() - if !e.selecting { - e.selectRow = row - e.selectColumn = col - } - }) + if !rightClick || !e.selecting { + e.CursorRow = row + e.CursorColumn = col + } + + if !e.selecting { + e.selectRow = row + e.selectColumn = col + } + e.propertyLock.Unlock() + + r := cache.Renderer(e.content) + if r != nil { + r.(*entryContentRenderer).moveCursor() + } } // updateText updates the internal text to the given value