mirror of
https://github.com/ShareX/ShareX.git
synced 2024-10-04 04:06:05 +13:00
Added GetUploadersConfigTabPage function to all URL shortener services
This commit is contained in:
parent
c84a3b4fe4
commit
d5d1dae20c
8 changed files with 3716 additions and 3374 deletions
|
@ -4462,12 +4462,9 @@ private void InitializeComponent()
|
||||||
internal System.Windows.Forms.TextBox txtCustomUploaderArgName;
|
internal System.Windows.Forms.TextBox txtCustomUploaderArgName;
|
||||||
private System.Windows.Forms.TabPage tpURLShorteners;
|
private System.Windows.Forms.TabPage tpURLShorteners;
|
||||||
private System.Windows.Forms.TabControl tcURLShorteners;
|
private System.Windows.Forms.TabControl tcURLShorteners;
|
||||||
private System.Windows.Forms.TabPage tpBitly;
|
|
||||||
private OAuthControl oauth2Bitly;
|
private OAuthControl oauth2Bitly;
|
||||||
private System.Windows.Forms.TabPage tpGoogleURLShortener;
|
|
||||||
private OAuthControl oauth2GoogleURLShortener;
|
private OAuthControl oauth2GoogleURLShortener;
|
||||||
private AccountTypeControl atcGoogleURLShortenerAccountType;
|
private AccountTypeControl atcGoogleURLShortenerAccountType;
|
||||||
private System.Windows.Forms.TabPage tpYourls;
|
|
||||||
private System.Windows.Forms.TextBox txtYourlsPassword;
|
private System.Windows.Forms.TextBox txtYourlsPassword;
|
||||||
private System.Windows.Forms.TextBox txtYourlsUsername;
|
private System.Windows.Forms.TextBox txtYourlsUsername;
|
||||||
private System.Windows.Forms.TextBox txtYourlsSignature;
|
private System.Windows.Forms.TextBox txtYourlsSignature;
|
||||||
|
@ -4694,7 +4691,6 @@ private void InitializeComponent()
|
||||||
private System.Windows.Forms.Label lblOwnCloudHost;
|
private System.Windows.Forms.Label lblOwnCloudHost;
|
||||||
private System.Windows.Forms.CheckBox cbOwnCloudCreateShare;
|
private System.Windows.Forms.CheckBox cbOwnCloudCreateShare;
|
||||||
private System.Windows.Forms.CheckBox cbOwnCloudDirectLink;
|
private System.Windows.Forms.CheckBox cbOwnCloudDirectLink;
|
||||||
private System.Windows.Forms.TabPage tpAdFly;
|
|
||||||
private System.Windows.Forms.TextBox txtAdflyAPIUID;
|
private System.Windows.Forms.TextBox txtAdflyAPIUID;
|
||||||
private System.Windows.Forms.Label lblAdflyAPIUID;
|
private System.Windows.Forms.Label lblAdflyAPIUID;
|
||||||
private System.Windows.Forms.TextBox txtAdflyAPIKEY;
|
private System.Windows.Forms.TextBox txtAdflyAPIKEY;
|
||||||
|
@ -4753,7 +4749,6 @@ private void InitializeComponent()
|
||||||
private System.Windows.Forms.TextBox txtUp1Host;
|
private System.Windows.Forms.TextBox txtUp1Host;
|
||||||
private System.Windows.Forms.Label lblUp1Key;
|
private System.Windows.Forms.Label lblUp1Key;
|
||||||
private System.Windows.Forms.Label lblUp1Host;
|
private System.Windows.Forms.Label lblUp1Host;
|
||||||
private System.Windows.Forms.TabPage tpCoinURL;
|
|
||||||
private System.Windows.Forms.TextBox txtCoinURLUUID;
|
private System.Windows.Forms.TextBox txtCoinURLUUID;
|
||||||
private System.Windows.Forms.Label lblCoinURLUUID;
|
private System.Windows.Forms.Label lblCoinURLUUID;
|
||||||
private System.Windows.Forms.CheckBox cbOwnCloud81Compatibility;
|
private System.Windows.Forms.CheckBox cbOwnCloud81Compatibility;
|
||||||
|
@ -4762,7 +4757,6 @@ private void InitializeComponent()
|
||||||
private System.Windows.Forms.Label lblOneTimeSecretEmail;
|
private System.Windows.Forms.Label lblOneTimeSecretEmail;
|
||||||
private System.Windows.Forms.TextBox txtOneTimeSecretAPIKey;
|
private System.Windows.Forms.TextBox txtOneTimeSecretAPIKey;
|
||||||
private System.Windows.Forms.TextBox txtOneTimeSecretEmail;
|
private System.Windows.Forms.TextBox txtOneTimeSecretEmail;
|
||||||
private System.Windows.Forms.TabPage tpPolr;
|
|
||||||
private System.Windows.Forms.TextBox txtPolrAPIKey;
|
private System.Windows.Forms.TextBox txtPolrAPIKey;
|
||||||
private System.Windows.Forms.Label lblPolrAPIKey;
|
private System.Windows.Forms.Label lblPolrAPIKey;
|
||||||
private System.Windows.Forms.TextBox txtPolrAPIHostname;
|
private System.Windows.Forms.TextBox txtPolrAPIHostname;
|
||||||
|
@ -4901,5 +4895,11 @@ private void InitializeComponent()
|
||||||
public System.Windows.Forms.TabPage tpStreamable;
|
public System.Windows.Forms.TabPage tpStreamable;
|
||||||
public System.Windows.Forms.TabPage tpSharedFolder;
|
public System.Windows.Forms.TabPage tpSharedFolder;
|
||||||
public System.Windows.Forms.TabPage tpEmail;
|
public System.Windows.Forms.TabPage tpEmail;
|
||||||
|
public System.Windows.Forms.TabPage tpBitly;
|
||||||
|
public System.Windows.Forms.TabPage tpGoogleURLShortener;
|
||||||
|
public System.Windows.Forms.TabPage tpYourls;
|
||||||
|
public System.Windows.Forms.TabPage tpAdFly;
|
||||||
|
public System.Windows.Forms.TabPage tpCoinURL;
|
||||||
|
public System.Windows.Forms.TabPage tpPolr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -26,6 +26,7 @@ You should have received a copy of the GNU General Public License
|
||||||
// Credits: https://github.com/LRNAB
|
// Credits: https://github.com/LRNAB
|
||||||
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace ShareX.UploadersLib.URLShorteners
|
namespace ShareX.UploadersLib.URLShorteners
|
||||||
{
|
{
|
||||||
|
@ -46,6 +47,8 @@ public override URLShortener CreateShortener(UploadersConfig config, TaskReferen
|
||||||
APIUID = config.AdFlyAPIUID
|
APIUID = config.AdFlyAPIUID
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override TabPage GetUploadersConfigTabPage(UploadersConfigForm form) => form.tpAdFly;
|
||||||
}
|
}
|
||||||
|
|
||||||
public class AdFlyURLShortener : URLShortener
|
public class AdFlyURLShortener : URLShortener
|
||||||
|
|
|
@ -27,6 +27,7 @@ You should have received a copy of the GNU General Public License
|
||||||
using ShareX.HelpersLib;
|
using ShareX.HelpersLib;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Web;
|
using System.Web;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace ShareX.UploadersLib.URLShorteners
|
namespace ShareX.UploadersLib.URLShorteners
|
||||||
{
|
{
|
||||||
|
@ -51,6 +52,8 @@ public override URLShortener CreateShortener(UploadersConfig config, TaskReferen
|
||||||
Domain = config.BitlyDomain
|
Domain = config.BitlyDomain
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override TabPage GetUploadersConfigTabPage(UploadersConfigForm form) => form.tpBitly;
|
||||||
}
|
}
|
||||||
|
|
||||||
public sealed class BitlyURLShortener : URLShortener, IOAuth2Basic
|
public sealed class BitlyURLShortener : URLShortener, IOAuth2Basic
|
||||||
|
|
|
@ -26,6 +26,7 @@ You should have received a copy of the GNU General Public License
|
||||||
// Credits: https://github.com/DanielMcAssey
|
// Credits: https://github.com/DanielMcAssey
|
||||||
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace ShareX.UploadersLib.URLShorteners
|
namespace ShareX.UploadersLib.URLShorteners
|
||||||
{
|
{
|
||||||
|
@ -45,6 +46,8 @@ public override URLShortener CreateShortener(UploadersConfig config, TaskReferen
|
||||||
UUID = config.CoinURLUUID
|
UUID = config.CoinURLUUID
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override TabPage GetUploadersConfigTabPage(UploadersConfigForm form) => form.tpCoinURL;
|
||||||
}
|
}
|
||||||
|
|
||||||
public sealed class CoinURLShortener : URLShortener
|
public sealed class CoinURLShortener : URLShortener
|
||||||
|
|
|
@ -26,6 +26,7 @@ You should have received a copy of the GNU General Public License
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using ShareX.HelpersLib;
|
using ShareX.HelpersLib;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace ShareX.UploadersLib.URLShorteners
|
namespace ShareX.UploadersLib.URLShorteners
|
||||||
{
|
{
|
||||||
|
@ -42,6 +43,8 @@ public override URLShortener CreateShortener(UploadersConfig config, TaskReferen
|
||||||
{
|
{
|
||||||
return new GoogleURLShortener(config.GoogleURLShortenerAccountType, APIKeys.GoogleAPIKey, config.GoogleURLShortenerOAuth2Info);
|
return new GoogleURLShortener(config.GoogleURLShortenerAccountType, APIKeys.GoogleAPIKey, config.GoogleURLShortenerOAuth2Info);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override TabPage GetUploadersConfigTabPage(UploadersConfigForm form) => form.tpGoogleURLShortener;
|
||||||
}
|
}
|
||||||
|
|
||||||
public class GoogleURLShortener : URLShortener, IOAuth2
|
public class GoogleURLShortener : URLShortener, IOAuth2
|
||||||
|
|
|
@ -27,6 +27,7 @@ You should have received a copy of the GNU General Public License
|
||||||
|
|
||||||
using ShareX.HelpersLib;
|
using ShareX.HelpersLib;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace ShareX.UploadersLib.URLShorteners
|
namespace ShareX.UploadersLib.URLShorteners
|
||||||
{
|
{
|
||||||
|
@ -47,6 +48,8 @@ public override URLShortener CreateShortener(UploadersConfig config, TaskReferen
|
||||||
API_KEY = config.PolrAPIKey
|
API_KEY = config.PolrAPIKey
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override TabPage GetUploadersConfigTabPage(UploadersConfigForm form) => form.tpPolr;
|
||||||
}
|
}
|
||||||
|
|
||||||
public sealed class PolrURLShortener : URLShortener
|
public sealed class PolrURLShortener : URLShortener
|
||||||
|
|
|
@ -25,6 +25,7 @@ You should have received a copy of the GNU General Public License
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace ShareX.UploadersLib.URLShorteners
|
namespace ShareX.UploadersLib.URLShorteners
|
||||||
{
|
{
|
||||||
|
@ -48,6 +49,8 @@ public override URLShortener CreateShortener(UploadersConfig config, TaskReferen
|
||||||
Password = config.YourlsPassword
|
Password = config.YourlsPassword
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override TabPage GetUploadersConfigTabPage(UploadersConfigForm form) => form.tpYourls;
|
||||||
}
|
}
|
||||||
|
|
||||||
public sealed class YourlsURLShortener : URLShortener
|
public sealed class YourlsURLShortener : URLShortener
|
||||||
|
|
Loading…
Reference in a new issue