From d189a564e38c2b4aa3b5e8a38be70dc53977c453 Mon Sep 17 00:00:00 2001 From: gambas Date: Fri, 10 Aug 2018 11:54:30 +0200 Subject: [PATCH] Use the correct default value for XDG_DATA_DIRS environment variable. [GB.DESKTOP] * BUG: Use the correct default value for XDG_DATA_DIRS environment variable. --- comp/src/gb.desktop/.component | 2 +- comp/src/gb.desktop/.project | 2 +- comp/src/gb.desktop/.settings | 18 +++++------------- comp/src/gb.desktop/.src/Main.module | 8 ++++++-- comp/src/gb.desktop/.startup | 2 +- 5 files changed, 14 insertions(+), 18 deletions(-) diff --git a/comp/src/gb.desktop/.component b/comp/src/gb.desktop/.component index 8c1322007..5d94e371f 100644 --- a/comp/src/gb.desktop/.component +++ b/comp/src/gb.desktop/.component @@ -1,6 +1,6 @@ [Component] Key=gb.desktop -Version=3.10.90 +Version=3.11.90 State=1 Needs=Form Requires=gb.image diff --git a/comp/src/gb.desktop/.project b/comp/src/gb.desktop/.project index 207713171..6666138b5 100644 --- a/comp/src/gb.desktop/.project +++ b/comp/src/gb.desktop/.project @@ -1,7 +1,7 @@ # Gambas Project File 3.0 Title=Desktop-neutral routines from Portland project Startup=Main -Version=3.10.90 +Version=3.11.90 VersionFile=1 Component=gb.image Component=gb.gui diff --git a/comp/src/gb.desktop/.settings b/comp/src/gb.desktop/.settings index f2e431cf5..b39d8aa57 100644 --- a/comp/src/gb.desktop/.settings +++ b/comp/src/gb.desktop/.settings @@ -141,19 +141,11 @@ Path="gb.desktop.gambas" LastCommit="[GB.DESKTOP]\n* BUG: Don't use 'gb.desktop.gnome' anymore, as libgnome-keyring is deprecated. Use the 'secret-tool' program only." [OpenFile] -File[1]=".src/_Desktop_Passwords.class:0.174" -Active=3 -Count=11 -File[2]=".src/Desktop.class:13.575" -File[3]=".src/Main.module:0.174" -File[4]=".src/DesktopMime.class:0.2" -File[5]=".src/Atom.class:9.2" -File[6]=".src/DesktopWatcher.class:9.4" -File[7]=".src/DesktopWindow.class:9.4" -File[8]=".src/Tests/Form1.class:9.2" -File[9]=".src/_DesktopVirtual.class:0.5" -File[10]=".src/_Desktop_Windows.class:9.5" -File[11]=".src/DesktopFile.class:0.30" +File[1]=".src/Desktop.class:0.16" +Active=2 +Count=3 +File[2]=".src/DesktopFile.class:40.500" +File[3]=".src/Main.module:21.143" [VersionControl] User="gambas" diff --git a/comp/src/gb.desktop/.src/Main.module b/comp/src/gb.desktop/.src/Main.module index eeb6e0169..1bcb4a069 100644 --- a/comp/src/gb.desktop/.src/Main.module +++ b/comp/src/gb.desktop/.src/Main.module @@ -143,9 +143,13 @@ End Public Sub GetDataDir() As String[] + Dim sDir As String + If Not $aDataDir Then - $aDataDir = Split(Desktop.DataDir, ":", "", True) - $aDataDir.Insert(Split(Env["XDG_DATA_DIRS"], ":", "", True)) + $aDataDir = [Desktop.DataDir] 'Split(Desktop.DataDir, ":", "", True) + sDir = Env["XDG_DATA_DIRS"] + If Not sDir Then sDir = "/usr/local/share:/usr/share" + $aDataDir.Insert(Split(sDir, ":", "", True)) Endif Return $aDataDir diff --git a/comp/src/gb.desktop/.startup b/comp/src/gb.desktop/.startup index 820e52fa7..a1c7a8a04 100644 --- a/comp/src/gb.desktop/.startup +++ b/comp/src/gb.desktop/.startup @@ -2,7 +2,7 @@ Main Desktop-neutral routines from Portland project 0 0 -3.10.90 +3.11.90 gb.image gb.gui