672 Commits

Author SHA1 Message Date
Casey Burkhardt
86b867fd45 Adds Settings.System.FONT_SCALE observer to ActivityManagerService
Changes to Settings.System.FONT_SCALE were not being handled by any service,
which required a device reboot for any changes to take effect.  Changes to
this field by the Settings app worked as expected only because it is able to
poke ActivityManager with an updated configuration, whereas unbundled
applications cannot.

This also ensures the setting value is backed up and doesn't conflict with
a configured value from accessibility onboarding during restore.

Bug:23033258
Change-Id: I98d4aed2f9f5893d054e6b10c4dfda406de8eba2
2016-01-24 04:21:36 -08:00
xinhe
f7705c3ed6 Initial codes for Quality network selection
In this change list, the old WifiAutojoin module is
    refactored initially. The old WifiAutojoinController is
    replaced with a new WifiQualifiedNetworkSelector.
    WifiConfiguration, WifiConfigureStore and
    WifiStateMachine have been modified accordingly. The new
    network selection logic is refactored with a more clear
    and deterministci one. To refer to thedescribed in
    details, in "Quality Network Selection and Connectivity
    Scan Management in N". The link of the document is:
    https://docs.google.com/document/d
    /1JPTa2NEk-PgjCJ16fIrR6ohV-kDKveDlYDOeiMCB2_c

cherry-picked from 8d106780b6a638552749e54e169fc72537d4bccc
and make changes on WiFiConfigurationSerializer.java since
it is not on mm-wireless-dev
Bug:26012244
Change-Id: I44e454544b630b891c9a58a18b5a028edcce580f
2016-01-13 15:06:30 -08:00
Mahaver Chopra
d68cc200ec Merge "Handle null pointer exception" 2016-01-08 20:20:02 +00:00
Anna Galusza
69c952f833 Merge "Add remaining Accessibility Settings to backup list. Note additional settings that should not be restored if they are already set (on account of the new Setup Wizard, which allows critical Accessibility Settings to be set before restore)." 2016-01-08 19:25:01 +00:00
Mahaver Chopra
87648756e3 Handle null pointer exception
Handle null pointer exception, just in case calling entitity doesn't
check.

Change-Id: I1b4809476cc689ad3dfd426e123a64e9a0336c87
2016-01-08 19:23:57 +00:00
Mahaver Chopra
dea471ef54 Added Data roaming user restriction
Added new user restriction DISALLOW_DATA_ROAMING, can only be set
by device owners.

Bug: 24890464
Change-Id: Ic4cb37dd5f9bbffa35f921751488ef7c7ff99452
2016-01-08 18:07:31 +00:00
Anna Galusza
fa7786cbe7 Add remaining Accessibility Settings to backup
list. Note additional settings that should not be
restored if they are already set (on account of
the new Setup Wizard, which allows critical
Accessibility Settings to be set before restore).

Change-Id: I95524abbef20ab12e529a2b1e6165adc7294c3db
2016-01-08 09:28:53 -08:00
Fyodor Kupolov
42f9fe75e6 Merge "Optimized database creation for a new user" 2015-12-18 17:22:04 +00:00
Bryce Lee
bd17928afc resolve merge conflicts of 6b9e5bf0c2 to master.
Change-Id: Idada49313619533bfeb375ee232c942589457fa4
2015-12-18 03:05:20 +00:00
Bryce Lee
9eaa59a1ff Merge "Add setting for declaring disabled bluetooth profiles." into cw-e-dev
am: cf91b45c05

* commit 'cf91b45c05358c81ddaccf3ddd4b1ea6d5295faa':
  Add setting for declaring disabled bluetooth profiles.
2015-12-17 11:45:17 -08:00
Fyodor Kupolov
497b5faba9 Optimized database creation for a new user
If the file doesn't exist, database can be kept in memory. It's safe because
the database will be migrated and disposed of immediately after onCreate
finishes.

Bug: 26237300
Change-Id: Ib37c520f28960c8d6b9ce8dd719ffbcc11a97a58
2015-12-17 10:47:33 -08:00
Bryce Lee
ec85f34812 Add setting for declaring disabled bluetooth profiles.
Bug: 25900899
Change-Id: I420a7c590d72ba10f3e466d15dccfdbb520e810a
2015-12-16 13:32:28 -08:00
Geoff Mendal
5f7eefc8d0 Import translations. DO NOT MERGE
Change-Id: I8dc68f5b6e8579613e61c5a060a9d2fff5729cef
Auto-generated-cl: translation import
2015-12-16 06:08:30 -08:00
Christopher Tate
a89f9d93cb Don't back up / restore EAP network definitions
Bug 25725016

Cherrypick from AOSP.

Change-Id: I6aa11a76e7724a0aaad05a1aa074afa2c429370c
2015-12-10 18:23:22 -08:00
Ritesh Reddy
4d4f0db8d9 Merge changes I2363e66a,If17effb9
* changes:
  Enabled NetworkPolicy backup and restore.
  Enabled SoftAP Configuration Backup
2015-12-10 18:38:42 +00:00
Ritesh Reddy
9f548b00dc Enabled NetworkPolicy backup and restore.
Backing up NetworkPolicy through NetworkPolicyManager API

Bug: 17857156
Change-Id: I2363e66a1b27f50b2454b4550a241a3d84bf4b7c
2015-12-10 16:21:18 +00:00
Ritesh Reddy
188ae9dc22 Enabled SoftAP Configuration Backup
Backing up SoftAP Configuration through WifiManager API.

Bug: 5343116
Change-Id: If17effb98c3489246d817fa3612f3f11b9ead9ab
2015-12-08 10:21:53 +00:00
Suprabh Shukla
269c11eee1 Added default config to enable adding users from lockscreen
A config value is added for enabling/disabling the ability
to add users while screen is locked. The config value, currently false,
is read and applied to the setting only if the user has not set the
value as true/false explicitly.

Bug-Id: b/24662310
Change-Id: Ie00ab0952c64cbc9805794bc0dde350920750026
2015-12-02 17:51:37 -08:00
Geoff Mendal
696953ca25 Import translations. DO NOT MERGE
Change-Id: I4247a09a0c94930c560bf92822248a4fc59903ac
Auto-generated-cl: translation import
2015-11-30 05:57:50 -08:00
Makoto Onuki
28da2e3490 Fix "some user restrictions not working" issue
SettingsProvider used to prevent any changes to certain settings
when the corresponding user restriction is set, which isn't really what
these restrictions mean.
Even if a user restriction is set, it should still changing in the more
restricting direction.

Also stop setting "" to LOCATION_PROVIDERS_ALLOWED, which will simply
be ignored.

Bug 25614198

Change-Id: Ifa8edc2927e21e6c6174620c8c874c86c1dc0f75
2015-11-23 10:48:16 -08:00
Svetoslav Ganov
c47132c205 Merge "Use resolved calling user id" 2015-11-20 21:10:52 +00:00
Svetoslav
d8d25e0038 Use resolved calling user id
bug:25476216

Change-Id: I0093a5c071affaa5f3ca8eeb0e3a7a36b66a3c1f
2015-11-20 13:09:32 -08:00
Chris Tate
3d4e969f4f Merge "Don\'t back up / restore EAP network definitions" am: 14a0981fde am: b5a38f6da5
am: 96333c2e8c

* commit '96333c2e8cd13df55e8c878925f8cd2e9c90ac42':
  Don't back up / restore EAP network definitions
2015-11-20 18:15:52 +00:00
Chris Tate
96333c2e8c Merge "Don\'t back up / restore EAP network definitions" am: 14a0981fde
am: b5a38f6da5

* commit 'b5a38f6da5f59020e2c32e00d7228ed71c18f70d':
  Don't back up / restore EAP network definitions
2015-11-20 18:10:21 +00:00
Chris Tate
b5a38f6da5 Merge "Don\'t back up / restore EAP network definitions"
am: 14a0981fde

* commit '14a0981fdef45967b19c3db4fb2f298c8b5a1f7c':
  Don't back up / restore EAP network definitions
2015-11-20 18:05:04 +00:00
Christopher Tate
9bc2f472e9 Don't back up / restore EAP network definitions
Bug 25725016

Change-Id: Idfef9dd53f2403bbe4c950493a0ab8fa66a3b7d4
2015-11-18 13:42:04 -08:00
Jeff Sharkey
f9fc6d6cc0 More file-based encryption work.
Add granular StorageManager APIs for key creation/destruction and
unlocking/locking.  Start passing through an opaque token as part
of the unlock command, but leave it empty for now.  We now have a
separate "prepare" method that sanity checks that user directories
are correctly setup.

Define a handful of system properties used for marking devices that
should be operating in FBE mode, and if they're emulating FBE.  Wire
a command to "sm", but persisting will come later.

Start using new "encryptionAware" flag on apps previously marked with
coreApp flag, which were apps running in the legacy CryptKeeper
model.  Small tweaks to handle non-encryptionAware voice interaction
services.  Switch PackageManager to consult StorageManager about the
unlocked state of a user.

Bug: 22358539
Change-Id: Ic2865f9b81c10ea39369c441422f7427a3c3c3d6
2015-11-11 10:47:23 -08:00
Svetoslav
41f3c49cce Don't crash if cannot persist settings
bug:23569962

Change-Id: I19fd7d37b6de251696d119cfc33e87e9743b2029
2015-11-09 19:47:22 +00:00
Baligh Uddin
185269d3e9 Import translations. DO NOT MERGE
Auto-generated-cl: translation import

Bug: 25433205
Change-Id: I3ae0e8f44a5933c708d072f2053dbde77795e411
2015-11-04 11:56:04 -08:00
Fyodor Kupolov
cd86ebf1c9 Check multi-user support in isUserSwitcherEnabled
isUserSwitcherEnabled now returns false if multi-user is disabled(
supportsMultipleUsers() returns false).

Removed GUEST_USER_ENABLED setting and replaced with DPM.getGuestUserDisabled
check. It currently always returns false, but will be replaced with an actual
policy check.

Bug: 17571233
Change-Id: I41853e8b321b2537952cac5d92e88bfdb8cbd9a8
2015-09-30 14:08:01 -07:00
Xiaohui Chen
e4de5a0d3b Cleanup OWNER references.
Bug: 19913735
Change-Id: I2150c6baaab80fe11312e4401394a2a8da52e595
2015-09-23 18:50:11 +00:00
Xiaohui Chen
43765b77a0 Cleanup USER_OWNER in SettingsProvider[Test]
Fixed up the tests and re-enabled it.
Still suppressed one test because what it relies on Settings.Bookmarks
is broken because Settings query format changed.
Fixed a bug in SettingsProvider that the package query is using the
wrong user id.

Bug: 19913735
Change-Id: Ied86a261defba2706f726a13bc32f385f7d93787
2015-09-02 09:52:02 -07:00
Chris Tate
590fb3e066 am 863676ef: am d4c0b52e: am 1e05bc6f: am 5ca842ae: am 5d05a24c: Merge "Fix wifi disable during restore" into mnc-dev
* commit '863676ef7f30080a1b88633c7c75f71f91150dbd':
  Fix wifi disable during restore
2015-08-10 23:13:33 +00:00
Chris Tate
d4c0b52e2a am 1e05bc6f: am 5ca842ae: am 5d05a24c: Merge "Fix wifi disable during restore" into mnc-dev
* commit '1e05bc6f77b9e609df598ef0aed20a0ef81848a1':
  Fix wifi disable during restore
2015-08-10 22:59:28 +00:00
Chris Tate
1e05bc6f77 am 5ca842ae: am 5d05a24c: Merge "Fix wifi disable during restore" into mnc-dev
* commit '5ca842ae0836a8daa04fd57cfc56f8e3b3e5054c':
  Fix wifi disable during restore
2015-08-10 22:51:28 +00:00
Chris Tate
5ca842ae08 am 5d05a24c: Merge "Fix wifi disable during restore" into mnc-dev
* commit '5d05a24cff5be83dc7b03deccfb7f52b0066b34e':
  Fix wifi disable during restore
2015-08-10 22:40:25 +00:00
Christopher Tate
45dc0d03fd Fix wifi disable during restore
The main looper needs to run freely for a moment after disabling
wifi in order for various signals (content observers, broadcast) to
propagate to all the listeners that need to take action for the
wifi stack to shut all the way down.  This patch breaks up the
disable-and-rewrite-config sequence of wifi AP restore in to two
distinct operations separated by a moment so as not to block those
necessary messages.

Bug 22979342

Change-Id: I271766cad0e454669a194652fb67f835bb022cd1
2015-08-07 19:20:05 -07:00
Chris Tate
e00211490d am a394b3d2: am 94275813: am 117f024b: am db0cff71: am c376afb4: Merge "Wait a bit longer for wifi to shut down before rewriting the config" into mnc-dev
* commit 'a394b3d25f53744ef9802d421422864595d19488':
  Wait a bit longer for wifi to shut down before rewriting the config
2015-08-07 23:06:41 +00:00
Chris Tate
94275813c2 am 117f024b: am db0cff71: am c376afb4: Merge "Wait a bit longer for wifi to shut down before rewriting the config" into mnc-dev
* commit '117f024b2566e8cce7b0d0669ce528dac7aa23ac':
  Wait a bit longer for wifi to shut down before rewriting the config
2015-08-07 18:40:38 +00:00
Chris Tate
117f024b25 am db0cff71: am c376afb4: Merge "Wait a bit longer for wifi to shut down before rewriting the config" into mnc-dev
* commit 'db0cff71c8d1a7f7f1d5c12a4f7c343030adf21b':
  Wait a bit longer for wifi to shut down before rewriting the config
2015-08-07 18:36:09 +00:00
Chris Tate
db0cff71c8 am c376afb4: Merge "Wait a bit longer for wifi to shut down before rewriting the config" into mnc-dev
* commit 'c376afb472d1d4f0fba4a03ac4cf05b498866d64':
  Wait a bit longer for wifi to shut down before rewriting the config
2015-08-07 18:19:35 +00:00
Christopher Tate
907e01eb70 Wait a bit longer for wifi to shut down before rewriting the config
We've seen case of it taking longer than 1500ms for the wifi system to
actually shut down after the triggering settings element is written,
so extend the wait time a bit.  We've seen it take more than 1500ms
but not more than 2500ms, so that's the new heuristic.

This will of course all become happily obsolete once we start
applying restored AP definitions programmatically rather than by
filesystem-level operations.

Bug 22979342

Change-Id: I6acf1baac23d4100124093128b82abf242b11a0e
2015-08-07 10:57:01 -07:00
Svetoslav Ganov
774fe81a7b am fa3dd628: am 5290bf58: am db67d5b7: am ba6cdbfd: am ac8c9861: Merge "Notify settings URI change without a lock held" into mnc-dev
* commit 'fa3dd628149b78e19b93db963385eac2b62f0334':
  Notify settings URI change without a lock held
2015-08-04 01:40:55 +00:00
Svetoslav Ganov
5290bf5875 am db67d5b7: am ba6cdbfd: am ac8c9861: Merge "Notify settings URI change without a lock held" into mnc-dev
* commit 'db67d5b79ab2da6d8b8a1211b354687fb7930744':
  Notify settings URI change without a lock held
2015-08-04 01:17:54 +00:00
Svetoslav Ganov
db67d5b79a am ba6cdbfd: am ac8c9861: Merge "Notify settings URI change without a lock held" into mnc-dev
* commit 'ba6cdbfdbbbb6f83052e895a698fcc0d71793b25':
  Notify settings URI change without a lock held
2015-08-04 01:09:07 +00:00
Svetoslav Ganov
ba6cdbfdbb am ac8c9861: Merge "Notify settings URI change without a lock held" into mnc-dev
* commit 'ac8c98614cb8260615795b2042699d93b21a1097':
  Notify settings URI change without a lock held
2015-08-04 01:00:17 +00:00
Svetoslav
7e0683b3bd Notify settings URI change without a lock held
bug:22469552

Change-Id: Ie4a42ceef07e3a8e593fe2b1374420239242ce7b
2015-08-03 16:06:49 -07:00
Billy Lau
a91dccdf57 am bafb5130: am ee2ee0f9: am be6bfb4c: am 83749ac9: am a6706627: Merge "Bug: 21589105 Rescope WRITE_SETTINGS permission (framework services perm check changes)" into mnc-dev
* commit 'bafb51305731fd837b12878fffabe8885239ea10':
  Bug: 21589105 Rescope WRITE_SETTINGS permission (framework services perm check changes)
2015-07-29 23:51:47 +00:00
Billy Lau
ee2ee0f92d am be6bfb4c: am 83749ac9: am a6706627: Merge "Bug: 21589105 Rescope WRITE_SETTINGS permission (framework services perm check changes)" into mnc-dev
* commit 'be6bfb4c910e02d7e18b732d7f9cf09d5b3e94a7':
  Bug: 21589105 Rescope WRITE_SETTINGS permission (framework services perm check changes)
2015-07-29 23:17:55 +00:00
Billy Lau
be6bfb4c91 am 83749ac9: am a6706627: Merge "Bug: 21589105 Rescope WRITE_SETTINGS permission (framework services perm check changes)" into mnc-dev
* commit '83749ac948c40a3c302f00bef47ef0b4bba96ae7':
  Bug: 21589105 Rescope WRITE_SETTINGS permission (framework services perm check changes)
2015-07-29 23:02:05 +00:00