TreeView: Canceling the Rename event keeps the editor opened.

[GB.GUI.BASE]
* NEW: TreeView: Canceling the Rename event keeps the editor opened.
This commit is contained in:
gambas 2018-07-17 22:29:04 +02:00
parent 609ef351f8
commit 8c34e888b5

View file

@ -1252,6 +1252,8 @@ End
Private Sub Cancel(Optional bOK As Boolean)
Dim sCursor As String
Dim bStop As Boolean
Dim hItem As _TreeView_Item
If Not $hRenameBox Then Return
@ -1262,13 +1264,15 @@ Private Sub Cancel(Optional bOK As Boolean)
sCursor = $sCursor
$sCursor = $sKeyRenaming
If bOK Then
Raise Rename
bStop = Raise Rename
Else
Raise Cancel
Endif
$sCursor = sCursor
hItem = $cItem[$sKeyRenaming]
$sKeyRenaming = ""
If bStop Then _Rename(hItem, $iColRenaming)
End