diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 12d4f606..881f4187 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -8,10 +8,11 @@ Here are the steps to updating to a new version: 1. Create a fork at github - - See this [guide](https://www.dataschool.io/how-to-contribute-on-github/) for setting up and using a fork + - See this [guide](https://www.dataschool.io/how-to-contribute-on-github/) for setting up and using a fork. + - See [Forking / Testing](#forking-testing) for advice to do independent testing. 2. Make whatever changes are necessary. -*Steps 3 through 10 only apply if you intend to merge your changes immediately into the master repository for Thor. This can only happen if you have access to do so and you are sure that your changes do not need any further testing by others.* +**Steps 3 through 10 only apply if you intend to merge your changes immediately into the master repository for Thor. This can only happen if you have access to do so and you are sure that your changes do not need any further testing by others.** *If you do not intend to merge into the master repository or are in any way unsure what this means, skip directly to step 11.* @@ -19,11 +20,11 @@ Here are the steps to updating to a new version: #### If updating Thor.App 3. Edit _Installed Files\Source\ThorVersion.h_ and change the version constants. 1. Update the AvailableVersion property in _ThorUpdater\\_ThorVersionFile.txt_. Be certain that the value be identical to the value of the `ccThorInternalVERSION` constant in _ThorVersion.h_. -1. Update the version number and date at the top of _README.md_ -1. Describe the changes in _Change Log.md_. +1. Update the version number and date at the top of _README.md_. +1. Describe the changes in _Change Log.md_, set the date on the footer to recent date. 1. Run FoxBin2Prg to create the text files in folder _Installed Files_ - `DO foxbin2prg.prg WITH 'BIN2PRG','*.*'` -1. Run _BuildThor.PRG_ in folder _"Installed Files\Source"_ to re-create the APP. You will need to this in an environment where Thor is no longer running: +1. Run _BuildThor.PRG_ in folder _"Installed Files\Source"_ to re-create the APP. You will need to do this in an environment where Thor is no longer running: - `Cancel()` - `Close All` - `Clear All` @@ -39,10 +40,59 @@ This applies to all updaters except those few (15 or so) where the version infor --- ### Finally 10. In folder _ThorUpdater_, right-click _CreateThorUpdate.ps1_ and select **Run with PowerShell** from the shortcut menu to re-create the installation zip files. -1. Commit -1. Push to your fork -1. Create a pull request +11. Commit +12. Push to your fork +13. Create a pull request +### Forking / Testing +If you consider to do an independent test of your fork (or run your fork for your needs), you might want to alter the repository or the branch of Thor or [ThorRepository](https://github.com/VFPX/Thorrepository). +Repository and branch determine the URL. + +The URL to a file on github comes in a form `https://github.com/VFPX/Thor/blob/master/Docs/TWEeTs.md`, +where `VFPX/Thor` is a *repository* (Thor) and *project* (VFPX), and `master` is the *branch*. +DEFINES are used to access those in several files. Alter the DEFINES to your repository and branch. + +#### Common helper project +To keep the files to target a change of URL together, there is an otherwise useless project: Thor_Help.pjx. +Compile this to force changes to the DEFINE into the code. + +#### Redirect Thor +You might redirect the web access from the main repository. To do so alter in: +- installed files\source\thor.h +- updaters\updates\thor_update_thor.prg +``` +#Define ccThor_URL 'VFPX/Thor' +#Define ccThor_Branch '/master' +``` +**Note, the leading slash on `ccThor_Branch` is mandatory.** + +The following files are touched by this DEFINES and must be compiled if the DEFINE is altered. Use the [helper project] (#common-helper-project) to compile. +- installed files\source\procs_for_thor\thor_proc_check_for_updates.prg +- installed files\thor\tools\procs\thor_proc_check_for_updates.prg +- installed files\thor\tools\thor_tool_thorchangelog.prg +- installed files\thor\tools\thor_tool_thorinternalframeworkhelp.prg +- installed files\thor\tools\thor_tool_thorinternalhelp.prg +- installed files\thor\tools\thor_tool_thorinternalrepositoryhomepage.prg +- installed files\thor\tools\thor_tool_thorinternaltweets.prg +- updaters\updates\thor_update_thor.prg +- installed files\source\thor_run.vcx +- installed files\source\thorformruntool.scx + +#### Redirect ThorRepository +You might redirect the web access from the main repository. To do so alter in: +- installed files\source\thor.h +- updaters\updates\thor_update_thorrepository.prg +``` +#Define ccThorRepository_URL 'VFPX/ThorRepository' +#Define ccThorRepository_Branch '/master' +``` + +**Note, the leading slash on `ccThorRepository` is mandatory.** + +The following files are touched by this DEFINES and must be compiled if the DEFINE is altered. Use the [helper project] (#common-helper-project) to compile. +- updaters\updates\old_thor_update_thor_repository.prg +- installed files\source\thor_update_thor_repository_beta.prg +- updaters\updates\thor_update_thorrepository.prg ---- -Last changed: _2023/01/21_ ![Picture](vfpxpoweredby_alternative.gif) +Last changed: _2023/12/01_ ![Picture](vfpxpoweredby_alternative.gif) diff --git a/.gitignore b/.gitignore index 8ff2c056..0d1f2c8a 100644 --- a/.gitignore +++ b/.gitignore @@ -28,3 +28,9 @@ syntax: glob *.SAVE *.zip *.ZIP + +*code references files +*_ref.dbf +*_ref.cdx +*_ref.fpt +*_ref.db2 diff --git a/Change Log.md b/Change Log.md index dc7ac873..9f6cf680 100644 --- a/Change Log.md +++ b/Change Log.md @@ -237,4 +237,4 @@ Thor Production Release - Released 2011-09-03 ## Contribution See [contribution](./.github/CONTRIBUTING.md) -Last changed: _2023/01/20_ ![Picture](Docs/Images/vfpxpoweredby_alternative.gif) \ No newline at end of file +Last changed: _2023/11/27_ ![Picture](Docs/Images/vfpxpoweredby_alternative.gif) \ No newline at end of file diff --git a/Installed Files/Source/Procs_For_Thor/thor_proc_check_for_updates.prg b/Installed Files/Source/Procs_For_Thor/thor_proc_check_for_updates.prg index e7ab8e5a..01bf5ab9 100644 --- a/Installed Files/Source/Procs_For_Thor/thor_proc_check_for_updates.prg +++ b/Installed Files/Source/Procs_For_Thor/thor_proc_check_for_updates.prg @@ -1,79 +1,83 @@ -Local laFiles[1], lcToolFolder, lcUpdateFolder, llAutoRun, lnFileCount, lnI, lnReturn - -*** DH 2021-12-28: changed URL from VFPXRepository to GitHub -#Define UpdaterURL 'https://raw.githubusercontent.com/VFPX/Thor/master/ThorUpdater/Updates.zip' - -WritetoCFULog('Begin CFU - ' + Transform(Datetime())) - -If Not Execscript (_Screen.cThorDispatcher, 'Thor_Proc_CheckInternetConnection') - Messagebox ('No Internet Connection Found!', 16, 'No Internet Connection', 0) - Return .F. -Endif - -WritetoCFULog('Checking for updates to Thor', .T.) - -If Execscript (_Screen.cThorDispatcher, 'Thor_Proc_DownloadAndInstallUpdates', .T.) >= 0 - - lcToolFolder = Execscript (_Screen.cThorDispatcher, 'Tool Folder=') - WritetoCFULog('Erasing Thor FXP files...') - EraseFXPFiles (lcToolFolder) - WritetoCFULog('Erasing Thor FXP files from Thor Procs folder...') - EraseFXPFiles (lcToolFolder + 'Procs') - WritetoCFULog('Erasing Thor FXP files from Thor MyTools folder...') - EraseFXPFiles (lcToolFolder + 'My Tools') - - lcUpdateFolder = Addbs (lcToolFolder) + 'Updates\' - lnFileCount = Adir (laFiles, lcUpdateFolder + '*.PRG') - WritetoCFULog('Processing (' + transform(lnFileCount) + ') Thor updater programs...') - - For lnI = 1 To lnFileCount - If Not Upper (laFiles[lnI, 1]) == Upper ('Thor_Update_Thor.PRG') - Erase (lcUpdateFolder + laFiles[lnI, 1]) - Endif - Endfor - *** Download the zip of Updaters, and install them - lnReturn = Execscript (_Screen.cThorDispatcher ; - , 'Thor_Proc_DownloadAndExtractToPath' ; - , UpdaterURL + '?=' + Sys(2015) ; - , lcToolFolder ; - , .T. ; - , 'Updates') - - *** Check if called from RunThor, meaning it is from AutoRun - llAutoRun = .F. - For lnI = 1 To Program (-1) - llAutoRun = llAutoRun Or 'RUNTHOR' $ Upper (Sys(16, lnI)) - Endfor - - WritetoCFULog('Checking for updates to all other apps', .T.) - - Execscript (_Screen.cThorDispatcher, 'Thor_Proc_DownloadAndInstallUpdates', .F., llAutoRun) - - Execscript (_Screen.cThorDispatcher, 'Run') - -Endif - -Execscript (_Screen.cThorDispatcher, 'Thor_Tool_ThorInternalThorNews', 'Check For Updates') - -Wait Clear - -Return - - -Procedure EraseFXPFiles (tcFolder) - Local lcFolder, lnCount, lnI, loException - lcFolder = Addbs (tcFolder) - lnCount = Adir (laFiles, lcFolder + '*.FXP') - For lnI = 1 To lnCount - Try - Erase (lcFolder + laFiles[lnI, 1]) - Catch To loException - - Endtry - Endfor -Endproc - - -Procedure WritetoCFULog(tcText, tlDivider) - Execscript (_Screen.cThorDispatcher, 'Thor_Proc_WritetoCFULog(', tcText, tlDivider) -EndProc +#Include ..\Thor.h +Local laFiles[1], lcToolFolder, lcUpdateFolder, llAutoRun, lnFileCount, lnI, lnReturn + +*** DH 2021-12-28: changed URL from VFPXRepository to GitHub +*SF 20231130 Change fixed URL to #DEFINE +*#Define UpdaterURL 'https://raw.githubusercontent.com/VFPX/Thor/master/ThorUpdater/Updates.zip' +#Define UpdaterURL 'https://raw.githubusercontent.com/'+ccThor_URL+ccThor_Branch+'/ThorUpdater/Updates.zip' +*/SF 20231130 Change fixed URL to #DEFINE + +WritetoCFULog('Begin CFU - ' + Transform(Datetime())) + +If Not Execscript (_Screen.cThorDispatcher, 'Thor_Proc_CheckInternetConnection') + Messagebox ('No Internet Connection Found!', 16, 'No Internet Connection', 0) + Return .F. +Endif + +WritetoCFULog('Checking for updates to Thor', .T.) + +If Execscript (_Screen.cThorDispatcher, 'Thor_Proc_DownloadAndInstallUpdates', .T.) >= 0 + + lcToolFolder = Execscript (_Screen.cThorDispatcher, 'Tool Folder=') + WritetoCFULog('Erasing Thor FXP files...') + EraseFXPFiles (lcToolFolder) + WritetoCFULog('Erasing Thor FXP files from Thor Procs folder...') + EraseFXPFiles (lcToolFolder + 'Procs') + WritetoCFULog('Erasing Thor FXP files from Thor MyTools folder...') + EraseFXPFiles (lcToolFolder + 'My Tools') + + lcUpdateFolder = Addbs (lcToolFolder) + 'Updates\' + lnFileCount = Adir (laFiles, lcUpdateFolder + '*.PRG') + WritetoCFULog('Processing (' + transform(lnFileCount) + ') Thor updater programs...') + + For lnI = 1 To lnFileCount + If Not Upper (laFiles[lnI, 1]) == Upper ('Thor_Update_Thor.PRG') + Erase (lcUpdateFolder + laFiles[lnI, 1]) + Endif + Endfor + *** Download the zip of Updaters, and install them + lnReturn = Execscript (_Screen.cThorDispatcher ; + , 'Thor_Proc_DownloadAndExtractToPath' ; + , UpdaterURL + '?=' + Sys(2015) ; + , lcToolFolder ; + , .T. ; + , 'Updates') + + *** Check if called from RunThor, meaning it is from AutoRun + llAutoRun = .F. + For lnI = 1 To Program (-1) + llAutoRun = llAutoRun Or 'RUNTHOR' $ Upper (Sys(16, lnI)) + Endfor + + WritetoCFULog('Checking for updates to all other apps', .T.) + + Execscript (_Screen.cThorDispatcher, 'Thor_Proc_DownloadAndInstallUpdates', .F., llAutoRun) + + Execscript (_Screen.cThorDispatcher, 'Run') + +Endif + +Execscript (_Screen.cThorDispatcher, 'Thor_Tool_ThorInternalThorNews', 'Check For Updates') + +Wait Clear + +Return + + +Procedure EraseFXPFiles (tcFolder) + Local lcFolder, lnCount, lnI, loException + lcFolder = Addbs (tcFolder) + lnCount = Adir (laFiles, lcFolder + '*.FXP') + For lnI = 1 To lnCount + Try + Erase (lcFolder + laFiles[lnI, 1]) + Catch To loException + + Endtry + Endfor +Endproc + + +Procedure WritetoCFULog(tcText, tlDivider) + Execscript (_Screen.cThorDispatcher, 'Thor_Proc_WritetoCFULog(', tcText, tlDivider) +EndProc diff --git a/Installed Files/Source/Procs_For_Thor/thor_proc_getupdatelist.prg b/Installed Files/Source/Procs_For_Thor/thor_proc_getupdatelist.prg index 07a9c356..1050991f 100644 --- a/Installed Files/Source/Procs_For_Thor/thor_proc_getupdatelist.prg +++ b/Installed Files/Source/Procs_For_Thor/thor_proc_getupdatelist.prg @@ -34,6 +34,12 @@ Procedure AddUpdateFolder (loUpdateList, tlIsThor, lcUpdateFolder, lcNeverUpdate Loop Endif +*SF 20231201 Ignore file in Updates, if identical named file is found in My Updates; #203 + IF tcFromMyUpdates=='No' AND File (tcUpdateFolder + 'My Updates\' + laFiles[lnI, 1]) Then + Loop + ENDIF &&tcFromMyUpdates=='No' AND File (tcUpdateFolder + 'My Updates\' + laFiles[lnI, 1]) +*SF 20231201 Ignore file in Updates, if identical named file is found in My Updates; #203 + loResult = Execscript (_Screen.cThorDispatcher, 'Thor_Proc_GetUpdaterObject2') loResult.File = lcFile loResult.FromMyUpdates = tcFromMyUpdates diff --git a/Installed Files/Source/thor.h b/Installed Files/Source/thor.h index 14eb8d4e..0586d2e0 100644 --- a/Installed Files/Source/thor.h +++ b/Installed Files/Source/thor.h @@ -1,58 +1,63 @@ -#include FOXPRO.H - -* Virtual key codes. - -#define VK_SHIFT 0x10 -#define VK_CONTROL 0x11 -#define VK_MENU 0x12 - -* Modifier key values. - -#define cnNO_MODIFIER 0 -#define cnSHIFT 1 -#define cnCTRL 2 -#define cnALT 4 - -#define ccCR chr(13) -#define ccLF chr(10) -#define ccCRLF chr(13) + chr(10) -#define ccTAB chr(9) - -#Define ccTOOLNAMEPREFIX 'Thor_Tool_' - -#define ccINTERNALEDITPRG ccTOOLNAMEPREFIX + 'ThorInternalEdit.PRG' -#define ccINTERNALHELPPRG ccTOOLNAMEPREFIX + 'ThorInternalHelp.PRG' -#define ccINTERNALALLTOOLSPRG ccTOOLNAMEPREFIX + 'ThorInternalAllTools.PRG' -#define ccINTERNALFRAMEWORK ccTOOLNAMEPREFIX + 'ThorInternalFrameWork.PRG' -#define ccCHECKFORUPDATES ccTOOLNAMEPREFIX + 'Thor_CheckForUpdates.PRG' -#define ccCOMMUNITY ccTOOLNAMEPREFIX + 'Thor_Community.PRG' -#define ccThorNews ccTOOLNAMEPREFIX + 'ThorInternalThorNews.PRG' -#define ccThorTWEeTs ccTOOLNAMEPREFIX + 'ThorInternalTWEeTs.PRG' -#define ccINTERNALRepostitory ccTOOLNAMEPREFIX + 'ThorInternalRepositoryHomePage.PRG' -#define ccINTERNALMODIFY ccTOOLNAMEPREFIX + 'ThorInternalModifyTool.PRG' -#define ccINTERNALTOOLLINK ccTOOLNAMEPREFIX + 'ThorInternalToolLink.PRG' -#define ccOPENFOLDERS ccTOOLNAMEPREFIX + 'ThorInternalOpenFolders.PRG' -#define ccSOURCEFILES ccTOOLNAMEPREFIX + 'ThorInternalSourceFiles.PRG' -#define ccUSAGESUMMARY ccTOOLNAMEPREFIX + 'ThorInternalUsageSummary.PRG' -#define ccDEBUGMODE ccTOOLNAMEPREFIX + 'ThorInternalDebugMode.PRG' -#Define ccMANAGEPLUGINS ccTOOLNAMEPREFIX + 'ThorInternalManagePlugIns.PRG' -#Define ccTOGGLEDEBUGMODE 'Toggle Debug Mode' - -#define ccMyTools 'My Tools' -#define ccProcs 'Procs' -#define ccUpdates 'Updates' -#define ccApps 'Apps' -#define ccComponents 'Components' -#define ccMySettings ccMyTools + '\Settings' -#define ccMyTemplates ccMyTools + '\Templates' -#define ccMyStartThorUI ccMyTools + '\StartThorUI' - -#Define ccThorDefaultTemplate 'Thor Default' - -#Define ccTemplatePrefix 'Thor_Tool_Template_' - -#Define ccOnKeyLabelPrefix 'ExecScript(_Screen.cThorDispatcher, "' - -#Define ccOnKeyLabelSuffix '")' - -#Define ccPEMEditor 'IDE Tools' \ No newline at end of file +#include FOXPRO.H + +* Virtual key codes. + +#define VK_SHIFT 0x10 +#define VK_CONTROL 0x11 +#define VK_MENU 0x12 + +* Modifier key values. + +#define cnNO_MODIFIER 0 +#define cnSHIFT 1 +#define cnCTRL 2 +#define cnALT 4 + +#define ccCR chr(13) +#define ccLF chr(10) +#define ccCRLF chr(13) + chr(10) +#define ccTAB chr(9) + +#Define ccTOOLNAMEPREFIX 'Thor_Tool_' + +#define ccINTERNALEDITPRG ccTOOLNAMEPREFIX + 'ThorInternalEdit.PRG' +#define ccINTERNALHELPPRG ccTOOLNAMEPREFIX + 'ThorInternalHelp.PRG' +#define ccINTERNALALLTOOLSPRG ccTOOLNAMEPREFIX + 'ThorInternalAllTools.PRG' +#define ccINTERNALFRAMEWORK ccTOOLNAMEPREFIX + 'ThorInternalFrameWork.PRG' +#define ccCHECKFORUPDATES ccTOOLNAMEPREFIX + 'Thor_CheckForUpdates.PRG' +#define ccCOMMUNITY ccTOOLNAMEPREFIX + 'Thor_Community.PRG' +#define ccThorNews ccTOOLNAMEPREFIX + 'ThorInternalThorNews.PRG' +#define ccThorTWEeTs ccTOOLNAMEPREFIX + 'ThorInternalTWEeTs.PRG' +#define ccINTERNALRepostitory ccTOOLNAMEPREFIX + 'ThorInternalRepositoryHomePage.PRG' +#define ccINTERNALMODIFY ccTOOLNAMEPREFIX + 'ThorInternalModifyTool.PRG' +#define ccINTERNALTOOLLINK ccTOOLNAMEPREFIX + 'ThorInternalToolLink.PRG' +#define ccOPENFOLDERS ccTOOLNAMEPREFIX + 'ThorInternalOpenFolders.PRG' +#define ccSOURCEFILES ccTOOLNAMEPREFIX + 'ThorInternalSourceFiles.PRG' +#define ccUSAGESUMMARY ccTOOLNAMEPREFIX + 'ThorInternalUsageSummary.PRG' +#define ccDEBUGMODE ccTOOLNAMEPREFIX + 'ThorInternalDebugMode.PRG' +#Define ccMANAGEPLUGINS ccTOOLNAMEPREFIX + 'ThorInternalManagePlugIns.PRG' +#Define ccTOGGLEDEBUGMODE 'Toggle Debug Mode' + +#define ccMyTools 'My Tools' +#define ccProcs 'Procs' +#define ccUpdates 'Updates' +#define ccApps 'Apps' +#define ccComponents 'Components' +#define ccMySettings ccMyTools + '\Settings' +#define ccMyTemplates ccMyTools + '\Templates' +#define ccMyStartThorUI ccMyTools + '\StartThorUI' + +#Define ccThorDefaultTemplate 'Thor Default' + +#Define ccTemplatePrefix 'Thor_Tool_Template_' + +#Define ccOnKeyLabelPrefix 'ExecScript(_Screen.cThorDispatcher, "' + +#Define ccOnKeyLabelSuffix '")' + +#Define ccPEMEditor 'IDE Tools' + +#Define ccThor_URL 'VFPX/Thor' +#Define ccThor_Branch '/master' +#Define ccThorRepository_URL 'VFPX/ThorRepository' +#Define ccThorRepository_Branch '/master' \ No newline at end of file diff --git a/Installed Files/Source/thor.pj2 b/Installed Files/Source/thor.pj2 index 7cafc34f..8cadb226 100644 --- a/Installed Files/Source/thor.pj2 +++ b/Installed Files/Source/thor.pj2 @@ -1,8 +1,7 @@ *-------------------------------------------------------------------------------------------------------------------------------------------------------- -* (ES) AUTOGENERADO - ¡¡ATENCIÓN!! - ¡¡NO PENSADO PARA EJECUTAR!! USAR SOLAMENTE PARA INTEGRAR CAMBIOS Y ALMACENAR CON HERRAMIENTAS SCM!! * (EN) AUTOGENERATED - ATTENTION!! - NOT INTENDED FOR EXECUTION!! USE ONLY FOR MERGING CHANGES AND STORING WITH SCM TOOLS!! *-------------------------------------------------------------------------------------------------------------------------------------------------------- -*< FOXBIN2PRG: Version="1.19" SourceFile="thor.pjx" /> (Solo para binarios VFP 9 / Only for VFP 9 binaries) +*< FOXBIN2PRG: Version="1.21" SourceFile="thor.pjx" CPID="1252" /> (Solo para binarios VFP 9 / Only for VFP 9 binaries) * LPARAMETERS tcDir @@ -33,7 +32,7 @@ _AutoIncrement = "0" * -*<.HomeDir = 'c:\visual foxpro\vfpx\thor\thor\source' /> +*<.HomeDir = 'e:\se\vfpx\thor\installed files\source' /> FOR EACH loProject IN _VFP.Projects FOXOBJECT loProject.Close() @@ -50,7 +49,7 @@ MODIFY PROJECT 'thor.pjx' NOWAIT NOSHOW NOPROJECTHOOK loProject = _VFP.Projects('thor.pjx') WITH loProject.FILES - .ADD('..\..\..\..\..\program files (x86)\microsoft visual foxpro 9\foxtools.fll') && *< FileMetadata: Type="L" Cpid="0" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('..\..\..\..\foxpro\foxtools.fll') && *< FileMetadata: Type="L" Cpid="0" Timestamp="0" ID="0" ObjRev="0" User="" /> .ADD('basecontrols.vcx') && *< FileMetadata: Type="V" Cpid="1252" Timestamp="0" ID="0" ObjRev="544" User="" /> .ADD('createdirectorystructure.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="544" User="" /> .ADD('createrunthorprg.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="544" User="" /> @@ -103,12 +102,16 @@ WITH loProject.FILES * * - .ITEM(lcCurdir + '..\..\..\..\..\program files (x86)\microsoft visual foxpro 9\foxtools.fll').Exclude = .T. + .ITEM(lcCurdir + '..\..\..\..\foxpro\foxtools.fll').Exclude = .T. .ITEM(lcCurdir + 'tables\hotkeydefinitions.dbf').Exclude = .T. .ITEM(lcCurdir + 'tables\menudefinitions.dbf').Exclude = .T. .ITEM(lcCurdir + 'tables\menutools.dbf').Exclude = .T. .ITEM(lcCurdir + 'tables\thor.dbf').Exclude = .T. .ITEM(lcCurdir + 'tables\toolhotkeyassignments.dbf').Exclude = .T. + .ITEM(lcCurdir + 'thor.h').Exclude = .T. + .ITEM(lcCurdir + 'thor_english.h').Exclude = .T. + .ITEM(lcCurdir + 'thor_ui.h').Exclude = .T. + .ITEM(lcCurdir + 'thorversion.h').Exclude = .T. * * diff --git a/Installed Files/Source/thor.pjt b/Installed Files/Source/thor.pjt index f4b5e9c6..39636169 100644 Binary files a/Installed Files/Source/thor.pjt and b/Installed Files/Source/thor.pjt differ diff --git a/Installed Files/Source/thor.pjx b/Installed Files/Source/thor.pjx index d37ef3a4..a1f67ec8 100644 Binary files a/Installed Files/Source/thor.pjx and b/Installed Files/Source/thor.pjx differ diff --git a/Installed Files/Source/thor_run.vct b/Installed Files/Source/thor_run.vct index bf092a91..1cbf2ca1 100644 Binary files a/Installed Files/Source/thor_run.vct and b/Installed Files/Source/thor_run.vct differ diff --git a/Installed Files/Source/thor_run.vcx b/Installed Files/Source/thor_run.vcx index e327ea1c..7dee0a7f 100644 Binary files a/Installed Files/Source/thor_run.vcx and b/Installed Files/Source/thor_run.vcx differ diff --git a/Installed Files/Source/thor_ui.h b/Installed Files/Source/thor_ui.h index c655e133..1e79cf28 100644 --- a/Installed Files/Source/thor_ui.h +++ b/Installed Files/Source/thor_ui.h @@ -1,44 +1,48 @@ -#include Thor.H -#include Thor_English.H - -* Windows event handling constants. - -#define WM_KEYUP 0x0101 -#define WM_SYSKEYUP 0x0105 - -* TreeView constants. - -#define cnROOT_NODE 0 -#define cnCHILD_NODE 4 - -* Menu constants. - -#define ccKEY_ROOT_SYSTEM_MENU 'VFP' -#define ccKEY_ROOT_POPUP_MENU 'POPUP' - -* Other constants. - -#define ccSEPARATOR_PROMPT '----------------------' -#define ccKEY_MENU 'M' -#define ccKEY_TOOL 'T' -#define ccKEY_SEPARATOR '\' -#define ccIMAGE_MENU 'Menu' -#define ccIMAGE_TOOL 'Tool' -#define ccIMAGE_POPUP 'Popup' - -*** DH 2018-04-10: new URLS -#Define ThorHelpURL 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_help.md' -#Define ThorFrameworkURL 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_repository.md' - -#Define ccRunAllTools 'Thor_Run_Tools' - -#Define cnDefaultMissingBackColor RGB(255,0,0) -#Define cnDefaultMissingForeColor RGB(255,255,255) - -#Define cnDefaultPrivateBackColor RGB(255,255,0) -#Define cnDefaultPrivateForeColor RGB(255,0,0) - -#Define cnDefaultPersonalBackColor RGB(255,255,0) -#Define cnDefaultPersonalForeColor RGB(0,0,0) - -#Define ccThorIcon 'Thor16.png' +#include Thor.H +#include Thor_English.H + +* Windows event handling constants. + +#define WM_KEYUP 0x0101 +#define WM_SYSKEYUP 0x0105 + +* TreeView constants. + +#define cnROOT_NODE 0 +#define cnCHILD_NODE 4 + +* Menu constants. + +#define ccKEY_ROOT_SYSTEM_MENU 'VFP' +#define ccKEY_ROOT_POPUP_MENU 'POPUP' + +* Other constants. + +#define ccSEPARATOR_PROMPT '----------------------' +#define ccKEY_MENU 'M' +#define ccKEY_TOOL 'T' +#define ccKEY_SEPARATOR '\' +#define ccIMAGE_MENU 'Menu' +#define ccIMAGE_TOOL 'Tool' +#define ccIMAGE_POPUP 'Popup' + +*** DH 2018-04-10: new URLS +*SF 20231130 Change fixed URL to #DEFINE +*#Define ThorHelpURL 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_help.md' +*#Define ThorFrameworkURL 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_repository.md' +#Define ThorHelpURL 'https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/Thor_help.md' +#Define ThorFrameworkURL 'https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/Thor_repository.md' +*/SF 20231130 Change fixed URL to #DEFINE + +#Define ccRunAllTools 'Thor_Run_Tools' + +#Define cnDefaultMissingBackColor RGB(255,0,0) +#Define cnDefaultMissingForeColor RGB(255,255,255) + +#Define cnDefaultPrivateBackColor RGB(255,255,0) +#Define cnDefaultPrivateForeColor RGB(255,0,0) + +#Define cnDefaultPersonalBackColor RGB(255,255,0) +#Define cnDefaultPersonalForeColor RGB(0,0,0) + +#Define ccThorIcon 'Thor16.png' diff --git a/Installed Files/Source/thor_update_thor_repository_beta.prg b/Installed Files/Source/thor_update_thor_repository_beta.prg index 10c46e67..653e2afe 100644 --- a/Installed Files/Source/thor_update_thor_repository_beta.prg +++ b/Installed Files/Source/thor_update_thor_repository_beta.prg @@ -1,12 +1,12 @@ -Lparameters loUpdateObject - -With loUpdateObject - .ApplicationName = 'ThorRepository Beta' - .ToolName = 'Thor_Tool_ThorInternalRepository' - .VersionFileURL = 'http://foxpro.mattslay.com/JRN/Thor_Repository/Beta/ThorRepositoryVersionFileBeta.txt' - .VersionLocalFilename = 'ThorRepositoryVersionFileBeta.txt' - .RegisterWithThor = '' -Endwith - -Return loUpdateObject - +Lparameters loUpdateObject + +With loUpdateObject + .ApplicationName = 'ThorRepository Beta' + .ToolName = 'Thor_Tool_ThorInternalRepository' + .VersionFileURL = 'http://foxpro.mattslay.com/JRN/Thor_Repository/Beta/ThorRepositoryVersionFileBeta.txt' + .VersionLocalFilename = 'ThorRepositoryVersionFileBeta.txt' + .RegisterWithThor = '' +Endwith + +Return loUpdateObject + diff --git a/Installed Files/Source/thorformruntool.sct b/Installed Files/Source/thorformruntool.sct index 0f406dae..221ceeb5 100644 Binary files a/Installed Files/Source/thorformruntool.sct and b/Installed Files/Source/thorformruntool.sct differ diff --git a/Installed Files/Source/thorformruntool.scx b/Installed Files/Source/thorformruntool.scx index 9379c8fe..87ce1bd8 100644 Binary files a/Installed Files/Source/thorformruntool.scx and b/Installed Files/Source/thorformruntool.scx differ diff --git a/Installed Files/Thor/Tools/Procs/Thor_Proc_Check_For_Updates.PRG b/Installed Files/Thor/Tools/Procs/Thor_Proc_Check_For_Updates.PRG index d27a9688..64c62aa5 100644 --- a/Installed Files/Thor/Tools/Procs/Thor_Proc_Check_For_Updates.PRG +++ b/Installed Files/Thor/Tools/Procs/Thor_Proc_Check_For_Updates.PRG @@ -1,86 +1,90 @@ -Local laFiles[1], lcCFUFolder, lcToolFolder, lcUpdateFolder, llAutoRun, lnFileCount, lnI, lnReturn - -*** DH 2021-12-28: changed URL from VFPXRepository to GitHub -#Define UpdaterURL 'https://raw.githubusercontent.com/VFPX/Thor/master/ThorUpdater/Updates.zip' - -*** DH 2022-01-06: added SET SAFETY OFF to eliminate overwrite prompts -Set Safety Off - -lcCFUFolder = Sys(2023) + '\Thor.CheckForUpdates.' + Left(Ttoc(Datetime(), 1), 8) + '.' + Right(Ttoc(Datetime(), 1), 6) + '\' -Mkdir(m.lcCFUFolder) -_Screen.AddProperty('cThorCFUFolder', m.lcCFUFolder) - -WritetoCFULog('Begin CFU - ' + Transform(Datetime())) - -If Not Execscript (_Screen.cThorDispatcher, 'Thor_Proc_CheckInternetConnection') - Messagebox ('No Internet Connection Found!', 16, 'No Internet Connection', 0) - Return .F. -Endif - -WritetoCFULog('Checking for updates to Thor', .T.) - -If Execscript (_Screen.cThorDispatcher, 'Thor_Proc_DownloadAndInstallUpdates', .T.) >= 0 - - lcToolFolder = Execscript (_Screen.cThorDispatcher, 'Tool Folder=') - WritetoCFULog('Erasing Thor FXP files...') - EraseFXPFiles (m.lcToolFolder) - WritetoCFULog('Erasing Thor FXP files from Thor Procs folder...') - EraseFXPFiles (m.lcToolFolder + 'Procs') - WritetoCFULog('Erasing Thor FXP files from Thor MyTools folder...') - EraseFXPFiles (m.lcToolFolder + 'My Tools') - - lcUpdateFolder = Addbs (m.lcToolFolder) + 'Updates\' - lnFileCount = Adir (laFiles, m.lcUpdateFolder + '*.PRG') - WritetoCFULog('Processing (' + Transform(m.lnFileCount) + ') Thor updater programs...') - - For lnI = 1 To m.lnFileCount - If Not Upper (m.laFiles[m.lnI, 1]) == Upper ('Thor_Update_Thor.PRG') - Erase (m.lcUpdateFolder + m.laFiles[m.lnI, 1]) - Endif - Endfor - *** Download the zip of Updaters, and install them - lnReturn = Execscript (_Screen.cThorDispatcher ; - , 'Thor_Proc_DownloadAndExtractToPath' ; - , UpdaterURL + '?=' + Sys(2015) ; - , m.lcToolFolder ; - , .T. ; - , 'Updates') - - *** Check if called from RunThor, meaning it is from AutoRun - llAutoRun = .F. - For lnI = 1 To Program (-1) - llAutoRun = m.llAutoRun Or 'RUNTHOR' $ Upper (Sys(16, m.lnI)) - Endfor - - WritetoCFULog('Checking for updates to all other apps', .T.) - - Execscript (_Screen.cThorDispatcher, 'Thor_Proc_DownloadAndInstallUpdates', .F., m.llAutoRun) - - Execscript (_Screen.cThorDispatcher, 'Run') - -Endif - -Execscript (_Screen.cThorDispatcher, 'Thor_Tool_ThorInternalThorNews', 'Check For Updates') - -Wait Clear - -Return - - -Procedure EraseFXPFiles (tcFolder) - Local lcFolder, lnCount, lnI, loException - lcFolder = Addbs (m.tcFolder) - lnCount = Adir (laFiles, m.lcFolder + '*.FXP') - For lnI = 1 To m.lnCount - Try - Erase (m.lcFolder + m.laFiles[m.lnI, 1]) - Catch To m.loException - - Endtry - Endfor -Endproc - - -Procedure WritetoCFULog(tcText, tlDivider) - Execscript (_Screen.cThorDispatcher, 'Thor_Proc_WritetoCFULog', m.tcText, m.tlDivider) -Endproc +#Include ..\..\..\Source\Thor.h +Local laFiles[1], lcCFUFolder, lcToolFolder, lcUpdateFolder, llAutoRun, lnFileCount, lnI, lnReturn + +*** DH 2021-12-28: changed URL from VFPXRepository to GitHub +*SF 20231130 Change fixed URL to #DEFINE +*#Define UpdaterURL 'https://raw.githubusercontent.com/VFPX/Thor/master/ThorUpdater/Updates.zip' +#Define UpdaterURL 'https://raw.githubusercontent.com/'+ccThor_URL+ccThor_Branch+'/ThorUpdater/Updates.zip' +*/SF 20231130 Change fixed URL to #DEFINE + +*** DH 2022-01-06: added SET SAFETY OFF to eliminate overwrite prompts +Set Safety Off + +lcCFUFolder = Sys(2023) + '\Thor.CheckForUpdates.' + Left(Ttoc(Datetime(), 1), 8) + '.' + Right(Ttoc(Datetime(), 1), 6) + '\' +Mkdir(m.lcCFUFolder) +_Screen.AddProperty('cThorCFUFolder', m.lcCFUFolder) + +WritetoCFULog('Begin CFU - ' + Transform(Datetime())) + +If Not Execscript (_Screen.cThorDispatcher, 'Thor_Proc_CheckInternetConnection') + Messagebox ('No Internet Connection Found!', 16, 'No Internet Connection', 0) + Return .F. +Endif + +WritetoCFULog('Checking for updates to Thor', .T.) + +If Execscript (_Screen.cThorDispatcher, 'Thor_Proc_DownloadAndInstallUpdates', .T.) >= 0 + + lcToolFolder = Execscript (_Screen.cThorDispatcher, 'Tool Folder=') + WritetoCFULog('Erasing Thor FXP files...') + EraseFXPFiles (m.lcToolFolder) + WritetoCFULog('Erasing Thor FXP files from Thor Procs folder...') + EraseFXPFiles (m.lcToolFolder + 'Procs') + WritetoCFULog('Erasing Thor FXP files from Thor MyTools folder...') + EraseFXPFiles (m.lcToolFolder + 'My Tools') + + lcUpdateFolder = Addbs (m.lcToolFolder) + 'Updates\' + lnFileCount = Adir (laFiles, m.lcUpdateFolder + '*.PRG') + WritetoCFULog('Processing (' + Transform(m.lnFileCount) + ') Thor updater programs...') + + For lnI = 1 To m.lnFileCount + If Not Upper (m.laFiles[m.lnI, 1]) == Upper ('Thor_Update_Thor.PRG') + Erase (m.lcUpdateFolder + m.laFiles[m.lnI, 1]) + Endif + Endfor + *** Download the zip of Updaters, and install them + lnReturn = Execscript (_Screen.cThorDispatcher ; + , 'Thor_Proc_DownloadAndExtractToPath' ; + , UpdaterURL + '?=' + Sys(2015) ; + , m.lcToolFolder ; + , .T. ; + , 'Updates') + + *** Check if called from RunThor, meaning it is from AutoRun + llAutoRun = .F. + For lnI = 1 To Program (-1) + llAutoRun = m.llAutoRun Or 'RUNTHOR' $ Upper (Sys(16, m.lnI)) + Endfor + + WritetoCFULog('Checking for updates to all other apps', .T.) + + Execscript (_Screen.cThorDispatcher, 'Thor_Proc_DownloadAndInstallUpdates', .F., m.llAutoRun) + + Execscript (_Screen.cThorDispatcher, 'Run') + +Endif + +Execscript (_Screen.cThorDispatcher, 'Thor_Tool_ThorInternalThorNews', 'Check For Updates') + +Wait Clear + +Return + + +Procedure EraseFXPFiles (tcFolder) + Local lcFolder, lnCount, lnI, loException + lcFolder = Addbs (m.tcFolder) + lnCount = Adir (laFiles, m.lcFolder + '*.FXP') + For lnI = 1 To m.lnCount + Try + Erase (m.lcFolder + m.laFiles[m.lnI, 1]) + Catch To m.loException + + Endtry + Endfor +Endproc + + +Procedure WritetoCFULog(tcText, tlDivider) + Execscript (_Screen.cThorDispatcher, 'Thor_Proc_WritetoCFULog', m.tcText, m.tlDivider) +Endproc diff --git a/Installed Files/Thor/Tools/Procs/thor_proc_getupdatelist.prg b/Installed Files/Thor/Tools/Procs/thor_proc_getupdatelist.prg index c021631b..de765e19 100644 --- a/Installed Files/Thor/Tools/Procs/thor_proc_getupdatelist.prg +++ b/Installed Files/Thor/Tools/Procs/thor_proc_getupdatelist.prg @@ -22,18 +22,24 @@ Execscript (_Screen.cThorDispatcher, 'Result=', loUpdateList) Return loUpdateList -Procedure AddUpdateFolder (loUpdateList, tlIsThor, lcUpdateFolder, lcNeverUpdateFolder, lcRemovedFolder, lcToolFolder, tcFromMyUpdates) +Procedure AddUpdateFolder (toUpdateList, tlIsThor, tcUpdateFolder, tcNeverUpdateFolder, tcRemovedFolder, tcToolFolder, tcFromMyUpdates) Local laFiles[1], laLocalVersionInfo[1], lcCode, lcFile, lcFolder, lcLocalVersion Local lcLocalVersionFile, lcVersionFileUrl, llSuccess, lnFileCount, lnI, loResult, loTool - lnFileCount = Adir (laFiles, lcUpdateFolder + 'Thor_Update_*.PRG') + lnFileCount = Adir (laFiles, tcUpdateFolder + 'Thor_Update_*.PRG') For lnI = 1 To lnFileCount - lcFile = lcUpdateFolder + laFiles[lnI, 1] + lcFile = tcUpdateFolder + laFiles[lnI, 1] - If File (lcRemovedFolder + laFiles[lnI, 1]) + If File (tcRemovedFolder + laFiles[lnI, 1]) Loop Endif +*SF 20231201 Ignore file in Updates, if identical named file is found in My Updates; #203 + IF tcFromMyUpdates=='No' AND File (tcUpdateFolder + 'My Updates\' + laFiles[lnI, 1]) Then + Loop + ENDIF &&tcFromMyUpdates=='No' AND File (tcUpdateFolder + 'My Updates\' + laFiles[lnI, 1]) +*SF 20231201 Ignore file in Updates, if identical named file is found in My Updates; #203 + loResult = Execscript (_Screen.cThorDispatcher, 'Thor_Proc_GetUpdaterObject2') loResult.File = lcFile loResult.FromMyUpdates = tcFromMyUpdates @@ -52,14 +58,14 @@ Procedure AddUpdateFolder (loUpdateList, tlIsThor, lcUpdateFolder, lcNeverUpdate Do Case Case loResult.InstallInTools - lcFolder = lcToolFolder + lcFolder = tcToolFolder Case Not Isnull (loTool) lcFolder = loTool.FolderName lcFolder = Evl(m.lcFolder, Left(_Screen.cThorFolder, Rat('\', _Screen.cThorFolder, 2))) Case loResult.Component = 'Yes' - lcFolder = Addbs(Addbs (lcToolFolder) + 'Components') + loResult.ApplicationName + lcFolder = Addbs(Addbs (tcToolFolder) + 'Components') + loResult.ApplicationName Otherwise - lcFolder = Addbs(Addbs (lcToolFolder) + 'Apps') + loResult.ApplicationName + lcFolder = Addbs(Addbs (tcToolFolder) + 'Apps') + loResult.ApplicationName Endcase lcLocalVersionFile = Addbs (lcFolder) + loResult.VersionLocalFilename @@ -73,7 +79,7 @@ Procedure AddUpdateFolder (loUpdateList, tlIsThor, lcUpdateFolder, lcNeverUpdate loResult.InstallationFolder = lcFolder loResult.LocalVersionFile = lcLocalVersionFile - loResult.NeverUpdateFile = lcNeverUpdateFolder + laFiles[lnI, 1] + loResult.NeverUpdateFile = tcNeverUpdateFolder + laFiles[lnI, 1] lcVersionFileUrl = loResult.VersionFileURL @@ -111,7 +117,7 @@ Procedure AddUpdateFolder (loUpdateList, tlIsThor, lcUpdateFolder, lcNeverUpdate Endif If loResult.ErrorCode >= 0 - loUpdateList.Add (loResult) + toUpdateList.Add (loResult) Endif Endif Endif diff --git a/Installed Files/Thor/Tools/THOR_TOOL_THORINTERNALFRAMEWORK.PRG b/Installed Files/Thor/Tools/THOR_TOOL_THORINTERNALFRAMEWORK.PRG index f5451941..726133ed 100644 --- a/Installed Files/Thor/Tools/THOR_TOOL_THORINTERNALFRAMEWORK.PRG +++ b/Installed Files/Thor/Tools/THOR_TOOL_THORINTERNALFRAMEWORK.PRG @@ -1,139 +1,144 @@ -#Define ccLF Chr(10) -#Define ccCR Chr(13) -#Define ccTab Chr(9) -#Define ccCRLF ccCR + ccLF - -Lparameters lxParam1 - -**************************************************************** -**************************************************************** -* Standard prefix for all tools for Thor, allowing this tool to -* tell Thor about itself. - -If Pcount() = 1 ; - And 'O' = Vartype (lxParam1) ; - And 'thorinfo' = Lower (lxParam1.Class) - - With lxParam1 - .Prompt = 'Framework' - .AppID = 'Thor' - .Description = 'Framework of tools to assist in creating tools' - .Source = 'Thor' - .Version = 'Thor - 1.45.26 - June 21, 2023' - .Sort = 30 - Endwith - - Return lxParam1 - -Endif - -Do ToolCode - -Return - -**************************************************************** -**************************************************************** -* Normal processing for this tool begins here. - -Procedure ToolCode - Local loFramework As Object - Local laLines[1], lcDisplay, lcFileName, lcHomePage, lcIndent, lcLine, lcThisLine, lcVariable - Local lnCount, lnI, lnPos - - lcIndent = '' && Chr(9) - loFramework = Execscript (_Screen.cThorDispatcher, '?') - -*** DH 2018-04-10: new URL - lcDisplay = '* ' + [Thor - 1.45.26 - June 21, 2023] + chr(13) + chr(10) + chr(13) + chr(10) ; - + '* Thor Framework home page = https://github.com/VFPX/Thor/blob/master/Docs/Thor_tools_making_tools.md' - - If Not Empty (loFramework.External) - lnCount = Alines ( laLines, loFramework.External, 5) - lcDisplay = lcDisplay + chr(13) + chr(10) + chr(13) + chr(10) + + Replicate ('*', 40) + ' External APPs ' + Replicate ('*', 40) - For lnI = 1 To lnCount - lcLine = laLines[lnI] - If '||' $ lcLine - lnPos = At ('||', lcLine) - lcVariable = Left (lcLine, lnPos - 1) + ' = ' - lcLine = Substr (lcLine, lnPos + 2) - Else - lcVariable = '' - Endif - - If '|' $ lcLine - lnPos = At ('|', lcLine) - lcHomePage = Substr (lcLine, lnPos + 1) - lcThisLine = Left (lcLine, lnPos - 1) - lcDisplay = lcDisplay + chr(13) + chr(10) ; - + chr(13) + chr(10) + lcIndent + '* ' + Getwordnum (lcThisLine, 2) + ' home page = ' + lcHomePage ; - + CreateLocalIntellisense (lcVariable, lcThisLine) ; - + chr(13) + chr(10) + lcIndent + lcVariable + 'ExecScript(_Screen.cThorDispatcher, "' + lcThisLine; - + IIF(0 = (Occurs(["], lcThisLine) % 2), '"', '') + ')' - Else - lcDisplay = lcDisplay + chr(13) + chr(10) ; - + CreateLocalIntellisense (lcVariable, lcThisLine) ; - + chr(13) + chr(10) + lcIndent + lcVariable + 'ExecScript(_Screen.cThorDispatcher, "' + lcLine; - + IIF(0 = (Occurs(["], lcLine) % 2), '"', '') + ')' - Endif - Endfor - Endif - - lcDisplay = lcDisplay + chr(13) + chr(10) + chr(13) + chr(10) + Replicate ('*', 40) + '* Internal *' + Replicate ('*', 40) - lnCount = Alines ( laLines, loFramework.Internal, 5) - - For lnI = 1 To lnCount - lcLine = laLines[lnI] - Do Case - Case lcLine = [Empty] - lcDisplay = lcDisplay + chr(13) + chr(10) - Case lcLine = '*' or lcLine = 'Local' - lcDisplay = lcDisplay + chr(13) + chr(10) + lcIndent + lcLine - Otherwise - If '|' $ lcLine - lnPos = At ('|', lcLine) - lcDisplay = lcDisplay + chr(13) + chr(10) + lcIndent ; - + Left (lcLine, lnPos - 1) + ' = ExecScript(_Screen.cThorDispatcher, "' + Substr (lcLine, lnPos + 1) ; - + IIF(0 = (Occurs(["], lcLine) % 2), '"', '') + ')' - Else - lcDisplay = lcDisplay + chr(13) + chr(10) + lcIndent ; - + 'ExecScript(_Screen.cThorDispatcher, "' + lcLine ; - + IIF(0 = (Occurs(["], lcLine) % 2), '"', '') + ')' - Endif - Endcase - Endfor - - lcFileName = Forceext (Addbs (Sys(2023)) + 'ThorFramework', 'prg') - Try - Erase (lcFileName) - Strtofile (lcDisplay, lcFileName, .F.) - Catch - - Endtry - Modify Command (lcFileName) Nowait - -Endproc - - -Procedure CreateLocalIntellisense (lcVariable, lcThisLine) - Local lcClass, lcClassLibrary, lcQuote, lcResult, loObject - - Try - loObject = Execscript (_Screen.cThorDispatcher, lcThisLine) - Catch to loException - loObject = .F. - EndTry - If 'O' # Vartype (loObject) - Return '' - Endif - - lcClass = loObject.Class - lcClassLibrary = loObject.ClassLibrary - If File (lcClassLibrary) - lcQuote = Iif (' ' $ lcClassLibrary, '"', '') - lcResult = chr(13) + chr(10) + 'Local ' + Alltrim (lcVariable, 1, ' ', '=' ) + ' as ' + lcClass + ' of ' + lcQuote + lcClassLibrary + lcQuote - Return lcResult - Else - Return '' - Endif - -Endproc +#Include ..\..\Source\Thor.h +*#Define ccLF Chr(10) +*#Define ccCR Chr(13) +*#Define ccTab Chr(9) +#Define ccCRLF ccCR + ccLF + +Lparameters lxParam1 + +**************************************************************** +**************************************************************** +* Standard prefix for all tools for Thor, allowing this tool to +* tell Thor about itself. + +If Pcount() = 1 ; + And 'O' = Vartype (lxParam1) ; + And 'thorinfo' = Lower (lxParam1.Class) + + With lxParam1 + .Prompt = 'Framework' + .AppID = 'Thor' + .Description = 'Framework of tools to assist in creating tools' + .Source = 'Thor' + .Version = 'Thor - 1.45.26 - June 21, 2023' + .Sort = 30 + Endwith + + Return lxParam1 + +Endif + +Do ToolCode + +Return + +**************************************************************** +**************************************************************** +* Normal processing for this tool begins here. + +Procedure ToolCode + Local loFramework As Object + Local laLines[1], lcDisplay, lcFileName, lcHomePage, lcIndent, lcLine, lcThisLine, lcVariable + Local lnCount, lnI, lnPos + + lcIndent = '' && Chr(9) + loFramework = Execscript (_Screen.cThorDispatcher, '?') + +*** DH 2018-04-10: new URL +*SF 20231130 Change fixed URL to #DEFINE +* lcDisplay = '* ' + [Thor - 1.45.26 - June 21, 2023] + chr(13) + chr(10) + chr(13) + chr(10) ; +* + '* Thor Framework home page = https://github.com/VFPX/Thor/blob/master/Docs/Thor_tools_making_tools.md' + lcDisplay = '* ' + [Thor - 1.45.26 - June 21, 2023] + chr(13) + chr(10) + chr(13) + chr(10) ; + + '* Thor Framework home page = https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/Thor_tools_making_tools.md' +*/SF 20231130 Change fixed URL to #DEFINE + + If Not Empty (loFramework.External) + lnCount = Alines ( laLines, loFramework.External, 5) + lcDisplay = lcDisplay + chr(13) + chr(10) + chr(13) + chr(10) + + Replicate ('*', 40) + ' External APPs ' + Replicate ('*', 40) + For lnI = 1 To lnCount + lcLine = laLines[lnI] + If '||' $ lcLine + lnPos = At ('||', lcLine) + lcVariable = Left (lcLine, lnPos - 1) + ' = ' + lcLine = Substr (lcLine, lnPos + 2) + Else + lcVariable = '' + Endif + + If '|' $ lcLine + lnPos = At ('|', lcLine) + lcHomePage = Substr (lcLine, lnPos + 1) + lcThisLine = Left (lcLine, lnPos - 1) + lcDisplay = lcDisplay + chr(13) + chr(10) ; + + chr(13) + chr(10) + lcIndent + '* ' + Getwordnum (lcThisLine, 2) + ' home page = ' + lcHomePage ; + + CreateLocalIntellisense (lcVariable, lcThisLine) ; + + chr(13) + chr(10) + lcIndent + lcVariable + 'ExecScript(_Screen.cThorDispatcher, "' + lcThisLine; + + IIF(0 = (Occurs(["], lcThisLine) % 2), '"', '') + ')' + Else + lcDisplay = lcDisplay + chr(13) + chr(10) ; + + CreateLocalIntellisense (lcVariable, lcThisLine) ; + + chr(13) + chr(10) + lcIndent + lcVariable + 'ExecScript(_Screen.cThorDispatcher, "' + lcLine; + + IIF(0 = (Occurs(["], lcLine) % 2), '"', '') + ')' + Endif + Endfor + Endif + + lcDisplay = lcDisplay + chr(13) + chr(10) + chr(13) + chr(10) + Replicate ('*', 40) + '* Internal *' + Replicate ('*', 40) + lnCount = Alines ( laLines, loFramework.Internal, 5) + + For lnI = 1 To lnCount + lcLine = laLines[lnI] + Do Case + Case lcLine = [Empty] + lcDisplay = lcDisplay + chr(13) + chr(10) + Case lcLine = '*' or lcLine = 'Local' + lcDisplay = lcDisplay + chr(13) + chr(10) + lcIndent + lcLine + Otherwise + If '|' $ lcLine + lnPos = At ('|', lcLine) + lcDisplay = lcDisplay + chr(13) + chr(10) + lcIndent ; + + Left (lcLine, lnPos - 1) + ' = ExecScript(_Screen.cThorDispatcher, "' + Substr (lcLine, lnPos + 1) ; + + IIF(0 = (Occurs(["], lcLine) % 2), '"', '') + ')' + Else + lcDisplay = lcDisplay + chr(13) + chr(10) + lcIndent ; + + 'ExecScript(_Screen.cThorDispatcher, "' + lcLine ; + + IIF(0 = (Occurs(["], lcLine) % 2), '"', '') + ')' + Endif + Endcase + Endfor + + lcFileName = Forceext (Addbs (Sys(2023)) + 'ThorFramework', 'prg') + Try + Erase (lcFileName) + Strtofile (lcDisplay, lcFileName, .F.) + Catch + + Endtry + Modify Command (lcFileName) Nowait + +Endproc + + +Procedure CreateLocalIntellisense (lcVariable, lcThisLine) + Local lcClass, lcClassLibrary, lcQuote, lcResult, loObject + + Try + loObject = Execscript (_Screen.cThorDispatcher, lcThisLine) + Catch to loException + loObject = .F. + EndTry + If 'O' # Vartype (loObject) + Return '' + Endif + + lcClass = loObject.Class + lcClassLibrary = loObject.ClassLibrary + If File (lcClassLibrary) + lcQuote = Iif (' ' $ lcClassLibrary, '"', '') + lcResult = chr(13) + chr(10) + 'Local ' + Alltrim (lcVariable, 1, ' ', '=' ) + ' as ' + lcClass + ' of ' + lcQuote + lcClassLibrary + lcQuote + Return lcResult + Else + Return '' + Endif + +Endproc diff --git a/Installed Files/Thor/Tools/THOR_TOOL_THORINTERNALTWEETS.PRG b/Installed Files/Thor/Tools/THOR_TOOL_THORINTERNALTWEETS.PRG index 5604c378..ec46badf 100644 --- a/Installed Files/Thor/Tools/THOR_TOOL_THORINTERNALTWEETS.PRG +++ b/Installed Files/Thor/Tools/THOR_TOOL_THORINTERNALTWEETS.PRG @@ -1,63 +1,67 @@ -#Define ccCR Chr[13] - -Lparameters lxParam1 - -**************************************************************** -**************************************************************** -* Standard prefix for all tools for Thor, allowing this tool to -* tell Thor about itself. - -If Pcount() = 1 ; - And 'O' = Vartype (lxParam1) ; - And 'thorinfo' == Lower (lxParam1.Class) - - With lxParam1 - - * Required - .Prompt = 'Thor TWEeTs' && used in menus - .AppID = 'Thor' - - * Optional - .Description = 'Home page for Thor TWEeTs' - .StatusBarText = '' - - * These are used to group and sort tools when they are displayed in menus or the Thor form - .Category = 'Thor' && creates categorization of tools; defaults to .Source if empty - - * For public tools, such as PEM Editor, etc. - .Author = 'Jim Nelson' - - Endwith - - Return lxParam1 -Endif - -If Pcount() = 0 - Do ToolCode -Else - Do ToolCode With lxParam1 -Endif - -Return - - - -**************************************************************** -**************************************************************** -* Normal processing for this tool begins here. -Procedure ToolCode - Lparameters lxParam1 - - If Not Execscript (_Screen.cThorDispatcher, 'Thor_Proc_CheckInternetConnection') - If 'L' = Vartype (lxParam1) - Messagebox ('No Internet Connection Found!', 16, 'No Internet Connection', 0) - Return .F. - Endif - Endif - - Execscript (_Screen.cThorDispatcher, 'Thor_Proc_Shell', 'https://github.com/VFPX/Thor/blob/master/Docs/TWEeTs.md') - - -Endproc - - +#Include ..\..\Source\Thor.h +*#Define ccCR Chr[13] + +Lparameters lxParam1 + +**************************************************************** +**************************************************************** +* Standard prefix for all tools for Thor, allowing this tool to +* tell Thor about itself. + +If Pcount() = 1 ; + And 'O' = Vartype (lxParam1) ; + And 'thorinfo' == Lower (lxParam1.Class) + + With lxParam1 + + * Required + .Prompt = 'Thor TWEeTs' && used in menus + .AppID = 'Thor' + + * Optional + .Description = 'Home page for Thor TWEeTs' + .StatusBarText = '' + + * These are used to group and sort tools when they are displayed in menus or the Thor form + .Category = 'Thor' && creates categorization of tools; defaults to .Source if empty + + * For public tools, such as PEM Editor, etc. + .Author = 'Jim Nelson' + + Endwith + + Return lxParam1 +Endif + +If Pcount() = 0 + Do ToolCode +Else + Do ToolCode With lxParam1 +Endif + +Return + + + +**************************************************************** +**************************************************************** +* Normal processing for this tool begins here. +Procedure ToolCode + Lparameters lxParam1 + + If Not Execscript (_Screen.cThorDispatcher, 'Thor_Proc_CheckInternetConnection') + If 'L' = Vartype (lxParam1) + Messagebox ('No Internet Connection Found!', 16, 'No Internet Connection', 0) + Return .F. + Endif + Endif + +*SF 20231130 Change fixed URL to #DEFINE +* Execscript (_Screen.cThorDispatcher, 'Thor_Proc_Shell', 'https://github.com/VFPX/Thor/blob/master/Docs/TWEeTs.md') + Execscript (_Screen.cThorDispatcher, 'Thor_Proc_Shell', 'https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/TWEeTs.md') +*/SF 20231130 Change fixed URL to #DEFINE + + +Endproc + + diff --git a/Installed Files/Thor/Tools/THOR_TOOL_ThorChangeLog.prg b/Installed Files/Thor/Tools/THOR_TOOL_ThorChangeLog.prg index a5152485..81b0ffe6 100644 --- a/Installed Files/Thor/Tools/THOR_TOOL_ThorChangeLog.prg +++ b/Installed Files/Thor/Tools/THOR_TOOL_ThorChangeLog.prg @@ -1,3 +1,4 @@ +#Include ..\..\Source\Thor.h Lparameters lxParam1 **************************************************************** @@ -30,7 +31,10 @@ Return Procedure ToolCode Local lcURL, loThorUtils - lcURL = 'https://github.com/VFPX/Thor/blob/master/Change%20Log.md' +*SF 20231130 Change fixed URL to #DEFINE +* lcURL = 'https://github.com/VFPX/Thor/blob/master/Change%20Log.md' + lcURL = 'https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Change%20Log.md' +*/SF 20231130 Change fixed URL to #DEFINE loThorUtils = Execscript(_Screen.cThorDispatcher, 'thor_proc_utils') m.loThorUtils.GoURL(m.lcURL) diff --git a/Installed Files/Thor/Tools/Thor_Tool_ThorInternalFrameworkHelp.PRG b/Installed Files/Thor/Tools/Thor_Tool_ThorInternalFrameworkHelp.PRG index db1654bb..038191eb 100644 --- a/Installed Files/Thor/Tools/Thor_Tool_ThorInternalFrameworkHelp.PRG +++ b/Installed Files/Thor/Tools/Thor_Tool_ThorInternalFrameworkHelp.PRG @@ -1,34 +1,38 @@ -Lparameters lxParam1 - -**************************************************************** -**************************************************************** -* Standard prefix for all tools for Thor, allowing this tool to -* tell Thor about itself. - -If Pcount() = 1 ; - And 'O' = Vartype (lxParam1) ; - And 'thorinfo' = Lower (lxParam1.Class) - - With lxParam1 - .Prompt = 'Help for Thor Framework' - .AppID = 'Thor' - .Description = 'Follows link to Thor Home Page' - .Source = 'Thor' - .Version = 'Thor - 1.45.26 - June 21, 2023' - .Sort = 20 - .Link = 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_help.md' - Endwith - - Return lxParam1 -Endif - -Do ToolCode - -Return - -**************************************************************** -**************************************************************** -* Normal processing for this tool begins here. -Procedure ToolCode - Do _Screen.cThorFolder + '..\Thor.APP' with 'Help' -EndProc +#Include ..\..\Source\Thor.h +Lparameters lxParam1 + +**************************************************************** +**************************************************************** +* Standard prefix for all tools for Thor, allowing this tool to +* tell Thor about itself. + +If Pcount() = 1 ; + And 'O' = Vartype (lxParam1) ; + And 'thorinfo' = Lower (lxParam1.Class) + + With lxParam1 + .Prompt = 'Help for Thor Framework' + .AppID = 'Thor' + .Description = 'Follows link to Thor Home Page' + .Source = 'Thor' + .Version = 'Thor - 1.45.26 - June 21, 2023' + .Sort = 20 +*SF 20231130 Change fixed URL to #DEFINE +* .Link = 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_help.md' + .Link = 'https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/Thor_help.md' +*/SF 20231130 Change fixed URL to #DEFINE + Endwith + + Return lxParam1 +Endif + +Do ToolCode + +Return + +**************************************************************** +**************************************************************** +* Normal processing for this tool begins here. +Procedure ToolCode + Do _Screen.cThorFolder + '..\Thor.APP' with 'Help' +EndProc diff --git a/Installed Files/Thor/Tools/Thor_Tool_ThorInternalHelp.PRG b/Installed Files/Thor/Tools/Thor_Tool_ThorInternalHelp.PRG index 7b7df10e..2a4aac08 100644 --- a/Installed Files/Thor/Tools/Thor_Tool_ThorInternalHelp.PRG +++ b/Installed Files/Thor/Tools/Thor_Tool_ThorInternalHelp.PRG @@ -1,33 +1,37 @@ -Lparameters lxParam1 - -**************************************************************** -**************************************************************** -* Standard prefix for all tools for Thor, allowing this tool to -* tell Thor about itself. - -If Pcount() = 1 ; - And 'O' = Vartype (lxParam1) ; - And 'thorinfo' = Lower (lxParam1.Class) - - With lxParam1 - .Prompt = 'Help for Thor' - .AppID = 'Thor' - .Description = 'Follows link to Thor Home Page' - .Source = 'Thor' - .Version = 'Thor - 1.45.26 - June 21, 2023' - .Sort = 20 - .Link = 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_help.md' - Endwith - - Return lxParam1 -Endif - -Do ToolCode - -Return - -**************************************************************** -**************************************************************** -* Normal processing for this tool begins here. -Procedure ToolCode +#Include ..\..\Source\Thor.h +Lparameters lxParam1 + +**************************************************************** +**************************************************************** +* Standard prefix for all tools for Thor, allowing this tool to +* tell Thor about itself. + +If Pcount() = 1 ; + And 'O' = Vartype (lxParam1) ; + And 'thorinfo' = Lower (lxParam1.Class) + + With lxParam1 + .Prompt = 'Help for Thor' + .AppID = 'Thor' + .Description = 'Follows link to Thor Home Page' + .Source = 'Thor' + .Version = 'Thor - 1.45.26 - June 21, 2023' + .Sort = 20 +*SF 20231130 Change fixed URL to #DEFINE +* .Link = 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_help.md' + .Link = 'https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/Thor_help.md' +*/SF 20231130 Change fixed URL to #DEFINE + Endwith + + Return lxParam1 +Endif + +Do ToolCode + +Return + +**************************************************************** +**************************************************************** +* Normal processing for this tool begins here. +Procedure ToolCode ExecScript(_Screen.cThorDispatcher, 'Thor_Proc_Shell', 'http://vfpx.org') \ No newline at end of file diff --git a/Installed Files/Thor/Tools/Thor_Tool_ThorInternalRepositoryHomePage.PRG b/Installed Files/Thor/Tools/Thor_Tool_ThorInternalRepositoryHomePage.PRG index 5e7407d2..a2e0cb0e 100644 --- a/Installed Files/Thor/Tools/Thor_Tool_ThorInternalRepositoryHomePage.PRG +++ b/Installed Files/Thor/Tools/Thor_Tool_ThorInternalRepositoryHomePage.PRG @@ -1,38 +1,48 @@ -#Define ThorFrameworkURL 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_repository.md' - -Lparameters lxParam1 - -**************************************************************** -**************************************************************** -* Standard prefix for all tools for Thor, allowing this tool to -* tell Thor about itself. - -If Pcount() = 1 ; - And 'O' = Vartype (lxParam1) ; - And 'thorinfo' = Lower (lxParam1.Class) - - With lxParam1 - .Prompt = 'Link to Thor Repository' - .AppID = 'Thor' - .Description = 'Link to Home Page for Thor Repository' - .Source = 'Thor' - .Version = 'Thor - 1.45.26 - June 21, 2023' - .Sort = 20 - .Link = 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_repository.md' - Endwith - - Return lxParam1 -Endif - -Do ToolCode - -Return - -**************************************************************** -**************************************************************** -* Normal processing for this tool begins here. -Procedure ToolCode - Local loLink - loLink = Newobject ('_ShellExecute', Home() + 'FFC\_Environ.vcx') - loLink.ShellExecute ('https://github.com/VFPX/Thor/blob/master/Docs/Thor_repository.md') -EndProc +#Include ..\..\Source\Thor.h +*SF 20231130 Change fixed URL to #DEFINE +*#Define ThorFrameworkURL 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_repository.md' +#Define ThorFrameworkURL 'https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/Thor_repository.md' +*/SF 20231130 Change fixed URL to #DEFINE + +Lparameters lxParam1 + +**************************************************************** +**************************************************************** +* Standard prefix for all tools for Thor, allowing this tool to +* tell Thor about itself. + +If Pcount() = 1 ; + And 'O' = Vartype (lxParam1) ; + And 'thorinfo' = Lower (lxParam1.Class) + + With lxParam1 + .Prompt = 'Link to Thor Repository' + .AppID = 'Thor' + .Description = 'Link to Home Page for Thor Repository' + .Source = 'Thor' + .Version = 'Thor - 1.45.26 - June 21, 2023' + .Sort = 20 +*SF 20231130 Change fixed URL to #DEFINE +* .Link = 'https://github.com/VFPX/Thor/blob/master/Docs/Thor_repository.md' + .Link = 'https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/Thor_repository.md' +*/SF 20231130 Change fixed URL to #DEFINE + Endwith + + Return lxParam1 +Endif + +Do ToolCode + +Return + +**************************************************************** +**************************************************************** +* Normal processing for this tool begins here. +Procedure ToolCode + Local loLink + loLink = Newobject ('_ShellExecute', Home() + 'FFC\_Environ.vcx') +*SF 20231130 Change fixed URL to #DEFINE +* loLink.ShellExecute ('https://github.com/VFPX/Thor/blob/master/Docs/Thor_repository.md') + loLink.ShellExecute ('https://github.com/'+ccThor_URL+'/blob'+ccThor_Branch+'/Docs/Thor_repository.md') +*/SF 20231130 Change fixed URL to #DEFINE +EndProc diff --git a/Thor_Help.PJT b/Thor_Help.PJT new file mode 100644 index 00000000..0a4a5d57 Binary files /dev/null and b/Thor_Help.PJT differ diff --git a/Thor_Help.pj2 b/Thor_Help.pj2 new file mode 100644 index 00000000..f69e5764 --- /dev/null +++ b/Thor_Help.pj2 @@ -0,0 +1,125 @@ +*-------------------------------------------------------------------------------------------------------------------------------------------------------- +* (EN) AUTOGENERATED - ATTENTION!! - NOT INTENDED FOR EXECUTION!! USE ONLY FOR MERGING CHANGES AND STORING WITH SCM TOOLS!! +*-------------------------------------------------------------------------------------------------------------------------------------------------------- +*< FOXBIN2PRG: Version="1.21" SourceFile="thor_help.pjx" CPID="1252" /> (Solo para binarios VFP 9 / Only for VFP 9 binaries) +* +LPARAMETERS tcDir + +lcCurdir = SYS(5)+CURDIR() +CD ( EVL( tcDir, JUSTPATH( SYS(16) ) ) ) + +* +_Author = "" +_Company = "" +_Address = "" +_City = "" +_State = "" +_PostalCode = "" +_Country = "" +*-- +_Comments = "" +_CompanyName = "" +_FileDescription = "" +_LegalCopyright = "" +_LegalTrademark = "" +_ProductName = "" +_MajorVer = "" +_MinorVer = "" +_Revision = "" +_LanguageID = "" +_AutoIncrement = "0" +* + + +* +*<.HomeDir = 'e:\se\vfpx\data\default' /> + +FOR EACH loProject IN _VFP.Projects FOXOBJECT + loProject.Close() +ENDFOR + +STRTOFILE( '', '__newproject.f2b' ) +BUILD PROJECT Thor_Help.pjx FROM '__newproject.f2b' +FOR EACH loProject IN _VFP.Projects FOXOBJECT + loProject.Close() +ENDFOR + +MODIFY PROJECT 'Thor_Help.pjx' NOWAIT NOSHOW NOPROJECTHOOK + +loProject = _VFP.Projects('Thor_Help.pjx') + +WITH loProject.FILES + .ADD('installed files\source\procs_for_thor\thor_proc_check_for_updates.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\source\thor.h') && *< FileMetadata: Type="T" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\source\thor_english.h') && *< FileMetadata: Type="T" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\source\thor_run.vcx') && *< FileMetadata: Type="V" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\source\thor_ui.h') && *< FileMetadata: Type="T" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\source\thor_update_thor_repository_beta.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\source\thorformruntool.scx') && *< FileMetadata: Type="K" Cpid="0" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\source\thorversion.h') && *< FileMetadata: Type="T" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\thor\tools\procs\thor_proc_check_for_updates.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\thor\tools\thor_tool_thorchangelog.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\thor\tools\thor_tool_thorinternalframework.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\thor\tools\thor_tool_thorinternalframeworkhelp.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\thor\tools\thor_tool_thorinternalhelp.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\thor\tools\thor_tool_thorinternalrepositoryhomepage.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('installed files\thor\tools\thor_tool_thorinternaltweets.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('thor_help.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('updaters\updates\old_thor_update_thor_repository.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('updaters\updates\thor_update_thor.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + .ADD('updaters\updates\thor_update_thorrepository.prg') && *< FileMetadata: Type="P" Cpid="1252" Timestamp="0" ID="0" ObjRev="0" User="" /> + * + + .ITEM('__newproject.f2b').Remove() + + * + * + + * + .ITEM(lcCurdir + 'installed files\source\procs_for_thor\thor_proc_check_for_updates.prg').Exclude = .T. + .ITEM(lcCurdir + 'installed files\source\thor.h').Exclude = .T. + .ITEM(lcCurdir + 'installed files\source\thor_english.h').Exclude = .T. + .ITEM(lcCurdir + 'installed files\source\thor_run.vcx').Exclude = .T. + .ITEM(lcCurdir + 'installed files\source\thor_ui.h').Exclude = .T. + .ITEM(lcCurdir + 'installed files\source\thor_update_thor_repository_beta.prg').Exclude = .T. + .ITEM(lcCurdir + 'installed files\source\thorformruntool.scx').Exclude = .T. + .ITEM(lcCurdir + 'installed files\source\thorversion.h').Exclude = .T. + .ITEM(lcCurdir + 'installed files\thor\tools\procs\thor_proc_check_for_updates.prg').Exclude = .T. + .ITEM(lcCurdir + 'installed files\thor\tools\thor_tool_thorchangelog.prg').Exclude = .T. + .ITEM(lcCurdir + 'installed files\thor\tools\thor_tool_thorinternalframework.prg').Exclude = .T. + .ITEM(lcCurdir + 'installed files\thor\tools\thor_tool_thorinternalframeworkhelp.prg').Exclude = .T. + .ITEM(lcCurdir + 'installed files\thor\tools\thor_tool_thorinternalhelp.prg').Exclude = .T. + .ITEM(lcCurdir + 'installed files\thor\tools\thor_tool_thorinternalrepositoryhomepage.prg').Exclude = .T. + .ITEM(lcCurdir + 'installed files\thor\tools\thor_tool_thorinternaltweets.prg').Exclude = .T. + .ITEM(lcCurdir + 'updaters\updates\thor_update_thor.prg').Exclude = .T. + .ITEM(lcCurdir + 'updaters\updates\thor_update_thorrepository.prg').Exclude = .T. + * + + * + .ITEM(lcCurdir + 'installed files\source\thor.h').Type = 'T' + .ITEM(lcCurdir + 'installed files\source\thor_english.h').Type = 'T' + .ITEM(lcCurdir + 'installed files\source\thor_ui.h').Type = 'T' + .ITEM(lcCurdir + 'installed files\source\thorversion.h').Type = 'T' + * +ENDWITH + +WITH loProject + * + .SetMain(lcCurdir + 'thor_help.prg') + + .Debug = .T. + .Encrypted = .F. + *<.CmntStyle = 1 /> + *<.NoLogo = .F. /> + *<.SaveCode = .T. /> + *<.User = '' /> + .ProjectHookLibrary = '' + .ProjectHookClass = '' + * +ENDWITH + + +_VFP.Projects('Thor_Help.pjx').Close() +*ERASE '__newproject.f2b' +CD (lcCurdir) +RETURN \ No newline at end of file diff --git a/Thor_Help.pjx b/Thor_Help.pjx new file mode 100644 index 00000000..b50e78ca Binary files /dev/null and b/Thor_Help.pjx differ diff --git a/Thor_Help.prg b/Thor_Help.prg new file mode 100644 index 00000000..d7647fdd --- /dev/null +++ b/Thor_Help.prg @@ -0,0 +1,2 @@ +MESSAGEBOX("This is not intended to run, just to compile.") +RETURN .F. diff --git a/Updaters/Updates/Thor_Update_Thor.PRG b/Updaters/Updates/Thor_Update_Thor.PRG index 62c653b8..c4b27346 100644 --- a/Updaters/Updates/Thor_Update_Thor.PRG +++ b/Updaters/Updates/Thor_Update_Thor.PRG @@ -1,17 +1,27 @@ -Lparameters loUpdateObject - -With loUpdateObject - .AppName = 'Thor.App' - .ApplicationName = 'Thor' - .ToolName = 'Thor_Tool_ThorInternalEdit' - .VersionFileURL = 'https://raw.githubusercontent.com/VFPX/Thor/master/ThorUpdater/_ThorVersionFile.txt' - .VersionLocalFilename = 'Thor\ThorVersion.txt' - .RegisterWithThor = 'Do "##InstallFolder##Thor.APP" with "Install"' - .SourceFileURL = 'Thor_Source.Zip = https://raw.githubusercontent.com/VFPX/Thor/master/ThorUpdater/Thor.zip' - .Link = 'https://github.com/VFPX/Thor' - .LinkPrompt = 'Thor Home Page' -Endwith - -AddProperty(loUpdateObject, 'UnzipAfterDownload', 'Yes') - -Return loUpdateObject +#Define ccThor_URL 'VFPX/Thor' +#Define ccThor_Branch '/master' + +Lparameters loUpdateObject + +With loUpdateObject + .AppName = 'Thor.App' + .ApplicationName = 'Thor' + .ToolName = 'Thor_Tool_ThorInternalEdit' +*SF 20231130 Change fixed URL to #DEFINE +* .VersionFileURL = 'https://raw.githubusercontent.com/VFPX/Thor/master/ThorUpdater/_ThorVersionFile.txt' + .VersionFileURL = 'https://raw.githubusercontent.com/'+ccThor_URL+ccThor_Branch+'/ThorUpdater/_ThorVersionFile.txt' +*/SF 20231130 Change fixed URL to #DEFINE + .VersionLocalFilename = 'Thor\ThorVersion.txt' + .RegisterWithThor = 'Do "##InstallFolder##Thor.APP" with "Install"' +*SF 20231130 Change fixed URL to #DEFINE +* .SourceFileURL = 'Thor_Source.Zip = https://raw.githubusercontent.com/VFPX/Thor/master/ThorUpdater/Thor.zip' +* .Link = 'https://github.com/VFPX/Thor' + .SourceFileURL = 'Thor_Source.Zip = https://raw.githubusercontent.com/'+ccThor_URL+ccThor_Branch+'/ThorUpdater/Thor.zip' + .Link = 'https://github.com/'+ccThor_URL +*/SF 20231130 Change fixed URL to #DEFINE + .LinkPrompt = 'Thor Home Page' +Endwith + +AddProperty(loUpdateObject, 'UnzipAfterDownload', 'Yes') + +Return loUpdateObject diff --git a/Updaters/Updates/old_thor_update_thor_repository.prg b/Updaters/Updates/old_thor_update_thor_repository.prg index 71f9f2f7..8487974b 100644 --- a/Updaters/Updates/old_thor_update_thor_repository.prg +++ b/Updaters/Updates/old_thor_update_thor_repository.prg @@ -1,76 +1,83 @@ -#Define VersionFileName 'ThorRepositoryVersionFile.txt' -Lparameters loUpdateObject - -Text to lcRegisterWithThor NoShow TextMerge - *Remove some old, no longer suppported tools - Local loThor - - * Main Thor Engine - Try - loThor = Execscript (_Screen.cThorDispatcher, 'Thor Engine=') - loThor.RemoveTool ('Thor_Tool_Repository_SetRevisionDate') - loThor.RemoveTool ('Thor_Tool_Repository_Sample_ModifySelectedText') - loThor.RemoveTool ('Thor_Tool_PEME_OpenProject') - Catch - EndTry - - Erase (_screen.Cthorfolder + '\Tools\Procs\beautify.h') - Erase (_screen.Cthorfolder + '\Tools\Procs\beautifyx.h') - Erase (_screen.Cthorfolder + '\Tools\Procs\THOR_PROC_ISX.h') - -EndText - -With loUpdateObject - .ApplicationName = 'ThorRepository' - .ToolName = 'Thor_Tool_ThorInternalRepository' - .VersionLocalFilename = VersionFileName - .RegisterWithThor = lcRegisterWithThor - .Notes = GetNotes() - .Link = 'https://github.com/VFPX/ThorRepository' - .LinkPrompt = 'Thor Repository Home Page' - - .VersionNumber = '62.06' - .VersionDate = Date(2022, 04, 01) - .SourceFileUrl = 'https://raw.githubusercontent.com/VFPX/ThorRepository/master/Source/Thor_Repository.zip' -Endwith - -AddProperty(loUpdateObject, 'UpdateNowIfNotInstalled', 'Yes') - -Return loUpdateObject - - -Procedure GetNotes - - Local lcNotes - Text to lcNotes NoShow -The Thor Repository is a collection of IDE tools, accessible thru Thor, -that have been written by members of the FoxPro community. - -You are encouraged to modify and enhance these tools and also to create -your own tools using these tools as samples. - -To edit an existing tool, find it in Thor’s configuration form and click -‘Edit Tool’. This will create a copy of the tool for you in your ‘My Tools’ -folder. Thereafter, it will be accessible to you thru the MRU list for PRGs. - -If you have created a new tool that you think would be of interest to the -FoxPro community, or have made enhancements or corrections to existing tools, -please submit them to be shared with the rest of the VFP community. - -Tools can be submitted to this address (the community form for Thor -and the Thor Repository): FoxProThor@googlegroups.com - -Tools will be accepted into the Repository if they meet some minimum -standards, which include: - - They must act as designed and described. - They must have no undesirable side effects. - They must not make assumptions about file locations (such as folder names, - other than system folders) - They must follow the standard Thor-Tool format for a PRG, and their - description must be as complete as possible. - - -EndText - Return lcNotes -EndProc +#Include "..\..\Installed Files\Source\Thor.h" +#Define VersionFileName 'ThorRepositoryVersionFile.txt' +Lparameters loUpdateObject + +Text to lcRegisterWithThor NoShow TextMerge + *Remove some old, no longer suppported tools + Local loThor + + * Main Thor Engine + Try + loThor = Execscript (_Screen.cThorDispatcher, 'Thor Engine=') + loThor.RemoveTool ('Thor_Tool_Repository_SetRevisionDate') + loThor.RemoveTool ('Thor_Tool_Repository_Sample_ModifySelectedText') + loThor.RemoveTool ('Thor_Tool_PEME_OpenProject') + Catch + EndTry + + Erase (_screen.Cthorfolder + '\Tools\Procs\beautify.h') + Erase (_screen.Cthorfolder + '\Tools\Procs\beautifyx.h') + Erase (_screen.Cthorfolder + '\Tools\Procs\THOR_PROC_ISX.h') + +EndText + +With loUpdateObject + .ApplicationName = 'ThorRepository' + .ToolName = 'Thor_Tool_ThorInternalRepository' + .VersionLocalFilename = VersionFileName + .RegisterWithThor = lcRegisterWithThor + .Notes = GetNotes() +*SF 20231130 Change fixed URL to #DEFINE +* .Link = 'https://github.com/VFPX/ThorRepository' + .Link = 'https://github.com/'+ccThorRepository_URL +*/SF 20231130 Change fixed URL to #DEFINE + .LinkPrompt = 'Thor Repository Home Page' + + .VersionNumber = '62.06' + .VersionDate = Date(2022, 04, 01) +*SF 20231130 Change fixed URL to #DEFINE +* .SourceFileUrl = 'https://raw.githubusercontent.com/VFPX/ThorRepository/master/Source/Thor_Repository.zip' + .SourceFileUrl = 'https://raw.githubusercontent.com/'+ccThorRepository_URL+ccThorRepository_Branch+'/Source/Thor_Repository.zip' +*/SF 20231130 Change fixed URL to #DEFINE +Endwith + +AddProperty(loUpdateObject, 'UpdateNowIfNotInstalled', 'Yes') + +Return loUpdateObject + + +Procedure GetNotes + + Local lcNotes + Text to lcNotes NoShow +The Thor Repository is a collection of IDE tools, accessible thru Thor, +that have been written by members of the FoxPro community. + +You are encouraged to modify and enhance these tools and also to create +your own tools using these tools as samples. + +To edit an existing tool, find it in Thor’s configuration form and click +‘Edit Tool’. This will create a copy of the tool for you in your ‘My Tools’ +folder. Thereafter, it will be accessible to you thru the MRU list for PRGs. + +If you have created a new tool that you think would be of interest to the +FoxPro community, or have made enhancements or corrections to existing tools, +please submit them to be shared with the rest of the VFP community. + +Tools can be submitted to this address (the community form for Thor +and the Thor Repository): FoxProThor@googlegroups.com + +Tools will be accepted into the Repository if they meet some minimum +standards, which include: + + They must act as designed and described. + They must have no undesirable side effects. + They must not make assumptions about file locations (such as folder names, + other than system folders) + They must follow the standard Thor-Tool format for a PRG, and their + description must be as complete as possible. + + +EndText + Return lcNotes +EndProc diff --git a/Updaters/Updates/thor_update_thorrepository.prg b/Updaters/Updates/thor_update_thorrepository.prg index 863df18c..8c792a40 100644 --- a/Updaters/Updates/thor_update_thorrepository.prg +++ b/Updaters/Updates/thor_update_thorrepository.prg @@ -1,30 +1,40 @@ -lparameters toUpdateObject -local lcRepositoryURL, ; - lcDownloadsURL, ; - lcVersionFileURL, ; - lcZIPFileURL, ; - lcRegisterWithThor - -* Get the URL for the version and ZIP files. - -lcRepositoryURL = 'https://github.com/VFPX/ThorRepository' - && the URL for the project's repository -lcDownloadsURL = strtran(lcRepositoryURL, 'github.com', ; - 'raw.githubusercontent.com') + '/master/ThorUpdater/' -lcVersionFileURL = lcDownloadsURL + 'ThorRepositoryVersion.txt' - && the URL for the file containing code to get the available version number -lcZIPFileURL = lcDownloadsURL + 'ThorRepository.zip' - && the URL for the zip file containing the project - -* Set the properties of the passed updater object. - -with toUpdateObject - .ApplicationName = 'Thor Repository' - .VersionLocalFilename = 'ThorRepositoryVersionFile.txt' - .VersionFileURL = lcVersionFileURL - .SourceFileUrl = lcZIPFileURL - .Link = lcRepositoryURL - .LinkPrompt = 'Thor Repository Home Page' - .InstallInTools = .T. -endwith -return toUpdateObject +#Define ccThorRepository_URL 'VFPX/ThorRepository' +#Define ccThorRepository_Branch '/master' + +lparameters toUpdateObject +local lcRepositoryURL, ; + lcDownloadsURL, ; + lcVersionFileURL, ; + lcZIPFileURL, ; + lcRegisterWithThor + +* Get the URL for the version and ZIP files. + +*SF 20231130 Change fixed URL to #DEFINE +*lcRepositoryURL = 'https://github.com/VFPX/ThorRepository' + && the URL for the project's repository +*lcDownloadsURL = strtran(lcRepositoryURL, 'github.com', ; + 'raw.githubusercontent.com') + '/master/ThorUpdater/' +lcRepositoryURL = 'https://github.com/'+ccThorRepository_URL + && the URL for the project's repository +lcDownloadsURL = strtran(lcRepositoryURL, 'github.com', ; + 'raw.githubusercontent.com') + ccThorRepository_Branch+'/ThorUpdater/' + +*/SF 20231130 Change fixed URL to #DEFINE +lcVersionFileURL = lcDownloadsURL + 'ThorRepositoryVersion.txt' + && the URL for the file containing code to get the available version number +lcZIPFileURL = lcDownloadsURL + 'ThorRepository.zip' + && the URL for the zip file containing the project + +* Set the properties of the passed updater object. + +with toUpdateObject + .ApplicationName = 'Thor Repository' + .VersionLocalFilename = 'ThorRepositoryVersionFile.txt' + .VersionFileURL = lcVersionFileURL + .SourceFileUrl = lcZIPFileURL + .Link = lcRepositoryURL + .LinkPrompt = 'Thor Repository Home Page' + .InstallInTools = .T. +endwith +return toUpdateObject