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

Side by Side Diff: ash/display/mirror_window_controller.h

Issue 15730006: Use the source display's pixel size as a mirror window's size. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: addressed comments Created 7 years, 6 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 | « ash/display/display_manager_unittest.cc ('k') | ash/display/mirror_window_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 ASH_DISPLAY_MIRROR_WINDOW_CONTROLLER_H_ 5 #ifndef ASH_DISPLAY_MIRROR_WINDOW_CONTROLLER_H_
6 #define ASH_DISPLAY_MIRROR_WINDOW_CONTROLLER_H_ 6 #define ASH_DISPLAY_MIRROR_WINDOW_CONTROLLER_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 19 matching lines...) Expand all
30 // is typically drawn by the window system. 30 // is typically drawn by the window system.
31 class MirrorWindowController { 31 class MirrorWindowController {
32 public: 32 public:
33 MirrorWindowController(); 33 MirrorWindowController();
34 ~MirrorWindowController(); 34 ~MirrorWindowController();
35 35
36 // Updates the root window's bounds using |display_info|. 36 // Updates the root window's bounds using |display_info|.
37 // Creates the new root window if one doesn't exist. 37 // Creates the new root window if one doesn't exist.
38 void UpdateWindow(const DisplayInfo& display_info); 38 void UpdateWindow(const DisplayInfo& display_info);
39 39
40 // Same as above, but using existing display info
41 // for the mirrored display.
42 void UpdateWindow();
43
44 // Close the mirror window.
40 void Close(); 45 void Close();
41 46
42 // Updates the mirrored cursor location,shape and 47 // Updates the mirrored cursor location,shape and
43 // visibility. 48 // visibility.
44 void UpdateCursorLocation(); 49 void UpdateCursorLocation();
45 void SetMirroredCursor(gfx::NativeCursor cursor); 50 void SetMirroredCursor(gfx::NativeCursor cursor);
46 void SetMirroredCursorVisibility(bool visible); 51 void SetMirroredCursorVisibility(bool visible);
47 52
48 private: 53 private:
49 friend class test::MirrorWindowTestApi; 54 friend class test::MirrorWindowTestApi;
50 55
51 int current_cursor_type_; 56 int current_cursor_type_;
52 aura::Window* cursor_window_; // owned by root window. 57 aura::Window* cursor_window_; // owned by root window.
53 scoped_ptr<aura::RootWindow> root_window_; 58 scoped_ptr<aura::RootWindow> root_window_;
54 scoped_ptr<CursorWindowDelegate> cursor_window_delegate_; 59 scoped_ptr<CursorWindowDelegate> cursor_window_delegate_;
55 gfx::Point hot_point_; 60 gfx::Point hot_point_;
56 61
57 DISALLOW_COPY_AND_ASSIGN(MirrorWindowController); 62 DISALLOW_COPY_AND_ASSIGN(MirrorWindowController);
58 }; 63 };
59 64
60 } // namespace internal 65 } // namespace internal
61 } // namespace ash 66 } // namespace ash
62 67
63 #endif // ASH_DISPLAY_MIRROR_WINDOW_CONTROLLER_H_ 68 #endif // ASH_DISPLAY_MIRROR_WINDOW_CONTROLLER_H_
OLDNEW
« no previous file with comments | « ash/display/display_manager_unittest.cc ('k') | ash/display/mirror_window_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698