Skip to content

Commit e917939

Browse files
committed
Switched Lib to data
Having it named Lib disallowed creating a shortcut to a stdlib folder/having a custom Lib for the scripts Fixed directory creation while compiled
1 parent 07b4e92 commit e917939

21 files changed

+29
-26
lines changed

Lib/getFileext.ahk

Lines changed: 0 additions & 4 deletions
This file was deleted.

Lib/getFilename.ahk

Lines changed: 0 additions & 4 deletions
This file was deleted.

ScriptUp.ahk

Lines changed: 21 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,31 @@
11
#singleInstance force
22
#persistent
33
#noEnv
4-
#include <threadMan>
4+
setWorkingDir,% a_scriptDir
5+
#include data\threadMan.ahk
56
menu,tray,tip,ScriptUp
67

78
; compiled installs
89
if(a_isCompiled){
9-
fileInstall,Lib\dlls\mini32.dll,Lib\dlls\mini32.dll
10-
fileInstall,Lib\dlls\mini64.dll,Lib\dlls\mini64.dll
11-
fileInstall,Lib\dlls\std32.dll,Lib\dlls\std32.dll
12-
fileInstall,Lib\dlls\std64.dll,Lib\dlls\std64.dll
13-
fileInstall,Lib\imgs\b1.png,Lib\imgs\b1.png
14-
fileInstall,Lib\imgs\b2.png,Lib\imgs\b2.png
15-
fileInstall,Lib\imgs\MXIII.png,Lib\imgs\MXIII.png
16-
fileInstall,Lib\workerH.ahk,Lib\workerH.ahk
10+
fileCreateDir,data\dlls
11+
fileCreateDir,data\imgs
12+
fileInstall,data\dlls\mini32.dll,data\dlls\mini32.dll
13+
fileInstall,data\dlls\mini64.dll,data\dlls\mini64.dll
14+
fileInstall,data\dlls\std32.dll,data\dlls\std32.dll
15+
fileInstall,data\dlls\std64.dll,data\dlls\std64.dll
16+
fileInstall,data\imgs\b1.png,data\imgs\b1.png
17+
fileInstall,data\imgs\b2.png,data\imgs\b2.png
18+
fileInstall,data\imgs\MXIII.png,data\imgs\MXIII.png
19+
fileInstall,data\workerH.ahk,data\workerH.ahk
1720
}
1821

1922
; setup config
2023
;sini:=(siniD:=a_appData . "\..\Local\ScriptUp") . "\config.ini"
21-
setWorkingDir,% a_scriptDir
22-
sini:=a_scriptDir . "\Lib\config.ini"
23-
dlls:=a_scriptDir . "\Lib\dlls"
24-
imgs:=a_scriptDir . "\Lib\imgs"
24+
sini:=a_scriptDir . "\data\config.ini"
25+
dlls:=a_scriptDir . "\data\dlls"
26+
imgs:=a_scriptDir . "\data\imgs"
2527
workerdll:=dlls . "\std" . (a_ptrSize*8) . ".dll"
26-
workerfile:=a_scriptDir . "\Lib\workerH.ahk"
28+
workerfile:=a_scriptDir . "\data\workerH.ahk"
2729
fileLastDir:=a_scriptDir
2830
if(!fileExist(sini))
2931
firstRun:=1
@@ -36,7 +38,7 @@ if(!errorLevel) ; auto-correct if the script has been moved
3638
regWrite,REG_SZ,% regStartupPath,ScriptUp,% a_scriptFullPath
3739

3840
; start worker
39-
#include <guiMake>
41+
#include data\guiMake.ahk
4042
worker:=new threadMan(workerdll)
4143
worker.newFromFile(workerfile)
4244
onExit,cleanup
@@ -52,9 +54,10 @@ if(firstRun){
5254
setTimer,checkStates,1000
5355
return
5456

55-
#include <guiSubs>
56-
#include <optionSubs>
57-
#include <menuSubs>
57+
#include data\guiSubs.ahk
58+
#include data\optionSubs.ahk
59+
#include data\menuSubs.ahk
60+
#include data\functions.ahk
5861

5962
checkStates:
6063
stateList:=worker.varGet("stateList")
File renamed without changes.
File renamed without changes.
File renamed without changes.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,12 @@ hideFocusBorder(wParam,lParam:="",msg:="",handle:=""){ ; by 'just me'
1212
dllCall("user32\PostMessage","ptr",handle,"uint",WM_UPDATEUISTATE,"ptr",SET_HIDEFOCUS,"ptr",0)
1313
}else if(dllCall("IsWindow","ptr",wParam,"uint"))
1414
dllCall("user32\PostMessage","ptr",wParam,"uint",WM_UPDATEUISTATE,"ptr",SET_HIDEFOCUS,"ptr",0)
15+
}
16+
getFilename(path){
17+
splitPath,path,,,,fname
18+
return fname
19+
}
20+
getFileext(path){
21+
splitPath,path,,,ext
22+
return ext
1523
}

0 commit comments

Comments
 (0)