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
6d823577
Commit
6d823577
authored
3 months ago
by
Mikhail Svechnikov
Browse files
Options
Downloads
Plain Diff
[m.0] Ask about data and upd instrument view (
#1051
) (Closes
#1051
)
Merging branch 'm.0' into 'main'. See merge request
!2792
parents
e42b01e0
9f5e92b2
No related branches found
No related tags found
1 merge request
!2792
Ask about data and upd instrument view (#1051)
Pipeline
#179159
passed
3 months ago
Stage: build
Changes
2
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
GUI/Model/Project/ProjectDocument.h
+0
-1
0 additions, 1 deletion
GUI/Model/Project/ProjectDocument.h
GUI/View/View/InstrumentView.cpp
+8
-3
8 additions, 3 deletions
GUI/View/View/InstrumentView.cpp
with
8 additions
and
4 deletions
GUI/Model/Project/ProjectDocument.h
+
0
−
1
View file @
6d823577
...
@@ -79,7 +79,6 @@ public:
...
@@ -79,7 +79,6 @@ public:
signals
:
signals
:
void
modifiedStateChanged
();
void
modifiedStateChanged
();
void
modelChanged
();
void
sampleChanged
();
void
sampleChanged
();
private
:
private
:
...
...
This diff is collapsed.
Click to expand it.
GUI/View/View/InstrumentView.cpp
+
8
−
3
View file @
6d823577
...
@@ -20,6 +20,7 @@
...
@@ -20,6 +20,7 @@
#include
"GUI/Model/Sim/InstrumentItems.h"
#include
"GUI/Model/Sim/InstrumentItems.h"
#include
"GUI/Model/Sim/InstrumentsSet.h"
#include
"GUI/Model/Sim/InstrumentsSet.h"
#include
"GUI/View/IO/ComponentRW.h"
#include
"GUI/View/IO/ComponentRW.h"
#include
"GUI/View/Info/MessageBox.h"
#include
"GUI/View/Instrument/DepthprobeInstrumentEditor.h"
#include
"GUI/View/Instrument/DepthprobeInstrumentEditor.h"
#include
"GUI/View/Instrument/OffspecInstrumentEditor.h"
#include
"GUI/View/Instrument/OffspecInstrumentEditor.h"
#include
"GUI/View/Instrument/Scatter2DInstrumentEditor.h"
#include
"GUI/View/Instrument/Scatter2DInstrumentEditor.h"
...
@@ -125,9 +126,13 @@ void InstrumentView::createActions(QToolBar* toolbar)
...
@@ -125,9 +126,13 @@ void InstrumentView::createActions(QToolBar* toolbar)
m_adapt_action
->
setToolTip
(
"Take axes from current data file"
);
m_adapt_action
->
setToolTip
(
"Take axes from current data file"
);
toolbar
->
addAction
(
m_adapt_action
);
toolbar
->
addAction
(
m_adapt_action
);
connect
(
m_adapt_action
,
&
QAction
::
triggered
,
[
this
]
{
connect
(
m_adapt_action
,
&
QAction
::
triggered
,
[
this
]
{
ASSERT
(
gDoc
->
datafiles
()
->
currentItem
());
const
DatafileItem
*
current_data
=
gDoc
->
datafiles
()
->
currentItem
();
m_set
->
currentItem
()
->
updateToRealData
(
gDoc
->
datafiles
()
->
currentItem
());
ASSERT
(
current_data
);
emit
gDoc
->
modelChanged
();
if
(
!
GUI
::
Message
::
question
(
"Adapt instrument"
,
"Adapt instrument dimensions to data"
,
QString
(
"%1?"
).
arg
(
current_data
->
name
()),
"Yes"
,
"No"
))
return
;
m_set
->
currentItem
()
->
updateToRealData
(
current_data
);
m_scroll_area
->
setWidget
(
createEditor
(
m_set
->
currentItem
()));
});
});
m_save_action
=
new
QAction
(
"Save as XML"
,
this
);
m_save_action
=
new
QAction
(
"Save as XML"
,
this
);
...
...
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