Fixed Uploader not auto opening last selected project after uploading

pull/2/head
Yuriy 1 year ago
parent 7c0ecd7abe
commit 342fab695a

@ -228,15 +228,6 @@ if(LBRYChannelID = ""){
;---Read Info From Project Files---
;------------------------------------------------
; Ask user to select file within the production folder
if(PassedParameter = "LastPost"){
IniRead, PassedParameter, %SettingsIniFilepath%, %ScriptSettingsSection%, LastPost, %A_Space%
}
if(PassedParameter = "ShowResults"){
IniRead, PassedParameter, %SettingsIniFilepath%, %ScriptSettingsSection%, LastPost, %A_Space%
}
; if passed argument is .exe file, then script has just been udpated and we need to move the old version
if(InStr(PassedParameter,ScriptName) and InStr(PassedParameter,".exe")){
@ -252,7 +243,7 @@ if(InStr(PassedParameter,ScriptName) and InStr(PassedParameter,".exe")){
; move old version to backups folder, overwrite if name conflict
FileMove, %PassedParameter%, %BackupsFolder%\*, 1
if(ErrorLevel){ ; most likely because the old version hasn't finished exiting yet
SaveOrPostProgress(Message:="Starting Up: Moving Old Version",PostType:="Tooltip,ErrorLoggingTextFile,ErrorSummaryVar")
SaveOrPostProgress(Message:="Moving Old Version to Backups",PostType:="Tooltip,ErrorLoggingTextFile,ErrorSummaryVar")
sleep, 2000
FileMove, %PassedParameter%, %BackupsFolder%\*, 1
if(ErrorLevel){
@ -260,9 +251,20 @@ if(InStr(PassedParameter,ScriptName) and InStr(PassedParameter,".exe")){
}
ToolTip
}
; Change paramter to LastPost so last post gets automatically opened instead of user having to re-select the file again
PassedParameter = LastPost
}
if(PassedParameter = "LastPost"){
IniRead, PassedParameter, %SettingsIniFilepath%, %ScriptSettingsSection%, LastPost, %A_Space%
}
if(PassedParameter = "ShowResults"){
IniRead, PassedParameter, %SettingsIniFilepath%, %ScriptSettingsSection%, LastPost, %A_Space%
}
PassedParameterLength := StrLen(PassedParameter)
if(PassedParameterLength < 5 and !InStr(PassedParameter, ".exe")){
FileSelectFile, BodyTextFilePath,,%RootDirToStartIn%,Please Select ANY File Within the Project Folder
@ -651,7 +653,7 @@ if(DescriptionCharCount > 3000){
else,
Gui, Add, Edit, w50 h20 x%DescriptionCharCountXPos% y+1 vDescriptionCharCount, %DescriptionCharCount%
Gui, Font, Normal
Gui, Add,Text, yp+3 xp-310, (Platform Char Limits: DM & Bitchute = 3K, Odysee,Brighteon = 5K)
Gui, Add,Text, yp+3 xp-310, (Platform Char. Limits: DM+Bitchute = 3K, Odysee,Brighteon = 5K)
Gui, Font, s%GuiFontSize%
Gui, font, Bold
Gui, Add, GroupBox,r8.5 x%MarginSpace% yp+10 w%EditBoxWidths% Center, Filepaths
@ -1168,64 +1170,64 @@ KeywordsArray := StrSplit(VideoTags,",")
; @todo: find a better location for this?
GetChromeFilepath()
if(Facebook){
if(Facebook){
UploadedToSites .= "Facebook,"
gosub, FacebookUpload
}
; gosub, FacebookUpload
}
if(Telegram){
if(Telegram){
UploadedToSites .= "Telegram,"
gosub, TelegramVideoUpload
}
}
; Call each sub one by one, if errors occur then an upload will be stopped and the next upload will then proceed
if(Locals){
; Call each sub one by one, if errors occur then an upload will be stopped and the next upload will then proceed
if(Locals){
UploadedToSites .= "Locals,"
gosub, LocalsUpload
}
}
if(BitChute){
if(BitChute){
UploadedToSites .= "Bitchute,"
Gosub, BitChuteUpload
}
}
if(OdyseeVideo){
if(OdyseeVideo){
UploadedToSites .= "LBRYVideo,"
LBRYUploadType := "Video"
Gosub, LBRYVideoUpload
}
if(OdyseeAudio){
}
if(OdyseeAudio){
UploadedToSites .= "LBRYAudio,"
LBRYUploadType := "Audio"
Gosub, LBRYAudioUpload
}
}
if(Rumble){
if(Rumble){
UploadedToSites .= "Rumble,"
Gosub, RumbleUpload
}
}
if(Brighteon){
if(Brighteon){
UploadedToSites .= "Brighteon,"
Gosub, BrighteonUpload
}
}
if(DailyMotion){
if(DailyMotion){
UploadedToSites .= "DailyMotion,"
Gosub, DailyMotionUpload
}
}
; grab the LBRY Video/Audio URLs
if(OdyseeVideo){
; grab the LBRY Video/Audio URLs
if(OdyseeVideo){
LBRYUploadType := "Video"
Gosub, LBRYGetURL
}
if(OdyseeAudio){
}
if(OdyseeAudio){
LBRYUploadType := "Audio"
Gosub, LBRYGetURL
}
}
/* if(OdyseeVideoThumb){
OdyseeUploadType := "Video"

Loading…
Cancel
Save