Commit Graph

112 Commits

Author SHA1 Message Date
Adam Cohen 0fb7db5a37 Fixing boot stall.
Revert "-Added 3D effect to home screen scrolling"

This reverts commit 9415d87eda.

Change-Id: Ib8d6602f5d82884eb1f6cc44c0cc71cc563a3a59
2010-09-29 13:04:32 -07:00
Patrick Dubroy de7658b5e0 Show crosshairs when dragging items around the workspace. 2010-09-29 11:14:28 -07:00
Adam Cohen 9415d87eda -Added 3D effect to home screen scrolling
-Added background outline fade in / out
-Modified the feel of scrolling: now using quintic
 interpolator and modified the influence of
 scroll velocity

Change-Id: Ifddcab5223ac20be7d9f800ccf09442d9b4db781
2010-09-28 16:56:10 -07:00
Michael Jurka 7ded67cd64 fixed: adding app shortcuts caused overlapping
icons
2010-09-28 13:57:39 -07:00
Michael Jurka 6a1435d78d Fix issue where items could not be moved back
to their original positions

This also fixes crash 3038168

Change-Id: I4142a1fe32954e76e6ab02ea09f50d4bdefec67c
2010-09-27 18:35:18 -07:00
Michael Jurka 28750fba6a fixed minor code review issues from change I0280c3be
(it was submitted early accidentally)

Change-Id: I3753366b4d5e1dc228baf02eba27a2c0d8fa42cf
2010-09-24 18:34:23 -07:00
Michael Jurka 0280c3be4d Adding support for drag and drop of folders and shortcuts.
also:
- Long press on empty space on workspace now brings up customization tray
- Fixed: while dragging, items appeared to be dropping on folders two cells to the right
- Fixed: Disabling drops on folders when the workspace is shrunken
- Fixed: account for scaling of dragged items when checking if they overlap
          with shrunken workspace screens
- Making folder icons dimmable to match shortcuts and widgets
- When deciding with shrunken workspace screen we're dragging to, we now use the closest screen rather than the one that has been overlapped the most
- Refactored drag/add mechanism, removing array of occupied cells from CellInfo
- Removed dead code/variables
2010-09-24 15:28:20 -07:00
Michael Jurka f79d5265c6 removing dead code 2010-09-17 10:59:31 -07:00
Brad Fitzpatrick 98cf129f80 am 73013bf9: Make LauncherModel.deleteItemFromDatabase write to disk async.
Merge commit '73013bf94f49ffbacba2b8300f6a2dd4eeebbd13'

* commit '73013bf94f49ffbacba2b8300f6a2dd4eeebbd13':
  Make LauncherModel.deleteItemFromDatabase write to disk async.
2010-09-15 12:17:49 -07:00
Brad Fitzpatrick 73013bf94f Make LauncherModel.deleteItemFromDatabase write to disk async.
Fixes a bunch of StrictMode violations and removes TODOs.

Change-Id: I886bd071d4a8336c228d29c517a8ffc5223c0623
2010-09-14 12:33:35 -07:00
Adam Cohen e54cec82a9 Re-adding the perspective shift on mini screens
Change-Id: If4acc0cbfc66305e9abe024529a69553df2f9ef2
2010-09-13 18:19:55 -07:00
Michael Jurka 5f1c509d5a supporting swipable home screens on xlarge devices
- icons and widgets on home screens can be "dimmed"
- celllayout no longer renders a dimmed version of itself, but instead its children make dimmed versions of themselves
- celllayout no longer always takes up full size of workspace, in landscape mode 
neighboring screens (celllayouts) are visible
- on xlarge devices, in landscape mode side screens are "dimmed"
- moved holographic outline helper to its own file
- fixed bug where mini-screens were still able to scroll left/right

Change-Id: I9e85ab4147edfae1e7525c3d11d42be3fabf4f6d
2010-09-13 15:16:10 -07:00
Adam Cohen a985e598f6 Applying fake perspective transform to the home screen previews
Change-Id: I2092fd963804eceaf0117bcb6d118d83e0da3573
2010-09-09 11:58:09 -07:00
Patrick Dubroy 2b9ff37edb When an app is chosen in All Apps, tapping a workspace screen adds it to that screen. 2010-09-08 10:38:54 -07:00
Chet Haase b1254a6bdb Animation classes renamed
Change-Id: I96ecb77357a914a746a5989c909246620b977b10
2010-09-08 08:51:12 -07:00
Michael Jurka 0142d49e13 Changed Workspace to inherit from PagedView
- adds support for seeing dimmed side-pages on
home
- adds workspace support for pages that are
smaller than workspace itself
- removing a lot of code duplicated between
PagedView and Workspace
- tested new Workspace on Nexus One, and perf.
was indistinguishable from old Workspace in my
tests

Change-Id: Ie33ab4e8b35ac01b22894cff66650bb0ece8dfcc
2010-09-01 14:54:34 -07:00
Joe Onorato 6b4adbc055 DO NOT MERGE - Allow the workspace to swipe while it's loading.
You still can't modify the contents of the workspace while it's loading,
but this makes it appear a little bit more responsive.  Launching apps
while the launcher is loading has always been possible.

Bug: 2748595
Change-Id: Iaf203c7358647a9b2211bb7386579ae75b82a698
2010-09-01 12:15:10 -07:00
Joe Onorato fdf5fd63c6 DO NOT MERGE - Allow the workspace to swipe while it's loading.
You still can't modify the contents of the workspace while it's loading,
but this makes it appear a little bit more responsive.  Launching apps
while the launcher is loading has always been possible.

Bug: 2748595
Change-Id: Icf252beaee5b801b30216202ce6032c4d565cde3
2010-08-31 12:02:32 -07:00
Patrick Dubroy df7c3a7853 Fix problems with unanimated toolbar transitions.
Rather than creating all the Animators and attempting to execute the
transitions immediately, add a separate code path for all the
unanimated cases.

Change-Id: Id615180bd0d2ed5cc60d8df351c00e8d7b13c68d
2010-08-26 18:17:08 -07:00
Michael Jurka 7f0f4f3c35 Workspace no longer scrolls during drag when shrunk
Change-Id: If71ba7638259f4015c5c088797f2b2719066cf2e
2010-08-25 17:40:44 -07:00
Patrick Dubroy 6b509c1fd6 Add a market button and add toolbar button animations.
Also clean up a lot of the animation code to be more centralized.
2010-08-25 17:11:08 -07:00
Winson Chung 86f7753bbd Preventing reloading of pages on swipe and disabling offsets for xlarge static wallpapers.
Change-Id: I4ca72164775d09706e36c38e0fac0e84254221c7
2010-08-24 14:58:11 -07:00
Michael Jurka a63c452f5b added support for dragging widgets and app icons to mini screens
- gave mini screens a rounded rect background
- mini screens change color when dragged over
- added a way to specify the active region of dragged items, to allow for clipping of whitespace at borders
- fixed: feedback while dragging was often one cell off
- fixed: bug when adding to almost-full screen
- removed unused classes

Change-Id: I2fbd2aaaee6831b288cca8dec75e7b446068e8d1
2010-08-23 15:49:58 -07:00
Michael Jurka 01f0ed4126 pressing home twice shows small overview mode
Change-Id: If5a6c0942685cd52ef77562dd342f28e16ae571c
2010-08-23 15:26:14 -07:00
Michael Jurka 96226223d9 clicking on mini screens no longer sends click to widgets/icons
Change-Id: Iee905655151dfe1d00acd776752525d3fcc9b0e1
2010-08-20 00:54:40 -07:00
Michael Jurka c28de51eed fixed crash in addVacantCell
No longer precalculating vacant cells

The previous way of finding empty cells for 
widgets/icons etc. precalculated all the possible
empty spaces. Now that we have an 8x7 grid in
tablet, there are too many possible empty spaces.

Change-Id: Ib39113fdf755935bfad257843e1618c680ed9e72
2010-08-13 11:59:51 -07:00
Patrick Dubroy a67e867db9 Fix workspace shrinking bug caused by change in animations
Change-Id: Ia34ae2a6cb863da28d319c46a95f61536cd31ade
2010-08-10 18:13:41 -07:00
Michael Jurka 4cb3724a2c workspace bug fixes
- fixed: pressing home sometimes left workspaces
in shrunken state
- fixed: position of delete zone (trash icon)
- fixed: workspace unshrink sometimes looked weird
when coming from all apps
- fixed: clicking power button and returning left
workspace in shrunken state

Change-Id: Ie974202926e6880ccda26ac9fe967fb587a9b7a3
2010-08-10 14:10:20 -07:00
Patrick Dubroy 3ec8bdd576 Refactor zooming animation, and apply it to customize drawer too.
Change-Id: I0bbd5a68adc82cea02dc583ac3d04e3de8c0346e
2010-08-09 14:25:36 -07:00
Michael Jurka 4bb4f735c8 small fixes to Launcher
- more robust unshrink animation
- catching a resource not found exception when
  making widget preview
- added more missing copyright headers
- hiding customization drawer when long press on widget
- long-pressing on widget is temporarily always
  springloaded to zoom in to workspace screen

Change-Id: I6c92877357e907d89840fecc4662f0700b96255b
2010-08-06 11:19:47 -07:00
Patrick Dubroy 976ebec9e3 Fix incorrect offset in drag feedback, and other minor stuff.
- moved some dimens to -xlarge
- enlarge AllApps so that it's not clipped
2010-08-04 20:10:24 -07:00
Adam Cohen ec1b932159 Fixing longpress bug on widgets with a ListView
Change-Id: Idca7a8948ca21f1e7a1c332fd56303f903eb122d
2010-08-04 18:57:04 -07:00
Patrick Dubroy 7247f6315b Move all apps to the new animation framework, and some other all apps changes
Change-Id: Ib4c827966423d76e62db24036bbca0cd6ee46b95
2010-08-04 18:00:58 -07:00
Michael Jurka 8335a24a6b updated Launcher2 based on recent changes to view properties
- fixes bugs on both N1 and stingray where workspace
  was seemingly disappearing

Change-Id: Ica3c5aad7bbce58c35417a0022bfe0d1328c2322
2010-08-04 17:32:13 -07:00
Adam Cohen d22015cd37 Cleaning up grid size specification in Launcher
This commit eliminates the notion of in-place rotations and a bunch of
associated complexities (including the notion of canonical coordinates).
Further, the number of x and y cells per workspace screen is now being stored
in a single location in the XML definition of Workspace. This fixes a couple
bugs where incorrect values were being used. Finally, eliminated the notion of
"shortAxis" and "longAxis" in terms of padding and cell count. These have been
translated to corresponding x and y axis values.

Change-Id: I30cfed66f82d739355b3f01730b28b6c0437989c
2010-08-04 11:03:47 -07:00
Michael Jurka 2c3af5ffb2 refreshed apps/configure button, added search button
- configure button now has a pressed state (as
  do the other two)
- also added a cast to getX() from float->int
  because of changes in the view property code

Change-Id: I57dc6e44838f4f4354f8977a3b542e93384b3d7d
2010-08-03 14:10:37 -07:00
Michael Jurka 79212d8136 Fixing bugs related to starting in All Apps mode
- fixed bug where Workspace.shrinkToBottom() was 
    not always called in showAllApps
- added logic to defer call to 
    Workspace.shrinkToBottom() after first layout
    call (necessary because shrinkToBottom relies
    on getWidth() working properly)
- added ability to Workspace.shrinkToBottom()
    without animation

Change-Id: I966141a60b6b014cf97e83b4d45725b41b16e55d
2010-07-30 17:39:39 -07:00
Michael Jurka 54dd75463d Tapping on mini-screen in All Apps view now goes back to home screen
- had to disable touch event swallowing in workspace in X-Large mode to get this to work
- also changed default screen in XLarge mode to 2 (the middle one)
2010-07-30 14:47:52 -07:00
Michael Jurka b0f28bd9a5 fixed bugs with layout in Launcher
- fix bug where calling unshrink on initialization was setting all the screens' x coordinate to 0
- fix bug where mScrollX was not synched to the proper value for the mCurrentScreen it was on
2010-07-30 12:04:12 -07:00
Michael Jurka 213d96354e Improved support for workspace screen thumbnails
- Shrinking workspace view in All Apps
- Added vertical margin for workspace screen thumnbnails
- Fixed bugs in a few of the Launcher state transitions (e.g. customization to all apps)

Change-Id: I9ad1c8861585d78fdb2e3bc986a614526b3cfe5f
2010-07-28 15:11:27 -07:00
Michael Jurka dee0589388 Home screen now shrinks while customizing
- added a shrink/fade animation on home screen when going into customization mode
- made items in the customization drawer larger

Change-Id: Iddbaf14aa5b1504fe94966971a1ab95c00f24331
2010-07-27 15:53:04 -07:00
Patrick Dubroy 8f86ddcb90 Generate a default preview for widgets that don't have a previewImage.
Change-Id: I3a3c24543c925a50ab34fd3cbf7947544a5ac5c0
2010-07-16 14:46:07 -07:00
Patrick Dubroy 440c360bc3 Fix bug with drag visualization and UserFolders.
When dragging an app shortcut, it was possible that we'd show a red rectangle
around a cell occupied by a UserFolder. This shouldn't be possible -- as soon
as that cell becomes the target drop cell, the folder should start handling
the drag and drop events.

Change-Id: I1b7a8b1aa9aeb7e2f1bd51ce8d947c06455e988f
2010-07-13 17:54:03 -07:00
Patrick Dubroy 6569f2c80e When dragging items on the home screen, visualize where they will drop.
Draw a rectangle around the area where an item will land if it is dropped.
If the area is vacant, the rectangle is green; otherwise, it is red.

Change-Id: I859b52514566fa55f8c7a04493b8088d12baa476
2010-07-12 17:29:35 -07:00
Michael Jurka 0e26059548 Improving home screen customization
- Created a drawer with tabs for widgets, folders, shortcuts, wallpapers
(wallpapers are currently not implemented)
- Tapping outside the drawer dismisses it
- Moved the all apps icon to the upper right of the screen
- Adding a toast that says "No more space on screen" when dragging a widget to a full screen
- Fixed bug where you could stack two equal-sized widgets on top of each other on the homescreen (exposed by the new ability to drag widgets onto the home screen)

Change-Id: I03b65ce54a85d24328c94e0c06e249571de449ee
2010-07-09 11:56:45 -07:00
Winson Chung aafa03cbb9 Allow for NxM layout and in-place rotation of items on homescreen.
Currently, rotation is disabled as designs are still in flux, but the NxM grid is enabled (8x4).

Change-Id: I0026f88c674719e3d67de6d6d481d2d4cd606362
2010-06-30 16:24:40 -07:00
Michael Jurka af44209bfa First cut at new home screen customization for xlarge displays.
- Add new layout for xlarge, removing hotseat, next/prev page, etc.
- Add a "+" button in top right which switches to customization mode
- Add a widget chooser which slides up from bottom of screen
- Initial support for dragging widgets onto home screen

Change-Id: I14e2e013ccceff4066fcb7c4492b4f6bef6595e7
2010-06-28 10:49:34 -07:00
Daniel Sandler 291ad12232 Ignore requests to add items to non-existant screens.
Should avoid crashes when using Launcher2 alongside
third-party launchers that add additional workspaces.

Bug: 2709532
Change-Id: I7775b43e582346ba686524e357a2b262e9fc4dcd
2010-05-25 10:35:44 -04:00
Daniel Sandler e1cc6c3745 Fix 2617318 - NPE in Launcher2.
Applies the fix in change Id91712fa to widgets.

Bug: 2617318
Change-Id: I1e1dac6238a26497eacc23b161df171ae40bb588
2010-05-07 11:49:29 -04:00
Adam Powell fe8e279dbc Bug 2639807 - Add smarter smoothing to home screen touch scrolling.
Change-Id: I242e11f5aec218ae2b8f80ef3babcb2836c173db
2010-05-04 14:20:28 -07:00