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/extensions/extension_processes_api.h" | 5 #include "chrome/browser/extensions/extension_processes_api.h" |
6 | 6 |
7 #include "base/callback.h" | 7 #include "base/callback.h" |
8 #include "base/json/json_writer.h" | 8 #include "base/json/json_writer.h" |
9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
(...skipping 634 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
645 SendResponse(false); | 645 SendResponse(false); |
646 } else { | 646 } else { |
647 SetResult(Value::CreateBooleanValue(killed)); | 647 SetResult(Value::CreateBooleanValue(killed)); |
648 SendResponse(true); | 648 SendResponse(true); |
649 } | 649 } |
650 | 650 |
651 // Balance the AddRef in the RunImpl. | 651 // Balance the AddRef in the RunImpl. |
652 Release(); | 652 Release(); |
653 } | 653 } |
654 | 654 |
655 GetProcessInfoFunction::GetProcessInfoFunction() { | 655 GetProcessInfoFunction::GetProcessInfoFunction() |
656 : memory_(false) { | |
Mark Mentovai
2012/08/01 16:36:20
Fix indentation. See http://google-styleguide.goog
nilesh
2012/08/01 16:40:52
Done. Thanks.
| |
656 } | 657 } |
657 | 658 |
658 GetProcessInfoFunction::~GetProcessInfoFunction() { | 659 GetProcessInfoFunction::~GetProcessInfoFunction() { |
659 } | 660 } |
660 | 661 |
661 bool GetProcessInfoFunction::RunImpl() { | 662 bool GetProcessInfoFunction::RunImpl() { |
662 #if defined(ENABLE_TASK_MANAGER) | 663 #if defined(ENABLE_TASK_MANAGER) |
663 Value* processes = NULL; | 664 Value* processes = NULL; |
664 | 665 |
665 EXTENSION_FUNCTION_VALIDATE(args_->Get(0, &processes)); | 666 EXTENSION_FUNCTION_VALIDATE(args_->Get(0, &processes)); |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
744 DCHECK(process_ids_.size() == 0); | 745 DCHECK(process_ids_.size() == 0); |
745 } | 746 } |
746 | 747 |
747 SetResult(processes); | 748 SetResult(processes); |
748 SendResponse(true); | 749 SendResponse(true); |
749 | 750 |
750 // Balance the AddRef in the RunImpl. | 751 // Balance the AddRef in the RunImpl. |
751 Release(); | 752 Release(); |
752 #endif // defined(ENABLE_TASK_MANAGER) | 753 #endif // defined(ENABLE_TASK_MANAGER) |
753 } | 754 } |
OLD | NEW |