diff options
author | oshima <oshima@chromium.org> | 2016-03-24 16:41:39 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-03-24 23:42:44 +0000 |
commit | 6d221f22e58f3706147d2c8d5cec7b9fd2b3566b (patch) | |
tree | 2bf04393e61619162dd487fa902c913a8dc401e3 | |
parent | cd9d5adba632129e407b6cb5f5b9e6d8425062db (diff) | |
download | chromium_src-6d221f22e58f3706147d2c8d5cec7b9fd2b3566b.zip chromium_src-6d221f22e58f3706147d2c8d5cec7b9fd2b3566b.tar.gz chromium_src-6d221f22e58f3706147d2c8d5cec7b9fd2b3566b.tar.bz2 |
Address comments in the orignial CL
BUG=597274
TBR=stevenjb@chromium.org
Review URL: https://codereview.chromium.org/1827083003
Cr-Commit-Position: refs/heads/master@{#383190}
-rw-r--r-- | ash/display/display_layout_store.cc | 4 | ||||
-rw-r--r-- | ash/display/display_util.h | 2 | ||||
-rw-r--r-- | ash/display/extended_mouse_warp_controller.cc | 6 | ||||
-rw-r--r-- | ash/display/extended_mouse_warp_controller.h | 10 |
4 files changed, 13 insertions, 9 deletions
diff --git a/ash/display/display_layout_store.cc b/ash/display/display_layout_store.cc index faec7ab..5ede80b 100644 --- a/ash/display/display_layout_store.cc +++ b/ash/display/display_layout_store.cc @@ -50,8 +50,8 @@ void DisplayLayoutStore::SetDefaultDisplayPlacement( void DisplayLayoutStore::RegisterLayoutForDisplayIdList( const DisplayIdList& list, scoped_ptr<DisplayLayout> layout) { - // A dev/beta channel may have a bad layout data saved in local state. - // TODO(oshima): Consider removing this a coulpe of milestones later. + // m50/51 dev/beta channel may have bad layout data saved in local state. + // TODO(oshima): Consider removing this after m53. if (list.size() == 2 && layout->placement_list.size() > 1) return; diff --git a/ash/display/display_util.h b/ash/display/display_util.h index 3267d70..fc331cb 100644 --- a/ash/display/display_util.h +++ b/ash/display/display_util.h @@ -63,7 +63,7 @@ ASH_EXPORT bool SetDisplayUIScale(int64_t display_id, float scale); bool HasDisplayModeForUIScale(const DisplayInfo& info, float ui_scale); // Computes the bounds that defines the bounds between two displays. -// Returns false if two displays does not intersect. +// Returns false if two displays do not intersect. bool ComputeBoundary(const gfx::Display& primary_display, const gfx::Display& secondary_display, gfx::Rect* primary_edge_in_screen, diff --git a/ash/display/extended_mouse_warp_controller.cc b/ash/display/extended_mouse_warp_controller.cc index 26a199d..6e5273f3 100644 --- a/ash/display/extended_mouse_warp_controller.cc +++ b/ash/display/extended_mouse_warp_controller.cc @@ -104,7 +104,11 @@ ExtendedMouseWarpController::ExtendedMouseWarpController( int64_t drag_source_id = drag_source ? GetDisplayIdFromWindow(drag_source) : gfx::Display::kInvalidDisplayID; DisplayList display_list = display_manager->active_display_list(); - while (display_list.size() > 0) { + // Try to create a Warp region for all possible two displays combination. + // The following code does it by poping the last element in the list + // and then pairing with remaining displays in the list, until the list + // becomes single element. + while (display_list.size() > 1) { gfx::Display display = display_list.back(); display_list.pop_back(); for (const gfx::Display& peer : display_list) { diff --git a/ash/display/extended_mouse_warp_controller.h b/ash/display/extended_mouse_warp_controller.h index 1126ef3..05a6988 100644 --- a/ash/display/extended_mouse_warp_controller.h +++ b/ash/display/extended_mouse_warp_controller.h @@ -105,11 +105,11 @@ class ASH_EXPORT ExtendedMouseWarpController : public MouseWarpController { const gfx::Point& point_in_screen, bool update_mouse_location_now); - // Creates WarpRegion between display |a| and - // |b|. |drag_source_dispaly_id| is used to indicate in which - // display a drag is started, or invalid id passed if this is not - // for dragging. Returns null scoped_ptr if two displays do not - // share the edge. + // Creates WarpRegion between display |a| and |b|. + // |drag_source_dispaly_id| is used to indicate in which display a + // drag is started, or invalid id passed if this is not for + // dragging. Returns null scoped_ptr if two displays do not share + // the edge. scoped_ptr<WarpRegion> CreateWarpRegion(const gfx::Display& a, const gfx::Display& b, int64_t drag_source_dispay_id); |