Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
mantidproject
mantid
Commits
c0d047d4
Commit
c0d047d4
authored
Dec 11, 2019
by
Anthony Lim
Browse files
refs #26904 rename ALFView_* to more sensible names
parent
d13457cc
Changes
9
Hide whitespace changes
Inline
Side-by-side
qt/scientific_interfaces/Direct/ALF
View_m
odel.cpp
→
qt/scientific_interfaces/Direct/ALF
CustomInstrumentM
odel.cpp
View file @
c0d047d4
...
...
@@ -5,7 +5,7 @@
// & Institut Laue - Langevin
// SPDX - License - Identifier: GPL - 3.0 +
#include
"ALF
View_m
odel.h"
#include
"ALF
CustomInstrumentM
odel.h"
#include
"MantidAPI/Algorithm.h"
#include
"MantidAPI/AlgorithmManager.h"
#include
"MantidAPI/AnalysisDataService.h"
...
...
@@ -25,7 +25,7 @@ using namespace Mantid::API;
namespace
MantidQt
{
namespace
CustomInterfaces
{
ALF
View_model
::
ALFView_m
odel
()
:
m_numberOfTubesInAverage
(
0
)
{
ALF
CustomInstrumentModel
::
ALFCustomInstrumentM
odel
()
:
m_numberOfTubesInAverage
(
0
)
{
m_tmpName
=
"ALF_tmp"
;
m_instrumentName
=
"ALF"
;
m_wsName
=
"ALFData"
;
...
...
@@ -38,7 +38,7 @@ ALFView_model::ALFView_model() : m_numberOfTubesInAverage(0) {
* @param name:: string name for ALF data
* @return std::pair<int,std::string>:: the run number and status
*/
std
::
pair
<
int
,
std
::
string
>
ALF
View_m
odel
::
loadData
(
const
std
::
string
&
name
)
{
std
::
pair
<
int
,
std
::
string
>
ALF
CustomInstrumentM
odel
::
loadData
(
const
std
::
string
&
name
)
{
auto
alg
=
AlgorithmManager
::
Instance
().
create
(
"Load"
);
alg
->
initialize
();
alg
->
setProperty
(
"Filename"
,
name
);
...
...
@@ -67,7 +67,7 @@ std::pair<int, std::string> ALFView_model::loadData(const std::string &name) {
* Loads data, normalise to current and then converts to d spacing
* @return pair<bool,bool>:: If the instrument is ALF, if it is d-spacing
*/
std
::
map
<
std
::
string
,
bool
>
ALF
View_m
odel
::
isDataValid
()
{
std
::
map
<
std
::
string
,
bool
>
ALF
CustomInstrumentM
odel
::
isDataValid
()
{
auto
ws
=
AnalysisDataService
::
Instance
().
retrieveWS
<
MatrixWorkspace
>
(
m_tmpName
);
bool
isItALF
=
false
;
...
...
@@ -88,7 +88,7 @@ std::map<std::string, bool> ALFView_model::isDataValid() {
* Transforms ALF data; normalise to current and then converts to d spacing
* If already d-space does nothing.
*/
void
ALF
View_m
odel
::
transformData
()
{
void
ALF
CustomInstrumentM
odel
::
transformData
()
{
auto
normAlg
=
AlgorithmManager
::
Instance
().
create
(
"NormaliseByCurrent"
);
normAlg
->
initialize
();
normAlg
->
setProperty
(
"InputWorkspace"
,
m_wsName
);
...
...
@@ -103,7 +103,7 @@ void ALFView_model::transformData() {
dSpacingAlg
->
execute
();
}
void
ALF
View_m
odel
::
storeSingleTube
(
const
std
::
string
&
name
)
{
void
ALF
CustomInstrumentM
odel
::
storeSingleTube
(
const
std
::
string
&
name
)
{
auto
alg
=
AlgorithmManager
::
Instance
().
create
(
"ScaleX"
);
alg
->
initialize
();
alg
->
setProperty
(
"InputWorkspace"
,
CURVES
);
...
...
@@ -120,12 +120,12 @@ void ALFView_model::storeSingleTube(const std::string &name) {
AnalysisDataService
::
Instance
().
remove
(
CURVES
);
}
std
::
string
ALF
View_m
odel
::
WSName
()
{
std
::
string
ALF
CustomInstrumentM
odel
::
WSName
()
{
std
::
string
name
=
m_instrumentName
+
std
::
to_string
(
getCurrentRun
());
return
EXTRACTEDWS
+
name
;
}
void
ALF
View_m
odel
::
averageTube
()
{
void
ALF
CustomInstrumentM
odel
::
averageTube
()
{
const
std
::
string
name
=
m_instrumentName
+
std
::
to_string
(
getCurrentRun
());
const
int
oldTotalNumber
=
m_numberOfTubesInAverage
;
// multiply up current average
...
...
@@ -158,11 +158,11 @@ void ALFView_model::averageTube() {
m_numberOfTubesInAverage
++
;
}
bool
ALF
View_m
odel
::
hasTubeBeenExtracted
(
const
std
::
string
&
name
)
{
bool
ALF
CustomInstrumentM
odel
::
hasTubeBeenExtracted
(
const
std
::
string
&
name
)
{
return
AnalysisDataService
::
Instance
().
doesExist
(
EXTRACTEDWS
+
name
);
}
bool
ALF
View_m
odel
::
extractTubeConditon
(
std
::
map
<
std
::
string
,
bool
>
tabBools
)
{
bool
ALF
CustomInstrumentM
odel
::
extractTubeConditon
(
std
::
map
<
std
::
string
,
bool
>
tabBools
)
{
try
{
bool
ifCurve
=
(
tabBools
.
find
(
"plotStored"
)
->
second
||
...
...
@@ -173,7 +173,7 @@ bool ALFView_model::extractTubeConditon(std::map<std::string, bool> tabBools) {
}
}
bool
ALF
View_m
odel
::
averageTubeConditon
(
std
::
map
<
std
::
string
,
bool
>
tabBools
)
{
bool
ALF
CustomInstrumentM
odel
::
averageTubeConditon
(
std
::
map
<
std
::
string
,
bool
>
tabBools
)
{
try
{
bool
ifCurve
=
(
tabBools
.
find
(
"plotStored"
)
->
second
||
...
...
@@ -186,12 +186,12 @@ bool ALFView_model::averageTubeConditon(std::map<std::string, bool> tabBools) {
return
false
;
}
}
void
ALF
View_m
odel
::
extractSingleTube
()
{
void
ALF
CustomInstrumentM
odel
::
extractSingleTube
()
{
storeSingleTube
(
m_instrumentName
+
std
::
to_string
(
getCurrentRun
()));
m_numberOfTubesInAverage
=
1
;
}
CompositeFunction_sptr
ALF
View_m
odel
::
getDefaultFunction
()
{
CompositeFunction_sptr
ALF
CustomInstrumentM
odel
::
getDefaultFunction
()
{
CompositeFunction_sptr
composite
=
boost
::
dynamic_pointer_cast
<
Mantid
::
API
::
CompositeFunction
>
(
...
...
qt/scientific_interfaces/Direct/ALF
View_m
odel.h
→
qt/scientific_interfaces/Direct/ALF
CustomInstrumentM
odel.h
View file @
c0d047d4
...
...
@@ -17,11 +17,11 @@
namespace
MantidQt
{
namespace
CustomInterfaces
{
class
ALF
View_m
odel
:
public
MantidWidgets
::
BaseCustomInstrumentModel
{
class
ALF
CustomInstrumentM
odel
:
public
MantidWidgets
::
BaseCustomInstrumentModel
{
public:
ALF
View_m
odel
();
virtual
~
ALF
View_m
odel
(){};
ALF
CustomInstrumentM
odel
();
virtual
~
ALF
CustomInstrumentM
odel
(){};
std
::
pair
<
int
,
std
::
string
>
loadData
(
const
std
::
string
&
name
)
override
;
std
::
map
<
std
::
string
,
bool
>
isDataValid
();
void
transformData
();
...
...
qt/scientific_interfaces/Direct/ALF
View_p
resenter.cpp
→
qt/scientific_interfaces/Direct/ALF
CustomInstrumentP
resenter.cpp
View file @
c0d047d4
...
...
@@ -4,9 +4,9 @@
// NScD Oak Ridge National Laboratory, European Spallation Source
// & Institut Laue - Langevin
// SPDX - License - Identifier: GPL - 3.0 +
#include
"ALF
View_p
resenter.h"
#include
"ALF
View_m
odel.h"
#include
"ALF
View_v
iew.h"
#include
"ALF
CustomInstrumentP
resenter.h"
#include
"ALF
CustomInstrumentM
odel.h"
#include
"ALF
CustomInstrumentV
iew.h"
#include
"MantidQtWidgets/InstrumentView/PlotFitAnalysisPanePresenter.h"
#include
"MantidAPI/FileFinder.h"
...
...
@@ -16,7 +16,7 @@
namespace
MantidQt
{
namespace
CustomInterfaces
{
ALF
View_presenter
::
ALFView_presenter
(
ALFView_view
*
view
,
ALFView_m
odel
*
model
,
ALF
CustomInstrumentPresenter
::
ALFCustomInstrumentPresenter
(
ALFCustomInstrumentView
*
view
,
ALFCustomInstrumentM
odel
*
model
,
MantidWidgets
::
PlotFitAnalysisPanePresenter
*
analysisPane
)
:
BaseCustomInstrumentPresenter
(
view
,
model
,
analysisPane
->
getView
()),
m_view
(
view
),
m_model
(
model
),
m_analysisPane
(
analysisPane
),
...
...
@@ -24,18 +24,18 @@ ALFView_presenter::ALFView_presenter(ALFView_view *view, ALFView_model *model,
addInstrument
();
}
void
ALF
View_p
resenter
::
addInstrument
()
{
void
ALF
CustomInstrumentP
resenter
::
addInstrument
()
{
auto
setUp
=
setupALFInstrument
();
initLayout
(
&
setUp
);
}
void
ALF
View_p
resenter
::
setUpInstrumentAnalysisSplitter
()
{
void
ALF
CustomInstrumentP
resenter
::
setUpInstrumentAnalysisSplitter
()
{
CompositeFunction_sptr
composite
=
m_model
->
getDefaultFunction
();
m_analysisPane
->
addFunction
(
composite
);
m_view
->
setupAnalysisPane
(
m_analysisPane
->
getView
());
}
void
ALF
View_p
resenter
::
loadSideEffects
()
{
m_analysisPane
->
clearCurrentWS
();
}
void
ALF
CustomInstrumentP
resenter
::
loadSideEffects
()
{
m_analysisPane
->
clearCurrentWS
();
}
typedef
std
::
pair
<
std
::
string
,
std
::
vector
<
std
::
function
<
bool
(
std
::
map
<
std
::
string
,
bool
>
)
>>>
...
...
@@ -49,7 +49,7 @@ typedef std::vector<std::tuple<std::string, Observer *>>
instrumentObserverOptions> : a pair of the conditions and observers
*/
std
::
pair
<
instrumentSetUp
,
instrumentObserverOptions
>
ALF
View_p
resenter
::
setupALFInstrument
()
{
ALF
CustomInstrumentP
resenter
::
setupALFInstrument
()
{
m_extractSingleTubeObserver
=
new
VoidObserver
();
m_averageTubeObserver
=
new
VoidObserver
();
...
...
@@ -62,10 +62,10 @@ ALFView_presenter::setupALFInstrument() {
// set up custom context menu conditions
std
::
function
<
bool
(
std
::
map
<
std
::
string
,
bool
>
)
>
extractConditionBinder
=
std
::
bind
(
&
ALF
View_m
odel
::
extractTubeConditon
,
m_model
,
std
::
bind
(
&
ALF
CustomInstrumentM
odel
::
extractTubeConditon
,
m_model
,
std
::
placeholders
::
_1
);
std
::
function
<
bool
(
std
::
map
<
std
::
string
,
bool
>
)
>
averageTubeConditonBinder
=
std
::
bind
(
&
ALF
View_m
odel
::
averageTubeConditon
,
m_model
,
std
::
bind
(
&
ALF
CustomInstrumentM
odel
::
averageTubeConditon
,
m_model
,
std
::
placeholders
::
_1
);
binders
.
emplace_back
(
extractConditionBinder
);
...
...
@@ -75,7 +75,7 @@ ALFView_presenter::setupALFInstrument() {
// set up single tube extract
std
::
function
<
void
()
>
extractSingleTubeBinder
=
std
::
bind
(
&
ALF
View_p
resenter
::
extractSingleTube
,
this
);
// binder for slot
std
::
bind
(
&
ALF
CustomInstrumentP
resenter
::
extractSingleTube
,
this
);
// binder for slot
m_extractSingleTubeObserver
->
setSlot
(
extractSingleTubeBinder
);
// add slot to observer
std
::
tuple
<
std
::
string
,
Observer
*>
tmp
=
std
::
make_tuple
(
...
...
@@ -84,7 +84,7 @@ ALFView_presenter::setupALFInstrument() {
// set up average tube
std
::
function
<
void
()
>
averageTubeBinder
=
std
::
bind
(
&
ALF
View_p
resenter
::
averageTube
,
this
);
std
::
bind
(
&
ALF
CustomInstrumentP
resenter
::
averageTube
,
this
);
m_averageTubeObserver
->
setSlot
(
averageTubeBinder
);
tmp
=
std
::
make_tuple
(
"averageTube"
,
m_averageTubeObserver
);
customInstrumentOptions
.
emplace_back
(
tmp
);
...
...
@@ -92,13 +92,13 @@ ALFView_presenter::setupALFInstrument() {
return
std
::
make_pair
(
setUpContextConditions
,
customInstrumentOptions
);
}
void
ALF
View_p
resenter
::
extractSingleTube
()
{
void
ALF
CustomInstrumentP
resenter
::
extractSingleTube
()
{
m_model
->
extractSingleTube
();
const
std
::
string
WSName
=
m_model
->
WSName
();
m_analysisPane
->
addSpectrum
(
WSName
);
}
void
ALF
View_p
resenter
::
averageTube
()
{
void
ALF
CustomInstrumentP
resenter
::
averageTube
()
{
m_model
->
averageTube
();
const
std
::
string
WSName
=
m_model
->
WSName
();
m_analysisPane
->
addSpectrum
(
WSName
);
...
...
qt/scientific_interfaces/Direct/ALF
View_p
resenter.h
→
qt/scientific_interfaces/Direct/ALF
CustomInstrumentP
resenter.h
View file @
c0d047d4
...
...
@@ -10,8 +10,8 @@
#include
"MantidQtWidgets/InstrumentView/BaseCustomInstrumentPresenter.h"
#include
"MantidQtWidgets/InstrumentView/PlotFitAnalysisPanePresenter.h"
#include
"ALF
View_m
odel.h"
#include
"ALF
View_v
iew.h"
#include
"ALF
CustomInstrumentM
odel.h"
#include
"ALF
CustomInstrumentV
iew.h"
#include
"DllConfig.h"
#include
"MantidQtWidgets/Common/ObserverPattern.h"
...
...
@@ -20,14 +20,14 @@
namespace
MantidQt
{
namespace
CustomInterfaces
{
class
MANTIDQT_DIRECT_DLL
ALF
View_p
resenter
class
MANTIDQT_DIRECT_DLL
ALF
CustomInstrumentP
resenter
:
public
MantidWidgets
::
BaseCustomInstrumentPresenter
{
Q_OBJECT
public:
ALF
View_presenter
(
ALFView_view
*
view
,
ALFView_m
odel
*
model
,
ALF
CustomInstrumentPresenter
(
ALFCustomInstrumentView
*
view
,
ALFCustomInstrumentM
odel
*
model
,
MantidWidgets
::
PlotFitAnalysisPanePresenter
*
analysisPane
);
~
ALF
View_p
resenter
()
{
~
ALF
CustomInstrumentP
resenter
()
{
delete
m_extractSingleTubeObserver
;
delete
m_averageTubeObserver
;
delete
m_analysisPane
;
...
...
@@ -47,8 +47,8 @@ private:
void
extractSingleTube
();
void
averageTube
();
ALF
View_v
iew
*
m_view
;
ALF
View_m
odel
*
m_model
;
ALF
CustomInstrumentV
iew
*
m_view
;
ALF
CustomInstrumentM
odel
*
m_model
;
MantidWidgets
::
PlotFitAnalysisPanePresenter
*
m_analysisPane
;
VoidObserver
*
m_extractSingleTubeObserver
;
VoidObserver
*
m_averageTubeObserver
;
...
...
qt/scientific_interfaces/Direct/ALF
View_v
iew.cpp
→
qt/scientific_interfaces/Direct/ALF
CustomInstrumentV
iew.cpp
View file @
c0d047d4
...
...
@@ -4,7 +4,7 @@
// NScD Oak Ridge National Laboratory, European Spallation Source
// & Institut Laue - Langevin
// SPDX - License - Identifier: GPL - 3.0 +
#include
"ALF
View_v
iew.h"
#include
"ALF
CustomInstrumentV
iew.h"
#include
"MantidQtWidgets/InstrumentView/InstrumentWidgetPickTab.h"
#include
<QMessageBox>
...
...
@@ -15,7 +15,7 @@
namespace
MantidQt
{
namespace
CustomInterfaces
{
ALF
View_view
::
ALFView_v
iew
(
const
std
::
string
&
instrument
,
QWidget
*
parent
)
ALF
CustomInstrumentView
::
ALFCustomInstrumentV
iew
(
const
std
::
string
&
instrument
,
QWidget
*
parent
)
:
MantidWidgets
::
BaseCustomInstrumentView
(
instrument
,
parent
),
m_extractSingleTubeObservable
(
nullptr
),
m_averageTubeObservable
(
nullptr
),
m_extractAction
(
nullptr
),
m_averageAction
(
nullptr
),
...
...
@@ -23,7 +23,7 @@ ALFView_view::ALFView_view(const std::string &instrument, QWidget *parent)
m_helpPage
=
"ALF View"
;
}
void
ALF
View_v
iew
::
setUpInstrument
(
void
ALF
CustomInstrumentV
iew
::
setUpInstrument
(
const
std
::
string
&
fileName
,
std
::
vector
<
std
::
function
<
bool
(
std
::
map
<
std
::
string
,
bool
>
)
>>
&
binders
)
{
...
...
@@ -52,27 +52,27 @@ void ALFView_view::setUpInstrument(
setInstrumentWidget
(
instrumentWidget
);
}
void
ALF
View_v
iew
::
extractSingleTube
()
{
void
ALF
CustomInstrumentV
iew
::
extractSingleTube
()
{
MantidWidgets
::
InstrumentWidget
*
instrumentView
=
getInstrumentView
();
instrumentView
->
getPickTab
()
->
savePlotToWorkspace
();
m_extractSingleTubeObservable
->
notify
();
}
void
ALF
View_v
iew
::
averageTube
()
{
void
ALF
CustomInstrumentV
iew
::
averageTube
()
{
MantidWidgets
::
InstrumentWidget
*
instrumentView
=
getInstrumentView
();
instrumentView
->
getPickTab
()
->
savePlotToWorkspace
();
m_averageTubeObservable
->
notify
();
}
void
ALF
View_v
iew
::
observeExtractSingleTube
(
Observer
*
listner
)
{
void
ALF
CustomInstrumentV
iew
::
observeExtractSingleTube
(
Observer
*
listner
)
{
m_extractSingleTubeObservable
->
attach
(
listner
);
}
void
ALF
View_v
iew
::
observeAverageTube
(
Observer
*
listner
)
{
void
ALF
CustomInstrumentV
iew
::
observeAverageTube
(
Observer
*
listner
)
{
m_averageTubeObservable
->
attach
(
listner
);
}
void
ALF
View_v
iew
::
addObserver
(
std
::
tuple
<
std
::
string
,
Observer
*>
&
listener
)
{
void
ALF
CustomInstrumentV
iew
::
addObserver
(
std
::
tuple
<
std
::
string
,
Observer
*>
&
listener
)
{
if
(
std
::
get
<
0
>
(
listener
)
==
"singleTube"
)
{
observeExtractSingleTube
(
std
::
get
<
1
>
(
listener
));
}
else
if
(
std
::
get
<
0
>
(
listener
)
==
"averageTube"
)
{
...
...
@@ -80,14 +80,14 @@ void ALFView_view::addObserver(std::tuple<std::string, Observer *> &listener) {
}
}
void
ALF
View_v
iew
::
setupAnalysisPane
(
MantidWidgets
::
PlotFitAnalysisPaneView
*
analysis
)
{
void
ALF
CustomInstrumentV
iew
::
setupAnalysisPane
(
MantidWidgets
::
PlotFitAnalysisPaneView
*
analysis
)
{
// keep a copy here so we can use a custom class
m_analysisPane
=
analysis
;
// just adds it to the view
BaseCustomInstrumentView
::
setupInstrumentAnalysisSplitters
(
analysis
);
}
void
ALF
View_v
iew
::
addSpectrum
(
std
::
string
wsName
)
{
void
ALF
CustomInstrumentV
iew
::
addSpectrum
(
std
::
string
wsName
)
{
m_analysisPane
->
addSpectrum
(
wsName
);
}
...
...
qt/scientific_interfaces/Direct/ALF
View_v
iew.h
→
qt/scientific_interfaces/Direct/ALF
CustomInstrumentV
iew.h
View file @
c0d047d4
...
...
@@ -4,8 +4,8 @@
// NScD Oak Ridge National Laboratory, European Spallation Source
// & Institut Laue - Langevin
// SPDX - License - Identifier: GPL - 3.0 +
#ifndef MANTIDQT_CUSTOMINTERFACES_ALF
VIEW_VIEW
_H_
#define MANTIDQT_CUSTOMINTERFACES_ALF
VIEW_VIEW
_H_
#ifndef MANTIDQT_CUSTOMINTERFACES_ALF
CustomInstrumentView
_H_
#define MANTIDQT_CUSTOMINTERFACES_ALF
CustomInstrumentView
_H_
#include
"MantidQtWidgets/InstrumentView/BaseCustomInstrumentView.h"
#include
"DllConfig.h"
...
...
@@ -21,11 +21,11 @@
namespace
MantidQt
{
namespace
CustomInterfaces
{
class
ALF
View_v
iew
:
public
MantidWidgets
::
BaseCustomInstrumentView
{
class
ALF
CustomInstrumentV
iew
:
public
MantidWidgets
::
BaseCustomInstrumentView
{
Q_OBJECT
public:
explicit
ALF
View_v
iew
(
const
std
::
string
&
instrument
,
explicit
ALF
CustomInstrumentV
iew
(
const
std
::
string
&
instrument
,
QWidget
*
parent
=
nullptr
);
void
observeExtractSingleTube
(
Observer
*
listner
);
void
observeAverageTube
(
Observer
*
listner
);
...
...
@@ -53,4 +53,4 @@ private:
}
// namespace CustomInterfaces
}
// namespace MantidQt
#endif
/* MANTIDQT_CUSTOMINTERFACES_ALF
VIEW_VIEW
_H_ */
#endif
/* MANTIDQT_CUSTOMINTERFACES_ALF
CustomInstrumentView
_H_ */
qt/scientific_interfaces/Direct/ALFView.cpp
View file @
c0d047d4
...
...
@@ -5,8 +5,8 @@
// & Institut Laue - Langevin
// SPDX - License - Identifier: GPL - 3.0 +
#include
"ALFView.h"
#include
"ALF
View_m
odel.h"
#include
"ALF
View_p
resenter.h"
#include
"ALF
CustomInstrumentM
odel.h"
#include
"ALF
CustomInstrumentP
resenter.h"
#include
"MantidQtWidgets/InstrumentView/PlotFitAnalysisPaneModel.h"
#include
"MantidQtWidgets/InstrumentView/PlotFitAnalysisPaneView.h"
...
...
@@ -24,14 +24,14 @@ Mantid::Kernel::Logger g_log("ALFView");
ALFView
::
ALFView
(
QWidget
*
parent
)
:
UserSubWindow
(
parent
),
m_view
(
nullptr
),
m_presenter
(
nullptr
),
m_analysisPane
(
nullptr
)
{
m_model
=
new
ALF
View_m
odel
();
m_view
=
new
ALF
View_v
iew
(
m_model
->
getInstrument
(),
this
);
m_model
=
new
ALF
CustomInstrumentM
odel
();
m_view
=
new
ALF
CustomInstrumentV
iew
(
m_model
->
getInstrument
(),
this
);
auto
analysisView
=
new
MantidWidgets
::
PlotFitAnalysisPaneView
(
-
15.0
,
15.0
,
m_view
);
auto
analysisModel
=
new
MantidWidgets
::
PlotFitAnalysisPaneModel
();
m_analysisPane
=
new
MantidWidgets
::
PlotFitAnalysisPanePresenter
(
analysisView
,
analysisModel
);
m_presenter
=
new
ALF
View_p
resenter
(
m_view
,
m_model
,
m_analysisPane
);
m_presenter
=
new
ALF
CustomInstrumentP
resenter
(
m_view
,
m_model
,
m_analysisPane
);
}
void
ALFView
::
initLayout
()
{
this
->
setCentralWidget
(
m_view
);
}
...
...
qt/scientific_interfaces/Direct/ALFView.h
View file @
c0d047d4
...
...
@@ -7,9 +7,9 @@
#ifndef MANTIDQT_CUSTOMINTERFACES_ALFVIEW_H_
#define MANTIDQT_CUSTOMINTERFACES_ALFVIEW_H_
#include
"ALF
View_m
odel.h"
#include
"ALF
View_p
resenter.h"
#include
"ALF
View_v
iew.h"
#include
"ALF
CustomInstrumentM
odel.h"
#include
"ALF
CustomInstrumentP
resenter.h"
#include
"ALF
CustomInstrumentV
iew.h"
#include
"DllConfig.h"
#include
"MantidQtWidgets/Common/ObserverPattern.h"
#include
"MantidQtWidgets/Common/UserSubWindow.h"
...
...
@@ -32,9 +32,9 @@ protected:
void
initLayout
()
override
;
private:
ALF
View_v
iew
*
m_view
;
ALF
View_m
odel
*
m_model
;
ALF
View_p
resenter
*
m_presenter
;
ALF
CustomInstrumentV
iew
*
m_view
;
ALF
CustomInstrumentM
odel
*
m_model
;
ALF
CustomInstrumentP
resenter
*
m_presenter
;
MantidWidgets
::
PlotFitAnalysisPanePresenter
*
m_analysisPane
;
};
}
// namespace CustomInterfaces
...
...
qt/scientific_interfaces/Direct/CMakeLists.txt
View file @
c0d047d4
set
(
SRC_FILES
ALFView.cpp
ALF
View_v
iew.cpp
ALF
View_p
resenter.cpp
ALF
View_m
odel.cpp
)
ALF
CustomInstrumentV
iew.cpp
ALF
CustomInstrumentP
resenter.cpp
ALF
CustomInstrumentM
odel.cpp
)
set
(
MOC_FILES
ALFView.h
ALF
View_v
iew.h
ALF
View_p
resenter.h
)
ALF
CustomInstrumentV
iew.h
ALF
CustomInstrumentP
resenter.h
)
set
(
INC_FILES
DllConfig.h
)
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment