Support pre-KitKat properties for update-binary

Google changed the in-memory format for storing properties in 4.4.
Zips containing an older update-binary expect the old format, otherwise
assertions on properties in the update script fail.

This is just enough of the old property service to copy the properties
to the legacy format before running the updater.

Change-Id: I404680384bdc5e952609e295029ab0a0faf743a5
Fix incorrect alignment of Restore Defaults button in some themes

Change-Id: I11bd9fea2a900a92794c5c297846eb87265eeee7
Merge "Fix incorrect alignment of Restore Defaults button in some themes" into android-4.4
Check to ensure that selinux_handle is populated before using

Change-Id: I6de4c5db3e3183229d7029fc72b957c7ef61f23a
Run TWFunc::Fixup_Time_On_Boot() before OpenRecoveryScript

* Fixes possible issues with names of backups made with ORS

Change-Id: If8da1b3abb0960e527bb0eb3dd8a04d184aaea4d
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
Fix skipping of relative paths and lost+found in twrpDU

Change-Id: Ib79029fd6237502338b041a6bc2f9e539536d6ad
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
Merge "Fix skipping of relative paths and lost+found in twrpDU" into android-4.4
Improve handling of settings storage and android secure

Change-Id: I8af92543c2f0c201e7220267c417d74e4561038d
Change to lstat so we don't count the target of symbolic links as part
of the tar archive size. Big thanks to Tassadar for pointing out the
fix.

Change-Id: I8894ffef54c93939b5b455634169d9c14d8ed7af
Re-arrange handling of settings storage partition

Sometimes we received an error about being unable to locate
storage partition because the DataManager would attempt to access
the PartitionManager before we finished adding the storage
partitions to the vector.

Change-Id: I0ce1778938d308b1eb17de46a192ecd52489cad3
Allow disabling legacy properties

Introduce TW_NO_LEGACY_PROPS flag for users that build TWRP in
non-kitkat trees and don't need the legacy prop environment.

Change-Id: Iacb2d9af7d7069acb3d0a96bb34f32ded6317a20
Actually skip excluded files from tar backup

Change-Id: Ibbc4eb2eb89863ccb2a15f5a3b5092fb10fcbcc0
Cleanup DU Get_Folder_Size function

Change-Id: I3c686c7c3a171f130d299fae586dc811cad0d3a9
Fix /data backup size if contains media subdirs

/data/*/media directories are mistakenly being excluded from the size
calculation. Change to absolute dir exclude so that only /data/media is
excluded.

Change-Id: I6e97604d44e6ea2bdf7dfd8c68a2f90ba6d44415
correctly mount tmpfs as /tmp in recovery

The syntax of init's mount command changed in April 2008 but
recovery's init.rc was never updated, so recovery's /tmp has been on
the root fs all this time.  Fix.

Also add /system/bin to the PATH in recovery, which is handy for
debugging.

Change-Id: I9e60d18803906bc75c263f12c8863cfd6a14147b
Add HTC charging LED support

Original implementation by Tom Hite, only slightly modified by Matt
Mower.

Change-Id: Ibc73bf04f122f5de1702f8beeccc468a9a1a2e95