277056 Commits

Author SHA1 Message Date
dongwan0605.kim
03c9afadab QS: Fix QuickQS visibility at non-first page
When user collapsed QSPanel at non-first page, QuickQS always remained
View.Visible. When user canceled collapsing, QQS remained clickable
although invisible to user(alpha = 0).
QQS must be non-clickable when user cancels collapsing at non-first page.

Test: QSPanel > 2nd page > Cancel collapsing while collapse QSPanel
      > Verify invisible QQS is non-clickable

Change-Id: I4c1f195a3faec8e89bb073443f6345f4faddf781
2017-01-03 06:47:17 +00:00
Yohann Roussel
b1453a95ca Fix LOCAL_SDK_VERSION of 3 multidex apks
Test: Install the apks on KitKat device
Change-Id: I2e7d7cd4406cdc59bc81cff280c96bb616af012c
2017-01-02 21:53:04 +01:00
Treehugger Robot
9156ccdbb4 Merge "LocalSocketImpl.cpp: Set O_CLOEXEC on received FDs" 2017-01-01 22:28:37 +00:00
Marie Janssen
9cc7ebe7d9 Merge "Bluetooth: track enabling in dumpsys" 2016-12-29 19:32:36 +00:00
Treehugger Robot
8a74d0440c Merge changes from topic 'HID-Client'
* changes:
  Rename the Bluetooth profile classes for HID Device role.
  Bluetooth: Add support for HID Device Role
2016-12-29 19:29:17 +00:00
Marie Janssen
5980456040 Bluetooth: track enabling in dumpsys
Move basic state dumpsys to here from AdapterService.

Track which apps are enabling and disabling Bluetooth, including BLE
apps, and show the apps in the dumpsys logs.

Test: start phone and enable/disable, take bug report
Bug: 33692282
Change-Id: I6ea62ebdcfd7873d0be1bb5c5c520bbce3737a40
2016-12-29 19:22:14 +00:00
Ivan Podogov
0afe190af5 Rename the Bluetooth profile classes for HID Device role.
We already have BluetoothInputDevice class, so adding something
called BluetoothHidDevice seems confusing. On the other hand,
the new class is designed to connect to HID Host devices, so
naming it BluetoothInputHost makes sense and goes in line with
the existing BluetoothInputDevice.

The same goes for the new constant HID_DEVICE that is just as
confusing to have together with the INPUT_DEVICE one.

This CL also renames the "connection state changed" broadcast
(for the same reasons), declares it as an SDK constant, and also
adds some javadoc to it.

Note that BluetoothHidDeviceApp* classes remained unchanged, as
those correspond to the app that implements the Device (and
connects to the Host).

Test: make
Change-Id: I5075ca5b97db3c1dd403c2e9660eecc7380cffe2
2016-12-29 14:30:40 +00:00
Hemant Gupta
e88fd4b594 Bluetooth: Add support for HID Device Role
This patch adds the HID Device Role support in Bluetooth framework.
Also AIDL and callback related files for HID Device role are added
to provide interface for third party applications to communicate with
HID Device Service.

Change-Id: Id03a362b7bcfa2e76056fa0197eaac12ce49b5a2
2016-12-29 14:29:53 +00:00
Ivan Podogov
895e2d7a40 Merge "In permission review mode, always request user's consent to toggle BT." 2016-12-29 10:18:11 +00:00
Martijn Coenen
7705363166 Merge "Add (un)linkToDeath support to HwBinder." 2016-12-29 08:07:45 +00:00
Martijn Coenen
727f7bf84f Add (un)linkToDeath support to HwBinder.
This is mostly copied over from binder's existing
death recipient support. The implementation keeps
a list of registered recipients, both for being
able to map a native recipient back to the corresponding
Java recipient, as well as being able to unregister
recipients correctly.

Test: mma, hidl_test_java
Bug: 31632518
Change-Id: Id313fd248be6925056c4ade8298fe5fb04e007cc
2016-12-29 04:22:30 +00:00
ashutoshj
fba752e64c Merge "Change the name of the contexthub service." 2016-12-29 01:29:41 +00:00
Adrian Roos
302efd6125 Merge "QS - Fix race condition in accessibility" 2016-12-28 23:29:59 +00:00
Ashutosh Joshi
835da289fa Change the name of the contexthub service.
Change the name used by the contexthub service. Specifically, this
change switches from using the "ContexthubService.CONTEXTHUB_SERVICE"
constant to using the "Context.CONTEXTHUB_SERVICE" constant- which is in
line with the other Android services.

Merged-In: I18ae73ed0fda2f938e3233670dc52b5692d321ae
Test: GTS tests pass.

Change-Id: I18ae73ed0fda2f938e3233670dc52b5692d321ae
2016-12-28 13:57:27 -08:00
Treehugger Robot
c26aa87a2b Merge "Cleanup the evaluateBinding() method." 2016-12-28 19:52:42 +00:00
Jeremy Joslin
e3d260d4e9 Cleanup the evaluateBinding() method.
Small refactor to remove 1 level of nesting.

Test: build, run.
Change-Id: Ic46a65036b207ff73fefced914e0928de2f2b500
Merged-In: I38836ca9d18c5fcd3c6edf5931b58de3b08614ee
2016-12-28 10:18:55 -08:00
Ivan Podogov
afababd4d8 In permission review mode, always request user's consent to toggle BT.
Bug: 33155221
Test: Manual: flash the watch, check that the consent UI was
      displayed in both apps (the one with CompileSDK=21 and
      TargetSDK=21, and the one with CompileSDK=25 and
      TargetSDK=25).
Change-Id: Ic1ed987bbaf282892a2aef354a8ca0add2c829ba
2016-12-28 11:18:21 +00:00
Treehugger Robot
1471ad3ea7 Merge "Send RECOMMEND_NETWORKS action when binding to provider." 2016-12-28 02:36:23 +00:00
Joe LaPenna
9bc5effad5 Send RECOMMEND_NETWORKS action when binding to provider.
Some services use action to disambiguate which binder to return in
onBind.

Test: built && installed && bound.
BUG: 33905890
Change-Id: I83ae41b472c597661b93f5467b64b258e9056f5f
Merged-In: I83ae41b472c597661b93f5467b64b258e9056f5f
2016-12-27 14:56:54 -08:00
Jorim Jaggi
8760e60da5 Merge "Fix window transformation related issue" 2016-12-27 16:08:44 +00:00
dooyoung.hwang
1b0066230e QS - Fix race condition in accessibility
When users try to open panel, initialization of accessibility is called
in Main Thread by this callstack.

at android.view.ViewGroup.buildOrderedChildList
at android.view.View.populateAccessibilityNodeInfoDrawingOrderInParent
at android.view.View.onInitializeAccessibilityNodeInfoInternal
at android.view.View.onInitializeAccessibilityNodeInfo
at android.view.View.createAccessibilityNodeInfoInternal
at android.view.View.createAccessibilityNodeInfo
at android.view.accessibility.AccessibilityRecord.setSource
...
at android.view.View.setFlags
at android.view.View.setVisibility
at com.android.systemui.qs.QSContainer.updateQsState
at com.android.systemui.qs.QSContainer.setExpanded
at com.android.systemui.statusbar.phone.NotificationPanelView.updateQsState

And another initialization is tried in QSTileHost Thread by this callstack.

at android.view.ViewGroup.buildOrderedChildList
at android.view.View.populateAccessibilityNodeInfoDrawingOrderInParent
at android.view.View.onInitializeAccessibilityNodeInfoInternal
at android.view.ViewGroup.onInitializeAccessibilityNodeInfoInternal
at android.view.View.onInitializeAccessibilityNodeInfo
at android.view.View.createAccessibilityNodeInfoInternal
at android.view.View.createAccessibilityNodeInfo
at android.view.accessibility.AccessibilityRecord.setSource
...
at android.view.View.announceForAccessibility
at com.android.systemui.qs.QSPanel.onAnnouncementRequested
at com.android.systemui.qs.QSTile.handleStateChanged

This race condition can cause crashes, because the same ArrayList
(mPreSortedChildren or mTempArrayList in ViewGroup) is modified by two
different thread.

Test : manual

Change-Id: I9e0ad1fef4be7dc378463c06d10854e0e4c5b3d6
2016-12-26 00:20:43 +00:00
Treehugger Robot
4ce798f45f Merge "Add simplified_network_settings_bool to CarrierConfig." 2016-12-22 21:29:56 +00:00
Treehugger Robot
380697ca79 Merge "HwBinder: fail gracefully for device w/o hwbinder" 2016-12-22 20:41:01 +00:00
Joe LaPenna
5e0164e16c Add simplified_network_settings_bool to CarrierConfig.
Some carriers want to further simplify network settings based on a
variety of wifi or cellular related bundles. Expose a config a
carrier might set to allow SysUi, Settings and platform to adjust.

BUG: 33111931
Test: runtest carrierconfig-unit
Change-Id: I35a7ef15bbba23cf9e0380432fc001804c7e1804
Merged-In: I35a7ef15bbba23cf9e0380432fc001804c7e1804
2016-12-22 11:53:10 -08:00
Alex Klyubin
933ea68aca Merge "Make users of MtpServer fill in DeviceInfo field values" 2016-12-22 17:06:06 +00:00
Treehugger Robot
5e055b6a18 Merge "Fix failing WifiNetworkScoreCacheTest." 2016-12-22 03:11:58 +00:00
Sundeep Ghuman
0a5b3e2fe9 Fix failing WifiNetworkScoreCacheTest.
There was a NPE thrown by an unintialized mock.

Bug: 33818187
Test: Android unit tests
Change-Id: I478885dcebaf41f93488a6a12bb83652ad462be5
2016-12-21 16:44:46 -08:00
Treehugger Robot
425af45d02 Merge "Cherrypick: Define the calculateRankingScore method and Key." 2016-12-22 00:03:57 +00:00
Treehugger Robot
4a04c07df4 Merge changes I40f055df,I562713df
* changes:
  Stay bound to the most current active scorer.
  Clear and restore the calling ID.
2016-12-21 22:58:41 +00:00
Sundeep Ghuman
0d79bdef27 Cherrypick: Define the calculateRankingScore method and Key.
Define the key to be used to store the rankingScoreOffset inside the
ScoredNetwork bundle. Implement a platform API method to calculate the
ranking score for a given rssi.

OCL: ag/1688711

Bug: 33049302
Test: Unit tests
Change-Id: Ia3fea2197d7c211a2313fced8713d79d8d5f4f6e
Merged-In: Ia3fea2197d7c211a2313fced8713d79d8d5f4f6e
Topic: ScoredNetworkRankingScore
2016-12-21 13:57:24 -08:00
Alex Klyubin
abdc2b47b3 Make users of MtpServer fill in DeviceInfo field values
This is part of weaning apps off accessing system identifiers via
system properties API. Apps should use android.os.Build API instead.

Bug: 33700679
Test: Enable MTP mode then check that mtp-detect output same as before this commit
Change-Id: I4e6696cdee18b9c3e987c432c095911e85a997db
2016-12-21 13:56:28 -08:00
Jeremy Joslin
b1365852cc Stay bound to the most current active scorer.
This fixes the following issue:

1) Scorer A is active and bound.
2) A change occurs to Scorer A such that it is no longer the selected
   scorer.
3) Scorer B is selected as the scorer and returned whenever
   getActiveScorer() is queried.
4) Scorer A is never unbound because it isn't seen as the active
   scorer.
5) Scorer B is never bound until its package changes in some way (or
   the feature is disabled/enabled).

Test: runtest frameworks-services -c com.android.server.NetworkScoreServiceTest + manual testing.
Change-Id: I40f055df472e2b9e7b07e6979a841dd4c0b794ce
Merged-In: I468a8c02a72f089f1fb778d150d945efe5485b88
2016-12-21 13:44:53 -08:00
Jeremy Joslin
29ed4a99bf Clear and restore the calling ID.
Clear and restore the calling identity in IPC methods after asserting
the caller has the required permissions.

Fixed 2 tests in NetworkScoreServiceTest that were failing due to a
recent refactor.

Test: runtest frameworks-services -c com.android.server.NetworkScoreServiceTest
BUG: 33781319
Change-Id: I562713df3d9455cdc02bf80a687940fb9daecd8f
Merged-In: Icd79751d12dcfe4af8026980aaa1f7bd463468dc
2016-12-21 13:39:10 -08:00
Jeff Sharkey
febd982cdd Merge "Avoid Calendar's unexpect change in snapToCycleDay()" 2016-12-21 21:11:20 +00:00
Treehugger Robot
a93e57f1ac Merge "Expose ScanResult#untrusted as a @SystemApi." 2016-12-21 19:47:32 +00:00
Amin Shaikh
3d18c621cb Expose ScanResult#untrusted as a @SystemApi.
- Expose ScanResult#untrusted to inform NetworkRecommendationProviders
  that a ScanResult does not correspond to a saved network.
- Add static construction methods and assertions to RecommendationResult

Test: runtest frameworks-services

Bug: 33490132
Change-Id: If7006040f63843c1c468c9d95c5c017383c5c5dd
Merged-In: If7006040f63843c1c468c9d95c5c017383c5c5dd
2016-12-21 11:46:22 -08:00
Shunta Sato
d18ffd8223 Avoid Calendar's unexpect change in snapToCycleDay()
Symptom:
Calendar object's certain field is unexpectedly changed after
using Calendar.add() method.

Detail and sample:
Following patch causes this issue.
- Switch network cycle calculation to use Calendar.
  https://android.googlesource.com/platform/frameworks/base/+/f2bead5

Call of Calendar.add() method might make a smaller field value
invariant. The smaller field means such a field of
Calendar.HOUR_OF_DAY, Calendar.MINUTE, Calendar.SECOND and so on
if Calendar.MONTH field is focused.
According to above, sometimes correct Calendar value won't be
acquired by original code.
To avoid unexpected change, it requires initialization toward
each smaller field after Calendar.add() call.

Solutions:
Calendar.DAY_OF_MONTH, Calendar.HOUR_OF_DAY, Calendar.MINUTE,
and Calendar.SECOND fields is set to 0 after added value to
Calendar.MONTH field.

Bug: 32724903
Author: Shigeki Yokomichi <shigeki.x.yokomichi@sonymobile.com>
Change-Id: I7af6391653be21786b662b2f8eaad10c413733c1
2016-12-21 12:44:30 -07:00
Steven Moreland
520d12c53c HwBinder: fail gracefully for device w/o hwbinder
Test: compiles
Change-Id: I03ffd0d7480c5771634977e30ccf02b39f69f8ba
2016-12-21 11:02:49 -08:00
Jeff Sharkey
48d5d6cda8 Merge "Reconnect to installd when it restarts." 2016-12-21 18:45:46 +00:00
Jeff Sharkey
9f2f2183fc Reconnect to installd when it restarts.
Test: builds, boots, reconnects when installd dies
Bug: 33695164
Change-Id: I29769a111783095f742ad81af779a7403ca52ff3
2016-12-21 09:19:08 -07:00
Calin Juravle
f23ea2ca62 Merge "Report non-primary dex files loads to PM" 2016-12-21 09:57:41 +00:00
Treehugger Robot
d9ce420d9a Merge "Fix incorrect FIFO cgroup assignment." 2016-12-21 01:47:56 +00:00
Treehugger Robot
c1940ef392 Merge "Change fillColor for Wi-Fi badges to #FFFFFF." 2016-12-21 01:00:19 +00:00
Treehugger Robot
31a8f712ab Merge "Create and implement a CacheListener inside WifiNetworkScoreCache." 2016-12-21 00:28:48 +00:00
Amin Shaikh
70b1c6ab40 Change fillColor for Wi-Fi badges to #FFFFFF.
Bug: 33778046
Test: make
Change-Id: I0cfc2c6d682a2f13e665563fc1c54fa19324af53
2016-12-20 15:28:34 -08:00
Sundeep Ghuman
d76e65bead Create and implement a CacheListener inside WifiNetworkScoreCache.
Bug: 33041117
Test: Unit tests
Change-Id: Ic07522062f79223079b84c49210fcfc0217ecd38
2016-12-20 15:07:01 -08:00
Treehugger Robot
f456ddf3fd Merge "Make WifiConfiguration#meteredHint a @SystemApi" 2016-12-20 22:24:13 +00:00
Tim Murray
20375fe124 Fix incorrect FIFO cgroup assignment.
bug 33745094
Test: builds

Change-Id: I46eefc8ea6f17ca3795f4743692ddfea36d5db0f
2016-12-20 14:04:44 -08:00
Hall Liu
26e5096364 Merge "Adds carrier config to determine if high definition audio is displayed" 2016-12-20 21:13:31 +00:00
Andre Eisenbach
8e9551bacf Merge "Bluetooth: persist state when turning on from BLE" 2016-12-20 21:11:59 +00:00