[GB.DESKTOP]
* BUG: Support for LXDE mime application cache. [GB.WEB] * NEW: Flush the output before calling Response.End if the response is not buffered. git-svn-id: svn://localhost/gambas/trunk@5137 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
parent
60a4cee44d
commit
e3cc0a986d
@ -135,6 +135,10 @@ Public Sub End()
|
||||
Wend
|
||||
Close #$hFile
|
||||
|
||||
Else
|
||||
|
||||
Flush
|
||||
|
||||
Endif
|
||||
|
||||
End
|
||||
|
@ -27,7 +27,7 @@ SearchString=True
|
||||
File[1]=".src/Desktop.class:362.0"
|
||||
File[2]=".src/DesktopWatcher.class:70.2"
|
||||
Active=3
|
||||
File[3]=".src/DesktopFile.class:66.20"
|
||||
File[3]=".src/DesktopFile.class:66.0"
|
||||
File[4]=".src/Main.module:149.2"
|
||||
File[5]=".src/_DesktopIcons.class:16.0"
|
||||
File[6]=".src/DesktopWindow.class:152.0"
|
||||
|
@ -64,7 +64,6 @@ Public Sub _new(Path As String)
|
||||
Dim sLine As String
|
||||
Dim iPos As Integer
|
||||
Dim sLang As String
|
||||
Dim sKey As String
|
||||
Dim iNameLevel As Integer
|
||||
Dim iLevel As Integer
|
||||
Dim bInDesktopEntry As Boolean
|
||||
@ -252,7 +251,7 @@ Static Private Sub FindInMimeInfoCache(sPath As String, sMime As String) As Stri
|
||||
iPos = InStr(sData, "=", iPos + 1)
|
||||
Return Mid$(sData, iPos + 1, iPos2 - iPos - 1)
|
||||
|
||||
'Catch
|
||||
Catch
|
||||
|
||||
End
|
||||
|
||||
@ -273,8 +272,11 @@ Static Public Sub FindMime(MimeType As String) As DesktopFile[]
|
||||
If MimeType Begins "text/" And If MimeType <> "text/plain" Then aMime.Add("text/plain")
|
||||
|
||||
For Each sMime In aMime
|
||||
|
||||
sList = FindInMimeInfoCache("~/.local/share/applications/mimeinfo.cache", sMime)
|
||||
If Not sList Then sList = FindInMimeInfoCache("/usr/share/applications/mimeinfo.cache", sMime)
|
||||
If Not sList Then sList = FindInMimeInfoCache("~/.local/share/applications/mimeapps.list", sMime)
|
||||
If Not sList Then sList = FindInMimeInfoCache("/usr/share/applications/mimeapps.list", sMime)
|
||||
|
||||
For Each sList In Split(sList, ";", "", True)
|
||||
hProg = DesktopFile[sList]
|
||||
|
Loading…
x
Reference in New Issue
Block a user