@@ -217,7 +217,7 @@ var ProfilerView = function(id, name, container_class, html, default_handler)
217217 this . _timeline_times_ele . clearAndRender ( this . _templates . timeline_markers ( interval . start , interval . end , width ) ) ;
218218 this . _timeline_ele . clearAndRender ( this . _templates . event_list_all ( event_list , interval , this . _event_id , width ) ) ;
219219
220- if ( this . _table )
220+ if ( this . _table && this . _table . get_data ( ) )
221221 {
222222 frag . appendChild ( this . _status_ele ) ;
223223 this . _details_ele . clearAndRender ( this . _templates . details ( this . _table ) ) ;
@@ -358,6 +358,7 @@ var ProfilerView = function(id, name, container_class, html, default_handler)
358358 else
359359 {
360360 this . _details_ele . clearAndRender ( this . _templates . no_events ( ) ) ;
361+ this . _status_ele . remove ( ) ;
361362 }
362363 } ;
363364
@@ -414,18 +415,6 @@ var ProfilerView = function(id, name, container_class, html, default_handler)
414415 }
415416 } ;
416417
417- this . _on_settings_changed = function ( msg )
418- {
419- if ( msg . id === this . id && msg . key === "zero-at-first-event" )
420- this . _has_zero_at_first_event = msg . value ;
421- } ;
422-
423- this . _on_settings_initialized = function ( msg )
424- {
425- if ( msg . view_id === this . id )
426- this . _has_zero_at_first_event = msg . setting . get ( "zero-at-first-event" ) ;
427- } ;
428-
429418 this . _ontooltip = function ( event , target )
430419 {
431420 var id = Number ( target . get_attr ( "parent-node-chain" , "data-event-id" ) ) ;
@@ -539,7 +528,6 @@ var ProfilerView = function(id, name, container_class, html, default_handler)
539528 this . _overlay = new OverlayService ( ) ;
540529 this . _templates = new ProfilerTemplates ( ) ;
541530 this . _has_overlay_service = false ;
542- this . _has_zero_at_first_event = false ;
543531 this . _old_session_id = null ;
544532 this . _reset ( ) ;
545533
@@ -570,8 +558,6 @@ var ProfilerView = function(id, name, container_class, html, default_handler)
570558 this . _handle_details_list_bound = this . _handle_details_list . bind ( this ) ;
571559
572560 window . messages . addListener ( "profile-enabled" , this . _on_profile_enabled . bind ( this ) ) ;
573- window . messages . addListener ( "setting-changed" , this . _on_settings_changed . bind ( this ) ) ;
574- window . messages . addListener ( "settings-initialized" , this . _on_settings_initialized . bind ( this ) ) ;
575561
576562 window . event_handlers . click [ "profiler-start-stop" ] = this . _start_stop_profiler . bind ( this ) ;
577563 window . event_handlers . click [ "profiler-reload-window" ] = this . _reload_window . bind ( this ) ;
@@ -598,27 +584,9 @@ ProfilerView.create_ui_widgets = function()
598584 title : ui_strings . S_BUTTON_START_PROFILER
599585 }
600586 ]
601- } ,
602- {
603- type : UI . TYPE_SWITCH ,
604- items : [
605- {
606- key : "profiler_all.zero-at-first-event"
607- }
608- ]
609587 }
610588 ]
611589 } ) ;
612-
613- new Settings (
614- "profiler_all" ,
615- {
616- "zero-at-first-event" : true
617- } ,
618- {
619- "zero-at-first-event" : ui_strings . S_SWITCH_CHANGE_START_TO_FIRST_EVENT
620- }
621- ) ;
622590} ;
623591
624592/**
0 commit comments