mirror of
https://github.com/doublecmd/doublecmd.git
synced 2026-06-28 10:02:14 +00:00
FIX: Load Lua library
This commit is contained in:
parent
4479e538a2
commit
4b97f2d671
1 changed files with 7 additions and 1 deletions
|
|
@ -35,7 +35,7 @@ function ExecuteScript(const FileName: String; Args: array of String): Boolean;
|
|||
implementation
|
||||
|
||||
uses
|
||||
Forms, Dialogs, LazUTF8, DCOSUtils, fMain, uFormCommands, uOSUtils;
|
||||
Forms, Dialogs, LazUTF8, DCOSUtils, fMain, uFormCommands, uOSUtils, uGlobs;
|
||||
|
||||
function luaFileGetAttr(L : Plua_State) : Integer; cdecl;
|
||||
begin
|
||||
|
|
@ -110,6 +110,12 @@ var
|
|||
begin
|
||||
Result:= False;
|
||||
|
||||
// Load Lua library
|
||||
if not IsLuaLibLoaded then
|
||||
begin
|
||||
if not LoadLuaLib(gLuaLib) then Exit;
|
||||
end;
|
||||
|
||||
// Get script file name
|
||||
Script:= mbFileNameToSysEnc(FileName);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue