The issue was that scrolling past the top or bottom of the view caused the band
select rectangle to grow in the wrong direction. This was caused by adjusting
the origin of the band select rectangle based on the calculated number of pixels
to scroll instead of the actual number of pixels scrolled. There can be a
discrepancy when the calculated value is higher than the maximum that can be
scrolled (when the view is already scroll almost to the top or bottom of the
view).
Bug: 23081362
Change-Id: I343cdec89260ab0571a792009d0c08585ed41199
This consists of:
1) Moving both BandSelect* classes into MultiSelectManager as nested
classes. This removes extra layers of indirection and makes code easier
to comprehend.
2) Fixing an issue where band selection could start within an item
instead of only within margins between items.
3) Adding "provisional selection" support to the Selection class. This
gives band select the ability to select some items "temporarily" such
that when the band select no longer covers those items, they are
deselected.
4) Adding glue code between the classes.
Bug: 23081429, 23083146, 20669231
Change-Id: I0dc57e2c0d2ccedb3e1218f0e496de637be227a2
This makes more space available for content.
Rename all the "Standalone" stuff to just "Files".
Move layout inflation into base class.
Move backbutton > drawer interaction into BaseActivity.
Change-Id: Ie778b323c6e80122389f029be148dd9e0c4bfb6e
Fix a bug that is causing thumbnail size to be 80px regardless of the
display mode. This causes larger thumbnails to be used in grid mode,
resulting in better image quality.
BUG=23385406
Change-Id: Ic62ed0de1c6326a7ccd9ca31bdead15b49c481c1
Introduce a new GridItem class whose onMeasure method enforces a square
aspect ratio, and use it for rendering items when in grid mode.
Change-Id: Ieda82b644d0155354ee8e4c1dacae4af7436b7aa
Normalize use of Annotations like VisibleForTesting, Nullable and so on.
Also, fix a small issue where we were not doubling the marging on cells when calculating columns for grid view.
Change-Id: Ia02f683c2682fa8d0963d13f253a359911d27965
Update Standalone mode to use drawer on smaller form factors.
While we're not implementing this now, we'll probably want
to switch to drawer mode when in portrait mode, even on relatively
larger devices.
Change-Id: I244cd3c6021d63cf43d0631a5397b05339a96ced
This is required for some of the intent invoked modes when the
"ALLOW_MULTI_SELECT" extra is not present.
Bug: 23155138
Change-Id: Ib92512c7f1c8e906ecca98d69ff727fc865fd53e
Now, if band select reaches the top or bottom of the view, the view scrolls in that direction. Very fast scrolls may cause some items not to be selected properly, but this will be fixed in a future CL.
BUG=20669231
Change-Id: Ie3110156c69ec620713c4929d2583c2ed5ab32df
Double clicking an item opens it.
BandSelectManager tells MultiSelectManager where its selection begins
so Shift+Click behavior can be complimentary.
BandSelectManager more actively manages selection...so it doesn't
clear existing selection on mouse down.
Change-Id: Ibe65e793e84463d333a19f363dfb0d42c37480e3
Use margin instead of padding (so clicks on empty space don't do unexpected things).
Make background of items white.
Change-Id: I98996c90276911535b7addad1aad4a3c9ca47156