File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ var embed = {
1919 enabled : false ,
2020 vlist : true ,
2121 graph : true ,
22- graph_exapnded : false ,
22+ graph_expanded : true ,
2323}
2424var params = window . location . search . substring ( 1 ) . split ( '&' ) ;
2525
@@ -31,7 +31,7 @@ for(var idx in params) {
3131 case "embed" : if ( line [ 1 ] == "1" ) embed . enabled = true ; break ;
3232 case "hidelist" : if ( line [ 1 ] == "1" ) embed . vlist = false ; break ;
3333 case "hidegraph" : if ( line [ 1 ] == "1" ) embed . graph = false ; break ;
34- case "expandgraph" : if ( line [ 1 ] == "1 " ) embed . graph_expanded = true ; break ;
34+ case "expandgraph" : if ( line [ 1 ] == "0 " ) embed . graph_expanded = false ; break ;
3535 case "filter" : vfilter = line [ 1 ] ; break ;
3636 case "nyan" : nyan_mode = true ; break ;
3737 }
@@ -346,9 +346,6 @@ $(window).ready(function() {
346346 } ) ;
347347 } ) ;
348348
349- // expand graph on startup, if nessary
350- if ( embed . graph_expanded ) $ ( '#telemetry_graph .graph_label' ) . click ( ) ;
351-
352349 // reset nite-overlay and timebox when mouse goes out of the graph box
353350 $ ( "#telemetry_graph" ) . on ( 'mouseout' , '.holder' , function ( ) {
354351 nite . setDate ( null ) ;
Original file line number Diff line number Diff line change @@ -1360,6 +1360,9 @@ function zoom_on_payload() {
13601360 // scroll list to the expanded element
13611361 listScroll . refresh ( ) ;
13621362 listScroll . scrollToElement ( '.portrait .vehicle' + i ) ;
1363+
1364+ // expand graph on startup, if nessary
1365+ if ( embed . graph_expanded && ! is_mobile ) $ ( '#telemetry_graph .graph_label' ) . click ( ) ;
13631366}
13641367
13651368function isInt ( n ) {
You can’t perform that action at this time.
0 commit comments