summaryrefslogtreecommitdiff
path: root/java
AgeCommit message (Collapse)Author
2017-12-07Switched CallLogDataSource interface to be Future based.zachh
Bug: 34672501 Test: existing PiperOrigin-RevId: 178038086 Change-Id: I1230992ad04bb4415f5a29bd15802d23dff88012
2017-12-07Add DialpadView's OnPreDrawListener in onFinishInflate() to ensure the ↵linyuh
layout is inflated before adjustments are made. Bug: 69665429 Test: DialpadFragmentIntegrationTest PiperOrigin-RevId: 178031541 Change-Id: I8e8799fd26a151a5357cd0bf4e2d886c802a15a5
2017-12-07Added manifest override for PhoneLookupHistory provider.zachh
Enabled PhoneLookupHistoryRecorder. Bug: 34672501 Test: manual PiperOrigin-RevId: 178030404 Change-Id: I4626262ebed14a9478f5ac8fc89fc81655e98b70
2017-12-07Hide bubble in (New)ReturnToCallController.tearDown().yueg
There is the case that onDisconnect() is not called but InCallService is unbind. Currently we only hide bubble when call disconnected. We should also do it when InCallService is unbind. Test: NewReturnToCallControllerTest, ReturnToCallControllerTest PiperOrigin-RevId: 178029862 Change-Id: I6806c5c80adb06317f09019bdf3420b462225945
2017-12-07Grouping each listener's logic in an inner class in CallDetailsActivity.linyuh
Bug: 70218437 Test: Existing tests PiperOrigin-RevId: 178029820 Change-Id: I60afe7c6d61a61ce4aa2fd2e30fbd5d869072930
2017-12-07Allow VVM activation to be rerun if carrier sent STATUS SMStwyen
Carrier might send STATUS SMS actively if the account configuration has changed. Previously it will be discarded if the account is already activated. In this CL activation will be rerun if the messageData already exist since it is initiated by an STATUS SMS. Bug: 69857261 Test: ActivationTaskTest PiperOrigin-RevId: 178028542 Change-Id: I6d103569c2be4eeadc3a7877d160fff03ad8b40e
2017-12-07Check for null subscription info list in TelecomUtil#getSubscriptionInfo.zachh
The javadoc for the method states that it can return null if the current state is unknown. Bug: 70224613 Test: unit PiperOrigin-RevId: 178020566 Change-Id: I4cd6f76b7c0572d1c9797eba4bf9c3981846468e
2017-12-07Ignore "new" voicemails that are too old for notificationstwyen
Bug: 68049435 Test: CallLogNotificationQueryHelperTest PiperOrigin-RevId: 178016400 Change-Id: I6ddbebc9edce6830966072d42cf05eb21f26c8ac
2017-12-07Display the automatically detected home country in assisted dialing settings.erfanian
Some degenerative cases are considered, like detected home countries that are currently unavailable. Bug: 68775522 Test: unit tests PiperOrigin-RevId: 178007559 Change-Id: Id85d7a2af1aa67757450bbbc80fd3ee67790b21c
2017-12-07Add DATA_USAGE column to the annotated call log.linyuh
Data in this column are copied from the DATA_USAGE column in the system call log (android.provider.CallLog.Calls#DATA_USAGE). Bug: 70218437 Test: AnnotatedCallLogDatabaseHelperTest, SystemCallLogDataSourceTest PiperOrigin-RevId: 177999609 Change-Id: I64d70734e8e85767f1e93a4a22ce2aae6c2168a1
2017-12-07Temporarily disable PhoneHistoryRecorder.zachh
PhoneLookupHistory provider isn't correct overridden in GoogleDialer manifest. I'l fix that in a later CL. Test: manual PiperOrigin-RevId: 177988816 Change-Id: I42af03d22db50bd70219d52826294529462bae43
2017-12-07Bubble v2 animation changes.yueg
Including: - expanded view expands/collapses from top of itself - small icon on avatar shows on left side when bubble is on right side - when expand on bottom, bubble move up a bit so that expanded view doesn't go off screen. It also go back to previous position when collapse. - remove animation for collapse when move expanded bubble This change should not enable bubble v2 for anyone. Bug: 67605985 Test: manual PiperOrigin-RevId: 177974562 Change-Id: Id83f3f744b717d51fbe58e58769ac2cd2810d2b5
2017-12-07Refactor Assisted Dialing Settings into standalone activity.erfanian
This will enable easier porting back into the framework. Test: existing tests PiperOrigin-RevId: 177960274 Change-Id: I1aa18734758900a93b19f4bb87b7759f6f7ca370
2017-12-07Added PhoneLookupHistoryRecorder.zachh
When a call is added in InCallUi, it fetches the current PhoneLookupInfo for the call and writes it to PhoneLookupHistory. Required updating PhoneLookupHistoryContentProvider#update to use "replace" to (presumably) atomically insert when a row is missing. Bug: 34672501 Test: unit PiperOrigin-RevId: 177896892 Change-Id: I43f9ded240a81156722be816a9635d586de642a1
2017-12-07Added PhoneLookupSelector.zachh
This class is responsible for prioritizing and selecting data from a PhoneLookupInfo object, which contains information from many phone lookup sources. Bug: 34672501 Test: unit PiperOrigin-RevId: 177893924 Change-Id: Ib98a4656fe87141162a7ac53af4a0ad421196046
2017-12-07Removed timestamps from PhoneLookup APIs.zachh
Also added onSuccessfulBulkUpdate method. It is safer for each PhoneLookup to keep track of its own last processed time via shared prefs where the value saved is the actual last processed timestamp from the underlying data. This is because it is difficult or impossible to select a single time that spans lookups due to queries being run and processed at different times. The onSuccessfulBulkUpdate method is provided as a hook for PhoneLookups to persist their shared pref once they know the result of bulkUpdate have been successfully saved. Finally, removed usage of the lastModified timestamp from PhoneLookupHistory in PhoneLookupDataSource since I believe the cases it was originally intended to cover are now handled by populateInserts(). Bug: 34672501 Test: unit PiperOrigin-RevId: 177891586 Change-Id: I072409fc217e4d7e36816548862e8b358aebf165
2017-12-04Add filtration logic to Assisted Dialing Settings.erfanian
The filtration logic will only show countries in the country picker if the feature is enabled for those countries. This will not cover the regressive case where a user has already selected a default option, but then the option is later removed. This behavior is currently undefined. Bug: 69274259 Test: unit tests PiperOrigin-RevId: 177881199 Change-Id: I113f6d25249c42c1bd98383fd6ee0bc6a8c0e615
2017-11-30Implemented new favorites list UI.calderwoodra
Bug: 36841782 Test: implemented PiperOrigin-RevId: 177516412 Change-Id: If9478ce22c10fd17e352d5fdcc2c0bef5e14a6d8
2017-11-30Action bar is no longer visible in dialpad search after configuartion change.calderwoodra
If a user, for example, opened dialpad search then entered multiwindow mode, the actionbar would be visible and search results maligned. This change corrects that by updating it's state once possible. Test: manual PiperOrigin-RevId: 177497979 Change-Id: I41d4910b5bb92e29623960e7d4741a9a961e5b9e
2017-11-30Rollback Broadcast in-call UI changes.yueg
Test: none PiperOrigin-RevId: 177490090 Change-Id: Ide2ea08f89b8a8072913617e6ce4587abffc7df4
2017-11-30Fix NPE crash on video call.wangqi
Bug: 69960961 Test: manual PiperOrigin-RevId: 177486235 Change-Id: I241867456830e0a8479ed0652aac71abc77c86e3
2017-11-30*** Reason for rollback ***roldenburg
Copybara is fixed for AOSP export Bug: 68665330 Test: rollback PiperOrigin-RevId: 177480870 Change-Id: I0ba38e213bb840436fa6dafc4af0a79019ee93f4
2017-11-29Implemented fill for PhoneLookupDataSource.zachh
Rewrote FakePhoneLookup to be more realistic. Bug: 34672501 Test: unit PiperOrigin-RevId: 177376374 Change-Id: Ifcd52b16b7046f39d1bfc0e8b8e76452a9daadd2
2017-11-29Search contacts now update when there are changes to the cp2 db.calderwoodra
Since we close the original cursor we queried in the cursor loader, we need to assign a new content observer to the cursor we build so that our search results update when there are changes to the contacts db. Bug: 63830179 Test: manual PiperOrigin-RevId: 177368459 Change-Id: I025ea70334265cb2fdc651ed7ea046b039738e94
2017-11-29Bump API ceiling for Assisted Dialing.erfanian
Bug: 69857502 Test: TAP PiperOrigin-RevId: 177367228 Change-Id: Id79546672fa8bf3bf85bbe569ef638970b1365d8
2017-11-29Add flag to control default assisted dialing state during precall flow.erfanian
Currently, the only other client that is initiating calls is Contacts, and we consider that to be a non-idle-dial. Bug: 69860859 Test: existing unit tests PiperOrigin-RevId: 177367226 Change-Id: I22de38dc973f5a1eecfe42833110690744c317fd
2017-11-29Enable timer in emergency call.wangqi
"This phone's number: xxx" is shown for emergency call which replaces in call timer. This change move it to under emergency location service so timer could be shown again. Bug: 69810801 Test: manual PiperOrigin-RevId: 177363955 Change-Id: I543fbbee869923800ffd92a5799819b712f0b953
2017-11-29Move country constraint logic into standalone class.erfanian
In a subsequent change, the assisted dialing settings will be able to use the parsing logic to filter the available countries listed in the settings. Bug: 69274259 Test: existing tests PiperOrigin-RevId: 177338864 Change-Id: I8ef76874d5f6d885b415174371225b738cc68716
2017-11-29Adjust strings for select SIM dialogtwyen
Test: N/A PiperOrigin-RevId: 177336359 Change-Id: Icec2eacef55ea6c1b3aad00fe10cde6284c89e25
2017-11-29Delete voicemails when disabling visual voicemailmdooley
For privacy reasons we now delete all voicemails and transcriptions when the user disables visual voicemail, (after confirming that they want to do this via a dialog). Note: we only delete voicemails whose source package is the google dialer. Note: the voicemails will be re-downloaded and re-transcribed if the user re-enables visual voicemail Bug: 69323147 Test: manual and unit test PiperOrigin-RevId: 177315139 Change-Id: Ie04496dc5960b485794733fbf74f7f704e806023
2017-11-29Switching to alarms and exponential backoff while polling for transcription ↵mdooley
result This cl switches the way asynchronous transcription tasks poll for their results. it has been observed that sometimes the server side transcription takes longer than expected (sometimes many minutes), so instead of blocking a thread for all that time this cl schedules an alarm for the next time to poll. it also uses an exponential backoff scheme to determine the poll times and increases the maximum total polling time from 20 seconds to 20 minutes. Bug: 66966157 Test: manual and unit tests PiperOrigin-RevId: 177257577 Change-Id: Ib2998f03cc418d5241ccffec71ba3945c9fe4cbc
2017-11-29Format number for SIM selectiontwyen
Bug: 69812286 Test: PhoneNumberHelperTest PiperOrigin-RevId: 177227451 Change-Id: I6cf53e50d17860f4374cbd9a94451bc0731905a4
2017-11-29Disable phone number formatting on the dialpad when making domestic call to ↵linyuh
Argentina mobile numbers. Bug: 30224215 Test: DialerPhoneNumberFormattingTextWatcherTest, DialpadFragmentIntegrationTest PiperOrigin-RevId: 177218942 Change-Id: Id6eaaad2f6d81e591d59a1d8444f45fb06f3f8d5
2017-11-29Fix resource not found when placing call outside dialertwyen
newInstance() defaults setDefaultResId to 0 and if it is written into the args the real default ID will not be used. Bug: 69804734 Test: SelectPhoneAccountDialogFragmentTest PiperOrigin-RevId: 177194281 Change-Id: Ic2b50fa741d812fd464d5e81199b040ef4c07195
2017-11-29Prevent PreCallActivity from showing in lockscreen if it is not started in ↵twyen
the lockscreen Bug: 69812359 Test: PreCallActivityTest PiperOrigin-RevId: 177193665 Change-Id: Ic61819b8456ee22c01228d6be2255b3f2c1e418a
2017-11-29Prevent change SIM icon from showing during a voicemail calltwyen
Calling the VM other number is to complicated for this release. Bug: 69803593 Test: CallButtonPresenterTest PiperOrigin-RevId: 177193486 Change-Id: I4149abe1d6eea48bb5399e12b9ce43a8e1ef4b37
2017-11-29Expose user home country code as public method in Mediator Interface.erfanian
This will be used in a subsequent change to show the user the default/predetected country code in the assisted dialing settings. Bug: 68775522 Test: unit tests PiperOrigin-RevId: 177168946 Change-Id: Ic738a6ddde8766962a725668f6db5056ab0bcafd
2017-11-29Update assisted dialing setting text.erfanian
Bug: 69562852 Test: none PiperOrigin-RevId: 177165337 Change-Id: I297faa26d778ec39f2365e84e90398e7ab49f353
2017-11-29Contact list no longer jumps to the top when the cp2 database updates.calderwoodra
The contacts fragment recycler view was rebuilding the adapter and layout manager each time the Contacts.CONTENT_URI observered a content change. Now we simply update the adapter's cursor and notifyDataSetChanged. This keeps the recycler view in place through all changes (inserts, deletes and updates). This change also fixes another bug replated to contacts fragment not refreshing when the contacts permission was granted in another part of the UI. Bug: 64044576,67781478,68179085 Test: manual PiperOrigin-RevId: 177106761 Change-Id: Ib6a929efb047001d681cb008c3ede69860146836
2017-11-29Refactor DialpadFragment's DtmfKeyListenermaxwelb
This change is the refactoring on DtmfKeyListener and adding tests. The class is an overridden version of DialerKeyListener, but it also supports direct onKeyDown and onKeyUp hooks from the DialpadFragment. There was a lot of duplicated code between these hooks and the overridden methods so the code was refactored to share more logic. The interesting part of this change is using EMPTY_SPANNABLE to call into super type methods instead of having to copy the implementation. This change may also help with OutOfMemoryExceptions because the DtmfKeyListener is promoted from a non-static inner class to a top level class. It no longer maintains an implicit reference to the DialpadFragment, holding onto the DialpadPresenter instead. To support testing this code, the ShadowCall had to be updated since it didn't support checking when a Dtmf tone was playing. Bug: 69133398 Test: DtmfKeyListenerTest, InCallActivityTest PiperOrigin-RevId: 177092841 Change-Id: I368083c71982e14db0ad936432a3a5bdf0dde5ee
2017-11-29Adjust strings for select SIM dialogtwyen
Test: N/A PiperOrigin-RevId: 177075957 Change-Id: Idf4546c57aba72470e07614d2a20d828da8ee08d
2017-11-29Add impressions for dual sim featurestwyen
Bug: 69618691 Test: CallingAccountSelectorTest PiperOrigin-RevId: 177062349 Change-Id: I4bc9098d06c541b607cca293269cf3489077b6c2
2017-11-28Adding transcription rating feedbackmdooley
Allow users who have agreed to donate their voicemails to also provide transcription quality feedback. screenshot: https://drive.google.com/open?id=0B9o_KvtLkcuIajVtdFN3Y0Qydmx2NXJYN2N3OVA3N0h5UEdR Bug: 68712148 Test: manual and new unit tests PiperOrigin-RevId: 176774942 Change-Id: I08b9afbbefaedfb0de5199038a1d2769bd983855
2017-11-22Fix the crash caused by DialpadView's OnPreDrawListener.linyuh
OnPreDrawListener can be triggered AFTER a device orientation change but BEFORE DialpadView's onDetachedFromWindow() and onFinishInflate() are called, i.e., the listener will attempt to adjust the layout before it is inflated, which results in a crash. This fix is to remove the listener after all keys are adjusted for the first time since no more adjustments will be needed during the rest of DialpadView's lifecycle. Bug: 69665429 Test: DialpadFragmentIntegrationTest PiperOrigin-RevId: 176718488 Change-Id: Iff8a4108c73054a9e76725ef85e2559b90fe5f3e
2017-11-22Prevent SIM selection and change SIM from showing when there are active callstwyen
Most devices are DSDS (dual SIM dual standby) which only one SIM can have active calls at a time. Telecom will ignore the phone account handle and use the current active SIM. The SIM selection dialog has no effect, and the change SIM button will just redial with the same SIM. Bug: 69417430 Test: CallingAccountSelectorTest, CallButtonPresenterTest PiperOrigin-RevId: 176718021 Change-Id: I231cfeaa5ff77c29cdaf8e0865d096c85cfb7fc4
2017-11-22Fix showing CallingAccountSelector in lock screentwyen
FLAG_SHOW_WHEN_LOCKED is added to PreCallActivity so it can be launched in lockscreen. PreCallCoordinator now grabs new instances of PreCallActions onResume so the state can be flushed. If it is reused states like PendingAction might be used after it is discarded. Added null check before discarding fragment because it might not be created yet due to background query. Bug: 69570769 Test: CallingAccountSelectorTest PiperOrigin-RevId: 176714225 Change-Id: I8b09441bd1cdb8df835978a1d82b53a3d3d056e0
2017-11-22Automated rollback of changelist 176587256twyen
Bug: 69570769 Test: CallingAccountSelectorTest PiperOrigin-RevId: 176706378 Change-Id: I50da0d2dd40a83ae6c1189fed2693368369849d3
2017-11-22Check Contacts support for preferred SIMtwyen
Preferred SIM can only be enabled when both dialer and the system contact app supports it. This CL checks if the app for ACTION_QUICK_CONTACT has the metadata supports_per_number_preferred_account. Also added a flag to disable the whole preferred SIM feature. Bug: 69638458 Test: CallingAccountSelectorTest PiperOrigin-RevId: 176687062 Change-Id: Id00debe2393068a422907a9eff2ac4ef0fcf6f8e
2017-11-22Add SpamJobType for all spam job IDs.wangqi
Bug: 69556012 Test: SpamJobSchedulerTest PiperOrigin-RevId: 176683042 Change-Id: I2807510e3c511c1672ed2c49117ad03b92c4cee5
2017-11-22Bubble v2 UI changes.yueg
Including: - Use exit-to-app icon instead of fullscreen icon for back-to-call button - Use ripple for first button since it needs top-rounded background - Change red hang-up button color and grey icon and text color - Change some dimensions Bug: 67605985 Test: manual PiperOrigin-RevId: 176678427 Change-Id: I3f7836d832f7130f82d7f3764fb392807f3fab9a
2017-11-22Allow deleting a call log entry in the call log UI and the call details UI.linyuh
In the call log UI, an entry can be deleted by selecting "delete" in its context menu. In the call details UI, a "delete" button is added at the bottom. The "delete" icon at the top right of the call details UI is removed. Public-Origin-Change-Id: Iabe1310fb9a97a277cf482a3fd61ffccbec125fe Signed-off-by: Linyu He <linyuh@google.com> Author: Masafumi Miya <masafumi.miya@sony.com> Bug: 38188896 Test: CallLogActivityIntegrationTest, CallDetailsActivityIntegrationTest PiperOrigin-RevId: 176677167 Change-Id: I2e31cd112efdfb83393f5e68ce016dcf36ac4858
2017-11-22Fix showing CallingAccountSelector in lock screentwyen
android:showWhenLocked and FLAG_SHOW_WHEN_LOCKED is added to PreCallActivity so it can be launched in lockscreen. PreCallCoordinator now grabs new instances of PreCallActions onResume so the state can be flushed. If it is reused states like PendingAction might be used after it is discarded. Added null check before discarding fragment because it might not be created yet due to background query. Bug: 69570769 Test: CallingAccountSelectorTest PiperOrigin-RevId: 176587256 Change-Id: Iaa7145e860136e9177f568e2c84461ed5efa12a1
2017-11-21Force disable VVM if carrier app is preloadedtwyen
This CL checks if the carrier app is installed on the system image. If so, VVM will be force disabled (user can't turn it on, can't even see the switch as if they are on a unsupported carrier). Otherwise, VVM will only be disabled by default if the carrier app is present (User can still turn it on in settings). Bug: 67496592 Test: OmtpCarrierConfigHelperTest / manual - move carrier app to /system/app PiperOrigin-RevId: 176586849 Change-Id: Idf79bdf61c600423062ca54d1b4c6e77cfcd8033
2017-11-21Adding call feedback mechanismAndroid Dialer
Test: No impact on existing functionalities PiperOrigin-RevId: 176562444 Change-Id: I209379dde3e920a27d6e735c8494647154e40e5a
2017-11-21Require N for preferred SIM querytwyen
PhoneLookup.DATA_ID is only available after N. The fallback database should address this in a future CL. Bug: 69420158 Test: CallingAccountSelectorTest PiperOrigin-RevId: 176534281 Change-Id: I51ae1705fce6d7d4138b41fbd00d131447e49786
2017-11-21Reduced jank when placing a call from search UI.calderwoodra
I accidently made the search/dialtacts UI TOO performant and everything was happening too quickly. Postponed closing the dialpad and exiting search until onPause, but immediately close the keyboard so it isn't visible over the in call ui. Bug: 69313203,68857994 Test: see video PiperOrigin-RevId: 176531801 Change-Id: I52729c451d46ad00ac87c47f189134694554d33a
2017-11-21Nearby places location permission request is now in a card view.calderwoodra
Bug: 68272141 Test: n/a PiperOrigin-RevId: 176531675 Change-Id: Ia6cc29c4285ebe280d23a81f91007a02a65855b3
2017-11-21Merge what's left in InCallActivityCommon into InCallActivity.linyuh
Bug: 69272096 Test: None PiperOrigin-RevId: 176443652 Change-Id: I90da4789deb4b6337a38cfe010b8aee5090d35e0
2017-11-20Quick fix recursively importing.weijiaxu
Test: On a local device. PiperOrigin-RevId: 176443649 Change-Id: I73982924baf6ce0e947137766ec0038decd716e5
2017-11-20Add impression to track when users explicitly disable assisted dialing.erfanian
Test: new unit tests PiperOrigin-RevId: 176438950 Change-Id: Ic0747302170593b91da4148029396c36ab070c6e
2017-11-20Initialize executors before updating change PIN statetwyen
When the activity is launched it might immediately attempt to verify the stored pin, which happened before the executor is initialized Bug: 69179171 Test: N/A - legacy code, refactoring required PiperOrigin-RevId: 176433263 Change-Id: I8202a760dbfc7759e128ef31d477510526d0bee7
2017-11-20Remove assert on StubVoicemailClient.addActivationStateListener()twyen
The default "do nothing" behavior is enough. Bug: 69309850 Test: N/A PiperOrigin-RevId: 176427193 Change-Id: Icd66f8ebb75b889a3cceef895bc3bf71c466ccf6
2017-11-20Implement SIM selection dialogtwyen
Bug: 64216442,64214592,64213352 Test: N/A PiperOrigin-RevId: 176424724 Change-Id: I1709156098a14ac3bd35d98b913e7b881fcd9b2b
2017-11-20Clear pendingAction when pausing PreCallCoordinatortwyen
When resumed runNextAction() will assert that pendingAction is null so if there's any it won't be interrupted. When the coordinator is paused all dialogs and pending actions must be discarded. If the pending action is not properly discarded it will still assert when trying to call finish(). Bug: 69069675 Test: PreCallCoordinatorImplTest PiperOrigin-RevId: 176420108 Change-Id: Ie89bda3621371a105dc58ff02d83812194a1ea0b
2017-11-20Add fast database populating button for benefit of testing.weijiaxu
Bug: 69431528 Test: On a local device. PiperOrigin-RevId: 176420058 Change-Id: I3013800d86597b19268723377112286d2e2ceb68
2017-11-20Dialpad icon now remains white through device rotation.calderwoodra
Bug: 69463065 Test: manual PiperOrigin-RevId: 176399153 Change-Id: I699688ab47c1ba497a0b6bb3301380a8e06f2ee2
2017-11-20Add config flag for CallingAccountSelectortwyen
Since CallingAccountSelector is currently the only action that requires a UI, disabling it will effectively revert the PreCall behavior back to pre-PreCall era, sending intents to telecom directly. Bug: 68953196 Test: CallingAccountSelectorTest PiperOrigin-RevId: 176398440 Change-Id: I612a56bc66f32cf72779bd7c507de6a0784f1298
2017-11-20Fixing verizon TOS textmdooley
This was caused by cl/176065849 where we added a per carrier check to see if transcription is supported. new screenshot: https://drive.google.com/open?id=0B9o_KvtLkcuINkJ0R0JPTUZWSlpDMmlaRFdEUnJkY3pyTmxR Bug: 67457582 Test: manual and updated unit test PiperOrigin-RevId: 176389716 Change-Id: Ib41607a0ec6e9b40092d32fe055db80b6f9f8301
2017-11-20Cancel missed calls in call history when needed.yueg
Including when: - onStop() - switching tabs Also move old CallLogActivityTest to espresso directory. Test: CallLogActivityTest PiperOrigin-RevId: 176387019 Change-Id: Icbb77747882c8a5e35595557baa6917a4dc674b6
2017-11-20Add more Cequint provider and signature check.wangqi
This change expands Cequint Caller ID to more provider name and adds signature check to avoid fake provider fraud. Bug: 69061848,69310040 Test: CequintPackageUtilsTest PiperOrigin-RevId: 176386836 Change-Id: I02bb3f67d74f7cccbf99b0967e517595c6c2033b
2017-11-20Use correct field type for annotation definition.erfanian
Test: TAP PiperOrigin-RevId: 176382315 Change-Id: Ifb41457ad54cdffe9d721f6c13ee985b0a30149a
2017-11-20Search now supports alternative sort and display orders for contact names.calderwoodra
This means that names like "Bob Dylan" can be displayed as "Dylan, Bob" and the names are now able to be sorted by last name as well. This change also adds content descriptions to search icon for a11y. Bug: 68293751 Test: NewSearchFragmentTest PiperOrigin-RevId: 176382228 Change-Id: Ia890ad20e9e484fa9c4622c4b899b33f5b6e3990
2017-11-18When an expanded NUI VM is collapsed, ensure it remains collapsed when ↵uabdullah
recycling views. The adapter maintains the state of those voicemails that were expanded. When the views are recycled we ensure that the expanded view holder whenever visible is expanded. However when an expanded viewholder is collapsed, taken out of view and then brought back into view (recycled), the expanded state is preserved. This CL ensures that this no longer happens. Bug: 64882313,68382421 Test: Unit test PiperOrigin-RevId: 176233960 Change-Id: Ib57859a287ec0c4f9e955a0fc01a49f093023fd1
2017-11-18Added place voice call search action to regular search.calderwoodra
When a user types a phone number into the search bar, there isn't an intuitive way for them to place a call when the number doesn't match any existing contacts in the new search UI. This change adds the option to place a voice call from regular search, like the old UI. Bug: 69385190 Test: NSFT PiperOrigin-RevId: 176189153 Change-Id: I6c1561bcce104c56855d996570a79b34da7230ff
2017-11-18Guard against remote directories returning results with no phone numbers ↵zachh
during search. We have observed in the wild that some apps implementing remote directory don't seem to respect the where clause. Note that if a search returns 10 results, and 4 of them have null numbers, we will only show 6 numbers where ideally we'd show 10. (It would take a lot of work to fix that just to workaround misbehaving providers which I don't think is worthwhile.) Bug: 68942044 Test: unit + manually changed guard condition and observed rows hidden PiperOrigin-RevId: 176183008 Change-Id: Icdb26fa043644e27a4b6ac3c767c728b3ca224ff
2017-11-18DialpadView cleanup.linyuh
Changes: 1. Rewrote the logic to pick a NumberFormat. 2. Deleted dead method setShowVoicemailButton(boolean) and field mCanDigitsBeEdited. 3. Deleted the redundant SDK version check when getting a Drawable. Test: DialpadFragmentIntegrationTest PiperOrigin-RevId: 176181808 Change-Id: Iee4e3db8535ebbea3d4c63c8d8c1d3eb342b538e
2017-11-18Merge the following methods in InCallActivityCommon into InCallActivity:linyuh
01. handleDialerKeyDown(int, KeyEvent), 02. onBackPressed(boolean), 03. onDestroy(), 04. onKeyDown(int, KeyEvent), 05. onKeyUp(int, KeyEvent), 06. onPause(), 07. onSaveInstanceState(Bundle), 08. onStart(), 09. onStop(), 10. updateNavigationBar(boolean), and 11. updateTaskDescription(). Note that InCallActivityCommon#handleDialerKeyDown(int, KeyEvent) is merged into InCallActivity#onKeyDown(int, KeyEvent). This is part of the effort to delete InCallActivityCommon. Bug: 69272096 Test: None PiperOrigin-RevId: 176161247 Change-Id: I6e74c7feec5414fb4bc58814eef3bd297d6eb96f
2017-11-18Add contact source options.Android Dialer
Bug: 66900825 Test: manual PiperOrigin-RevId: 176155772 Change-Id: Ibe722477b90671b55ff7bf5405de9fb66569d43e
2017-11-18Automated rollback of changelist 174944384zachh
Bug: 68942044 Test: NO PiperOrigin-RevId: 176147553 Change-Id: Ia22751f02cdd621c2095e8e476a3077db2c541fa
2017-11-18Refactoring and adding TOS check before transcribingmdooley
This cl just adds a check before starting a transcription job to verify that the user has accepted the appropriate TOS. Its a rather big cl just because it had to expose some TOS acceptance details that were previously encapsulated in the VoicemailTosMessageCreator. Bug: 69267260 Test: manual and unit tests PiperOrigin-RevId: 176132370 Change-Id: Ic28fb197a07f9df7a9b5f1729c84566cba0890fc
2017-11-18Adding exponential backoff utilitiesmdooley
This cl adds two classes, one to calculate a base multiplier for an exponential backoff series and the other to return sequential values in an exponential backoff series. This cl has a number of advantages over the previous one, such as: - separating the base multiplier calculation from the exponential backoff class so that a standard exponential backoff class like com.google.common.labs.concurrent.RetryStrategy.ExponentialBackoff could be used instead if it becomes open source - allows the backoff sequence to be scaled by specify an initial backoff delay - uses milliseconds instead of arbitrary time units which allows the tolerance to be set automatically when calculating the base multiplier WANT_LGTM=zachh Bug: 66966157 Test: unit tests PiperOrigin-RevId: 176130268 Change-Id: I75135d4df16f642ea9dd3ef9ff9498981beae2c6
2017-11-18Implement suggested SIMtwyen
This CL adds a module that can query providers to aid users choosing which SIM to call with. Bug: 64214592 Test: MotoSuggestionProviderTest PiperOrigin-RevId: 176129303 Change-Id: Idb6314ad7f5a1bcd20b5b9173d3bfd873383cc84
2017-11-18Fix dialer simulator for conference calling funcitonality.weijiaxu
Updated the following contents: 1.Fix the order of spawning connections for GSM conference. 2.Make VOLTE conference call more realistic. 3.Fix minor bugs about simulator. 4.Add SimulatorConnectionsBank class to store connection tags created by simulator. 5.Fix tests influenced by SimulatorConnectionsBank. WANT_LGTM=wangqi Bug: 67785540 Test: In dialer lab. PiperOrigin-RevId: 176127584 Change-Id: I846174b97ed9329df6347583c41095f45f43494b
2017-11-18Use OnPreDrawListener to adjust key layouts on the dialpad.linyuh
Test: DialpadFragmentIntegrationTest PiperOrigin-RevId: 176122540 Change-Id: Iebf5ab67569fd4532411cfdae20ad5fb91cbcc55
2017-11-18Don't transcribe voicemail unless carrier allows OTT transcriptionmdooley
Added a carrier config and check to see if the carrier allows over the top voicemail transcription, and if not do not attempt transcription. Bug: 68951869 Test: manual and unit test PiperOrigin-RevId: 176065849 Change-Id: I69df1f2867420d7fdcc7f0a31e0e6c26da67abb1
2017-11-18Implement change SIM animationtwyen
CheckableLabledButton will no longer set icon if the icon has not changed, so the animation will not be interrupted. Bug: 64215256 Test: N/A PiperOrigin-RevId: 176047325 Change-Id: I8cb0c6e706b931406e78c91821f75e266e453ceb
2017-11-18Implement headless PreCalltwyen
If no actions require an activity, instead of launching the PreCallActivity, all actions will be performed immediately, and the call intent will be sent to telecom directly. This reduces the latency & risk when mutli SIM is not supported. Bug: 68953196 Test: PreCallImplTest, HeadlessPreCallCoordinatorTest PiperOrigin-RevId: 176032790 Change-Id: I03258e8643f18c65a8e5b1a84b18b71b30638044
2017-11-18Merge the following methods in InCallActivityCommon into InCallActivity:linyuh
1. maybeShowErrorDialogOnDisconnect(DisconnectMessage), 2. onDialogDismissed(), 3. showErrorDialog(Dialog, CharSequence), 4. showInternationalCallOnWifiDialog(DialerCall), 5. showWifiFailedDialog(DialerCall), and 6. showWifiToLteHandoverToast(DialerCall). Renaming in InCallActivity: 1. "maybeShowErrorDialogOnDisconnect" -> "showDialogOrToastForDisconnectedCall", 2. "onHandoverToWifiFailed" -> "showDialogOrToastForWifiHandoverFailure", 3. "onInternationalCallOnWifi" -> "showDialogForInternationalCallOnWifi", and 4. "onWiFiToLteHandover" -> "showToastForWiFiToLteHandover". This is part of the effort to delete InCallActivityCommon. Bug: 69272096 Test: None PiperOrigin-RevId: 175991784 Change-Id: I0b31bd93437e633d2f77b09982e0c7fc94ad8a32
2017-11-18Added PhoneLookupDataSource and implemented isDirty.zachh
Also extracted FakePhoneLookup to a testing package. Bug: 34672501 Test: unit PiperOrigin-RevId: 175923790 Change-Id: I866708a676e788051b369a024344967975c05979
2017-11-18Send SUB_ID_EXTRA to VoicemailSettingsActivity in Telephonytwyen
EXTRA_PHONE_ACCOUNT_HANDLE is not implemented in O. subId is required to determine which SIM the settings is for. Bug: 67669006 Test: VoicemailSettingsFragmentTest, TelecomUtilTest PiperOrigin-RevId: 175913331 Change-Id: I84f9e19b711c5baa275d934cfdfd5b7a2d4b6f6d
2017-11-18Add preferred SIM meta-data to dialer manifesttwyen
Contacts need to check the meta-data to decide if the preferred SIM UI should be shown. Bug: 64213352 Test: N/A PiperOrigin-RevId: 175912590 Change-Id: Ic02ca47ab156c3bb752b33c97cfb3b62f45a3667
2017-11-18Remove unused code InCallUiBings.getUiReadyBroadcastIntent().yueg
It also fixes NPE when mContext is null in InCallPresenter.onUiShowing(). Test: InCallPresenterTest PiperOrigin-RevId: 175898339 Change-Id: Id4aad7e15310663b9f561e5bdc56be5106e24ca8
2017-11-18Move the following methods from InCallActivityCommon to InCallActivity:linyuh
1. enableInCallOrientationEventListener(boolean) 2. isDialpadVisible() 3. getDialpadFragment() This is part of the effort to delete InCallActivityCommon. Bug: 69272096 Test: None PiperOrigin-RevId: 175898158 Change-Id: Ib0f58dbe35d528a475268a86b2af4119e7cfa381
2017-11-18Keyboard now closes in regular search when user scrolls list.calderwoodra
This change also enables search actions to be visible in regular search. screenshot: http://screen/ULBgq2RnKnM Bug: 68730642,67657783,68775021,66723880 Test: manual PiperOrigin-RevId: 175892821 Change-Id: I2c71fe8ffa2ffddfbc88d777909c4837e0ea4384
2017-11-18Optimize contact search by using a Ternary Search Tree.calderwoodra
This change updates search fragment to now preprocess query results and hold them in memory. This significantly improves the lookup runtime to be O(logn) on average and O(N) worst case. Bug: 69100384 Test: existing (plus some time measurement regression tests) PiperOrigin-RevId: 175891990 Change-Id: I6d7ae61c478b544af42d954af4e8580e052693ba
2017-11-18Dialpad FAB no longer loses it's icon on fragment resume.calderwoodra
There must be a bug in FloatingActionButton because when you call setImageDrawable multiple times (possibly with the same drawable/icon), the FAB renders with no icon present. That's why the icon would disappear in Fragment#onResume. Bug: 69006360 Test: manual PiperOrigin-RevId: 175878924 Change-Id: I1c36be3f9aeb003410f0bdbb9d52b5a483262f03
2017-11-18Automated rollbackroldenburg
END_PUBLIC BEGIN_PUBLIC Automated rollback of changelist 169615685 Test: rollback PiperOrigin-RevId: 175863544 Change-Id: I8785da90afed236cbe897efe774263765f188b14
2017-11-18Move InCallActivityCommon#dismissPendingDialogs to InCallActivity.linyuh
This is part of the effort to delete InCallActivityCommon. Related instance variables remain in InCallActivityCommon for now as they are used in several other places. Temporary getters/setters are added in InCallActivityCommon so that InCallActivity has access to these instance variables. Bug: 69272096 Test: None PiperOrigin-RevId: 175853702 Change-Id: Iaeb96c8ad7acb628393dd5c775ad7f3b40940a2b
2017-11-18Automated rollbackroldenburg
END_PUBLIC BEGIN_PUBLIC Automated rollback of changelist 169756942 Test: rollback PiperOrigin-RevId: 175849764 Change-Id: I3be3899682db84521fd933a5f058d5518ecb1fa1
2017-11-18Replace NUI voicemail media buttons with image buttonsuabdullah
Replaces the existing buttons with Image Buttons using standards images. Also added a phone button. Bug: 64882313,68382421 Test: Unit Tests PiperOrigin-RevId: 175843834 Change-Id: I21898f7da72f3dd17fce0047b11349737b373513