| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_WIDGET_NATIVE_WIDGET_MAC_H_ | 5 #ifndef UI_VIEWS_WIDGET_NATIVE_WIDGET_MAC_H_ |
| 6 #define UI_VIEWS_WIDGET_NATIVE_WIDGET_MAC_H_ | 6 #define UI_VIEWS_WIDGET_NATIVE_WIDGET_MAC_H_ |
| 7 | 7 |
| 8 #include "ui/gfx/native_widget_types.h" | 8 #include "ui/gfx/native_widget_types.h" |
| 9 #include "ui/views/widget/native_widget_private.h" | 9 #include "ui/views/widget/native_widget_private.h" |
| 10 | 10 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 // Return true if the delegate's modal type is window-modal. These display as | 28 // Return true if the delegate's modal type is window-modal. These display as |
| 29 // a native window "sheet", and have a different lifetime to regular windows. | 29 // a native window "sheet", and have a different lifetime to regular windows. |
| 30 bool IsWindowModalSheet() const; | 30 bool IsWindowModalSheet() const; |
| 31 | 31 |
| 32 // Deletes |bridge_| and informs |delegate_| that the native widget is | 32 // Deletes |bridge_| and informs |delegate_| that the native widget is |
| 33 // destroyed. | 33 // destroyed. |
| 34 // This is usually called from the NSWindowDelegate. A derived class can | 34 // This is usually called from the NSWindowDelegate. A derived class can |
| 35 // override this method for an early hook into the native window teardown. | 35 // override this method for an early hook into the native window teardown. |
| 36 virtual void OnWindowWillClose(); | 36 virtual void OnWindowWillClose(); |
| 37 | 37 |
| 38 // Called by BridgedNativeWidget so NativeWidgetMac can be notified of |
| 39 // fullscreen changes. |
| 40 virtual void OnFullscreenTransitionComplete(bool is_fullscreen); |
| 41 |
| 38 // internal::NativeWidgetPrivate: | 42 // internal::NativeWidgetPrivate: |
| 39 void InitNativeWidget(const Widget::InitParams& params) override; | 43 void InitNativeWidget(const Widget::InitParams& params) override; |
| 40 NonClientFrameView* CreateNonClientFrameView() override; | 44 NonClientFrameView* CreateNonClientFrameView() override; |
| 41 bool ShouldUseNativeFrame() const override; | 45 bool ShouldUseNativeFrame() const override; |
| 42 bool ShouldWindowContentsBeTransparent() const override; | 46 bool ShouldWindowContentsBeTransparent() const override; |
| 43 void FrameTypeChanged() override; | 47 void FrameTypeChanged() override; |
| 44 Widget* GetWidget() override; | 48 Widget* GetWidget() override; |
| 45 const Widget* GetWidget() const override; | 49 const Widget* GetWidget() const override; |
| 46 gfx::NativeView GetNativeView() const override; | 50 gfx::NativeView GetNativeView() const override; |
| 47 gfx::NativeWindow GetNativeWindow() const override; | 51 gfx::NativeWindow GetNativeWindow() const override; |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 scoped_ptr<BridgedNativeWidget> bridge_; | 141 scoped_ptr<BridgedNativeWidget> bridge_; |
| 138 | 142 |
| 139 Widget::InitParams::Ownership ownership_; | 143 Widget::InitParams::Ownership ownership_; |
| 140 | 144 |
| 141 DISALLOW_COPY_AND_ASSIGN(NativeWidgetMac); | 145 DISALLOW_COPY_AND_ASSIGN(NativeWidgetMac); |
| 142 }; | 146 }; |
| 143 | 147 |
| 144 } // namespace views | 148 } // namespace views |
| 145 | 149 |
| 146 #endif // UI_VIEWS_WIDGET_NATIVE_WIDGET_MAC_H_ | 150 #endif // UI_VIEWS_WIDGET_NATIVE_WIDGET_MAC_H_ |
| OLD | NEW |