Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BornAgain
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mlz
BornAgain
Commits
5534da2c
Commit
5534da2c
authored
8 months ago
by
Wuttke, Joachim
Browse files
Options
Downloads
Patches
Plain Diff
rm DoubleProperty::readFrom1
parent
cb7154cf
No related branches found
No related tags found
1 merge request
!2654
XML read/write more compact
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
GUI/Model/Descriptor/DoubleProperty.cpp
+1
-6
1 addition, 6 deletions
GUI/Model/Descriptor/DoubleProperty.cpp
GUI/Model/Descriptor/DoubleProperty.h
+0
-1
0 additions, 1 deletion
GUI/Model/Descriptor/DoubleProperty.h
GUI/Model/Sim/InstrumentItems.cpp
+1
-2
1 addition, 2 deletions
GUI/Model/Sim/InstrumentItems.cpp
with
2 additions
and
9 deletions
GUI/Model/Descriptor/DoubleProperty.cpp
+
1
−
6
View file @
5534da2c
...
...
@@ -53,18 +53,13 @@ void DoubleProperty::writeTo2(QXmlStreamWriter* w, const QString& tag) const
w
->
writeEndElement
();
}
void
DoubleProperty
::
readFrom
1
(
QXmlStreamReader
*
r
)
void
DoubleProperty
::
readFrom
2
(
QXmlStreamReader
*
r
,
const
QString
&
tag
)
{
const
uint
version
=
XML
::
readUInt
(
r
,
XML
::
Attrib
::
version
);
Q_UNUSED
(
version
)
m_value
=
XML
::
readDouble
(
r
,
XML
::
Attrib
::
value
);
m_uid
=
XML
::
readString
(
r
,
XML
::
Attrib
::
id
);
}
void
DoubleProperty
::
readFrom2
(
QXmlStreamReader
*
r
,
const
QString
&
tag
)
{
readFrom1
(
r
);
XML
::
gotoEndElementOfTag
(
r
,
tag
);
}
...
...
This diff is collapsed.
Click to expand it.
GUI/Model/Descriptor/DoubleProperty.h
+
0
−
1
View file @
5534da2c
...
...
@@ -60,7 +60,6 @@ public:
void
setLimits
(
const
RealLimits
&
limits
)
{
m_limits
=
limits
;
}
void
writeTo2
(
QXmlStreamWriter
*
w
,
const
QString
&
tag
)
const
;
void
readFrom1
(
QXmlStreamReader
*
r
);
void
readFrom2
(
QXmlStreamReader
*
r
,
const
QString
&
tag
);
signals
:
...
...
This diff is collapsed.
Click to expand it.
GUI/Model/Sim/InstrumentItems.cpp
+
1
−
2
View file @
5534da2c
...
...
@@ -248,9 +248,8 @@ void InstrumentItem::readFrom(QXmlStreamReader* r)
// analyzer efficiency OBSOLETE since v21 (version == 2)
}
else
if
(
version
==
1
&&
tag
==
Tag
::
AnalyzerEfficiency
)
{
DoubleProperty
analyzerEfficiency
;
analyzerEfficiency
.
readFrom
1
(
r
);
analyzerEfficiency
.
readFrom
2
(
r
,
tag
);
m_analyzer_bloch_vector
.
setR3
(
m_analyzer_bloch_vector
.
r3
()
*
analyzerEfficiency
.
dVal
());
XML
::
gotoEndElementOfTag
(
r
,
tag
);
// background
}
else
if
(
tag
==
Tag
::
Background
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment