| 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 "content/shell/renderer/layout_test/blink_test_runner.h" | 5 #include "content/shell/renderer/layout_test/blink_test_runner.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <clocale> | 8 #include <clocale> |
| 9 #include <cmath> | 9 #include <cmath> |
| 10 | 10 |
| (...skipping 659 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 670 const GURL& url, | 670 const GURL& url, |
| 671 const base::Callback<void(const blink::WebURLResponse& response, | 671 const base::Callback<void(const blink::WebURLResponse& response, |
| 672 const std::string& data)>& callback) { | 672 const std::string& data)>& callback) { |
| 673 ::content::FetchManifest(view, url, callback); | 673 ::content::FetchManifest(view, url, callback); |
| 674 } | 674 } |
| 675 | 675 |
| 676 void BlinkTestRunner::SetPermission(const std::string& name, | 676 void BlinkTestRunner::SetPermission(const std::string& name, |
| 677 const std::string& value, | 677 const std::string& value, |
| 678 const GURL& origin, | 678 const GURL& origin, |
| 679 const GURL& embedding_origin) { | 679 const GURL& embedding_origin) { |
| 680 content::PermissionStatus status; | 680 permission::Status status; |
| 681 if (value == "granted") | 681 if (value == "granted") |
| 682 status = PERMISSION_STATUS_GRANTED; | 682 status = permission::STATUS_GRANTED; |
| 683 else if (value == "prompt") | 683 else if (value == "prompt") |
| 684 status = PERMISSION_STATUS_ASK; | 684 status = permission::STATUS_ASK; |
| 685 else if (value == "denied") | 685 else if (value == "denied") |
| 686 status = PERMISSION_STATUS_DENIED; | 686 status = permission::STATUS_DENIED; |
| 687 else { | 687 else { |
| 688 NOTREACHED(); | 688 NOTREACHED(); |
| 689 status = PERMISSION_STATUS_DENIED; | 689 status = permission::STATUS_DENIED; |
| 690 } | 690 } |
| 691 | 691 |
| 692 Send(new LayoutTestHostMsg_SetPermission( | 692 Send(new LayoutTestHostMsg_SetPermission( |
| 693 routing_id(), name, status, origin, embedding_origin)); | 693 routing_id(), name, status, origin, embedding_origin)); |
| 694 } | 694 } |
| 695 | 695 |
| 696 void BlinkTestRunner::ResetPermissions() { | 696 void BlinkTestRunner::ResetPermissions() { |
| 697 Send(new LayoutTestHostMsg_ResetPermissions(routing_id())); | 697 Send(new LayoutTestHostMsg_ResetPermissions(routing_id())); |
| 698 } | 698 } |
| 699 | 699 |
| (...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 963 get_bluetooth_events_callbacks_.pop_front(); | 963 get_bluetooth_events_callbacks_.pop_front(); |
| 964 callback.Run(events); | 964 callback.Run(events); |
| 965 } | 965 } |
| 966 | 966 |
| 967 void BlinkTestRunner::ReportLeakDetectionResult( | 967 void BlinkTestRunner::ReportLeakDetectionResult( |
| 968 const LeakDetectionResult& report) { | 968 const LeakDetectionResult& report) { |
| 969 Send(new ShellViewHostMsg_LeakDetectionDone(routing_id(), report)); | 969 Send(new ShellViewHostMsg_LeakDetectionDone(routing_id(), report)); |
| 970 } | 970 } |
| 971 | 971 |
| 972 } // namespace content | 972 } // namespace content |
| OLD | NEW |