Chromium Code Reviews| Index: chrome/browser/win/jumplist.cc |
| diff --git a/chrome/browser/win/jumplist.cc b/chrome/browser/win/jumplist.cc |
| index 071087a3db853eaa28f52a2a835f809db9bf2b44..3f879adac52ca93f91df8048d6129f9304a48ef8 100644 |
| --- a/chrome/browser/win/jumplist.cc |
| +++ b/chrome/browser/win/jumplist.cc |
| @@ -121,6 +121,7 @@ bool CreateIconFile(const gfx::ImageSkia& image_skia, |
| // loaded icons. |
| void CreateIconFiles(const base::FilePath& icon_dir, |
| const ShellLinkItemList& item_list) { |
| + SCOPED_UMA_HISTOGRAM_TIMER("WinJumplist.CreateIconFilesDuration"); |
|
gab
2017/04/13 15:14:22
Add
// TODO(chengx): Remove after settling http:/
chengx
2017/04/13 19:21:52
Done.
|
| for (ShellLinkItemList::const_iterator item = item_list.begin(); |
| item != item_list.end(); ++item) { |
| base::FilePath icon_path; |
| @@ -177,6 +178,7 @@ bool UpdateJumpList(const wchar_t* app_id, |
| const ShellLinkItemList& most_visited_pages, |
| const ShellLinkItemList& recently_closed_pages, |
| IncognitoModePrefs::Availability incognito_availability) { |
| + SCOPED_UMA_HISTOGRAM_TIMER("WinJumplist.UpdateJumpListDuration"); |
| // JumpList is implemented only on Windows 7 or later. |
| // So, we should return now when this function is called on earlier versions |
| // of Windows. |
| @@ -256,6 +258,10 @@ void RunUpdateJumpListUserVisiblePriority( |
| // jumplist icons. The jumplist links should be updated anyway, as it doesn't |
| // involve disk IO. |
| if (base::DirectoryExists(icon_dir) && base::IsDirectoryEmpty(icon_dir)) { |
| + UMA_HISTOGRAM_COUNTS_100( |
| + "WinJumplist.CreateIconFilesCount", |
| + local_most_visited_pages.size() + local_recently_closed_pages.size()); |
| + |
| // Create icon files for shortcuts in the "Most Visited" category. |
| CreateIconFiles(icon_dir, local_most_visited_pages); |