| OLD | NEW |
| 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 "chrome/browser/ui/views/hung_renderer_view.h" | 5 #include "chrome/browser/ui/views/hung_renderer_view.h" |
| 6 | 6 |
| 7 #include "base/i18n/rtl.h" | 7 #include "base/i18n/rtl.h" |
| 8 #include "base/memory/ptr_util.h" | 8 #include "base/memory/ptr_util.h" |
| 9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
| 10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| (...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 345 | 345 |
| 346 crash_keys.push_back(std::make_pair( | 346 crash_keys.push_back(std::make_pair( |
| 347 crash_keys::kHungRendererOutstandingAckCount, | 347 crash_keys::kHungRendererOutstandingAckCount, |
| 348 base::IntToString(unresponsive_state_.outstanding_ack_count))); | 348 base::IntToString(unresponsive_state_.outstanding_ack_count))); |
| 349 crash_keys.push_back(std::make_pair( | 349 crash_keys.push_back(std::make_pair( |
| 350 crash_keys::kHungRendererOutstandingEventType, | 350 crash_keys::kHungRendererOutstandingEventType, |
| 351 base::IntToString(unresponsive_state_.outstanding_event_type))); | 351 base::IntToString(unresponsive_state_.outstanding_event_type))); |
| 352 crash_keys.push_back( | 352 crash_keys.push_back( |
| 353 std::make_pair(crash_keys::kHungRendererLastEventType, | 353 std::make_pair(crash_keys::kHungRendererLastEventType, |
| 354 base::IntToString(unresponsive_state_.last_event_type))); | 354 base::IntToString(unresponsive_state_.last_event_type))); |
| 355 crash_keys.push_back( | |
| 356 std::make_pair(crash_keys::kHungRendererReason, | |
| 357 base::IntToString(unresponsive_state_.reason))); | |
| 358 | 355 |
| 359 // Try to generate a crash report for the hung process. | 356 // Try to generate a crash report for the hung process. |
| 360 CrashDumpAndTerminateHungChildProcess(rph->GetHandle(), crash_keys); | 357 CrashDumpAndTerminateHungChildProcess(rph->GetHandle(), crash_keys); |
| 361 #else | 358 #else |
| 362 rph->Shutdown(content::RESULT_CODE_HUNG, false); | 359 rph->Shutdown(content::RESULT_CODE_HUNG, false); |
| 363 #endif | 360 #endif |
| 364 } | 361 } |
| 365 return true; | 362 return true; |
| 366 } | 363 } |
| 367 | 364 |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 461 | 458 |
| 462 // static | 459 // static |
| 463 void HungRendererDialogView::InitClass() { | 460 void HungRendererDialogView::InitClass() { |
| 464 static bool initialized = false; | 461 static bool initialized = false; |
| 465 if (!initialized) { | 462 if (!initialized) { |
| 466 ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); | 463 ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); |
| 467 frozen_icon_ = rb.GetImageSkiaNamed(IDR_FROZEN_TAB_ICON); | 464 frozen_icon_ = rb.GetImageSkiaNamed(IDR_FROZEN_TAB_ICON); |
| 468 initialized = true; | 465 initialized = true; |
| 469 } | 466 } |
| 470 } | 467 } |
| OLD | NEW |