OSDN Git Service

Fix shortcuts alignment in landscape
authorTony Wickham <twickham@google.com>
Sat, 10 Dec 2016 01:15:12 +0000 (17:15 -0800)
committerTony Wickham <twickham@google.com>
Fri, 20 Jan 2017 20:30:24 +0000 (12:30 -0800)
commit10bf35ff1a31688894b77dcaa4c56670c9486f70
tree8feb41e7d40ab49f34b6fb0486ce805693749d66
parenta2441e88ff862714d823d6c786b2d563047f75fc
Fix shortcuts alignment in landscape

- Take left inset into account.
- If there is no way to orient the shortcuts next to the icon,
  instead center it in the drag layer and don't draw the arrow.
- If possible, place the shortcuts to the left or right of the
  icon when centered vertically. If for whatever reason that
  isn't possible, center the shortcuts horizontally as well.

Bug: 33421656
Change-Id: I838b30ea487e0f7c64637db1cb8991ca3ee16bf9
src/com/android/launcher3/shortcuts/DeepShortcutsContainer.java