Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
AMOEBA3
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
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SMAC
Learning Group
AMOEBA3
Commits
8c0e430d
Commit
8c0e430d
authored
7 years ago
by
BrunoDatoMeneses
Browse files
Options
Downloads
Patches
Plain Diff
ADD: right click neighbours diplay on viewer
parent
391e89d9
No related branches found
No related tags found
1 merge request
!1
Merge Master
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
AMOEBA3/src/visualization/view/system/twoDim/GrapheTwoDimPanelStandard.java
+11
-2
11 additions, 2 deletions
...ization/view/system/twoDim/GrapheTwoDimPanelStandard.java
with
11 additions
and
2 deletions
AMOEBA3/src/visualization/view/system/twoDim/GrapheTwoDimPanelStandard.java
+
11
−
2
View file @
8c0e430d
...
@@ -1333,7 +1333,7 @@ private void startPanelController() {
...
@@ -1333,7 +1333,7 @@ private void startPanelController() {
//JOptionPane.showMessageDialog(this, info, "Context : " + id, JOptionPane.PLAIN_MESSAGE);
//JOptionPane.showMessageDialog(this, info, "Context : " + id, JOptionPane.PLAIN_MESSAGE);
if
(
currentId
!=
null
)
{
if
(
currentId
!=
null
)
{
highlightContextNeighbours
(
world
.
getScheduler
().
getContextByName
(
currentId
));
//
highlightContextNeighbours(world.getScheduler().getContextByName(currentId));
setTextAreaInfo
(
currentId
);
setTextAreaInfo
(
currentId
);
if
(
sliderValue
==
currentTick
||
(!
rememberState
))
{
if
(
sliderValue
==
currentTick
||
(!
rememberState
))
{
...
@@ -1449,18 +1449,27 @@ private void startPanelController() {
...
@@ -1449,18 +1449,27 @@ private void startPanelController() {
*/
*/
public
void
popupMenuForVisualization
(
String
id
)
{
public
void
popupMenuForVisualization
(
String
id
)
{
JPopupMenu
popup
=
new
JPopupMenu
(
"Visualization"
);
JPopupMenu
popup
=
new
JPopupMenu
(
"Visualization"
);
JMenuItem
itemShowContextNeighbours
=
new
JMenuItem
(
"Neighbours"
);
itemShowContextNeighbours
.
addActionListener
(
e
->
{
highlightNeighbours
(
id
);});
JMenuItem
itemShow2Dim
=
new
JMenuItem
(
"History of grapgh in 2 Dim"
);
JMenuItem
itemShow2Dim
=
new
JMenuItem
(
"History of grapgh in 2 Dim"
);
itemShow2Dim
.
addActionListener
(
e
->
{
popupVisualization2Dim
(
id
);});
itemShow2Dim
.
addActionListener
(
e
->
{
popupVisualization2Dim
(
id
);});
JMenuItem
itemShowNDim
=
new
JMenuItem
(
"Graph Visualization in N Dim"
);
JMenuItem
itemShowNDim
=
new
JMenuItem
(
"Graph Visualization in N Dim"
);
itemShowNDim
.
addActionListener
(
e
->
{
popupVisualizationNDim
(
id
);});
itemShowNDim
.
addActionListener
(
e
->
{
popupVisualizationNDim
(
id
);});
JMenuItem
itemShowAll
=
new
JMenuItem
(
"Both"
);
JMenuItem
itemShowAll
=
new
JMenuItem
(
"Both"
);
itemShowAll
.
addActionListener
(
e
->
{
popupVisualization2Dim
(
id
);
popupVisualizationNDim
(
id
);});
itemShowAll
.
addActionListener
(
e
->
{
highlightNeighbours
(
id
);
popupVisualization2Dim
(
id
);
popupVisualizationNDim
(
id
);});
popup
.
add
(
itemShowContextNeighbours
);
popup
.
add
(
itemShow2Dim
);
popup
.
add
(
itemShow2Dim
);
popup
.
add
(
itemShowNDim
);
popup
.
add
(
itemShowNDim
);
popup
.
add
(
itemShowAll
);
popup
.
add
(
itemShowAll
);
popup
.
show
(
this
,
this
.
getX
()
+
mouseEvent
.
getX
(),
this
.
getY
()
+
mouseEvent
.
getY
());
popup
.
show
(
this
,
this
.
getX
()
+
mouseEvent
.
getX
(),
this
.
getY
()
+
mouseEvent
.
getY
());
}
}
private
void
highlightNeighbours
(
String
id
)
{
highlightContextNeighbours
(
world
.
getScheduler
().
getContextByName
(
id
));
}
/**
/**
* Popup visualization 2 dim.
* Popup visualization 2 dim.
*
*
...
...
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