Commit Graph

102 Commits

Author SHA1 Message Date
Sunny Goyal
e27815e33f Fixing wrong method name
Change-Id: Idabe5d8ee41f31d30dcbe03aa626f7b39f713c14
2016-04-04 17:51:04 -07:00
Sunny Goyal
13178ac822 Adding an upper bound to all-apps width on larger devices
Change-Id: I16a0d8fb7c5023045d0a6b9e8089e0ab6a476d6d
2016-04-04 16:35:47 -07:00
Sunny Goyal
f37a21412a Defining separate layouts for horizontal and vertical drop target bars
instead of chaning the layouts in DeviceProfile

Bug: 27721989
Change-Id: I9a22c21e643f4fd0058c9be5e9d705aaf7649204
2016-03-24 17:29:23 -07:00
Adam Cohen
efca0279eb Switch all folder preview rendering to be programmatic (ie. no assets)
-> Refactored the preview background rendering to be much more self-contained.
   This cleans up a lot of code in the CellLayout, and keeps the logic in the
   right place.
-> We switch to software rendering for performance and compatibility reasons.
-> Removed all assets.
-> FolderIcon accept animation includes animation of the clipped region.
-> 1:1 hand-off of drawing of the FolderIcon background between the FolderIcon
   and the CellLayout. Unfortunately, CellLayout rendering is still required
   to work around clipping issues (due to use of software layer). We also
   need this to support folder creation feedback.

Change-Id: Ib8f7fa6359dfedff8145f38dd50ba03849ca0d51
2016-03-03 09:24:45 -08:00
Sunny Goyal
775d4c9ac0 Merge "Setting content bounds in onMeasure as it uses measuredWidth, which might not be available during onCreate" into ub-launcher3-burnaby-polish
am: 5df98da8fd

* commit '5df98da8fd2c1997bd6c09a4772f018730345090':
  Setting content bounds in onMeasure as it uses measuredWidth, which might not be available during onCreate
2016-02-17 02:03:05 +00:00
Sunny Goyal
94f46d9e5f Setting content bounds in onMeasure as it uses measuredWidth, which might
not be available during onCreate

Also fixing the calculation of allApps column could, which was counting an
additional icon gap

Bug: 27173894
Change-Id: I8be8cccc76d7e7d945cf9383567a3026228b6c86
2016-02-16 15:24:14 -08:00
Adam Cohen
f9c184a619 Refactor FolderIcon to separate the preview effect into it's own class
-> Created com.android.launcher3.folder package to house most folder-related files
   (aside from the FolderInfo) which is more related to the model than the UI.

Change-Id: I767063e1e4c775c01a799a3bede30cd94ac48ade
2016-02-12 17:28:31 -08:00
Tony Wickham
e0c3323656 Tweak spring-loaded workspace.
- No page indicators in spring-loaded mode
- Don’t move workspace up as high
- Scale workspace at 90% instead of 80% on phones
- Increase speed of workspace -> spring-loaded -> workspace
- Widgets were being scaled down twice when dragging from widget picker
- Don't scale up icons when dragging (scaling other stuff down is enough)
- Make scrim less dark and panels more transparent
- Thin white border around page instead of highlight when hovering

Change-Id: I963e91c20d4c0340480d165e0f3b8064783c0cb2
2016-02-08 11:37:19 -08:00
Tony Wickham
c32c63c46e resolve merge conflicts of b9759d399b to ub-launcher3-calgary.
Change-Id: I66230c15e5eaeef316d4e2f14b85c6ff1b6e977d
2016-02-01 14:51:35 -08:00
Tony Wickham
8a75806c1a Add extra space for the search bar.
Also fixed a broken test.

Change-Id: I1c270e69617528ea30f0e26a2101673e9b9fa63c
2016-02-01 14:15:37 -08:00
Sunny Goyal
38e7f28d3f resolve merge conflicts of a50a419b82 to ub-launcher3-master.
Change-Id: Ie0e233e22284b8ddd2dbb86204e042651b6dfae2
2015-12-11 14:18:16 -08:00
Sunny Goyal
a50a419b82 Restarting launcher when on font scale change
Chaning the font scale affects the static device profile and may
affect various background threads and static constants. Killing
the process ensures that these states get invalidated properly.

Bug: 26131935
Change-Id: Idc262ee5d158019e7a2505f8fb9a6413c06bfdeb
2015-12-11 10:55:20 -08:00
Sunny Goyal
258797318a Merge "Fixing All apps not respecting scaled icon size" into ub-launcher3-burnaby-polish
am: 49750ce75e

* commit '49750ce75e7413ad3c4fe4be31a2e1d73312794b':
  Fixing All apps not respecting scaled icon size
2015-12-10 17:52:01 -08:00
Sunny Goyal
383e0a29ec Fixing All apps not respecting scaled icon size
Change-Id: I3d05c713939fd69d04f5896cdc5db91480b0d4d1
2015-12-10 13:02:01 -08:00
Tony Wickham
ec73dd97f0 Revert "Revert "Reverting folder cell width on portrait phones.""
am: 6159c242bc

* commit '6159c242bc610f13e4c7550ae8b15f25603f4b23':
  Revert "Revert "Reverting folder cell width on portrait phones.""
2015-11-13 18:10:57 +00:00
Tony Wickham
6159c242bc Revert "Revert "Reverting folder cell width on portrait phones.""
This reverts commit 1974e98f5e.

Change-Id: I7c5d86de187989c085f676933ce3f1cbd57ed8a7
2015-11-13 18:07:18 +00:00
Tony Wickham
0309fbc65f Revert "Reverting folder cell width on portrait phones."
am: 1974e98f5e

* commit '1974e98f5ec4713e50ba64ec32a7607c92ddce9b':
  Revert "Reverting folder cell width on portrait phones."
2015-11-12 23:52:34 +00:00
Tony Wickham
1974e98f5e Revert "Reverting folder cell width on portrait phones."
This reverts commit b25e684a76.

Change-Id: Ie86adc4b35c73ab7ef78d73225b437adc4751172
2015-11-12 23:46:33 +00:00
Tony Wickham
79b4194765 Reverting folder cell width on portrait phones.
am: b25e684a76

* commit 'b25e684a766362422f5693f7a2189910c1275584':
  Reverting folder cell width on portrait phones.
2015-11-12 23:41:06 +00:00
Tony Wickham
b25e684a76 Reverting folder cell width on portrait phones.
The extra folder cell space added in ag/790800 looks bad on phones in
portrait mode, so reverting it here. However, we keep the extra space
on tablets or phones in landscape mode, since it provides more room
for long app names (bug 22462641).

Bug: 25662215
Change-Id: I2a37b884458ee557c9b8cff0c3edef16bfc50efb
2015-11-12 15:34:59 -08:00
Tony Wickham
5ea422e39e Added Gravity.CENTER_HORIZONTAL to drop target layout params.
I'm not sure if it is strictly necessary, but it is probably good to
be more explicit regardless.

Change-Id: Ib7647dbcb5449e22ef87da8d49b4e7804ba5c17f
2015-10-30 11:22:44 -07:00
Tony Wickham
c1ff24c077 resolve merge conflicts of a3c74d10a7 to ub-launcher3-master.
Change-Id: Ibeb2499ac278e4094a2922501cfffad2489e58ed
2015-10-30 10:37:43 -07:00
Tony Wickham
a3c74d10a7 Setting correct height for search bar widget options bundle.
- Seperate search bar height from its top and bottom paddings
- Report this height plus 8dps top and bottom for the widget options
- Use a separate bottom padding to adjust spacing between QSB and
  the workspace
- Add tests to verify the height of the search bar in both normal and
  tall modes (ran on Nexus 6, 7, and 10)
Change-Id: Ia7557785d1b38194eee869d0460456e8f33447d5
2015-10-29 12:18:28 -07:00
Tony Wickham
c1763b24fc resolve merge conflicts of 52040c2d51 to ub-launcher3-master.
Change-Id: Ie3cf72ef11b43e2c681d6d614c668062c7e7b74c
2015-10-23 12:29:44 -07:00
Tony Wickham
eef443248a Set search bar height before setting up views in Launcher.
This ensures that the QSB widget options are set correctly the first
time they are used.

Bug: 24704753
Change-Id: I2bb13ff012b6f13ca076deed61f0b08a7037e2fa
2015-10-21 12:20:31 -07:00
Tony Wickham
be424b2c32 am a295048a: Increase folder cell width slightly.
* commit 'a295048a69d35b5adc3f021c3d40c32700cc9629':
  Increase folder cell width slightly.
2015-10-12 23:25:24 +00:00
Tony Wickham
a295048a69 Increase folder cell width slightly.
The increased breathing room makes it more likely that long app names
will fit in the folder cells without being cut off.

Bug: 22462641
Change-Id: I110ede040f9e8fdddbf0c4e7a395ac71435559f3
2015-10-12 15:57:23 -07:00
Tony Wickham
a72f49cfc4 resolved conflicts for fa3c369c to ub-launcher3-master
Change-Id: I6bfc3d3b731a414060d86d4f1dfc5480c279edc9
2015-10-09 10:05:56 -07:00
Tony Wickham
3786092361 Merge "Added launcher callback to specify search bar height." into ub-launcher3-burnaby 2015-10-09 01:37:39 +00:00
Tony Wickham
72c689a7a2 resolved conflicts for d70a4b7b to ub-launcher3-master
Change-Id: Ib04f80eeebf551fc026925830fc4739d1c620513
2015-10-08 18:32:22 -07:00
Tony Wickham
55616cd363 Added launcher callback to specify search bar height.
The search bar can now be be normal or tall. When it is set to tall,
the hotseat and page indicators move down so that the workspace isn't
compressed quite as much.

Change-Id: Id92a946eab3a93524999f92efd847a501a95f002
2015-10-08 16:58:05 -07:00
Tony Wickham
d6b4037b09 Grid adjustments, specifically for Ryu.
> Less than 14% of the screen is used for left/right workspace padding.
  (To be clear, this means 7% for the left and 7% for the right.)
> Hotseat icons are the same size as workspace icons.
> Far left and right hotseat edges line up with workspace edges.
> All Apps button is scaled down 8dp.

Bug: 24003478

Change-Id: Idb057ab0f6ba29e7fd93feac7573ca2e07c7e839
2015-10-08 09:23:10 -07:00
Tony Wickham
439bc06dc0 am d47807d7: am 3a3517fb: Add widget size options for QSB.
* commit 'd47807d7a97d4ab555b2f9be882591c08955d699':
  Add widget size options for QSB.
2015-10-07 20:45:49 +00:00
Tony Wickham
3a3517fb6c Add widget size options for QSB.
Bug: 24704753
Change-Id: I3e16c1f67a67b08b3843f7f38312447bdfa6a91e
2015-10-06 13:07:23 -07:00
Tony Wickham
ab946a19d4 Flinging to the left deletes when in vertical bar layout mode.
This mode has the remove icon on the left side, so flinging to the
left makes more sense. But flinging up still works in either case.

Change-Id: I7ab40776b67659026f03f81efd43fae3375b5ba0
2015-09-16 16:28:43 -07:00
Tony Wickham
34d2c915c4 Added AppInfoDropTargetBar to spring loaded workspace.
Change-Id: Ieedc68eba9a5934ab30d6d546d8a837274491064
2015-09-15 11:37:58 -07:00
Sunny Goyal
756cd26592 General code refactoring
> Removing utility method for isAttachedToWindow
  > Moving logic to calculate cell size from workspace to DeviceProfile
  > Replacing some constants with xml resource variables
  > Saving the item info using content values for better compatibility with other methods

Change-Id: Idd612633d97a6241cb31148df9466031374bd5a0
2015-08-20 12:56:58 -07:00
Winson
2a87fe8c41 resolved conflicts for merge of 0ad33066 to ub-launcher3-master
Change-Id: I5dbbaaf9fb03ed3003174154ea7d7dbae9048a70
2015-08-07 10:37:21 -07:00
Winson Chung
006ee269ba Refactoring search bar animations.
- This refactoring ensures that LauncherStateTransition does not
  do its own animation on the QSB, and that all animations to the
  SearchDropTargetBar go through its own animators.

Bug: 22515084

Change-Id: Ia7d13c44d861eac7517076b52a9651a90911ed0a
2015-08-05 12:04:06 -07:00
Winson Chung
687ae8483d am 946609f0: Merge "Fixing overview mode scale calculations." into ub-launcher3-burnaby
* commit '946609f0ea70e1361dbe979af0e054d4c18b929b':
  Fixing overview mode scale calculations.
2015-07-28 22:54:51 +00:00
Winson Chung
946609f0ea Merge "Fixing overview mode scale calculations." into ub-launcher3-burnaby 2015-07-28 22:38:14 +00:00
Winson Chung
4988ae8cda am af263737: Merge "Fixing regression in calculating workspace padding." into ub-launcher3-burnaby
* commit 'af2637376f5fb37d1dfa598a8c95a623367501ce':
  Fixing regression in calculating workspace padding.
2015-07-13 23:38:36 +00:00
Winson Chung
4f3bfadbf4 Fixing regression in calculating workspace padding.
Bug: 22340087
Change-Id: I28d599fbb8f136b8b5aa4aeffaa0fba5661ab73c
2015-07-13 11:15:06 -07:00
Winson Chung
4f7eb4077e Fixing overview mode scale calculations.
- Making the overview scale apply just like the spring loaded scale factor
- Tweaking overview scale to make it not so small

Change-Id: If93bac08609b0cfd9c9d9f8f6057498957378b56
2015-07-10 18:23:08 -07:00
Sunny Goyal
cf25b52763 Removing some unused PagedView attributes
Change-Id: I1c7312b46ec95286d8e49d3dee60b1bf4d98dc20
2015-07-09 10:06:31 -07:00
Winson Chung
ef7f874a88 Refactoring all apps search to support external search bar.
- Adding support for an external search bar that can be used
  to search a container view.  This adds a new interface
  AllAppsSearchController which manages the external search
  bar.  Each controller will have its own search implementation
  which means that we no longer need a common AppSearchManager
  interface.
- Removing elevation controller as we no longer have a builtin
  search bar in all apps
- Refactoring container view insets so that they behave
  the same in all containers.
- Refactoring apps view to ensure that we only update the number
  of columns with the available width
- Cleaning up LauncherCallbacks interface

Bug: 20127840
Bug: 21494973

Change-Id: I710b8e18196961d77d8a29f0c345531d480936fe
2015-06-15 14:22:47 -07:00
Winson Chung
2c6e5ccbcd Ensuring that we use the screen width more optimally in AllApps.
- Fixing issue with prediction bar height being calculated incorrectly
- Fixing issue where the prediction bar divider was not drawn exactly
  between the bar and the first row of apps
- Removing padding to allow scrollbars to reach full height

Bug: 20222023
Bug: 21335377
Change-Id: I2c0614a36e2294d0d6184a6bff4847876ffe971e
2015-06-05 09:49:12 -07:00
Winson Chung
f8c6f885f0 Fixing issue with hotseat being on the wrong side of the screen in RTL.
Bug: 21499466

Change-Id: I566cd89dfb855f89f4e68bf56e48bf99204b11ab
2015-06-03 11:42:15 -07:00
Winson Chung
5f4e0fdd2e Moving all apps code into sub package.
- Renaming resources, dimens, etc to be more consistent
- Removing old AppsCustomize resources and other unused code

Change-Id: I15ce35e7cb7a9b9344fc7103963e4e4c9e45d89a
2015-05-22 12:21:40 -07:00
Sunny Goyal
c6205603ef Creating landscape and portrait device profiles at app initialization
Change-Id: Ide9d007adc36b348e19b05cdf49e87f8b02db60e
2015-05-22 08:46:41 -07:00