Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(461)

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_win.cc

Issue 25022003: Report LatencyInfo through trace buffer (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fix compile error Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/renderer_host/render_widget_host_view_win.h" 5 #include "content/browser/renderer_host/render_widget_host_view_win.h"
6 6
7 #include <InputScope.h> 7 #include <InputScope.h>
8 #include <wtsapi32.h> 8 #include <wtsapi32.h>
9 #pragma comment(lib, "wtsapi32.lib") 9 #pragma comment(lib, "wtsapi32.lib")
10 10
(...skipping 1378 matching lines...) Expand 10 before | Expand all | Expand 10 after
1389 if (!web_contents_switch_paint_time_.is_null()) { 1389 if (!web_contents_switch_paint_time_.is_null()) {
1390 TimeDelta web_contents_switch_paint_duration = TimeTicks::Now() - 1390 TimeDelta web_contents_switch_paint_duration = TimeTicks::Now() -
1391 web_contents_switch_paint_time_; 1391 web_contents_switch_paint_time_;
1392 UMA_HISTOGRAM_TIMES("MPArch.RWH_TabSwitchPaintDuration", 1392 UMA_HISTOGRAM_TIMES("MPArch.RWH_TabSwitchPaintDuration",
1393 web_contents_switch_paint_duration); 1393 web_contents_switch_paint_duration);
1394 // Reset contents_switch_paint_time_ to 0 so future tab selections are 1394 // Reset contents_switch_paint_time_ to 0 so future tab selections are
1395 // recorded. 1395 // recorded.
1396 web_contents_switch_paint_time_ = TimeTicks(); 1396 web_contents_switch_paint_time_ = TimeTicks();
1397 } 1397 }
1398 1398
1399 software_latency_info_.swap_timestamp = TimeTicks::HighResNow(); 1399 software_latency_info_.AddLatencyNumber(
1400 ui::INPUT_EVENT_LATENCY_TERMINATED_FRAME_SWAP_COMPONENT, 0, 0);
1400 render_widget_host_->FrameSwapped(software_latency_info_); 1401 render_widget_host_->FrameSwapped(software_latency_info_);
1401 software_latency_info_.Clear(); 1402 software_latency_info_.Clear();
1402 } else { 1403 } else {
1403 DrawBackground(paint_dc.m_ps.rcPaint, &paint_dc); 1404 DrawBackground(paint_dc.m_ps.rcPaint, &paint_dc);
1404 if (whiteout_start_time_.is_null()) 1405 if (whiteout_start_time_.is_null())
1405 whiteout_start_time_ = TimeTicks::Now(); 1406 whiteout_start_time_ = TimeTicks::Now();
1406 } 1407 }
1407 } 1408 }
1408 1409
1409 void RenderWidgetHostViewWin::DrawBackground(const RECT& dirty_rect, 1410 void RenderWidgetHostViewWin::DrawBackground(const RECT& dirty_rect,
(...skipping 1773 matching lines...) Expand 10 before | Expand all | Expand 10 after
3183 return new RenderWidgetHostViewWin(widget); 3184 return new RenderWidgetHostViewWin(widget);
3184 } 3185 }
3185 3186
3186 // static 3187 // static
3187 void RenderWidgetHostViewPort::GetDefaultScreenInfo( 3188 void RenderWidgetHostViewPort::GetDefaultScreenInfo(
3188 WebKit::WebScreenInfo* results) { 3189 WebKit::WebScreenInfo* results) {
3189 GetScreenInfoForWindow(0, results); 3190 GetScreenInfoForWindow(0, results);
3190 } 3191 }
3191 3192
3192 } // namespace content 3193 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_mac.mm ('k') | content/common/content_param_traits_macros.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698