21,8 → 21,10 |
dlg_Preferences::dlg_Preferences(QWidget *parent) : QDialog(parent) |
{ |
setupUi(this); |
connect(pb_DIR_CVS, SIGNAL(clicked()), this, SLOT(slot_DIR_CVS())); |
connect(pb_DIR_SET, SIGNAL(clicked()), this, SLOT(slot_DIR_SET())); |
connect(pb_DIR_CVS, SIGNAL(clicked()), this, SLOT(slot_DIR_CVS())); |
connect(pb_DIR_SET, SIGNAL(clicked()), this, SLOT(slot_DIR_SET())); |
connect(pb_DIR_CACHE, SIGNAL(clicked()), this, SLOT(slot_DIR_CACHE())); |
connect(pb_PATH_AVRDUDE, SIGNAL(clicked()), this, SLOT(slot_PATH_AVRDUDE())); |
} |
|
void dlg_Preferences::set_Settings(cSettings *Set) |
31,6 → 33,8 |
|
le_DIR_CVS->setText(Settings->DIR.Logging); |
le_DIR_SET->setText(Settings->DIR.Parameter); |
le_DIR_CACHE->setText(Settings->DIR.Cache); |
le_PATH_AVRDUDE->setText(Settings->DIR.AVRDUDE); |
le_TTY->setText(Settings->TTY.Port); |
sp_Plotter_Count->setValue(Settings->Data.Plotter_Count); |
sp_Debug_Fast->setValue(Settings->Data.Debug_Fast); |
79,7 → 83,6 |
{ |
Settings->DIR.Logging = directory; |
le_DIR_CVS->setText(Settings->DIR.Logging); |
// Settings->write_Settings(); |
} |
} |
|
91,11 → 94,32 |
{ |
Settings->DIR.Parameter = directory; |
le_DIR_SET->setText(Settings->DIR.Parameter); |
// Settings->write_Settings(); |
} |
|
} |
void dlg_Preferences::slot_DIR_CACHE() |
{ |
QString directory = QFileDialog::getExistingDirectory(this, trUtf8("Verzeichniss für Karten-Cache"), Settings->DIR.Cache, QFileDialog::DontResolveSymlinks | QFileDialog::ShowDirsOnly); |
|
if ((!directory.isEmpty()) && (Settings->DIR.Cache != directory)) |
{ |
Settings->DIR.Cache = directory; |
le_DIR_CACHE->setText(Settings->DIR.Cache); |
} |
} |
|
void dlg_Preferences::slot_PATH_AVRDUDE() |
{ |
QString directory = QFileDialog::getOpenFileName(this, trUtf8("Pfad zu AVRDUDE"), Settings->DIR.AVRDUDE, tr("AVRDUDE (*)")); |
|
|
if ((!directory.isEmpty()) && (Settings->DIR.AVRDUDE != directory)) |
{ |
Settings->DIR.AVRDUDE = directory; |
le_PATH_AVRDUDE->setText(Settings->DIR.AVRDUDE); |
} |
} |
|
dlg_Preferences::~dlg_Preferences() |
{ |
} |