Project tree: Fix behaviour of 'Open with' menu.

[DEVELOPMENT ENVIRONMENT]
* BUG: Project tree: Fix behaviour of 'Open with' menu.
This commit is contained in:
Benoît Minisini 2023-01-04 20:39:19 +01:00
parent 1fd1d16ec8
commit 8309139973
2 changed files with 9 additions and 9 deletions

View file

@ -2,7 +2,7 @@
Title=Gambas 3
Startup=Project
Icon=img/logo/logo-ide.png
Version=3.17.90
Version=3.18.0
VersionFile=1
Component=gb.image
Component=gb.gui

View file

@ -579,7 +579,7 @@ Public Sub mnuPopup_Show()
If sMime Then
hProgList = DesktopFile.FromMime(sMime)
If hProgList And If hProgList.Count Then
mnuEditWith.Visible = sMime
mnuEditWith.Visible = True
mnuEditWith.Tag = hProgList
Endif
Endif
@ -2297,15 +2297,15 @@ End
Public Sub mnuEditWithProg_Click()
Dim sKey As String = Last.Parent.Tag
Dim hProcess As Process
Dim hDesktopFile As DesktopFile
Dim sPath As String
If sKey Then
If CanEdit(sKey) Then
hProcess = Last.Tag.Run(sKey)
hProcess.Ignore = True
Endif
Endif
sPath = GetCurrent()
If Not sPath Then Return
hDesktopFile = Last.Tag
hProcess = hDesktopFile.Run(sPath)
hProcess.Ignore = True
End