mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-09-26 23:46:36 +00:00
patched highcharts.js and highcharts.src.js to not use UTC by default
This commit is contained in:
@@ -78,7 +78,7 @@ i,j=function(m){for(g=m.length;g--;)m[g]===Za&&m.splice(g+1,0,m[g+1],m[g+2],m[g+
|
||||
e[f]=isNaN(d)?a[f]:c*parseFloat(b[f]-d)+d}else e=b;return e}};ma&&ma.init&&ma.init(Nc);if(!ma&&db.jQuery){var Mb=jQuery;u=function(a,b){for(var c=0,d=a.length;c<d;c++)if(b.call(a[c],a[c],c,a)===false)return c};Dd=Mb.grep;tc=function(a,b){for(var c=[],d=0,e=a.length;d<e;d++)c[d]=b.call(a[d],a[d],d,a);return c};Ca=function(){var a=arguments;return Mb.extend(true,null,a[0],a[1],a[2],a[3])};Qa=function(a,b,c){Mb(a).bind(b,c)};pb=function(a,b,c){var d=ua.removeEventListener?"removeEventListener":"detachEvent";
|
||||
if(ua[d]&&!a[d])a[d]=function(){};Mb(a).unbind(b,c)};Pa=function(a,b,c,d){var e=Mb.Event(b),f="detached"+b;sa(e,c);if(a[b]){a[f]=a[b];a[b]=null}Mb(a).trigger(e);if(a[f]){a[b]=a[f];a[f]=null}d&&!e.isDefaultPrevented()&&d(e)};gd=function(a,b,c){var d=Mb(a);if(b.d){a.toD=b.d;b.d=1}d.stop();d.animate(b,c)};Hc=function(a){Mb(a).stop()};Mb.extend(Mb.easing,{easeOutQuad:function(a,b,c,d,e){return-d*(b/=e)*(b-2)+c}});var de=jQuery.fx,ee=de.step;u(["cur","_default","width","height"],function(a,b){var c=b?
|
||||
ee:de.prototype,d=c[a],e;if(d)c[a]=function(f){f=b?f:this;e=f.elem;return e.attr?e.attr(f.prop,f.now):d.apply(this,arguments)}});ee.d=function(a){var b=a.elem;if(!a.started){var c=Nc.init(b,b.d,b.toD);a.start=c[0];a.end=c[1];a.started=true}b.attr("d",Nc.step(a.start,a.end,a.pos,b.toD))}}ma={enabled:true,align:"center",x:0,y:15,style:{color:"#666",fontSize:"11px",lineHeight:"14px"}};Xa={colors:["#4572A7","#AA4643","#89A54E","#80699B","#3D96AE","#DB843D","#92A8CD","#A47D7C","#B5CA92"],symbols:["circle",
|
||||
"diamond","square","triangle","triangle-down"],lang:{loading:"Loading...",months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","June","Jul","Aug","Sep","Oct","Nov","Dec"],weekdays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],decimalPoint:".",resetZoom:"Reset zoom",resetZoomTitle:"Reset zoom level 1:1",thousandsSep:","},global:{useUTC:true},chart:{borderColor:"#4572A7",
|
||||
"diamond","square","triangle","triangle-down"],lang:{loading:"Loading...",months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","June","Jul","Aug","Sep","Oct","Nov","Dec"],weekdays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],decimalPoint:".",resetZoom:"Reset zoom",resetZoomTitle:"Reset zoom level 1:1",thousandsSep:","},global:{useUTC:false},chart:{borderColor:"#4572A7",
|
||||
borderRadius:5,defaultSeriesType:"line",ignoreHiddenSeries:true,spacingTop:10,spacingRight:10,spacingBottom:15,spacingLeft:10,style:{fontFamily:'"Lucida Grande", "Lucida Sans Unicode", Verdana, Arial, Helvetica, sans-serif',fontSize:"12px"},backgroundColor:"#FFFFFF",plotBorderColor:"#C0C0C0"},title:{text:"Chart title",align:"center",y:15,style:{color:"#3E576F",fontSize:"16px"}},subtitle:{text:"",align:"center",y:30,style:{color:"#6D869F"}},plotOptions:{line:{allowPointSelect:false,showCheckbox:false,
|
||||
animation:{duration:1E3},events:{},lineWidth:2,shadow:true,marker:{enabled:true,lineWidth:0,radius:4,lineColor:"#FFFFFF",states:{hover:{},select:{fillColor:"#FFFFFF",lineColor:"#000000",lineWidth:2}}},point:{events:{}},dataLabels:Ca(ma,{enabled:false,y:-6,formatter:function(){return this.y}}),showInLegend:true,states:{hover:{marker:{}},select:{marker:{}}},stickyTracking:true}},labels:{style:{position:ic,color:"#3E576F"}},legend:{enabled:true,align:"center",layout:"horizontal",labelFormatter:function(){return this.name},
|
||||
borderWidth:1,borderColor:"#909090",borderRadius:5,shadow:false,style:{padding:"5px"},itemStyle:{cursor:"pointer",color:"#3E576F"},itemHoverStyle:{cursor:"pointer",color:"#000000"},itemHiddenStyle:{color:"#C0C0C0"},itemCheckboxStyle:{position:ic,width:"13px",height:"13px"},symbolWidth:16,symbolPadding:5,verticalAlign:"bottom",x:0,y:0},loading:{hideDuration:100,labelStyle:{fontWeight:"bold",position:Xd,top:"1em"},showDuration:100,style:{position:ic,backgroundColor:"white",opacity:0.5,textAlign:"center"}},
|
||||
|
||||
@@ -968,7 +968,7 @@ defaultOptions = {
|
||||
thousandsSep: ','
|
||||
},
|
||||
global: {
|
||||
useUTC: true
|
||||
useUTC: false
|
||||
},
|
||||
chart: {
|
||||
//animation: true,
|
||||
|
||||
+2
-3
@@ -22,7 +22,6 @@ import org.moxieapps.gwt.highcharts.client.plotOptions.Marker;
|
||||
|
||||
import com.google.gwt.i18n.client.DateTimeFormat;
|
||||
import com.google.gwt.i18n.client.NumberFormat;
|
||||
import com.google.gwt.i18n.client.TimeZone;
|
||||
import com.google.gwt.user.client.rpc.AsyncCallback;
|
||||
import com.google.gwt.user.client.ui.VerticalPanel;
|
||||
import com.google.gwt.user.client.ui.Widget;
|
||||
@@ -76,7 +75,7 @@ public class WindChart implements Component<WindChartSettings>, RaceSelectionCha
|
||||
.setZoomType(Chart.ZoomType.X)
|
||||
.setSpacingRight(20)
|
||||
.setChartTitle(new ChartTitle().setText(stringMessages.wind()))
|
||||
.setChartSubtitle(new ChartSubtitle().setText(stringMessages.clickAndDragToZoomIn()+"; "+stringMessages.allTimesInUTC()))
|
||||
.setChartSubtitle(new ChartSubtitle().setText(stringMessages.clickAndDragToZoomIn()))
|
||||
.setLegend(new Legend().setEnabled(true))
|
||||
.setLinePlotOptions(new LinePlotOptions().setLineWidth(LINE_WIDTH).setMarker(new Marker().setEnabled(false).setHoverState(
|
||||
new Marker().setEnabled(true).setRadius(4))).setShadow(false)
|
||||
@@ -88,7 +87,7 @@ public class WindChart implements Component<WindChartSettings>, RaceSelectionCha
|
||||
public String format(ToolTipData toolTipData) {
|
||||
return "<b>" + toolTipData.getSeriesName() + (toolTipData.getPointName() != null ? " "+toolTipData.getPointName() : "")
|
||||
+ "</b><br/>" +
|
||||
dateFormat.format(new Date(toolTipData.getXAsLong()), TimeZone.createTimeZone(0)) + ": " +
|
||||
dateFormat.format(new Date(toolTipData.getXAsLong())) + ": " +
|
||||
numberFormat.format(toolTipData.getYAsDouble()) + unit;
|
||||
}
|
||||
}));
|
||||
|
||||
+2
-3
@@ -29,7 +29,6 @@ import com.google.gwt.event.dom.client.ClickHandler;
|
||||
import com.google.gwt.event.shared.GwtEvent;
|
||||
import com.google.gwt.i18n.client.DateTimeFormat;
|
||||
import com.google.gwt.i18n.client.NumberFormat;
|
||||
import com.google.gwt.i18n.client.TimeZone;
|
||||
import com.google.gwt.resources.client.ImageResource;
|
||||
import com.google.gwt.user.client.rpc.AsyncCallback;
|
||||
import com.google.gwt.user.client.ui.AbsolutePanel;
|
||||
@@ -122,7 +121,7 @@ implements CompetitorSelectionChangeListener, RaceSelectionChangeListener, TimeL
|
||||
chart = new Chart().setZoomType(Chart.ZoomType.X)
|
||||
.setSpacingRight(20)
|
||||
.setChartTitle(new ChartTitle().setText(DetailTypeFormatter.format(dataToShow, stringMessages)))
|
||||
.setChartSubtitle(new ChartSubtitle().setText(stringMessages.clickAndDragToZoomIn()+"; "+stringMessages.allTimesInUTC()))
|
||||
.setChartSubtitle(new ChartSubtitle().setText(stringMessages.clickAndDragToZoomIn()))
|
||||
.setLegend(new Legend().setEnabled(true))
|
||||
.setLinePlotOptions(new LinePlotOptions().setLineWidth(LINE_WIDTH).setMarker(new Marker().setEnabled(false).setHoverState(
|
||||
new Marker().setEnabled(true).setRadius(4))).setShadow(false)
|
||||
@@ -147,7 +146,7 @@ implements CompetitorSelectionChangeListener, RaceSelectionChangeListener, TimeL
|
||||
public String format(ToolTipData toolTipData) {
|
||||
return "<b>" + toolTipData.getSeriesName() + (toolTipData.getPointName() != null ? " "+toolTipData.getPointName() : "")
|
||||
+ "</b><br/>" +
|
||||
dateFormat.format(new Date(toolTipData.getXAsLong()), TimeZone.createTimeZone(0)) + ": " +
|
||||
dateFormat.format(new Date(toolTipData.getXAsLong())) + ": " +
|
||||
numberFormat.format(toolTipData.getYAsDouble()) + unit;
|
||||
}
|
||||
}));
|
||||
|
||||
+1
-1
@@ -57,7 +57,7 @@ public class LeaderboardPage extends AbstractEntryPoint {
|
||||
breadcrumbLinksData.add(new Pair<String, String>(link, leaderboardGroupName));
|
||||
}
|
||||
BreadcrumbPanel breadcrumbPanel = new BreadcrumbPanel(breadcrumbLinksData, leaderboardName.toUpperCase());
|
||||
|
||||
// FIXME bug #247: can't pass null as LeaderboardSettings since the leaderboardPanel will choke
|
||||
LeaderboardPanel leaderboardPanel = new LeaderboardPanel(sailingService, null,
|
||||
new CompetitorSelectionModel(/* hasMultiSelection */ true), leaderboardName, leaderboardGroupName,
|
||||
LeaderboardPage.this, stringMessages);
|
||||
|
||||
Reference in New Issue
Block a user