OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/cocoa/extension_view_mac.h" | 5 #include "chrome/browser/ui/cocoa/extensions/extension_view_mac.h" |
6 | 6 |
7 #include "chrome/browser/extensions/extension_host.h" | 7 #include "chrome/browser/extensions/extension_host.h" |
8 #include "chrome/browser/renderer_host/render_view_host.h" | 8 #include "chrome/browser/renderer_host/render_view_host.h" |
9 #include "chrome/browser/renderer_host/render_widget_host_view_mac.h" | 9 #include "chrome/browser/renderer_host/render_widget_host_view_mac.h" |
10 | 10 |
11 // The minimum/maximum dimensions of the popup. | 11 // The minimum/maximum dimensions of the popup. |
12 const CGFloat ExtensionViewMac::kMinWidth = 25.0; | 12 const CGFloat ExtensionViewMac::kMinWidth = 25.0; |
13 const CGFloat ExtensionViewMac::kMinHeight = 25.0; | 13 const CGFloat ExtensionViewMac::kMinHeight = 25.0; |
14 const CGFloat ExtensionViewMac::kMaxWidth = 800.0; | 14 const CGFloat ExtensionViewMac::kMaxWidth = 800.0; |
15 const CGFloat ExtensionViewMac::kMaxHeight = 600.0; | 15 const CGFloat ExtensionViewMac::kMaxHeight = 600.0; |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 DCHECK(!render_widget_host_view_); | 103 DCHECK(!render_widget_host_view_); |
104 render_widget_host_view_ = new RenderWidgetHostViewMac(render_view_host()); | 104 render_widget_host_view_ = new RenderWidgetHostViewMac(render_view_host()); |
105 | 105 |
106 // The RenderWidgetHostViewMac is owned by its native view, which is created | 106 // The RenderWidgetHostViewMac is owned by its native view, which is created |
107 // in an autoreleased state. retain it, so that it doesn't immediately | 107 // in an autoreleased state. retain it, so that it doesn't immediately |
108 // disappear. | 108 // disappear. |
109 [render_widget_host_view_->native_view() retain]; | 109 [render_widget_host_view_->native_view() retain]; |
110 | 110 |
111 extension_host_->CreateRenderViewSoon(render_widget_host_view_); | 111 extension_host_->CreateRenderViewSoon(render_widget_host_view_); |
112 } | 112 } |
OLD | NEW |