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