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

Unified Diff: ash/display/display_util.h

Issue 2270553002: Move ash::DisplayInfo to ui (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: build Created 4 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 side-by-side diff with in-line comments
Download patch
Index: ash/display/display_util.h
diff --git a/ash/display/display_util.h b/ash/display/display_util.h
index b5f5d49073446b1443b65c9a60cf8e274061f191..483f9d1aa7968161015463ad7ce016f3c2d36233 100644
--- a/ash/display/display_util.h
+++ b/ash/display/display_util.h
@@ -12,9 +12,9 @@
#include <vector>
#include "ash/ash_export.h"
-#include "ash/common/display/display_info.h"
#include "base/memory/ref_counted.h"
#include "ui/display/manager/display_layout.h"
+#include "ui/display/manager/managed_display_info.h"
namespace gfx {
class Point;
@@ -22,48 +22,51 @@ class Rect;
class Size;
}
+namespace ui {
+class ManagedDisplayInfo;
+}
+
namespace ash {
class AshWindowTreeHost;
class ManagedDisplayMode;
-class DisplayInfo;
// Creates the display mode list for internal display
// based on |native_mode|.
-ASH_EXPORT DisplayInfo::ManagedDisplayModeList
+ASH_EXPORT ui::ManagedDisplayInfo::ManagedDisplayModeList
CreateInternalManagedDisplayModeList(
- const scoped_refptr<ManagedDisplayMode>& native_mode);
+ const scoped_refptr<ui::ManagedDisplayMode>& native_mode);
// Creates the display mode list for unified display
// based on |native_mode| and |scales|.
-ASH_EXPORT DisplayInfo::ManagedDisplayModeList
+ASH_EXPORT ui::ManagedDisplayInfo::ManagedDisplayModeList
CreateUnifiedManagedDisplayModeList(
- const scoped_refptr<ManagedDisplayMode>& native_mode,
+ const scoped_refptr<ui::ManagedDisplayMode>& native_mode,
const std::set<std::pair<float, float>>& dsf_scale_list);
// Gets the display mode for |resolution|. Returns false if no display
// mode matches the resolution, or the display is an internal display.
-ASH_EXPORT scoped_refptr<ManagedDisplayMode> GetDisplayModeForResolution(
- const DisplayInfo& info,
+ASH_EXPORT scoped_refptr<ui::ManagedDisplayMode> GetDisplayModeForResolution(
+ const ui::ManagedDisplayInfo& info,
const gfx::Size& resolution);
// Gets the display mode for the next valid UI scale. Returns false
// if the display is not an internal display.
-ASH_EXPORT scoped_refptr<ManagedDisplayMode> GetDisplayModeForNextUIScale(
- const DisplayInfo& info,
+ASH_EXPORT scoped_refptr<ui::ManagedDisplayMode> GetDisplayModeForNextUIScale(
+ const ui::ManagedDisplayInfo& info,
bool up);
// Gets the display mode for the next valid resolution. Returns false
// if the display is an internal display.
-ASH_EXPORT scoped_refptr<ManagedDisplayMode> GetDisplayModeForNextResolution(
- const DisplayInfo& info,
- bool up);
+ASH_EXPORT scoped_refptr<ui::ManagedDisplayMode>
+GetDisplayModeForNextResolution(const ui::ManagedDisplayInfo& info, bool up);
// Sets the UI scale for the |display_id|. Returns false if the
// display_id is not an internal display.
ASH_EXPORT bool SetDisplayUIScale(int64_t display_id, float scale);
// Tests if the |info| has display mode that matches |ui_scale|.
-bool HasDisplayModeForUIScale(const DisplayInfo& info, float ui_scale);
+bool HasDisplayModeForUIScale(const ui::ManagedDisplayInfo& info,
+ float ui_scale);
// Computes the bounds that defines the bounds between two displays.
// Returns false if two displays do not intersect.

Powered by Google App Engine
This is Rietveld 408576698