Commit Graph

1297 Commits

Author SHA1 Message Date
Adam Lesinski
534881d8fa Merge "Improve performance of LocaleList with Resources" into nyc-dev am: bb26248bbb am: 5e106dea45
am: 9ed84d8612

* commit '9ed84d86120dd6487eacba503f45f6d147f05fbf':
  Improve performance of LocaleList with Resources

Change-Id: I7c1694545f9eee940ca7065f3ac5aee5e2a7b27c
2016-05-24 21:47:36 +00:00
Adam Lesinski
5e106dea45 Merge "Improve performance of LocaleList with Resources" into nyc-dev
am: bb26248bbb

* commit 'bb26248bbba6e4014ea89a97b86618b7289a5f29':
  Improve performance of LocaleList with Resources

Change-Id: Ic43a26915a28d71a967eb038331a0f3c31bdfe8f
2016-05-24 21:35:56 +00:00
Adam Lesinski
b61e405397 Improve performance of LocaleList with Resources
We allow each individual Resources object to select the best
Locale for the given APK. This allows one update to the configuration
instead of multiple updates, once the locale is chosen.

The Java locale is selected from the app context's locale.

Bug:28625993
Bug:27325465
Change-Id: I99e1e53f522e560f3b80bbd1e1c605f552dbdff0
2016-05-24 12:54:48 -07:00
Adrian Roos
4d10db7fdd Fix RemoteViewsTests
Change-Id: I99d1f3b5521e3efad419074fede7eaef5707216d
2016-05-23 21:33:54 +00:00
Adam Lesinski
6028e28986 Merge "Merge "Fix parsing of kernel wakelocks" into nyc-dev am: 6f0d399214 am: 7dd96663a0" into nyc-mr1-dev-plus-aosp
am: 768542e38d

* commit '768542e38d356bd18cb567dacc89c504d128ccd4':
  Fix parsing of kernel wakelocks

Change-Id: Ic5b48697830e96528cd87a579f0ee8a5ab665bf9
2016-05-20 17:43:40 +00:00
Adam Lesinski
fea0c3af7a Merge "Fix parsing of kernel wakelocks" into nyc-dev
am: 6f0d399214

* commit '6f0d3992149aa782450667ed750fe0c3cf8ee334':
  Fix parsing of kernel wakelocks

Change-Id: Ibc60849809b5553e820833437a9d2d47d065a38e
2016-05-20 17:32:42 +00:00
Adam Lesinski
acb5ac77a3 Merge "Fix parsing of kernel wakelocks" into nyc-dev am: 6f0d399214
am: 7dd96663a0

* commit '7dd96663a0c728b4913ed4146cc442336833a1ca':
  Fix parsing of kernel wakelocks

Change-Id: I312c22fdbee545a2f7991c320ee4d5eea73decba
2016-05-20 17:32:04 +00:00
Adam Lesinski
6f0d399214 Merge "Fix parsing of kernel wakelocks" into nyc-dev 2016-05-20 17:23:08 +00:00
Adam Lesinski
d84ad30ee6 Fix parsing of kernel wakelocks
We handled stale wakelocks (wakelocks that disappear from /d/wakeup_sources)
differently in previous version of Android. They would be set stale, but still be
updated with their previous counts (they would never disappear).

The method setStale has been replaced with endSample(), which is semantically different.
Once a SamplingTimer has endSample() called, it expects any future calls to update() to
be a new sample, meaning the entire amount passed to update() is included in the kernel
wakelock's total. Since stale wakelocks were never removed from the list, this would
increase by large amounts when nothing had actually changed.

This was exacerbated by the fact that there was a bug where the last wakelock in
/d/wakeup_sources was never parsed, so if the order ever changed, this "stale" wakelock
would suddenly re-appear and the entire amount reported would be charged to the wakelock,
instead of just the difference since the last update.

All this was exposed when we added support to handle wakelocks that would disappear and
reappear with smaller values, meaning the kernel had pruned them from its accounting and
reset them.

Bug:28601080
Change-Id: Ic96027f7d580dac5e20aa73d67e5cedac4ccabeb
2016-05-19 17:21:10 -07:00
Yohei Yukawa
af15c8bcae Merge "Move LocaleList to avoid layering violation." into nyc-dev am: 31884efd13 am: ddaf3f4681
am: bf4c8f730b

* commit 'bf4c8f730b167e5ee65ed7c59dfa1d7867b63fcc':
  Move LocaleList to avoid layering violation.

Change-Id: I78fee5269f7428e34b196573575784fc15cb1372
2016-05-18 02:25:10 +00:00
Yohei Yukawa
ddaf3f4681 Merge "Move LocaleList to avoid layering violation." into nyc-dev
am: 31884efd13

* commit '31884efd13b3ac60078edaa0b7e8a4b75d995538':
  Move LocaleList to avoid layering violation.

Change-Id: I9132fe456a8d79569c651dac0a0bce0153444767
2016-05-18 02:18:38 +00:00
Yohei Yukawa
23cbe85610 Move LocaleList to avoid layering violation.
Since LocaleList needs to depend on android.os.Parcelable, we cannot let
that class belong to "android.util" package, which causes layering
violation.

Bug: 28819696
Change-Id: Ia8de2ee9df3dd0a42b1fe84574439519b680fe18
2016-05-17 16:42:58 -07:00
Felipe Leme
850ce012e7 Merge "Refactored NetworkPolicyManagerService mUidRules." into nyc-dev am: de66540fd3 am: 443c032e52
am: fd1ace40ec

* commit 'fd1ace40eccc468b5e5d33c29693bf66e1761d39':
  Refactored NetworkPolicyManagerService mUidRules.

Change-Id: I0b348dc47666d563d368d82aa9633dcfe56992a0
2016-05-06 22:03:18 +00:00
Felipe Leme
443c032e52 Merge "Refactored NetworkPolicyManagerService mUidRules." into nyc-dev
am: de66540fd3

* commit 'de66540fd3f73937c3cfbe1d50e575aa69acc474':
  Refactored NetworkPolicyManagerService mUidRules.

Change-Id: I25d2520eafcf8c45b80b94908a3b5bfa04315f76
2016-05-06 21:53:39 +00:00
Felipe Leme
46c4fc357c Refactored NetworkPolicyManagerService mUidRules.
NetworkPolicyManagerService (NMPS) keeps an internal list of uid
rules (mUidRules) for network restrictions, and when these rules
changes it needs to notify external listeners (such as
ConnectivityService / CS).

Prior to Android N, both Data Saver mode (the feature previously known
as "Restrict Baground Data") and Battery Save mode used the same set of
firewall rules to implement their restrictions: when Battery Saver mode
NPMS would mark all networks as metered and set the proper firewall
rules externally.

Recently, these 2 modes were split in 2 distinct firewall rules and
NMPS.updateRuleForRestrictBackgroundLocked() was changed to update
the mUidRules logic based on the Data Saver firewall (since the Battery
Saver firewall changes are handled externally, on
updateRuleForRestrictPowerLocked()). As such, CS was not notified when
the power-related changes were made, which would cause apps to get a
state of CONNECTED / CONNECTED when querying its active connection.

This change refactores the mUidRules to use bitmasks, in preparation for
another change that will fix the issue.

It also fixes a minor bug that was preventing removed packages to be
removed from the whitelist.

BUG: 28521946
Change-Id: I9f0e1509a6192cad403f740c1cd76a6b7dab7d26
2016-05-06 17:58:40 +00:00
Adam Lesinski
042799c06d Merge "BatteryStats: Fix up semantics of SamplingTimer" into nyc-dev am: 1a8a717 am: 8414b87
am: 34e3a5f

* commit '34e3a5f72daa73f69956aace6583370d82902171':
  BatteryStats: Fix up semantics of SamplingTimer

Change-Id: I08d997bc9c0fc96c54eee8dda69e3c62005b38e5
2016-04-23 00:29:37 +00:00
Adam Lesinski
8414b87f6c Merge "BatteryStats: Fix up semantics of SamplingTimer" into nyc-dev
am: 1a8a717

* commit '1a8a717ab517e7b5ace00bb4d3370e0f3a2677b2':
  BatteryStats: Fix up semantics of SamplingTimer

Change-Id: Iaab0fd5bf59399a3ef2bfe2eb3904ec13691e186
2016-04-23 00:23:56 +00:00
Adam Lesinski
757c6eacc8 BatteryStats: Fix up semantics of SamplingTimer
SamplingTimer has been losing some data, as well as not correctly handling
entries that have gone away and come back with less data (reset).

This change correctly ends a SamplingTimer sample by adding the accumulated amount
to the total, then reseting the running counter to accept new values.

This is also triggered automatically when the incoming data is less than what is currently
recorded.

Bug:25695597
Change-Id: I6b540906e6be527578d1003485384a75ba211b52
2016-04-22 14:48:18 -07:00
Adam Lesinski
9369eb8802 Merge "Record in progress count when parceling Timer" into nyc-dev am: 752434a am: 7c7ee79
am: 27d36bb

* commit '27d36bb9421c6a05990820919f90989a0d92323a':
  Record in progress count when parceling Timer

Change-Id: I364905f0be07562b83695fea09c0ca154e0171f6
2016-04-20 05:26:21 +00:00
Adam Lesinski
27d36bb942 Merge "Record in progress count when parceling Timer" into nyc-dev am: 752434a
am: 7c7ee79

* commit '7c7ee79dc93ad12b2b5535e9727eef30ce1a3693':
  Record in progress count when parceling Timer

Change-Id: I7c4c92d2048df9bab52596bd3c9717fac9a056fb
2016-04-20 05:20:26 +00:00
Adam Lesinski
50e1291340 Merge "Record in progress count when parceling Timer" into nyc-dev
am: 752434a

* commit '752434a0ff54ac30b7701292b66361e64b2ae5a0':
  Record in progress count when parceling Timer

Change-Id: Icc7e8312df00bd22f0e5433e15fc65d2ad705db4
2016-04-20 01:31:46 +00:00
Adam Lesinski
752434a0ff Merge "Record in progress count when parceling Timer" into nyc-dev 2016-04-20 01:22:37 +00:00
Adam Lesinski
98f0d4692c Record in progress count when parceling Timer
The total time is computed before parceling, but the total count is not.

Bug:27747854
Change-Id: If3afdca9605f74d96a54fb9df17f6df761b99e55
2016-04-19 17:21:40 -07:00
Seigo Nonaka
c2c0786787 Merge "Delete emojis before and after ZWJ at the same time." into nyc-dev am: 7ecd767 am: 3de469a
am: e519b51

* commit 'e519b51d1db816c454bd73ded90ae6b9ea32de4e':
  Delete emojis before and after ZWJ at the same time.

Change-Id: I2426af56d5659c3e6c67d82cbd449815bb7d0e14
2016-04-19 18:44:59 +00:00
Raph Levien
e519b51d1d Merge "Delete emojis before and after ZWJ at the same time." into nyc-dev am: 7ecd767
am: 3de469a

* commit '3de469a68750e8b9b455a4a5bd3a78ad2ecd4af0':
  Delete emojis before and after ZWJ at the same time.

Change-Id: I826f62aae6baaffea722d8c853cc1d01c8ff41f5
2016-04-19 18:39:52 +00:00
Seigo Nonaka
c94fd1664e Merge "Delete emojis before and after ZWJ at the same time." into nyc-dev
am: 7ecd767

* commit '7ecd7671b75b2ae7c4d20928722b4a1d41bd62ff':
  Delete emojis before and after ZWJ at the same time.

Change-Id: If877cde7549f0bd0e56c7cbd707e360c8df012fd
2016-04-19 18:36:15 +00:00
Raph Levien
7ecd7671b7 Merge "Delete emojis before and after ZWJ at the same time." into nyc-dev 2016-04-19 18:31:05 +00:00
Jeff Sharkey
8f218a61af Merge "Unlock should always wait for pending PRE_BOOT." into nyc-dev am: 89fa73f am: 25b3756
am: 4d341a5

* commit '4d341a5a1c204e4b23fd86cb78b85dd3471c4bb5':
  Unlock should always wait for pending PRE_BOOT.

Change-Id: Id07b89914bcf161ab1a8e9fb1d61b3e2f69c0fe3
2016-04-19 17:28:55 +00:00
Jeff Sharkey
4d341a5a1c Merge "Unlock should always wait for pending PRE_BOOT." into nyc-dev am: 89fa73f
am: 25b3756

* commit '25b37561104a3dfb5cc52d076f904fe0e8313217':
  Unlock should always wait for pending PRE_BOOT.

Change-Id: Ieba43635739603787daa110a0bf35381c0e09574
2016-04-19 17:22:36 +00:00
Jeff Sharkey
4dc65d31a1 Merge "Unlock should always wait for pending PRE_BOOT." into nyc-dev
am: 89fa73f

* commit '89fa73fd7abe0f87634d2914163a8fc79ba2f738':
  Unlock should always wait for pending PRE_BOOT.

Change-Id: I0043da18fabef2c5c916a2e5562d9e613c2b057c
2016-04-19 17:16:25 +00:00
Seigo Nonaka
3675d3cd84 Delete emojis before and after ZWJ at the same time.
Vendor may want to introduce their own ZWJ emoji sequence. To delete
them by one back space as the same behavior of Unicode emoji sequence,
use all emoji as the zwj emoji.

Bug: 28248662
Change-Id: I572dad42ee108476962d4b3fe9f3a6019cb50098
2016-04-19 18:54:50 +09:00
Jeff Sharkey
84a4c971c4 Unlock should always wait for pending PRE_BOOT.
While processing an unlock request, we might go async to handle
long-running operations like dispatching PRE_BOOT_COMPLETED.  This
change ensures that all unlock requests for a particular user wait
in line behind any pending async operations.

Without this CL, any subsequent unlock requests would immediately
return successful, even though PRE_BOOT_COMPLETED events were still
being processed.

Bug: 28240584
Change-Id: I307d6aaebfb8f38028f3666a2e19e4399b7cf3a7
2016-04-18 15:38:35 -06:00
Siyamed Sinir
5932e8b8f0 Update autoLink URL regex to match empty path, $ and _
Update URL regular expression to match
- path and query that contains dollar sign
- domain name that contains underscore
- empty path with query parameters. i.e. a.com?q=v

Bug: 27436084
Bug: 27501264
Change-Id: I3884624e145ccc1175915327dc2f280ef4e55ce1
2016-04-13 20:10:47 +00:00
Joe Onorato
5ae916e1ad Merge "Merge "Add some tests for procstats, and fix some bugs that the tests uncovered." into nyc-dev am: 5dc3c67" into nyc-dev-plus-aosp
am: e111018

* commit 'e111018c1766b5708a85660ee5f52b7f2a64357d':
  Add some tests for procstats, and fix some bugs that the tests uncovered.

Change-Id: I3b4957a0f20767a44a5064b1276ccd34c49b26f8
2016-04-12 22:42:11 +00:00
Joe Onorato
f35f061c50 Merge "Add some tests for procstats, and fix some bugs that the tests uncovered." into nyc-dev
am: 5dc3c67

* commit '5dc3c674a2635179d17e96af8fb248142e03b87e':
  Add some tests for procstats, and fix some bugs that the tests uncovered.

Change-Id: I53ee3334f58db4a0904370fc4f2f1b6b29365020
2016-04-12 22:22:52 +00:00
Joe Onorato
65adfeecd2 Add some tests for procstats, and fix some bugs that the tests uncovered.
Bug: 27045736
Change-Id: Ia910730c5a3a899c89aa63dd7ab48be62cf9cfef
2016-04-12 13:13:41 -07:00
Siyamed Sinir
4b46826f16 Merge "Exclude unicode space characters from autoLink URL patterns" into nyc-dev am: 4b92594
am: cda996c

* commit 'cda996cff8ab4a0b8009768a6754a031b2c2a731':
  Exclude unicode space characters from autoLink URL patterns

Change-Id: I00026490816b2a64424effe34d349870eaeae549
2016-04-12 00:48:10 +00:00
Siyamed Sinir
cda996cff8 Merge "Exclude unicode space characters from autoLink URL patterns" into nyc-dev
am: 4b92594

* commit '4b92594857ce52f96252f43c776f3ed31f0ebdfb':
  Exclude unicode space characters from autoLink URL patterns

Change-Id: Ie8c41292ab33ed50cd41a62eaa98ca7f1a06db14
2016-04-12 00:43:08 +00:00
Siyamed Sinir
4b92594857 Merge "Exclude unicode space characters from autoLink URL patterns" into nyc-dev 2016-04-12 00:35:29 +00:00
Yohei Yukawa
f883c447aa Merge "Shift+Meta+Space should reverse-rotate subtypes." into nyc-dev am: 270fe5d
am: ddee287

* commit 'ddee2875c1587fabf09a6e0afa4369119c91ede7':
  Shift+Meta+Space should reverse-rotate subtypes.

Change-Id: I82773b8bf55eacc6fbc07ee98936df47619f1400
2016-04-11 06:43:07 +00:00
Yohei Yukawa
ddee2875c1 Merge "Shift+Meta+Space should reverse-rotate subtypes." into nyc-dev
am: 270fe5d

* commit '270fe5dbe49b5619ac87ebd50cdececd699fc0ad':
  Shift+Meta+Space should reverse-rotate subtypes.

Change-Id: I8d0bd25545c6892f2788194350e290e6f8d9eb4c
2016-04-11 05:32:05 +00:00
Yohei Yukawa
d39ae85482 Shift+Meta+Space should reverse-rotate subtypes.
This is a follow up CL to my previous CL [1], which added a new key
binding Meta+Space to rotate enabled IME subtypes.  With this CL,
Shift+Meta+Space starts reverse-rotating enabled IME subtypes as
originally planed.

 [1]: I4005692215edfcf8bed3e86b1e07000148f986f5
      ae61f7118a

Bug: 25753404
Bug: 28103839
Change-Id: I3694edd80be6dfe18b90360e24ae4d451b331928
2016-04-10 20:28:40 -07:00
Adam Lesinski
3acf361908 Merge "Remove tests that have been moved to CTS" into nyc-dev am: 41c1bb8
am: 968e6e9

* commit '968e6e940a86633192fd81802aa6846dc2d13301':
  Remove tests that have been moved to CTS

Change-Id: I2053b6ea6865e7dc347344a21da13601135e41f9
2016-04-07 17:12:44 +00:00
Adam Lesinski
968e6e940a Merge "Remove tests that have been moved to CTS" into nyc-dev
am: 41c1bb8

* commit '41c1bb8f4a5a1f2f0a23d6cece525eaea50f57b3':
  Remove tests that have been moved to CTS

Change-Id: I39012b182d637d37fccafbc13677089885dcbcdb
2016-04-07 17:08:33 +00:00
Adam Lesinski
41c1bb8f4a Merge "Remove tests that have been moved to CTS" into nyc-dev 2016-04-07 17:04:13 +00:00
Keisuke Kuroyanagi
3c4a67def0 Merge "Rewrite SuggestionsPopupWindowTest using espresso." into nyc-dev am: d119ab9
am: 240c23b

* commit '240c23b5340a5a37cb162d3fbef5c880cabca2d8':
  Rewrite SuggestionsPopupWindowTest using espresso.

Change-Id: I70b0a86b391fed471cd2f7d1e14b55c818bab90b
2016-04-07 04:40:35 +00:00
Keisuke Kuroyanagi
240c23b534 Merge "Rewrite SuggestionsPopupWindowTest using espresso." into nyc-dev
am: d119ab9

* commit 'd119ab94c0d55c3077b1a7c8ca6a54baf6d7087b':
  Rewrite SuggestionsPopupWindowTest using espresso.

Change-Id: I5dca34e91ee05a1cc3cea3f5fa016df675266cb5
2016-04-07 04:37:50 +00:00
Keisuke Kuroyanagi
d119ab94c0 Merge "Rewrite SuggestionsPopupWindowTest using espresso." into nyc-dev 2016-04-07 04:33:11 +00:00
Adam Lesinski
04518f8e9f Remove tests that have been moved to CTS
ag/906284

Change-Id: I9e5da9239a62dbc85a1b22f8fe8876da65675d9a
2016-04-06 17:47:10 -07:00
Keisuke Kuroyanagi
31eb74fb2b Rewrite SuggestionsPopupWindowTest using espresso.
- Rewrite existing test about text appearance.
- Add new tests for suggestions popup.

Bug: 25904136
Bug: 27765262
Change-Id: I12e522436a83fa264cd22176d054877eec411708
2016-04-06 19:37:46 +09:00