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

Unified Diff: ash/test/display_manager_test_api.h

Issue 2355063002: Separate ash::test::DisplayManagerTestApi from ash (Closed)
Patch Set: review comment Created 4 years, 2 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
« no previous file with comments | « ash/test/ash_test_impl_aura.cc ('k') | ash/test/display_manager_test_api.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/test/display_manager_test_api.h
diff --git a/ash/test/display_manager_test_api.h b/ash/test/display_manager_test_api.h
index b28a63cc77e3b1bc1c31e21fc3c150e734835e7b..5624aa82810d993990ea35163cb5d6fda18c7012 100644
--- a/ash/test/display_manager_test_api.h
+++ b/ash/test/display_manager_test_api.h
@@ -15,6 +15,10 @@
#include "ui/display/manager/display_layout.h"
#include "ui/display/types/display_constants.h"
+namespace display {
+class ManagedDisplayInfo;
+}
+
namespace gfx {
class Point;
class Size;
@@ -33,12 +37,7 @@ namespace test {
class DisplayManagerTestApi {
public:
- // Test if moving a mouse to |point_in_screen| warps it to another
- // display.
- static bool TestIfMouseWarpsAt(ui::test::EventGenerator& event_generator,
- const gfx::Point& point_in_screen);
-
- DisplayManagerTestApi();
+ explicit DisplayManagerTestApi(DisplayManager* display_manager);
virtual ~DisplayManagerTestApi();
// Update the display configuration as given in |display_specs|. The format of
@@ -59,6 +58,10 @@ class DisplayManagerTestApi {
int64_t display_id,
const std::vector<ui::ColorCalibrationProfile>& profiles);
+ // Gets the internal display::ManagedDisplayInfo for a specific display id.
+ const display::ManagedDisplayInfo& GetInternalManagedDisplayInfo(
+ int64_t display_id);
+
private:
friend class ScopedSetInternalDisplayId;
// Sets the display id for internal display and
@@ -81,7 +84,7 @@ class ScopedDisable125DSFForUIScaling {
class ScopedSetInternalDisplayId {
public:
- ScopedSetInternalDisplayId(int64_t id);
+ ScopedSetInternalDisplayId(DisplayManager* test_api, int64_t id);
~ScopedSetInternalDisplayId();
private:
@@ -89,10 +92,9 @@ class ScopedSetInternalDisplayId {
};
// Sets the display mode that matches the |resolution| for |display_id|.
-bool SetDisplayResolution(int64_t display_id, const gfx::Size& resolution);
-
-// Swap the primary display with the secondary.
-void SwapPrimaryDisplay();
+bool SetDisplayResolution(DisplayManager* display_manager,
+ int64_t display_id,
+ const gfx::Size& resolution);
// Creates the dislpay layout from position and offset for the current
// display list. If you simply want to create a new layout that is
@@ -100,6 +102,7 @@ void SwapPrimaryDisplay();
// create a new DisplayLayout and set display id fields (primary, ids
// in placement) manually.
std::unique_ptr<display::DisplayLayout> CreateDisplayLayout(
+ DisplayManager* display_manager,
display::DisplayPlacement::Position position,
int offset);
« no previous file with comments | « ash/test/ash_test_impl_aura.cc ('k') | ash/test/display_manager_test_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698