144 unsigned C_INT32 newMaxFiles = 0;
147 QList< QTreeWidgetItem *> Items = mpTreeWidget->findItems(
"Max Last Visited Files", 0, 0);
150 if (Items.size() > 0 &&
153 newMaxFiles = Items[0]->text(
COL_VALUE).toUInt();
156 if (newMaxFiles > 0 && newMaxFiles <= 20)
161 "Max Last Visited Files should be a number between 1 and 20.",
162 QMessageBox::Ok, QMessageBox::Ok);
163 Items[0]->setText(
COL_VALUE, QString::number(maxFiles));
169 Items = mpTreeWidget->findItems(
"Max Last Visited SBML Files", 0, 0);
172 if (Items.size() > 0 &&
175 newMaxFiles = Items[0]->text(
COL_VALUE).toUInt();
178 if (newMaxFiles > 0 && newMaxFiles <= 20)
182 CQMessageBox::critical(
this,
"Incorrect Setting",
"Max Last Visited SBML Files should be a number between 1 and 20.",
183 QMessageBox::Ok, QMessageBox::Ok);
185 Items[0]->setText(
COL_VALUE, QString::number(maxFiles));
191 Items = mpTreeWidget->findItems(
"Application for opening URLs", 0, 0);
192 pParameter = configFile->
getParameter(
"Application for opening URLs");
194 if (Items.size() > 0 &&
202 Items = mpTreeWidget->findItems(
"Validate Units", 0, 0);
203 pParameter = configFile->
getParameter(
"Validate Units");
205 if (Items.size() > 0 &&
211 Items = mpTreeWidget->findItems(
"Use OpenGL", 0, 0);
214 if (Items.size() > 0 &&
220 Items = mpTreeWidget->findItems(
"Use Advanced Sliders", 0, 0);
221 pParameter = configFile->
getParameter(
"Use Advanced Sliders");
223 if (Items.size() > 0 &&
229 Items = mpTreeWidget->findItems(
"Use Advanced Editing", 0, 0);
230 pParameter = configFile->
getParameter(
"Use Advanced Editing");
232 if (Items.size() > 0 &&
238 Items = mpTreeWidget->findItems(
"Normalize Weights per Experiment", 0, 0);
239 pParameter = configFile->
getParameter(
"Normalize Weights per Experiment");
241 if (Items.size() > 0 &&
bool setValue(const CType &value)
CRecentFiles & getRecentFiles()
static CConfigurationFile * getConfiguration()
const Value & getValue() const
CRecentFiles & getRecentSBMLFiles()
CCopasiParameter * getParameter(const std::string &name)
static StandardButton critical(QWidget *parent, const QString &title, const QString &text, StandardButtons buttons=Ok, StandardButton defaultButton=NoButton)