History log of /packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
851222a96b5d68602fb361ea3527101e893f67e3 21-Jun-2012 Maurice Chu <mochu@google.com> Added thin object layer around contact data

This refactoring abstracts out the need to directly
refer to Contacts database columns throughout the code. Instead,
all of this information is retained in getter/setter methods
within the Contact, RawContact, and DataItem classes and
sub-classes.

ContactLoader.Result class has been pulled to the top level as
the Contact class.

The Entity class has been removed and replaced with a RawContact
class, with getters/setters to raw contact information.
Renamed EntityDelta to RawContactDelta for better understandability
as well as adding getters/setters for specific fields in the
ValuesDelta nested class within EntityDelta. EntityDeltaList
and EntityModifier have been renamed to RawContactDeltaList and
RawContactModifier with the methods using the RawContact class
directly rather than the Entity class.

Data items for a raw contact are represented by a DataItem object
with specialized getters/setters for subclasses of DataItem.
(e.g., EmailDataItem, PhoneDataItem. etc.). DataItem is a wrapper
around ContentValues. This abstracts away the ContactsContract
column fields into getters/setters.

The above refactoring is accompanied with changes throughout the
codebase to use the new Contact, RawContact, and DataItem classes.

Change-Id: I31c1dccd724e9652f9d0af78ca81feb6c5acd71d
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
e0b2f1e2d01d1ac52ba207dc7ce76971d853298e 12-Jun-2012 Chiao Cheng <chiaocheng@google.com> Global import order fix.

Changed import order to be in accordance with style guide:
http://source.android.com/source/code-style.html#order-import-statements

Static imports will be placed at the top since most existing files used that
convention. It is also a style that can be handled by both eclipse and intellij.

Change-Id: Ia7013c7a2d88e5fefb8f4975d121f7fcd3fcc462
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
2f77c85543e6c497e63cd0e216b70e58c1d13ec3 31-Mar-2012 Daniel Lehmann <lehmannd@google.com> Various refactorings to prepare proper big picture loading

- Added a function to load a picture with ideal sampleSize
- Renamed xmls/java files for tiles
- ContactTileView is now abstract and has subclasses for each use-case
- Added mechanism to estimate the image-size in a tile before layout
- Changed the cross-fade in ContactPhotoManager to apply the fade to the
current picture instead of the default avatar. Reduces flickering

Bug:6202229

Change-Id: Ic8636d1b3349473163fb2424b5f74476fd435fb5
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
f30723782e801deaf159aea2443e9507596ef11d 23-Feb-2012 Daniel Lehmann <lehmannd@google.com> Don't re-use the SaveMode in the group editor anymore.

As we only ever use SaveMode.CLOSE, I decided to remove this entirely.
We don't support re-loading at the moment, so it seems wrong to have
code in there that pretends to be able to do it.

Also I cleaned up some Eclipse warnings, so that the side-bar has fewer
yellow lines

Change-Id: I263b716c2edc98682bd5f5d1bc2b18ede15d7ced
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
7cdbe5c0b11acb6128974f593b4ede86b01f95b2 22-Nov-2011 Katherine Kuan <katherinekuan@google.com> Remove titles in simple confirmation dialogs

Bug: 5476234
Change-Id: I7970c3378860e3521b55d248968a4710d8161c04
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
a939372643a86688ae196cce03cf4f6f70864d93 31-Oct-2011 Daisuke Miyakawa <dmiyakawa@google.com> Reduce the number of columns for group queries

1~5% performance improvement. Also will improve memory usage.

Bug: 5550672
Change-Id: I5ad0876ce469fbf86334e3f77b15cd240d9f761b
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
77c20e8355e5bcd3f1106b87abc2b6d582f9b0bf 28-Sep-2011 Makoto Onuki <omakoto@google.com> SelectAccountDialogFragment: Handle orientation changes

- Put all parameters to the argument Bundle, so they won't be lost
on orientation changes.

- Removed the subdialog in ImportExportDialogFragment, which used
the argument Bundle for a different purpose. Now we put the
information needed to ImportExportDialogFragment as a sub Bundle
in the argument Bundle.

Tested all 3 uses:
- "Add new group"
- "Copy to my contacts" (Couldn't configure my device to show this dialog,
so I had to apply a local patch to test this part.)
- "Import from SD" "Import from SIM".
Also made sure other features on "Export/Import" still work, except for
pre-existing bug 5387545.

Bug 5382646
Bug 5369853

Change-Id: If7f75ee8192889dbe484874c52e1a355d6b35c6c
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
6f74c0f3313cbb08ee8a8fbb79bfefc5b03fe215 27-Sep-2011 Makoto Onuki <omakoto@google.com> Fix account list for group editing (for master)

- Don't use contact writable account list to populate the
account picker when creating new groups, instead check for
isGroupMembershipEditable() on the account type

- Repeat the same for determining whether the "new group"
button should appear in the PeopleActivity or not

Bug: 5360120
Change-Id: Ifd2fd1cf4ea7bf02d4dcba3e9c023bd7041fab83
Original-Id: Ia1ec62eff3fe4fd5b495548218c58f238ff49788
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
ecfc26c3f9495f1a4efed69a1582ff2b0deb2c71 13-Sep-2011 Daniel Lehmann <lehmannd@google.com> New avatars

Bug:5074147

Change-Id: I583d22c63a7b617567c523efeed292ae1e2be7e4
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
d3c35957bbe9a10000909087cbdcc06b6fbe0354 08-Sep-2011 Makoto Onuki <omakoto@google.com> Make group editor usable in landscape

In both landscape/portrait
- Disable the IME extraction mode.
(We probably don't have to do it for portrait, but just for consistency.)

In landscape
- Remove the accout header.
- Horizontally align the group name field and the member name field,
much like the tablet layout.

- Also un-bold group name, per UX request

Bug 5265688

Change-Id: Ic6a39d61f91d21bbf820ee90e807b677ac5d3535
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
04e6b557e45cc645c4fca1578358b63945452975 03-Sep-2011 Katherine Kuan <katherinekuan@google.com> Show edit group option for default auto-added Focus groups

- Focus groups like "Friends", "Family", and "Coworkers" are read-only
because their titles are read-only and they cannot be deleted, but
their membership can still be editable, so show the "edit group"
option.

- Fix bug with editable Google+ circles were editable by adding a
missing dataset field

Bug: 5250453

Change-Id: I3c5590a01bf641fb22e97fdba4a4eb3c41725e6c
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
b848271a560eaeddb2f4007fcbd3f77506a40ac1 19-Aug-2011 Isaac Katzenelson <isaack@android.com> Fix overlapping group editors

Bug: 5173297 Group editor tends to duplicate
itself and overlap the views on top of each other

Add code to remove old editor when a new one is created.
Added code to prevent multiple contacts in list of contacts to display.

Change-Id: I1bd6da440545047d18667bd01f74f84c1677601a
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
94f216b210f29abe7fdb96a18a1718e91b628f54 18-Aug-2011 Makoto Onuki <omakoto@google.com> Group editor: Just close activity when there's no accounts

Rather than crashing.

Bug 5035734

Change-Id: I433049de1a254213beb83501fdae74907f11a4cf
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
7254f976a0a87a4eea3367a931fa1a93dce4e098 12-Aug-2011 Makoto Onuki <omakoto@google.com> Fix ClassCastException from Parcelable[] to Member[]

I didn't know you could put ArrayLists to a bundle...

Bug 5158102

Change-Id: Ib2ae84010526789cee8ae34b6817a7c18257d99d
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
ba482b6c88a4f6be66233a78749dcfccf87889ac 12-Aug-2011 Makoto Onuki <omakoto@google.com> Merge "Fix group editor crash (IndexOutOfBoundsException)"
1ba8b6fea4c3f82ded19305874e72a326612aed1 12-Aug-2011 Katherine Kuan <katherinekuan@google.com> Finish string changes

Bug: 5147284
Bug: 5144069
Bug: 5150725
Bug: 5149819
Bug: 5144900

Change-Id: Ib3495e1ef7847eb2c01d7609c1524024123c993c
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
59b46720e92799a29d84e6e31fb3eeea60166f0d 12-Aug-2011 Makoto Onuki <omakoto@google.com> Fix group editor crash (IndexOutOfBoundsException)

It's probably that the suggestion list has changed just before the callback
is called.
Use the view tag to get SuggestedMember to avoid look-up by index.

Bug 5149812

Change-Id: I04254eaf94728c42164ddc73dbd2dbf140ec8525
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
0133589fec89150313918576ab5e4f569cb7de5d 10-Aug-2011 Makoto Onuki <omakoto@google.com> Merge "Makke DONE button close activity on readonly group editor"
ad8e14065996cf8c0f5e0d6bc90c7fa334fc227f 10-Aug-2011 Makoto Onuki <omakoto@google.com> Makke DONE button close activity on readonly group editor

Bug 5142181

Change-Id: I5b300b150113b77800de698dbb7bdd40c35b15f4
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
bec0e12648b7c90aab9eda5b2837faca2493e5c3 10-Aug-2011 Makoto Onuki <omakoto@google.com> Remove unused callback

Bug 5143491

Change-Id: I20b82551329f1beb05dc4039cf0d501fe9a9e676
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
f81b6d9ba129f0220de93aa9a7426547889755c3 09-Aug-2011 Makoto Onuki <omakoto@google.com> Group editor: Handle rotation correctly

- Properly save/restore fragment state
- Don't close cursors loaded by cursor loader.
They are retained through orientation changes. Closing them manually
causes accessing closed cursors after screen rotation.

Bug 5075387
Bug 5136936

Change-Id: I7722d90e5a5b52af1666a69bc56d1df27c4de2a0
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
1c07d4bf219bcdcc433b69a40ed3398ba7b3389f 28-Jul-2011 Katherine Kuan <katherinekuan@google.com> Fix NPE in GroupEditorFragment name checks

- We need a valid group name when we save the editor, so
we read the group name text view before saving. However
this is throwing a NPE because now the group name text view
is not retrieved until we've selected an account (new group
creation) or loaded the account (existing groups) and
determined which layout we're inflating.

- So there's a period of time where it's possible the
group name text view variable is null, so verify
it's not null before checking if the name string is valid.
If the text view is null, then we'll abort the save group
procedure early.

Bug: 5090543
Bug: 5091206

Change-Id: I1d768ad3b0c1f11a56de5c7f9c476b5176e5c3ed
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
f75900ed2bafa5411c46e8fde0b8dccbc6753176 28-Jul-2011 Makoto Onuki <omakoto@google.com> Fix group member suggestion

We were not setting mDataSet properly, and doing "data_set = ''" when
it should be data_set IS NULL.

Bug 5091319

Change-Id: I4ec8fcb5e21772dcdbbf1359fe3dcc7cab6a9f36
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
2b3f3c54d3beb017b2f59f19e9ce0ecc3e039dbc 27-Jul-2011 Dave Santoro <dsantoro@google.com> App changes for account types with data sets.

This is primarily a replacement of the Android Account object in most
parts of the app with a new AccountWithDataSet object that extends
Account (by adding an additional attribute, the data set).

This also includes a major refactoring of the AccountTypeManager,
both to allow it to handle data sets and to allow for
non-sync-adapter packages to be referenced by the sync adapters for
an account and registered as sources of contact data. Attributes of
the sync adapter that would typically come from the authenticator
can be parsed out of the Contacts XML for these packages.

Bug 5077096

Change-Id: I88f311c64eae78c88e9999bff6f7de8538e62157
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
1390f85d3776dd9ad9d38f611f3a0d4ed59f6249 27-Jul-2011 Katherine Kuan <katherinekuan@google.com> Modify action bar for group editor and group card

- Remove home icon in group card
- Change done/cancel buttons in editor
- Remove old honeycomb style on editor activities
and have it use the new split style solid action bar one

Bug: 5081353
Change-Id: Ie39f7f1ea5bd80d5246158442325207effd6aff7
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
1eb2b361508bb1a43755f07ce8ab543e8df5273b 26-Jul-2011 Katherine Kuan <katherinekuan@google.com> Merge "Non-editable group page"
a615b7ac82f3512a1689bab3542bbe403ed90923 26-Jul-2011 Katherine Kuan <katherinekuan@google.com> Go to group card after group editing

- Unfortunately, since we don't have support for group URIs
(to view a group, edit a group, or view the group list), we need
to determine whether we should set an activity result or
launch the GroupDetailActivity to view the group after editing
is finished.

Bug: 5042435
Change-Id: I71357dfc44f8539273e12169aeea78d80d258a06
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
ffb45de77c1c51214b5baa0eb6f59a7801cfcbaf 26-Jul-2011 Katherine Kuan <katherinekuan@google.com> Non-editable group page

- If the group membership cannot be edited, then show
a warning message, gray out the group name, and
remove the "delete member" buttons.

Bug: 5070780

Change-Id: I9213c7eff2237d153c60bb8842515fe404053701
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
717e343811088da922cd84fb0d196de85fba7fe9 14-Jul-2011 Katherine Kuan <katherinekuan@google.com> Add members when creating new group

- Enable adding new members at group creation time
- Modify the existing createNewGroup methods in
ContactSaveService to take an array of raw contact IDs
- Note: adding the contact to the group must be
done with applyBatch instead of a single insert
to the data table because otherwise the raw contact
version will not increase

Change-Id: I474758110840b8cad144e6c1b90d09558a7e9478
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
2d851cc895ffc7afd322298c7d4391ca5bea1a2d 06-Jul-2011 Katherine Kuan <katherinekuan@google.com> Batch add and remove group members in group editor

- Create save intent in ContactSaveService to update
the group name, add a list of new members, and remove
a list of existing members

- Add raw contact ID column to GroupMemberLoader so that
the raw contact IDs can be used in ContactSaveService

- Remove old code that would do the database save one at a
time for each contact member when the action was taken
(and remove the step that would load the full contact because
we now only need the raw contact ID)

- TODO: General cleanup to just use raw contact IDs everywhere
and have one Member class (get rid of SuggestedMember)

- TODO: Allow users to add contacts for new groups (still
can only change the name), but this should be straightforward
after this change

Bug: 4961845
Change-Id: I8a2f1086feecbb63dc6eb3d1e985bccabe28b803
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
075bb70341fa5544db6654020c58a1e0ae609c22 12-Jul-2011 Isaac Katzenelson <isaack@android.com> Fix crash in onLoadFinished in GroupEditorFragment

Change-Id: I7e06d2c994607178518d3d3a8cecec5a3571beda
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
971116e466757434f4979a61d4f58ea0deac1ea4 05-Jul-2011 Katherine Kuan <katherinekuan@google.com> New group disambiguation dialog

- Since switching accounts in the group editor is difficult
(i.e. we need to wipe all added group members when accounts
are switched), it's easier to just have an account disambig
dialog when you first create the group
- The disambig happens as a popupwindow anchored to the
action bar "New group" button if it's a wide screen
- Otherwise the disambig is a dialog that comes from
the GroupEditorFragment

Change-Id: Ibd75607b326e600c412f4bd04eb4cc72534aed72
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java
c6b8afe730255537978f2c938cca6986cae63c34 23-Jun-2011 Katherine Kuan <katherinekuan@google.com> Group editor on tablet

- Allow autocomplete to add new members which presents
the user with suggestions from the raw_contacts table
with the same account name and type as the group
- Hook up the "new" and "edit" group buttons on the tablet
- Once the user exits the editor, update the group list
and scroll the group list to the group that was just edited
- Allow rename of groups (make the names of read-only groups
not editable)
- Allow removal of members
- Hook up the done / cancel / up / back buttons

- TODO: Be able to create a new group + add new members
in the same transaction. Then the new group editor
will allow adding members at the same time. Currently
you can only add a name to a new group. Once it's created,
then you can go and edit the membership.

- TODO: Bulk add/remove members in one transaction when the
user exits the editor. Currently it's saving the change
after you modify the membership list (even before you hit
the "Done" button in the editor).

- TODO: Add member status message and chat presence

- TODO: Add UI for non-editable groups

Change-Id: I1f32a28862c358b8bd1469666743cd240d28f80b
/packages/apps/Contacts/src/com/android/contacts/group/GroupEditorFragment.java