Prevent factory reset for short passwords in CryptKeeper

Since patterns and passwords can't be shorter than 4
elements, we shouldn't count them against attempts to unlock
the device.  If we do, we risk resetting the device
due to stray input.

Bug: 18211475
Bug: 18273380

Change-Id: Ib329cd3383471483cda68bfac4278b17d0c09c57

Conflicts:
	src/com/android/settings/CryptKeeper.java

Conflicts:
	src/com/android/settings/CryptKeeper.java
Revert "Port: Wake on plug (2/2)"

This reverts commit fa6298e8a7c5a6c2af456249935e5cb2f0527e90.

Change-Id: Ia2c42e9c6d83dba204c4fe326bc8a477a21b75c0
Port: Wake on plug (2/2)

Change-Id: I22ee2a05040561cca796814573adc5226f1f03d4
Correct double tap to sleep summary

Change-Id: If2e7ab2c138e72eeb7d862738bb7dd3ad43d4b16
Correct development shortcut summary

Change-Id: Ia776d25c8f58789c3eedf16b7d5c705b04130b5f
Improve notification tone string

Change-Id: I731903a7bcda38229502de33dbc83c44e3782996
Protected Apps: update protected apps screens UI

Change-Id: I2dd922956f8ffd9ed153c3d1aa1f9161a127e4c6
Remove unnecessary drawables for launching Protected Apps

Change-Id: I58f471ef9d64c7ced79befbfc30b94d75a0085a2
Move Blacklist and Notif Filter to Privacy

Match CM 11

Change-Id: I5e3f9c26b68a89ba1622d95e2d0e4f4a93361c5e
Merge tag 'android-5.0.1_r1' into HEAD

Android 5.0.1 release 1
Development Settings: fix Advanced reboot not being updated on resume

Change-Id: I5475bec978c9cf50c02769091dbb43c6eff6c020
privacy: Actually set the blacklist preference

The preference was not being set, which caused this code to throw an NPE on
devices without telephony when opening the privacy preferences.

This bug also affects devices with telephony in that the preference doesn't
update its text. I also got rid of the null check because the preference
always exists, the null check is pointless and ended up hiding this bug.

Change-Id: I95555d44349700a8f29a71a2f2ee9aedf419b49b
bluetooth: Don't crash when the local adapter is not set

In devices where bluetooth is not working (like the emulator or devices
in development), the bluetooth Settings crashes when closing the activity.

Most of the code checks for the nullability of the local adapter except
for this particular piece. This is usually not a worry for production
devices and I wouldn't usually worry about this but since the rest of the
code performs the nullability check it seems silly to crash onPause.

Change-Id: I7c1d3b43969b516336be770957008ef2054d312f
Settings: squash of new profile UI for cm-12.0

Additions for cm-12.0:
- removed expanded desktop
- added add profile FAB
- updated tabs for meterial style
- added enabler switch bar

Squashed commits:
-------------------------------

Settings: refactor Profiles to be more user friendly

* Remove the notion of Profile app groups
* Rearrange profile setup flow, now we first present the user with ways
which will trigger the profile, then allow them to set what happens when
the profile is triggered.

Change-Id: I2870df894046cd43c21c67991fb5efc9c3fec837
Signed-off-by: Roman Birg <roman@cyngn.com>

Settings: cleanup new profiles UI

* cleanup old code
* for configuring profiles, add options to modify triggers and remove
the profile
* remove separate activity
* don't hardcode padding pixel sizes

Change-Id: I6b1d05c9f918714249411006c7562496e2a7539e
Signed-off-by: Roman Birg <roman@cyngn.com>

Profiles: fix expanded desktop settings not applying

Change-Id: Ia523145bf47bfc189c29b035ad5ec6e053cf9296

Settings: Fix profiles volume override summary.

Change-Id: I499cfb3006a7fc7b5e931ac854a7437f5d141523

Settings: fix Profiles expanded desktop choice mapping

Change-Id: Ib96811a0c268ca68a7b9732283c5abc142d143a4
Signed-off-by: Roman Birg <roman@cyngn.com>

Settings: add "Untouched" ring mode option in profiles

Change-Id: I4ac2d63119b328533217104a799cb0660ecddfb9
Signed-off-by: Roman Birg <roman@cyngn.com>

Settings: profiles: fix volume streams override behavior

Before we would always assume to override the stream, but that is not
always the case. Add a checkbox to turn the override on and off.

Change-Id: Ic1a58d59a9e514d4c2ccf376191ac7989bbead26
Signed-off-by: Roman Birg <roman@cyngn.com>
Merge branch 'cm-12.0' of https://github.com/cyanogenMod/android_packages_apps_settings into CyanogenMod-cm-12.0
Merge branch 'CyanogenMod-cm-12.0' into cm-12.0
setting clock DO NOT MERGE

Change-Id: Ie94cb5304c3813b6c83c55c494c2d89080e8e046