124 Commits

Author SHA1 Message Date
Ben Kwa
fd53fdeed3 Update apostophes to material spec.
TLDR: use \u2019 instead of ' for apostrophes.

See
https://spec.googleplex.com/quantum/style/writing.html#writing-capitalization-punctuation.

Change-Id: Idc3bee55dc65a1ebd5bf12483fced85d36c1614f
2016-02-05 08:02:21 -08:00
Ben Kwa
1c3966a389 Merge "Tweak the query error message per UX." 2016-02-05 03:09:44 +00:00
Ben Kwa
c9b3bde667 Tweak the query error message per UX.
BUG=24949214

Change-Id: I207b55ebfff47cc561a536dc1827431545bf0030
2016-02-04 19:06:56 -08:00
Steve McKay
1f264a8a1a Normalize toolbar management.
Since it was almost all redundant (especially the stack stuff).
Ensure "Files" title present on drawer title in Files app.
DocumentsToolBar > DocumentsToolbar to match toolkit naming.

Bug: 26193264
Change-Id: I92c82c66d936aae3ce0f792581daa12898dfadee
2016-02-03 17:59:06 -08:00
Steve McKay
efa1761776 Decouple SD card from ADVANCED storage toggle.
A variety of related fixes:
- don't force size enable when browsing from device mounted notifications.
- don't show settings menu item as action (put in overflow).
- add sd card icon (not quite yet used, need to suss that out).

Bug:26880985,26883578,26771127
Change-Id: I36f153c42217f8092f157ded2a756c02525593ab
2016-02-02 09:28:30 -08:00
Steve McKay
5fe5c458dc Files always visible, same for new window menu.
Remove "productivity_device" bit.

Change-Id: I28ee3e210fc5f8c367d45a74edab0e04667ddd5e
2016-01-28 11:43:08 -08:00
Tomasz Mikolajewski
748ea8cc78 Show a warning notification and a dialog in case of conversion when copying.
Change-Id: I451b0944069deb5f0b49b54c514e7761be449e3d
2016-01-28 13:12:55 +09:00
Steve McKay
0bbf302573 Merge "Remove variants of "show/hide" internal storage string." 2016-01-27 19:47:50 +00:00
Steve McKay
de3f4c89ca Merge "Revert "Eliminate the "productivity_device" setting."" 2016-01-27 19:25:07 +00:00
Steve McKay
8fa9ffcdc0 Revert "Eliminate the "productivity_device" setting."
This reverts commit d0a0fc2cd1fbb629f329cf10e0413a674a8e54b6.

Missed a use. Prema-revert.

Change-Id: I6bce595646e2e2bf1e506388a2da9e1cd8f61a09
2016-01-27 19:24:25 +00:00
Ben Kwa
3ca3a3db5e Merge "Eliminate the "productivity_device" setting." 2016-01-27 18:48:01 +00:00
Felipe Leme
b012f913cb Initial implementation of OPEN_EXTERNAL_DIRECTORY.
It opens a an alert dialog that tells user application X is requesting
access to folder Y on volume Z; if user accepts, it returns the proper
URI, otherwise it returns RESULT_CANCELED.

The requested path must satisfy the following requirements:

1.It's directory (getName()) must be one of the pre-definied folders on
  Environment.
2.It's root (getParent()) must be a valid external storage root.

In order to satisfy #2, DocumentsUI calls the ExternalStorageProvider,
through a custom call() implementation.

BUG:  23011462
Change-Id: I8e491e82ae320df88f7b8923286c4c1ad050ae80
2016-01-27 08:52:58 -08:00
Steve McKay
e3a798c559 Remove variants of "show/hide" internal storage string.
Bug: 26768708
Change-Id: I62a5068eab3104ab379bb0f22a609b9cf0b6777b
2016-01-26 17:45:35 -08:00
Steve McKay
d0a0fc2cd1 Eliminate the "productivity_device" setting.
Files will be available  to all in N.

Change-Id: I964b581c06dea6dfa848624c36566090544509f1
2016-01-26 16:58:12 -08:00
Tomasz Mikolajewski
af231f0a67 Remove retry logic from DocumentsUI.
Bug: 26720030
Change-Id: I041caeed7243614e20d92e1bb3308f564f6aae34
2016-01-25 17:25:20 +09:00
Steve McKay
8d4d5c1c20 Merge "Change "touch" to "tap"." 2016-01-22 23:46:17 +00:00
Steve McKay
9814a1a62e Change "touch" to "tap".
Bug: 26744850
Change-Id: I2f0f0c817ea40de4fbc6ef21e68ccbde293d3135
2016-01-22 15:44:49 -08:00
Aga Wronska
31f97bc4ee Merge "Add support for renaming documents" 2016-01-22 23:26:35 +00:00
Aga Wronska
3b327ef9f9 Add support for renaming documents
- Add rename dialog
- Add rename menu option
- Enable rename menu option only when renaming supported
- Rename files and directories
- Present error message if renaming fails

Bug: 20493815
Change-Id: Ic7386d14e3876655fb19245b9a90b4c67a4febb4
2016-01-22 13:36:40 -08:00
Steve McKay
9ed88a4da7 Show empty file cabinet for no search results.
And for empty directory.

Magic-submit? Yes please!

Change-Id: If9e1f8ab48eebd9c275ad043da728e28b850ab73
2016-01-22 11:59:16 -08:00
Steve McKay
3564543e1e Move delete support into FileOperationService.
Refactor Jobs to work with files from multiple providers.
Don't shut down threadpool until service#onDestroy is called.

Bug: 26696797, 26462789, 26567205, 25162803, 26714663
Change-Id: Id43e8e3dc2294cd07dcd6a3477b19efb298c260f
2016-01-21 12:16:04 -08:00
Ben Kwa
b0fed2b72e Merge "Embiggen the progress bar." 2016-01-12 21:56:39 +00:00
Ben Kwa
a66cebde23 Embiggen the progress bar.
BUG=26159818

Change-Id: I12a33be503dd29d03cb85b814b287879c016275d
2016-01-12 13:36:44 -08:00
Steve McKay
76be620a6f Grid view padding + explicit background.
Also move section break holder into the wrapper class.

Change-Id: I949e81af180f11514aff558615cfeda44cb96a3c
2016-01-12 11:41:26 -08:00
Aga Wronska
d3b8e52009 Merge "Keep Search View visible after search completed Improve Search View behavior Add Search View background color" 2016-01-11 23:05:43 +00:00
Aga Wronska
97831485e7 Keep Search View visible after search completed
Improve Search View behavior
Add Search View background color

Bug:26143355
Change-Id: Ifdc4bfff56fc6244c571dfbeff4179e1515d53b7
2016-01-11 14:58:18 -08:00
Ben Kwa
ddc3d21ef9 Add checkmark icons for selection.
- Add a new checkmark icon.
- Modify the grid and list items to include the check icon in the
  appropriate location.
- Add code to various DocumentHolder subclasses to cross-fade between
  icons when things are selected/deselected.
- Create new dimensions quantities to represent new icon sizes.
- Clean up xml files.

BUG=24326546

Change-Id: Ib3f04c8274d35ac3b95ed13730df340e8b7c36c6
2016-01-07 19:05:32 -08:00
Steve McKay
a8f03a2d81 Eliminate dialog mode from DocumentsUI.
DocumentsActivity to Use standard drawer layout at all display resolutions.

Bug: 26208032
Change-Id: I3b93c81bf97045744074a299e92cdea4aae7628d
2015-12-17 09:44:57 -08:00
Steve McKay
5a24749237 Merge "Fix broken copy after recent copy related chagnes." 2015-12-04 22:29:43 +00:00
Steve McKay
8fd086a18d Fix broken copy after recent copy related chagnes.
Also, add a label to Downloads app, and enabled drag and drop by default.
Cleanued up menu handling in BaseActivity (use switch statement).

Bug: 26033335
Change-Id: I3cef89a4a9f9e30b4e926411e94cf06bc2dc0f8d
2015-12-04 14:24:48 -08:00
Jeff Sharkey
28b41a3bd6 Grr, fix build from a skipped merge.
Change-Id: Id5961399c6057b8d721ad2a858aa91d107b0ab94
2015-12-03 20:06:46 -07:00
Ben Kwa
d27906e581 Tweak grid item layout. Adjust colors to match spec.
BUG=10960718
BUG=24326989

Change-Id: I74da23fe0b40d713a3f435d1467d26d707e76fca
2015-11-19 10:50:35 -08:00
Ben Kwa
9094585eb4 Adjust grid item layouts to match mocks.
BUG=24326989

Change-Id: I8a4133890036a2ef9173f20828f062a7e991525d
2015-11-10 20:32:17 -08:00
Ben Kwa
c11f46f416 Merge "Update DocumentUI styles to match mocks." 2015-10-30 15:13:15 +00:00
Ben Kwa
a7e9eb04e2 Update DocumentUI styles to match mocks.
BUG=24870921

Change-Id: Ic91c9fbbe8c577c2276a4afc79753ba702c53733
2015-10-29 15:43:23 -07:00
Steve McKay
1eafb666c2 Address followup comments from 793838.
Change-Id: Ie77112ea38796f970a8f688c1c94aeb05f46ab78
2015-10-26 13:27:59 -07:00
Steve McKay
3b2ad11fca Enable explicit package for quick view intent.
Define the package in config...suitable for setup via overlay.
Undefined by default makes the feature disabled on phones...n stuff.
Fall back to single-file QUICK_VIEW.
Work around 24963914 (for now).

Bug: 24963914
Change-Id: Ia9c5a606d294ae053fd5e60d015f0aa0010eba4f
2015-10-16 16:33:38 -07:00
Steve McKay
5bbae10c4c Normalize and improve menu fiddling.
Also, don't show copy/paste menu items (though they can still be invoked via keyboard).
Show copy to /move to instead.

Change-Id: I6e7bdf35bf370ea30d4f12a5a200ad38ff0221f4
2015-10-02 09:48:27 -07:00
Ben Kwa
68da5bf488 Merge "Disable productivity mode by default." 2015-09-30 17:03:30 +00:00
Ben Kwa
7a52b6b70b Disable productivity mode by default.
Productivity mode is a flag that was designed to be enabled only in
andromeda builds.  It should not be enabled in the base-level package.

BUG=24474568

Change-Id: I048bae9d3cf8270503cf245ed1e6959dab68571c
2015-09-28 15:54:27 -07:00
Steve McKay
9f9d5b432d Add support for opening multiple windows.
Installs an intermediate activity that manages tasks.

Bug: 20562850
Change-Id: If2d0a125b0630c27af07666b0f6a712f58243e9f
2015-09-25 14:46:14 -07:00
Ben Kwa
91bec536ac DocumentsUI: Add an error screen to DirectoryFragment.
- Reorganize the directory fragment.
- Repurpose the "empty" view to hold a message and a button.
- Message is set to the "No items" message if a directory is empty.
- Message is set to the error message if a query error occurs.
- Don't close DocumentsUI when a query error occurs.

Change-Id: I4e1e96f23040606b410ac746252dcb0ab9286f04
2015-09-24 15:06:14 -07:00
Ben Kwa
91caed80b1 Restore more missing DirectoryFragment functionality.
- Add a material-style horizontal progress bar to DocumentsUI.  This
  replaces the old loading footer.
- Restore the view-switching code that displayed a dedicated "empty"
  view when displaying an empty directory.
- Fix tests.

Change-Id: Ifecb867f6edecbdeb37b8607d87d9797879a589d
2015-09-22 13:24:51 -07:00
Ben Kwa
3b19e31e18 Replace error/info footers with a message bar.
- Remove footers from DirectoryFragment.
- Add a new MessageBar fragment that can display error/info messages.

BUG=22638983

Change-Id: I2075ae8e4dca8954a09c1fc57ed62bb6d3bff7a9
2015-09-18 13:53:41 -07:00
Ben Kwa
7cc80013f3 Adjust theming for Files mode.
- Bring files mode in line with MD spec platform colors.
- Normalize selection highlight color in grid and table mode.
- Fix status bar and accent colors in portrait mode.

BUG=23797347
BUG=24012021

Change-Id: I3427939b39f3f39f5e04bd4d854166dd6b3881b1
2015-09-15 10:55:22 -07:00
Ben Kwa
0f7078f004 Refactor DocsUI to break out a new ManageRootActivity.
- Split all ACTION_MANAGE-related functionality off from
  DocumentsActivity, into a new activity.
- Create new full-screen layouts for said activity.
- Fix some styling issues in {Documents,Files}Activity.

Change-Id: I0384715ad3c7d70a3a3daf510f1a09e8c5732348
2015-09-11 13:58:41 -07:00
Ben Kwa
545407f6c0 Merge "Factor and consolidate style and color names." 2015-09-04 22:01:45 +00:00
Ben Kwa
92b547b813 Factor and consolidate style and color names.
Change-Id: I02d344a4e5528d58e57255a31fbf127402e8ea31
2015-09-04 11:06:49 -07:00
Ben Kwa
304895a8bf Implement undo deletion.
Add a snackbar that pops up upon deleting files, giving the user a chance to
undo the operation.  If the user takes no action, the files are deleted.

This feature basically hides the files temporarily and pops up the said
snackbar, and if the user doesn' hit "undo", the files will be actually
deleted when the snackbar times out.

BUG=23518578

Change-Id: I181395aff967e62ca9287ed6fea2c7c8b8c09a71
2015-09-02 14:07:32 -07:00
Ben Kwa
a747d2e223 Switch DocumentsUI over to use AppCompat themes.
Switches from Material to AppCompat themes in order to start using
Snackbar.

Also, factor the common bits out of DocumentsNonDialogTheme and
FilesTheme, and make the theme names clearer.

BUG=23518578

Change-Id: I94a00e910469c57315823ae9df33024f2c7360ee
2015-08-31 11:43:46 -07:00