Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
metexplore
MetExploreViz
Commits
6e747efb
Commit
6e747efb
authored
Apr 23, 2021
by
Jean-Clement Gallardo
Browse files
Finish hotfix/MappingAndRefresh
parents
00e97c7a
88e6aa85
Changes
1
Hide whitespace changes
Inline
Side-by-side
resources/lib/functions/GraphLink.js
View file @
6e747efb
...
...
@@ -386,10 +386,28 @@ metExploreD3.GraphLink = {
})
.
style
(
"
stroke
"
,
linkStyle
.
getStrokeColor
())
.
style
(
"
stroke-width
"
,
linkStyle
.
getLineWidth
())
.
style
(
"
opacity
"
,
1
)
.
style
(
"
opacity
"
,
linkStyle
.
getOpacity
()
)
.
style
(
"
stroke-dasharray
"
,
null
);
if
(
_metExploreViz
.
getMappingsLength
()
>
0
){
metExploreD3
.
GraphLink
.
majMapping
(
Ext
.
ComponentQuery
.
query
(
'
aStyleForm
'
));
}
if
(
metExploreD3
.
GraphStyleEdition
.
curvedPath
===
true
){
var
flux
=
_metExploreViz
.
getSessionById
(
parent
).
getMappingDataType
()
===
"
Flux
"
;
if
(
flux
)
{
funcPath
=
metExploreD3
.
GraphLink
.
funcPathForFlux
;
d3
.
select
(
"
#
"
+
parent
).
select
(
"
#D3viz
"
).
select
(
"
#graphComponent
"
)
.
selectAll
(
"
path.link.reaction
"
)
.
attr
(
"
d
"
,
function
(
link
){
return
funcPath
(
link
,
parent
,
this
.
id
);})
.
style
(
"
stroke-linejoin
"
,
"
bevel
"
);
}
else
{
metExploreD3
.
GraphLink
.
bundleLinks
(
parent
);
}
}
if
(
metExploreD3
.
getGeneralStyle
().
isDisplayedPathwaysOnLinks
())
metExploreD3
.
GraphCaption
.
majCaptionPathwayOnLink
();
...
...
@@ -1286,5 +1304,31 @@ metExploreD3.GraphLink = {
*/
removeReactionLinks
:
function
()
{
d3
.
selectAll
(
"
path.link.reaction
"
).
remove
();
},
majMapping
:
function
(
views
)
{
views
.
forEach
(
function
(
view
,
i
)
{
if
(
view
.
lookupReference
(
'
selectConditionForm
'
)
!==
undefined
&&
view
.
lookupReference
(
'
selectConditionForm
'
)
!==
null
){
var
selectConditionType
=
view
.
lookupReference
(
'
selectConditionForm
'
).
lookupReference
(
'
selectConditionType
'
);
var
dataType
=
selectConditionType
.
getValue
();
var
conditionName
=
view
.
lookupReference
(
'
selectConditionForm
'
).
lookupReference
(
'
selectCondition
'
).
getValue
();
if
(
conditionName
!==
null
)
{
if
(
dataType
===
"
Alias
"
){
metExploreD3
.
GraphMapping
.
graphMappingDiscreteData
(
conditionName
,
view
);
}
if
(
dataType
===
"
Discrete
"
){
metExploreD3
.
GraphMapping
.
graphMappingDiscreteData
(
conditionName
,
view
);
}
if
(
dataType
===
"
As selection
"
){
metExploreD3
.
GraphMapping
.
graphMappingAsSelectionData
(
conditionName
,
view
);
}
if
(
dataType
===
"
Continuous
"
)
{
metExploreD3
.
GraphMapping
.
graphMappingContinuousData
(
conditionName
,
view
);
}
}
}
});
}
};
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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