Skip to content

Commit

Permalink
Merge pull request MoravianUniversity#57 from Michael5011st/master
Browse files Browse the repository at this point in the history
this is a fix for firefox to work with the object oriented map
  • Loading branch information
WCollins3 committed Jul 29, 2015
2 parents 009f8c7 + e490a53 commit 1880cb5
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
14 changes: 11 additions & 3 deletions gradientUSMap.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,18 +155,26 @@ function GradientMap(feature){
}

}

var Location=this.id%2;
this.mouseOver = function(d){


d3.select("#tooltip" + newThis.id.toString()).transition().duration(200).style("opacity", 0.9);


if(newThis.q[0] === "Gecko") {
if(Location==0){
var coord = d3.mouse(this);
var c_x = (coord[0] + 100) +"px";
var c_y = (coord[1] + 680 + (newThis.id * 650)) + "px";

var c_y = (coord[1] + 680 + (newThis.id* 200)) + "px";}
else{
var coord = d3.mouse(this);
if(newThis.id > 2){
var c_x = (coord[0] + 100+(newThis.id*125)) +"px"
var c_y = (coord[1] + 680+(newThis.id* 100)) + "px";}
else{
var c_x = (coord[0] + 100+(newThis.id*450)) +"px";
var c_y = (coord[1] + 680) + "px";}}
} else{
var x_offset = (function () {
var offset_temp = window.getComputedStyle(document.getElementById("Main_Content")).marginLeft;
Expand Down
1 change: 1 addition & 0 deletions morningstar.html
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,7 @@ <h4>Maximum Color:</h4>
manager.makeCombo();
manager.addMap(map);
//manager.addMap(map2);

var dict_of_state_dict = {};
var dict_of_county_dict = {};
var features = [];
Expand Down

0 comments on commit 1880cb5

Please sign in to comment.