Skip to content

Commit

Permalink
Merge pull request #79 from WPI-CS3733-C17-Gamma/highLightSelectedMap
Browse files Browse the repository at this point in the history
Highlight Map
  • Loading branch information
ad1217 authored Feb 17, 2017
2 parents d2120b8 + 4367102 commit d237c43
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/main/java/PatientController.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@
import javafx.fxml.FXML;
import javafx.fxml.Initializable;
import javafx.geometry.Insets;
import javafx.scene.Node;
import javafx.scene.control.Button;
import javafx.scene.control.Label;
import javafx.scene.control.ListView;
import javafx.scene.control.TextField;
import javafx.scene.effect.DropShadow;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;
import javafx.scene.input.MouseEvent;
Expand Down Expand Up @@ -308,6 +310,10 @@ public void getPath (GraphNode start, GraphNode end) {
for (int x = 0; x <currentPath.size(); x++){
SubPath p = currentPath.get(x);
ImageView i = new ImageView();
if(x == 0){
i.setEffect(new DropShadow());
}

i.setPreserveRatio(true);
i.setFitHeight(95);
i.setFitWidth(165);
Expand All @@ -332,6 +338,10 @@ public void getPath (GraphNode start, GraphNode end) {
public void mapChoice(MouseEvent e){
try {
ImageView iv = (ImageView) e.getSource();
for(Node child :iv.getParent().getChildrenUnmodifiable()){
child.setEffect(null);
}
iv.setEffect(new DropShadow());
System.out.println(iv.getId() + "*******");
currentSubPath = (int) iv.getId().charAt(0) - 48;
SubPath path = currentPath.get(currentSubPath);//ascii conversion
Expand Down

0 comments on commit d237c43

Please sign in to comment.