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 #ifndef UI_VIEWS_VIEWS_DELEGATE_H_ | 5 #ifndef UI_VIEWS_VIEWS_DELEGATE_H_ |
6 #define UI_VIEWS_VIEWS_DELEGATE_H_ | 6 #define UI_VIEWS_VIEWS_DELEGATE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #if defined(OS_WIN) | 10 #if defined(OS_WIN) |
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
102 virtual void AddRef() = 0; | 102 virtual void AddRef() = 0; |
103 virtual void ReleaseRef() = 0; | 103 virtual void ReleaseRef() = 0; |
104 | 104 |
105 // Converts ui::Event::flags to a WindowOpenDisposition. | 105 // Converts ui::Event::flags to a WindowOpenDisposition. |
106 virtual int GetDispositionForEvent(int event_flags) = 0; | 106 virtual int GetDispositionForEvent(int event_flags) = 0; |
107 | 107 |
108 #if defined(USE_AURA) | 108 #if defined(USE_AURA) |
109 // Creates an object that implements desktop integration behavior. Returned | 109 // Creates an object that implements desktop integration behavior. Returned |
110 // object is owned by the NativeWidgetAura passed in. May return NULL. | 110 // object is owned by the NativeWidgetAura passed in. May return NULL. |
111 virtual NativeWidgetHelperAura* CreateNativeWidgetHelper( | 111 virtual NativeWidgetHelperAura* CreateNativeWidgetHelper( |
112 NativeWidgetAura* native_widget) = 0; | 112 NativeWidgetAura* native_widget, gfx::NativeView parent) = 0; |
113 #endif | 113 #endif |
114 | 114 |
115 // Creates a web contents. This will return NULL unless overriden. | 115 // Creates a web contents. This will return NULL unless overriden. |
116 virtual content::WebContents* CreateWebContents( | 116 virtual content::WebContents* CreateWebContents( |
117 content::BrowserContext* browser_context, | 117 content::BrowserContext* browser_context, |
118 content::SiteInstance* site_instance) = 0; | 118 content::SiteInstance* site_instance) = 0; |
119 | 119 |
120 // Creates a NativeWidget implementation. Returning NULL means Widget will | 120 // Creates a NativeWidget implementation. Returning NULL means Widget will |
121 // create a default implementation for the platform. | 121 // create a default implementation for the platform. |
122 virtual NativeWidget* CreateNativeWidget( | 122 virtual NativeWidget* CreateNativeWidget( |
123 Widget::InitParams::Type type, | 123 Widget::InitParams::Type type, |
124 internal::NativeWidgetDelegate* delegate, | 124 internal::NativeWidgetDelegate* delegate, |
125 gfx::NativeView parent) = 0; | 125 gfx::NativeView parent) = 0; |
126 }; | 126 }; |
127 | 127 |
128 } // namespace views | 128 } // namespace views |
129 | 129 |
130 #endif // UI_VIEWS_VIEWS_DELEGATE_H_ | 130 #endif // UI_VIEWS_VIEWS_DELEGATE_H_ |
OLD | NEW |