Ejemplo n.º 1
0
 public static void OpenProfiler(string marker = "", Analytics.ActionSource source = Analytics.ActionSource.Scripting)
 {
     Analytics.SendPerformanceActionEvent(new Analytics.PerformanceActionEvent(
                                              Analytics.ActionType.OpenProfilerOnMarker,
                                              marker, source));
     ProfilerHelpers.OpenProfiler(marker);
 }
Ejemplo n.º 2
0
        private static WindowAction StartProfilerRecordingEditorAction()
        {
            var action = WindowAction.CreateWindowMenuItem("StartProfilerRecordingEditor", (window, _action) =>
            {
                // We need to fix this!! See

                var marker = PerformanceTrackerMonitoringService.GetWindowPaintMarker(window);
                ProfilerHelpers.OpenProfiler(marker, profilerWindow =>
                {
                    ProfilerHelpers.SetRecordingEnabled(profilerWindow, true);
                    ProfilerHelpers.StartProfilerRecording("", true, ProfilerDriver.deepProfiling);
                });
            }, "Window Performance/Start Profiler Recording");

            return(action);
        }