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

Side by Side Diff: ui/display/chromeos/display_snapshot_virtual.h

Issue 615133002: Add support for a virtual display on ChromeOS (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove ash/ dep from content Created 5 years, 9 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef UI_DISPLAY_TYPES_DISPLAY_SNAPSHOT_VIRTUAL_H_
6 #define UI_DISPLAY_TYPES_DISPLAY_SNAPSHOT_VIRTUAL_H_
7
8 #include "ui/display/types/display_snapshot.h"
9
10 #include "base/memory/scoped_ptr.h"
11 #include "ui/display/types/display_mode.h"
12
13 namespace ui {
14
15 // This class represents a virtual display to be enabled on demand. The display
16 // is constructed for the desired pixel resolution.
17 class DisplaySnapshotVirtual : public DisplaySnapshot {
18 public:
19 // |display_id| is the numerical identifier for the virtual display,
20 // |display_size| is the pixel dimensions for the display.
21 DisplaySnapshotVirtual(int64_t display_id, gfx::Size display_size);
22 ~DisplaySnapshotVirtual() override;
23
24 // DisplaySnapshot overrides.
25 std::string ToString() const override;
26
27 // Update the identifer to |display_id|. This is used by DisplayConfigurator
28 // to update the virtual display's id after the physical displays are
29 // enumerated.
30 void set_display_id(int64_t display_id) { display_id_ = display_id; }
31
32 private:
33 scoped_ptr<DisplayMode> mode_;
34 DISALLOW_COPY_AND_ASSIGN(DisplaySnapshotVirtual);
35 };
36
37 } // namespace ui
38
39 #endif // UI_DISPLAY_TYPES_DISPLAY_SNAPSHOT_VIRTUAL_H_
OLDNEW
« no previous file with comments | « ui/display/chromeos/display_configurator_unittest.cc ('k') | ui/display/chromeos/display_snapshot_virtual.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698