fixed bug where locals would upload even when checkbox was unchecked
This commit is contained in:
@@ -411,7 +411,7 @@ OdyseeAudioThumbCheckStatus := 0
|
||||
*/
|
||||
(RumbleURL != "")?(RumbleCheckStatus := 0) : (RumbleCheckStatus := 1)
|
||||
; if user tried to upload to locals already and still needs to grab the url, check
|
||||
(LocalsURL = "LocalsUploadStartedNeedToGrabURL")?(LocalsCheckStatus := 1) : (LocalsCheckStatus := 0)
|
||||
(LocalsURL = "LocalsUploadStartedNeedToGrabURL")?(LocalsCheckStatus := 0) : (LocalsCheckStatus := 0)
|
||||
(BrighteonURL != "")?(BrighteonCheckStatus := 0) : (BrighteonCheckStatus := 1)
|
||||
if(VideoFileSizeInMB > 6144){
|
||||
VideoFileSizeOver6GB := 1
|
||||
@@ -556,6 +556,13 @@ else, {
|
||||
}
|
||||
|
||||
|
||||
; @ TODO REMOVE
|
||||
; LocalsGrabURL := 0
|
||||
; Locals := 0
|
||||
|
||||
|
||||
|
||||
|
||||
; -------------------------------GUI-------------------------------
|
||||
|
||||
Gui, Font, s%GuiFontSize%
|
||||
@@ -738,28 +745,28 @@ Gui, Add, GroupBox,r6 y+%MarginSpaceTripled% x%PageTwoXStartPos% w%PageTwoGroupB
|
||||
; if(VideoFileSizeInMB < 1792)
|
||||
; Gui, Add, Checkbox, x+%MarginSpaceDoubled% vFacebook Checked%FacebookCheckStatus%, Facebook
|
||||
|
||||
Gui, Add, Checkbox, xp+10 yp+25 vBitChute Checked%BitChuteCheckStatus%, BitChute
|
||||
Gui, Add, Checkbox, xp+10 yp+25 vBitChute Checked%BitChuteCheckStatus% gUpdateVars, BitChute
|
||||
|
||||
if(LocalsURL = "LocalsUploadStartedNeedToGrabURL"){
|
||||
Gui, Add, Checkbox, x+%MarginSpaceTripled% yp+0 vLocalsGrabURL Checked%LocalsCheckStatus%, Locals (Grab URL)
|
||||
Gui, Add, Checkbox, x+%MarginSpaceTripled% yp+0 vLocalsGrabURL Checked%LocalsCheckStatus% gUpdateVars, Locals (Grab URL)
|
||||
}
|
||||
else, {
|
||||
Gui, Add, Checkbox, x+%MarginSpaceTripled% yp+0 vLocals Checked%LocalsCheckStatus%, Locals
|
||||
Gui, Add, Checkbox, x+%MarginSpaceTripled% yp+0 vLocals Checked%LocalsCheckStatus% gUpdateVars, Locals
|
||||
}
|
||||
|
||||
if(VideoFileSizeInMB < 50)
|
||||
Gui, Add, Checkbox, vTelegram x+%MarginSpaceDoubled% Checked%TelegramCheckStatus%, Telegram
|
||||
Gui, Add, Checkbox, vTelegram x+%MarginSpaceDoubled% Checked%TelegramCheckStatus% gUpdateVars, Telegram
|
||||
|
||||
|
||||
Gui, Add, Checkbox, x%GroupBoxCheckboxPos% y+%MarginSpace% vOdyseeVideo Checked%OdyseeVideoCheckStatus%, Odysee Video
|
||||
Gui, Add, Checkbox, x%GroupBoxCheckboxPos% y+%MarginSpace% vOdyseeVideo Checked%OdyseeVideoCheckStatus% gUpdateVars, Odysee Video
|
||||
; Gui, Add, Checkbox, x+%MarginSpace% vOdyseeVideoThumb Checked%OdyseeVideoThumbCheckStatus%,Thumbnail
|
||||
Gui, Add, Checkbox, x%GroupBoxCheckboxPos% y+%MarginSpace% vOdyseeAudio Checked%OdyseeAudioCheckStatus%, Odysee Audio
|
||||
Gui, Add, Checkbox, x%GroupBoxCheckboxPos% y+%MarginSpace% vOdyseeAudio Checked%OdyseeAudioCheckStatus% gUpdateVars, Odysee Audio
|
||||
; Gui, Add, Checkbox, x+%MarginSpace% vOdyseeAudioThumb Checked%OdyseeAudioThumbCheckStatus%, Thumbnail
|
||||
|
||||
Gui, Add, Checkbox, x%GroupBoxCheckboxPos% y+%MarginSpace% vRumble Checked%RumbleCheckStatus%, Rumble
|
||||
Gui, Add, Checkbox, x%GroupBoxCheckboxPos% y+%MarginSpace% vRumble Checked%RumbleCheckStatus% gUpdateVars, Rumble
|
||||
|
||||
Gui, Add, Checkbox, vBrighteon y+%MarginSpace% Checked%BrighteonCheckStatus%, Brighteon
|
||||
Gui, Add, Checkbox, vDailyMotion y+%MarginSpace% Checked%DailyMotionCheckStatus%, DailyMotion
|
||||
Gui, Add, Checkbox, vBrighteon y+%MarginSpace% Checked%BrighteonCheckStatus% gUpdateVars, Brighteon
|
||||
Gui, Add, Checkbox, vDailyMotion y+%MarginSpace% Checked%DailyMotionCheckStatus% gUpdateVars, DailyMotion
|
||||
; Gui, Add, Checkbox, vStreamanity Checked%StreamanityCheckStatus%, Streamanity
|
||||
|
||||
; Gui, Font, s12
|
||||
@@ -949,41 +956,44 @@ if(!status){
|
||||
}
|
||||
|
||||
|
||||
DownloadLatestChromium()
|
||||
DownloadLatestChromium()
|
||||
|
||||
|
||||
Return
|
||||
|
||||
; now defunt, safe to remove
|
||||
CreateDescriptionForVideosPosting:
|
||||
; msgbox, here
|
||||
Gui, VideoDescriptionTrimmer:New,
|
||||
Gui, Font, s%GuiFontSize%
|
||||
Gui, Add, Text,, Discord and Telegram have a maximum API post length of 2000 Characters `nwhich the curent description exceeds.`nPlease Trim down the description and then click submit.
|
||||
Gui, Font, s%GuiFontSize%
|
||||
Gui, Add, Edit, w800 h500 gUpdateVars vVideoDescriptionForVideosChannel, %VideoDescription%
|
||||
Gui, Add, Button, gSubmitDescriptionForVideosChannel, Submit
|
||||
gui, Show,w820, Video Description Trimmer
|
||||
; msgbox
|
||||
Return
|
||||
/*
|
||||
*/
|
||||
|
||||
; now defunt, safe to remove
|
||||
CreateDescriptionForVideosPosting:
|
||||
; msgbox, here
|
||||
Gui, VideoDescriptionTrimmer:New,
|
||||
Gui, Font, s%GuiFontSize%
|
||||
Gui, Add, Text,, Discord and Telegram have a maximum API post length of 2000 Characters `nwhich the curent description exceeds.`nPlease Trim down the description and then click submit.
|
||||
Gui, Font, s%GuiFontSize%
|
||||
Gui, Add, Edit, w800 h500 gUpdateVars vVideoDescriptionForVideosChannel, %VideoDescription%
|
||||
Gui, Add, Button, gSubmitDescriptionForVideosChannel, Submit
|
||||
gui, Show,w820, Video Description Trimmer
|
||||
; msgbox
|
||||
Return
|
||||
|
||||
|
||||
SubmitDescriptionForVideosChannel:
|
||||
Gui, Submit
|
||||
; msgbox, submitted
|
||||
if(CurrentSocialMediaPosting = "Discord")
|
||||
Goto, SubmitDescriptionForDiscordVideosChannel
|
||||
if(CurrentSocialMediaPosting = "Telegram")
|
||||
Goto, SubmitDescriptionForTelegramVideosChannel
|
||||
SubmitDescriptionForVideosChannel:
|
||||
Gui, Submit
|
||||
; msgbox, submitted
|
||||
if(CurrentSocialMediaPosting = "Discord")
|
||||
Goto, SubmitDescriptionForDiscordVideosChannel
|
||||
if(CurrentSocialMediaPosting = "Telegram")
|
||||
Goto, SubmitDescriptionForTelegramVideosChannel
|
||||
|
||||
if(CurrentSocialMediaPosting = "Telegram Video")
|
||||
goto, SubmitDescriptionForTelegramVideoUpload
|
||||
if(CurrentSocialMediaPosting = "Telegram Video")
|
||||
goto, SubmitDescriptionForTelegramVideoUpload
|
||||
|
||||
Return
|
||||
Return
|
||||
|
||||
|
||||
|
||||
CreateDescriptionForSocialMedia(){
|
||||
CreateDescriptionForSocialMedia(){
|
||||
SplitText = Free Documentaries:
|
||||
|
||||
SocialMediaDescription := StrSplit(VideoDescription, SplitText)
|
||||
@@ -995,22 +1005,22 @@ DownloadLatestChromium()
|
||||
}
|
||||
|
||||
Return
|
||||
}
|
||||
; -------------------------------Upload Video Functionality-------------------------------
|
||||
StartScript:
|
||||
WinGetPos, XPosition, YPosition, , , A
|
||||
IniWrite, %XPosition%, %SettingsIniFilepath%, General, XPosition
|
||||
IniWrite, %YPosition%, %SettingsIniFilepath%, General, YPosition
|
||||
}
|
||||
; -------------------------------Upload Video Functionality-------------------------------
|
||||
StartScript:
|
||||
WinGetPos, XPosition, YPosition, , , A
|
||||
IniWrite, %XPosition%, %SettingsIniFilepath%, General, XPosition
|
||||
IniWrite, %YPosition%, %SettingsIniFilepath%, General, YPosition
|
||||
|
||||
Gui, Submit
|
||||
Gui, Destroy
|
||||
Gui, Submit
|
||||
Gui, Destroy
|
||||
|
||||
|
||||
|
||||
|
||||
; Save Testing Mode Info
|
||||
;------------------------------------------------
|
||||
if(TestingMode){ ; save currently seelcted sites to ini file for next test
|
||||
; Save Testing Mode Info
|
||||
;------------------------------------------------
|
||||
if(TestingMode){ ; save currently seelcted sites to ini file for next test
|
||||
; IniWrite, %Streamanity%, %SettingsIniFilepath%, Testing, Streamanity
|
||||
IniWrite, %BitChute%, %SettingsIniFilepath%, Testing, BitChute
|
||||
IniWrite, %OdyseeVideo%, %SettingsIniFilepath%, Testing, OdyseeVideo
|
||||
@@ -1023,127 +1033,127 @@ DownloadLatestChromium()
|
||||
IniWrite, %Locals%, %SettingsIniFilepath%, Testing, Locals
|
||||
IniWrite, %Telegram%, %SettingsIniFilepath%, Testing, Telegram
|
||||
IniWrite, %Facebook%, %SettingsIniFilepath%, Testing, Facebook
|
||||
}
|
||||
}
|
||||
|
||||
; Save Video Info
|
||||
;------------------------------------------------
|
||||
; if changes made, delete the original file and save the new content to it
|
||||
; Save Video Info
|
||||
;------------------------------------------------
|
||||
; if changes made, delete the original file and save the new content to it
|
||||
|
||||
if(VideoTitle != OriginalVideoTitle){
|
||||
if(VideoTitle != OriginalVideoTitle){
|
||||
VideoTitleFilepath = %VideoFolderDir%\title.txt
|
||||
|
||||
FileDelete, %VideoTitleFilepath%
|
||||
FileAppend, %VideoTitle%, %VideoTitleFilepath%
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if(VideoTags != OriginalVideoTags){
|
||||
if(VideoTags != OriginalVideoTags){
|
||||
VideoTagsFilepath = %VideoFolderDir%\keywords.txt
|
||||
|
||||
FileDelete, %VideoTagsFilepath%
|
||||
FileAppend, %VideoTags%, %VideoTagsFilepath%
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if(PodcastTags != OriginalPodcastTags){
|
||||
if(PodcastTags != OriginalPodcastTags){
|
||||
PodcastTagsFilepath = %VideoFolderDir%\keywords_podcast.txt
|
||||
|
||||
FileDelete, %PodcastTagsFilepath%
|
||||
FileAppend, %PodcastTags%, %PodcastTagsFilepath%
|
||||
}
|
||||
}
|
||||
|
||||
if(VideoDescription != OriginalVideoDescription){
|
||||
if(VideoDescription != OriginalVideoDescription){
|
||||
VideoBodyFilepath = %VideoFolderDir%\body.txt
|
||||
|
||||
FileDelete, %VideoBodyFilepath%
|
||||
FileAppend, %VideoDescription%, %VideoBodyFilepath%
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
; -------------------------------/Save Video Info-------------------------------
|
||||
; -------------------------------/Save Video Info-------------------------------
|
||||
|
||||
; Save settings to config file
|
||||
IniWrite, %ReuseTabs%, %SettingsIniFilepath%, General, ReuseTabs
|
||||
IniWrite, %ShowTooltipProgress%, %SettingsIniFilepath%, General, ShowTooltipProgress
|
||||
IniWrite, %AutoUpdateCheck%, %SettingsIniFilepath%, General, AutoUpdateCheck
|
||||
IniWrite, %AutoLogin%, %SettingsIniFilepath%, General, AutoLogin
|
||||
IniWrite, %PingOnCompletion%, %SettingsIniFilepath%, General, PingOnCompletion
|
||||
IniWrite, %KillLBRYAfterUpload%, %SettingsIniFilepath%, General, KillLBRYAfterUpload
|
||||
; Save settings to config file
|
||||
IniWrite, %ReuseTabs%, %SettingsIniFilepath%, General, ReuseTabs
|
||||
IniWrite, %ShowTooltipProgress%, %SettingsIniFilepath%, General, ShowTooltipProgress
|
||||
IniWrite, %AutoUpdateCheck%, %SettingsIniFilepath%, General, AutoUpdateCheck
|
||||
IniWrite, %AutoLogin%, %SettingsIniFilepath%, General, AutoLogin
|
||||
IniWrite, %PingOnCompletion%, %SettingsIniFilepath%, General, PingOnCompletion
|
||||
IniWrite, %KillLBRYAfterUpload%, %SettingsIniFilepath%, General, KillLBRYAfterUpload
|
||||
|
||||
|
||||
if(VideoFilepath = ""){
|
||||
if(VideoFilepath = ""){
|
||||
Msgbox,4096,Error,No Video Filepath Found.`nPlease Input Video Filepath to Upload a Video.
|
||||
run, "%A_ScriptFullPath%" "LastPost"
|
||||
ExitApp
|
||||
}
|
||||
}
|
||||
|
||||
; Format the LBRYURLSlug to be API Compatible
|
||||
if(LBRYURLSlug = "") ; if slug spot is blank, then set it to video title
|
||||
LBRYURLSlug := VideoTitle
|
||||
LBRYURLSlug := LBRYCMDTextReplacement(LBRYURLSlug)
|
||||
; Format the LBRYURLSlug to be API Compatible
|
||||
if(LBRYURLSlug = "") ; if slug spot is blank, then set it to video title
|
||||
LBRYURLSlug := VideoTitle
|
||||
LBRYURLSlug := LBRYCMDTextReplacement(LBRYURLSlug)
|
||||
|
||||
; Save the LBRY URL Slug to .ini file in case it's needed later
|
||||
IniWrite, %LBRYURLSlug%, %VideoLinksIniFile%, Misc, LBRYUrlSlug
|
||||
IniWrite, %VideoThumbFilepath%, %VideoLinksIniFile%, Misc, VideoThumbFilepath
|
||||
IniWrite, %PodcastNumber%, %VideoLinksIniFile%, Misc, PodcastNumber
|
||||
; Save the LBRY URL Slug to .ini file in case it's needed later
|
||||
IniWrite, %LBRYURLSlug%, %VideoLinksIniFile%, Misc, LBRYUrlSlug
|
||||
IniWrite, %VideoThumbFilepath%, %VideoLinksIniFile%, Misc, VideoThumbFilepath
|
||||
IniWrite, %PodcastNumber%, %VideoLinksIniFile%, Misc, PodcastNumber
|
||||
|
||||
|
||||
|
||||
; -------------------------------Log Info To Text-------------------------------
|
||||
; -------------------------------Log Info To Text-------------------------------
|
||||
|
||||
(Facebook = 1)?(PostedWebsites .= "Facebook|") : ()
|
||||
(Bitchute = 1)?(PostedWebsites .= "Bitchute|") : ()
|
||||
(Locals = 1)?(PostedWebsites .= "Locals|") : ()
|
||||
(Rumble = 1)?(PostedWebsites .= "Rumble|") : ()
|
||||
(Brighteon = 1)?(PostedWebsites .= "Brighteon|") : ()
|
||||
; (Streamanity = 1)?(PostedWebsites .= "Streamanity|") : ()
|
||||
(Telegram = 1)?(PostedWebsites .= "Telegram|") : ()
|
||||
(DailyMotion = 1)?(PostedWebsites .= "DailyMotion|") : ()
|
||||
(OdyseeVideo = 1)?(PostedWebsites .= "OdyseeVideo|") : ()
|
||||
(OdyseeAudio = 1)?(PostedWebsites .= "OdyseeAudio|") : ()
|
||||
(Facebook = 1)?(PostedWebsites .= "Facebook|") : ()
|
||||
(Bitchute = 1)?(PostedWebsites .= "Bitchute|") : ()
|
||||
(Locals = 1)?(PostedWebsites .= "Locals|") : ()
|
||||
(Rumble = 1)?(PostedWebsites .= "Rumble|") : ()
|
||||
(Brighteon = 1)?(PostedWebsites .= "Brighteon|") : ()
|
||||
; (Streamanity = 1)?(PostedWebsites .= "Streamanity|") : ()
|
||||
(Telegram = 1)?(PostedWebsites .= "Telegram|") : ()
|
||||
(DailyMotion = 1)?(PostedWebsites .= "DailyMotion|") : ()
|
||||
(OdyseeVideo = 1)?(PostedWebsites .= "OdyseeVideo|") : ()
|
||||
(OdyseeAudio = 1)?(PostedWebsites .= "OdyseeAudio|") : ()
|
||||
|
||||
|
||||
; Log Basic info to the errorlogging file
|
||||
Message = %ScriptName% v%ScriptVersion%: Starting Upload `nFor: **%VideoTitle%**`nTo: %PostedWebsites%
|
||||
SaveOrPostProgress(Message:=Message,PostType:="Tooltip,ErrorLoggingTextFile,DiscordErrorLogging")
|
||||
; Log Basic info to the errorlogging file
|
||||
Message = %ScriptName% v%ScriptVersion%: Starting Upload `nFor: **%VideoTitle%**`nTo: %PostedWebsites%
|
||||
SaveOrPostProgress(Message:=Message,PostType:="Tooltip,ErrorLoggingTextFile,DiscordErrorLogging")
|
||||
|
||||
Message := "VideoTitle: " VideoTitle
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
Message := "VideoTitle: " VideoTitle
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
|
||||
Message := "VideoDescription: `n" VideoDescription
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
Message := "VideoDescription: `n" VideoDescription
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
|
||||
Message := "VideoTags: " VideoTags
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
Message := "VideoTags: " VideoTags
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
|
||||
Message := "VideoFilepath: " VideoFilepath
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
Message := "VideoFilepath: " VideoFilepath
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
|
||||
Message := "VideoThumbFilepath: " VideoThumbFilepath
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
Message := "VideoThumbFilepath: " VideoThumbFilepath
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
|
||||
Message := "TotalVideosUploaded: " TotalVideosUploaded
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
Message := "TotalVideosUploaded: " TotalVideosUploaded
|
||||
SaveOrPostProgress(Message:=Message,PostType:=",ErrorLoggingTextFile")
|
||||
|
||||
; Convert Video Description into javascript text format for sending to selenium
|
||||
JSVideoDescription := FormatTextToJSText(VideoDescription)
|
||||
JSVideoTitle := FormatTextToJSText(VideoTitle)
|
||||
; Convert Video Description into javascript text format for sending to selenium
|
||||
JSVideoDescription := FormatTextToJSText(VideoDescription)
|
||||
JSVideoTitle := FormatTextToJSText(VideoTitle)
|
||||
|
||||
; -------------------------------/Log Info To Text-------------------------------
|
||||
; -------------------------------/Log Info To Text-------------------------------
|
||||
|
||||
|
||||
|
||||
|
||||
; Create an array out of the keywords to be used in different places
|
||||
VideoTags := StrReplace(VideoTags, ", ",",")
|
||||
VideoTags := StrReplace(VideoTags, " ,",",")
|
||||
VideoTags := StrReplace(VideoTags, " ",",")
|
||||
; Create an array out of the keywords to be used in different places
|
||||
VideoTags := StrReplace(VideoTags, ", ",",")
|
||||
VideoTags := StrReplace(VideoTags, " ,",",")
|
||||
VideoTags := StrReplace(VideoTags, " ",",")
|
||||
|
||||
KeywordsArray := StrSplit(VideoTags,",")
|
||||
KeywordsArray := StrSplit(VideoTags,",")
|
||||
|
||||
|
||||
; Call each sub one by one, if errors occur then an upload will be stopped and the next upload will then proceed
|
||||
; Call each sub one by one, if errors occur then an upload will be stopped and the next upload will then proceed
|
||||
|
||||
/*
|
||||
|
||||
@@ -1157,6 +1167,7 @@ if(Facebook)
|
||||
if(Telegram)
|
||||
gosub, TelegramVideoUpload
|
||||
|
||||
|
||||
if(Locals)
|
||||
gosub, LocalsUpload
|
||||
|
||||
@@ -1198,7 +1209,7 @@ if(OdyseeAudio){
|
||||
Gosub, LBRYGetURL
|
||||
}
|
||||
|
||||
if(LocalsGrabURL OR LocalsURL = "LocalsUploadStartedNeedToGrabURL"){
|
||||
if(LocalsGrabURL){
|
||||
Gosub, LocalsGrabURL
|
||||
}
|
||||
|
||||
@@ -1359,6 +1370,10 @@ Gui, +Resize +MaximizeBox
|
||||
OriginalVideoDescription := VideoDescription
|
||||
OriginalPodcastTags := PodcastTags
|
||||
|
||||
|
||||
if(XPosition and YPosition)
|
||||
Gui, Show,x%XPosition% y%YPosition%,%FullScriptName% - Upload Results
|
||||
else,
|
||||
Gui, Show,,%FullScriptName% - Upload Results
|
||||
|
||||
SaveCurrentChromeVersionToIniFile()
|
||||
@@ -1629,11 +1644,11 @@ Return
|
||||
|
||||
|
||||
|
||||
OnMsgBoxConfirmChromiumOverwrite() {
|
||||
OnMsgBoxConfirmChromiumOverwrite() {
|
||||
DetectHiddenWindows, On
|
||||
Process, Exist
|
||||
If (WinExist("ahk_class #32770 ahk_pid " . ErrorLevel)) {
|
||||
ControlSetText Button1, Cancel
|
||||
ControlSetText Button2, Yes
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user