mirror of
https://github.com/sqlitebrowser/sqlitebrowser.git
synced 2026-01-20 02:50:46 -06:00
Remove the defaulttext settings field
Remove the settings field for setting the default text. It's not used at all and I honestly have no idea what it could be useful for.
This commit is contained in:
@@ -41,7 +41,6 @@ void PreferencesDialog::loadSettings()
|
||||
ui->encodingComboBox->setCurrentIndex(ui->encodingComboBox->findText(getSettingsValue("db", "defaultencoding").toString(), Qt::MatchFixedString));
|
||||
ui->defaultdataComboBox->setCurrentIndex(ui->defaultdataComboBox->findText(getSettingsValue("db", "defaultnewdata").toString(), Qt::MatchFixedString));
|
||||
ui->locationEdit->setText(getSettingsValue("db", "defaultlocation").toString());
|
||||
ui->defaultTextComboBox->setCurrentIndex(ui->defaultTextComboBox->findText(getSettingsValue("db", "defaulttext").toString(), Qt::MatchFixedString));
|
||||
ui->foreignKeysCheckBox->setChecked(getSettingsValue("db", "foreignkeys").toBool());
|
||||
}
|
||||
|
||||
@@ -50,7 +49,6 @@ void PreferencesDialog::saveSettings()
|
||||
setSettingsValue("db", "defaultencoding", ui->encodingComboBox->currentText());
|
||||
setSettingsValue("db", "defaultnewdata", ui->defaultdataComboBox->currentText());
|
||||
setSettingsValue("db", "defaultlocation", ui->locationEdit->text());
|
||||
setSettingsValue("db", "defaulttext", ui->defaultTextComboBox->currentText());
|
||||
setSettingsValue("db", "foreignkeys", ui->foreignKeysCheckBox->isChecked());
|
||||
accept();
|
||||
}
|
||||
@@ -99,10 +97,6 @@ QVariant PreferencesDialog::getSettingsDefaultValue(const QString& group, const
|
||||
if(group == "db" && name == "defaultlocation")
|
||||
return QDir::homePath();
|
||||
|
||||
// db/defaulttext?
|
||||
if(group == "db" && name == "defaulttext")
|
||||
return "Plain";
|
||||
|
||||
// db/foreignkeys?
|
||||
if(group == "db" && name == "foreignkeys")
|
||||
return true;
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>492</width>
|
||||
<height>219</height>
|
||||
<height>147</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
@@ -32,6 +32,20 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QComboBox" name="encodingComboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string notr="true">UTF-8</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string notr="true">UTF-16</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="text">
|
||||
@@ -62,30 +76,26 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_3">
|
||||
<widget class="QLabel" name="label_5">
|
||||
<property name="toolTip">
|
||||
<string>Open databases with foreign keys enabled.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Default text editor format</string>
|
||||
<string>Foreign keys</string>
|
||||
</property>
|
||||
<property name="buddy">
|
||||
<cstring>defaultTextComboBox</cstring>
|
||||
<cstring>foreignKeysCheckBox</cstring>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QComboBox" name="defaultTextComboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Plain</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Auto</string>
|
||||
</property>
|
||||
</item>
|
||||
<widget class="QCheckBox" name="foreignKeysCheckBox">
|
||||
<property name="text">
|
||||
<string>enabled</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="label_4">
|
||||
<property name="text">
|
||||
<string>Default location</string>
|
||||
@@ -95,7 +105,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<item row="3" column="1">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QLineEdit" name="locationEdit">
|
||||
@@ -113,40 +123,6 @@
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QComboBox" name="encodingComboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string notr="true">UTF-8</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string notr="true">UTF-16</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="label_5">
|
||||
<property name="toolTip">
|
||||
<string>Open databases with foreign keys enabled.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Foreign keys</string>
|
||||
</property>
|
||||
<property name="buddy">
|
||||
<cstring>foreignKeysCheckBox</cstring>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QCheckBox" name="foreignKeysCheckBox">
|
||||
<property name="text">
|
||||
<string>enabled</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
@@ -164,7 +140,6 @@
|
||||
<tabstops>
|
||||
<tabstop>encodingComboBox</tabstop>
|
||||
<tabstop>defaultdataComboBox</tabstop>
|
||||
<tabstop>defaultTextComboBox</tabstop>
|
||||
<tabstop>foreignKeysCheckBox</tabstop>
|
||||
<tabstop>locationEdit</tabstop>
|
||||
<tabstop>setLocationButton</tabstop>
|
||||
@@ -223,10 +198,6 @@
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>saveSettings()</slot>
|
||||
<slot>defaultDataChanged(int)</slot>
|
||||
<slot>encodingChanged(int)</slot>
|
||||
<slot>chooseLocation()</slot>
|
||||
<slot>defaultTextChanged(int)</slot>
|
||||
<slot>foreignkeysStateChanged(int)</slot>
|
||||
</slots>
|
||||
</ui>
|
||||
|
||||
Reference in New Issue
Block a user