Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Marc SCHWEITZER
sight
Commits
e2a9386b
Commit
e2a9386b
authored
Jan 10, 2018
by
fw4splbot
Browse files
merge(dev): release 13.1.0
parents
2a42ae2d
496f5df8
Changes
85
Hide whitespace changes
Inline
Side-by-side
Bundles/LeafActivity/3DVisualizationActivity/rc/configurations/3DNegatoWithAcq.xml
View file @
e2a9386b
...
...
@@ -7,8 +7,6 @@
<param
name=
"landmarks"
/>
<param
name=
"patient_name"
default=
""
/>
<param
name=
"orientation"
default=
"axial"
/>
<!-- axial, frontal, sagittal -->
<param
name=
"ModelRepresentationChannel"
/>
<param
name=
"ModelDisplayChannel"
/>
<param
name=
"CrossTypeChannel"
default=
"crossTypeChannel"
/>
<param
name=
"PickingChannel"
default=
"pickingChannel"
/>
<param
name=
"setSagittalCameraChannel"
/>
...
...
@@ -176,14 +174,6 @@
<slot>
multiDistances/createDistance
</slot>
</connect>
<connect
channel=
"${ModelRepresentationChannel}"
>
<slot>
modelSeries/updateNormalMode
</slot>
</connect>
<connect
channel=
"${ModelDisplayChannel}"
>
<slot>
modelSeries/showReconstructions
</slot>
</connect>
<connect
channel=
"${PickingChannel}"
>
<signal>
pickerInteractor/picked
</signal>
</connect>
...
...
Bundles/LeafActivity/3DVisualizationActivity/rc/configurations/3DVisualization.xml
View file @
e2a9386b
...
...
@@ -129,8 +129,6 @@
<appConfig
id=
"OrganManagerWithSeries"
/>
<inout
key=
"ORGAN_MANAGER_MODELSERIES"
uid=
"${modelSeries}"
/>
<parameter
replace=
"ICON_PATH"
by=
"${ICON_PATH}"
/>
<parameter
replace=
"ModelRepresentationChannel"
by=
"ModelRepresentationChannel"
/>
<parameter
replace=
"ModelDisplayChannel"
by=
"ModelDisplayChannel"
/>
</service>
<service
uid=
"cfgNegato1"
type=
"::fwServices::SConfigController"
>
...
...
@@ -141,8 +139,6 @@
<parameter
replace=
"orientation"
by=
"axial"
/>
<parameter
replace=
"WID_PARENT"
by=
"view_negato1"
/>
<parameter
replace=
"patient_name"
by=
"${patient_name}"
/>
<parameter
replace=
"ModelRepresentationChannel"
by=
"ModelRepresentationChannel"
/>
<parameter
replace=
"ModelDisplayChannel"
by=
"ModelDisplayChannel"
/>
<parameter
replace=
"PickingChannel"
by=
"pickerChannel"
/>
<parameter
replace=
"CrossTypeChannel"
by=
"crossTypeChannel"
/>
<parameter
replace=
"setSagittalCameraChannel"
by=
"setSagittalCameraChannel"
/>
...
...
@@ -292,10 +288,6 @@
<signal>
action_AxialViewMPR3D/triggered
</signal>
</connect>
<!-- Shared channels between 3DNegatoWithAcq and OrganManagerWithSeries -->
<connect
channel=
"ModelDisplayChannel"
/>
<connect
channel=
"ModelRepresentationChannel"
/>
<!-- START AND STOP SERVICES -->
<start
uid=
"mainView"
/>
<start
uid=
"extractImage"
/>
...
...
Bundles/LeafActivity/3DVisualizationActivity/rc/configurations/ManageOrganWithSeries.xml
View file @
e2a9386b
...
...
@@ -4,8 +4,7 @@
<param
name=
"ORGAN_MANAGER_MODELSERIES"
/>
<param
name=
"CLOSE_CONFIG_CHANNEL"
default=
"DummyChannel"
/>
<!-- defined by SConfigLauncher -->
<param
name=
"ICON_PATH"
/>
<param
name=
"ModelRepresentationChannel"
/>
<param
name=
"ModelDisplayChannel"
/>
<param
name=
"WindowTitle"
default=
"Organs Manager"
/>
</parameters>
<config>
...
...
@@ -17,7 +16,7 @@
<window
onclose=
"notify"
/>
<gui>
<frame>
<name>
Organs Manager
</name>
<name>
${WindowTitle}
</name>
<icon>
${ICON_PATH}
</icon>
<style
mode=
"STAY_ON_TOP"
/>
</frame>
...
...
@@ -72,15 +71,6 @@
<signal>
organManagerFrame/closed
</signal>
</connect>
<connect
channel=
"${ModelDisplayChannel}"
>
<signal>
listOrganEditor/recDisplayModified
</signal>
<slot>
listOrganEditor/showReconstructions
</slot>
</connect>
<connect
channel=
"${ModelRepresentationChannel}"
>
<signal>
representationEditor/normalsModeModified
</signal>
</connect>
<!-- START AND STOP SERVICES -->
<start
uid=
"organManagerFrame"
/>
<start
uid=
"myUpdaterReconst"
/>
...
...
Bundles/LeafActivity/volumeRenderingActivity/rc/configurations/VolumeRendering.xml
View file @
e2a9386b
...
...
@@ -108,8 +108,6 @@
<appConfig
id=
"OrganManagerWithSeries"
/>
<inout
key=
"ORGAN_MANAGER_MODELSERIES"
uid=
"optionalModelSeries"
/>
<parameter
replace=
"ICON_PATH"
by=
"${ICON_PATH}"
/>
<parameter
replace=
"ModelRepresentationChannel"
by=
"ModelRepresentationChannel"
/>
<parameter
replace=
"ModelDisplayChannel"
by=
"ModelDisplayChannel"
/>
</service>
<service
uid=
"ActionSnapshotVR"
type=
"::uiVisu::action::SSnapshot"
/>
...
...
@@ -230,14 +228,6 @@
<slot>
snapshot1/snap
</slot>
</connect>
<connect
channel=
"ModelRepresentationChannel"
>
<slot>
modelSeriesAdaptor/updateNormalMode
</slot>
</connect>
<connect
channel=
"ModelDisplayChannel"
>
<slot>
modelSeriesAdaptor/showReconstructions
</slot>
</connect>
<!-- START AND STOP SERVICES -->
<start
uid=
"computeHistogram"
/>
<start
uid=
"LockImageSrv"
/>
...
...
Bundles/LeafRegistration/basicRegistration/include/basicRegistration/SPointListRegistration.hpp
View file @
e2a9386b
/* ***** BEGIN LICENSE BLOCK *****
* FW4SPL - Copyright (C) IRCAD, 2009-201
7
.
* FW4SPL - Copyright (C) IRCAD, 2009-201
8
.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
...
...
@@ -18,12 +18,12 @@ namespace basicRegistration
/**
* @brief Register a point list against a reference point list. Each point in the list to register is matched
* with a point in the reference list according to
its label
.
* with a point in the reference list according to
their order or to their labels if they have any
.
* The output is a transformation matrix.
* @section Signals Signals
* - \b errorComputed(double): emitted when registration error is computed.
* @section Slots Slots
* - \b changeMode(
std::string,
std::string): called when registration mode is changed.
* - \b changeMode(std::string): called when registration mode is changed.
* Three modes are available : RIGID, SIMILARITY or AFFINE
* @section XML XML Configuration
* @code{.xml}
...
...
@@ -31,6 +31,7 @@ namespace basicRegistration
<inout key="registeredPL" uid="..." />
<inout key="referencePL" uid="..." />
<inout key="output" uid="..." />
<config mode="similarity" />
</service>
@endcode
* @subsection In-Out In-Out
...
...
@@ -38,6 +39,9 @@ namespace basicRegistration
* - \b referencePL [::fwData::PointList]: List containing the reference points to match with the points to register.
* - \b output [::fwData::TransformationMatrix3D]: Transformation matrix between the source and target points.
*
* @subsection Configuration Configuration
* - \b mode (optional, values=rigid|similarity|affine, default=rigid): registration mode.
*
*/
class
BASICREGISTRATION_CLASS_API
SPointListRegistration
:
public
::
fwServices
::
IController
{
...
...
@@ -93,7 +97,7 @@ protected:
private:
///SLOT: changeMode
void
changeMode
(
std
::
string
_value
,
std
::
string
_key
);
void
changeMode
(
std
::
string
_value
);
/// Key source point list
std
::
string
m_registeredPointsKey
;
...
...
Bundles/LeafRegistration/basicRegistration/src/basicRegistration/SPointListRegistration.cpp
View file @
e2a9386b
/* ***** BEGIN LICENSE BLOCK *****
* FW4SPL - Copyright (C) IRCAD, 2009-201
7
.
* FW4SPL - Copyright (C) IRCAD, 2009-201
8
.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
...
...
@@ -51,6 +51,27 @@ SPointListRegistration::~SPointListRegistration()
void
SPointListRegistration
::
configuring
()
{
const
ConfigType
config
=
this
->
getConfigTree
().
get_child
(
"config.<xmlattr>"
);
const
std
::
string
mode
=
config
.
get
<
std
::
string
>
(
"mode"
,
"rigid"
);
if
(
mode
==
"rigid"
)
{
m_registrationMode
=
RIGID
;
}
else
if
(
mode
==
"similarity"
)
{
m_registrationMode
=
SIMILARITY
;
}
else
if
(
mode
==
"affine"
)
{
m_registrationMode
=
AFFINE
;
}
else
{
SLM_ERROR
(
"Unknown registration mode: '"
+
mode
+
"', it must be 'rigid', 'similarity' or 'affine'."
" Defaulting to 'rigid'."
)
}
}
// ----------------------------------------------------------------------------
...
...
@@ -81,38 +102,59 @@ void SPointListRegistration::updating()
vtkSmartPointer
<
vtkPoints
>
sourcePts
=
vtkSmartPointer
<
vtkPoints
>::
New
();
vtkSmartPointer
<
vtkPoints
>
targetPts
=
vtkSmartPointer
<
vtkPoints
>::
New
();
// Match each point in both list according to the label
for
(
::
fwData
::
Point
::
sptr
pointRef
:
referencePL
->
getPoints
()
)
{
const
std
::
string
&
labelRef
=
pointRef
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
->
value
();
const
auto
&
firstPoint
=
referencePL
->
getCRefPoints
()[
0
];
for
(
::
fwData
::
Point
::
sptr
pointReg
:
registeredPL
->
getPoints
()
)
// If the points have labels ...
if
(
firstPoint
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
!=
nullptr
)
{
// ... Then match them according to that label.
for
(
::
fwData
::
Point
::
sptr
pointRef
:
referencePL
->
getPoints
()
)
{
const
std
::
string
&
labelRe
g
=
pointRe
g
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
->
value
();
const
std
::
string
&
labelRe
f
=
pointRe
f
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
->
value
();
if
(
labelRef
==
labelReg
)
for
(
::
fwData
::
Point
::
sptr
pointReg
:
registeredPL
->
getPoints
()
)
{
auto
coord
=
pointRef
->
getRefCoord
();
sourcePts
->
InsertNextPoint
(
coord
[
0
],
coord
[
1
],
coord
[
2
]);
OSLM_TRACE
(
"referencePL : "
<<
pointRef
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
->
value
()
);
OSLM_TRACE
(
"referencePL : "
<<
pointRef
->
getCoord
()[
0
]
<<
" "
<<
pointRef
->
getCoord
()[
1
]
<<
" "
<<
pointRef
->
getCoord
()[
2
]
);
coord
=
pointReg
->
getRefCoord
();
targetPts
->
InsertNextPoint
(
coord
[
0
],
coord
[
1
],
coord
[
2
]);
OSLM_TRACE
(
"registeredPL : "
<<
pointReg
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
->
value
()
);
OSLM_TRACE
(
"registeredPL : "
<<
pointReg
->
getCoord
()[
0
]
<<
" "
<<
pointReg
->
getCoord
()[
1
]
<<
" "
<<
pointReg
->
getCoord
()[
2
]
);
const
std
::
string
&
labelReg
=
pointReg
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
->
value
();
if
(
labelRef
==
labelReg
)
{
auto
coord
=
pointRef
->
getRefCoord
();
sourcePts
->
InsertNextPoint
(
coord
[
0
],
coord
[
1
],
coord
[
2
]);
OSLM_TRACE
(
"referencePL : "
<<
pointRef
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
->
value
()
);
OSLM_TRACE
(
"referencePL : "
<<
pointRef
->
getCoord
()[
0
]
<<
" "
<<
pointRef
->
getCoord
()[
1
]
<<
" "
<<
pointRef
->
getCoord
()[
2
]
);
coord
=
pointReg
->
getRefCoord
();
targetPts
->
InsertNextPoint
(
coord
[
0
],
coord
[
1
],
coord
[
2
]);
OSLM_TRACE
(
"registeredPL : "
<<
pointReg
->
getField
<
::
fwData
::
String
>
(
::
fwDataTools
::
fieldHelper
::
Image
::
m_labelId
)
->
value
()
);
OSLM_TRACE
(
"registeredPL : "
<<
pointReg
->
getCoord
()[
0
]
<<
" "
<<
pointReg
->
getCoord
()[
1
]
<<
" "
<<
pointReg
->
getCoord
()[
2
]
);
}
}
}
}
else
{
// ... Else match them according to their order.
for
(
const
auto
&
refPoint
:
referencePL
->
getCRefPoints
())
{
const
auto
&
coords
=
refPoint
->
getRefCoord
();
sourcePts
->
InsertNextPoint
(
coords
[
0
],
coords
[
1
],
coords
[
2
]);
}
for
(
const
auto
&
regPoint
:
registeredPL
->
getCRefPoints
())
{
const
auto
&
coords
=
regPoint
->
getRefCoord
();
targetPts
->
InsertNextPoint
(
coords
[
0
],
coords
[
1
],
coords
[
2
]);
}
}
landmarkTransform
->
SetSourceLandmarks
(
sourcePts
);
landmarkTransform
->
SetTargetLandmarks
(
targetPts
);
...
...
@@ -135,9 +177,9 @@ void SPointListRegistration::updating()
// Get the resulting transformation matrix (this matrix takes the source points to the target points)
vtkSmartPointer
<
vtkMatrix4x4
>
m
=
landmarkTransform
->
GetMatrix
();
m
->
Invert
();
for
(
s
ize
_t
l
=
0
;
l
<
4
;
++
l
)
for
(
s
td
::
uint8
_t
l
=
0
;
l
<
4
;
++
l
)
{
for
(
s
ize
_t
c
=
0
;
c
<
4
;
++
c
)
for
(
s
td
::
uint8
_t
c
=
0
;
c
<
4
;
++
c
)
{
matrix
->
setCoefficient
(
l
,
c
,
m
->
GetElement
(
l
,
c
));
}
...
...
@@ -198,7 +240,7 @@ void SPointListRegistration::swapping()
//----------------------------------------------------------------------------
void
SPointListRegistration
::
changeMode
(
std
::
string
_value
,
std
::
string
_key
)
void
SPointListRegistration
::
changeMode
(
std
::
string
_value
)
{
if
(
_value
==
"RIGID"
)
{
...
...
Bundles/LeafUI/guiQt/test/tu/include/GuiQtTest.hpp
View file @
e2a9386b
/* ***** BEGIN LICENSE BLOCK *****
* FW4SPL - Copyright (C) IRCAD, 2009-201
5
.
* FW4SPL - Copyright (C) IRCAD, 2009-201
7
.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
...
...
Bundles/LeafUI/guiQt/test/tu/rc/profile.xml
View file @
e2a9386b
...
...
@@ -16,6 +16,7 @@
<activate
id=
"Tuto01Basic"
/>
<activate
id=
"Tuto02DataServiceBasic"
/>
<start
id=
"visuVTKQt"
/>
<start
id=
"guiQt"
/>
</profile>
Bundles/LeafUI/uiIO/include/uiIO/action/SFolderSelector.hpp
0 → 100644
View file @
e2a9386b
/* ***** BEGIN LICENSE BLOCK *****
* FW4SPL - Copyright (C) IRCAD, 2009-2017.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
#ifndef __UIIO_ACTION_SFOLDERSELECTOR_HPP__
#define __UIIO_ACTION_SFOLDERSELECTOR_HPP__
#include
"uiIO/config.hpp"
#include
<fwGui/IActionSrv.hpp>
#include
<boost/filesystem/path.hpp>
namespace
uiIO
{
namespace
action
{
/**
* @brief Raise a pop-up dialog to select a directory, then send it via a signal.
*
* @section Signals Signals
* - \b folderSelector(::boost::filesystem::path) : Emitted when the directory is chosen.
*
* @section XML XML Configuration
*
* @code{.xml}
<service type="::uiIO::action::SFolderSelector" >
<dialogTitle>Select a folder</dialogTitle>
</service>
@endcode
* @subsection Configuration Configuration:
* - \b dialogTitle (optional): title of the dialog.
*/
class
UIIO_CLASS_API
SFolderSelector
:
public
::
fwGui
::
IActionSrv
{
public:
fwCoreServiceClassDefinitionsMacro
(
(
SFolderSelector
)(
::
fwGui
::
IActionSrv
)
)
/**
* @name Signals API
* @{
*/
typedef
::
fwCom
::
Signal
<
void
(
::
boost
::
filesystem
::
path
)
>
FolderSelectedSignalType
;
static
const
::
fwCom
::
Signals
::
SignalKeyType
s_FOLDER_SELECTED_SIG
;
/// @}
UIIO_API
SFolderSelector
()
noexcept
;
UIIO_API
virtual
~
SFolderSelector
()
noexcept
;
protected:
/// Do nothing
UIIO_API
void
configuring
()
override
;
/// Do nothing.
UIIO_API
void
starting
()
override
;
/// Show the dialog and send the signal with the chosen directory
UIIO_API
void
updating
()
override
;
/// Do nothing.
UIIO_API
void
stopping
()
override
;
private:
/// Optional title for the dialog
std
::
string
m_dialogTitle
;
};
}
// namespace action
}
// namespace uiIO
#endif // __UIIO_ACTION_SFOLDERSELECTOR_HPP__
Bundles/LeafUI/uiIO/src/uiIO/action/SFolderSelector.cpp
0 → 100644
View file @
e2a9386b
/* ***** BEGIN LICENSE BLOCK *****
* FW4SPL - Copyright (C) IRCAD, 2009-2017.
* Distributed under the terms of the GNU Lesser General Public License (LGPL) as
* published by the Free Software Foundation.
* ****** END LICENSE BLOCK ****** */
#include
"uiIO/action/SFolderSelector.hpp"
#include
<fwCom/Signal.hxx>
#include
<fwData/location/Folder.hpp>
#include
<fwGui/dialog/LocationDialog.hpp>
#include
<fwServices/macros.hpp>
namespace
uiIO
{
namespace
action
{
fwServicesRegisterMacro
(
::
fwGui
::
IActionSrv
,
::
uiIO
::
action
::
SFolderSelector
,
::
fwData
::
Object
);
const
::
fwCom
::
Signals
::
SignalKeyType
SFolderSelector
::
s_FOLDER_SELECTED_SIG
=
"folderSelected"
;
//------------------------------------------------------------------------------
SFolderSelector
::
SFolderSelector
(
)
noexcept
{
newSignal
<
FolderSelectedSignalType
>
(
s_FOLDER_SELECTED_SIG
);
}
//------------------------------------------------------------------------------
SFolderSelector
::~
SFolderSelector
()
noexcept
{
}
//------------------------------------------------------------------------------
void
SFolderSelector
::
configuring
()
{
const
auto
&
config
=
this
->
getConfigTree
();
m_dialogTitle
=
config
.
get
(
"dialogTitle"
,
"Select a folder"
);
}
//------------------------------------------------------------------------------
void
SFolderSelector
::
starting
()
{
}
//------------------------------------------------------------------------------
void
SFolderSelector
::
updating
(
)
{
static
::
boost
::
filesystem
::
path
_sDefaultPath
(
""
);
::
fwGui
::
dialog
::
LocationDialog
dialogFile
;
dialogFile
.
setTitle
(
m_dialogTitle
);
dialogFile
.
setDefaultLocation
(
::
fwData
::
location
::
Folder
::
New
(
_sDefaultPath
)
);
dialogFile
.
setOption
(
::
fwGui
::
dialog
::
ILocationDialog
::
READ
);
dialogFile
.
setType
(
::
fwGui
::
dialog
::
ILocationDialog
::
FOLDER
);
::
fwData
::
location
::
Folder
::
sptr
result
;
result
=
::
fwData
::
location
::
Folder
::
dynamicCast
(
dialogFile
.
show
()
);
if
(
result
)
{
auto
sig
=
this
->
signal
<
FolderSelectedSignalType
>
(
s_FOLDER_SELECTED_SIG
);
sig
->
asyncEmit
(
result
->
getFolder
());
}
}
//------------------------------------------------------------------------------
void
SFolderSelector
::
stopping
()
{
}
//------------------------------------------------------------------------------
//
}
// namespace action
}
// namespace uiIO
Bundles/LeafUI/uiMedDataQt/include/uiMedDataQt/editor/SModelSeriesList.hpp
View file @
e2a9386b
...
...
@@ -99,17 +99,12 @@ protected:
*/
virtual
void
configuring
()
override
;
/// Overrides
virtual
void
info
(
std
::
ostream
&
_sstream
)
override
;
typedef
std
::
map
<
std
::
string
,
ValueView
*
>
DisplayedInformation
;
void
updateReconstructions
();
void
fillTree
();
static
const
::
fwCom
::
Signals
::
SignalKeyType
s_REC_DISPLAY_MODIFIED__SIG
;
typedef
::
fwCom
::
Signal
<
void
(
bool
)
>
RecDisplayModifiedSignalType
;
static
const
::
fwCom
::
Signals
::
SignalKeyType
s_RECONSTRUCTION_SELECTED_SIG
;
typedef
::
fwCom
::
Signal
<
void
(
::
fwData
::
Object
::
sptr
)
>
ReconstructionSelectedSignalType
;
static
const
::
fwCom
::
Signals
::
SignalKeyType
s_EMPTIED_SELECTION_SIG
;
...
...
@@ -149,9 +144,6 @@ private:
bool
m_enableHideAll
;
/// Signal emitted when m_showCheckBox value changed
RecDisplayModifiedSignalType
::
sptr
m_sigRecDisplayModified
;
/// Signal emitted when a reconstruction is selected
ReconstructionSelectedSignalType
::
sptr
m_sigReconstructionSelected
;
...
...
Bundles/LeafUI/uiMedDataQt/src/uiMedDataQt/editor/SActivityWizard.cpp
View file @
e2a9386b
...
...
@@ -122,13 +122,14 @@ void SActivityWizard::configuring()
for
(
::
fwRuntime
::
ConfigurationElement
::
sptr
elt
:
cfg
)
{
std
::
string
type
=
elt
->
getAttributeValue
(
"type"
);
const
std
::
string
type
=
elt
->
getAttributeValue
(
"type"
);
SLM_ASSERT
(
"'series' attribute is missing"
,
!
type
.
empty
());
std
::
string
icon
=
elt
->
getAttributeValue
(
"icon"
);
const
std
::
string
icon
=
elt
->
getAttributeValue
(
"icon"
);
SLM_ASSERT
(
"'icon' attribute is missing"
,
!
icon
.
empty
());
m_objectIcons
[
type
]
=
icon
;
const
auto
file
=
::
fwRuntime
::
getResourceFilePath
(
icon
);
m_objectIcons
[
type
]
=
file
.
string
();
}
}
}
...
...
Bundles/LeafUI/uiMedDataQt/src/uiMedDataQt/editor/SModelSeriesList.cpp
View file @
e2a9386b
...
...
@@ -24,6 +24,8 @@
#include
<fwDataCamp/getObject.hpp>
#include
<fwDataTools/helper/Field.hpp>
#include
<fwGuiQt/container/QtContainer.hpp>
#include
<fwMedData/ModelSeries.hpp>
...
...
@@ -124,7 +126,6 @@ public:
fwServicesRegisterMacro
(
::
gui
::
editor
::
IEditor
,
::
uiMedDataQt
::
editor
::
SModelSeriesList
,
::
fwMedData
::
ModelSeries
);
const
::
fwCom
::
Signals
::
SignalKeyType
SModelSeriesList
::
s_REC_DISPLAY_MODIFIED__SIG
=
"recDisplayModified"
;
const
::
fwCom
::
Signals
::
SignalKeyType
SModelSeriesList
::
s_RECONSTRUCTION_SELECTED_SIG
=
"reconstructionSelected"
;
const
::
fwCom
::
Signals
::
SignalKeyType
SModelSeriesList
::
s_EMPTIED_SELECTION_SIG
=
"emptiedSelection"
;
const
::
fwCom
::
Slots
::
SlotKeyType
SModelSeriesList
::
s_SHOW_RECONSTRUCTIONS_SLOT
=
"showReconstructions"
;
...
...
@@ -133,7 +134,6 @@ SModelSeriesList::SModelSeriesList() noexcept :
m_tree
(
new
QTreeWidget
()),
m_enableHideAll
(
true
)
{
m_sigRecDisplayModified
=
newSignal
<
RecDisplayModifiedSignalType
>
(
s_REC_DISPLAY_MODIFIED__SIG
);
m_sigReconstructionSelected
=
newSignal
<
ReconstructionSelectedSignalType
>
(
s_RECONSTRUCTION_SELECTED_SIG
);
m_sigEmptiedSelection
=
newSignal
<
EmptiedSelectionSignalType
>
(
s_EMPTIED_SELECTION_SIG
);
...
...
@@ -275,12 +275,6 @@ void SModelSeriesList::swapping()
//------------------------------------------------------------------------------
void
SModelSeriesList
::
info
(
std
::
ostream
&
_sstream
)
{
}
//------------------------------------------------------------------------------
void
SModelSeriesList
::
updateReconstructions
()
{
::
fwGuiQt
::
container
::
QtContainer
::
sptr
qtContainer
...
...
@@ -342,7 +336,7 @@ void SModelSeriesList::fillTree()
//------------------------------------------------------------------------------
void
SModelSeriesList
::
onCurrentItemChanged
(
QTreeWidgetItem
*
current
,
QTreeWidgetItem
*
previous
)
void
SModelSeriesList
::
onCurrentItemChanged
(
QTreeWidgetItem
*
current
,
QTreeWidgetItem
*
)
{
SLM_ASSERT
(
"Current selected item is null"
,
current
);
std
::
string
id
=
current
->
data
(
0
,
Qt
::
UserRole
).
toString
().
toStdString
();
...
...
@@ -361,7 +355,7 @@ void SModelSeriesList::onCurrentItemChanged ( QTreeWidgetItem* current, int colu
//------------------------------------------------------------------------------
void
SModelSeriesList
::
onOrganChoiceVisibility
(
QTreeWidgetItem
*
item
,
int
column
)
void
SModelSeriesList
::
onOrganChoiceVisibility
(
QTreeWidgetItem
*
item
,
int
)
{
std
::
string
id
=
item
->
data
(
0
,
Qt
::
UserRole
).
toString
().
toStdString
();
::
fwData
::
Reconstruction
::
sptr
rec
=
::
fwData
::
Reconstruction
::
dynamicCast
(
::
fwTools
::
fwID
::
getObject
(
id
));
...
...
@@ -391,10 +385,10 @@ void SModelSeriesList::onShowReconstructions(int state )