Skip to content
This repository was archived by the owner on Aug 31, 2021. It is now read-only.

Commit 3831e0e

Browse files
committed
[[ ExtensionUtils ]] Tweak load order
1 parent 04827e6 commit 3831e0e

3 files changed

Lines changed: 12 additions & 4 deletions

File tree

Toolset/home.livecodescript

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1193,8 +1193,6 @@ command revInternal__InitialiseLibraries
11931193
put return & "revIDEDocumentationLibrary" after tLoadList
11941194
put return & "revMetadataLibrary" after tLoadList
11951195
put return & "revSBLibrary" after tLoadList
1196-
put return & "extension-utils" after tLoadList
1197-
put return & "revideextensionlibrary" after tLoadList
11981196
put return & "revIDELibrary" after tLoadList
11991197
put return & "revidemessagehandlerlibrary" after tLoadList
12001198
put return & "revBackScriptLibrary" after tLoadList

Toolset/libraries/revideextensionlibrary.livecodescript

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ on extensionInitialize
55
if the target is me then
66
insert script of me into back
77
end if
8+
9+
# Explicitly load extension utils first
10+
revInternal__LoadLibrary "extension-utils"
11+
12+
# Load all the extensions ready for use
13+
__extensionsLoad
814
end extensionInitialize
915

1016
on extensionFinalize
@@ -914,6 +920,7 @@ private command addToList pElement, @xArray
914920
put pElement into xArray[the number of elements in xArray + 1]
915921
end addToList
916922

923+
constant kExtensionUtils = "com.livecode.library.extension-utils"
917924
on __extensionsLoad
918925
local tDataA
919926
# Fetch all the available data about extensions in the search paths
@@ -965,6 +972,10 @@ on __extensionsLoad
965972
tLoadOrder
966973

967974
repeat for each line tLine in tLoadOrder
975+
# Extension utils is explicitly loaded
976+
if tLine is kExtensionUtils then
977+
next repeat
978+
end if
968979
__extensionLoad tLine, tToLoadA[tLine]
969980
end repeat
970981
end __extensionsLoad
@@ -1266,7 +1277,7 @@ private command __revIDELCSExtensionLoad pFullPath, pFolder, pVersion, pStatus,
12661277
__extensionPropertySet tCacheIndex, "type_id", tId & "." & pVersion
12671278

12681279
__extensionPropertySet tCacheIndex, "author", pAdditionalInfoA["author"]
1269-
__extensionPropertySet tCacheIndex, "title", pAdditionalInfoA["display name"]
1280+
__extensionPropertySet tCacheIndex, "title", pAdditionalInfoA["title"]
12701281
__extensionPropertySet tCacheIndex, "svgicon", pAdditionalInfoA["svgicon"]
12711282
__extensionPropertySet tCacheIndex, "version", pAdditionalInfoA["version"]
12721283

Toolset/libraries/revidelibrary.8.livecodescript

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1340,7 +1340,6 @@ on revIDEInitialiseIDELibrary
13401340

13411341
## Load Extensions
13421342
revInternal__LoadLibrary "revideextensionlibrary"
1343-
revIDEInitialiseExtensions
13441343

13451344
## Regenerate dictionary data
13461345
revInternal__LoadLibrary "revDatabaseLibrary"

0 commit comments

Comments
 (0)