| 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_WIN_FULLSCREEN_HANDLER_H_ | 5 #ifndef UI_VIEWS_WIN_FULLSCREEN_HANDLER_H_ |
| 6 #define UI_VIEWS_WIN_FULLSCREEN_HANDLER_H_ | 6 #define UI_VIEWS_WIN_FULLSCREEN_HANDLER_H_ |
| 7 | 7 |
| 8 #include <windows.h> | 8 #include <windows.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 void SetFullscreen(bool fullscreen); | 27 void SetFullscreen(bool fullscreen); |
| 28 | 28 |
| 29 gfx::Rect GetRestoreBounds() const; | 29 gfx::Rect GetRestoreBounds() const; |
| 30 | 30 |
| 31 bool fullscreen() const { return fullscreen_; } | 31 bool fullscreen() const { return fullscreen_; } |
| 32 | 32 |
| 33 private: | 33 private: |
| 34 // Information saved before going into fullscreen mode, used to restore the | 34 // Information saved before going into fullscreen mode, used to restore the |
| 35 // window afterwards. | 35 // window afterwards. |
| 36 struct SavedWindowInfo { | 36 struct SavedWindowInfo { |
| 37 bool maximized; | |
| 38 LONG style; | 37 LONG style; |
| 39 LONG ex_style; | 38 LONG ex_style; |
| 40 RECT window_rect; | 39 RECT window_rect; |
| 41 }; | 40 }; |
| 42 | 41 |
| 43 void SetFullscreenImpl(bool fullscreen); | 42 void SetFullscreenImpl(bool fullscreen); |
| 44 | 43 |
| 45 HWND hwnd_; | 44 HWND hwnd_; |
| 46 bool fullscreen_; | 45 bool fullscreen_; |
| 47 | 46 |
| 48 // Saved window information from before entering fullscreen mode. | 47 // Saved window information from before entering fullscreen mode. |
| 49 // TODO(beng): move to private once GetRestoredBounds() moves onto Widget. | 48 // TODO(beng): move to private once GetRestoredBounds() moves onto Widget. |
| 50 SavedWindowInfo saved_window_info_; | 49 SavedWindowInfo saved_window_info_; |
| 51 | 50 |
| 52 DISALLOW_COPY_AND_ASSIGN(FullscreenHandler); | 51 DISALLOW_COPY_AND_ASSIGN(FullscreenHandler); |
| 53 }; | 52 }; |
| 54 | 53 |
| 55 } // namespace views | 54 } // namespace views |
| 56 | 55 |
| 57 #endif // UI_VIEWS_WIN_FULLSCREEN_HANDLER_H_ | 56 #endif // UI_VIEWS_WIN_FULLSCREEN_HANDLER_H_ |
| OLD | NEW |