Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: ui/views/win/fullscreen_handler.h

Issue 10871020: Move Fullscreen stuff onto FullscreenHandler type that hangs off NWW. This is the first step in mov… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ui/views/win/DEPS ('k') | ui/views/win/fullscreen_handler.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef UI_VIEWS_WIN_FULLSCREEN_HANDLER_H_
6 #define UI_VIEWS_WIN_FULLSCREEN_HANDLER_H_
7
8 #include <windows.h>
9
10 #include <map>
11
12 #include "base/basictypes.h"
13
14 namespace gfx {
15 class Rect;
16 }
17
18 namespace views {
19
20 // TODO(beng): Temporary dependancy until fullscreen moves to
21 // HWNDMessageHandler.
22 class Widget;
23
24 class FullscreenHandler {
25 public:
26 explicit FullscreenHandler(Widget* widget);
27 ~FullscreenHandler();
28
29 void SetFullscreen(bool fullscreen);
30 void SetMetroSnap(bool metro_snap);
31
32 gfx::Rect GetRestoreBounds() const;
33
34 bool fullscreen() const { return fullscreen_; }
35 bool metro_snap() const { return metro_snap_; }
36
37 private:
38 // Information saved before going into fullscreen mode, used to restore the
39 // window afterwards.
40 struct SavedWindowInfo {
41 bool maximized;
42 LONG style;
43 LONG ex_style;
44 RECT window_rect;
45 };
46
47 void SetFullscreenImpl(bool fullscreen, bool for_metro);
48
49 Widget* widget_;
50 bool fullscreen_;
51 bool metro_snap_;
52
53 // Saved window information from before entering fullscreen mode.
54 // TODO(beng): move to private once GetRestoredBounds() moves onto Widget.
55 SavedWindowInfo saved_window_info_;
56
57 DISALLOW_COPY_AND_ASSIGN(FullscreenHandler);
58 };
59
60 } // namespace views
61
62 #endif // UI_VIEWS_WIN_FULLSCREEN_HANDLER_H_
OLDNEW
« no previous file with comments | « ui/views/win/DEPS ('k') | ui/views/win/fullscreen_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698