pastebin URL app setting

This commit is contained in:
swirl 2022-01-14 18:30:02 -05:00
parent a62155c1c9
commit a606b47a22
No known key found for this signature in database
GPG Key ID: 46507311CD292A08
3 changed files with 6 additions and 13 deletions

View File

@ -714,8 +714,8 @@ Application::Application(int &argc, char **argv) : QApplication(argc, argv)
m_settings->registerSetting("UpdateDialogGeometry", "");
// paste.ee API key
m_settings->registerSetting("PasteEEAPIKey", "multimc");
// pastebin URL
m_settings->registerSetting("PastebinURL", "0x0.st");
// Init page provider
{

View File

@ -43,16 +43,9 @@ PastePage::~PastePage()
void PastePage::loadSettings()
{
auto s = APPLICATION->settings();
QString keyToUse = s->get("PasteEEAPIKey").toString();
if(keyToUse == "multimc")
{
ui->multimcButton->setChecked(true);
}
else
{
ui->customButton->setChecked(true);
ui->customAPIkeyEdit->setText(keyToUse);
}
QString pastebin = s->get("PastebinURL");
int index = ui->urlChoices->findText(pastebin);
ui->urlChoices->setCurrentIndex(index);
}
void PastePage::applySettings()

View File

@ -47,7 +47,7 @@
</widget>
</item>
<item>
<widget class="QComboBox" name="comboBox">
<widget class="QComboBox" name="urlChoices">
<item>
<property name="text">
<string>0x0.st</string>