There's no need to create a URI just to rip in appart again. Additionally, to
support additional changes (i.e. to use Mailbox instead of Folder in the
MessageController), we need to store the actual Account.
NOTE -- This change only affects IMAP and POP3. SMTP will come in a follow-on CL
Change-Id: I400036a17271c99272fd9c603547dcd713b50b9d
This now uses an XML layout that gets inflated and computed after a
layout pass. The drawing simply uses the coordinates stored after the
layout.
This makes it a lot easier to maintain the different views and allows us
to simply provide different XML files for different modes/views, isntead
of trying to hand tweak Java layout code.
Some TODOs - clean up the "paints" and optimize the layout/drawing
computation
Change-Id: I784919f726bd4d80aba8744a8f047fcfe79ad93a
The phone code has gone stale and ignored auto advance policies - this
fixes it, though that code is likely to get merged anyways.
Makes it so that auto-advancing to the end of the list pops back out to
the message list
Bug: 4302999
Change-Id: I609747c0a19672b8aa56d2c0ab57533823899e47
We can now drill down into nested folders during drag-n-drop. Simply hover over
a collapsed folder for 750ms and it will auto-expand.
Change-Id: Ia9b42dd87e19c2ebdf8675c761cb1453bb26d158
ListStateSaver did nothing more than hold a Parcelable, and was a
Parcelable itself. The abstraction may have been useful at some point,
but that time seems to have passed.
Change-Id: I2f1f45828782ab44aa8935aa50b825e07845a2a5
- adds a compile time dependency to the guava library
- changes to use @VisibleForTesting in places to ensure it works
Change-Id: I2c5c4f9861234fec3613da011185e5c11f228466
We were handling the subfolder icon strangely. Sometimes it was shown in the
folder_icon view and sometimes in the folder_expanded_icon view. Now the
folder_icon view is used exclusively for system folders (such as inbox, etc...)
and folder_expanded_icon is always used for the expanded/collapsed icon.
Change-Id: Ifff9a44cc792497a469c2408337dafd431f6dfc3
Batch operations that occur when the current message selection is
contained within the affected messages will now force the selection to
advance according to the auto advance policy to the next unselected
conversation.
Bug: 3409809
Bug: 3405864
Change-Id: Ibe75f32b9263ef6f3fb2314a07e63980f437f988
If a mailbox doesn't have any sub-mailboxes, only allow selecting them to view
any contained messages. Do not update the mailbox list.
Change-Id: I6f469bf20a57dc440885402084c21ff184f13dff
The layout requires different indentation. Although the exact layout may
change, we will likely always need to differentiate between the different
mailbox types.
Change-Id: Ia2ff84b552873f92fa45563b2dc0868c29bec3e3
mPreviousMeetingResponse is tied to the current response state, so it
should be reset too when we clear the response checkboxes.
Bug 4132763
Change-Id: If816706f47f8500441330882fb4f372b31465ff5
When selecting a nested folder, the currently selected folder should be listed
along with "All Folders" and sub-folders
Change-Id: I7c6f726a0355a13d3e7b59aa4707bd92473283b4
All focus changes to the message body content was pushing the selection
to the end, which is wrong if state restoration happens, and is just
non-standard behavior if the user explicitly taps on a particular spot
on the text view. Make this slightly less aggressive.
Misc other changes in compose view.
Bug: 3076256
Change-Id: I9edb9c3c4edb5ddec12207f4136f3ca73cabf89d
* Just in MessageListXL for now, as with search
* This allows us to test functionality within EAS, and confirm that
it's all working w/ unbundled Exchange (API 1)
Change-Id: I4f062ae871a28d2b57a23a269d6ec65903181d26
There's no need to use a different loader ID for each mailbox. Just use
one loader ID to keep things simple.
Change-Id: I46cf0a9ad48c8e0badf72ee73e2d5edadda66912
Exchange accounts support nested folders, so, we need to use the selection
that excludes any mailboxes with IDs greater than 0. Otherwise, we see all
mailboxes on the account.
Change-Id: If8c2085458176e8bd87013e3b598bd7740c652b2
currently only really works for exchange accounts. legacy accounts (imap
or pop) do not build a folder heirarchy.
Change-Id: Idb7c622b64a599a0776233a076359869f4ab4a4f
- All layouts are still temporary, but at least they're usable now.
- Removed reply/forward button from the bottom panel.
There're buttons in the layout.
- Switched to getView().
- removed the unnecessary LinearLayout from the xlarge layout.
- removed some backgrounds that'll probably not be used.
Change-Id: I3aa27c63ab139ae30e5714ac3d9a1eadce74b0e8
The roles between MessageListXLFragmentManager and MessageListXL was confusing
and not well defined. Now, the activity (MessageListXL) is responsible for
managing the application "chrome" (such as the action bar) and
MessageListXLFragmentManager is responsible for managing the content area.
Change-Id: I9a36d962bae5263f17fc7dccf133a6711229821c
Only pass along the things we need. For the message dialog, we were passing
in an Activity that was not needed. In the ActivityHelper, we were passing
in an Activity when all we needed was a Context.
Change-Id: I9a93ae07ff2bbdce9466c7e991410c87fb610673
the callback method name was not appropriate in all situations. This has been
renamed to just "onBind()" and will still be invoked whenever data is bound to
the adapter. also, create an empty callback that can be used if the adapter
doesn't need to be informed when a bind occurs.
Change-Id: Ifaa4aea3a59734557651270330ca9439e3ea4ab4
... assuming we're going to use the holo light on the phone as well.
Now the text on MailboxList is clearly visible.
Also updated/added some comments.
Change-Id: I280db2b82cbd1627c78a305dd31bbf1b1bb34d1d
There are currently two places where we use a mailbox list -- in the main
view and in the "move to" dialog. We've replaced the single, modally
configured adapter with two specialized subclasses.
Change-Id: I5dfd5ccd435fefbab4b7647c2bd7a14818f73bf3
There are two ways globals can be specified. There can be only one global
character ['*'] and/or multiple wildcard characters ['?']. The global
will match zero or more characters. The wildcard will match any character.
bug 4090086
Change-Id: I07e3edebd1fe989094c68cf047ce5bc9fb91aba0
... for Welcome and EmailWidget. So that now it's safe for onDestroy()
to be called while a task is running. (onDestroy cancels it.)
Change-Id: I660b471465170e1d1d0ce153571fb924ae703d7d
Added two new functions:
- UiUtilities.getView()
is a fail-fast version of findViewById(). Crashes when there's no view
- setVisibilitySafe()
same as View.setVisibility, but doesn't crash even if a view doesn't exist
Let's try to avoid the use of findViewById(), and instead use getView(), *right
after* the layout is inflated, so that we'll always fail-fast if a layout
doesn't have a required view. (Rather than getting a NPE only when the view
is really accessed, which can be in a code path which is rarely executed--e.g.
only when there's a protocol error.)
Let's only use findViewById() only when we're sure no all the variants of a
layout have the view in question and leave a comment to make it clear it's on
purpose.
(UiUtilities has been moved from com.android.email to
com.android.email.activity)
Change-Id: I36e0bab65a989f5d34cf636f13e1eaee084547af
After the account is created, don't allow editing the user name. We want to
prevent this as the user name is core to the account and changing the user
name is tantamount to creating a new account.
bug 3502279
Change-Id: I1d89710fd48aca67ba13abea5bdbdc1d87941618
We now allow a single global character ['*'] to be specified somewhere in
the domain attribute. Additionally, we will replace the string "$domain"
with the matched domain in all attributes -- user name, password and URIs.
bug 4090086
Change-Id: I46a637ed364c1a079e1230fa22393a1bac059b1f
- Menu now works
- Removed a lot of unnecessary/soon-to-be-unnecessary code.
Especially,
- multi-selection panel is now replaced with CAB
- SetTitleTask will be replaced with a loader
- Removed the option menu xml for magic mailboxes
(The regular one should work for them as well)
Bug 4184142
Change-Id: I52adff6d711232d536b6f00367a240e1faeea14b
If an IMAP server supports the UIDPLUS capability, it can return the new UID
as part of the response to the "UID COPY" command. However, if the server does
not support UIDPLUS, we perform a SEARCH to try to determine the new message
UID.
This is the second of a couple modifications.
bug 4092301
Change-Id: I1f548b63becfec8733cb8ba9a3fe6ff4be6fdd83
We were always loading from the network for HTML messages. Now we don't
load from the network until the user clicks the "display images" button.
Change-Id: I1838b6cb09d49a2b521baa12a80239107391534f
When copying messages between mailboxes using standard IMAP, we must perform
a QUERY or FETCH in order to determine the new message UID. However, if the
server supports the UIDPLUS capability, the server will return the new UID
as part of the response to the "UID COPY" command.
This is the first of a couple modifications. We still need to fallback to a
less efficient QUERY/FETCH if the server does not support UIDPLUS.
bug 4092301
Change-Id: I9279f7fd70daf85adba3b3e202c12d67ddf91f22
Refactor the changes introduced in Ib02842bb.
- Now Welcome and AccountSettingsXL accept intents with URLs of the following
style, and get IDs from query params, rather than extras.
Welcome:
content://ui.email.android.com/view/mailbox?ACCOUNT_ID=1&MAILBOX_ID=2&MESSAGE_ID=3
AccountSettingsXL:
content://ui.email.android.com/settings?ACCOUNT_ID=1
- Now the "new message" and "login failed" notifications use these new style
intents, so the system wouldn't merge PendingIntents for different accounts.
Also:
- Moved all notification creation logic to NotificationController.
(Except the one in CalendarSyncEnabler; which is used only to support
upgrading from pre-froyo and I don't think it's worth refactoring.)
- Note the "password expired/expiring" and "security needed" notifications
aren't changed; they still use extras to store account IDs. This is okay
because these notifications are not per-account.
Bug 4065269
Change-Id: I70737438d2e7c45fd7488a5b0a7105c8568e02f7
We initialize the focus with setNewMessageFocus(), but it's only called
from processSourceMessage() (for EDIT_DRAFT) initFromIntent() (for other
actions, except for "new draft"). We didn't intialize the focus for new
drafts. Let's just get the To field to get the focus by default to
cover this case.
Bug 4048238
Change-Id: I50cd69b8813198c96beab2025576d390520dc6a4
Modified location of the test to processUploadMessage() method. We do this to
prevent creating multiple EmailContent.Message objects.
bug 4096266
Change-Id: Id83d3703283c0cd89a60c6210976093d39fb6934
There is an optimization to prevent re-loading server settings if they've
arlready been loaded once. However, in certain circumstances (e.g., server
setting auto discover), we want to be able to reload the server settings.
bug 4091290
Change-Id: I03c47a7fe3b45d1c581401ac891895a00315d45b
When processing message updates, we handle messages in the "sent" folder
specially. We continue to do that. However, we must also check that the
given message is still in the "sent" folder.
bug 4096266
Change-Id: Iaa47512fad287e63d8216b755a761b52b324cfff
* We needed to set DevicePolicyMnager.PASSWORD_QUALITY_COMPLEX
* Setting this, we also need to clear some of the defaults for complex
mode that are not correct for Exchange's definition of "complex".
* Unit tests
Bug: 4092218
Change-Id: Iea7bd05d48f1aa9406222c1db5937cfd7f2662b8
* Caught & diagnosed by crash while checking settings
* Also possible in MoveMessageToDialog
Bug: 3412875
Change-Id: Ie78c61cf5ca10ce1eedc25ba2eb97ed0ac5bc615
We would update the attachment buttons if the UI was becoming visible (i.e.
coming back from a settings page), but, we weren't updating them after the
attachment finished loading.
bug 4074694
Change-Id: I9d235620b5a92c2bbb871f70c9d97350cc151ce8
The attachment info may be null when we attempt to mark them for downloading.
Add a null-check before we try to dereference the info structure.
bug 4053184
Change-Id: I831e3abd100664c92f7af585014a03250e40ff64