| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/website_settings/mock_permission_bubble_view.h" | 5 #include "chrome/browser/ui/website_settings/mock_permission_bubble_view.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/run_loop.h" | 8 #include "base/run_loop.h" |
| 9 #include "chrome/browser/ui/website_settings/permission_bubble_manager.h" | 9 #include "chrome/browser/ui/website_settings/permission_bubble_manager.h" |
| 10 | 10 |
| 11 // TODO(hcarmona): compile this |
| 12 |
| 11 MockPermissionBubbleView::~MockPermissionBubbleView() {} | 13 MockPermissionBubbleView::~MockPermissionBubbleView() {} |
| 12 | 14 |
| 13 // Static | 15 // Static |
| 14 scoped_ptr<PermissionBubbleView> MockPermissionBubbleView::CreateBrowserMock( | 16 scoped_ptr<PermissionBubbleView> MockPermissionBubbleView::CreateBrowserMock( |
| 15 Browser* browser) { | 17 Browser* browser) { |
| 16 return make_scoped_ptr(new MockPermissionBubbleView(true)); | 18 return make_scoped_ptr(new MockPermissionBubbleView(true)); |
| 17 } | 19 } |
| 18 | 20 |
| 19 // Static | 21 // Static |
| 20 scoped_ptr<PermissionBubbleView> MockPermissionBubbleView::CreateUnitMock( | 22 scoped_ptr<PermissionBubbleView> MockPermissionBubbleView::CreateUnitMock( |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 browser_test_ = browser_test; | 102 browser_test_ = browser_test; |
| 101 } | 103 } |
| 102 | 104 |
| 103 MockPermissionBubbleView::MockPermissionBubbleView(bool browser_test) | 105 MockPermissionBubbleView::MockPermissionBubbleView(bool browser_test) |
| 104 : visible_(false), | 106 : visible_(false), |
| 105 show_count_(0), | 107 show_count_(0), |
| 106 requests_count_(0), | 108 requests_count_(0), |
| 107 can_accept_updates_(true), | 109 can_accept_updates_(true), |
| 108 delegate_(nullptr), | 110 delegate_(nullptr), |
| 109 browser_test_(browser_test) {} | 111 browser_test_(browser_test) {} |
| OLD | NEW |