remove operators in QPIConfig::Entry
git-svn-id: svn://db.shs.com.ru/libs@946 a8b55f48-bf90-11e4-a774-851b48703e85
This commit is contained in:
@@ -81,7 +81,7 @@ void MainWindow::redrawGraphics() {
|
||||
|
||||
void MainWindow::loading(QPIConfig & conf) {
|
||||
active_ = false;
|
||||
QStringList vars = conf.getValue("variables", QStringList());
|
||||
QStringList vars = conf.getValue("variables").toStringList();
|
||||
int vc = vars.size() / 2;
|
||||
for (int i = 0; i < vc; ++i) {
|
||||
QTreeWidgetItem * ti = new QTreeWidgetItem(treeVariables);
|
||||
@@ -91,7 +91,8 @@ void MainWindow::loading(QPIConfig & conf) {
|
||||
treeVariables->addTopLevelItem(ti);
|
||||
}
|
||||
buttonVarClear->setEnabled(treeVariables->topLevelItemCount() > 0);
|
||||
QByteArray ba = QString2QByteArray(conf.getValue("graphics")); QDataStream s(ba);
|
||||
QByteArray ba = conf.getValue("graphics").toByteArray();
|
||||
QDataStream s(ba);
|
||||
QVector<GraphicType> g;
|
||||
if (!ba.isEmpty()) s >> g;
|
||||
graphic->setAllGraphics(g);
|
||||
@@ -105,8 +106,8 @@ void MainWindow::loading(QPIConfig & conf) {
|
||||
treeGraphics->addTopLevelItem(ti);
|
||||
}
|
||||
buttonGraphicClear->setEnabled(treeGraphics->topLevelItemCount() > 0);
|
||||
graphic->setVisualRect(conf.getValue("graphicRect", QRectF(-1., -1., 2., 2.)));
|
||||
ba = conf.getValue("graphic_state", QByteArray());
|
||||
graphic->setVisualRect(conf.getValue("graphicRect", QRectF(-1., -1., 2., 2.)).toRectF());
|
||||
ba = conf.getValue("graphic_state").toByteArray();
|
||||
if (!ba.isEmpty())
|
||||
graphic->load(ba);
|
||||
on_tabWidget_currentChanged(0);
|
||||
|
||||
Reference in New Issue
Block a user